10
10
; RUN: llc -mtriple=x86_64-apple-xros8.0 < %s | FileCheck -check-prefix=APPLE %s
11
11
; RUN: llc -mtriple=x86_64-apple-driverkit < %s | FileCheck -check-prefix=APPLE %s
12
12
; RUN: llc -mtriple=x86_64-apple-driverkit24.0 < %s | FileCheck -check-prefix=APPLE %s
13
- ; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=2 | FileCheck %s --check-prefix=GISEL-X86
14
- ; RUN: llc < %s -mtriple=x86_64-linux-gnu -global-isel -global-isel-abort=2 | FileCheck %s --check-prefix=GISEL-X64
13
+ ; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefix=GISEL-X86
14
+ ; RUN: llc < %s -mtriple=x86_64-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefix=GISEL-X64
15
15
16
16
; RUN: not llc -mtriple=x86_64-apple-macos10.8 -filetype=null %s 2>&1 | FileCheck -check-prefix=ERR %s
17
17
; Check exp10/exp10f is emitted as __exp10/__exp10f on assorted systems.
@@ -30,15 +30,18 @@ define float @test_exp10_f32(float %x) nounwind {
30
30
; GISEL-X86-LABEL: test_exp10_f32:
31
31
; GISEL-X86: # %bb.0:
32
32
; GISEL-X86-NEXT: subl $12, %esp
33
- ; GISEL-X86-NEXT: flds {{[0-9]+}}(%esp)
34
- ; GISEL-X86-NEXT: fstps (%esp)
33
+ ; GISEL-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
34
+ ; GISEL-X86-NEXT: movl %eax, (%esp)
35
35
; GISEL-X86-NEXT: calll exp10f
36
36
; GISEL-X86-NEXT: addl $12, %esp
37
37
; GISEL-X86-NEXT: retl
38
38
;
39
39
; GISEL-X64-LABEL: test_exp10_f32:
40
40
; GISEL-X64: # %bb.0:
41
- ; GISEL-X64-NEXT: jmp exp10f@PLT # TAILCALL
41
+ ; GISEL-X64-NEXT: pushq %rax
42
+ ; GISEL-X64-NEXT: callq exp10f
43
+ ; GISEL-X64-NEXT: popq %rax
44
+ ; GISEL-X64-NEXT: retq
42
45
%ret = call float @llvm.exp10.f32 (float %x )
43
46
ret float %ret
44
47
}
@@ -55,15 +58,23 @@ define double @test_exp10_f64(double %x) nounwind {
55
58
; GISEL-X86-LABEL: test_exp10_f64:
56
59
; GISEL-X86: # %bb.0:
57
60
; GISEL-X86-NEXT: subl $12, %esp
58
- ; GISEL-X86-NEXT: fldl {{[0-9]+}}(%esp)
59
- ; GISEL-X86-NEXT: fstpl (%esp)
61
+ ; GISEL-X86-NEXT: leal {{[0-9]+}}(%esp), %eax
62
+ ; GISEL-X86-NEXT: movl {{[0-9]+}}(%esp), %ecx
63
+ ; GISEL-X86-NEXT: movl 4(%eax), %eax
64
+ ; GISEL-X86-NEXT: xorl %edx, %edx
65
+ ; GISEL-X86-NEXT: addl %esp, %edx
66
+ ; GISEL-X86-NEXT: movl %ecx, (%esp)
67
+ ; GISEL-X86-NEXT: movl %eax, 4(%edx)
60
68
; GISEL-X86-NEXT: calll exp10
61
69
; GISEL-X86-NEXT: addl $12, %esp
62
70
; GISEL-X86-NEXT: retl
63
71
;
64
72
; GISEL-X64-LABEL: test_exp10_f64:
65
73
; GISEL-X64: # %bb.0:
66
- ; GISEL-X64-NEXT: jmp exp10@PLT # TAILCALL
74
+ ; GISEL-X64-NEXT: pushq %rax
75
+ ; GISEL-X64-NEXT: callq exp10
76
+ ; GISEL-X64-NEXT: popq %rax
77
+ ; GISEL-X64-NEXT: retq
67
78
%ret = call double @llvm.exp10.f64 (double %x )
68
79
ret double %ret
69
80
}
@@ -101,7 +112,7 @@ define x86_fp80 @test_exp10_f80(x86_fp80 %x) nounwind {
101
112
; GISEL-X64-NEXT: subq $24, %rsp
102
113
; GISEL-X64-NEXT: fldt {{[0-9]+}}(%rsp)
103
114
; GISEL-X64-NEXT: fstpt (%rsp)
104
- ; GISEL-X64-NEXT: callq exp10l@PLT
115
+ ; GISEL-X64-NEXT: callq exp10l
105
116
; GISEL-X64-NEXT: addq $24, %rsp
106
117
; GISEL-X64-NEXT: retq
107
118
%ret = call x86_fp80 @llvm.exp10.f80 (x86_fp80 %x )
0 commit comments