diff options
author | Daniel Jacobowitz <drow@false.org> | 2007-01-04 20:26:42 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2007-01-04 20:26:42 +0000 |
commit | 303b6f5dea757484ac8074bee1b4d5f7c897a997 (patch) | |
tree | 0ae6c7a147525bc1204424559e035ade47febafe /gdb/buildsym.c | |
parent | 2d0720d988230d947d5eee9245a7d2fc3f0eeb0a (diff) | |
download | gdb-303b6f5dea757484ac8074bee1b4d5f7c897a997.zip gdb-303b6f5dea757484ac8074bee1b4d5f7c897a997.tar.gz gdb-303b6f5dea757484ac8074bee1b4d5f7c897a997.tar.bz2 |
* buildsym.c (start_subfile): Handle producer.
(record_producer): New function.
* buildsym.h (struct subfile): Include producer.
(record_producer): New prototype.
* dwarf2-frame.c (struct dwarf2_cie): Add version and augmentation.
(struct dwarf2_frame_state): Add armcc_cfa_offsets_sf and
armcc_cfa_offsets_reversed.
(execute_cfa_program): Handle armcc_cfa_offsets_sf.
(dwarf2_frame_find_quirks): New function.
(dwarf2_frame_cache): Call it. Handle armcc_cfa_offsets_reversed.
(decode_frame_entry_1): Record the CIE version. Record the
augmentation. Skip armcc augmentations.
* dwarf2read.c (read_file_scope): Save the producer.
* symtab.h (struct symtab): Rename unused version member to
producer.
Diffstat (limited to 'gdb/buildsym.c')
-rw-r--r-- | gdb/buildsym.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gdb/buildsym.c b/gdb/buildsym.c index 2e946b9..ab6fff3 100644 --- a/gdb/buildsym.c +++ b/gdb/buildsym.c @@ -596,6 +596,9 @@ start_subfile (char *name, char *dirname) later via a call to record_debugformat. */ subfile->debugformat = NULL; + /* Similarly for the producer. */ + subfile->producer = NULL; + /* If the filename of this subfile ends in .C, then change the language of any pending subfiles from C to C++. We also accept any other C++ suffixes accepted by deduce_language_from_filename. */ @@ -1004,6 +1007,12 @@ end_symtab (CORE_ADDR end_addr, struct objfile *objfile, int section) &objfile->objfile_obstack); } + /* Similarly for the producer. */ + if (subfile->producer != NULL) + symtab->producer = obsavestring (subfile->producer, + strlen (subfile->producer), + &objfile->objfile_obstack); + /* All symtabs for the main file and the subfiles share a blockvector, so we need to clear primary for everything but the main file. */ @@ -1026,6 +1035,8 @@ end_symtab (CORE_ADDR end_addr, struct objfile *objfile, int section) { xfree ((void *) subfile->debugformat); } + if (subfile->producer != NULL) + xfree (subfile->producer); nextsub = subfile->next; xfree ((void *) subfile); @@ -1102,6 +1113,12 @@ record_debugformat (char *format) current_subfile->debugformat = savestring (format, strlen (format)); } +void +record_producer (const char *producer) +{ + current_subfile->producer = savestring (producer, strlen (producer)); +} + /* Merge the first symbol list SRCLIST into the second symbol list TARGETLIST by repeated calls to add_symbol_to_list(). This procedure "frees" each link of SRCLIST by adding it to the |