1 ; RUN: llc -mtriple=powerpc %s -o - | FileCheck %s --check-prefixes=CHECK,PPC32
2 ; RUN: llc -mtriple=powerpc64 %s -o - | FileCheck %s --check-prefixes=CHECK,PPC64
4 @a = global i32 0, align 4
11 ; CHECK-NOT: .section __patchable_function_entries
15 define void @f1() "patchable-function-entry"="0" {
20 ; CHECK-NOT: .section __patchable_function_entries
24 define void @f2() "patchable-function-entry"="1" {
26 ; CHECK-LABEL-NEXT: .Lfunc_begin2:
30 ; CHECK: .section __patchable_function_entries
31 ; PPC32: .p2align 2, 0x0
32 ; PPC64: .p2align 3, 0x0
33 ; PPC32-NEXT: .long .Lfunc_begin2
34 ; PPC64-NEXT: .quad .Lfunc_begin2
38 define i32 @f3() "patchable-function-entry"="1" "patchable-function-prefix"="2" {
39 ; CHECK-LABEL: .Ltmp0:
45 ; PPC32-NEXT: lwz 3, a@l(3)
46 ; PPC64: addis 3, 2, .LC0@toc@ha
47 ; PPC64-NEXT: ld 3, .LC0@toc@l(3)
48 ; PPC64-NEXT: lwz 3, 0(3)
50 ; CHECK: .section __patchable_function_entries
51 ; PPC32: .p2align 2, 0x0
52 ; PPC64: .p2align 3, 0x0
53 ; PPC32-NEXT: .long .Ltmp0
54 ; PPC64-NEXT: .quad .Ltmp0
56 %0 = load i32, ptr @a, align 4