xref: /aosp_15_r20/external/llvm/test/MC/MachO/ARM/empty-function-nop.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -filetype=obj -mtriple=thumbv6-apple-darwin -o - | llvm-readobj -s -sd | FileCheck -check-prefix=CHECK-T1 %s
2*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -filetype=obj -mtriple=thumbv7-apple-darwin -o - | llvm-readobj -s -sd | FileCheck -check-prefix=CHECK-T2 %s
3*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -filetype=obj -mtriple=armv6-apple-darwin -o - | llvm-readobj -s -sd | FileCheck -check-prefix=CHECK-ARM %s
4*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -filetype=obj -mtriple=armv7-apple-darwin -o - | llvm-readobj -s -sd | FileCheck -check-prefix=CHECK-ARMV7 %s
5*9880d681SAndroid Build Coastguard Worker
6*9880d681SAndroid Build Coastguard Worker; Empty functions need a NOP in them for MachO to prevent DWARF FDEs from
7*9880d681SAndroid Build Coastguard Worker; getting all mucked up. See lib/CodeGen/AsmPrinter/AsmPrinter.cpp for
8*9880d681SAndroid Build Coastguard Worker; details.
9*9880d681SAndroid Build Coastguard Workerdefine internal fastcc void @empty_function() {
10*9880d681SAndroid Build Coastguard Worker  unreachable
11*9880d681SAndroid Build Coastguard Worker}
12*9880d681SAndroid Build Coastguard Worker; CHECK-T1:    SectionData (
13*9880d681SAndroid Build Coastguard Worker; CHECK-T1:      0000: C046                                 |.F|
14*9880d681SAndroid Build Coastguard Worker; CHECK-T1:    )
15*9880d681SAndroid Build Coastguard Worker; CHECK-T2:    SectionData (
16*9880d681SAndroid Build Coastguard Worker; CHECK-T2:      0000: 00BF                                 |..|
17*9880d681SAndroid Build Coastguard Worker; CHECK-T2:    )
18*9880d681SAndroid Build Coastguard Worker; CHECK-ARM:   SectionData (
19*9880d681SAndroid Build Coastguard Worker; CHECK-ARM:     0000: 0000A0E1                             |....|
20*9880d681SAndroid Build Coastguard Worker; CHECK-ARM:   )
21*9880d681SAndroid Build Coastguard Worker; CHECK-ARMV7: SectionData (
22*9880d681SAndroid Build Coastguard Worker; CHECK-ARMV7:   0000: 00F020E3                             |.. .|
23*9880d681SAndroid Build Coastguard Worker; CHECK-ARMV7: )
24