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 /lib | |
| parent | 2225c9aafc9245e12b22d34b68be8017c42febd8 (diff) | |
| download | luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.tar.gz luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.tar.bz2 luajit-bcd459aa0e5ab8e6df4a89c75c4f9f00ec7d0176.zip | |
MIPS: Integrate and enable JIT compiler.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/dis_mips.lua | 2 | ||||
| -rw-r--r-- | lib/dump.lua | 17 |
2 files changed, 15 insertions, 4 deletions
diff --git a/lib/dis_mips.lua b/lib/dis_mips.lua index 165405d2..2edfdf40 100644 --- a/lib/dis_mips.lua +++ b/lib/dis_mips.lua | |||
| @@ -231,7 +231,7 @@ local map_gpr = { | |||
| 231 | [0] = "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", | 231 | [0] = "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7", |
| 232 | "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15", | 232 | "r8", "r9", "r10", "r11", "r12", "r13", "r14", "r15", |
| 233 | "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23", | 233 | "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23", |
| 234 | "r24", "r25", "r26", "r27", "gp", "sp", "r30", "ra", | 234 | "r24", "r25", "r26", "r27", "r28", "sp", "r30", "ra", |
| 235 | } | 235 | } |
| 236 | 236 | ||
| 237 | ------------------------------------------------------------------------------ | 237 | ------------------------------------------------------------------------------ |
diff --git a/lib/dump.lua b/lib/dump.lua index 37c06502..3d62c4ea 100644 --- a/lib/dump.lua +++ b/lib/dump.lua | |||
| @@ -84,6 +84,10 @@ local nexitsym = 0 | |||
| 84 | local function fillsymtab_tr(tr, nexit) | 84 | local function fillsymtab_tr(tr, nexit) |
| 85 | local t = {} | 85 | local t = {} |
| 86 | symtabmt.__index = t | 86 | symtabmt.__index = t |
| 87 | if jit.arch == "mips" or jit.arch == "mipsel" then | ||
| 88 | t[traceexitstub(tr, 0)] = "exit" | ||
| 89 | return | ||
| 90 | end | ||
| 87 | for i=0,nexit-1 do | 91 | for i=0,nexit-1 do |
| 88 | local addr = traceexitstub(tr, i) | 92 | local addr = traceexitstub(tr, i) |
| 89 | t[addr] = tostring(i) | 93 | t[addr] = tostring(i) |
| @@ -604,9 +608,16 @@ local function dump_texit(tr, ex, ngpr, nfpr, ...) | |||
| 604 | if i % 8 == 0 then out:write("\n") end | 608 | if i % 8 == 0 then out:write("\n") end |
| 605 | end | 609 | end |
| 606 | end | 610 | end |
| 607 | for i=1,nfpr do | 611 | if jit.arch == "mips" or jit.arch == "mipsel" then |
| 608 | out:write(format(" %+17.14g", regs[ngpr+i])) | 612 | for i=1,nfpr,2 do |
| 609 | if i % 4 == 0 then out:write("\n") end | 613 | out:write(format(" %+17.14g", regs[ngpr+i])) |
| 614 | if i % 8 == 7 then out:write("\n") end | ||
| 615 | end | ||
| 616 | else | ||
| 617 | for i=1,nfpr do | ||
| 618 | out:write(format(" %+17.14g", regs[ngpr+i])) | ||
| 619 | if i % 4 == 0 then out:write("\n") end | ||
| 620 | end | ||
| 610 | end | 621 | end |
| 611 | end | 622 | end |
| 612 | end | 623 | end |
