[PATCH] D67759: [llvm-readobj] - Simplify stack-sizes.test test case.

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 19 05:22:45 PDT 2019


grimar created this revision.
grimar added reviewers: jhenderson, MaskRay.
Herald added subscribers: seiya, rupprecht.

This is a follow-up for D67757 <https://reviews.llvm.org/D67757>,
which allows to describe `.stack_sizes` sections with a new
YAML syntax.

Depends on D67757 <https://reviews.llvm.org/D67757>.


https://reviews.llvm.org/D67759

Files:
  test/tools/llvm-readobj/stack-sizes.test


Index: test/tools/llvm-readobj/stack-sizes.test
===================================================================
--- test/tools/llvm-readobj/stack-sizes.test
+++ test/tools/llvm-readobj/stack-sizes.test
@@ -28,14 +28,15 @@
     Size:    16
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
-## 2 stack size entries. Each consists of an address (subject to relocation)
-## followed by a ULEB for the size.
-    Content: "000000000000000010000000000000000020"
+    Entries:
+      - Size: 0x10
+      - Size: 0x20
     Link:    .text
   - Name:    .stack_sizes.baz
     Type:    SHT_PROGBITS
-## One stack size entry.
-    Content: "200000000000000008"
+    Entries:
+      - Address: 0x20
+        Size:    0x8
     Link:    .text.baz
   - Name:    .rela.stack_sizes
     Type:    SHT_RELA
@@ -99,7 +100,11 @@
     Size:    16
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
-    Content: "100000000000000010200000000000000020"
+    Entries:
+      - Address: 0x10
+        Size:    0x10
+      - Address: 0x20
+        Size:    0x20
     Link:    .text
 Symbols:
   - Name:    foo
@@ -176,7 +181,8 @@
     Flags:   [SHF_ALLOC]
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
-    Content: "000000000000000008"
+    Entries:
+      - Size: 0x8
     Link:    .text2
   - Name:    .rela.stack_sizes
     Type:    SHT_RELA
@@ -276,7 +282,8 @@
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
     Link:    .text
-    Content: "000000000000000008"
+    Entries:
+      - Size: 0x8
   - Name:    .rela.stack_sizes
     Type:    SHT_RELA
     Info:    .stack_sizes
@@ -315,7 +322,8 @@
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
     Link:    .text
-    Content: "000000000000000008"
+    Entries:
+      - Size: 0x1
 
 ## Check that we handle multiple object files, separately and when they
 ## are in an archive. This also checks whether we have blank lines between the
@@ -459,7 +467,9 @@
     Size:    16
   - Name:    .stack_sizes
     Type:    SHT_PROGBITS
-    Content: "100000000000000010"
+    Entries:
+      - Address: 0x10
+        Size:    0x10
     Link:    .text
 Symbols:
   - Name:    _Z3foof


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67759.220842.patch
Type: text/x-patch
Size: 2137 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190919/42de919d/attachment.bin>


More information about the llvm-commits mailing list