1 /* see copyright notice in squirrel.h */
\r
2 #ifndef _SQOPCODES_H_
\r
3 #define _SQOPCODES_H_
\r
5 #define MAX_FUNC_STACKSIZE 0xFF
\r
6 #define MAX_LITERALS 0xFFFFFFFF
\r
10 BW_OR = 2, //like ADD
\r
19 CMP_GE = 2, //like ADD
\r
27 _OP_TAILCALL= 0x02,
\r
29 _OP_PREPCALL= 0x04,
\r
30 _OP_PREPCALLK= 0x05,
\r
42 _OP_LOADNULLS= 0x11,
\r
43 _OP_LOADROOTTABLE= 0x12,
\r
48 _OP_LOADFREEVAR= 0x17,
\r
50 _OP_GETVARGV= 0x19,
\r
51 _OP_NEWTABLE= 0x1A,
\r
52 _OP_NEWARRAY= 0x1B,
\r
53 _OP_APPENDARRAY= 0x1C,
\r
54 _OP_GETPARENT= 0x1D,
\r
55 _OP_COMPARITH= 0x1E,
\r
56 _OP_COMPARITHL= 0x1F,
\r
63 _OP_INSTANCEOF= 0x26,
\r
83 struct SQInstructionDesc {
\r
84 const SQChar *name;
\r
87 struct SQInstruction
\r
90 SQInstruction(SQOpcode _op,int a0=0,int a1=0,int a2=0,int a3=0)
\r
92 _arg0 = a0;_arg1 = a1;
\r
93 _arg2 = a2;_arg3 = a3;
\r
99 unsigned char _arg0;
\r
100 unsigned char _arg2;
\r
101 unsigned char _arg3;
\r
104 #include "squtils.h"
\r
105 typedef sqvector<SQInstruction> SQInstructionVec;
\r
107 #endif // _SQOPCODES_H_
\r