2005-03-28 Mark Kettenis <kettenis@gnu.org>
+ * sparc64nbsd-tdep.c (sparc64nbsd_sigcontext_saved_regs): Handle
+ StackGhost.
+
* sparc-tdep.c (sparc_supply_rwindow, sparc_collect_rwindow):
Handle StackGhost in 64-bit code.
* sparc64-tdep.c (sparc64_frame_prev_register): Handle StackGhost.
regnum <= SPARC_I7_REGNUM; regnum++, addr += 8)
saved_regs[regnum].addr = addr;
+ /* Handle StackGhost. */
+ {
+ ULONGEST wcookie = sparc_fetch_wcookie ();
+
+ if (wcookie != 0)
+ {
+ ULONGEST i7;
+
+ addr = saved_regs[SPARC_I7_REGNUM].addr;
+ i7 = get_frame_memory_unsigned (next_frame, addr, 8);
+ trad_frame_set_value (saved_regs, SPARC_I7_REGNUM, i7 ^ wcookie);
+ }
+ }
+
/* TODO: Handle the floating-point registers. */
return saved_regs;