From: Jim Blandy Date: Wed, 5 Dec 2001 00:20:37 +0000 (+0000) Subject: * s390-tdep.c (s390_get_frame_info): Recognize spills of reg X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=a479c1f59da6b0612f9f5715aa177798409a00e1;p=pf3gnuchains%2Fpf3gnuchains3x.git * s390-tdep.c (s390_get_frame_info): Recognize spills of reg arguments into their stack slots. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index d6dbbae65f..94d43f9307 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,8 @@ 2001-12-04 Jim Blandy + * s390-tdep.c (s390_get_frame_info): Recognize spills of reg + arguments into their stack slots. + * s390-tdep.c (s390_get_frame_info): More doc fixes. * s390-tdep.c (s390_get_frame_info): Doc fixes. diff --git a/gdb/s390-tdep.c b/gdb/s390-tdep.c index 2d28d9c0ae..cefa9b7e16 100644 --- a/gdb/s390-tdep.c +++ b/gdb/s390-tdep.c @@ -405,6 +405,23 @@ s390_get_frame_info (CORE_ADDR pc, struct frame_extra_info *fextra_info, continue; } + /* Check for an fp-relative STG or ST. This is probably + spilling an argument from a register out into a stack slot. + This could be a user instruction, but if we haven't included + any other suspicious instructions in the prologue, this + could only be an initializing store, which isn't too bad to + skip. The consequences of not including arg-to-stack spills + are more serious, though --- you don't see the proper values + of the arguments. */ + if ((save_link_state == 3 || save_link_state == 4) + && instr[0] == 0x50 /* st %rA, D(%rX,%rB) */ + && (instr[1] & 0xf) == 0 /* %rX is zero, no index reg */ + && ((instr[2] >> 4) & 0xf) == frame_pointer_regidx) + { + valid_prologue = 1; + continue; + } + /* check for STD */ if (instr[0] == 0x60 && (instr[2] >> 4) == 0xf) {