Daniel Jacobowitz wrote: > > The beauty of using the CFI data is that it _is_ supposed to work in > the prologue. It sounds like the CFI is wrong. Could you post both > assembly and CFI data for the same testcase? I don't know CRIS > assembly but I imagine I can interpret it well enough to see what's > going on. I have attached the test program, dissassembly (objdump -d -S) and the dwarf2 info (readelf -w). (Crash course in CRIS assembly, if at all needed: r8 holds the frame pointer and srp holds the return address, pushed only in non-leaf functions.) > It also sounds like your DWARF2_REG_TO_REGNUM may need work, if the > unwinder thinks r16 is the return address column and GDB thinks it's an > 8-bit register. Ugh, I had totally missed that (i.e. I don't even have a CRIS-specific DWARF2_REG_TO_REGNUM). Looking at the other targets' implementations I don't understand where they got the dwarf2 register mapping from (though amd64-tdep.c mentions System V psABI), and the dwarf2 spec says in "2.4.2 Register Name Operators" it should be in the architecture's ABI spec. I'll go bug my compiler guy, or go look in gcc myself. -- Orjan Friberg Axis Communications