1 // Test that notes
(both from object files
and synthetic
) are duplicated into
6 // RUN
: llvm-mc
%s
-o
%t.o
-filetype
=obj
--triple
=x86_64-unknown-linux
7 // RUN
: ld.lld
%t.o
-o
%t --shared
--gc-sections
--build-id
=sha1
9 // RUN
: llvm-objcopy
--extract-main-partition
%t %t0
10 // RUN
: llvm-objcopy
--extract-partition
=part1
%t %t1
12 // RUN
: llvm-readobj
--all
%t0 | FileCheck
%s
13 // RUN
: llvm-readobj
--all
%t1 | FileCheck
%s
15 // CHECK
: Type
: PT_NOTE
16 // CHECK-NEXT
: Offset
: 0x
{{0*}}[[NOTE_OFFSET
:[^
]*]]
18 // CHECK
: NoteSections
[
19 // CHECK-NEXT
: NoteSection
{
20 // CHECK-NEXT
: Name
: .note.obj
21 // CHECK-NEXT
: Offset
: 0x
{{0*}}[[NOTE_OFFSET
]]
23 // CHECK-NEXT
: Notes
[
25 // CHECK-NEXT
: Owner
: foo
26 // CHECK-NEXT
: Data size
: 0x4
27 // CHECK-NEXT
: Type
: NT_VERSION
(version
)
28 // CHECK-NEXT
: Description data
(
29 // CHECK-NEXT
: 0000: 62617200 |bar.|
34 // CHECK-NEXT
: NoteSection
{
35 // CHECK-NEXT
: Name
: .note.gnu.build-id
36 // CHECK-NEXT
: Offset
:
38 // CHECK-NEXT
: Notes
[
40 // CHECK-NEXT
: Owner
: GNU
41 // CHECK-NEXT
: Data size
:
42 // CHECK-NEXT
: Type
: NT_GNU_BUILD_ID
(unique build ID bitstring
)
43 // CHECK-NEXT
: Build ID
: d5101cb9d03b7e836ba9b64f5768a0b31980920f
{{$
}}
49 .section .llvm_sympart,"",@llvm_sympart
53 .section .data.p0,"aw",@progbits
57 .section .data.p1,"aw",@progbits
61 .section .note.obj,"a",@note