[PATCH] Fix that different function breakpoints are set at same pc address (PR gdb/12703)

Terry Guo terry.guo@arm.com
Wed Jun 29 08:49:00 GMT 2011


Hi,

First if you look at the generated binary code, I thought it is a valid case. After performing the function test, it will fall into function bar which is a normal function. At least my case can run correctly on QEMU. It is very likely for people to write program in assembly code like:

main:
    b test

test:
    movs r5, #10
bar:
    push.......
    .........

You cannot say this is a invalid program. If you have concern about attribute NAKED, I can rewrite it in assembly code.

Second, we all know that current prologue analyzer cannot handle all cases. My patch only intends to be a worthwhile supplement for cases that beyond the prologue analyzer capability.

Third, I also have strong interesting to enhance prologue analyze. I suggest we use another thread to discuss how to enhance prologue analyzer to handle all possible cases. And leave this one to discuss whether is it worthwhile to have my patch.

BR,
Terry





More information about the Gdb-patches mailing list