diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2016-10-31 21:46:33 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2016-10-31 22:46:33 +0100 |
commit | 8628bc67f12fbbe9e5d4072ff3b1e28f57b3ef8e (patch) | |
tree | 557e294687e2f5289a5c930222276d43284c6f02 | |
parent | 13c21337f882406c1de0e67fb5439727a44c8274 (diff) | |
download | gcc-8628bc67f12fbbe9e5d4072ff3b1e28f57b3ef8e.zip gcc-8628bc67f12fbbe9e5d4072ff3b1e28f57b3ef8e.tar.gz gcc-8628bc67f12fbbe9e5d4072ff3b1e28f57b3ef8e.tar.bz2 |
dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): Adjust for -gdwarf-5.
* dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): Adjust for -gdwarf-5.
(DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): Likewise.
Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
From-SVN: r241725
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/dwarf2out.c | 9 |
2 files changed, 12 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index cdb09d2..b862943 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2016-10-31 Jan Kratochvil <jan.kratochvil@redhat.com> + Jakub Jelinek <jakub@redhat.com> + + * dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): Adjust for -gdwarf-5. + (DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): Likewise. + 2016-10-31 Jakub Jelinek <jakub@redhat.com> * dwarf2out.c (dwarf_AT): Handle DW_AT_dwo_name. diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c index 8259ae0..a6da7a3 100644 --- a/gcc/dwarf2out.c +++ b/gcc/dwarf2out.c @@ -2983,12 +2983,15 @@ skeleton_chain_node; /* Fixed size portion of the DWARF compilation unit header. */ #define DWARF_COMPILE_UNIT_HEADER_SIZE \ - (DWARF_INITIAL_LENGTH_SIZE + DWARF_OFFSET_SIZE + 3) + (DWARF_INITIAL_LENGTH_SIZE + DWARF_OFFSET_SIZE \ + + (dwarf_version >= 5 \ + ? 4 + DWARF_TYPE_SIGNATURE_SIZE + DWARF_OFFSET_SIZE : 3)) /* Fixed size portion of the DWARF comdat type unit header. */ #define DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE \ - (DWARF_COMPILE_UNIT_HEADER_SIZE + DWARF_TYPE_SIGNATURE_SIZE \ - + DWARF_OFFSET_SIZE) + (DWARF_COMPILE_UNIT_HEADER_SIZE \ + + (dwarf_version >= 5 \ + ? 0 : DWARF_TYPE_SIGNATURE_SIZE + DWARF_OFFSET_SIZE)) /* Fixed size portion of public names info. */ #define DWARF_PUBNAMES_HEADER_SIZE (2 * DWARF_OFFSET_SIZE + 2) |