c++: normalizing ttp constraints [PR115656]
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / float128-minmax.c
blobe9ace19ef091a20b9fb94c8f2464295f6e1e9f26
1 /* { dg-require-effective-target ppc_float128_hw } */
2 /* { dg-options "-mvsx -O2 -ffast-math" } */
3 /* { dg-additional-options "-mdejagnu-cpu=power9" { target { ! has_arch_pwr9 } } } */
5 #ifndef TYPE
6 #define TYPE _Float128
7 #endif
9 /* Test that the fminf128/fmaxf128 functions generate if/then/else and not a
10 call. */
11 TYPE f128_min (TYPE a, TYPE b) { return __builtin_fminf128 (a, b); }
12 TYPE f128_max (TYPE a, TYPE b) { return __builtin_fmaxf128 (a, b); }
14 /* Adjust code power10 which has native min/max instructions. */
15 /* { dg-final { scan-assembler-times {\mxscmpuqp\M} 2 { target { ! has_arch_pwr10 } } } } */
16 /* { dg-final { scan-assembler-times {\mxsmincqp\M} 1 { target has_arch_pwr10 } } } */
17 /* { dg-final { scan-assembler-times {\mxsmaxcqp\M} 1 { target has_arch_pwr10 } } } */
18 /* { dg-final { scan-assembler-not {\mbl\M} } } */