[PATCH] D27449: [ARM] Implement execute-only support in CodeGen
Renato Golin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 8 04:49:02 PST 2016
rengolin added inline comments.
================
Comment at: include/llvm/MC/SectionKind.h:32
+ /// ExecuteOnly, Text section that is not readable.
+ ExecuteOnly,
+
----------------
prakhar wrote:
> rengolin wrote:
> > No TABs, please. Use clang-format on your patch to make sure it adheres to the coding standard.
> This isn't a tab character. Unless you meant that ExecuteOnly should be placed at the same indent level as Text?
yup
================
Comment at: lib/Target/ARM/ARMTargetObjectFile.cpp:49
+ // Use 0 as the unique ID for execute-only text
+ TextSection = Ctx.getELFSection(".text", Type, Flags, 0, "", 0U);
+ }
----------------
prakhar wrote:
> rengolin wrote:
> > Where is the TextSection initialised if it's not pure? Shouldn't this move to the same place?
> We cannot change the flags of an existing section, so we create a new text section with the flags set in addition to the default one.
Oh, I see. I think this deserves a nice comment. :)
https://reviews.llvm.org/D27449
More information about the llvm-commits
mailing list