diff options
author | Mike Frysinger <vapier@gentoo.org> | 2006-08-26 06:59:03 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2006-08-26 06:59:03 +0000 |
commit | d700db13bd2f81f3ec4cc5108b87d048705f2ecf (patch) | |
tree | 7f5b3155be6ac094f64a51e4c5e458f275a22cf2 /4.1.1 | |
parent | backport from trunk for #145029 (diff) | |
download | gcc-patches-d700db13bd2f81f3ec4cc5108b87d048705f2ecf.tar.gz gcc-patches-d700db13bd2f81f3ec4cc5108b87d048705f2ecf.tar.bz2 gcc-patches-d700db13bd2f81f3ec4cc5108b87d048705f2ecf.zip |
backport from trunk for #145028
Diffstat (limited to '4.1.1')
-rw-r--r-- | 4.1.1/gentoo/95_all_gcc-mips-dwarf-info.patch | 92 | ||||
-rw-r--r-- | 4.1.1/gentoo/95_all_gcc-mips-dwarf-old-info.patch | 24 |
2 files changed, 116 insertions, 0 deletions
diff --git a/4.1.1/gentoo/95_all_gcc-mips-dwarf-info.patch b/4.1.1/gentoo/95_all_gcc-mips-dwarf-info.patch new file mode 100644 index 0000000..1129ba6 --- /dev/null +++ b/4.1.1/gentoo/95_all_gcc-mips-dwarf-info.patch @@ -0,0 +1,92 @@ +http://gcc.gnu.org/ml/gcc-patches/2006-03/msg01152.html + +http://bugs.gentoo.org/145028 + +2006-04-01 Joseph S. Myers <joseph@codesourcery.com> + + * dwarf2.h (DW64_CIE_ID): Define. + * dwarf2out.c (DWARF_CIE_ID): Define. + (output_call_frame_info): Output 0xffffffff before standard 8-byte + length header. Use DWARF_CIE_ID. + (value_format): Use DW_FORM_data4 or DW_FORM_data8 for + dw_val_class_loc_list depending on DWARF_OFFSET_SIZE. + +Index: trunk/gcc/dwarf2out.c +=================================================================== +--- trunk/gcc/dwarf2out.c (revision 112600) ++++ trunk/gcc/dwarf2out.c (revision 112601) +@@ -288,6 +288,14 @@ dw_fde_node; + #endif + #endif + ++/* CIE identifier. */ ++#if HOST_BITS_PER_WIDE_INT >= 64 ++#define DWARF_CIE_ID \ ++ (unsigned HOST_WIDE_INT) (DWARF_OFFSET_SIZE == 4 ? DW_CIE_ID : DW64_CIE_ID) ++#else ++#define DWARF_CIE_ID DW_CIE_ID ++#endif ++ + /* A pointer to the base of a table that contains frame description + information for each routine. */ + static GTY((length ("fde_table_allocated"))) dw_fde_ref fde_table; +@@ -2218,6 +2226,9 @@ output_call_frame_info (int for_eh) + /* Output the CIE. */ + ASM_GENERATE_INTERNAL_LABEL (l1, CIE_AFTER_SIZE_LABEL, for_eh); + ASM_GENERATE_INTERNAL_LABEL (l2, CIE_END_LABEL, for_eh); ++ if (DWARF_INITIAL_LENGTH_SIZE - DWARF_OFFSET_SIZE == 4 && !for_eh) ++ dw2_asm_output_data (4, 0xffffffff, ++ "Initial length escape value indicating 64-bit DWARF extension"); + dw2_asm_output_delta (for_eh ? 4 : DWARF_OFFSET_SIZE, l2, l1, + "Length of Common Information Entry"); + ASM_OUTPUT_LABEL (asm_out_file, l1); +@@ -2225,7 +2236,7 @@ output_call_frame_info (int for_eh) + /* Now that the CIE pointer is PC-relative for EH, + use 0 to identify the CIE. */ + dw2_asm_output_data ((for_eh ? 4 : DWARF_OFFSET_SIZE), +- (for_eh ? 0 : DW_CIE_ID), ++ (for_eh ? 0 : DWARF_CIE_ID), + "CIE Identifier Tag"); + + dw2_asm_output_data (1, DW_CIE_VERSION, "CIE Version"); +@@ -2350,6 +2361,9 @@ output_call_frame_info (int for_eh) + targetm.asm_out.internal_label (asm_out_file, FDE_LABEL, for_eh + i * 2); + ASM_GENERATE_INTERNAL_LABEL (l1, FDE_AFTER_SIZE_LABEL, for_eh + i * 2); + ASM_GENERATE_INTERNAL_LABEL (l2, FDE_END_LABEL, for_eh + i * 2); ++ if (DWARF_INITIAL_LENGTH_SIZE - DWARF_OFFSET_SIZE == 4 && !for_eh) ++ dw2_asm_output_data (4, 0xffffffff, ++ "Initial length escape value indicating 64-bit DWARF extension"); + dw2_asm_output_delta (for_eh ? 4 : DWARF_OFFSET_SIZE, l2, l1, + "FDE Length"); + ASM_OUTPUT_LABEL (asm_out_file, l1); +@@ -6775,6 +6789,7 @@ value_format (dw_attr_ref a) + return DW_FORM_addr; + case dw_val_class_range_list: + case dw_val_class_offset: ++ case dw_val_class_loc_list: + switch (DWARF_OFFSET_SIZE) + { + case 4: +@@ -6784,10 +6799,6 @@ value_format (dw_attr_ref a) + default: + gcc_unreachable (); + } +- case dw_val_class_loc_list: +- /* FIXME: Could be DW_FORM_data8, with a > 32 bit size +- .debug_loc section */ +- return DW_FORM_data4; + case dw_val_class_loc: + switch (constant_size (size_of_locs (AT_loc (a)))) + { +Index: trunk/gcc/dwarf2.h +=================================================================== +--- trunk/gcc/dwarf2.h (revision 112600) ++++ trunk/gcc/dwarf2.h (revision 112601) +@@ -757,6 +757,7 @@ enum dwarf_call_frame_info + }; + + #define DW_CIE_ID 0xffffffff ++#define DW64_CIE_ID 0xffffffffffffffffULL + #define DW_CIE_VERSION 1 + + #define DW_CFA_extended 0 diff --git a/4.1.1/gentoo/95_all_gcc-mips-dwarf-old-info.patch b/4.1.1/gentoo/95_all_gcc-mips-dwarf-old-info.patch new file mode 100644 index 0000000..a109da9 --- /dev/null +++ b/4.1.1/gentoo/95_all_gcc-mips-dwarf-old-info.patch @@ -0,0 +1,24 @@ +http://gcc.gnu.org/ml/gcc-patches/2006-03/msg01152.html + +http://bugs.gentoo.org/145028 + +2006-05-04 Joseph S. Myers <joseph@codesourcery.com> + + * config/mips/linux64.h (DWARF_OFFSET_SIZE): Remove. + +Index: trunk/gcc/config/mips/linux64.h +=================================================================== +--- trunk/gcc/config/mips/linux64.h (revision 113523) ++++ trunk/gcc/config/mips/linux64.h (revision 113524) +@@ -65,11 +65,6 @@ Boston, MA 02110-1301, USA. */ + #undef LOCAL_LABEL_PREFIX + #define LOCAL_LABEL_PREFIX (TARGET_OLDABI ? "$" : ".") + +-/* The size in bytes of a DWARF field indicating an offset or length +- relative to a debug info section, specified to be 4 bytes in the DWARF-2 +- specification. The SGI/MIPS ABI defines it to be the same as PTR_SIZE. */ +-#define DWARF_OFFSET_SIZE PTR_SIZE +- + /* GNU/Linux doesn't use the same floating-point format that IRIX uses + for long double. There's no need to override this here, since + ieee_quad_format is the default, but let's put this here to make |