1 # RUN: yaml2obj %s -o %t.obj
2 # RUN: lld-link /out:%t.exe /entry:main /subsystem:console /force \
3 # RUN: /section:.foo,r %t.obj
4 # RUN: llvm-readobj --sections %t.exe | FileCheck -check-prefix=R %s
6 # RUN: lld-link /out:%t.exe /entry:main /subsystem:console /force \
7 # RUN: /section:.foo,w %t.obj
8 # RUN: llvm-readobj --sections %t.exe | FileCheck -check-prefix=W %s
10 # RUN: lld-link /out:%t.exe /entry:main /subsystem:console /force \
11 # RUN: /section:.foo,e %t.obj
12 # RUN: llvm-readobj --sections %t.exe | FileCheck -check-prefix=E %s
14 # RUN: lld-link /out:%t.exe /entry:main /subsystem:console /force \
15 # RUN: /section:.foo,s %t.obj
16 # RUN: llvm-readobj --sections %t.exe | FileCheck -check-prefix=S %s
18 # R: Characteristics [
19 # R-NEXT: IMAGE_SCN_CNT_INITIALIZED_DATA
20 # R-NEXT: IMAGE_SCN_MEM_READ
23 # W: Characteristics [
24 # W-NEXT: IMAGE_SCN_CNT_INITIALIZED_DATA
25 # W-NEXT: IMAGE_SCN_MEM_WRITE
28 # E: Characteristics [
29 # E-NEXT: IMAGE_SCN_CNT_INITIALIZED_DATA
30 # E-NEXT: IMAGE_SCN_MEM_EXECUTE
33 # S: Characteristics [
34 # S-NEXT: IMAGE_SCN_CNT_INITIALIZED_DATA
35 # S-NEXT: IMAGE_SCN_MEM_SHARED
40 Machine: IMAGE_FILE_MACHINE_AMD64
44 Characteristics: [ IMAGE_SCN_CNT_INITIALIZED_DATA, IMAGE_SCN_MEM_READ, IMAGE_SCN_MEM_WRITE ]
46 SectionData: 000000000000
51 SimpleType: IMAGE_SYM_TYPE_NULL
52 ComplexType: IMAGE_SYM_DTYPE_NULL
53 StorageClass: IMAGE_SYM_CLASS_STATIC
56 NumberOfRelocations: 0
57 NumberOfLinenumbers: 0
63 SimpleType: IMAGE_SYM_TYPE_NULL
64 ComplexType: IMAGE_SYM_DTYPE_FUNCTION
65 StorageClass: IMAGE_SYM_CLASS_EXTERNAL