diff options
author | Mike Stump <mrs@apple.com> | 2004-05-19 02:11:42 +0000 |
---|---|---|
committer | Mike Stump <mrs@gcc.gnu.org> | 2004-05-19 02:11:42 +0000 |
commit | eeab4d81a61970e9079dbd9a8033d13e0cc27980 (patch) | |
tree | 4adbc5fe821c2a82672b65131f45055c866c807e /gcc/config | |
parent | bb9a388dad84486a075d822e4bed05a74faab780 (diff) | |
download | gcc-eeab4d81a61970e9079dbd9a8033d13e0cc27980.zip gcc-eeab4d81a61970e9079dbd9a8033d13e0cc27980.tar.gz gcc-eeab4d81a61970e9079dbd9a8033d13e0cc27980.tar.bz2 |
tm.texi (TARGET_ASM_EMIT_UNWIND_LABEL): Add argument to indicate if this label is for eh.
* doc/tm.texi (TARGET_ASM_EMIT_UNWIND_LABEL): Add argument to indicate
if this label is for eh.
* config/darwin-protos.h (darwin_emit_unwind_label): Likewise.
* config/darwin.c (darwin_emit_unwind_label): Likewise.
* dwarf2out.c (output_call_frame_info): Likewise.
* output.h (default_emit_unwind_label): Likewise.
* target.h (unwind_label): Likewise.
* varasm.c (default_emit_unwind_label): Likewise.
* config/darwin.h (DWARF2_DEBUGGING_INFO, PREFERRED_DEBUGGING_TYPE,
DEBUG_FRAME_SECTION, DEBUG_INFO_SECTION, DEBUG_ABBREV_SECTION,
DEBUG_ARANGES_SECTION, DEBUG_MACINFO_SECTION, DEBUG_LINE_SECTION,
DEBUG_LOC_SECTION, DEBUG_PUBNAMES_SECTION, DEBUG_STR_SECTION,
DEBUG_RANGES_SECTION): Define.
Radar 3657068.
Co-Authored-By: Devang Patel <dpatel@apple.com>
From-SVN: r82016
Diffstat (limited to 'gcc/config')
-rw-r--r-- | gcc/config/darwin-protos.h | 2 | ||||
-rw-r--r-- | gcc/config/darwin.c | 14 | ||||
-rw-r--r-- | gcc/config/darwin.h | 15 |
3 files changed, 26 insertions, 5 deletions
diff --git a/gcc/config/darwin-protos.h b/gcc/config/darwin-protos.h index 845a828..1cfdd73 100644 --- a/gcc/config/darwin-protos.h +++ b/gcc/config/darwin-protos.h @@ -76,7 +76,7 @@ extern void darwin_asm_named_section (const char *, unsigned int); extern unsigned int darwin_section_type_flags (tree, const char *, int); extern void darwin_non_lazy_pcrel (FILE *, rtx); -extern void darwin_emit_unwind_label(FILE *, tree, int); +extern void darwin_emit_unwind_label (FILE *, tree, int, int); extern void darwin_pragma_ignore (struct cpp_reader *); extern void darwin_pragma_options (struct cpp_reader *); diff --git a/gcc/config/darwin.c b/gcc/config/darwin.c index a626045..89e11de 100644 --- a/gcc/config/darwin.c +++ b/gcc/config/darwin.c @@ -1334,10 +1334,12 @@ darwin_unique_section (tree decl, int reloc ATTRIBUTE_UNUSED) } /* Emit a label for an FDE, making it global and/or weak if appropriate. - The third parameter is nonzero if this is just a placeholder for an + The third parameter is nonzero if this is for exception handling. + The fourth parameter is nonzero if this is just a placeholder for an FDE that we are omitting. */ + void -darwin_emit_unwind_label(FILE *file, tree decl, int empty) +darwin_emit_unwind_label (FILE *file, tree decl, int for_eh, int empty) { tree id = DECL_ASSEMBLER_NAME (decl) ? DECL_ASSEMBLER_NAME (decl) @@ -1350,12 +1352,15 @@ darwin_emit_unwind_label(FILE *file, tree decl, int empty) unsigned int base_len = IDENTIFIER_LENGTH (id); const char *suffix = ".eh"; - unsigned int suffix_len = 3; int need_quotes = name_needs_quotes (base); int quotes_len = need_quotes ? 2 : 0; + char *lab; + + if (! for_eh) + suffix = ".eh1"; - char *lab = xmalloc (prefix_len + base_len + suffix_len + quotes_len + 1); + lab = xmalloc (prefix_len + base_len + strlen (suffix) + quotes_len + 1); lab[0] = '\0'; if (need_quotes) @@ -1385,6 +1390,7 @@ darwin_emit_unwind_label(FILE *file, tree decl, int empty) } /* Generate a PC-relative reference to a Mach-O non-lazy-symbol. */ + void darwin_non_lazy_pcrel (FILE *file, rtx addr) { diff --git a/gcc/config/darwin.h b/gcc/config/darwin.h index de8d0c4..67bb294 100644 --- a/gcc/config/darwin.h +++ b/gcc/config/darwin.h @@ -304,6 +304,21 @@ Boston, MA 02111-1307, USA. */ #define DBX_DEBUGGING_INFO 1 +/* Also enable Dwarf 2 as an option. */ +#define DWARF2_DEBUGGING_INFO +#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG + +#define DEBUG_FRAME_SECTION "__DWARFA,__debug_frame,coalesced,no_toc+strip_static_syms" +#define DEBUG_INFO_SECTION "__DWARFA,__debug_info" +#define DEBUG_ABBREV_SECTION "__DWARFA,__debug_abbrev" +#define DEBUG_ARANGES_SECTION "__DWARFA,__debug_aranges" +#define DEBUG_MACINFO_SECTION "__DWARFA,__debug_macinfo" +#define DEBUG_LINE_SECTION "__DWARFA,__debug_line" +#define DEBUG_LOC_SECTION "__DWARFA,__debug_loc" +#define DEBUG_PUBNAMES_SECTION "__DWARFA,__debug_pubnames" +#define DEBUG_STR_SECTION "__DWARFA,__debug_str" +#define DEBUG_RANGES_SECTION "__DWARFA,__debug_ranges" + /* When generating stabs debugging, use N_BINCL entries. */ #define DBX_USE_BINCL |