Hi Alwyn,
  You can try enabling debug information in Terra using the -mg flag. On
Linux/OSX this should give line number information in stack traces. Using
LLVM 3.5 on Linux, this should also allow GDB to see the function names and
line number information.

Zach

On Mon, Nov 24, 2014 at 1:54 PM, Husselmann, Alwyn <
[email protected]> wrote:

>  Hi all,
>
> I've been trying to follow the LuaJIT gdb session example given in:
> https://github.com/LuaDist/luajit/blob/master/src/lj_gdbjit.c
>
> When a crash happens in my Terra code, my C program (with Terra embedded),
> attaches GDB upon getting SIGSEGV. What I'd really like is if I could see
> exactly where in the Terra code this is happening. Using Lua's C interface
> I can print out a Lua stacktrace, but I can't see within Terra functions
> composed of statements and generated automatically.
>
> Does anyone have any advice? Is there perhaps a way of pinpointing the
> instruction within the LLVM IR, or the terra function with printpretty() ?
>
> Many thanks,
> Alwyn
>
> _______________________________________________
> terralang mailing list
> [email protected]
> https://mailman.stanford.edu/mailman/listinfo/terralang
>
>
_______________________________________________
terralang mailing list
[email protected]
https://mailman.stanford.edu/mailman/listinfo/terralang

Reply via email to