brintos

brintos / llvm-project-archived public Read only

0
0
Text · 851 B · c06ce93 Raw
35 lines · plain
1; RUN: llc -mtriple=hexagon < %s | FileCheck %s2; Check that we generate compare to general register.3 4define i32 @compare1(i32 %a) nounwind {5; CHECK: r{{[0-9]+}} = cmp.eq(r{{[0-9]+}},#120)6entry:7  %cmp = icmp eq i32 %a, 1208  %conv = zext i1 %cmp to i329  ret i32 %conv10}11 12define i32 @compare2(i32 %a) nounwind readnone {13; CHECK: r{{[0-9]+}} = !cmp.eq(r{{[0-9]+}},#120)14entry:15  %cmp = icmp ne i32 %a, 12016  %conv = zext i1 %cmp to i3217  ret i32 %conv18}19 20define i32 @compare3(i32 %a, i32 %b) nounwind readnone {21; CHECK: r{{[0-9]+}} = cmp.eq(r{{[0-9]+}},r{{[0-9]+}})22entry:23  %cmp = icmp eq i32 %a, %b24  %conv = zext i1 %cmp to i3225  ret i32 %conv26}27 28define i32 @compare4(i32 %a, i32 %b) nounwind readnone {29; CHECK: r{{[0-9]+}} = !cmp.eq(r{{[0-9]+}},r{{[0-9]+}})30entry:31  %cmp = icmp ne i32 %a, %b32  %conv = zext i1 %cmp to i3233  ret i32 %conv34}35