Hi
When I remove some breakpoints in my code, and re enable it just after I have a non constant breakpoint index
For example:
Execution stopped in Thread mode at 0x1FFE447A0x1FFE447A 9,0 return result;break -p "I:/try_env/src/tests/D_IP_ISI_SYN/imx8qm/pdma_bypass_dc0_iris_fetchlayer0_di0.c":547Breakpoint 10 at 0x1FFF9A60 on file pdma_bypass_dc0_iris_fetchlayer0_di0.c, line 547delete 10Breakpoint 10 deletedbreak -p "I:/try_env/src/tests/D_IP_ISI_SYN/imx8qm/pdma_bypass_dc0_iris_fetchlayer0_di0.c":547Breakpoint 11 at 0x1FFF9A60 on file pdma_bypass_dc0_iris_fetchlayer0_di0.c, line 547waitcontinue
It sounds last breakpoint index is not removed from internal database of DS5.
It can be annoying when doing some scripting and using bkp index.
How to overcome this issue?
Issue is poping up with latest v 5.27.0 DS5 .
regards
claude
Hi Claude,
The breakpoints are being removed. It's just that the next available id is used for each new breakpoint.
You could use the 'clear' command instead, and then still reference the symbol that you used to set the breakpoint at.
So, for example, if you want to set a breakpoint at, say, the start of a function called 'compare_sorts()' you can do :
break -p compare_sorts
or if you know the offset from the function you can do :
break -p compare_sorts+0xC
then to delete use the 'clear' command, thus :
clear compare_sorts
clear compare_sorts+0xC
Does that help you ?
Regards,
Stuart
Thanks Stuart,
I really missed that command since I always used the delete command.
So I use the following sequence
break mainBreakpoint 12 at 0x1FFF732C on file pdma_bypass_axi_mem_Ch0_irq.c, line 235clear mainBreakpoint 2 deletedBreakpoint 3 deletedBreakpoint 4 deletedBreakpoint 5 deletedBreakpoint 6 deletedBreakpoint 7 deletedBreakpoint 8 deletedBreakpoint 9 deletedBreakpoint 10 deletedBreakpoint 12 deletedbreak -p mainBreakpoint 13 at 0x1FFF732C on file pdma_bypass_axi_mem_Ch0_irq.c, line 235clear mainBreakpoint 13 deleted
I see that all bkp are deleted after a clear command and when reseting the bkp in the same location, index is 13, not 12.
Did I miss something?
Hi Claude
Related to the above, the internal "$" variable keeps track of the last "thing" (breakpoint, watchpoint...) created. You can check it with:
print $
(should return 13 above).
You can use this, or an offset of it ($-3) to reference other breakpoints. Be careful though... doing something like
print $-1
will return 12 above, and set $=$-1, so then
will return 12.
Ronan