* spu-tdep.c (spu_frame_unwind_cache): Add comment.
This commit is contained in:
parent
aa67235e6e
commit
0a44cb368d
|
@ -1,3 +1,7 @@
|
||||||
|
2007-05-11 Ulrich Weigand <uweigand@de.ibm.com>
|
||||||
|
|
||||||
|
* spu-tdep.c (spu_frame_unwind_cache): Add comment.
|
||||||
|
|
||||||
2007-05-11 Ulrich Weigand <uweigand@de.ibm.com>
|
2007-05-11 Ulrich Weigand <uweigand@de.ibm.com>
|
||||||
|
|
||||||
* breakpoint.c (remove_breakpoint): Do not remove software
|
* breakpoint.c (remove_breakpoint): Do not remove software
|
||||||
|
|
|
@ -743,13 +743,19 @@ spu_frame_unwind_cache (struct frame_info *next_frame,
|
||||||
/* The previous SP is equal to the CFA. */
|
/* The previous SP is equal to the CFA. */
|
||||||
trad_frame_set_value (info->saved_regs, SPU_SP_REGNUM, info->frame_base);
|
trad_frame_set_value (info->saved_regs, SPU_SP_REGNUM, info->frame_base);
|
||||||
|
|
||||||
/* The previous PC comes from the link register. In the case
|
/* Read full contents of the unwound link register in order to
|
||||||
of overlay return stubs, we unwind to the real return address. */
|
be able to determine the return address. */
|
||||||
if (trad_frame_addr_p (info->saved_regs, SPU_LR_REGNUM))
|
if (trad_frame_addr_p (info->saved_regs, SPU_LR_REGNUM))
|
||||||
target_read_memory (info->saved_regs[SPU_LR_REGNUM].addr, buf, 16);
|
target_read_memory (info->saved_regs[SPU_LR_REGNUM].addr, buf, 16);
|
||||||
else
|
else
|
||||||
frame_unwind_register (next_frame, SPU_LR_REGNUM, buf);
|
frame_unwind_register (next_frame, SPU_LR_REGNUM, buf);
|
||||||
|
|
||||||
|
/* Normally, the return address is contained in the slot 0 of the
|
||||||
|
link register, and slots 1-3 are zero. For an overlay return,
|
||||||
|
slot 0 contains the address of the overlay manager return stub,
|
||||||
|
slot 1 contains the partition number of the overlay section to
|
||||||
|
be returned to, and slot 2 contains the return address within
|
||||||
|
that section. Return the latter address in that case. */
|
||||||
if (extract_unsigned_integer (buf + 8, 4) != 0)
|
if (extract_unsigned_integer (buf + 8, 4) != 0)
|
||||||
trad_frame_set_value (info->saved_regs, SPU_PC_REGNUM,
|
trad_frame_set_value (info->saved_regs, SPU_PC_REGNUM,
|
||||||
extract_unsigned_integer (buf + 8, 4));
|
extract_unsigned_integer (buf + 8, 4));
|
||||||
|
|
Loading…
Reference in New Issue