[PATCH] D14218: [ELF2] Implements -z relro: create an ELF "PT_GNU_RELRO" segment header in the object.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 18 23:26:13 PST 2015


grimar added inline comments.

================
Comment at: ELF/Writer.cpp:371
@@ +370,3 @@
+    return Config->ZNow;
+  StringRef WhiteList[] = {".data.rel.ro", ".ctors", ".dtors",  ".jcr",
+                           ".eh_frame",    ".got",   ".dynamic"};
----------------
rafael wrote:
> Check for &Dynamic and &Got instead of the names.
I tried that and the above when developed it to see and that made method to look a bit more bulky. It adds one more _if_ section and for me comparing of names looks better since we anyways unable to get rid of that at all and dont plan to rename the sections ever.
So do you think its really be better to do ?


http://reviews.llvm.org/D14218





More information about the llvm-commits mailing list