[PATCH] D113771: [ELF] Support the "read-only" memory region attribute
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 22 11:24:49 PST 2021
MaskRay added inline comments.
================
Comment at: lld/ELF/LinkerScript.h:145
+ // ... or any of these flags are not set.
+ uint32_t invFlags;
+ // A section cannot be assigned to the region if any of these flags are set...
----------------
peter.smith wrote:
> Could be worth an example.
> // ... or any of these flags are not set. For example the linker script `r` maps to ~SHF_WRITE.
The `~` notation in `~SHF_WRITE` may be ambiguous. It is not the bitwise operation in regular C++ programs.
Since the comment applies to invFlags, I think `~` can be omitted.
Ditto for `negInvFlags` below.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D113771/new/
https://reviews.llvm.org/D113771
More information about the llvm-commits
mailing list