// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %s -o %t
// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %S/Inputs/far-arm-thumb-abs.s -o %tfar
// RUN: echo "SECTIONS { \
+// RUN: . = 0xb4; \
// RUN: .callee1 : { *(.callee_low) } \
// RUN: .callee2 : { *(.callee_arm_low) } \
// RUN: .caller : { *(.text) } \
// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %s -o %t
// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %S/Inputs/far-arm-abs.s -o %tfar
// RUN: echo "SECTIONS { \
+// RUN: . = 0xb4; \
// RUN: .callee1 : { *(.callee_low) } \
// RUN: .caller : { *(.text) } \
// RUN: .callee2 : { *(.callee_high) } } " > %t.script
// RUN: llvm-mc -filetype=obj -triple=thumbv7a-none-linux-gnueabi %s -o %t
// RUN: llvm-mc -filetype=obj -triple=thumbv7a-none-linux-gnueabi %S/Inputs/far-arm-thumb-abs.s -o %tfar
// RUN: echo "SECTIONS { \
+// RUN: . = 0xb4; \
// RUN: .callee1 : { *(.callee_low) } \
// RUN: .caller : { *(.text) } \
// RUN: .callee2 : { *(.callee_high) } } " > %t.script
# RUN: ld.lld -o %t1 --eh-frame-hdr --script %t.script %t
# RUN: llvm-objdump -s -section=".eh_frame_hdr" %t1 | FileCheck %s
-# CHECK: 0158 011b033b 14000000 01000000 49000000
-# CHECK-NEXT: 0168 30000000
+# CHECK: 011b033b 14000000 01000000 49000000
+# CHECK-NEXT: 30000000
.global _start
_start:
# RUN: llvm-objdump -s %t1.o | FileCheck %s
# CHECK: Contents of section .foo:
-# CHECK-NEXT: 0120 01000000 00000000 04000000 00000000
-# CHECK-NEXT: 0130 07000000 00000000 05000000 00000000
-# CHECK-NEXT: 0140 08000000 00000000 03000000 00000000
-# CHECK-NEXT: 0150 09000000 00000000
+# CHECK-NEXT: 01000000 00000000 04000000 00000000
+# CHECK-NEXT: 07000000 00000000 05000000 00000000
+# CHECK-NEXT: 08000000 00000000 03000000 00000000
+# CHECK-NEXT: 09000000 00000000
# CHECK-NEXT: Contents of section .foo.2:
-# CHECK-NEXT: 0158 02000000 00000000
+# CHECK-NEXT: 02000000 00000000
# CHECK-NEXT: Contents of section .foo.3:
-# CHECK-NEXT: 0160 06000000 00000000
+# CHECK-NEXT: 06000000 00000000
.section .foo.1,"a"
.quad 1
# RUN: ld.lld -o %t1 --script %t1.script %tfirst.o %tsecond.o
# RUN: llvm-objdump -s %t1 | FileCheck --check-prefix=FIRSTSECOND %s
# FIRSTSECOND: Contents of section .foo:
-# FIRSTSECOND-NEXT: 0120 01000000 00000000 11000000 00000000
+# FIRSTSECOND-NEXT: 01000000 00000000 11000000 00000000
# RUN: echo "SECTIONS { .foo : { \
# RUN: KEEP(*second.o(.foo)) \
# RUN: ld.lld -o %t2 --script %t2.script %tfirst.o %tsecond.o
# RUN: llvm-objdump -s %t2 | FileCheck --check-prefix=SECONDFIRST %s
# SECONDFIRST: Contents of section .foo:
-# SECONDFIRST-NEXT: 0120 11000000 00000000 01000000 00000000
+# SECONDFIRST-NEXT: 11000000 00000000 01000000 00000000
## Now the same tests but without KEEP. Checking that file name inside
## KEEP is parsed fine.
# RUN: llvm-objdump -s %t | FileCheck %s
# CHECK: Contents of section .out:
-# CHECK-NEXT: 0120 aa222222 22bb2222 22222222 2222
+# CHECK-NEXT: aa222222 22bb2222 22222222 2222
.text
.globl _start
# RUN: ld.lld -o %t1 --script %t.script %t
# RUN: llvm-objdump -section-headers %t1 | FileCheck %s
# CHECK: Sections:
-# CHECK-NEXT: Idx Name Size Address Type
-# CHECK-NEXT: 0 00000000 0000000000000000
-# CHECK-NEXT: 1 .foo 00000004 0000000000000120 DATA
-# CHECK-NEXT: 2 .text 00000001 0000000000000124 TEXT DATA
+# CHECK-NEXT: Idx Name Size
+# CHECK-NEXT: 0 00000000
+# CHECK-NEXT: 1 .foo 00000004
+# CHECK-NEXT: 2 .text 00000001
.global _start
_start:
# CHECK-NEXT: SHF_MERGE
# CHECK-NEXT: SHF_STRINGS
# CHECK-NEXT: ]
-# CHECK-NEXT: Address: 0x1C8
-# CHECK-NEXT: Offset: 0x1C8
+# CHECK-NEXT: Address: 0x[[ADDR1:.*]]
+# CHECK-NEXT: Offset: 0x[[ADDR1]]
# CHECK-NEXT: Size: 4
# CHECK-NEXT: Link: 0
# CHECK-NEXT: Info: 0
# CHECK-NEXT: SHF_ALLOC
# CHECK-NEXT: SHF_MERGE
# CHECK-NEXT: ]
-# CHECK-NEXT: Address: 0x1CC
-# CHECK-NEXT: Offset: 0x1CC
+# CHECK-NEXT: Address: 0x
+# CHECK-NEXT: Offset: 0x
# CHECK-NEXT: Size: 1
# CHECK-NEXT: Link: 0
# CHECK-NEXT: Info: 0
# CHECK-NEXT: SHF_ALLOC
# CHECK-NEXT: SHF_MERGE
# CHECK-NEXT: ]
-# CHECK-NEXT: Address: 0x1CE
-# CHECK-NEXT: Offset: 0x1CE
+# CHECK-NEXT: Address: 0x
+# CHECK-NEXT: Offset: 0x
# CHECK-NEXT: Size: 2
# CHECK-NEXT: Link: 0
# CHECK-NEXT: Info: 0
# CHECK-NEXT: AddressAlignment: 2
# CHECK-NEXT: EntrySize: 2
+# CHECK-NEXT: }
+# CHECK-NEXT: Section {
+# CHECK-NEXT: Index:
+# CHECK-NEXT: Name:
+# CHECK-NEXT: Type:
+# CHECK-NEXT: Flags [
+# CHECK-NEXT: SHF_ALLOC
+# CHECK-NEXT: ]
+# CHECK-NEXT: Address: 0x[[ADDR2:.*]]
+# CHECK-NEXT: Offset: 0x[[ADDR2]]
# CHECK: Name: begin
-# CHECK-NEXT: Value: 0x1C8
+# CHECK-NEXT: Value: 0x[[ADDR1]]
# CHECK: Name: end
-# CHECK-NEXT: Value: 0x1D0
+# CHECK-NEXT: Value: 0x[[ADDR2]]
.section .foo.1a,"aMS",@progbits,1
.asciz "foo"
# RUN: llvm-objdump -section-headers %t1 | \
# RUN: FileCheck -check-prefix=BASE %s
# BASE: Sections:
-# BASE-NEXT: Idx Name Size Address Type
-# BASE-NEXT: 0 00000000 0000000000000000
-# BASE-NEXT: 1 .writable 00000004 0000000000000200 DATA
-# BASE-NEXT: 2 .readable 00000004 0000000000000204 DATA
+# BASE-NEXT: Idx Name Size
+# BASE-NEXT: 0 00000000
+# BASE-NEXT: 1 .writable 00000004
+# BASE-NEXT: 2 .readable 00000004
# RUN: echo "SECTIONS { \
# RUN: .foo : ONLY_IF_RO { *(.foo.*) } \
# RUN: llvm-objdump -section-headers %t2 | \
# RUN: FileCheck -check-prefix=NO1 %s
# NO1: Sections:
-# NO1-NEXT: Idx Name Size Address Type
-# NO1-NEXT: 0 00000000 0000000000000000
-# NO1-NEXT: 1 .writable 00000004 0000000000000200 DATA
-# NO1-NEXT: 2 .readable 00000004 0000000000000204 DATA
-# NO1-NEXT: 3 .text 00000001 0000000000000208 TEXT DATA
-# NO1-NEXT: 4 .foo.2 00000004 0000000000000209 DATA
-# NO1-NEXT: 5 .foo.1 00000004 000000000000020d TEXT DATA
+# NO1-NEXT: Idx Name Size
+# NO1-NEXT: 0 00000000
+# NO1-NEXT: 1 .writable 00000004
+# NO1-NEXT: 2 .readable 00000004
+# NO1-NEXT: 3 .text 00000001
+# NO1-NEXT: 4 .foo.2 00000004
+# NO1-NEXT: 5 .foo.1 00000004
.global _start
_start:
# RUN: llvm-objdump -section-headers %t1 | \
# RUN: FileCheck -check-prefix=SECGC %s
# SECGC: Sections:
-# SECGC-NEXT: Idx Name Size Address Type
-# SECGC-NEXT: 0 00000000 0000000000000000
-# SECGC-NEXT: 1 .text 00000007 0000000000000158 TEXT DATA
-# SECGC-NEXT: 2 .temp 00000004 000000000000015f DATA
+# SECGC-NEXT: Idx Name Size
+# SECGC-NEXT: 0 00000000
+# SECGC-NEXT: 1 .text 00000007
+# SECGC-NEXT: 2 .temp 00000004
## Now apply KEEP command to preserve the section.
# RUN: echo "SECTIONS { \
# RUN: llvm-objdump -section-headers %t1 | \
# RUN: FileCheck -check-prefix=SECNOGC %s
# SECNOGC: Sections:
-# SECNOGC-NEXT: Idx Name Size Address Type
-# SECNOGC-NEXT: 0 00000000 0000000000000000
-# SECNOGC-NEXT: 1 .text 00000007 0000000000000158 TEXT DATA
-# SECNOGC-NEXT: 2 .keep 00000004 000000000000015f DATA
-# SECNOGC-NEXT: 3 .temp 00000004 0000000000000163 DATA
+# SECNOGC-NEXT: Idx Name Size
+# SECNOGC-NEXT: 0 00000000
+# SECNOGC-NEXT: 1 .text 00000007
+# SECNOGC-NEXT: 2 .keep 00000004
+# SECNOGC-NEXT: 3 .temp 00000004
## A section name matches two entries in the SECTIONS directive. The
## first one doesn't have KEEP, the second one does. If section that have
# RUN: ld.lld --gc-sections -o %t1 --script %t.script %t
# RUN: llvm-objdump -section-headers %t1 | FileCheck -check-prefix=MIXED1 %s
# MIXED1: Sections:
-# MIXED1-NEXT: Idx Name Size Address Type
-# MIXED1-NEXT: 0 00000000 0000000000000000
-# MIXED1-NEXT: 1 .keep 00000004 0000000000000120 DATA
-# MIXED1-NEXT: 2 .temp 00000004 0000000000000124 DATA
-# MIXED1-NEXT: 3 .text 00000007 0000000000000128 TEXT DATA
-# MIXED1-NEXT: 4 .symtab 00000060 0000000000000000
-# MIXED1-NEXT: 5 .shstrtab 0000002d 0000000000000000
-# MIXED1-NEXT: 6 .strtab 00000012 0000000000000000
+# MIXED1-NEXT: Idx Name Size
+# MIXED1-NEXT: 0 00000000
+# MIXED1-NEXT: 1 .keep 00000004
+# MIXED1-NEXT: 2 .temp 00000004
+# MIXED1-NEXT: 3 .text 00000007
+# MIXED1-NEXT: 4 .symtab 00000060
+# MIXED1-NEXT: 5 .shstrtab 0000002d
+# MIXED1-NEXT: 6 .strtab 00000012
## The same, but now section without KEEP is at first place.
## gold and bfd linkers disagree here. gold collects .keep while
# RUN: ld.lld --gc-sections -o %t1 --script %t.script %t
# RUN: llvm-objdump -section-headers %t1 | FileCheck -check-prefix=MIXED2 %s
# MIXED2: Sections:
-# MIXED2-NEXT: Idx Name Size Address Type
-# MIXED2-NEXT: 0 00000000 0000000000000000
-# MIXED2-NEXT: 1 .nokeep 00000004 0000000000000120 DATA
-# MIXED2-NEXT: 2 .temp 00000004 0000000000000124 DATA
-# MIXED2-NEXT: 3 .text 00000007 0000000000000128 TEXT DATA
-# MIXED2-NEXT: 4 .symtab 00000060 0000000000000000
-# MIXED2-NEXT: 5 .shstrtab 0000002f 0000000000000000
-# MIXED2-NEXT: 6 .strtab 00000012 0000000000000000
+# MIXED2-NEXT: Idx Name Size
+# MIXED2-NEXT: 0 00000000
+# MIXED2-NEXT: 1 .nokeep 00000004
+# MIXED2-NEXT: 2 .temp 00000004
+# MIXED2-NEXT: 3 .text 00000007
+# MIXED2-NEXT: 4 .symtab 00000060
+# MIXED2-NEXT: 5 .shstrtab 0000002f
+# MIXED2-NEXT: 6 .strtab 00000012
.global _start
_start:
# RUN: echo "SECTIONS { .mysec : { *(.mysec*) } =0x1122 }" > %t.script
# RUN: ld.lld -o %t.out --script %t.script %t
# RUN: llvm-objdump -s %t.out | FileCheck -check-prefix=YES %s
-# YES: 0120 66001122 00001122 00001122 00001122
+# YES: 66001122 00001122 00001122 00001122
## Confirming that address was correct:
# RUN: echo "SECTIONS { .mysec : { *(.mysec*) } =0x99887766 }" > %t.script
# RUN: ld.lld -o %t.out --script %t.script %t
# RUN: llvm-objdump -s %t.out | FileCheck -check-prefix=YES2 %s
-# YES2: 0120 66887766 99887766 99887766 99887766
+# YES2: 66887766 99887766 99887766 99887766
## Default padding value is 0x00:
# RUN: echo "SECTIONS { .mysec : { *(.mysec*) } }" > %t.script
# RUN: ld.lld -o %t.out --script %t.script %t
# RUN: llvm-objdump -s %t.out | FileCheck -check-prefix=NO %s
-# NO: 0120 66000000 00000000 00000000 00000000
+# NO: 66000000 00000000 00000000 00000000
## Decimal value.
# RUN: echo "SECTIONS { .mysec : { *(.mysec*) } =777 }" > %t.script
# RUN: ld.lld -o %t.out --script %t.script %t
# RUN: llvm-objdump -s %t.out | FileCheck -check-prefix=DEC %s
-# DEC: 0120 66000309 00000309 00000309 00000309
+# DEC: 66000309 00000309 00000309 00000309
## Invalid hex value:
# RUN: echo "SECTIONS { .mysec : { *(.mysec*) } =0x99XX }" > %t.script
# RUN: ld.lld -o %t1 --script %t.script %t
# RUN: llvm-objdump -t -section-headers %t1 | FileCheck %s
# CHECK: Sections:
-# CHECK-NEXT: Idx Name Size Address Type
-# CHECK-NEXT: 0 00000000 0000000000000000
-# CHECK-NEXT: 1 .aaa 00000008 0000000000000120 DATA
-# CHECK-NEXT: 2 .bbb 00000010 0000000000000128 DATA
-# CHECK-NEXT: 3 .ccc 00000018 0000000000000138 DATA
+# CHECK-NEXT: Idx Name Size
+# CHECK-NEXT: 0 00000000
+# CHECK-NEXT: 1 .aaa 00000008
+# CHECK-NEXT: 2 .bbb 00000010
+# CHECK-NEXT: 3 .ccc 00000018
# CHECK: SYMBOL TABLE:
# CHECK-NEXT: 0000000000000000 *UND* 00000000
-# CHECK-NEXT: 0000000000000150 .text 00000000 _start
+# CHECK-NEXT: .text 00000000 _start
# CHECK-NEXT: 0000000000000008 *ABS* 00000000 _aaa
# CHECK-NEXT: 0000000000000010 *ABS* 00000000 _bbb
# CHECK-NEXT: 0000000000000018 *ABS* 00000000 _ccc
# RUN: ld.lld -o %t1 --script %t1.script %t1.o %t2.o
# RUN: llvm-objdump -s %t1 | FileCheck -check-prefix=SORTED_AN %s
# SORTED_AN: Contents of section .aaa:
-# SORTED_AN-NEXT: 0120 01000000 00000000 00000000 00000000
-# SORTED_AN-NEXT: 0130 11000000 00000000 00000000 00000000
-# SORTED_AN-NEXT: 0140 55000000 00000000 22000000 00000000
-# SORTED_AN-NEXT: 0150 02000000 00000000
+# SORTED_AN-NEXT: 01000000 00000000 00000000 00000000
+# SORTED_AN-NEXT: 11000000 00000000 00000000 00000000
+# SORTED_AN-NEXT: 55000000 00000000 22000000 00000000
+# SORTED_AN-NEXT: 02000000 00000000
## Check sorting first by name and then by alignment.
# RUN: echo "SECTIONS { .aaa : { *(SORT_BY_NAME(SORT_BY_ALIGNMENT(.aaa.*))) } }" > %t2.script
# RUN: ld.lld -o %t1 --script %t1.script %t2.o %t1.o
# RUN: llvm-objdump -s %t1 | FileCheck -check-prefix=UNSORTED %s
# UNSORTED: Contents of section .aaa:
-# UNSORTED-NEXT: 0120 55000000 00000000 00000000 00000000
-# UNSORTED-NEXT: 0130 00000000 00000000 00000000 00000000
-# UNSORTED-NEXT: 0140 11000000 00000000 33000000 00000000
-# UNSORTED-NEXT: 0150 22000000 00000000 44000000 00000000
-# UNSORTED-NEXT: 0160 05000000 00000000 01000000 00000000
-# UNSORTED-NEXT: 0170 03000000 00000000 02000000 00000000
-# UNSORTED-NEXT: 0180 04000000 00000000
+# UNSORTED-NEXT: 55000000 00000000 00000000 00000000
+# UNSORTED-NEXT: 00000000 00000000 00000000 00000000
+# UNSORTED-NEXT: 11000000 00000000 33000000 00000000
+# UNSORTED-NEXT: 22000000 00000000 44000000 00000000
+# UNSORTED-NEXT: 05000000 00000000 01000000 00000000
+# UNSORTED-NEXT: 03000000 00000000 02000000 00000000
+# UNSORTED-NEXT: 04000000 00000000
## Check that SORT works (sorted by name of section).
# RUN: echo "SECTIONS { .aaa : { *(SORT(.aaa.*)) } }" > %t2.script
# RUN: ld.lld -o %t2 --script %t2.script %t2.o %t1.o
# RUN: llvm-objdump -s %t2 | FileCheck -check-prefix=SORTED_A %s
# SORTED_A: Contents of section .aaa:
-# SORTED_A-NEXT: 0120 11000000 00000000 01000000 00000000
-# SORTED_A-NEXT: 0130 22000000 00000000 02000000 00000000
-# SORTED_A-NEXT: 0140 33000000 00000000 03000000 00000000
-# SORTED_A-NEXT: 0150 44000000 00000000 00000000 00000000
-# SORTED_A-NEXT: 0160 04000000 00000000 55000000 00000000
-# SORTED_A-NEXT: 0170 00000000 00000000 00000000 00000000
-# SORTED_A-NEXT: 0180 05000000 00000000
+# SORTED_A-NEXT: 11000000 00000000 01000000 00000000
+# SORTED_A-NEXT: 22000000 00000000 02000000 00000000
+# SORTED_A-NEXT: 33000000 00000000 03000000 00000000
+# SORTED_A-NEXT: 44000000 00000000 00000000 00000000
+# SORTED_A-NEXT: 04000000 00000000 55000000 00000000
+# SORTED_A-NEXT: 00000000 00000000 00000000 00000000
+# SORTED_A-NEXT: 05000000 00000000
## When we switch the order of files, check that sorting by
## section names is stable.
# RUN: ld.lld -o %t3 --script %t3.script %t1.o %t2.o
# RUN: llvm-objdump -s %t3 | FileCheck -check-prefix=SORTED_B %s
# SORTED_B: Contents of section .aaa:
-# SORTED_B-NEXT: 0120 01000000 00000000 00000000 00000000
-# SORTED_B-NEXT: 0130 00000000 00000000 00000000 00000000
-# SORTED_B-NEXT: 0140 11000000 00000000 02000000 00000000
-# SORTED_B-NEXT: 0150 22000000 00000000 03000000 00000000
-# SORTED_B-NEXT: 0160 33000000 00000000 00000000 00000000
-# SORTED_B-NEXT: 0170 04000000 00000000 44000000 00000000
-# SORTED_B-NEXT: 0180 05000000 00000000 55000000 00000000
+# SORTED_B-NEXT: 01000000 00000000 00000000 00000000
+# SORTED_B-NEXT: 00000000 00000000 00000000 00000000
+# SORTED_B-NEXT: 11000000 00000000 02000000 00000000
+# SORTED_B-NEXT: 22000000 00000000 03000000 00000000
+# SORTED_B-NEXT: 33000000 00000000 00000000 00000000
+# SORTED_B-NEXT: 04000000 00000000 44000000 00000000
+# SORTED_B-NEXT: 05000000 00000000 55000000 00000000
## Check that SORT surrounded with KEEP also works.
# RUN: echo "SECTIONS { .aaa : { KEEP (*(SORT(.aaa.*))) } }" > %t3.script
# RUN: ld.lld -o %t5 --script %t5.script %t1.o %t2.o
# RUN: llvm-objdump -s %t5 | FileCheck -check-prefix=SORTED_ALIGNMENT %s
# SORTED_ALIGNMENT: Contents of section .aaa:
-# SORTED_ALIGNMENT-NEXT: 0120 05000000 00000000 00000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0130 00000000 00000000 00000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0140 11000000 00000000 00000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0150 04000000 00000000 00000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0160 22000000 00000000 03000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0170 33000000 00000000 02000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0180 44000000 00000000 01000000 00000000
-# SORTED_ALIGNMENT-NEXT: 0190 55000000 00000000
+# SORTED_ALIGNMENT-NEXT: 05000000 00000000 00000000 00000000
+# SORTED_ALIGNMENT-NEXT: 00000000 00000000 00000000 00000000
+# SORTED_ALIGNMENT-NEXT: 11000000 00000000 00000000 00000000
+# SORTED_ALIGNMENT-NEXT: 04000000 00000000 00000000 00000000
+# SORTED_ALIGNMENT-NEXT: 22000000 00000000 03000000 00000000
+# SORTED_ALIGNMENT-NEXT: 33000000 00000000 02000000 00000000
+# SORTED_ALIGNMENT-NEXT: 44000000 00000000 01000000 00000000
+# SORTED_ALIGNMENT-NEXT: 55000000 00000000
## SORT_NONE itself does not sort anything.
# RUN: echo "SECTIONS { .aaa : { *(SORT_NONE(.aaa.*)) } }" > %t6.script
# CHECK: SYMBOL TABLE:
# CHECK-NEXT: 0000000000000000 *UND* 00000000
-# CHECK-NEXT: 0000000000000120 .text 00000000 _start
-# CHECK-NEXT: 0000000000000121 .text 00000000 foo
+# CHECK-NEXT: .text 00000000 _start
+# CHECK-NEXT: .text 00000000 foo
# CHECK-NEXT: 0000000000200000 *ABS* 00000000 symbol
# CHECK-NEXT: 0000000000201234 *ABS* 00000000 symbol2
# CHECK-NEXT: 0000000000201234 *ABS* 00000000 symbol3
# RUN: echo "SECTIONS {.text : {*(.text.*)} text_end = .;}" > %t.script
# RUN: ld.lld -o %t1 --script %t.script %t
# RUN: llvm-objdump -t %t1 | FileCheck --check-prefix=SIMPLE %s
-# SIMPLE: 0000000000000121 *ABS* 00000000 text_end
+# SIMPLE: *ABS* 00000000 text_end
# The symbol is not referenced. Don't provide it.
# RUN: echo "SECTIONS { PROVIDE(newsym = 1);}" > %t.script
# RUN: llvm-objdump -section-headers %t.out | \
# RUN: FileCheck -check-prefix=SEC-DEFAULT %s
# SEC-DEFAULT: Sections:
-# SEC-DEFAULT-NEXT: Idx Name Size Address Type
-# SEC-DEFAULT-NEXT: 0 00000000 0000000000000000
-# SEC-DEFAULT-NEXT: 1 .text 00000008 0000000000000120 TEXT DATA
-# SEC-DEFAULT-NEXT: 2 .abcd 00000004 0000000000000128 TEXT DATA
-# SEC-DEFAULT-NEXT: 3 .ad 00000004 000000000000012c TEXT DATA
-# SEC-DEFAULT-NEXT: 4 .ag 00000004 0000000000000130 TEXT DATA
-# SEC-DEFAULT-NEXT: 5 .symtab 00000030 0000000000000000
-# SEC-DEFAULT-NEXT: 6 .shstrtab 0000002f 0000000000000000
-# SEC-DEFAULT-NEXT: 7 .strtab 00000008 0000000000000000
+# SEC-DEFAULT-NEXT: Idx Name Size
+# SEC-DEFAULT-NEXT: 0 00000000
+# SEC-DEFAULT-NEXT: 1 .text 00000008
+# SEC-DEFAULT-NEXT: 2 .abcd 00000004
+# SEC-DEFAULT-NEXT: 3 .ad 00000004
+# SEC-DEFAULT-NEXT: 4 .ag 00000004
+# SEC-DEFAULT-NEXT: 5 .symtab 00000030
+# SEC-DEFAULT-NEXT: 6 .shstrtab 0000002f
+# SEC-DEFAULT-NEXT: 7 .strtab 00000008
## Now replace the symbol with '?' and check that results are the same.
# RUN: echo "SECTIONS { \
# RUN: llvm-objdump -section-headers %t.out | \
# RUN: FileCheck -check-prefix=SEC-ALL %s
# SEC-ALL: Sections:
-# SEC-ALL-NEXT: Idx Name Size Address Type
-# SEC-ALL-NEXT: 0 00000000 0000000000000000
-# SEC-ALL-NEXT: 1 .text 0000000c 0000000000000120 TEXT DATA
-# SEC-ALL-NEXT: 2 .ad 00000004 000000000000012c TEXT DATA
-# SEC-ALL-NEXT: 3 .ag 00000004 0000000000000130 TEXT DATA
-# SEC-ALL-NEXT: 4 .symtab 00000030 0000000000000000
-# SEC-ALL-NEXT: 5 .shstrtab 00000029 0000000000000000
-# SEC-ALL-NEXT: 6 .strtab 00000008 0000000000000000
+# SEC-ALL-NEXT: Idx Name Size
+# SEC-ALL-NEXT: 0 00000000
+# SEC-ALL-NEXT: 1 .text 0000000c
+# SEC-ALL-NEXT: 2 .ad 00000004
+# SEC-ALL-NEXT: 3 .ag 00000004
+# SEC-ALL-NEXT: 4 .symtab 00000030
+# SEC-ALL-NEXT: 5 .shstrtab 00000029
+# SEC-ALL-NEXT: 6 .strtab 00000008
## All sections started with .a are merged.
# RUN: echo "SECTIONS { \
# RUN: llvm-objdump -section-headers %t.out | \
# RUN: FileCheck -check-prefix=SEC-NO %s
# SEC-NO: Sections:
-# SEC-NO-NEXT: Idx Name Size Address Type
-# SEC-NO-NEXT: 0 00000000 0000000000000000
-# SEC-NO-NEXT: 1 .text 00000014 0000000000000120 TEXT DATA
-# SEC-NO-NEXT: 2 .symtab 00000030 0000000000000000
-# SEC-NO-NEXT: 3 .shstrtab 00000021 0000000000000000
-# SEC-NO-NEXT: 4 .strtab 00000008 0000000000000000
+# SEC-NO-NEXT: Idx Name Size
+# SEC-NO-NEXT: 0 00000000
+# SEC-NO-NEXT: 1 .text 00000014
+# SEC-NO-NEXT: 2 .symtab 00000030
+# SEC-NO-NEXT: 3 .shstrtab 00000021
+# SEC-NO-NEXT: 4 .strtab 00000008
.text
.section .abc,"ax",@progbits
# RUN: llvm-objdump -section-headers %t.out | \
# RUN: FileCheck %s
# CHECK: Sections:
-# CHECK-NEXT: Idx Name Size Address Type
-# CHECK-NEXT: 0 00000000 0000000000000000
-# CHECK-NEXT: 1 .text 00000004 0000000000000120 TEXT DATA
-# CHECK-NEXT: 2 aabc 00000004 0000000000000124 TEXT DATA
+# CHECK-NEXT: Idx Name Size
+# CHECK-NEXT: 0 00000000
+# CHECK-NEXT: 1 .text 00000004
+# CHECK-NEXT: 2 aabc 00000004
.text
.section .abc,"ax",@progbits