[PATCH] D21995: [ELF] Implement minimal PHDRS parser and section-to-segment assignment

Eugene Leviant via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 12 06:58:58 PDT 2016


evgeny777 added inline comments.

================
Comment at: ELF/LinkerScript.cpp:286
@@ +285,3 @@
+  ssize_t RelroNum = -1;
+  Phdr *Load = nullptr;
+  uintX_t Flags = PF_R;
----------------
ssize_t is not (definitly) int.
It is normally used to hold either size or error.

================
Comment at: ELF/Writer.h:36
@@ +35,3 @@
+// Each contains type, access flags and range of output sections that will be
+// placed in it.
+template<class ELFT>
----------------
It's been clang-format'ted

================
Comment at: test/ELF/linkerscript-phdrs.s:17
@@ +16,3 @@
+# CHECK-NEXT:      PF_R (0x4)
+# CHECK-NEXT:      PF_W (0x2)
+# CHECK-NEXT:      PF_X (0x1)
----------------
Hmm. Have you tried this:
```
grep PF_R test/ELF/*.s
```



Repository:
  rL LLVM

http://reviews.llvm.org/D21995





More information about the llvm-commits mailing list