From a1b4d225d8cd07c79eea81fb6416e8ad5a07f018 Mon Sep 17 00:00:00 2001 From: Bill Schmidt Date: Wed, 2 Feb 2022 20:59:00 -0600 Subject: [PATCH] rs6000: Unify error messages for built-in constant restrictions We currently give different error messages for built-in functions that violate range restrictions on their arguments, depending on whether we record them as requiring an n-bit literal or a literal between two values. It's better to be consistent. Change the error message for the n-bit literal to look like the other one. 2022-02-02 Bill Schmidt gcc/ * config/rs6000/rs6000-call.cc (rs6000_expand_builtin): Revise error message for RES_BITS case. gcc/testsuite/ * gcc.target/powerpc/bfp/scalar-test-data-class-10.c: Adjust error messages. * gcc.target/powerpc/bfp/scalar-test-data-class-2.c: Likewise. * gcc.target/powerpc/bfp/scalar-test-data-class-3.c: Likewise. * gcc.target/powerpc/bfp/scalar-test-data-class-4.c: Likewise. * gcc.target/powerpc/bfp/scalar-test-data-class-5.c: Likewise. * gcc.target/powerpc/bfp/scalar-test-data-class-9.c: Likewise. * gcc.target/powerpc/bfp/vec-test-data-class-4.c: Likewise. * gcc.target/powerpc/bfp/vec-test-data-class-5.c: Likewise. * gcc.target/powerpc/bfp/vec-test-data-class-6.c: Likewise. * gcc.target/powerpc/bfp/vec-test-data-class-7.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-12.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-14.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-17.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-19.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-2.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-22.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-24.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-27.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-29.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-32.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-34.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-37.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-39.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-4.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-42.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-44.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-47.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-49.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-52.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-54.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-57.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-59.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-62.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-64.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-67.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-69.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-7.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-72.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-74.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-77.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-79.c: Likewise. * gcc.target/powerpc/dfp/dtstsfi-9.c: Likewise. * gcc.target/powerpc/pr80315-1.c: Likewise. * gcc.target/powerpc/pr80315-2.c: Likewise. * gcc.target/powerpc/pr80315-3.c: Likewise. * gcc.target/powerpc/pr80315-4.c: Likewise. * gcc.target/powerpc/pr82015.c: Likewise. * gcc.target/powerpc/pr91903.c: Likewise. * gcc.target/powerpc/test_fpscr_rn_builtin_error.c: Likewise. * gcc.target/powerpc/vec-ternarylogic-10.c: Likewise. --- gcc/config/rs6000/rs6000-call.cc | 6 ++- .../powerpc/bfp/scalar-test-data-class-10.c | 2 +- .../powerpc/bfp/scalar-test-data-class-2.c | 2 +- .../powerpc/bfp/scalar-test-data-class-3.c | 2 +- .../powerpc/bfp/scalar-test-data-class-4.c | 2 +- .../powerpc/bfp/scalar-test-data-class-5.c | 2 +- .../powerpc/bfp/scalar-test-data-class-9.c | 2 +- .../gcc.target/powerpc/bfp/vec-test-data-class-4.c | 2 +- .../gcc.target/powerpc/bfp/vec-test-data-class-5.c | 2 +- .../gcc.target/powerpc/bfp/vec-test-data-class-6.c | 2 +- .../gcc.target/powerpc/bfp/vec-test-data-class-7.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-12.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-14.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-17.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-19.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-2.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-22.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-24.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-27.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-29.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-32.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-34.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-37.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-39.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-4.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-42.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-44.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-47.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-49.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-52.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-54.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-57.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-59.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-62.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-64.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-67.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-69.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-7.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-72.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-74.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-77.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-79.c | 2 +- gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-9.c | 2 +- gcc/testsuite/gcc.target/powerpc/pr80315-1.c | 2 +- gcc/testsuite/gcc.target/powerpc/pr80315-2.c | 2 +- gcc/testsuite/gcc.target/powerpc/pr80315-3.c | 2 +- gcc/testsuite/gcc.target/powerpc/pr80315-4.c | 2 +- gcc/testsuite/gcc.target/powerpc/pr82015.c | 4 +- gcc/testsuite/gcc.target/powerpc/pr91903.c | 60 +++++++++++----------- .../powerpc/test_fpscr_rn_builtin_error.c | 8 +-- .../gcc.target/powerpc/vec-ternarylogic-10.c | 6 +-- 51 files changed, 89 insertions(+), 87 deletions(-) diff --git a/gcc/config/rs6000/rs6000-call.cc b/gcc/config/rs6000/rs6000-call.cc index 5c870d4..d9bd5ca 100644 --- a/gcc/config/rs6000/rs6000-call.cc +++ b/gcc/config/rs6000/rs6000-call.cc @@ -5717,8 +5717,10 @@ rs6000_expand_builtin (tree exp, rtx target, rtx /* subtarget */, if (!(TREE_CODE (restr_arg) == INTEGER_CST && (TREE_INT_CST_LOW (restr_arg) & ~mask) == 0)) { - error ("argument %d must be a %d-bit unsigned literal", - bifaddr->restr_opnd[i], bifaddr->restr_val1[i]); + unsigned p = (1U << bifaddr->restr_val1[i]) - 1; + error ("argument %d must be a literal between 0 and %d," + " inclusive", + bifaddr->restr_opnd[i], p); return CONST0_RTX (mode[0]); } break; diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-10.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-10.c index 2e3643c..fcf6a9d 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-10.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-10.c @@ -13,6 +13,6 @@ test_data_class (__ieee128 *p, const int condition_flag) { __ieee128 source = *p; - return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-2.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-2.c index 59f03a3..9130c97 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-2.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-2.c @@ -10,6 +10,6 @@ test_data_class (double *p) { double source = *p; - return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-3.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-3.c index d3d9426..b863bb2 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-3.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-3.c @@ -10,6 +10,6 @@ test_data_class (float *p) { float source = *p; - return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-4.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-4.c index 210fa41..83ddffa 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-4.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-4.c @@ -10,6 +10,6 @@ test_data_class (double *p, const int condition_flag) { double source = *p; - return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-5.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-5.c index b66f0a2..101a919 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-5.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-5.c @@ -10,6 +10,6 @@ test_data_class (float *p, const int condition_flag) { float source = *p; - return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-9.c b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-9.c index cfa9a9c..f87851c 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-9.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/scalar-test-data-class-9.c @@ -13,6 +13,6 @@ test_data_class (__ieee128 *p) /* IEEE 128-bit floating point operations are only supported on 64-bit targets. */ - return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return scalar_test_data_class (source, 256); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-4.c b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-4.c index 56ce5f9..448406c 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-4.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-4.c @@ -9,5 +9,5 @@ get_data_class_flags (__vector float *p) { __vector float source = *p; - return vec_test_data_class (source, 256); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return vec_test_data_class (source, 256); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-5.c b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-5.c index 11624c9..64a52a1 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-5.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-5.c @@ -9,5 +9,5 @@ get_data_class_flags (__vector double *p) { __vector double source = *p; - return vec_test_data_class (source, 256); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return vec_test_data_class (source, 256); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-6.c b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-6.c index 2c7e9de..5f35e0e 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-6.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-6.c @@ -9,5 +9,5 @@ get_data_class_flags (__vector float *p, int condition_flag) { __vector float source = *p; - return vec_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return vec_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-7.c b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-7.c index 86eff8d..bda2c6d 100644 --- a/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-7.c +++ b/gcc/testsuite/gcc.target/powerpc/bfp/vec-test-data-class-7.c @@ -9,5 +9,5 @@ get_data_class_flags (__vector double *p, int condition_flag) { __vector double source = *p; - return vec_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a 7-bit unsigned literal" } */ + return vec_test_data_class (source, condition_flag); /* { dg-error "argument 2 must be a literal between 0 and 127, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-12.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-12.c index 350b4c1..4feb391 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-12.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-12.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_lt_dd (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt_dd (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-14.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-14.c index 011d200..ef4d6ad 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-14.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-14.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_lt_dd (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt_dd (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-17.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-17.c index 28033db..5a9ab51 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-17.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-17.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_lt_td (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt_td (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-19.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-19.c index 092b9c0..f1918a2 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-19.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-19.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_lt_td (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt_td (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-2.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-2.c index 4b72fa8..b353d63 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-2.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-2.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_lt (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-22.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-22.c index 15d7a35..464dc66 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-22.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-22.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_gt (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-24.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-24.c index f6ed00a..6e5e07b 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-24.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-24.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_gt (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-27.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-27.c index 8e3954d..d8760ce 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-27.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-27.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_gt (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-29.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-29.c index f6c0ede..fed06bb 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-29.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-29.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_gt (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-32.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-32.c index d24f398..868146c 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-32.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-32.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_gt_dd (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt_dd (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-34.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-34.c index b6620c5..de17499 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-34.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-34.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_gt_dd (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt_dd (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-37.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-37.c index dc4c8ec..1e5ff35 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-37.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-37.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_gt_td (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt_td (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-39.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-39.c index 1aee9ef..b5f886d 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-39.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-39.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_gt_td (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_gt_td (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-4.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-4.c index 6397aae..ad840bf 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-4.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-4.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_lt (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-42.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-42.c index fc6b356..586c86f 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-42.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-42.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_eq (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-44.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-44.c index b896865..dc01b7f 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-44.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-44.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_eq (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-47.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-47.c index edfac68..9ff4126 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-47.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-47.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_eq (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-49.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-49.c index e7b50dc1..5040ac8 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-49.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-49.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_eq (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-52.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-52.c index c9431b5..a79e6b5 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-52.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-52.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_eq_dd (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq_dd (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-54.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-54.c index 2fdb58f..5e9a93f 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-54.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-54.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_eq_dd (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq_dd (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-57.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-57.c index 275bf8d..ec2abc6 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-57.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-57.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_eq_td (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq_td (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-59.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-59.c index e1da3d8..6f63d0f 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-59.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-59.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_eq_td (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_eq_td (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-62.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-62.c index 44aaab2..4786be7 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-62.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-62.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_ov (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-64.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-64.c index fb33311..c406d4d 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-64.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-64.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_ov (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-67.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-67.c index 59471cf..d7b3b6f 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-67.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-67.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_ov (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-69.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-69.c index c9e1721..bc9ced3 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-69.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-69.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_ov (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-7.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-7.c index d0d3f23..dcfe162 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-7.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-7.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_lt (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-72.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-72.c index 725cc54..04d950e 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-72.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-72.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_ov_dd (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov_dd (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-74.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-74.c index c6ffd51..369312d 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-74.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-74.c @@ -8,6 +8,6 @@ int doTestBCDSignificance (_Decimal64 *p, unsigned int significance) { _Decimal64 source = *p; - return __builtin_dfp_dtstsfi_ov_dd (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov_dd (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-77.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-77.c index d279bfb..ca6c739 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-77.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-77.c @@ -8,7 +8,7 @@ int doTestBCDSignificance (_Decimal128 *p) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_ov_td (65, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov_td (65, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-79.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-79.c index b88b5a8..9ee60cf 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-79.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-79.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_ov_td (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_ov_td (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-9.c b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-9.c index b2073f5..9a9ff38 100644 --- a/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-9.c +++ b/gcc/testsuite/gcc.target/powerpc/dfp/dtstsfi-9.c @@ -8,5 +8,5 @@ int doTestBCDSignificance (_Decimal128 *p, unsigned int significance) { _Decimal128 source = *p; - return __builtin_dfp_dtstsfi_lt (significance, source); /* { dg-error "argument 1 must be a 6-bit unsigned literal" } */ + return __builtin_dfp_dtstsfi_lt (significance, source); /* { dg-error "argument 1 must be a literal between 0 and 63, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/pr80315-1.c b/gcc/testsuite/gcc.target/powerpc/pr80315-1.c index f37f1f1..7198611 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr80315-1.c +++ b/gcc/testsuite/gcc.target/powerpc/pr80315-1.c @@ -10,6 +10,6 @@ main() int mask; /* Argument 2 must be 0 or 1. Argument 3 must be in range 0..15. */ - res = __builtin_crypto_vshasigmaw (test, 1, 0xff); /* { dg-error {argument 3 must be a 4-bit unsigned literal} } */ + res = __builtin_crypto_vshasigmaw (test, 1, 0xff); /* { dg-error {argument 3 must be a literal between 0 and 15, inclusive} } */ return 0; } diff --git a/gcc/testsuite/gcc.target/powerpc/pr80315-2.c b/gcc/testsuite/gcc.target/powerpc/pr80315-2.c index 0819a05..0f77f77 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr80315-2.c +++ b/gcc/testsuite/gcc.target/powerpc/pr80315-2.c @@ -10,6 +10,6 @@ main () int mask; /* Argument 2 must be 0 or 1. Argument 3 must be in range 0..15. */ - res = __builtin_crypto_vshasigmad (test, 1, 0xff); /* { dg-error {argument 3 must be a 4-bit unsigned literal} } */ + res = __builtin_crypto_vshasigmad (test, 1, 0xff); /* { dg-error {argument 3 must be a literal between 0 and 15, inclusive} } */ return 0; } diff --git a/gcc/testsuite/gcc.target/powerpc/pr80315-3.c b/gcc/testsuite/gcc.target/powerpc/pr80315-3.c index cc2e46c..398c512 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr80315-3.c +++ b/gcc/testsuite/gcc.target/powerpc/pr80315-3.c @@ -12,6 +12,6 @@ main () int mask; /* Argument 2 must be 0 or 1. Argument 3 must be in range 0..15. */ - res = vec_shasigma_be (test, 1, 0xff); /* { dg-error {argument 3 must be a 4-bit unsigned literal} } */ + res = vec_shasigma_be (test, 1, 0xff); /* { dg-error {argument 3 must be a literal between 0 and 15, inclusive} } */ return res; } diff --git a/gcc/testsuite/gcc.target/powerpc/pr80315-4.c b/gcc/testsuite/gcc.target/powerpc/pr80315-4.c index ac12910..4326ff6 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr80315-4.c +++ b/gcc/testsuite/gcc.target/powerpc/pr80315-4.c @@ -12,6 +12,6 @@ main () int mask; /* Argument 2 must be 0 or 1. Argument 3 must be in range 0..15. */ - res = vec_shasigma_be (test, 1, 0xff); /* { dg-error {argument 3 must be a 4-bit unsigned literal} } */ + res = vec_shasigma_be (test, 1, 0xff); /* { dg-error {argument 3 must be a literal between 0 and 15, inclusive} } */ return res; } diff --git a/gcc/testsuite/gcc.target/powerpc/pr82015.c b/gcc/testsuite/gcc.target/powerpc/pr82015.c index ec939e9..40f1c7d 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr82015.c +++ b/gcc/testsuite/gcc.target/powerpc/pr82015.c @@ -5,10 +5,10 @@ unsigned long foo_11(__vector __int128_t *p) { - return __builtin_unpack_vector_int128(*p, 11); /* { dg-error "argument 2 must be a 1-bit unsigned literal" } */ + return __builtin_unpack_vector_int128(*p, 11); /* { dg-error "argument 2 must be a literal between 0 and 1, inclusive" } */ } unsigned long foo_n(__vector __int128_t *p, unsigned long n) { - return __builtin_unpack_vector_int128(*p, n); /* { dg-error "argument 2 must be a 1-bit unsigned literal" } */ + return __builtin_unpack_vector_int128(*p, n); /* { dg-error "argument 2 must be a literal between 0 and 1, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/pr91903.c b/gcc/testsuite/gcc.target/powerpc/pr91903.c index 3045d07..7f9470e 100644 --- a/gcc/testsuite/gcc.target/powerpc/pr91903.c +++ b/gcc/testsuite/gcc.target/powerpc/pr91903.c @@ -12,62 +12,62 @@ vector signed int retsi; void test_int(vector signed int a, const int b) { - retf = vec_ctf(a,b); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-1); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-31); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retf = vec_ctf(a,b); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-1); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-31); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ retf = vec_ctf(a,1); retf = vec_ctf(a,31); - retf = vec_ctf(a,32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,42); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retf = vec_ctf(a,32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,42); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ } void test_uint(vector unsigned int a, const int b) { - retf = vec_ctf(a,b); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-1); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-31); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,-32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retf = vec_ctf(a,b); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-1); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-31); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,-32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ retf = vec_ctf(a,1); retf = vec_ctf(a,31); - retf = vec_ctf(a,32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retf = vec_ctf(a,42); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retf = vec_ctf(a,32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retf = vec_ctf(a,42); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ } void test_longlong(vector signed long long a, const int b,int x) { - retd = vec_ctf(a,b); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-1); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-31); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retd = vec_ctf(a,b); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-1); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-31); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ retd = vec_ctf(a,1); retd = vec_ctf(a,31); - retd = vec_ctf(a,32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,42); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retd = vec_ctf(a,32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,42); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ } void test_ulonglong(vector unsigned long long a, const int b,int x) { - retd = vec_ctf(a,b); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-1); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-31); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,-32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retd = vec_ctf(a,b); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-1); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-31); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,-32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ retd = vec_ctf(a,1); retd = vec_ctf(a,31); - retd = vec_ctf(a,32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retd = vec_ctf(a,42); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retd = vec_ctf(a,32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retd = vec_ctf(a,42); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ } void test_cts_1(vector float a, const int b) { - retsi = vec_cts(a,b); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retsi = vec_cts(a,-1); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retsi = vec_cts(a,-31); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retsi = vec_cts(a,-32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retsi = vec_cts(a,b); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retsi = vec_cts(a,-1); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retsi = vec_cts(a,-31); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retsi = vec_cts(a,-32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ retsi = vec_cts(a,1); retsi = vec_cts(a,31); - retsi = vec_cts(a,32); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ - retsi = vec_cts(a,42); /* { dg-error "argument 2 must be a 5-bit unsigned literal" } */ + retsi = vec_cts(a,32); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ + retsi = vec_cts(a,42); /* { dg-error "argument 2 must be a literal between 0 and 31, inclusive" } */ } diff --git a/gcc/testsuite/gcc.target/powerpc/test_fpscr_rn_builtin_error.c b/gcc/testsuite/gcc.target/powerpc/test_fpscr_rn_builtin_error.c index 10391b7..62152c6 100644 --- a/gcc/testsuite/gcc.target/powerpc/test_fpscr_rn_builtin_error.c +++ b/gcc/testsuite/gcc.target/powerpc/test_fpscr_rn_builtin_error.c @@ -8,11 +8,11 @@ int main () int arguments. The builtins __builtin_set_fpscr_rn() also supports a variable as an argument but can't test variable value at compile time. */ - __builtin_mtfsb0(-1); /* { dg-error "argument 1 must be a 5-bit unsigned literal" } */ - __builtin_mtfsb0(32); /* { dg-error "argument 1 must be a 5-bit unsigned literal" } */ + __builtin_mtfsb0(-1); /* { dg-error "argument 1 must be a literal between 0 and 31, inclusive" } */ + __builtin_mtfsb0(32); /* { dg-error "argument 1 must be a literal between 0 and 31, inclusive" } */ - __builtin_mtfsb1(-1); /* { dg-error "argument 1 must be a 5-bit unsigned literal" } */ - __builtin_mtfsb1(32); /* { dg-error "argument 1 must be a 5-bit unsigned literal" } */ + __builtin_mtfsb1(-1); /* { dg-error "argument 1 must be a literal between 0 and 31, inclusive" } */ + __builtin_mtfsb1(32); /* { dg-error "argument 1 must be a literal between 0 and 31, inclusive" } */ __builtin_set_fpscr_rn(-1); /* { dg-error "argument 1 must be a variable or a literal between 0 and 3, inclusive" } */ __builtin_set_fpscr_rn(4); /* { dg-error "argument 1 must be a variable or a literal between 0 and 3, inclusive" } */ diff --git a/gcc/testsuite/gcc.target/powerpc/vec-ternarylogic-10.c b/gcc/testsuite/gcc.target/powerpc/vec-ternarylogic-10.c index 35700fc..d5ec14c 100644 --- a/gcc/testsuite/gcc.target/powerpc/vec-ternarylogic-10.c +++ b/gcc/testsuite/gcc.target/powerpc/vec-ternarylogic-10.c @@ -28,7 +28,7 @@ doTests00000001 (vector unsigned __int128 a_sources [], vector unsigned __int128 b = b_sources [j]; vector unsigned __int128 c = c_sources [k]; vector unsigned __int128 result; - result = vec_ternarylogic (a, b, c, 0xfff); /* { dg-error "8-bit unsigned literal" } */ + result = vec_ternarylogic (a, b, c, 0xfff); /* { dg-error "literal between 0 and 255, inclusive" } */ vector unsigned __int128 intended = (a & b & c); if (!vector_equal (result, intended)) abort (); @@ -47,7 +47,7 @@ doTests11100101 (vector unsigned __int128 a_sources [], vector unsigned __int128 b = b_sources [j]; vector unsigned __int128 c = c_sources [k]; vector unsigned __int128 result; - result = vec_ternarylogic (a, b, c, -1); /* { dg-error "8-bit unsigned literal" } */ + result = vec_ternarylogic (a, b, c, -1); /* { dg-error "literal between 0 and 255, inclusive" } */ vector unsigned __int128 intended = { 0 }; // Supposed to be a ? c: nand (b,c) for (int l = 0; l < 1; l++) @@ -80,7 +80,7 @@ doTests11110011 (vector unsigned __int128 a_sources [], vector unsigned __int128 b = b_sources [j]; vector unsigned __int128 c = c_sources [k]; vector unsigned __int128 result; - result = vec_ternarylogic (a, b, c, i); /* { dg-error "8-bit unsigned literal" } */ + result = vec_ternarylogic (a, b, c, i); /* { dg-error "literal between 0 and 255, inclusive" } */ vector unsigned __int128 intended = { 0 }; for (int i = 0; i < 1; i++) intended [i] = b [i] | ~(a [i] & c [i]); -- 2.7.4