Skip to content

Commit a0f361b

Browse files
opt test
1 parent 7894b05 commit a0f361b

File tree

3 files changed

+84
-112
lines changed

3 files changed

+84
-112
lines changed

llvm/test/CodeGen/X86/isel-ceil.ll

Lines changed: 28 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
22
; RUN: llc < %s -mtriple=x86_64-linux-gnu | FileCheck %s --check-prefixes=X64,DAG-X64
33
; RUN: llc < %s -mtriple=x86_64-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X64,FASTISEL-X64
4-
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86,DAG-X86
5-
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86,FASTISEL-X86
4+
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86
5+
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86
66
; RUN: llc < %s -mtriple=x86_64-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X64
7-
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=X86,GISEL-X86
7+
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X86
88

99
define float @ceil_f32(float %a) nounwind readnone {
1010
; DAG-X64-LABEL: ceil_f32:
@@ -18,23 +18,14 @@ define float @ceil_f32(float %a) nounwind readnone {
1818
; FASTISEL-X64-NEXT: popq %rax
1919
; FASTISEL-X64-NEXT: retq
2020
;
21-
; DAG-X86-LABEL: ceil_f32:
22-
; DAG-X86: # %bb.0:
23-
; DAG-X86-NEXT: subl $12, %esp
24-
; DAG-X86-NEXT: flds {{[0-9]+}}(%esp)
25-
; DAG-X86-NEXT: fstps (%esp)
26-
; DAG-X86-NEXT: calll ceilf
27-
; DAG-X86-NEXT: addl $12, %esp
28-
; DAG-X86-NEXT: retl
29-
;
30-
; FASTISEL-X86-LABEL: ceil_f32:
31-
; FASTISEL-X86: # %bb.0:
32-
; FASTISEL-X86-NEXT: subl $12, %esp
33-
; FASTISEL-X86-NEXT: flds {{[0-9]+}}(%esp)
34-
; FASTISEL-X86-NEXT: fstps (%esp)
35-
; FASTISEL-X86-NEXT: calll ceilf
36-
; FASTISEL-X86-NEXT: addl $12, %esp
37-
; FASTISEL-X86-NEXT: retl
21+
; X86-LABEL: ceil_f32:
22+
; X86: # %bb.0:
23+
; X86-NEXT: subl $12, %esp
24+
; X86-NEXT: flds {{[0-9]+}}(%esp)
25+
; X86-NEXT: fstps (%esp)
26+
; X86-NEXT: calll ceilf
27+
; X86-NEXT: addl $12, %esp
28+
; X86-NEXT: retl
3829
;
3930
; GISEL-X64-LABEL: ceil_f32:
4031
; GISEL-X64: # %bb.0:
@@ -67,23 +58,14 @@ define double @ceil_f64(double %a) nounwind readnone {
6758
; FASTISEL-X64-NEXT: popq %rax
6859
; FASTISEL-X64-NEXT: retq
6960
;
70-
; DAG-X86-LABEL: ceil_f64:
71-
; DAG-X86: # %bb.0:
72-
; DAG-X86-NEXT: subl $12, %esp
73-
; DAG-X86-NEXT: fldl {{[0-9]+}}(%esp)
74-
; DAG-X86-NEXT: fstpl (%esp)
75-
; DAG-X86-NEXT: calll ceil
76-
; DAG-X86-NEXT: addl $12, %esp
77-
; DAG-X86-NEXT: retl
78-
;
79-
; FASTISEL-X86-LABEL: ceil_f64:
80-
; FASTISEL-X86: # %bb.0:
81-
; FASTISEL-X86-NEXT: subl $12, %esp
82-
; FASTISEL-X86-NEXT: fldl {{[0-9]+}}(%esp)
83-
; FASTISEL-X86-NEXT: fstpl (%esp)
84-
; FASTISEL-X86-NEXT: calll ceil
85-
; FASTISEL-X86-NEXT: addl $12, %esp
86-
; FASTISEL-X86-NEXT: retl
61+
; X86-LABEL: ceil_f64:
62+
; X86: # %bb.0:
63+
; X86-NEXT: subl $12, %esp
64+
; X86-NEXT: fldl {{[0-9]+}}(%esp)
65+
; X86-NEXT: fstpl (%esp)
66+
; X86-NEXT: calll ceil
67+
; X86-NEXT: addl $12, %esp
68+
; X86-NEXT: retl
8769
;
8870
; GISEL-X64-LABEL: ceil_f64:
8971
; GISEL-X64: # %bb.0:
@@ -136,7 +118,15 @@ define x86_fp80 @ceil_f80(x86_fp80 %a) nounwind readnone {
136118
; GISEL-X64-NEXT: callq ceill
137119
; GISEL-X64-NEXT: addq $24, %rsp
138120
; GISEL-X64-NEXT: retq
121+
;
122+
; GISEL-X86-LABEL: ceil_f80:
123+
; GISEL-X86: # %bb.0:
124+
; GISEL-X86-NEXT: subl $12, %esp
125+
; GISEL-X86-NEXT: fldt {{[0-9]+}}(%esp)
126+
; GISEL-X86-NEXT: fstpt (%esp)
127+
; GISEL-X86-NEXT: calll ceill
128+
; GISEL-X86-NEXT: addl $12, %esp
129+
; GISEL-X86-NEXT: retl
139130
%c = call x86_fp80 @llvm.ceil.f80(x86_fp80 %a)
140131
ret x86_fp80 %c
141132
}
142-

llvm/test/CodeGen/X86/isel-floor.ll

Lines changed: 28 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
22
; RUN: llc < %s -mtriple=x86_64-linux-gnu | FileCheck %s --check-prefixes=X64,DAG-X64
33
; RUN: llc < %s -mtriple=x86_64-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X64,FASTISEL-X64
4-
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86,DAG-X86
5-
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86,FASTISEL-X86
4+
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86
5+
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86
66
; RUN: llc < %s -mtriple=x86_64-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X64
7-
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=X86,GISEL-X86
7+
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X86
88

99
define float @floor_f32(float %a) nounwind readnone {
1010
; DAG-X64-LABEL: floor_f32:
@@ -18,23 +18,14 @@ define float @floor_f32(float %a) nounwind readnone {
1818
; FASTISEL-X64-NEXT: popq %rax
1919
; FASTISEL-X64-NEXT: retq
2020
;
21-
; DAG-X86-LABEL: floor_f32:
22-
; DAG-X86: # %bb.0:
23-
; DAG-X86-NEXT: subl $12, %esp
24-
; DAG-X86-NEXT: flds {{[0-9]+}}(%esp)
25-
; DAG-X86-NEXT: fstps (%esp)
26-
; DAG-X86-NEXT: calll floorf
27-
; DAG-X86-NEXT: addl $12, %esp
28-
; DAG-X86-NEXT: retl
29-
;
30-
; FASTISEL-X86-LABEL: floor_f32:
31-
; FASTISEL-X86: # %bb.0:
32-
; FASTISEL-X86-NEXT: subl $12, %esp
33-
; FASTISEL-X86-NEXT: flds {{[0-9]+}}(%esp)
34-
; FASTISEL-X86-NEXT: fstps (%esp)
35-
; FASTISEL-X86-NEXT: calll floorf
36-
; FASTISEL-X86-NEXT: addl $12, %esp
37-
; FASTISEL-X86-NEXT: retl
21+
; X86-LABEL: floor_f32:
22+
; X86: # %bb.0:
23+
; X86-NEXT: subl $12, %esp
24+
; X86-NEXT: flds {{[0-9]+}}(%esp)
25+
; X86-NEXT: fstps (%esp)
26+
; X86-NEXT: calll floorf
27+
; X86-NEXT: addl $12, %esp
28+
; X86-NEXT: retl
3829
;
3930
; GISEL-X64-LABEL: floor_f32:
4031
; GISEL-X64: # %bb.0:
@@ -67,23 +58,14 @@ define double @floor_f64(double %a) nounwind readnone {
6758
; FASTISEL-X64-NEXT: popq %rax
6859
; FASTISEL-X64-NEXT: retq
6960
;
70-
; DAG-X86-LABEL: floor_f64:
71-
; DAG-X86: # %bb.0:
72-
; DAG-X86-NEXT: subl $12, %esp
73-
; DAG-X86-NEXT: fldl {{[0-9]+}}(%esp)
74-
; DAG-X86-NEXT: fstpl (%esp)
75-
; DAG-X86-NEXT: calll floor
76-
; DAG-X86-NEXT: addl $12, %esp
77-
; DAG-X86-NEXT: retl
78-
;
79-
; FASTISEL-X86-LABEL: floor_f64:
80-
; FASTISEL-X86: # %bb.0:
81-
; FASTISEL-X86-NEXT: subl $12, %esp
82-
; FASTISEL-X86-NEXT: fldl {{[0-9]+}}(%esp)
83-
; FASTISEL-X86-NEXT: fstpl (%esp)
84-
; FASTISEL-X86-NEXT: calll floor
85-
; FASTISEL-X86-NEXT: addl $12, %esp
86-
; FASTISEL-X86-NEXT: retl
61+
; X86-LABEL: floor_f64:
62+
; X86: # %bb.0:
63+
; X86-NEXT: subl $12, %esp
64+
; X86-NEXT: fldl {{[0-9]+}}(%esp)
65+
; X86-NEXT: fstpl (%esp)
66+
; X86-NEXT: calll floor
67+
; X86-NEXT: addl $12, %esp
68+
; X86-NEXT: retl
8769
;
8870
; GISEL-X64-LABEL: floor_f64:
8971
; GISEL-X64: # %bb.0:
@@ -136,6 +118,15 @@ define x86_fp80 @floor_f80(x86_fp80 %a) nounwind readnone {
136118
; GISEL-X64-NEXT: callq floorl
137119
; GISEL-X64-NEXT: addq $24, %rsp
138120
; GISEL-X64-NEXT: retq
121+
;
122+
; GISEL-X86-LABEL: floor_f80:
123+
; GISEL-X86: # %bb.0:
124+
; GISEL-X86-NEXT: subl $12, %esp
125+
; GISEL-X86-NEXT: fldt {{[0-9]+}}(%esp)
126+
; GISEL-X86-NEXT: fstpt (%esp)
127+
; GISEL-X86-NEXT: calll floorl
128+
; GISEL-X86-NEXT: addl $12, %esp
129+
; GISEL-X86-NEXT: retl
139130
%c = call x86_fp80 @llvm.floor.f80(x86_fp80 %a)
140131
ret x86_fp80 %c
141132
}

llvm/test/CodeGen/X86/isel-ftrunc.ll

Lines changed: 28 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
22
; RUN: llc < %s -mtriple=x86_64-linux-gnu | FileCheck %s --check-prefixes=X64,DAG-X64
33
; RUN: llc < %s -mtriple=x86_64-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X64,FASTISEL-X64
4-
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86,DAG-X86
5-
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86,FASTISEL-X86
4+
; RUN: llc < %s -mtriple=i686-linux-gnu | FileCheck %s --check-prefixes=X86
5+
; RUN: llc < %s -mtriple=i686-linux-gnu -fast-isel | FileCheck %s --check-prefixes=X86
66
; RUN: llc < %s -mtriple=x86_64-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X64
7-
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=X86,GISEL-X86
7+
; RUN: llc < %s -mtriple=i686-linux-gnu -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=GISEL-X86
88

99
define float @trunc_f32(float %a) nounwind readnone {
1010
; DAG-X64-LABEL: trunc_f32:
@@ -18,23 +18,14 @@ define float @trunc_f32(float %a) nounwind readnone {
1818
; FASTISEL-X64-NEXT: popq %rax
1919
; FASTISEL-X64-NEXT: retq
2020
;
21-
; DAG-X86-LABEL: trunc_f32:
22-
; DAG-X86: # %bb.0:
23-
; DAG-X86-NEXT: subl $12, %esp
24-
; DAG-X86-NEXT: flds {{[0-9]+}}(%esp)
25-
; DAG-X86-NEXT: fstps (%esp)
26-
; DAG-X86-NEXT: calll truncf
27-
; DAG-X86-NEXT: addl $12, %esp
28-
; DAG-X86-NEXT: retl
29-
;
30-
; FASTISEL-X86-LABEL: trunc_f32:
31-
; FASTISEL-X86: # %bb.0:
32-
; FASTISEL-X86-NEXT: subl $12, %esp
33-
; FASTISEL-X86-NEXT: flds {{[0-9]+}}(%esp)
34-
; FASTISEL-X86-NEXT: fstps (%esp)
35-
; FASTISEL-X86-NEXT: calll truncf
36-
; FASTISEL-X86-NEXT: addl $12, %esp
37-
; FASTISEL-X86-NEXT: retl
21+
; X86-LABEL: trunc_f32:
22+
; X86: # %bb.0:
23+
; X86-NEXT: subl $12, %esp
24+
; X86-NEXT: flds {{[0-9]+}}(%esp)
25+
; X86-NEXT: fstps (%esp)
26+
; X86-NEXT: calll truncf
27+
; X86-NEXT: addl $12, %esp
28+
; X86-NEXT: retl
3829
;
3930
; GISEL-X64-LABEL: trunc_f32:
4031
; GISEL-X64: # %bb.0:
@@ -67,23 +58,14 @@ define double @trunc_f64(double %a) nounwind readnone {
6758
; FASTISEL-X64-NEXT: popq %rax
6859
; FASTISEL-X64-NEXT: retq
6960
;
70-
; DAG-X86-LABEL: trunc_f64:
71-
; DAG-X86: # %bb.0:
72-
; DAG-X86-NEXT: subl $12, %esp
73-
; DAG-X86-NEXT: fldl {{[0-9]+}}(%esp)
74-
; DAG-X86-NEXT: fstpl (%esp)
75-
; DAG-X86-NEXT: calll trunc
76-
; DAG-X86-NEXT: addl $12, %esp
77-
; DAG-X86-NEXT: retl
78-
;
79-
; FASTISEL-X86-LABEL: trunc_f64:
80-
; FASTISEL-X86: # %bb.0:
81-
; FASTISEL-X86-NEXT: subl $12, %esp
82-
; FASTISEL-X86-NEXT: fldl {{[0-9]+}}(%esp)
83-
; FASTISEL-X86-NEXT: fstpl (%esp)
84-
; FASTISEL-X86-NEXT: calll trunc
85-
; FASTISEL-X86-NEXT: addl $12, %esp
86-
; FASTISEL-X86-NEXT: retl
61+
; X86-LABEL: trunc_f64:
62+
; X86: # %bb.0:
63+
; X86-NEXT: subl $12, %esp
64+
; X86-NEXT: fldl {{[0-9]+}}(%esp)
65+
; X86-NEXT: fstpl (%esp)
66+
; X86-NEXT: calll trunc
67+
; X86-NEXT: addl $12, %esp
68+
; X86-NEXT: retl
8769
;
8870
; GISEL-X64-LABEL: trunc_f64:
8971
; GISEL-X64: # %bb.0:
@@ -136,6 +118,15 @@ define x86_fp80 @trunc_f80(x86_fp80 %a) nounwind readnone {
136118
; GISEL-X64-NEXT: callq truncl
137119
; GISEL-X64-NEXT: addq $24, %rsp
138120
; GISEL-X64-NEXT: retq
121+
;
122+
; GISEL-X86-LABEL: trunc_f80:
123+
; GISEL-X86: # %bb.0:
124+
; GISEL-X86-NEXT: subl $12, %esp
125+
; GISEL-X86-NEXT: fldt {{[0-9]+}}(%esp)
126+
; GISEL-X86-NEXT: fstpt (%esp)
127+
; GISEL-X86-NEXT: calll truncl
128+
; GISEL-X86-NEXT: addl $12, %esp
129+
; GISEL-X86-NEXT: retl
139130
%c = call x86_fp80 @llvm.trunc.f80(x86_fp80 %a)
140131
ret x86_fp80 %c
141132
}

0 commit comments

Comments
 (0)