diff options
author | Mike Pall <mike> | 2012-03-30 01:36:55 +0200 |
---|---|---|
committer | Mike Pall <mike> | 2012-03-30 01:36:55 +0200 |
commit | bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176 (patch) | |
tree | 1c2a3b358455eda1abcf45bbdc6600f1e4e58810 /src/lj_mcode.c | |
parent | 2225c9aafc9245e12b22d34b68be8017c42febd8 (diff) | |
download | luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.tar.gz luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.tar.bz2 luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.zip |
MIPS: Integrate and enable JIT compiler.
Diffstat (limited to 'src/lj_mcode.c')
-rw-r--r-- | src/lj_mcode.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lj_mcode.c b/src/lj_mcode.c index 7857ebc0..fb6b6dce 100644 --- a/src/lj_mcode.c +++ b/src/lj_mcode.c | |||
@@ -203,7 +203,13 @@ static void *mcode_alloc(jit_State *J, size_t sz) | |||
203 | /* Target an address in the static assembler code (64K aligned). | 203 | /* Target an address in the static assembler code (64K aligned). |
204 | ** Try addresses within a distance of target-range/2+1MB..target+range/2-1MB. | 204 | ** Try addresses within a distance of target-range/2+1MB..target+range/2-1MB. |
205 | */ | 205 | */ |
206 | #if LJ_TARGET_MIPS | ||
207 | /* Use the middle of the 256MB-aligned region. */ | ||
208 | uintptr_t target = ((uintptr_t)(void *)lj_vm_exit_handler & 0xf0000000u) + | ||
209 | 0x08000000u; | ||
210 | #else | ||
206 | uintptr_t target = (uintptr_t)(void *)lj_vm_exit_handler & ~(uintptr_t)0xffff; | 211 | uintptr_t target = (uintptr_t)(void *)lj_vm_exit_handler & ~(uintptr_t)0xffff; |
212 | #endif | ||
207 | const uintptr_t range = (1u << LJ_TARGET_JUMPRANGE) - (1u << 21); | 213 | const uintptr_t range = (1u << LJ_TARGET_JUMPRANGE) - (1u << 21); |
208 | /* First try a contiguous area below the last one. */ | 214 | /* First try a contiguous area below the last one. */ |
209 | uintptr_t hint = J->mcarea ? (uintptr_t)J->mcarea - sz : 0; | 215 | uintptr_t hint = J->mcarea ? (uintptr_t)J->mcarea - sz : 0; |