comparison lwasm/insn_gen.c @ 220:2b254f02b252

Fixed off by one relocation offset for direct page external references
author lost
date Sat, 09 May 2009 16:21:54 +0000
parents bae1e3ecdce1
children 7803d2d09993
comparison
equal deleted inserted replaced
219:402a035220ed 220:2b254f02b252
100 } 100 }
101 v1 = v1 & 0xff; 101 v1 = v1 & 0xff;
102 lwasm_emitop(as, l, instab[opnum].ops[0]); 102 lwasm_emitop(as, l, instab[opnum].ops[0]);
103 if (extra != -1) 103 if (extra != -1)
104 lwasm_emit(as, l, extra); 104 lwasm_emit(as, l, extra);
105 lwasm_emit(as, l, v1 & 0xff);
106 l -> relocoff = as -> addr - l -> codeaddr; 105 l -> relocoff = as -> addr - l -> codeaddr;
107 l -> reloc8bit = 1; 106 l -> reloc8bit = 1;
107 lwasm_emit(as, l, v1 & 0xff);
108 return; 108 return;
109 } 109 }
110 else 110 else
111 { 111 {
112 // everything else is 16 bit.... 112 // everything else is 16 bit....