41 #if SIZEOF_VOID_P == 8
61 #define MAYBE_UNUSED __attribute__((unused))
66 #if SIZEOF_VOID_P == 4
77 #define FETCH_DCELL_T(d_,lo,hi,t_) ({ \
79 _d.cells.low = (lo); \
80 _d.cells.high = (hi); \
84 #define STORE_DCELL_T(d_,lo,hi,t_) ({ \
87 (lo) = _d.cells.low; \
88 (hi) = _d.cells.high; \
100 #define FETCH_DCELL_T(d_,lo,hi,t_) ({ (d_) = ((Double_Store)(lo)).t_; })
101 #define STORE_DCELL_T(d_,lo,hi,t_) ({ (lo) = ((Double_Store)(d_)).low; })
106 #if defined(ENABLE_THREADS)
108 #define global_sp (THREADOBJECT->_global_sp)
112 #define MAX_STACK_SIZE 128*1024
113 static char stack[MAX_STACK_SIZE];
116 #define global_sp _global_sp
120 #define CLEAR_global_sp (global_sp=NULL)
123 #define vm_twoCell2l(hi,lo,d_) FETCH_DCELL_T(d_,lo,hi,l);
124 #define vm_twoCell2d(hi,lo,d_) FETCH_DCELL_T(d_,lo,hi,d);
126 #define vm_l2twoCell(d_,hi,lo) STORE_DCELL_T(d_,lo,hi,l);
127 #define vm_d2twoCell(d_,hi,lo) STORE_DCELL_T(d_,lo,hi,d);
129 #define vm_Cell2v(cell, v) ((v)=(Cell)(cell))
130 #define vm_Cell2b(cell, b) ((b)=(u1)(Cell)(cell))
131 #define vm_Cell2i(cell, i) ((i)=(s4)(Cell)(cell))
133 #define vm_Cell2aRef(x1,x2) ((x2) = (java_objectheader *)(x1))
134 #define vm_Cell2aArray(x1,x2) ((x2) = (java_arrayheader * )(x1))
135 #define vm_Cell2aaTarget(x1,x2) ((x2) = (Inst ** )(x1))
136 #define vm_Cell2aClass(x1,x2) ((x2) = (classinfo * )(x1))
137 #define vm_Cell2acr(x1,x2) ((x2) = (constant_classref *)(x1))
138 #define vm_Cell2addr(x1,x2) ((x2) = (u1 * )(x1))
139 #define vm_Cell2af(x1,x2) ((x2) = (functionptr )(x1))
140 #define vm_Cell2afi(x1,x2) ((x2) = (fieldinfo * )(x1))
141 #define vm_Cell2am(x1,x2) ((x2) = (methodinfo * )(x1))
142 #define vm_Cell2acell(x1,x2) ((x2) = (Cell * )(x1))
143 #define vm_Cell2ainst(x1,x2) ((x2) = (Inst * )(x1))
144 #define vm_Cell2auf(x1,x2) ((x2) = (unresolved_field * )(x1))
145 #define vm_Cell2aum(x1,x2) ((x2) = (unresolved_method *)(x1))
146 #define vm_Cell2avftbl(x1,x2) ((x2) = (vftbl_t * )(x1))
148 #define vm_ui2Cell(x1,x2) ((x2) = (Cell)(x1))
149 #define vm_v2Cell(x1,x2) ((x2) = (Cell)(x1))
150 #define vm_b2Cell(x1,x2) ((x2) = (Cell)(x1))
151 #define vm_s2Cell(x1,x2) ((x2) = (Cell)(x1))
152 #define vm_i2Cell(x1,x2) ((x2) = (Cell)(x1))
153 #define vm_aRef2Cell(x1,x2) ((x2) = (Cell)(x1))
154 #define vm_aArray2Cell(x1,x2) ((x2) = (Cell)(x1))
155 #define vm_aaTarget2Cell(x1,x2) ((x2) = (Cell)(x1))
156 #define vm_aClass2Cell(x1,x2) ((x2) = (Cell)(x1))
157 #define vm_acr2Cell(x1,x2) ((x2) = (Cell)(x1))
158 #define vm_addr2Cell(x1,x2) ((x2) = (Cell)(x1))
159 #define vm_af2Cell(x1,x2) ((x2) = (Cell)(x1))
160 #define vm_afi2Cell(x1,x2) ((x2) = (Cell)(x1))
161 #define vm_am2Cell(x1,x2) ((x2) = (Cell)(x1))
162 #define vm_acell2Cell(x1,x2) ((x2) = (Cell)(x1))
163 #define vm_ainst2Cell(x1,x2) ((x2) = (Cell)(x1))
164 #define vm_auf2Cell(x1,x2) ((x2) = (Cell)(x1))
165 #define vm_aum2Cell(x1,x2) ((x2) = (Cell)(x1))
166 #define vm_avftbl2Cell(x1,x2) ((x2) = (Cell)(x1))
168 #define vm_Cell2Cell(x1,x2) ((x2)=(Cell)(x1))
170 #define IMM_ARG(access,value) (access)
173 #define VM_IS_INST(inst, n) ((inst) == vm_prim[n])
176 #define gen_BBSTART (cd->lastmcodeptr = NULL, append_dispatch(cd))
177 #define gen_BBEND (finish_ss(cd))
186 #define access_local_int(_offset) \
187 ( *(Cell*)(((u1 *)fp) + (_offset)) )
189 #define access_local_ref(_offset) \
190 ( *(void **)(((u1 *)fp) + (_offset)) )
192 #define access_local_cell(_offset) \
193 ( *(Cell *)(((u1 *)fp) + (_offset)) )
198 #define vm_f2Cell(x1,x2) ((x2) =(((union Cell_float)(x1)).cell))
199 #define vm_Cell2f(x1,x2) ((x2) =(((union Cell_float)(x1)).f))
void printarg_acr(constant_classref *acr)
Cell * nativecall(functionptr f, methodinfo *m, Cell *sp, Inst *ra, Cell *fp, u1 *addrcif)
void printarg_aClass(classinfo *aClass)
void printarg_aaTarget(Inst **aaTarget)
void dynamic_super_rewrite(codegendata *cd)
void finish_ss(codegendata *cd)
void printarg_aArray(java_arrayheader *aArray)
void printarg_avftbl(vftbl_t *avftbl)
void patchersuper_rewrite(Inst *p)
void printarg_d(double d)
void gen_inst(codegendata *cd, ptrint instr)
void init_peeptable(void)
block_count * vm_block_insert(Inst *ip)
void(* functionptr)(void)
void printarg_addr(u1 *addr)
#define vm_uncount_block(_ip)
void printarg_acell(Cell *acell)
void printarg_aum(unresolved_method *aum)
alloc::list< PassInfo::IDTy >::type & stack
void printarg_auf(unresolved_field *auf)
void printarg_af(functionptr af)
Inst * intrp_asm_handle_exception(Inst *ip, java_objectheader *o, Cell *fp, Cell **new_spp, Cell **new_fpp)
ptrint peephole_opt(ptrint inst1, ptrint inst2, Cell peeptable)
void printarg_ainst(Inst *ainst)
Inst * vm_disassemble_inst(Inst *ip, Inst vm_prim[])
void printarg_Cell(Cell x)
void append_dispatch(codegendata *cd)
u1 * createcalljavafunction(methodinfo *m)
void printarg_am(methodinfo *am)
void vm_disassemble(Inst *ip, Inst *endp, Inst vm_prim[])
void printarg_afi(fieldinfo *afi)
void dynamic_super_init(void)
void printarg_aRef(java_objectheader *aRef)