diff options
Diffstat (limited to 'lib/AsmParser/llvmAsmParser.cpp')
-rw-r--r-- | lib/AsmParser/llvmAsmParser.cpp | 4815 |
1 files changed, 2101 insertions, 2714 deletions
diff --git a/lib/AsmParser/llvmAsmParser.cpp b/lib/AsmParser/llvmAsmParser.cpp index 5cb9fff077..9eee49dfb5 100644 --- a/lib/AsmParser/llvmAsmParser.cpp +++ b/lib/AsmParser/llvmAsmParser.cpp @@ -1,265 +1,114 @@ -/* A Bison parser, made by GNU Bison 1.875c. */ -/* Skeleton parser for Yacc-like parsing with Bison, - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003 Free Software Foundation, Inc. +/* A Bison parser, made from /Users/sabre/cvs/llvm/lib/AsmParser/llvmAsmParser.y + by GNU Bison version 1.28 */ - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ +#define YYBISON 1 /* Identify Bison output. */ -/* As a special exception, when this file is copied by Bison into a - Bison output file, you may use that output file without restriction. - This special exception was added by the Free Software Foundation - in version 1.24 of Bison. */ - -/* Written by Richard Stallman by simplifying the original so called - ``semantic'' parser. */ - -/* All symbols defined below should begin with yy or YY, to avoid - infringing on user name space. This should be done even for local - variables, as they might otherwise be expanded by user macros. - There are some unavoidable exceptions within include files to - define necessary library symbols; they are noted "INFRINGES ON - USER NAME SPACE" below. */ - -/* Identify Bison output. */ -#define YYBISON 1 - -/* Skeleton name. */ -#define YYSKELETON_NAME "yacc.c" - -/* Pure parsers. */ -#define YYPURE 0 - -/* Using locations. */ -#define YYLSP_NEEDED 0 - -/* If NAME_PREFIX is specified substitute the variables and functions - names. */ #define yyparse llvmAsmparse -#define yylex llvmAsmlex +#define yylex llvmAsmlex #define yyerror llvmAsmerror -#define yylval llvmAsmlval -#define yychar llvmAsmchar +#define yylval llvmAsmlval +#define yychar llvmAsmchar #define yydebug llvmAsmdebug #define yynerrs llvmAsmnerrs - - -/* Tokens. */ -#ifndef YYTOKENTYPE -# define YYTOKENTYPE - /* Put the tokens into the symbol table, so that GDB and other debuggers - know about them. */ - enum yytokentype { - ESINT64VAL = 258, - EUINT64VAL = 259, - SINTVAL = 260, - UINTVAL = 261, - FPVAL = 262, - VOID = 263, - BOOL = 264, - SBYTE = 265, - UBYTE = 266, - SHORT = 267, - USHORT = 268, - INT = 269, - UINT = 270, - LONG = 271, - ULONG = 272, - FLOAT = 273, - DOUBLE = 274, - TYPE = 275, - LABEL = 276, - VAR_ID = 277, - LABELSTR = 278, - STRINGCONSTANT = 279, - IMPLEMENTATION = 280, - ZEROINITIALIZER = 281, - TRUETOK = 282, - FALSETOK = 283, - BEGINTOK = 284, - ENDTOK = 285, - DECLARE = 286, - GLOBAL = 287, - CONSTANT = 288, - SECTION = 289, - VOLATILE = 290, - TO = 291, - DOTDOTDOT = 292, - NULL_TOK = 293, - UNDEF = 294, - CONST = 295, - INTERNAL = 296, - LINKONCE = 297, - WEAK = 298, - APPENDING = 299, - OPAQUE = 300, - NOT = 301, - EXTERNAL = 302, - TARGET = 303, - TRIPLE = 304, - ENDIAN = 305, - POINTERSIZE = 306, - LITTLE = 307, - BIG = 308, - ALIGN = 309, - DEPLIBS = 310, - CALL = 311, - TAIL = 312, - CC_TOK = 313, - CCC_TOK = 314, - FASTCC_TOK = 315, - COLDCC_TOK = 316, - RET = 317, - BR = 318, - SWITCH = 319, - INVOKE = 320, - UNWIND = 321, - UNREACHABLE = 322, - ADD = 323, - SUB = 324, - MUL = 325, - DIV = 326, - REM = 327, - AND = 328, - OR = 329, - XOR = 330, - SETLE = 331, - SETGE = 332, - SETLT = 333, - SETGT = 334, - SETEQ = 335, - SETNE = 336, - MALLOC = 337, - ALLOCA = 338, - FREE = 339, - LOAD = 340, - STORE = 341, - GETELEMENTPTR = 342, - PHI_TOK = 343, - CAST = 344, - SELECT = 345, - SHL = 346, - SHR = 347, - VAARG = 348, - EXTRACTELEMENT = 349, - INSERTELEMENT = 350, - VAARG_old = 351, - VANEXT_old = 352 - }; -#endif -#define ESINT64VAL 258 -#define EUINT64VAL 259 -#define SINTVAL 260 -#define UINTVAL 261 -#define FPVAL 262 -#define VOID 263 -#define BOOL 264 -#define SBYTE 265 -#define UBYTE 266 -#define SHORT 267 -#define USHORT 268 -#define INT 269 -#define UINT 270 -#define LONG 271 -#define ULONG 272 -#define FLOAT 273 -#define DOUBLE 274 -#define TYPE 275 -#define LABEL 276 -#define VAR_ID 277 -#define LABELSTR 278 -#define STRINGCONSTANT 279 -#define IMPLEMENTATION 280 -#define ZEROINITIALIZER 281 -#define TRUETOK 282 -#define FALSETOK 283 -#define BEGINTOK 284 -#define ENDTOK 285 -#define DECLARE 286 -#define GLOBAL 287 -#define CONSTANT 288 -#define SECTION 289 -#define VOLATILE 290 -#define TO 291 -#define DOTDOTDOT 292 -#define NULL_TOK 293 -#define UNDEF 294 -#define CONST 295 -#define INTERNAL 296 -#define LINKONCE 297 -#define WEAK 298 -#define APPENDING 299 -#define OPAQUE 300 -#define NOT 301 -#define EXTERNAL 302 -#define TARGET 303 -#define TRIPLE 304 -#define ENDIAN 305 -#define POINTERSIZE 306 -#define LITTLE 307 -#define BIG 308 -#define ALIGN 309 -#define DEPLIBS 310 -#define CALL 311 -#define TAIL 312 -#define CC_TOK 313 -#define CCC_TOK 314 -#define FASTCC_TOK 315 -#define COLDCC_TOK 316 -#define RET 317 -#define BR 318 -#define SWITCH 319 -#define INVOKE 320 -#define UNWIND 321 -#define UNREACHABLE 322 -#define ADD 323 -#define SUB 324 -#define MUL 325 -#define DIV 326 -#define REM 327 -#define AND 328 -#define OR 329 -#define XOR 330 -#define SETLE 331 -#define SETGE 332 -#define SETLT 333 -#define SETGT 334 -#define SETEQ 335 -#define SETNE 336 -#define MALLOC 337 -#define ALLOCA 338 -#define FREE 339 -#define LOAD 340 -#define STORE 341 -#define GETELEMENTPTR 342 -#define PHI_TOK 343 -#define CAST 344 -#define SELECT 345 -#define SHL 346 -#define SHR 347 -#define VAARG 348 -#define EXTRACTELEMENT 349 -#define INSERTELEMENT 350 -#define VAARG_old 351 -#define VANEXT_old 352 - - - - -/* Copy the first part of user declarations. */ -#line 14 "/proj/llvm/llvm2/lib/AsmParser/llvmAsmParser.y" +#define ESINT64VAL 257 +#define EUINT64VAL 258 +#define SINTVAL 259 +#define UINTVAL 260 +#define FPVAL 261 +#define VOID 262 +#define BOOL 263 +#define SBYTE 264 +#define UBYTE 265 +#define SHORT 266 +#define USHORT 267 +#define INT 268 +#define UINT 269 +#define LONG 270 +#define ULONG 271 +#define FLOAT 272 +#define DOUBLE 273 +#define TYPE 274 +#define LABEL 275 +#define VAR_ID 276 +#define LABELSTR 277 +#define STRINGCONSTANT 278 +#define IMPLEMENTATION 279 +#define ZEROINITIALIZER 280 +#define TRUETOK 281 +#define FALSETOK 282 +#define BEGINTOK 283 +#define ENDTOK 284 +#define DECLARE 285 +#define GLOBAL 286 +#define CONSTANT 287 +#define SECTION 288 +#define VOLATILE 289 +#define TO 290 +#define DOTDOTDOT 291 +#define NULL_TOK 292 +#define UNDEF 293 +#define CONST 294 +#define INTERNAL 295 +#define LINKONCE 296 +#define WEAK 297 +#define APPENDING 298 +#define OPAQUE 299 +#define NOT 300 +#define EXTERNAL 301 +#define TARGET 302 +#define TRIPLE 303 +#define ENDIAN 304 +#define POINTERSIZE 305 +#define LITTLE 306 +#define BIG 307 +#define ALIGN 308 +#define DEPLIBS 309 +#define CALL 310 +#define TAIL 311 +#define ASM_TOK 312 +#define CC_TOK 313 +#define CCC_TOK 314 +#define FASTCC_TOK 315 +#define COLDCC_TOK 316 +#define RET 317 +#define BR 318 +#define SWITCH 319 +#define INVOKE 320 +#define UNWIND 321 +#define UNREACHABLE 322 +#define ADD 323 +#define SUB 324 +#define MUL 325 +#define DIV 326 +#define REM 327 +#define AND 328 +#define OR 329 +#define XOR 330 +#define SETLE 331 +#define SETGE 332 +#define SETLT 333 +#define SETGT 334 +#define SETEQ 335 +#define SETNE 336 +#define MALLOC 337 +#define ALLOCA 338 +#define FREE 339 +#define LOAD 340 +#define STORE 341 +#define GETELEMENTPTR 342 +#define PHI_TOK 343 +#define CAST 344 +#define SELECT 345 +#define SHL 346 +#define SHR 347 +#define VAARG 348 +#define EXTRACTELEMENT 349 +#define INSERTELEMENT 350 +#define VAARG_old 351 +#define VANEXT_old 352 + +#line 14 "/Users/sabre/cvs/llvm/lib/AsmParser/llvmAsmParser.y" #include "ParserInternals.h" #include "llvm/CallingConv.h" @@ -1123,23 +972,8 @@ Module *llvm::RunVMAsmParser(const char * AsmString, Module * M) { } - -/* Enabling traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif - -/* Enabling verbose error messages. */ -#ifdef YYERROR_VERBOSE -# undef YYERROR_VERBOSE -# define YYERROR_VERBOSE 1 -#else -# define YYERROR_VERBOSE 0 -#endif - -#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED) -#line 878 "/proj/llvm/llvm2/lib/AsmParser/llvmAsmParser.y" -typedef union YYSTYPE { +#line 878 "/Users/sabre/cvs/llvm/lib/AsmParser/llvmAsmParser.y" +typedef union { llvm::Module *ModuleVal; llvm::Function *FunctionVal; std::pair<llvm::PATypeHolder*, char*> *ArgVal; @@ -1178,1284 +1012,944 @@ typedef union YYSTYPE { llvm::Instruction::OtherOps OtherOpVal; llvm::Module::Endianness Endianness; } YYSTYPE; -/* Line 191 of yacc.c. */ -#line 1183 "llvmAsmParser.tab.c" -# define yystype YYSTYPE /* obsolescent; will be withdrawn */ -# define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 -#endif - - - -/* Copy the second part of user declarations. */ - - -/* Line 214 of yacc.c. */ -#line 1195 "llvmAsmParser.tab.c" - -#if ! defined (yyoverflow) || YYERROR_VERBOSE +#include <stdio.h> -# ifndef YYFREE -# define YYFREE free -# endif -# ifndef YYMALLOC -# define YYMALLOC malloc -# endif - -/* The parser invokes alloca or malloc; define the necessary symbols. */ - -# ifdef YYSTACK_USE_ALLOCA -# if YYSTACK_USE_ALLOCA -# define YYSTACK_ALLOC alloca -# endif -# else -# if defined (alloca) || defined (_ALLOCA_H) -# define YYSTACK_ALLOC alloca -# else -# ifdef __GNUC__ -# define YYSTACK_ALLOC __builtin_alloca -# endif -# endif -# endif +#ifndef __cplusplus +#ifndef __STDC__ +#define const +#endif +#endif -# ifdef YYSTACK_ALLOC - /* Pacify GCC's `empty if-body' warning. */ -# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) -# else -# if defined (__STDC__) || defined (__cplusplus) -# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# define YYSIZE_T size_t -# endif -# define YYSTACK_ALLOC YYMALLOC -# define YYSTACK_FREE YYFREE -# endif -#endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */ -#if (! defined (yyoverflow) \ - && (! defined (__cplusplus) \ - || (defined (YYSTYPE_IS_TRIVIAL) && YYSTYPE_IS_TRIVIAL))) +#define YYFINAL 465 +#define YYFLAG -32768 +#define YYNTBASE 113 + +#define YYTRANSLATE(x) ((unsigned)(x) <= 352 ? yytranslate[x] : 183) + +static const char yytranslate[] = { 0, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 102, + 103, 111, 2, 100, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 107, + 99, 108, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 104, 101, 106, 2, 2, 2, 2, 2, 112, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 105, + 2, 2, 109, 2, 110, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 1, 3, 4, 5, 6, + 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, + 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, + 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, + 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, + 97, 98 +}; -/* A type that is properly aligned for any stack member. */ -union yyalloc -{ - short yyss; - YYSTYPE yyvs; - }; +#if YYDEBUG != 0 +static const short yyprhs[] = { 0, + 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, + 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, + 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, + 60, 62, 64, 67, 68, 70, 72, 74, 76, 77, + 78, 80, 82, 84, 87, 88, 91, 92, 96, 99, + 100, 102, 103, 107, 109, 112, 114, 116, 118, 120, + 122, 124, 126, 128, 130, 132, 134, 136, 138, 140, + 142, 144, 146, 148, 150, 152, 154, 157, 162, 168, + 174, 178, 181, 184, 186, 190, 192, 196, 198, 199, + 204, 208, 212, 217, 222, 226, 229, 232, 235, 238, + 241, 244, 247, 250, 253, 256, 263, 269, 278, 285, + 292, 299, 306, 313, 317, 319, 321, 323, 325, 328, + 331, 335, 338, 340, 345, 348, 352, 353, 361, 362, + 370, 374, 379, 380, 382, 384, 386, 390, 394, 398, + 402, 406, 408, 409, 411, 413, 415, 416, 419, 423, + 425, 427, 431, 433, 434, 443, 445, 447, 451, 453, + 455, 458, 459, 463, 465, 467, 469, 471, 473, 475, + 477, 479, 483, 485, 487, 489, 491, 493, 496, 499, + 502, 506, 509, 510, 512, 515, 518, 522, 532, 542, + 551, 565, 567, 569, 576, 582, 585, 592, 600, 602, + 606, 608, 609, 612, 614, 620, 626, 632, 635, 640, + 645, 652, 657, 662, 667, 672, 679, 682, 690, 692, + 695, 696, 698, 699, 703, 710, 714, 721, 724, 729, + 736 +}; -/* The size of the maximum gap between one aligned stack and the next. */ -# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) - -/* The size of an array large to enough to hold all stacks, each with - N elements. */ -# define YYSTACK_BYTES(N) \ - ((N) * (sizeof (short) + sizeof (YYSTYPE)) \ - + YYSTACK_GAP_MAXIMUM) - -/* Copy COUNT objects from FROM to TO. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined (__GNUC__) && 1 < __GNUC__ -# define YYCOPY(To, From, Count) \ - __builtin_memcpy (To, From, (Count) * sizeof (*(From))) -# else -# define YYCOPY(To, From, Count) \ - do \ - { \ - register YYSIZE_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ - } \ - while (0) -# endif -# endif - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack, Stack, yysize); \ - Stack = &yyptr->Stack; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (0) +static const short yyrhs[] = { 5, + 0, 6, 0, 3, 0, 4, 0, 69, 0, 70, + 0, 71, 0, 72, 0, 73, 0, 74, 0, 75, + 0, 76, 0, 77, 0, 78, 0, 79, 0, 80, + 0, 81, 0, 82, 0, 92, 0, 93, 0, 16, + 0, 14, 0, 12, 0, 10, 0, 17, 0, 15, + 0, 13, 0, 11, 0, 119, 0, 120, 0, 18, + 0, 19, 0, 153, 99, 0, 0, 41, 0, 42, + 0, 43, 0, 44, 0, 0, 0, 60, 0, 61, + 0, 62, 0, 59, 4, 0, 0, 54, 4, 0, + 0, 100, 54, 4, 0, 34, 24, 0, 0, 128, + 0, 0, 100, 131, 130, 0, 128, 0, 54, 4, + 0, 134, 0, 8, 0, 136, 0, 8, 0, 136, + 0, 9, 0, 10, 0, 11, 0, 12, 0, 13, + 0, 14, 0, 15, 0, 16, 0, 17, 0, 18, + 0, 19, 0, 20, 0, 21, 0, 45, 0, 135, + 0, 166, 0, 101, 4, 0, 133, 102, 138, 103, + 0, 104, 4, 105, 136, 106, 0, 107, 4, 105, + 136, 108, 0, 109, 137, 110, 0, 109, 110, 0, + 136, 111, 0, 136, 0, 137, 100, 136, 0, 137, + 0, 137, 100, 37, 0, 37, 0, 0, 134, 104, + 141, 106, 0, 134, 104, 106, 0, 134, 112, 24, + 0, 134, 107, 141, 108, 0, 134, 109, 141, 110, + 0, 134, 109, 110, 0, 134, 38, 0, 134, 39, + 0, 134, 166, 0, 134, 140, 0, 134, 26, 0, + 119, 114, 0, 120, 4, 0, 9, 27, 0, 9, + 28, 0, 122, 7, 0, 90, 102, 139, 36, 134, + 103, 0, 88, 102, 139, 180, 103, 0, 91, 102, + 139, 100, 139, 100, 139, 103, 0, 115, 102, 139, + 100, 139, 103, 0, 116, 102, 139, 100, 139, 103, + 0, 117, 102, 139, 100, 139, 103, 0, 118, 102, + 139, 100, 139, 103, 0, 95, 102, 139, 100, 139, + 103, 0, 141, 100, 139, 0, 139, 0, 32, 0, + 33, 0, 144, 0, 144, 162, 0, 144, 163, 0, + 144, 58, 148, 0, 144, 25, 0, 145, 0, 145, + 123, 20, 132, 0, 145, 163, 0, 145, 58, 148, + 0, 0, 145, 123, 124, 142, 139, 146, 130, 0, + 0, 145, 123, 47, 142, 134, 147, 130, 0, 145, + 48, 150, 0, 145, 55, 99, 151, 0, 0, 24, + 0, 53, 0, 52, 0, 50, 99, 149, 0, 51, + 99, 4, 0, 49, 99, 24, 0, 104, 152, 106, + 0, 152, 100, 24, 0, 24, 0, 0, 22, 0, + 24, 0, 153, 0, 0, 134, 154, 0, 156, 100, + 155, 0, 155, 0, 156, 0, 156, 100, 37, 0, + 37, 0, 0, 125, 132, 153, 102, 157, 103, 129, + 126, 0, 29, 0, 109, 0, 124, 158, 159, 0, + 30, 0, 110, 0, 169, 161, 0, 0, 31, 164, + 158, 0, 3, 0, 4, 0, 7, 0, 27, 0, + 28, 0, 38, 0, 39, 0, 26, 0, 107, 141, + 108, 0, 140, 0, 113, 0, 153, 0, 166, 0, + 165, 0, 134, 167, 0, 169, 170, 0, 160, 170, + 0, 171, 123, 172, 0, 171, 174, 0, 0, 23, + 0, 63, 168, 0, 63, 8, 0, 64, 21, 167, + 0, 64, 9, 167, 100, 21, 167, 100, 21, 167, + 0, 65, 121, 167, 100, 21, 167, 104, 173, 106, + 0, 65, 121, 167, 100, 21, 167, 104, 106, 0, + 66, 125, 132, 167, 102, 177, 103, 36, 21, 167, + 67, 21, 167, 0, 67, 0, 68, 0, 173, 121, + 165, 100, 21, 167, 0, 121, 165, 100, 21, 167, + 0, 123, 179, 0, 134, 104, 167, 100, 167, 106, + 0, 175, 100, 104, 167, 100, 167, 106, 0, 168, + 0, 176, 100, 168, 0, 176, 0, 0, 57, 56, + 0, 56, 0, 115, 134, 167, 100, 167, 0, 116, + 134, 167, 100, 167, 0, 117, 134, 167, 100, 167, + 0, 46, 168, 0, 118, 168, 100, 168, 0, 90, + 168, 36, 134, 0, 91, 168, 100, 168, 100, 168, + 0, 94, 168, 100, 134, 0, 97, 168, 100, 134, + 0, 98, 168, 100, 134, 0, 95, 168, 100, 168, + 0, 96, 168, 100, 168, 100, 168, 0, 89, 175, + 0, 178, 125, 132, 167, 102, 177, 103, 0, 182, + 0, 100, 176, 0, 0, 35, 0, 0, 83, 134, + 127, 0, 83, 134, 100, 15, 167, 127, 0, 84, + 134, 127, 0, 84, 134, 100, 15, 167, 127, 0, + 85, 168, 0, 181, 86, 134, 167, 0, 181, 87, + 168, 100, 134, 167, 0, 88, 134, 167, 180, 0 +}; #endif -#if defined (__STDC__) || defined (__cplusplus) - typedef signed char yysigned_char; -#else - typedef short yysigned_char; +#if YYDEBUG != 0 +static const short yyrline[] = { 0, + 997, 998, 1005, 1006, 1015, 1015, 1015, 1015, 1015, 1016, + 1016, 1016, 1017, 1017, 1017, 1017, 1017, 1017, 1019, 1019, + 1023, 1023, 1023, 1023, 1024, 1024, 1024, 1024, 1025, 1025, + 1026, 1026, 1029, 1032, 1036, 1036, 1037, 1038, 1039, 1042, + 1042, 1043, 1044, 1045, 1054, 1054, 1060, 1060, 1068, 1075, + 1075, 1081, 1081, 1083, 1087, 1100, 1100, 1101, 1101, 1103, + 1112, 1112, 1112, 1112, 1112, 1112, 1112, 1113, 1113, 1113, + 1113, 1113, 1113, 1114, 1117, 1120, 1126, 1133, 1145, 1149, + 1160, 1169, 1172, 1180, 1184, 1189, 1190, 1193, 1196, 1206, + 1231, 1244, 1272, 1297, 1317, 1329, 1338, 1342, 1401, 1407, + 1415, 1420, 1425, 1428, 1431, 1438, 1448, 1479, 1486, 1507, + 1517, 1522, 1529, 1539, 1542, 1549, 1549, 1559, 1566, 1570, + 1573, 1576, 1579, 1592, 1612, 1614, 1616, 1619, 1622, 1626, + 1629, 1631, 1633, 1637, 1646, 1647, 1649, 1652, 1660, 1665, + 1667, 1671, 1675, 1683, 1683, 1684, 1684, 1686, 1692, 1697, + 1703, 1706, 1711, 1715, 1719, 1805, 1805, 1807, 1815, 1815, + 1817, 1821, 1821, 1830, 1833, 1836, 1839, 1842, 1845, 1848, + 1851, 1854, 1878, 1885, 1888, 1893, 1893, 1899, 1903, 1906, + 1914, 1923, 1927, 1937, 1948, 1951, 1954, 1957, 1960, 1974, + 1978, 2031, 2034, 2040, 2048, 2058, 2065, 2070, 2077, 2081, + 2087, 2087, 2089, 2092, 2098, 2110, 2121, 2131, 2143, 2150, + 2157, 2164, 2169, 2188, 2210, 2218, 2230, 2244, 2301, 2307, + 2309, 2313, 2316, 2322, 2326, 2330, 2334, 2338, 2345, 2355, + 2368 +}; #endif -/* YYFINAL -- State number of the termination state. */ -#define YYFINAL 4 -/* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 1210 - -/* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 112 -/* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 70 -/* YYNRULES -- Number of rules. */ -#define YYNRULES 229 -/* YYNRULES -- Number of states. */ -#define YYNSTATES 460 - -/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ -#define YYUNDEFTOK 2 -#define YYMAXUTOK 352 - -#define YYTRANSLATE(YYX) \ - ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) - -/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ -static const unsigned char yytranslate[] = -{ - 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 101, 102, 110, 2, 99, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 106, 98, 107, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 103, 100, 105, 2, 2, 2, 2, 2, 111, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 104, 2, 2, 108, 2, 109, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, - 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, - 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, - 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, - 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, - 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, - 95, 96, 97 -}; -#if YYDEBUG -/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in - YYRHS. */ -static const unsigned short yyprhs[] = -{ - 0, 0, 3, 5, 7, 9, 11, 13, 15, 17, - 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, - 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, - 59, 61, 63, 65, 67, 70, 71, 73, 75, 77, - 79, 80, 81, 83, 85, 87, 90, 91, 94, 95, - 99, 102, 103, 105, 106, 110, 112, 115, 117, 119, - 121, 123, 125, 127, 129, 131, 133, 135, 137, 139, - 141, 143, 145, 147, 149, 151, 153, 155, 157, 160, - 165, 171, 177, 181, 184, 187, 189, 193, 195, 199, - 201, 202, 207, 211, 215, 220, 225, 229, 232, 235, - 238, 241, 244, 247, 250, 253, 256, 259, 266, 272, - 281, 288, 295, 302, 309, 316, 320, 322, 324, 326, - 328, 331, 334, 337, 339, 344, 347, 348, 356, 357, - 365, 369, 374, 375, 377, 379, 383, 387, 391, 395, - 399, 401, 402, 404, 406, 408, 409, 412, 416, 418, - 420, 424, 426, 427, 436, 438, 440, 444, 446, 448, - 451, 452, 456, 458, 460, 462, 464, 466, 468, 470, - 472, 476, 478, 480, 482, 484, 486, 489, 492, 495, - 499, 502, 503, 505, 508, 511, 515, 525, 535, 544, - 558, 560, 562, 569, 575, 578, 585, 593, 595, 599, - 601, 602, 605, 607, 613, 619, 625, 628, 633, 638, - 645, 650, 655, 660, 665, 672, 675, 683, 685, 688, - 689, 691, 692, 696, 703, 707, 714, 717, 722, 729 +#if YYDEBUG != 0 || defined (YYERROR_VERBOSE) + +static const char * const yytname[] = { "$","error","$undefined.","ESINT64VAL", +"EUINT64VAL","SINTVAL","UINTVAL","FPVAL","VOID","BOOL","SBYTE","UBYTE","SHORT", +"USHORT","INT","UINT","LONG","ULONG","FLOAT","DOUBLE","TYPE","LABEL","VAR_ID", +"LABELSTR","STRINGCONSTANT","IMPLEMENTATION","ZEROINITIALIZER","TRUETOK","FALSETOK", +"BEGINTOK","ENDTOK","DECLARE","GLOBAL","CONSTANT","SECTION","VOLATILE","TO", +"DOTDOTDOT","NULL_TOK","UNDEF","CONST","INTERNAL","LINKONCE","WEAK","APPENDING", +"OPAQUE","NOT","EXTERNAL","TARGET","TRIPLE","ENDIAN","POINTERSIZE","LITTLE", +"BIG","ALIGN","DEPLIBS","CALL","TAIL","ASM_TOK","CC_TOK","CCC_TOK","FASTCC_TOK", +"COLDCC_TOK","RET","BR","SWITCH","INVOKE","UNWIND","UNREACHABLE","ADD","SUB", +"MUL","DIV","REM","AND","OR","XOR","SETLE","SETGE","SETLT","SETGT","SETEQ","SETNE", +"MALLOC","ALLOCA","FREE","LOAD","STORE","GETELEMENTPTR","PHI_TOK","CAST","SELECT", +"SHL","SHR","VAARG","EXTRACTELEMENT","INSERTELEMENT","VAARG_old","VANEXT_old", +"'='","','","'\\\\'","'('","')'","'['","'x'","']'","'<'","'>'","'{'","'}'","'*'", +"'c'","INTVAL","EINT64VAL","ArithmeticOps","LogicalOps","SetCondOps","ShiftOps", +"SIntType","UIntType","IntType","FPType","OptAssign","OptLinkage","OptCallingConv", +"OptAlign","OptCAlign","SectionString","OptSection","GlobalVarAttributes","GlobalVarAttribute", +"TypesV","UpRTypesV","Types","PrimType","UpRTypes","TypeListI","ArgTypeListI", +"ConstVal","ConstExpr","ConstVector","GlobalType","Module","FunctionList","ConstPool", +"@1","@2","AsmBlock","BigOrLittle","TargetDefinition","LibrariesDefinition", +"LibList","Name","OptName","ArgVal","ArgListH","ArgList","FunctionHeaderH","BEGIN", +"FunctionHeader","END","Function","FunctionProto","@3","ConstValueRef","SymbolicValueRef", +"ValueRef","ResolvedVal","BasicBlockList","BasicBlock","InstructionList","BBTerminatorInst", +"JumpTable","Inst","PHIList","ValueRefList","ValueRefListE","OptTailCall","InstVal", +"IndexList","OptVolatile","MemoryInst", NULL }; +#endif -/* YYRHS -- A `-1'-separated list of the rules' RHS. */ -static const short yyrhs[] = -{ - 143, 0, -1, 5, -1, 6, -1, 3, -1, 4, - -1, 68, -1, 69, -1, 70, -1, 71, -1, 72, - -1, 73, -1, 74, -1, 75, -1, 76, -1, 77, - -1, 78, -1, 79, -1, 80, -1, 81, -1, 91, - -1, 92, -1, 16, -1, 14, -1, 12, -1, 10, - -1, 17, -1, 15, -1, 13, -1, 11, -1, 119, - -1, 120, -1, 18, -1, 19, -1, 152, 98, -1, - -1, 41, -1, 42, -1, 43, -1, 44, -1, -1, - -1, 59, -1, 60, -1, 61, -1, 58, 4, -1, - -1, 54, 4, -1, -1, 99, 54, 4, -1, 34, - 24, -1, -1, 128, -1, -1, 99, 131, 130, -1, - 128, -1, 54, 4, -1, 134, -1, 8, -1, 136, - -1, 8, -1, 136, -1, 9, -1, 10, -1, 11, - -1, 12, -1, 13, -1, 14, -1, 15, -1, 16, - -1, 17, -1, 18, -1, 19, -1, 20, -1, 21, - -1, 45, -1, 135, -1, 165, -1, 100, 4, -1, - 133, 101, 138, 102, -1, 103, 4, 104, 136, 105, - -1, 106, 4, 104, 136, 107, -1, 108, 137, 109, - -1, 108, 109, -1, 136, 110, -1, 136, -1, 137, - 99, 136, -1, 137, -1, 137, 99, 37, -1, 37, - -1, -1, 134, 103, 141, 105, -1, 134, 103, 105, - -1, 134, 111, 24, -1, 134, 106, 141, 107, -1, - 134, 108, 141, 109, -1, 134, 108, 109, -1, 134, - 38, -1, 134, 39, -1, 134, 165, -1, 134, 140, - -1, 134, 26, -1, 119, 114, -1, 120, 4, -1, - 9, 27, -1, 9, 28, -1, 122, 7, -1, 89, - 101, 139, 36, 134, 102, -1, 87, 101, 139, 179, - 102, -1, 90, 101, 139, 99, 139, 99, 139, 102, - -1, 115, 101, 139, 99, 139, 102, -1, 116, 101, - 139, 99, 139, 102, -1, 117, 101, 139, 99, 139, - 102, -1, 118, 101, 139, 99, 139, 102, -1, 94, - 101, 139, 99, 139, 102, -1, 141, 99, 139, -1, - 139, -1, 32, -1, 33, -1, 144, -1, 144, 161, - -1, 144, 162, -1, 144, 25, -1, 145, -1, 145, - 123, 20, 132, -1, 145, 162, -1, -1, 145, 123, - 124, 142, 139, 146, 130, -1, -1, 145, 123, 47, - 142, 134, 147, 130, -1, 145, 48, 149, -1, 145, - 55, 98, 150, -1, -1, 53, -1, 52, -1, 50, - 98, 148, -1, 51, 98, 4, -1, 49, 98, 24, - -1, 103, 151, 105, -1, 151, 99, 24, -1, 24, - -1, -1, 22, -1, 24, -1, 152, -1, -1, 134, - 153, -1, 155, 99, 154, -1, 154, -1, 155, -1, - 155, 99, 37, -1, 37, -1, -1, 125, 132, 152, - 101, 156, 102, 129, 126, -1, 29, -1, 108, -1, - 124, 157, 158, -1, 30, -1, 109, -1, 168, 160, - -1, -1, 31, 163, 157, -1, 3, -1, 4, -1, - 7, -1, 27, -1, 28, -1, 38, -1, 39, -1, - 26, -1, 106, 141, 107, -1, 140, -1, 113, -1, - 152, -1, 165, -1, 164, -1, 134, 166, -1, 168, - 169, -1, 159, 169, -1, 170, 123, 171, -1, 170, - 173, -1, -1, 23, -1, 62, 167, -1, 62, 8, - -1, 63, 21, 166, -1, 63, 9, 166, 99, 21, - 166, 99, 21, 166, -1, 64, 121, 166, 99, 21, - 166, 103, 172, 105, -1, 64, 121, 166, 99, 21, - 166, 103, 105, -1, 65, 125, 132, 166, 101, 176, - 102, 36, 21, 166, 66, 21, 166, -1, 66, -1, - 67, -1, 172, 121, 164, 99, 21, 166, -1, 121, - 164, 99, 21, 166, -1, 123, 178, -1, 134, 103, - 166, 99, 166, 105, -1, 174, 99, 103, 166, 99, - 166, 105, -1, 167, -1, 175, 99, 167, -1, 175, - -1, -1, 57, 56, -1, 56, -1, 115, 134, 166, - 99, 166, -1, 116, 134, 166, 99, 166, -1, 117, - 134, 166, 99, 166, -1, 46, 167, -1, 118, 167, - 99, 167, -1, 89, 167, 36, 134, -1, 90, 167, - 99, 167, 99, 167, -1, 93, 167, 99, 134, -1, - 96, 167, 99, 134, -1, 97, 167, 99, 134, -1, - 94, 167, 99, 167, -1, 95, 167, 99, 167, 99, - 167, -1, 88, 174, -1, 177, 125, 132, 166, 101, - 176, 102, -1, 181, -1, 99, 175, -1, -1, 35, - -1, -1, 82, 134, 127, -1, 82, 134, 99, 15, - 166, 127, -1, 83, 134, 127, -1, 83, 134, 99, - 15, 166, 127, -1, 84, 167, -1, 180, 85, 134, - 166, -1, 180, 86, 167, 99, 134, 166, -1, 87, - 134, 166, 179, -1 +static const short yyr1[] = { 0, + 113, 113, 114, 114, 115, 115, 115, 115, 115, 116, + 116, 116, 117, 117, 117, 117, 117, 117, 118, 118, + 119, 119, 119, 119, 120, 120, 120, 120, 121, 121, + 122, 122, 123, 123, 124, 124, 124, 124, 124, 125, + 125, 125, 125, 125, 126, 126, 127, 127, 128, 129, + 129, 130, 130, 131, 131, 132, 132, 133, 133, 134, + 135, 135, 135, 135, 135, 135, 135, 135, 135, 135, + 135, 135, 135, 136, 136, 136, 136, 136, 136, 136, + 136, 136, 136, 137, 137, 138, 138, 138, 138, 139, + 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, + 139, 139, 139, 139, 139, 140, 140, 140, 140, 140, + 140, 140, 140, 141, 141, 142, 142, 143, 144, 144, + 144, 144, 144, 145, 145, 145, 146, 145, 147, 145, + 145, 145, 145, 148, 149, 149, 150, 150, 150, 151, + 152, 152, 152, 153, 153, 154, 154, 155, 156, 156, + 157, 157, 157, 157, 158, 159, 159, 160, 161, 161, + 162, 164, 163, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 166, 166, 167, 167, 168, 169, 169, |