+Wed Sep 15 05:14:32 1999 Jeffrey A Law (law@cygnus.com)
+
+ * config/tc-hppa.c: Include dwarf2dbg.h if OBJ_ELF. Declare
+ debug_line.
+ (md_pseudo_table): Add .file and .line pseudo-ops for OBJ_ELF.
+ (md_assemble): Call dwarf2_where for OBJ_ELF.
+ (pa_ip): Call dwarf2_gen_line_info for OBJ_ELF.
+ (pa_end_of_source): New function.
+ * tc-hppa.h (md_end): Define for OBJ_ELF.
+
1999-09-14 Michael Meissner <meissner@cygnus.com>
* configure.in (Canonicalization of target names): Remove adding
error only one of OBJ_ELF and OBJ_SOM can be defined
#endif
+/* If we are using ELF, then we probably can support dwarf2 debug
+ records. Furthermore, if we are supporting dwarf2 debug records,
+ then we want to use the assembler support for compact line numbers. */
+#ifdef OBJ_ELF
+#include "dwarf2dbg.h"
+struct dwarf2_line_info debug_line;
+#endif
+
/* A "convient" place to put object file dependencies which do
not need to be seen outside of tc-hppa.c. */
#ifdef OBJ_ELF
{"equ", pa_equ, 0},
{"exit", pa_exit, 0},
{"export", pa_export, 0},
+#ifdef OBJ_ELF
+ { "file", dwarf2_directive_file },
+#endif
{"fill", pa_fill, 0},
{"float", pa_float_cons, 'f'},
{"half", pa_cons, 2},
{"lcomm", pa_lcomm, 0},
{"leave", pa_leave, 0},
{"level", pa_level, 0},
+#ifdef OBJ_ELF
+ { "loc", dwarf2_directive_loc },
+#endif
{"long", pa_cons, 4},
{"lsym", pa_lsym, 0},
#ifdef OBJ_SOM
(offsetT) 0, &the_insn.exp, the_insn.pcrel,
the_insn.reloc, the_insn.field_selector,
the_insn.format, the_insn.arg_reloc, NULL);
+
+#ifdef OBJ_ELF
+ if (debug_type == DEBUG_DWARF2)
+ dwarf2_where (&debug_line);
+#endif
+
}
/* Do the real work for assembling a single instruction. Store results
break;
}
+#ifdef OBJ_ELF
+ if (debug_type == DEBUG_DWARF2)
+ {
+ bfd_vma addr;
+
+ addr = frag_now->fr_address + frag_now_fix ();
+ dwarf2_gen_line_info (addr, &debug_line);
+ }
+#endif
+
the_insn.opcode = opcode;
}
}
}
#endif
+
+#ifdef OBJ_ELF
+pa_end_of_source ()
+{
+ if (debug_type == DEBUG_DWARF2)
+ dwarf2_finish ();
+}
+#endif