blob: b4c0ee7c99bea8288953b608bfa3ec74edde6250 [file] [log] [blame]
Chris Lattner2f7c9632001-06-06 20:29:01 +00001typedef union {
2 Module *ModuleVal;
3 Method *MethodVal;
4 MethodArgument *MethArgVal;
5 BasicBlock *BasicBlockVal;
6 TerminatorInst *TermInstVal;
7 Instruction *InstVal;
8 ConstPoolVal *ConstVal;
9 const Type *TypeVal;
10
11 list<MethodArgument*> *MethodArgList;
12 list<Value*> *ValueList;
13 list<const Type*> *TypeList;
Chris Lattner931ef3b2001-06-11 15:04:20 +000014 list<pair<Value*, BasicBlock*> > *PHIList; // Represent the RHS of PHI node
Chris Lattner2f7c9632001-06-06 20:29:01 +000015 list<pair<ConstPoolVal*, BasicBlock*> > *JumpTable;
16 vector<ConstPoolVal*> *ConstVector;
17
18 int64_t SInt64Val;
19 uint64_t UInt64Val;
20 int SIntVal;
21 unsigned UIntVal;
22
23 char *StrVal; // This memory is allocated by strdup!
24 ValID ValIDVal; // May contain memory allocated by strdup
25
26 Instruction::UnaryOps UnaryOpVal;
27 Instruction::BinaryOps BinaryOpVal;
28 Instruction::TermOps TermOpVal;
29 Instruction::MemoryOps MemOpVal;
Chris Lattnerd8bebcd2001-07-08 21:10:27 +000030 Instruction::OtherOps OtherOpVal;
Chris Lattner2f7c9632001-06-06 20:29:01 +000031} YYSTYPE;
32#define ESINT64VAL 257
33#define EUINT64VAL 258
34#define SINTVAL 259
35#define UINTVAL 260
36#define VOID 261
37#define BOOL 262
38#define SBYTE 263
39#define UBYTE 264
40#define SHORT 265
41#define USHORT 266
42#define INT 267
43#define UINT 268
44#define LONG 269
45#define ULONG 270
46#define FLOAT 271
47#define DOUBLE 272
48#define STRING 273
49#define TYPE 274
50#define LABEL 275
51#define VAR_ID 276
52#define LABELSTR 277
53#define STRINGCONSTANT 278
54#define IMPLEMENTATION 279
55#define TRUE 280
56#define FALSE 281
57#define BEGINTOK 282
58#define END 283
59#define DECLARE 284
Chris Lattnera6821822001-07-08 04:57:15 +000060#define TO 285
Chris Lattnerd8bebcd2001-07-08 21:10:27 +000061#define RET 286
62#define BR 287
63#define SWITCH 288
64#define NOT 289
65#define ADD 290
66#define SUB 291
67#define MUL 292
68#define DIV 293
69#define REM 294
70#define SETLE 295
71#define SETGE 296
72#define SETLT 297
73#define SETGT 298
74#define SETEQ 299
75#define SETNE 300
76#define MALLOC 301
77#define ALLOCA 302
78#define FREE 303
79#define LOAD 304
80#define STORE 305
Chris Lattner62ecb4a2001-07-08 23:22:50 +000081#define GETELEMENTPTR 306
82#define PHI 307
83#define CALL 308
84#define CAST 309
85#define SHL 310
86#define SHR 311
Chris Lattner2f7c9632001-06-06 20:29:01 +000087
88
89extern YYSTYPE llvmAsmlval;