[PATCH] D107216: Revert [MC][ELF] Emit separate unique sections for different flags
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 31 01:16:59 PDT 2021
nikic created this revision.
nikic added reviewers: tmatheson, bd1976llvm, peter.smith, MaskRay.
Herald added subscribers: pengfei, atanasyan, jrtc27, JDevlieghere, hiraditya, sdardis.
nikic requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
D100944 <https://reviews.llvm.org/D100944> broke the ability to specify custom section flags in LLVM IR by including an empty section with the desired flags in module asm. This functionality is used by rustc to embed LTO bitcode with the SHF_EXCLUDE flag, and currently blocks our evaluation of the LLVM 13 release. As the post-commit discussion on D100944 <https://reviews.llvm.org/D100944> indicates, other people were using this functionality as well: https://reviews.llvm.org/D100944#2840948
This reverts D100944 <https://reviews.llvm.org/D100944> to restore the ability to set section flags. The change from D100944 <https://reviews.llvm.org/D100944> can be reapplied once LLVM provides an alternative way to specify section flags -- it would certainly be better if it were possible to do this using a dedicated IR construct. But I don't think it's possible to add such a construct for the LLVM 13 release anymore, so this reverts to the status quo.
Fixes https://bugs.llvm.org/show_bug.cgi?id=51207.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D107216
Files:
llvm/include/llvm/MC/MCContext.h
llvm/lib/MC/MCContext.cpp
llvm/test/CodeGen/Mips/gpopt-explict-section.ll
llvm/test/CodeGen/X86/elf-unique-sections-by-flags.ll
llvm/test/CodeGen/X86/explicit-section-mergeable.ll
llvm/unittests/ExecutionEngine/Orc/RTDyldObjectLinkingLayerTest.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D107216.363277.patch
Type: text/x-patch
Size: 25167 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210731/33f15d18/attachment.bin>
More information about the llvm-commits
mailing list