LLVM API Documentation
#include "ParserInternals.h"
#include "llvm/CallingConv.h"
#include "llvm/InlineAsm.h"
#include "llvm/Instructions.h"
#include "llvm/Module.h"
#include "llvm/SymbolTable.h"
#include "llvm/Assembly/AutoUpgrade.h"
#include "llvm/Support/GetElementPtrTypeIterator.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/Support/MathExtras.h"
#include <algorithm>
#include <iostream>
#include <list>
#include <utility>
Include dependency graph for llvmAsmParser.cpp:
Go to the source code of this file.
Namespaces | |
namespace | llvm |
Classes | |
struct | PerModuleInfo |
struct | PerFunctionInfo |
union | YYSTYPE |
union | yyalloc |
Defines | |
#define | YYBISON 1 |
#define | YYBISON_VERSION "2.3" |
#define | YYSKELETON_NAME "yacc.c" |
#define | YYPURE 0 |
#define | YYLSP_NEEDED 0 |
#define | yyparse llvmAsmparse |
#define | yylex llvmAsmlex |
#define | yyerror llvmAsmerror |
#define | yylval llvmAsmlval |
#define | yychar llvmAsmchar |
#define | yydebug llvmAsmdebug |
#define | yynerrs llvmAsmnerrs |
#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 | ASM_TOK 313 |
#define | MODULE 314 |
#define | SIDEEFFECT 315 |
#define | CC_TOK 316 |
#define | CCC_TOK 317 |
#define | FASTCC_TOK 318 |
#define | COLDCC_TOK 319 |
#define | RET 320 |
#define | BR 321 |
#define | SWITCH 322 |
#define | INVOKE 323 |
#define | UNWIND 324 |
#define | UNREACHABLE 325 |
#define | ADD 326 |
#define | SUB 327 |
#define | MUL 328 |
#define | DIV 329 |
#define | REM 330 |
#define | AND 331 |
#define | OR 332 |
#define | XOR 333 |
#define | SETLE 334 |
#define | SETGE 335 |
#define | SETLT 336 |
#define | SETGT 337 |
#define | SETEQ 338 |
#define | SETNE 339 |
#define | MALLOC 340 |
#define | ALLOCA 341 |
#define | FREE 342 |
#define | LOAD 343 |
#define | STORE 344 |
#define | GETELEMENTPTR 345 |
#define | PHI_TOK 346 |
#define | CAST 347 |
#define | SELECT 348 |
#define | SHL 349 |
#define | SHR 350 |
#define | VAARG 351 |
#define | EXTRACTELEMENT 352 |
#define | INSERTELEMENT 353 |
#define | SHUFFLEVECTOR 354 |
#define | VAARG_old 355 |
#define | VANEXT_old 356 |
#define | UR_OUT(X) |
#define | YYERROR_VERBOSE 1 |
#define | YYDEBUG 0 |
#define | YYERROR_VERBOSE 1 |
#define | YYTOKEN_TABLE 0 |
#define | yystype YYSTYPE |
#define | YYSTYPE_IS_DECLARED 1 |
#define | YYSTYPE_IS_TRIVIAL 1 |
#define | YYSIZE_T unsigned int |
#define | YYSIZE_MAXIMUM ((YYSIZE_T) -1) |
#define | YY_(msgid) msgid |
#define | YYUSE(e) ((void) (e)) |
#define | YYID(n) (n) |
#define | YYSTACK_ALLOC YYMALLOC |
#define | YYSTACK_FREE YYFREE |
#define | YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
#define | YYMALLOC malloc |
#define | YYFREE free |
#define | YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) |
#define | YYSTACK_BYTES(N) |
#define | YYCOPY(To, From, Count) |
#define | YYSTACK_RELOCATE(Stack) |
#define | YYFINAL 4 |
#define | YYLAST 1314 |
#define | YYNTOKENS 116 |
#define | YYNNTS 72 |
#define | YYNRULES 238 |
#define | YYNSTATES 495 |
#define | YYUNDEFTOK 2 |
#define | YYMAXUTOK 356 |
#define | YYTRANSLATE(YYX) ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) |
#define | YYPACT_NINF -441 |
#define | YYTABLE_NINF -122 |
#define | yyerrok (yyerrstatus = 0) |
#define | yyclearin (yychar = YYEMPTY) |
#define | YYEMPTY (-2) |
#define | YYEOF 0 |
#define | YYACCEPT goto yyacceptlab |
#define | YYABORT goto yyabortlab |
#define | YYERROR goto yyerrorlab |
#define | YYFAIL goto yyerrlab |
#define | YYRECOVERING() (!!yyerrstatus) |
#define | YYBACKUP(Token, Value) |
#define | YYTERROR 1 |
#define | YYERRCODE 256 |
#define | YYRHSLOC(Rhs, K) ((Rhs)[K]) |
#define | YYLLOC_DEFAULT(Current, Rhs, N) |
#define | YY_LOCATION_PRINT(File, Loc) ((void) 0) |
#define | YYLEX yylex () |
#define | YYDPRINTF(Args) |
#define | YY_SYMBOL_PRINT(Title, Type, Value, Location) |
#define | YY_STACK_PRINT(Bottom, Top) |
#define | YY_REDUCE_PRINT(Rule) |
#define | YYINITDEPTH 200 |
#define | YYMAXDEPTH 10000 |
#define | YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) |
Typedefs | |
typedef std::vector< Value * > | ValueList |
typedef unsigned char | yytype_uint8 |
typedef short int | yytype_int8 |
typedef unsigned short int | yytype_uint16 |
typedef short int | yytype_int16 |
Enumerations | |
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, ASM_TOK = 313, MODULE = 314, SIDEEFFECT = 315, CC_TOK = 316, CCC_TOK = 317, FASTCC_TOK = 318, COLDCC_TOK = 319, RET = 320, BR = 321, SWITCH = 322, INVOKE = 323, UNWIND = 324, UNREACHABLE = 325, ADD = 326, SUB = 327, MUL = 328, DIV = 329, REM = 330, AND = 331, OR = 332, XOR = 333, SETLE = 334, SETGE = 335, SETLT = 336, SETGT = 337, SETEQ = 338, SETNE = 339, MALLOC = 340, ALLOCA = 341, FREE = 342, LOAD = 343, STORE = 344, GETELEMENTPTR = 345, PHI_TOK = 346, CAST = 347, SELECT = 348, SHL = 349, SHR = 350, VAARG = 351, EXTRACTELEMENT = 352, INSERTELEMENT = 353, SHUFFLEVECTOR = 354, VAARG_old = 355, VANEXT_old = 356 } |
Functions | |
int | yyerror (const char *ErrorMsg) |
int | yylex () |
int | yyparse () |
static void | ResolveDefinitions (std::map< const Type *, ValueList > &LateResolvers, std::map< const Type *, ValueList > *FutureLateResolvers=0) |
static bool | inFunctionScope () |
static int | InsertValue (Value *V, std::map< const Type *, ValueList > &ValueTab=CurFun.Values) |
static const Type * | getTypeVal (const ValID &D, bool DoNotImprovise=false) |
static Value * | lookupInSymbolTable (const Type *Ty, const std::string &Name) |
static Value * | getValNonImprovising (const Type *Ty, const ValID &D) |
static Value * | getVal (const Type *Ty, const ValID &ID) |
static BasicBlock * | getBBVal (const ValID &ID, bool isDefinition=false) |
static void | ResolveTypeTo (char *Name, const Type *ToTy) |
static void | setValueName (Value *V, char *NameStr) |
static GlobalVariable * | ParseGlobalVariable (char *NameStr, GlobalValue::LinkageTypes Linkage, bool isConstantGlobal, const Type *Ty, Constant *Initializer) |
static bool | setTypeName (const Type *T, char *NameStr) |
static bool | TypeContains (const Type *Ty, const Type *E) |
static PATypeHolder | HandleUpRefs (const Type *ty) |
static Module * | RunParser (Module *M) |
Module * | llvm::RunVMAsmParser (const std::string &Filename, FILE *F) |
Module * | llvm::RunVMAsmParser (const char *AsmString, Module *M) |
static YYSIZE_T | yystrlen (yystr) const char *yystr |
Variables | |
std::string | llvm::CurFilename |
static Module * | ParserResult |
static bool | ObsoleteVarArgs |
static bool | NewVarArgs |
static BasicBlock * | CurBB |
static GlobalVariable * | CurGV |
static struct PerModuleInfo | CurModule |
static struct PerFunctionInfo | CurFun |
unsigned | NestingLevel |
const Type * | LastContainedTy |
OpaqueType * | UpRefTy |
static std::vector< UpRefRecord > | UpRefs |
static const yytype_uint8 | yytranslate [] |
static const char *const | yytname [] |
static const yytype_uint8 | yyr1 [] |
static const yytype_uint8 | yyr2 [] |
static const yytype_uint8 | yydefact [] |
static const yytype_int16 | yydefgoto [] |
static const yytype_int16 | yypact [] |
static const yytype_int16 | yypgoto [] |
static const yytype_int16 | yytable [] |
static const yytype_int16 | yycheck [] |
static const yytype_uint8 | yystos [] |
const char * | yysrc |
int | yytype |
YYSTYPE * | yyvaluep |
int | yychar |
YYSTYPE | yylval |
int | yynerrs |
#define ADD 326 |
Definition at line 247 of file llvmAsmParser.cpp.
Referenced by BuildSDIVSequence(), BuildUDIVSequence(), llvm::IA64RegisterInfo::eliminateFrameIndex(), llvm::IA64RegisterInfo::emitEpilogue(), llvm::IA64RegisterInfo::emitPrologue(), getScalarizedOpcode(), and isCommutativeBinOp().
#define ALIGN 309 |
Definition at line 230 of file llvmAsmParser.cpp.
#define ALLOCA 341 |
Definition at line 262 of file llvmAsmParser.cpp.
#define AND 331 |
Definition at line 252 of file llvmAsmParser.cpp.
Referenced by getScalarizedOpcode(), and isCommutativeBinOp().
#define APPENDING 299 |
Definition at line 220 of file llvmAsmParser.cpp.
#define ASM_TOK 313 |
Definition at line 234 of file llvmAsmParser.cpp.
#define BEGINTOK 284 |
Definition at line 205 of file llvmAsmParser.cpp.
#define BIG 308 |
Definition at line 229 of file llvmAsmParser.cpp.
#define BOOL 264 |
Definition at line 185 of file llvmAsmParser.cpp.
#define BR 321 |
Definition at line 242 of file llvmAsmParser.cpp.
#define CALL 311 |
Definition at line 232 of file llvmAsmParser.cpp.
#define CAST 347 |
Definition at line 268 of file llvmAsmParser.cpp.
#define CC_TOK 316 |
Definition at line 237 of file llvmAsmParser.cpp.
#define CCC_TOK 317 |
Definition at line 238 of file llvmAsmParser.cpp.
#define COLDCC_TOK 319 |
Definition at line 240 of file llvmAsmParser.cpp.
#define CONST 295 |
Definition at line 216 of file llvmAsmParser.cpp.
#define CONSTANT 288 |
Definition at line 209 of file llvmAsmParser.cpp.
#define DECLARE 286 |
Definition at line 207 of file llvmAsmParser.cpp.
#define DEPLIBS 310 |
Definition at line 231 of file llvmAsmParser.cpp.
#define DIV 329 |
Definition at line 250 of file llvmAsmParser.cpp.
#define DOTDOTDOT 292 |
Definition at line 213 of file llvmAsmParser.cpp.
#define DOUBLE 274 |
Definition at line 195 of file llvmAsmParser.cpp.
#define ENDIAN 305 |
Definition at line 226 of file llvmAsmParser.cpp.
#define ENDTOK 285 |
Definition at line 206 of file llvmAsmParser.cpp.
#define ESINT64VAL 258 |
Definition at line 179 of file llvmAsmParser.cpp.
#define EUINT64VAL 259 |
Definition at line 180 of file llvmAsmParser.cpp.
#define EXTERNAL 302 |
Definition at line 223 of file llvmAsmParser.cpp.
#define EXTRACTELEMENT 352 |
Definition at line 273 of file llvmAsmParser.cpp.
#define FALSETOK 283 |
Definition at line 204 of file llvmAsmParser.cpp.
#define FASTCC_TOK 318 |
Definition at line 239 of file llvmAsmParser.cpp.
#define FLOAT 273 |
Definition at line 194 of file llvmAsmParser.cpp.
#define FPVAL 262 |
Definition at line 183 of file llvmAsmParser.cpp.
#define FREE 342 |
Definition at line 263 of file llvmAsmParser.cpp.
#define GETELEMENTPTR 345 |
Definition at line 266 of file llvmAsmParser.cpp.
#define GLOBAL 287 |
Definition at line 208 of file llvmAsmParser.cpp.
#define IMPLEMENTATION 280 |
Definition at line 201 of file llvmAsmParser.cpp.
#define INSERTELEMENT 353 |
Definition at line 274 of file llvmAsmParser.cpp.
#define INT 269 |
Definition at line 190 of file llvmAsmParser.cpp.
#define INTERNAL 296 |
Definition at line 217 of file llvmAsmParser.cpp.
#define INVOKE 323 |
Definition at line 244 of file llvmAsmParser.cpp.
#define LABEL 276 |
Definition at line 197 of file llvmAsmParser.cpp.
#define LABELSTR 278 |
Definition at line 199 of file llvmAsmParser.cpp.
#define LINKONCE 297 |
Definition at line 218 of file llvmAsmParser.cpp.
#define LITTLE 307 |
Definition at line 228 of file llvmAsmParser.cpp.
#define LOAD 343 |
Definition at line 264 of file llvmAsmParser.cpp.
#define LONG 271 |
Definition at line 192 of file llvmAsmParser.cpp.
#define MALLOC 340 |
Definition at line 261 of file llvmAsmParser.cpp.
#define MODULE 314 |
Definition at line 235 of file llvmAsmParser.cpp.
#define MUL 328 |
Definition at line 249 of file llvmAsmParser.cpp.
Referenced by getScalarizedOpcode(), and isCommutativeBinOp().
#define NOT 301 |
Definition at line 222 of file llvmAsmParser.cpp.
#define NULL_TOK 293 |
Definition at line 214 of file llvmAsmParser.cpp.
#define OPAQUE 300 |
Definition at line 221 of file llvmAsmParser.cpp.
#define OR 332 |
Definition at line 253 of file llvmAsmParser.cpp.
Referenced by getScalarizedOpcode(), and isCommutativeBinOp().
#define PHI_TOK 346 |
Definition at line 267 of file llvmAsmParser.cpp.
#define POINTERSIZE 306 |
Definition at line 227 of file llvmAsmParser.cpp.
#define REM 330 |
Definition at line 251 of file llvmAsmParser.cpp.
#define RET 320 |
Definition at line 241 of file llvmAsmParser.cpp.
Referenced by llvm::X86RegisterInfo::emitEpilogue(), and llvm::IA64RegisterInfo::emitEpilogue().
#define SBYTE 265 |
Definition at line 186 of file llvmAsmParser.cpp.
#define SECTION 289 |
Definition at line 210 of file llvmAsmParser.cpp.
#define SELECT 348 |
Definition at line 269 of file llvmAsmParser.cpp.
#define SETEQ 338 |
Definition at line 259 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), and IntCondCCodeToICC().
#define SETGE 335 |
Definition at line 256 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), and IntCondCCodeToICC().
#define SETGT 337 |
Definition at line 258 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), and IntCondCCodeToICC().
#define SETLE 334 |
Definition at line 255 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), and IntCondCCodeToICC().
#define SETLT 336 |
Definition at line 257 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), and IntCondCCodeToICC().
#define SETNE 339 |
Definition at line 260 of file llvmAsmParser.cpp.
Referenced by FPCondCCodeToFCC(), getBCCForSetCC(), getCRIdxForSetCC(), IntCondCCodeToICC(), and LookThroughSetCC().
#define SHL 349 |
#define SHORT 267 |
Definition at line 188 of file llvmAsmParser.cpp.
#define SHR 350 |
Definition at line 271 of file llvmAsmParser.cpp.
#define SHUFFLEVECTOR 354 |
Definition at line 275 of file llvmAsmParser.cpp.
#define SIDEEFFECT 315 |
Definition at line 236 of file llvmAsmParser.cpp.
#define SINTVAL 260 |
Definition at line 181 of file llvmAsmParser.cpp.
#define STORE 344 |
Definition at line 265 of file llvmAsmParser.cpp.
#define STRINGCONSTANT 279 |
Definition at line 200 of file llvmAsmParser.cpp.
#define SUB 327 |
Definition at line 248 of file llvmAsmParser.cpp.
Referenced by BuildSDIVSequence(), BuildUDIVSequence(), and getScalarizedOpcode().
#define SWITCH 322 |
Definition at line 243 of file llvmAsmParser.cpp.
#define TAIL 312 |
Definition at line 233 of file llvmAsmParser.cpp.
#define TARGET 303 |
Definition at line 224 of file llvmAsmParser.cpp.
#define TO 291 |
Definition at line 212 of file llvmAsmParser.cpp.
#define TRIPLE 304 |
Definition at line 225 of file llvmAsmParser.cpp.
#define TRUETOK 282 |
Definition at line 203 of file llvmAsmParser.cpp.
#define TYPE 275 |
Definition at line 196 of file llvmAsmParser.cpp.
#define UBYTE 266 |
Definition at line 187 of file llvmAsmParser.cpp.
#define UINT 270 |
Definition at line 191 of file llvmAsmParser.cpp.
#define UINTVAL 261 |
Definition at line 182 of file llvmAsmParser.cpp.
#define ULONG 272 |
Definition at line 193 of file llvmAsmParser.cpp.
#define UNDEF 294 |
Definition at line 215 of file llvmAsmParser.cpp.
#define UNREACHABLE 325 |
Definition at line 246 of file llvmAsmParser.cpp.
#define UNWIND 324 |
Definition at line 245 of file llvmAsmParser.cpp.
#define UR_OUT | ( | X | ) |
#define USHORT 268 |
Definition at line 189 of file llvmAsmParser.cpp.
#define VAARG 351 |
Definition at line 272 of file llvmAsmParser.cpp.
#define VAARG_old 355 |
Definition at line 276 of file llvmAsmParser.cpp.
#define VANEXT_old 356 |
Definition at line 277 of file llvmAsmParser.cpp.
#define VAR_ID 277 |
Definition at line 198 of file llvmAsmParser.cpp.
#define VOID 263 |
Definition at line 184 of file llvmAsmParser.cpp.
#define VOLATILE 290 |
Definition at line 211 of file llvmAsmParser.cpp.
#define WEAK 298 |
Definition at line 219 of file llvmAsmParser.cpp.
#define XOR 333 |
Definition at line 254 of file llvmAsmParser.cpp.
Referenced by getScalarizedOpcode(), and isCommutativeBinOp().
#define YY_ | ( | msgid | ) | msgid |
Definition at line 1291 of file llvmAsmParser.cpp.
#define YY_LOCATION_PRINT | ( | File, | |||
Loc | ) | ((void) 0) |
Definition at line 2320 of file llvmAsmParser.cpp.
#define YY_REDUCE_PRINT | ( | Rule | ) |
Definition at line 2490 of file llvmAsmParser.cpp.
#define YY_STACK_PRINT | ( | Bottom, | |||
Top | ) |
Definition at line 2489 of file llvmAsmParser.cpp.
Definition at line 2488 of file llvmAsmParser.cpp.
#define YYABORT goto yyabortlab |
Definition at line 2249 of file llvmAsmParser.cpp.
#define YYACCEPT goto yyacceptlab |
Definition at line 2248 of file llvmAsmParser.cpp.
#define YYBACKUP | ( | Token, | |||
Value | ) |
Value:
do \ if (yychar == YYEMPTY && yylen == 1) \ { \ yychar = (Token); \ yylval = (Value); \ yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ else \ { \ yyerror (YY_("syntax error: cannot back up")); \ YYERROR; \ } \ while (YYID (0))
Definition at line 2261 of file llvmAsmParser.cpp.
#define YYBISON 1 |
Definition at line 47 of file llvmAsmParser.cpp.
#define YYBISON_VERSION "2.3" |
Definition at line 50 of file llvmAsmParser.cpp.
#define yychar llvmAsmchar |
Definition at line 66 of file llvmAsmParser.cpp.
#define yyclearin (yychar = YYEMPTY) |
Definition at line 2244 of file llvmAsmParser.cpp.
#define YYCOPY | ( | To, | |||
From, | |||||
Count | ) |
Value:
do \ { \ YYSIZE_T yyi; \ for (yyi = 0; yyi < (Count); yyi++) \ (To)[yyi] = (From)[yyi]; \ } \ while (YYID (0))
Definition at line 1417 of file llvmAsmParser.cpp.
#define YYDEBUG 0 |
Definition at line 1162 of file llvmAsmParser.cpp.
#define yydebug llvmAsmdebug |
Definition at line 67 of file llvmAsmParser.cpp.
#define YYDPRINTF | ( | Args | ) |
Definition at line 2487 of file llvmAsmParser.cpp.
#define YYEMPTY (-2) |
#define YYEOF 0 |
Definition at line 2246 of file llvmAsmParser.cpp.
#define YYERRCODE 256 |
Definition at line 2280 of file llvmAsmParser.cpp.
#define yyerrok (yyerrstatus = 0) |
Definition at line 2243 of file llvmAsmParser.cpp.
#define YYERROR goto yyerrorlab |
Definition at line 2250 of file llvmAsmParser.cpp.
#define yyerror llvmAsmerror |
Definition at line 64 of file llvmAsmParser.cpp.
#define YYERROR_VERBOSE 1 |
Definition at line 1168 of file llvmAsmParser.cpp.
#define YYERROR_VERBOSE 1 |
Definition at line 1168 of file llvmAsmParser.cpp.
#define YYFAIL goto yyerrlab |
Definition at line 2257 of file llvmAsmParser.cpp.
#define YYFINAL 4 |
Definition at line 1447 of file llvmAsmParser.cpp.
#define YYFREE free |
Definition at line 1380 of file llvmAsmParser.cpp.
#define YYID | ( | n | ) | (n) |
Definition at line 1304 of file llvmAsmParser.cpp.
#define YYINITDEPTH 200 |
Definition at line 2496 of file llvmAsmParser.cpp.
#define YYLAST 1314 |
Definition at line 1449 of file llvmAsmParser.cpp.
#define YYLEX yylex () |
Definition at line 2330 of file llvmAsmParser.cpp.
#define yylex llvmAsmlex |
Definition at line 63 of file llvmAsmParser.cpp.
#define YYLLOC_DEFAULT | ( | Current, | |||
Rhs, | |||||
N | ) |
Value:
do \ if (YYID (N)) \ { \ (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ } \ else \ { \ (Current).first_line = (Current).last_line = \ YYRHSLOC (Rhs, 0).last_line; \ (Current).first_column = (Current).last_column = \ YYRHSLOC (Rhs, 0).last_column; \ } \ while (YYID (0))
Definition at line 2289 of file llvmAsmParser.cpp.
#define YYLSP_NEEDED 0 |
Definition at line 59 of file llvmAsmParser.cpp.
#define yylval llvmAsmlval |
Definition at line 65 of file llvmAsmParser.cpp.
#define YYMALLOC malloc |
Definition at line 1373 of file llvmAsmParser.cpp.
#define YYMAXDEPTH 10000 |
Definition at line 2507 of file llvmAsmParser.cpp.
#define YYMAXUTOK 356 |
Definition at line 1462 of file llvmAsmParser.cpp.
#define yynerrs llvmAsmnerrs |
Definition at line 68 of file llvmAsmParser.cpp.
#define YYNNTS 72 |
Definition at line 1454 of file llvmAsmParser.cpp.
#define YYNRULES 238 |
Definition at line 1456 of file llvmAsmParser.cpp.
#define YYNSTATES 495 |
Definition at line 1458 of file llvmAsmParser.cpp.
#define YYNTOKENS 116 |
Definition at line 1452 of file llvmAsmParser.cpp.
#define YYPACT_NINF -441 |
Definition at line 1842 of file llvmAsmParser.cpp.
int yyparse llvmAsmparse |
#define YYPOPSTACK | ( | N | ) | (yyvsp -= (N), yyssp -= (N)) |
#define YYPURE 0 |
Definition at line 56 of file llvmAsmParser.cpp.
#define YYRECOVERING | ( | ) | (!!yyerrstatus) |
Definition at line 2259 of file llvmAsmParser.cpp.
#define YYRHSLOC | ( | Rhs, | |||
K | ) | ((Rhs)[K]) |
Definition at line 2287 of file llvmAsmParser.cpp.
#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) |
Definition at line 1281 of file llvmAsmParser.cpp.
#define YYSIZE_T unsigned int |
Definition at line 1277 of file llvmAsmParser.cpp.
#define YYSKELETON_NAME "yacc.c" |
Definition at line 53 of file llvmAsmParser.cpp.
#define YYSTACK_ALLOC YYMALLOC |
Definition at line 1359 of file llvmAsmParser.cpp.
#define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
Definition at line 1362 of file llvmAsmParser.cpp.
#define YYSTACK_BYTES | ( | N | ) |
Value:
((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM)
Definition at line 1406 of file llvmAsmParser.cpp.
#define YYSTACK_FREE YYFREE |
Definition at line 1360 of file llvmAsmParser.cpp.
#define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) |
Definition at line 1402 of file llvmAsmParser.cpp.
#define YYSTACK_RELOCATE | ( | Stack | ) |
Value:
do \ { \ YYSIZE_T yynewbytes; \ YYCOPY (&yyptr->Stack, Stack, yysize); \ Stack = &yyptr->Stack; \ yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ yyptr += yynewbytes / sizeof (*yyptr); \ } \ while (YYID (0))
Definition at line 1433 of file llvmAsmParser.cpp.
#define yystype YYSTYPE |
Definition at line 1223 of file llvmAsmParser.cpp.
#define YYSTYPE_IS_DECLARED 1 |
Definition at line 1224 of file llvmAsmParser.cpp.
#define YYSTYPE_IS_TRIVIAL 1 |
Definition at line 1225 of file llvmAsmParser.cpp.
#define YYTABLE_NINF -122 |
Definition at line 1914 of file llvmAsmParser.cpp.
#define YYTERROR 1 |
Definition at line 2279 of file llvmAsmParser.cpp.
#define YYTOKEN_TABLE 0 |
Definition at line 1175 of file llvmAsmParser.cpp.
#define YYTRANSLATE | ( | YYX | ) | ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) |
Definition at line 1464 of file llvmAsmParser.cpp.
#define YYUNDEFTOK 2 |
Definition at line 1461 of file llvmAsmParser.cpp.
#define YYUSE | ( | e | ) | ((void) (e)) |
Definition at line 1297 of file llvmAsmParser.cpp.
#define ZEROINITIALIZER 281 |
Definition at line 202 of file llvmAsmParser.cpp.
Definition at line 332 of file llvmAsmParser.cpp.
typedef short int yytype_int16 |
Definition at line 1264 of file llvmAsmParser.cpp.
typedef short int yytype_int8 |
Definition at line 1252 of file llvmAsmParser.cpp.
typedef unsigned short int yytype_uint16 |
Definition at line 1258 of file llvmAsmParser.cpp.
typedef unsigned char yytype_uint8 |
Definition at line 1243 of file llvmAsmParser.cpp.
enum yytokentype |
Definition at line 76 of file llvmAsmParser.cpp.
static BasicBlock* getBBVal | ( | const ValID & | ID, | |
bool | isDefinition = false | |||
) | [static] |
getBBVal - This is used for two purposes: If isDefinition is true, a new basic block with the specified ID is being defined. If isDefinition is true, this is a reference to a basic block, which may or may not be a forward reference.
Definition at line 651 of file llvmAsmParser.cpp.
References llvm::ISD::BasicBlock, BB, PerFunctionInfo::BBForwardRefs, CurFun, PerFunctionInfo::CurrentFunction, llvm::Function::getBasicBlockList(), inFunctionScope(), llvmAsmlineno, Name, PerFunctionInfo::NumberedBlocks, llvm::Value::setName(), and llvm::ThrowException().
Definition at line 462 of file llvmAsmParser.cpp.
References CurModule, PerModuleInfo::CurrentModule, D, llvm::Module::getTypeByName(), I, inFunctionScope(), llvm::itostr(), PerModuleInfo::LateResolveTypes, llvm::ThrowException(), and PerModuleInfo::Types.
Definition at line 616 of file llvmAsmParser.cpp.
References CurFun, CurModule, getValNonImprovising(), inFunctionScope(), InsertValue(), llvm::Type::isFirstClassType(), PerModuleInfo::LateResolveValues, PerFunctionInfo::LateResolveValues, llvmAsmlineno, PerModuleInfo::PlaceHolderInfo, llvm::ThrowException(), Ty, and V.
Referenced by EvaluateFunction().
Definition at line 513 of file llvmAsmParser.cpp.
References ConstantVal, CurFun, CurModule, D, llvm::SequentialType::getElementType(), llvm::itostr(), lookupInSymbolTable(), second, llvm::ThrowException(), Ty, llvm::utostr(), PerFunctionInfo::Values, and PerModuleInfo::Values.
Referenced by getVal(), and ResolveDefinitions().
static PATypeHolder HandleUpRefs | ( | const Type * | ty | ) | [static] |
HandleUpRefs - Every time we finish a new layer of types, this function is called. It loops through the UpRefs vector, which is a list of the currently active types. For each type, if the up reference is contained in the newly completed type, we decrement the level count. When the level count reaches zero, the upreferenced type is the type that is passed in: thus we can complete the cycle.
Definition at line 971 of file llvmAsmParser.cpp.
References llvm::Type::getDescription(), llvm::Type::isAbstract(), LastContainedTy, NestingLevel, second, Ty, TypeContains(), UpRefs, and UR_OUT.
static bool inFunctionScope | ( | ) | [static] |
Definition at line 445 of file llvmAsmParser.cpp.
References CurFun, and PerFunctionInfo::CurrentFunction.
Referenced by getBBVal(), getTypeVal(), getVal(), lookupInSymbolTable(), setTypeName(), and setValueName().
static int InsertValue | ( | Value * | V, | |
std::map< const Type *, ValueList > & | ValueTab = CurFun.Values | |||
) | [static] |
Definition at line 452 of file llvmAsmParser.cpp.
References V.
Referenced by getVal(), ParseGlobalVariable(), and ResolveDefinitions().
Definition at line 502 of file llvmAsmParser.cpp.
References CurFun, CurModule, PerFunctionInfo::CurrentFunction, PerModuleInfo::CurrentModule, llvm::Module::getSymbolTable(), llvm::Function::getSymbolTable(), inFunctionScope(), llvm::SymbolTable::lookup(), and Ty.
Referenced by getValNonImprovising().
static GlobalVariable* ParseGlobalVariable | ( | char * | NameStr, | |
GlobalValue::LinkageTypes | Linkage, | |||
bool | isConstantGlobal, | |||
const Type * | Ty, | |||
Constant * | Initializer | |||
) | [static] |
ParseGlobalVariable - Handle parsing of a global. If Initializer is null, this is a declaration, otherwise it is a definition.
Definition at line 810 of file llvmAsmParser.cpp.
References CurModule, PerModuleInfo::CurrentModule, PerModuleInfo::GetForwardRefForGlobal(), llvm::Module::getGlobalList(), llvm::Module::getGlobalVariable(), GV, InsertValue(), Name, llvm::GlobalValue::setLinkage(), llvm::ThrowException(), Ty, and PerModuleInfo::Values.
static void ResolveDefinitions | ( | std::map< const Type *, ValueList > & | LateResolvers, | |
std::map< const Type *, ValueList > * | FutureLateResolvers = 0 | |||
) | [static] |
Definition at line 725 of file llvmAsmParser.cpp.
References CurModule, E, getValNonImprovising(), InsertValue(), llvm::itostr(), llvm::PHI, PerModuleInfo::PlaceHolderInfo, llvm::ThrowException(), and V.
Referenced by PerFunctionInfo::FunctionDone(), and PerModuleInfo::ModuleDone().
static void ResolveTypeTo | ( | char * | Name, | |
const Type * | ToTy | |||
) | [static] |
Definition at line 771 of file llvmAsmParser.cpp.
References CurModule, D, I, PerModuleInfo::LateResolveTypes, and PerModuleInfo::Types.
Definition at line 1022 of file llvmAsmParser.cpp.
References CurModule, PerModuleInfo::CurrentModule, F, llvm::Module::getFunctionList(), llvm::Module::getNamedFunction(), llvm::Module::getOrInsertFunction(), llvmAsmlineno, M, NewVarArgs, ObsoleteVarArgs, ParserResult, RetTy, llvm::ThrowException(), and yyparse.
Referenced by llvm::RunVMAsmParser().
static bool setTypeName | ( | const Type * | T, | |
char * | NameStr | |||
) | [static] |
Definition at line 891 of file llvmAsmParser.cpp.
References llvm::Module::addTypeName(), CurModule, PerModuleInfo::CurrentModule, llvm::Type::getDescription(), llvm::Module::getTypeByName(), inFunctionScope(), Name, T, and llvm::ThrowException().
static void setValueName | ( | Value * | V, | |
char * | NameStr | |||
) | [static] |
Definition at line 788 of file llvmAsmParser.cpp.
References CurFun, PerFunctionInfo::CurrentFunction, llvm::Function::getSymbolTable(), inFunctionScope(), llvm::SymbolTable::lookup(), Name, llvm::ThrowException(), and V.
Definition at line 937 of file llvmAsmParser.cpp.
References E, llvm::Type::subtype_begin(), llvm::Type::subtype_end(), and Ty.
Referenced by HandleUpRefs().
int yyerror | ( | const char * | ErrorMsg | ) |
Definition at line 5249 of file llvmAsmParser.cpp.
References llvm::CurFilename, llvmAsmleng, llvmAsmlineno, llvmAsmtext, llvm::ThrowException(), llvm::utostr(), and YYEMPTY.
int yylex | ( | ) |
int yyparse | ( | ) |
static YYSIZE_T yystrlen | ( | yystr | ) | const [static] |
BasicBlock* CurBB [static] |
Definition at line 325 of file llvmAsmParser.cpp.
struct PerFunctionInfo CurFun [static] |
Referenced by getBBVal(), getVal(), getValNonImprovising(), inFunctionScope(), lookupInSymbolTable(), and setValueName().
GlobalVariable* CurGV [static] |
Definition at line 326 of file llvmAsmParser.cpp.
struct PerModuleInfo CurModule [static] |
const Type* LastContainedTy |
unsigned NestingLevel |
bool NewVarArgs [static] |
bool ObsoleteVarArgs [static] |
Module* ParserResult [static] |
std::vector<UpRefRecord> UpRefs [static] |
Definition at line 954 of file llvmAsmParser.cpp.
int yychar |
Definition at line 2767 of file llvmAsmParser.cpp.
const yytype_int16 yycheck[] [static] |
Definition at line 2051 of file llvmAsmParser.cpp.
const yytype_uint8 yydefact[] [static] |
Definition at line 1773 of file llvmAsmParser.cpp.
const yytype_int16 yydefgoto[] [static] |
Initial value:
{ -1, 75, 236, 252, 253, 254, 255, 176, 177, 206, 178, 22, 12, 31, 422, 288, 367, 386, 311, 368, 76, 77, 179, 79, 80, 105, 188, 319, 279, 320, 97, 1, 2, 3, 258, 231, 52, 160, 43, 92, 163, 81, 333, 264, 265, 266, 32, 85, 13, 38, 14, 15, 25, 338, 280, 82, 282, 395, 16, 34, 35, 152, 470, 87, 213, 426, 427, 153, 154, 347, 155, 156 }
Definition at line 1828 of file llvmAsmParser.cpp.
Definition at line 2777 of file llvmAsmParser.cpp.
int yynerrs |
Definition at line 2780 of file llvmAsmParser.cpp.
const yytype_int16 yypact[] [static] |
Definition at line 1843 of file llvmAsmParser.cpp.
const yytype_int16 yypgoto[] [static] |
Initial value:
{ -441, -441, -441, 290, 291, 293, 295, -114, -112, -440, -441, 347, 361, -93, -441, -204, 50, -441, -245, -441, -40, -441, -31, -441, -57, 280, -441, -96, 213, -231, 345, -441, -441, -441, -441, -441, 349, -441, -441, -441, -441, 8, -441, 65, -441, -441, 373, -441, -441, -441, -441, 398, -441, -441, -402, -58, 167, -106, -441, 386, -441, -441, -441, -441, -441, 57, -1, -441, -441, 46, -441, -441 }
Definition at line 1898 of file llvmAsmParser.cpp.
const yytype_uint8 yyr1[] [static] |
Initial value:
{ 0, 116, 117, 117, 118, 118, 119, 119, 119, 119, 119, 120, 120, 120, 121, 121, 121, 121, 121, 121, 122, 122, 123, 123, 123, 123, 124, 124, 124, 124, 125, 125, 126, 126, 127, 127, 128, 128, 128, 128, 128, 129, 129, 129, 129, 129, 130, 130, 131, 131, 132, 133, 133, 134, 134, 135, 135, 136, 136, 137, 137, 138, 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, 140, 140, 140, 140, 140, 140, 140, 140, 140, 140, 141, 141, 142, 142, 142, 142, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, 144, 144, 144, 144, 144, 144, 144, 144, 144, 144, 145, 145, 146, 146, 147, 148, 148, 148, 148, 148, 149, 149, 149, 150, 149, 151, 149, 149, 149, 149, 152, 153, 153, 154, 154, 154, 155, 156, 156, 156, 157, 157, 158, 158, 159, 160, 160, 161, 161, 161, 161, 162, 163, 163, 164, 165, 165, 166, 168, 167, 169, 169, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 170, 171, 171, 172, 172, 173, 174, 174, 175, 176, 176, 176, 177, 177, 177, 177, 177, 177, 177, 177, 177, 178, 178, 179, 180, 180, 181, 181, 182, 182, 183, 183, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, 185, 185, 186, 186, 187, 187, 187, 187, 187, 187, 187, 187 }
Definition at line 1713 of file llvmAsmParser.cpp.
const yytype_uint8 yyr2[] [static] |
Initial value:
{ 0, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 2, 0, 2, 0, 3, 2, 0, 1, 0, 3, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 4, 5, 5, 3, 2, 2, 1, 3, 1, 3, 1, 0, 4, 3, 3, 4, 4, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 6, 5, 8, 6, 6, 6, 6, 6, 8, 8, 3, 1, 1, 1, 1, 2, 2, 4, 2, 1, 4, 2, 4, 0, 7, 0, 7, 3, 4, 0, 1, 1, 1, 3, 3, 3, 3, 3, 1, 0, 1, 1, 1, 0, 2, 3, 1, 1, 3, 1, 0, 8, 1, 1, 3, 1, 1, 2, 0, 3, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 5, 1, 1, 1, 1, 2, 2, 2, 3, 2, 0, 1, 2, 2, 3, 9, 9, 8, 13, 1, 1, 6, 5, 2, 6, 7, 1, 3, 1, 0, 2, 1, 5, 5, 5, 2, 4, 4, 6, 4, 4, 4, 4, 6, 6, 2, 7, 1, 2, 0, 1, 0, 3, 6, 3, 6, 2, 4, 6, 4 }
Definition at line 1742 of file llvmAsmParser.cpp.
const char* yysrc |
Definition at line 2550 of file llvmAsmParser.cpp.
const yytype_uint8 yystos[] [static] |
Definition at line 2189 of file llvmAsmParser.cpp.
const yytype_int16 yytable[] [static] |
Definition at line 1915 of file llvmAsmParser.cpp.
const char* const yytname[] [static] |
Definition at line 1655 of file llvmAsmParser.cpp.
const yytype_uint8 yytranslate[] [static] |
Definition at line 1468 of file llvmAsmParser.cpp.
int yytype |
Definition at line 2735 of file llvmAsmParser.cpp.
Definition at line 2737 of file llvmAsmParser.cpp.