[llvm-commits] CVS: llvm/test/Regression/CodeGen/ARM/fpcmp.ll

Rafael Espindola rafael.espindola at gmail.com
Tue Oct 10 07:26:20 PDT 2006



Changes in directory llvm/test/Regression/CodeGen/ARM:

fpcmp.ll added (r1.1)
---
Log message:

add some tests for floating point compare


---
Diffs of the changes:  (+41 -0)

 fpcmp.ll |   41 +++++++++++++++++++++++++++++++++++++++++
 1 files changed, 41 insertions(+)


Index: llvm/test/Regression/CodeGen/ARM/fpcmp.ll
diff -c /dev/null llvm/test/Regression/CodeGen/ARM/fpcmp.ll:1.1
*** /dev/null	Tue Oct 10 09:26:16 2006
--- llvm/test/Regression/CodeGen/ARM/fpcmp.ll	Tue Oct 10 09:26:06 2006
***************
*** 0 ****
--- 1,41 ----
+ ; RUN: llvm-as < %s | llc -march=arm &&
+ ; RUN: llvm-as < %s | llc -march=arm  | grep movlt &&
+ ; RUN: llvm-as < %s | llc -march=arm  | grep moveq &&
+ ; RUN: llvm-as < %s | llc -march=arm  | grep movgt &&
+ ; RUN: llvm-as < %s | llc -march=arm  | grep movge &&
+ ; RUN: llvm-as < %s | llc -march=arm  | grep movle
+ 
+ int %f1(float %a) {
+ entry:
+ 	%tmp = setlt float %a, 1.000000e+00		; <bool> [#uses=1]
+ 	%tmp = cast bool %tmp to int		; <int> [#uses=1]
+ 	ret int %tmp
+ }
+ 
+ int %f2(float %a) {
+ entry:
+ 	%tmp = seteq float %a, 1.000000e+00		; <bool> [#uses=1]
+ 	%tmp = cast bool %tmp to int		; <int> [#uses=1]
+ 	ret int %tmp
+ }
+ 
+ int %f3(float %a) {
+ entry:
+ 	%tmp = setgt float %a, 1.000000e+00		; <bool> [#uses=1]
+ 	%tmp = cast bool %tmp to int		; <int> [#uses=1]
+ 	ret int %tmp
+ }
+ 
+ int %f4(float %a) {
+ entry:
+ 	%tmp = setge float %a, 1.000000e+00		; <bool> [#uses=1]
+ 	%tmp = cast bool %tmp to int		; <int> [#uses=1]
+ 	ret int %tmp
+ }
+ 
+ int %f5(float %a) {
+ entry:
+ 	%tmp = setle float %a, 1.000000e+00		; <bool> [#uses=1]
+ 	%tmp = cast bool %tmp to int		; <int> [#uses=1]
+ 	ret int %tmp
+ }






More information about the llvm-commits mailing list