Forum Replies Created
-
AuthorPosts
-
jturnsekParticipant
When I call hbreak in my gdb session I get this:
No hardware breakpoint support in the target.
jturnsekParticipantThanks for the information. I wasn’t aware that I could use hardware breakpoints with GNU/Linux session.
jturnsekParticipantActually what I found out is the problem with GNU/Linux GDB session, but currently I can not confirm it. Investigating and searching on the web, the problem is most probably with setting software breakpoints during the debugging session, when I should have hardware breakpoints. Because I am not using any JTAG for debugging I can not confirm this. As I have mentioned before, running the program without setting any breakpoint in my injected assembly thus not produce the SIGSEGV exception and the program runs ok. Also I have tried to go around of IT instruction with using plain conditional branch instruction and the debugging works. Only debugging IT blocks is problematic.
jturnsekParticipantActually is not an IT instruction which is segfaulting, it is an instruction inside an IT block and which is executed if condition is met. If I manually change the condition to false, thus instruction in IT block would not be executed, program runs through without SIGSEGV.
jturnsekParticipantI have already tested the execution of my program without debugging it and it works as it should. The problem is only when I am debugging my assembly code step by step. Also executing the program directly on the target (BTW it is Ubuntu 18.04 operating system and Beagleboard X15), it works without problems. I have find out some old patch for the old GDB where something similar was mentioned about debugging Thumb2 code step by step within IT block. but that was before GDB version 7. I have GDB 8.1.0 installed on Ubutnu 18.04.
jturnsekParticipantHi,
I have tested on ARM Cortex A15 and A8. Both are ARMv7-A architecture which also supports Thumb2 instructions. In the reference manual for the ARMv7-A it is clearly stated that IT is needed for conditional opcodes.
Maybe GDB is not supporting IT?
Regards,
Jernej
jturnsekParticipantI have found out that setting:
set disassembler-options force-thumb
forces disassembler to show Thumb encoding. Good. But still when hitting IT instruction, SIGSEGV is thrown. Why?
Jernej
-
AuthorPosts