3 # RUN: yaml2obj %s -o %t.o
5 # Test that we get both the resource and the code from a single object
6 # file that contains both, while merging resources from another object
9 # RUN: lld-link -lldmingw -out:%t.exe %t.o %p/Inputs/id.res.o -entry:main
10 # RUN: llvm-readobj --coff-resources %t.exe | FileCheck %s --check-prefix=CHECK-RESOURCES
11 # RUN: llvm-objdump --no-print-imm-hex -d %t.exe | FileCheck %s --check-prefix=CHECK-DISASM
13 # CHECK-RESOURCES: Resources [
14 # CHECK-RESOURCES-NEXT: Total Number of Resources: 2
16 # CHECK-DISASM: <.text>:
17 # CHECK-DISASM-NEXT: movl $42, %eax
18 # CHECK-DISASM-NEXT: retq
22 Machine: IMAGE_FILE_MACHINE_AMD64
23 Characteristics: [ IMAGE_FILE_LINE_NUMS_STRIPPED ]
26 Characteristics: [ IMAGE_SCN_CNT_INITIALIZED_DATA, IMAGE_SCN_MEM_READ, IMAGE_SCN_MEM_WRITE ]
28 SectionData: 0000000000000000000000000000010005000000180000800000000000000000000000000100000048000080300000800000000000000000000000000000010009040000600000000A0054004500530054004400490041004C004F0047000000700000006C00000000000000000000000000C0800000000002000A000A00C8002C01000000005400650073007400000001000250000000000A000A00E6000E000100FFFF820043006F006E00740069006E00750065003A0000000000000001500000000042008600A1000D000200FFFF800026004F004B000000000000000000
32 Type: IMAGE_REL_AMD64_ADDR32NB
34 Characteristics: [ IMAGE_SCN_CNT_CODE, IMAGE_SCN_MEM_EXECUTE, IMAGE_SCN_MEM_READ ]
36 SectionData: B82A000000C3
41 SimpleType: IMAGE_SYM_TYPE_NULL
42 ComplexType: IMAGE_SYM_DTYPE_NULL
43 StorageClass: IMAGE_SYM_CLASS_STATIC
47 SimpleType: IMAGE_SYM_TYPE_NULL
48 ComplexType: IMAGE_SYM_DTYPE_NULL
49 StorageClass: IMAGE_SYM_CLASS_STATIC
52 NumberOfRelocations: 0
53 NumberOfLinenumbers: 0
59 SimpleType: IMAGE_SYM_TYPE_NULL
60 ComplexType: IMAGE_SYM_DTYPE_FUNCTION
61 StorageClass: IMAGE_SYM_CLASS_EXTERNAL