This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[obish/dwarf2] Describe frame-base hack


Stumbled across this during testing of symbol_ops. This adds a comment alerting the reader as to a problem.

Index: ChangeLog
2004-01-26  Andrew Cagney  <>

	* dwarf2read.c (read_func_scope): Document hack.

Index: dwarf2read.c
RCS file: /cvs/src/src/gdb/dwarf2read.c,v
retrieving revision 1.124
diff -u -r1.124 dwarf2read.c
--- dwarf2read.c	23 Jan 2004 22:41:28 -0000	1.124
+++ dwarf2read.c	26 Jan 2004 19:54:06 -0000
@@ -2211,6 +2211,15 @@
      it.  */
   attr = dwarf_attr (die, DW_AT_frame_base);
   if (attr)
+    /* FIXME: cagney/2004-01-26: The DW_AT_frame_base's location
+       expression is being recorded directly in the function's symbol
+       and not in a separate frame-base object.  I guess this hack is
+       to avoid adding some sort of frame-base adjunct/annex to the
+       function's symbol :-(.  The problem with doing this is that it
+       results in a function symbol with a location expression that
+       has nothing to do with the location of the function, ouch!  The
+       relationship should be: a function's symbol has-a frame base; a
+       frame-base has-a location expression.  */
     dwarf2_symbol_mark_computed (attr, new->name, cu);
   list_in_scope = &local_symbols;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]