public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Iain D Sandoe <iains@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r11-3769] Darwin : Only emit Objective-C section switches for older linkers. Date: Sat, 10 Oct 2020 16:24:15 +0000 (GMT) [thread overview] Message-ID: <20201010162415.A09463857C52@sourceware.org> (raw) https://gcc.gnu.org/g:bb675539ba2f661c6bfab258847b41798a449432 commit r11-3769-gbb675539ba2f661c6bfab258847b41798a449432 Author: Iain Sandoe <iain@sandoe.co.uk> Date: Sat Oct 3 13:51:29 2020 +0100 Darwin : Only emit Objective-C section switches for older linkers. At one time, the system linkers needed to have at least a dummy entry for every Objective-C section in use. This removes the extra emitted code when it is not needed by the linker. gcc/ChangeLog: * config/darwin.c (output_objc_section_asm_op): Avoid extra objective-c section switches unless the linker needs them. Diff: --- gcc/config/darwin.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gcc/config/darwin.c b/gcc/config/darwin.c index e101f8eb655..370ee5cedaa 100644 --- a/gcc/config/darwin.c +++ b/gcc/config/darwin.c @@ -136,7 +136,7 @@ output_objc_section_asm_op (const void *directive) order in the object. The code below implements this by emitting a section header for each ObjC section the first time that an ObjC section is requested. */ - if (! been_here) + if (darwin_symbol_stubs && ! been_here) { section *saved_in_section = in_section; static const enum darwin_section_enum tomark[] = @@ -176,20 +176,21 @@ output_objc_section_asm_op (const void *directive) { objc2_method_names_section, objc2_message_refs_section, + objc2_selector_refs_section, + objc2_ivar_section, objc2_classdefs_section, objc2_metadata_section, objc2_classrefs_section, objc2_class_names_section, objc2_classlist_section, objc2_categorylist_section, - objc2_selector_refs_section, objc2_nonlazy_class_section, objc2_nonlazy_category_section, objc2_protocollist_section, objc2_protocolrefs_section, objc2_super_classrefs_section, + objc2_constant_string_object_section, objc2_image_info_section, - objc2_constant_string_object_section } ; size_t i;
reply other threads:[~2020-10-10 16:24 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20201010162415.A09463857C52@sourceware.org \ --to=iains@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).