aboutsummaryrefslogtreecommitdiff
path: root/gdb/stack.c
diff options
context:
space:
mode:
authorJim Kingdon <jkingdon@engr.sgi.com>1993-04-21 22:20:53 +0000
committerJim Kingdon <jkingdon@engr.sgi.com>1993-04-21 22:20:53 +0000
commit31258e4f6f1a275df7153c6e5ef5a83f8b12946d (patch)
tree07b033396aa21fc360080c999573e18ed768bb9e /gdb/stack.c
parentf2c365f51737f8933759f0dd7dcb096f3bb4a0b0 (diff)
downloadgdb-31258e4f6f1a275df7153c6e5ef5a83f8b12946d.zip
gdb-31258e4f6f1a275df7153c6e5ef5a83f8b12946d.tar.gz
gdb-31258e4f6f1a275df7153c6e5ef5a83f8b12946d.tar.bz2
* stack.c (print_frame_arg_vars), printcmd.c (print_frame_args):
Expand comments about LOC_ARG/LOC_LOCAL pairs.
Diffstat (limited to 'gdb/stack.c')
-rw-r--r--gdb/stack.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/gdb/stack.c b/gdb/stack.c
index 3d3d135..0d9019f 100644
--- a/gdb/stack.c
+++ b/gdb/stack.c
@@ -887,10 +887,18 @@ print_frame_arg_vars (frame, stream)
values_printed = 1;
fputs_filtered (SYMBOL_SOURCE_NAME (sym), stream);
fputs_filtered (" = ", stream);
- /* We have to look up the symbol because arguments often have
- two entries (one a parameter, one a register) and the one
- we want is the register, which lookup_symbol will find for
- us. */
+
+ /* We have to look up the symbol because arguments can have
+ two entries (one a parameter, one a local) and the one we
+ want is the local, which lookup_symbol will find for us.
+ This includes gcc1 (not gcc2) on the sparc when passing a
+ small structure and gcc2 when the argument type is float
+ and it is passed as a double and converted to float by
+ the prologue (in the latter case the type of the LOC_ARG
+ symbol is double and the type of the LOC_LOCAL symbol is
+ float). It's possible this should be dealt with in
+ symbol reading the way it now is for LOC_REGPARM. */
+
sym2 = lookup_symbol (SYMBOL_NAME (sym),
b, VAR_NAMESPACE, (int *)NULL, (struct symtab **)NULL);
print_variable_value (sym2, frame, stream);