62 lines · plain
1# REQUIRES: arm2 3# RUN: yaml2obj %s -o %t.obj4# RUN: llvm-objdump --no-print-imm-hex -d %t.obj | FileCheck %s --check-prefix BEFORE5# RUN: lld-link /entry:function /subsystem:console /out:%t.exe %t.obj6# RUN: llvm-objdump --no-print-imm-hex -d %t.exe | FileCheck %s --check-prefix AFTER7 8# BEFORE: Disassembly of section .text:9# BEFORE-EMPTY:10# BEFORE: 0: 4770 bx lr11# BEFORE: 2: bf00 nop12# BEFORE: 4: 2020 movs r0, #3213# BEFORE: 6: f000 b800 b.w {{.+}} @ imm = #014 15# AFTER: Disassembly of section .text:16# AFTER-EMPTY:17# AFTER: <.text>:18# AFTER: 401000: 4770 bx lr19# AFTER: 401002: bf00 nop20# AFTER: 401004: 2020 movs r0, #3221# AFTER: 401006: f7ff bffb b.w 0x401000 <.text>22 23--- !COFF24header:25 Machine: IMAGE_FILE_MACHINE_ARMNT26 Characteristics: []27sections:28 - Name: .text29 Characteristics: [ IMAGE_SCN_CNT_CODE, IMAGE_SCN_MEM_PURGEABLE, IMAGE_SCN_MEM_16BIT, IMAGE_SCN_MEM_EXECUTE, IMAGE_SCN_MEM_READ ]30 Alignment: 431 SectionData: 704700BF202000F000B832 Relocations:33 - VirtualAddress: 634 SymbolName: identity35 Type: IMAGE_REL_ARM_BRANCH24T36symbols:37 - Name: .text38 Value: 039 SectionNumber: 140 SimpleType: IMAGE_SYM_TYPE_NULL41 ComplexType: IMAGE_SYM_DTYPE_NULL42 StorageClass: IMAGE_SYM_CLASS_STATIC43 SectionDefinition:44 Length: 1045 NumberOfRelocations: 146 NumberOfLinenumbers: 047 CheckSum: 048 Number: 149 - Name: identity50 Value: 051 SectionNumber: 152 SimpleType: IMAGE_SYM_TYPE_NULL53 ComplexType: IMAGE_SYM_DTYPE_FUNCTION54 StorageClass: IMAGE_SYM_CLASS_EXTERNAL55 - Name: function56 Value: 457 SectionNumber: 158 SimpleType: IMAGE_SYM_TYPE_NULL59 ComplexType: IMAGE_SYM_DTYPE_FUNCTION60 StorageClass: IMAGE_SYM_CLASS_EXTERNAL61...62