[PATCH] D65722: [ELF] Expand regions for gaps due to explicit address

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 4 19:32:23 PDT 2019


MaskRay added inline comments.


================
Comment at: lld/test/ELF/linkerscript/section-gap-explicit-expr.test:7
+
+# RUN: llvm-objdump -section-headers %t2 | FileCheck %s
+# CHECK: .aaa_s 00000008 0000000000000000 DATA
----------------
single-dash long options are discouraged in llvm-objdump. Use `-h` or `--section-headers`. I would use `llvm-readelf -S`.




================
Comment at: lld/test/ELF/linkerscript/section-gap-explicit-expr.test:16
+SECTIONS {
+  .aaa_s ORIGIN(REGION) :
+  {
----------------
`ORIGIN(REGION)` is not important in this test. You can just write:

```
SECTIONS {
  .aaa_s 0 : { *(.aaa) } > REGION
  .bbb_s 0x14 : { *(.bbb) } > REGION
}
```

There is no need to copy out-of-order-section-in-region.test. How about renaming to `memory-*`? There are several memory region tests named `memory-*` now. It'd be ideal to have a single dedicated prefix for these tests.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65722/new/

https://reviews.llvm.org/D65722





More information about the llvm-commits mailing list