================
@@ -359,6 +357,12 @@ void MCELFStreamer::finalizeCGProfile() {
}
void MCELFStreamer::finishImpl() {
+ // Emit .note.GNU-stack, similar to AsmPrinter::doFinalization.
+ if (const MCTargetOptions *TO = getContext().getTargetOptions())
+ if (TO->MCNoExecStack)
+ switchSection(getContext().getAsmInfo()->getStackSection(getContext(),
+
/*Exec=*/false));
----------------
MaskRay wrote:
Thanks for catching this! Solaris's -filetype=obj would fail
(https://reviews.llvm.org/D159179). Added a test case.
https://github.com/llvm/llvm-project/pull/187880
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits