1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mcpu=pwr10 -ppc-asm-full-reg-names --enable-unsafe-fp-math \
3 ; RUN: -verify-machineinstrs --enable-no-signed-zeros-fp-math \
4 ; RUN: --enable-no-nans-fp-math \
5 ; RUN: -mtriple=powerpc64le-unknown-unknown < %s | FileCheck %s
6 ; RUN: llc -mcpu=pwr10 -ppc-asm-full-reg-names -verify-machineinstrs \
7 ; RUN: -mtriple=powerpc64le-unknown-unknown < %s | FileCheck %s
8 define dso_local fp128 @testqmax(fp128 %a, fp128 %b) local_unnamed_addr {
9 ; CHECK-LABEL: testqmax:
10 ; CHECK: # %bb.0: # %entry
11 ; CHECK-NEXT: xsmaxcqp v2, v2, v3
14 %cmp = fcmp ogt fp128 %a, %b
15 %cond = select i1 %cmp, fp128 %a, fp128 %b
19 define dso_local fp128 @testqmin(fp128 %a, fp128 %b) local_unnamed_addr {
20 ; CHECK-LABEL: testqmin:
21 ; CHECK: # %bb.0: # %entry
22 ; CHECK-NEXT: xsmincqp v2, v2, v3
25 %cmp = fcmp olt fp128 %a, %b
26 %cond = select i1 %cmp, fp128 %a, fp128 %b
30 define dso_local fp128 @testqmax_fast(fp128 %a, fp128 %b) local_unnamed_addr {
31 ; CHECK-LABEL: testqmax_fast:
32 ; CHECK: # %bb.0: # %entry
33 ; CHECK-NEXT: xsmaxcqp v2, v2, v3
36 %cmp = fcmp nnan ninf ogt fp128 %a, %b
37 %cond = select i1 %cmp, fp128 %a, fp128 %b
41 define dso_local fp128 @testqmin_fast(fp128 %a, fp128 %b) local_unnamed_addr {
42 ; CHECK-LABEL: testqmin_fast:
43 ; CHECK: # %bb.0: # %entry
44 ; CHECK-NEXT: xsmincqp v2, v2, v3
47 %cmp = fcmp nnan ninf olt fp128 %a, %b
48 %cond = select i1 %cmp, fp128 %a, fp128 %b
52 declare fp128 @llvm.maxnum.f128(fp128, fp128)
53 define dso_local fp128 @testq_intrinsic_maxnum(fp128 %a, fp128 %b) local_unnamed_addr {
54 ; CHECK-LABEL: testq_intrinsic_maxnum:
55 ; CHECK: # %bb.0: # %entry
56 ; CHECK-NEXT: xsmaxcqp v2, v2, v3
59 %0 = tail call fast fp128 @llvm.maxnum.f128(fp128 %a, fp128 %b)
63 declare fp128 @llvm.minnum.f128(fp128, fp128)
64 define dso_local fp128 @testq_intrinsic_minnum(fp128 %a, fp128 %b) local_unnamed_addr {
65 ; CHECK-LABEL: testq_intrinsic_minnum:
66 ; CHECK: # %bb.0: # %entry
67 ; CHECK-NEXT: xsmincqp v2, v2, v3
70 %0 = tail call fast fp128 @llvm.minnum.f128(fp128 %a, fp128 %b)