Test 1: Building on linux pure-cap, building ARM's standard examples e.g helloworld. Inside lldb, set breakpoint at main and run. Does not halt, program runs to completion.
Test 2: Build for linux-aarch64-gnu, i.e without pure-cap flag, and perform the same lldb actions. Works fine - program halts at main.
Test 3: Build for linux-aarch64-gnu as per test 2 but THEN use the morello_elf tool to patch the purecap flag in the executable then lldb does not work in the same way as observed in test 1.
I suspect I am doing something silly, but I cannot figure out what - but I suspect it is something obvious I have missed! Please help.
- In all cases, in lldb process launch -s will indeed stop at the entry point
- lldb reports breakpoints are being set correctly in all cases. Also doing a memory dump shows the address is correct (I tried setting breakpoint via address and at printf() also).
- In all cases, program runs normally outside the debugger
- When debugging the heap test example, lldb shows the seg fault as expected including the source trace.
(lldb) br set -n main
Assuming this is all supposed to work, any pointers to something obvious I have missed would be appreciated. This is all running on Morello board with a linux pure-cap stack installed on the SATA ssd, lldb running on the target also (i.e not remote debugging). I will also try debugging with gnu tools (gdb).
Thanks Silviu, will register for the gitlab access and raise an issue there as you suggest.