2006-10-22 06:08:13 +00:00
|
|
|
typedef union {
|
2005-08-27 18:50:39 +00:00
|
|
|
llvm::Module *ModuleVal;
|
|
|
|
llvm::Function *FunctionVal;
|
|
|
|
std::pair<llvm::PATypeHolder*, char*> *ArgVal;
|
|
|
|
llvm::BasicBlock *BasicBlockVal;
|
|
|
|
llvm::TerminatorInst *TermInstVal;
|
|
|
|
llvm::Instruction *InstVal;
|
|
|
|
llvm::Constant *ConstVal;
|
|
|
|
|
|
|
|
const llvm::Type *PrimType;
|
|
|
|
llvm::PATypeHolder *TypeVal;
|
|
|
|
llvm::Value *ValueVal;
|
|
|
|
|
|
|
|
std::vector<std::pair<llvm::PATypeHolder*,char*> > *ArgList;
|
|
|
|
std::vector<llvm::Value*> *ValueList;
|
|
|
|
std::list<llvm::PATypeHolder> *TypeList;
|
|
|
|
// Represent the RHS of PHI node
|
|
|
|
std::list<std::pair<llvm::Value*,
|
|
|
|
llvm::BasicBlock*> > *PHIList;
|
|
|
|
std::vector<std::pair<llvm::Constant*, llvm::BasicBlock*> > *JumpTable;
|
|
|
|
std::vector<llvm::Constant*> *ConstVector;
|
|
|
|
|
|
|
|
llvm::GlobalValue::LinkageTypes Linkage;
|
|
|
|
int64_t SInt64Val;
|
|
|
|
uint64_t UInt64Val;
|
|
|
|
int SIntVal;
|
|
|
|
unsigned UIntVal;
|
|
|
|
double FPVal;
|
|
|
|
bool BoolVal;
|
|
|
|
|
|
|
|
char *StrVal; // This memory is strdup'd!
|
|
|
|
llvm::ValID ValIDVal; // strdup'd memory maybe!
|
|
|
|
|
|
|
|
llvm::Instruction::BinaryOps BinaryOpVal;
|
|
|
|
llvm::Instruction::TermOps TermOpVal;
|
|
|
|
llvm::Instruction::MemoryOps MemOpVal;
|
|
|
|
llvm::Instruction::OtherOps OtherOpVal;
|
|
|
|
llvm::Module::Endianness Endianness;
|
2006-09-28 19:28:24 +00:00
|
|
|
} YYSTYPE;
|
2006-10-22 06:08:13 +00:00
|
|
|
#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 DLLIMPORT 299
|
|
|
|
#define DLLEXPORT 300
|
|
|
|
#define EXTERN_WEAK 301
|
|
|
|
#define OPAQUE 302
|
|
|
|
#define NOT 303
|
|
|
|
#define EXTERNAL 304
|
|
|
|
#define TARGET 305
|
|
|
|
#define TRIPLE 306
|
|
|
|
#define ENDIAN 307
|
|
|
|
#define POINTERSIZE 308
|
|
|
|
#define LITTLE 309
|
|
|
|
#define BIG 310
|
|
|
|
#define ALIGN 311
|
|
|
|
#define DEPLIBS 312
|
|
|
|
#define CALL 313
|
|
|
|
#define TAIL 314
|
|
|
|
#define ASM_TOK 315
|
|
|
|
#define MODULE 316
|
|
|
|
#define SIDEEFFECT 317
|
|
|
|
#define CC_TOK 318
|
|
|
|
#define CCC_TOK 319
|
|
|
|
#define CSRETCC_TOK 320
|
|
|
|
#define FASTCC_TOK 321
|
|
|
|
#define COLDCC_TOK 322
|
|
|
|
#define X86_STDCALLCC_TOK 323
|
|
|
|
#define X86_FASTCALLCC_TOK 324
|
|
|
|
#define DATALAYOUT 325
|
|
|
|
#define RET 326
|
|
|
|
#define BR 327
|
|
|
|
#define SWITCH 328
|
|
|
|
#define INVOKE 329
|
|
|
|
#define UNWIND 330
|
|
|
|
#define UNREACHABLE 331
|
|
|
|
#define ADD 332
|
|
|
|
#define SUB 333
|
|
|
|
#define MUL 334
|
|
|
|
#define DIV 335
|
|
|
|
#define REM 336
|
|
|
|
#define AND 337
|
|
|
|
#define OR 338
|
|
|
|
#define XOR 339
|
|
|
|
#define SETLE 340
|
|
|
|
#define SETGE 341
|
|
|
|
#define SETLT 342
|
|
|
|
#define SETGT 343
|
|
|
|
#define SETEQ 344
|
|
|
|
#define SETNE 345
|
|
|
|
#define MALLOC 346
|
|
|
|
#define ALLOCA 347
|
|
|
|
#define FREE 348
|
|
|
|
#define LOAD 349
|
|
|
|
#define STORE 350
|
|
|
|
#define GETELEMENTPTR 351
|
|
|
|
#define PHI_TOK 352
|
|
|
|
#define CAST 353
|
|
|
|
#define SELECT 354
|
|
|
|
#define SHL 355
|
|
|
|
#define SHR 356
|
|
|
|
#define VAARG 357
|
|
|
|
#define EXTRACTELEMENT 358
|
|
|
|
#define INSERTELEMENT 359
|
|
|
|
#define SHUFFLEVECTOR 360
|
|
|
|
#define VAARG_old 361
|
|
|
|
#define VANEXT_old 362
|
2006-10-20 07:07:24 +00:00
|
|
|
|
|
|
|
|
2006-10-22 06:08:13 +00:00
|
|
|
extern YYSTYPE llvmAsmlval;
|