summaryrefslogtreecommitdiff
path: root/src/lj_gdbjit.c
diff options
context:
space:
mode:
authorMike Pall <mike>2011-06-07 21:37:24 +0200
committerMike Pall <mike>2011-06-07 21:37:24 +0200
commit585cf05dbd54564d2d3387cef09b3ac2d5e52afd (patch)
treed455c80e6d916ae2673d8aaaee50f0ba77d0b92a /src/lj_gdbjit.c
parentb44ccd426339a9eb0da83633d4b71a23dac29762 (diff)
downloadluajit-585cf05dbd54564d2d3387cef09b3ac2d5e52afd.tar.gz
luajit-585cf05dbd54564d2d3387cef09b3ac2d5e52afd.tar.bz2
luajit-585cf05dbd54564d2d3387cef09b3ac2d5e52afd.zip
Move debugging/introspection functionality to lj_debug.c.
Diffstat (limited to 'src/lj_gdbjit.c')
-rw-r--r--src/lj_gdbjit.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/lj_gdbjit.c b/src/lj_gdbjit.c
index 41ee1b33..28e063fb 100644
--- a/src/lj_gdbjit.c
+++ b/src/lj_gdbjit.c
@@ -12,6 +12,7 @@
12 12
13#include "lj_gc.h" 13#include "lj_gc.h"
14#include "lj_err.h" 14#include "lj_err.h"
15#include "lj_debug.h"
15#include "lj_frame.h" 16#include "lj_frame.h"
16#include "lj_jit.h" 17#include "lj_jit.h"
17#include "lj_dispatch.h" 18#include "lj_dispatch.h"
@@ -728,10 +729,8 @@ void lj_gdbjit_addtrace(jit_State *J, GCtrace *T)
728 ctx.spadjp = CFRAME_SIZE_JIT + 729 ctx.spadjp = CFRAME_SIZE_JIT +
729 (MSize)(parent ? traceref(J, parent)->spadjust : 0); 730 (MSize)(parent ? traceref(J, parent)->spadjust : 0);
730 ctx.spadj = CFRAME_SIZE_JIT + T->spadjust; 731 ctx.spadj = CFRAME_SIZE_JIT + T->spadjust;
731 if (startpc >= proto_bc(pt) && startpc < proto_bc(pt) + pt->sizebc) 732 lua_assert(startpc >= proto_bc(pt) && startpc < proto_bc(pt) + pt->sizebc);
732 ctx.lineno = proto_line(pt, proto_bcpos(pt, startpc)); 733 ctx.lineno = lj_debug_line(pt, proto_bcpos(pt, startpc));
733 else
734 ctx.lineno = proto_line(pt, 0); /* Wrong, but better than nothing. */
735 ctx.filename = strdata(proto_chunkname(pt)); 734 ctx.filename = strdata(proto_chunkname(pt));
736 if (*ctx.filename == '@' || *ctx.filename == '=') 735 if (*ctx.filename == '@' || *ctx.filename == '=')
737 ctx.filename++; 736 ctx.filename++;