[PATCH] D74634: Remove "ELF Only" restriction from section flags
rnk created this revision. rnk added reviewers: hans, aaron.ballman. Herald added subscribers: sunfish, aheejin. Herald added a project: clang. -ffunction-sections and -fdata-sections are well supported by many object file formats: - ELF - COFF - XCOFF - wasm Only MachO ignores this flag. While here, remove it from -funique-section-names. Wasm honors this option. Addresses PR44910. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D74634 Files: clang/include/clang/Driver/Options.td Index: clang/include/clang/Driver/Options.td === --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -1952,10 +1952,10 @@ def fzero_initialized_in_bss : Flag<["-"], "fzero-initialized-in-bss">, Group; def ffunction_sections : Flag<["-"], "ffunction-sections">, Group, Flags<[CC1Option]>, - HelpText<"Place each function in its own section (ELF Only)">; + HelpText<"Place each function in its own section">; def fno_function_sections : Flag<["-"], "fno-function-sections">, Group; def fdata_sections : Flag <["-"], "fdata-sections">, Group, - Flags<[CC1Option]>, HelpText<"Place each data in its own section (ELF Only)">; + Flags<[CC1Option]>, HelpText<"Place each data in its own section">; def fno_data_sections : Flag <["-"], "fno-data-sections">, Group; def fstack_size_section : Flag<["-"], "fstack-size-section">, Group, Flags<[CC1Option]>, HelpText<"Emit section containing metadata on function stack sizes">; @@ -1964,7 +1964,7 @@ def funique_section_names : Flag <["-"], "funique-section-names">, Group, - HelpText<"Use unique names for text and data sections (ELF Only)">; + HelpText<"Use unique names for text and data sections">; def fno_unique_section_names : Flag <["-"], "fno-unique-section-names">, Group, Flags<[CC1Option]>; Index: clang/include/clang/Driver/Options.td === --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -1952,10 +1952,10 @@ def fzero_initialized_in_bss : Flag<["-"], "fzero-initialized-in-bss">, Group; def ffunction_sections : Flag<["-"], "ffunction-sections">, Group, Flags<[CC1Option]>, - HelpText<"Place each function in its own section (ELF Only)">; + HelpText<"Place each function in its own section">; def fno_function_sections : Flag<["-"], "fno-function-sections">, Group; def fdata_sections : Flag <["-"], "fdata-sections">, Group, - Flags<[CC1Option]>, HelpText<"Place each data in its own section (ELF Only)">; + Flags<[CC1Option]>, HelpText<"Place each data in its own section">; def fno_data_sections : Flag <["-"], "fno-data-sections">, Group; def fstack_size_section : Flag<["-"], "fstack-size-section">, Group, Flags<[CC1Option]>, HelpText<"Emit section containing metadata on function stack sizes">; @@ -1964,7 +1964,7 @@ def funique_section_names : Flag <["-"], "funique-section-names">, Group, - HelpText<"Use unique names for text and data sections (ELF Only)">; + HelpText<"Use unique names for text and data sections">; def fno_unique_section_names : Flag <["-"], "fno-unique-section-names">, Group, Flags<[CC1Option]>; ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D74634: Remove "ELF Only" restriction from section flags
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74634/new/ https://reviews.llvm.org/D74634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D74634: Remove "ELF Only" restriction from section flags
hans accepted this revision. hans added a comment. In the commit message, which is currently "Remove "ELF Only" restriction from section flags" maybe add "help text" or something to make it obvious this only changes the help text -- i.e. it's not removing any actual "elf only" restriction. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74634/new/ https://reviews.llvm.org/D74634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D74634: Remove "ELF Only" restriction from section flags
This revision was automatically updated to reflect the committed changes. Closed by commit rGa0a1f412fd1d: Remove "ELF Only" from -f*-sections help text (authored by rnk). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74634/new/ https://reviews.llvm.org/D74634 Files: clang/include/clang/Driver/Options.td Index: clang/include/clang/Driver/Options.td === --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -1952,10 +1952,10 @@ def fzero_initialized_in_bss : Flag<["-"], "fzero-initialized-in-bss">, Group; def ffunction_sections : Flag<["-"], "ffunction-sections">, Group, Flags<[CC1Option]>, - HelpText<"Place each function in its own section (ELF Only)">; + HelpText<"Place each function in its own section">; def fno_function_sections : Flag<["-"], "fno-function-sections">, Group; def fdata_sections : Flag <["-"], "fdata-sections">, Group, - Flags<[CC1Option]>, HelpText<"Place each data in its own section (ELF Only)">; + Flags<[CC1Option]>, HelpText<"Place each data in its own section">; def fno_data_sections : Flag <["-"], "fno-data-sections">, Group; def fstack_size_section : Flag<["-"], "fstack-size-section">, Group, Flags<[CC1Option]>, HelpText<"Emit section containing metadata on function stack sizes">; @@ -1964,7 +1964,7 @@ def funique_section_names : Flag <["-"], "funique-section-names">, Group, - HelpText<"Use unique names for text and data sections (ELF Only)">; + HelpText<"Use unique names for text and data sections">; def fno_unique_section_names : Flag <["-"], "fno-unique-section-names">, Group, Flags<[CC1Option]>; Index: clang/include/clang/Driver/Options.td === --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -1952,10 +1952,10 @@ def fzero_initialized_in_bss : Flag<["-"], "fzero-initialized-in-bss">, Group; def ffunction_sections : Flag<["-"], "ffunction-sections">, Group, Flags<[CC1Option]>, - HelpText<"Place each function in its own section (ELF Only)">; + HelpText<"Place each function in its own section">; def fno_function_sections : Flag<["-"], "fno-function-sections">, Group; def fdata_sections : Flag <["-"], "fdata-sections">, Group, - Flags<[CC1Option]>, HelpText<"Place each data in its own section (ELF Only)">; + Flags<[CC1Option]>, HelpText<"Place each data in its own section">; def fno_data_sections : Flag <["-"], "fno-data-sections">, Group; def fstack_size_section : Flag<["-"], "fstack-size-section">, Group, Flags<[CC1Option]>, HelpText<"Emit section containing metadata on function stack sizes">; @@ -1964,7 +1964,7 @@ def funique_section_names : Flag <["-"], "funique-section-names">, Group, - HelpText<"Use unique names for text and data sections (ELF Only)">; + HelpText<"Use unique names for text and data sections">; def fno_unique_section_names : Flag <["-"], "fno-unique-section-names">, Group, Flags<[CC1Option]>; ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits