public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH-1v4] Value Range: Add range op for builtin isinf
@ 2024-07-11  7:32 HAO CHEN GUI
  2024-07-11 14:21 ` Andrew MacLeod
                   ` (2 more replies)
  0 siblings, 3 replies; 16+ messages in thread
From: HAO CHEN GUI @ 2024-07-11  7:32 UTC (permalink / raw)
  To: gcc-patches; +Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner

Hi,
  The builtin isinf is not folded at front end if the corresponding optab
exists. It causes the range evaluation failed on the targets which has
optab_isinf. For instance, range-sincos.c will fail on the targets which
has optab_isinf as it calls builtin_isinf.

  This patch fixed the problem by adding range op for builtin isinf. It
also fixed the issue in PR114678.

  Compared with previous version, the main change is to remove xfail for
s390 in range-sincos.c and vrp-float-abs-1.c.
https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653096.html

  Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no
regressions. Is it OK for the trunk?

Thanks
Gui Haochen


ChangeLog
Value Range: Add range op for builtin isinf

The builtin isinf is not folded at front end if the corresponding optab
exists.  So the range op for isinf is needed for value range analysis.
This patch adds range op for builtin isinf.

gcc/
	PR target/114678
	* gimple-range-op.cc (class cfn_isinf): New.
	(op_cfn_isinf): New variables.
	(gimple_range_op_handler::maybe_builtin_call): Handle
	CASE_FLT_FN (BUILT_IN_ISINF).

gcc/testsuite/
	PR target/114678
	* gcc.dg/tree-ssa/range-isinf.c: New test.
	* gcc.dg/tree-ssa/range-sincos.c: Remove xfail for s390.
	* gcc.dg/tree-ssa/vrp-float-abs-1.c: Likewise.

patch.diff
diff --git a/gcc/gimple-range-op.cc b/gcc/gimple-range-op.cc
index a80b93cf063..24559951dd6 100644
--- a/gcc/gimple-range-op.cc
+++ b/gcc/gimple-range-op.cc
@@ -1153,6 +1153,63 @@ private:
   bool m_is_pos;
 } op_cfn_goacc_dim_size (false), op_cfn_goacc_dim_pos (true);

+// Implement range operator for CFN_BUILT_IN_ISINF
+class cfn_isinf : public range_operator
+{
+public:
+  using range_operator::fold_range;
+  using range_operator::op1_range;
+  virtual bool fold_range (irange &r, tree type, const frange &op1,
+			   const irange &, relation_trio) const override
+  {
+    if (op1.undefined_p ())
+      return false;
+
+    if (op1.known_isinf ())
+      {
+	wide_int one = wi::one (TYPE_PRECISION (type));
+	r.set (type, one, one);
+	return true;
+      }
+
+    if (op1.known_isnan ()
+	|| (!real_isinf (&op1.lower_bound ())
+	    && !real_isinf (&op1.upper_bound ())))
+      {
+	r.set_zero (type);
+	return true;
+      }
+
+    r.set_varying (type);
+    return true;
+  }
+  virtual bool op1_range (frange &r, tree type, const irange &lhs,
+			  const frange &, relation_trio) const override
+  {
+    if (lhs.undefined_p ())
+      return false;
+
+    if (lhs.zero_p ())
+      {
+	nan_state nan (true);
+	r.set (type, real_min_representable (type),
+	       real_max_representable (type), nan);
+	return true;
+      }
+
+    if (!range_includes_zero_p (lhs))
+      {
+	// The range is [-INF,-INF][+INF,+INF], but it can't be represented.
+	// Set range to [-INF,+INF]
+	r.set_varying (type);
+	r.clear_nan ();
+	return true;
+      }
+
+    r.set_varying (type);
+    return true;
+  }
+} op_cfn_isinf;

 // Implement range operator for CFN_BUILT_IN_
 class cfn_parity : public range_operator
@@ -1246,6 +1303,11 @@ gimple_range_op_handler::maybe_builtin_call ()
       m_operator = &op_cfn_signbit;
       break;

+    CASE_FLT_FN (BUILT_IN_ISINF):
+      m_op1 = gimple_call_arg (call, 0);
+      m_operator = &op_cfn_isinf;
+      break;
+
     CASE_CFN_COPYSIGN_ALL:
       m_op1 = gimple_call_arg (call, 0);
       m_op2 = gimple_call_arg (call, 1);
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
new file mode 100644
index 00000000000..468f1bcf5c7
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
@@ -0,0 +1,44 @@
+/* { dg-do compile } */
+/* { dg-options "-O2 -fdump-tree-evrp" } */
+
+#include <math.h>
+void link_error();
+
+void
+test1 (double x)
+{
+  if (x > __DBL_MAX__ && !__builtin_isinf (x))
+    link_error ();
+  if (x < -__DBL_MAX__ && !__builtin_isinf (x))
+    link_error ();
+}
+
+void
+test2 (float x)
+{
+  if (x > __FLT_MAX__ && !__builtin_isinf (x))
+    link_error ();
+  if (x < -__FLT_MAX__ && !__builtin_isinf (x))
+    link_error ();
+}
+
+void
+test3 (double x)
+{
+  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __DBL_MAX__)
+    link_error ();
+  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__DBL_MAX__)
+    link_error ();
+}
+
+void
+test4 (float x)
+{
+  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __FLT_MAX__)
+    link_error ();
+  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__FLT_MAX__)
+    link_error ();
+}
+
+/* { dg-final { scan-tree-dump-not "link_error" "evrp" } } */
+
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
index 35b38c3c914..337f9cda02f 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
@@ -40,4 +40,4 @@ stool (double x)
     link_error ();
 }

-// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } xfail s390*-*-* } } } xfail: PR114678
+// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } } } }
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
index a814a973963..4b7b75833e0 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
@@ -14,4 +14,4 @@ foo (double x, double y)
     }
 }

-// { dg-final { scan-tree-dump-not "link_error" "evrp" { xfail s390*-*-* } } } xfail: PR114678
+// { dg-final { scan-tree-dump-not "link_error" "evrp" } }

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-11  7:32 [PATCH-1v4] Value Range: Add range op for builtin isinf HAO CHEN GUI
@ 2024-07-11 14:21 ` Andrew MacLeod
  2024-07-11 22:13 ` Jeff Law
  2024-07-22  2:07 ` Ping " HAO CHEN GUI
  2 siblings, 0 replies; 16+ messages in thread
From: Andrew MacLeod @ 2024-07-11 14:21 UTC (permalink / raw)
  To: HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner, Jakub Jelinek

I have no issues with any of the range-op work in this patch series,  
but I am unequipped to review the floating point aspects of any of the 
patches.

We just need someone to signoff that this properly reflects those builtins.

Andrew


On 7/11/24 03:32, HAO CHEN GUI wrote:
> Hi,
>    The builtin isinf is not folded at front end if the corresponding optab
> exists. It causes the range evaluation failed on the targets which has
> optab_isinf. For instance, range-sincos.c will fail on the targets which
> has optab_isinf as it calls builtin_isinf.
>
>    This patch fixed the problem by adding range op for builtin isinf. It
> also fixed the issue in PR114678.
>
>    Compared with previous version, the main change is to remove xfail for
> s390 in range-sincos.c and vrp-float-abs-1.c.
> https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653096.html
>
>    Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no
> regressions. Is it OK for the trunk?
>
> Thanks
> Gui Haochen
>
>
> ChangeLog
> Value Range: Add range op for builtin isinf
>
> The builtin isinf is not folded at front end if the corresponding optab
> exists.  So the range op for isinf is needed for value range analysis.
> This patch adds range op for builtin isinf.
>
> gcc/
> 	PR target/114678
> 	* gimple-range-op.cc (class cfn_isinf): New.
> 	(op_cfn_isinf): New variables.
> 	(gimple_range_op_handler::maybe_builtin_call): Handle
> 	CASE_FLT_FN (BUILT_IN_ISINF).
>
> gcc/testsuite/
> 	PR target/114678
> 	* gcc.dg/tree-ssa/range-isinf.c: New test.
> 	* gcc.dg/tree-ssa/range-sincos.c: Remove xfail for s390.
> 	* gcc.dg/tree-ssa/vrp-float-abs-1.c: Likewise.
>
> patch.diff
> diff --git a/gcc/gimple-range-op.cc b/gcc/gimple-range-op.cc
> index a80b93cf063..24559951dd6 100644
> --- a/gcc/gimple-range-op.cc
> +++ b/gcc/gimple-range-op.cc
> @@ -1153,6 +1153,63 @@ private:
>     bool m_is_pos;
>   } op_cfn_goacc_dim_size (false), op_cfn_goacc_dim_pos (true);
>
> +// Implement range operator for CFN_BUILT_IN_ISINF
> +class cfn_isinf : public range_operator
> +{
> +public:
> +  using range_operator::fold_range;
> +  using range_operator::op1_range;
> +  virtual bool fold_range (irange &r, tree type, const frange &op1,
> +			   const irange &, relation_trio) const override
> +  {
> +    if (op1.undefined_p ())
> +      return false;
> +
> +    if (op1.known_isinf ())
> +      {
> +	wide_int one = wi::one (TYPE_PRECISION (type));
> +	r.set (type, one, one);
> +	return true;
> +      }
> +
> +    if (op1.known_isnan ()
> +	|| (!real_isinf (&op1.lower_bound ())
> +	    && !real_isinf (&op1.upper_bound ())))
> +      {
> +	r.set_zero (type);
> +	return true;
> +      }
> +
> +    r.set_varying (type);
> +    return true;
> +  }
> +  virtual bool op1_range (frange &r, tree type, const irange &lhs,
> +			  const frange &, relation_trio) const override
> +  {
> +    if (lhs.undefined_p ())
> +      return false;
> +
> +    if (lhs.zero_p ())
> +      {
> +	nan_state nan (true);
> +	r.set (type, real_min_representable (type),
> +	       real_max_representable (type), nan);
> +	return true;
> +      }
> +
> +    if (!range_includes_zero_p (lhs))
> +      {
> +	// The range is [-INF,-INF][+INF,+INF], but it can't be represented.
> +	// Set range to [-INF,+INF]
> +	r.set_varying (type);
> +	r.clear_nan ();
> +	return true;
> +      }
> +
> +    r.set_varying (type);
> +    return true;
> +  }
> +} op_cfn_isinf;
>
>   // Implement range operator for CFN_BUILT_IN_
>   class cfn_parity : public range_operator
> @@ -1246,6 +1303,11 @@ gimple_range_op_handler::maybe_builtin_call ()
>         m_operator = &op_cfn_signbit;
>         break;
>
> +    CASE_FLT_FN (BUILT_IN_ISINF):
> +      m_op1 = gimple_call_arg (call, 0);
> +      m_operator = &op_cfn_isinf;
> +      break;
> +
>       CASE_CFN_COPYSIGN_ALL:
>         m_op1 = gimple_call_arg (call, 0);
>         m_op2 = gimple_call_arg (call, 1);
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
> new file mode 100644
> index 00000000000..468f1bcf5c7
> --- /dev/null
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
> @@ -0,0 +1,44 @@
> +/* { dg-do compile } */
> +/* { dg-options "-O2 -fdump-tree-evrp" } */
> +
> +#include <math.h>
> +void link_error();
> +
> +void
> +test1 (double x)
> +{
> +  if (x > __DBL_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +  if (x < -__DBL_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +}
> +
> +void
> +test2 (float x)
> +{
> +  if (x > __FLT_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +  if (x < -__FLT_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +}
> +
> +void
> +test3 (double x)
> +{
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __DBL_MAX__)
> +    link_error ();
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__DBL_MAX__)
> +    link_error ();
> +}
> +
> +void
> +test4 (float x)
> +{
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __FLT_MAX__)
> +    link_error ();
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__FLT_MAX__)
> +    link_error ();
> +}
> +
> +/* { dg-final { scan-tree-dump-not "link_error" "evrp" } } */
> +
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> index 35b38c3c914..337f9cda02f 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> @@ -40,4 +40,4 @@ stool (double x)
>       link_error ();
>   }
>
> -// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } xfail s390*-*-* } } } xfail: PR114678
> +// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } } } }
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> index a814a973963..4b7b75833e0 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> @@ -14,4 +14,4 @@ foo (double x, double y)
>       }
>   }
>
> -// { dg-final { scan-tree-dump-not "link_error" "evrp" { xfail s390*-*-* } } } xfail: PR114678
> +// { dg-final { scan-tree-dump-not "link_error" "evrp" } }
>


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-11  7:32 [PATCH-1v4] Value Range: Add range op for builtin isinf HAO CHEN GUI
  2024-07-11 14:21 ` Andrew MacLeod
@ 2024-07-11 22:13 ` Jeff Law
  2024-07-12  3:17   ` HAO CHEN GUI
  2024-07-22  2:07 ` Ping " HAO CHEN GUI
  2 siblings, 1 reply; 16+ messages in thread
From: Jeff Law @ 2024-07-11 22:13 UTC (permalink / raw)
  To: HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner



On 7/11/24 1:32 AM, HAO CHEN GUI wrote:
> Hi,
>    The builtin isinf is not folded at front end if the corresponding optab
> exists. It causes the range evaluation failed on the targets which has
> optab_isinf. For instance, range-sincos.c will fail on the targets which
> has optab_isinf as it calls builtin_isinf.
> 
>    This patch fixed the problem by adding range op for builtin isinf. It
> also fixed the issue in PR114678.
> 
>    Compared with previous version, the main change is to remove xfail for
> s390 in range-sincos.c and vrp-float-abs-1.c.
> https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653096.html
> 
>    Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no
> regressions. Is it OK for the trunk?
> 
> Thanks
> Gui Haochen
> 
> 
> ChangeLog
> Value Range: Add range op for builtin isinf
> 
> The builtin isinf is not folded at front end if the corresponding optab
> exists.  So the range op for isinf is needed for value range analysis.
> This patch adds range op for builtin isinf.
> 
> gcc/
> 	PR target/114678
> 	* gimple-range-op.cc (class cfn_isinf): New.
> 	(op_cfn_isinf): New variables.
> 	(gimple_range_op_handler::maybe_builtin_call): Handle
> 	CASE_FLT_FN (BUILT_IN_ISINF).
> 
> gcc/testsuite/
> 	PR target/114678
> 	* gcc.dg/tree-ssa/range-isinf.c: New test.
> 	* gcc.dg/tree-ssa/range-sincos.c: Remove xfail for s390.
> 	* gcc.dg/tree-ssa/vrp-float-abs-1.c: Likewise.
> 
> patch.diff
> diff --git a/gcc/gimple-range-op.cc b/gcc/gimple-range-op.cc
> index a80b93cf063..24559951dd6 100644
> --- a/gcc/gimple-range-op.cc
> +++ b/gcc/gimple-range-op.cc
> @@ -1153,6 +1153,63 @@ private:
>     bool m_is_pos;
>   } op_cfn_goacc_dim_size (false), op_cfn_goacc_dim_pos (true);
> 
> +// Implement range operator for CFN_BUILT_IN_ISINF
> +class cfn_isinf : public range_operator
> +{
> +public:
> +  using range_operator::fold_range;
> +  using range_operator::op1_range;
> +  virtual bool fold_range (irange &r, tree type, const frange &op1,
> +			   const irange &, relation_trio) const override
> +  {
> +    if (op1.undefined_p ())
> +      return false;
> +
> +    if (op1.known_isinf ())
> +      {
> +	wide_int one = wi::one (TYPE_PRECISION (type));
> +	r.set (type, one, one);
> +	return true;
> +      }
> +
> +    if (op1.known_isnan ()
> +	|| (!real_isinf (&op1.lower_bound ())
> +	    && !real_isinf (&op1.upper_bound ())))
> +      {
> +	r.set_zero (type);
> +	return true;
> +      }
So why the test for real_isinf on the upper/lower bound?  If op1 is 
known to be a NaN, then why test the bounds at all?  If a bounds test is 
needed, why only test the upper bound?


> +  virtual bool op1_range (frange &r, tree type, const irange &lhs,
> +			  const frange &, relation_trio) const override
> +  {
> +    if (lhs.undefined_p ())
> +      return false;
> +
> +    if (lhs.zero_p ())
> +      {
> +	nan_state nan (true);
> +	r.set (type, real_min_representable (type),
> +	       real_max_representable (type), nan);
> +	return true;
> +      }
If the result of a builtin_isinf is zero, that doesn't mean the input 
has a nan state.  It means we know it's not infinity.  The input 
argument could be anything but an Inf.


Jeff

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-11 22:13 ` Jeff Law
@ 2024-07-12  3:17   ` HAO CHEN GUI
  2024-07-23 19:18     ` Jeff Law
  0 siblings, 1 reply; 16+ messages in thread
From: HAO CHEN GUI @ 2024-07-12  3:17 UTC (permalink / raw)
  To: Jeff Law, gcc-patches; +Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner

Hi Jeff,
  Thanks for your comments.

在 2024/7/12 6:13, Jeff Law 写道:
> 
> 
> On 7/11/24 1:32 AM, HAO CHEN GUI wrote:
>> Hi,
>>    The builtin isinf is not folded at front end if the corresponding optab
>> exists. It causes the range evaluation failed on the targets which has
>> optab_isinf. For instance, range-sincos.c will fail on the targets which
>> has optab_isinf as it calls builtin_isinf.
>>
>>    This patch fixed the problem by adding range op for builtin isinf. It
>> also fixed the issue in PR114678.
>>
>>    Compared with previous version, the main change is to remove xfail for
>> s390 in range-sincos.c and vrp-float-abs-1.c.
>> https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653096.html
>>
>>    Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no
>> regressions. Is it OK for the trunk?
>>
>> Thanks
>> Gui Haochen
>>
>>
>> ChangeLog
>> Value Range: Add range op for builtin isinf
>>
>> The builtin isinf is not folded at front end if the corresponding optab
>> exists.  So the range op for isinf is needed for value range analysis.
>> This patch adds range op for builtin isinf.
>>
>> gcc/
>>     PR target/114678
>>     * gimple-range-op.cc (class cfn_isinf): New.
>>     (op_cfn_isinf): New variables.
>>     (gimple_range_op_handler::maybe_builtin_call): Handle
>>     CASE_FLT_FN (BUILT_IN_ISINF).
>>
>> gcc/testsuite/
>>     PR target/114678
>>     * gcc.dg/tree-ssa/range-isinf.c: New test.
>>     * gcc.dg/tree-ssa/range-sincos.c: Remove xfail for s390.
>>     * gcc.dg/tree-ssa/vrp-float-abs-1.c: Likewise.
>>
>> patch.diff
>> diff --git a/gcc/gimple-range-op.cc b/gcc/gimple-range-op.cc
>> index a80b93cf063..24559951dd6 100644
>> --- a/gcc/gimple-range-op.cc
>> +++ b/gcc/gimple-range-op.cc
>> @@ -1153,6 +1153,63 @@ private:
>>     bool m_is_pos;
>>   } op_cfn_goacc_dim_size (false), op_cfn_goacc_dim_pos (true);
>>
>> +// Implement range operator for CFN_BUILT_IN_ISINF
>> +class cfn_isinf : public range_operator
>> +{
>> +public:
>> +  using range_operator::fold_range;
>> +  using range_operator::op1_range;
>> +  virtual bool fold_range (irange &r, tree type, const frange &op1,
>> +               const irange &, relation_trio) const override
>> +  {
>> +    if (op1.undefined_p ())
>> +      return false;
>> +
>> +    if (op1.known_isinf ())
>> +      {
>> +    wide_int one = wi::one (TYPE_PRECISION (type));
>> +    r.set (type, one, one);
>> +    return true;
>> +      }
>> +
>> +    if (op1.known_isnan ()
>> +    || (!real_isinf (&op1.lower_bound ())
>> +        && !real_isinf (&op1.upper_bound ())))
>> +      {
>> +    r.set_zero (type);
>> +    return true;
>> +      }
> So why the test for real_isinf on the upper/lower bound?  If op1 is known to be a NaN, then why test the bounds at all?  If a bounds test is needed, why only test the upper bound?
> 
IMHO, logical is if the op1 is a NAN, it's not an infinite number. If the upper
and lower bound both are finite numbers, the op1 is not an infinite number.
Under both situations, the result should be set to 0 which means op1 isn't an
infinite number.
> 
>> +  virtual bool op1_range (frange &r, tree type, const irange &lhs,
>> +              const frange &, relation_trio) const override
>> +  {
>> +    if (lhs.undefined_p ())
>> +      return false;
>> +
>> +    if (lhs.zero_p ())
>> +      {
>> +    nan_state nan (true);
>> +    r.set (type, real_min_representable (type),
>> +           real_max_representable (type), nan);
>> +    return true;
>> +      }
> If the result of a builtin_isinf is zero, that doesn't mean the input has a nan state.  It means we know it's not infinity.  The input argument could be anything but an Inf.
> 
If the result of a builtin_isinf is zero, it means the input might be a NAN or
a finite number. So the range should be [min_rep, max_rep] U NAN.

Looking forward to your further comments.

Thanks
Gui Haochen
> 
> Jeff

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Ping [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-11  7:32 [PATCH-1v4] Value Range: Add range op for builtin isinf HAO CHEN GUI
  2024-07-11 14:21 ` Andrew MacLeod
  2024-07-11 22:13 ` Jeff Law
@ 2024-07-22  2:07 ` HAO CHEN GUI
  2 siblings, 0 replies; 16+ messages in thread
From: HAO CHEN GUI @ 2024-07-22  2:07 UTC (permalink / raw)
  To: gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner, MacLeod,
	Andrew, Jeff Law

Hi,
  Gently ping it.
https://gcc.gnu.org/pipermail/gcc-patches/2024-July/656937.html

Thanks
Gui Haochen

在 2024/7/11 15:32, HAO CHEN GUI 写道:
> Hi,
>   The builtin isinf is not folded at front end if the corresponding optab
> exists. It causes the range evaluation failed on the targets which has
> optab_isinf. For instance, range-sincos.c will fail on the targets which
> has optab_isinf as it calls builtin_isinf.
> 
>   This patch fixed the problem by adding range op for builtin isinf. It
> also fixed the issue in PR114678.
> 
>   Compared with previous version, the main change is to remove xfail for
> s390 in range-sincos.c and vrp-float-abs-1.c.
> https://gcc.gnu.org/pipermail/gcc-patches/2024-May/653096.html
> 
>   Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no
> regressions. Is it OK for the trunk?
> 
> Thanks
> Gui Haochen
> 
> 
> ChangeLog
> Value Range: Add range op for builtin isinf
> 
> The builtin isinf is not folded at front end if the corresponding optab
> exists.  So the range op for isinf is needed for value range analysis.
> This patch adds range op for builtin isinf.
> 
> gcc/
> 	PR target/114678
> 	* gimple-range-op.cc (class cfn_isinf): New.
> 	(op_cfn_isinf): New variables.
> 	(gimple_range_op_handler::maybe_builtin_call): Handle
> 	CASE_FLT_FN (BUILT_IN_ISINF).
> 
> gcc/testsuite/
> 	PR target/114678
> 	* gcc.dg/tree-ssa/range-isinf.c: New test.
> 	* gcc.dg/tree-ssa/range-sincos.c: Remove xfail for s390.
> 	* gcc.dg/tree-ssa/vrp-float-abs-1.c: Likewise.
> 
> patch.diff
> diff --git a/gcc/gimple-range-op.cc b/gcc/gimple-range-op.cc
> index a80b93cf063..24559951dd6 100644
> --- a/gcc/gimple-range-op.cc
> +++ b/gcc/gimple-range-op.cc
> @@ -1153,6 +1153,63 @@ private:
>    bool m_is_pos;
>  } op_cfn_goacc_dim_size (false), op_cfn_goacc_dim_pos (true);
> 
> +// Implement range operator for CFN_BUILT_IN_ISINF
> +class cfn_isinf : public range_operator
> +{
> +public:
> +  using range_operator::fold_range;
> +  using range_operator::op1_range;
> +  virtual bool fold_range (irange &r, tree type, const frange &op1,
> +			   const irange &, relation_trio) const override
> +  {
> +    if (op1.undefined_p ())
> +      return false;
> +
> +    if (op1.known_isinf ())
> +      {
> +	wide_int one = wi::one (TYPE_PRECISION (type));
> +	r.set (type, one, one);
> +	return true;
> +      }
> +
> +    if (op1.known_isnan ()
> +	|| (!real_isinf (&op1.lower_bound ())
> +	    && !real_isinf (&op1.upper_bound ())))
> +      {
> +	r.set_zero (type);
> +	return true;
> +      }
> +
> +    r.set_varying (type);
> +    return true;
> +  }
> +  virtual bool op1_range (frange &r, tree type, const irange &lhs,
> +			  const frange &, relation_trio) const override
> +  {
> +    if (lhs.undefined_p ())
> +      return false;
> +
> +    if (lhs.zero_p ())
> +      {
> +	nan_state nan (true);
> +	r.set (type, real_min_representable (type),
> +	       real_max_representable (type), nan);
> +	return true;
> +      }
> +
> +    if (!range_includes_zero_p (lhs))
> +      {
> +	// The range is [-INF,-INF][+INF,+INF], but it can't be represented.
> +	// Set range to [-INF,+INF]
> +	r.set_varying (type);
> +	r.clear_nan ();
> +	return true;
> +      }
> +
> +    r.set_varying (type);
> +    return true;
> +  }
> +} op_cfn_isinf;
> 
>  // Implement range operator for CFN_BUILT_IN_
>  class cfn_parity : public range_operator
> @@ -1246,6 +1303,11 @@ gimple_range_op_handler::maybe_builtin_call ()
>        m_operator = &op_cfn_signbit;
>        break;
> 
> +    CASE_FLT_FN (BUILT_IN_ISINF):
> +      m_op1 = gimple_call_arg (call, 0);
> +      m_operator = &op_cfn_isinf;
> +      break;
> +
>      CASE_CFN_COPYSIGN_ALL:
>        m_op1 = gimple_call_arg (call, 0);
>        m_op2 = gimple_call_arg (call, 1);
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
> new file mode 100644
> index 00000000000..468f1bcf5c7
> --- /dev/null
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/range-isinf.c
> @@ -0,0 +1,44 @@
> +/* { dg-do compile } */
> +/* { dg-options "-O2 -fdump-tree-evrp" } */
> +
> +#include <math.h>
> +void link_error();
> +
> +void
> +test1 (double x)
> +{
> +  if (x > __DBL_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +  if (x < -__DBL_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +}
> +
> +void
> +test2 (float x)
> +{
> +  if (x > __FLT_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +  if (x < -__FLT_MAX__ && !__builtin_isinf (x))
> +    link_error ();
> +}
> +
> +void
> +test3 (double x)
> +{
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __DBL_MAX__)
> +    link_error ();
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__DBL_MAX__)
> +    link_error ();
> +}
> +
> +void
> +test4 (float x)
> +{
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x > __FLT_MAX__)
> +    link_error ();
> +  if (!__builtin_isinf (x) && !__builtin_isnan (x) && x < -__FLT_MAX__)
> +    link_error ();
> +}
> +
> +/* { dg-final { scan-tree-dump-not "link_error" "evrp" } } */
> +
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> index 35b38c3c914..337f9cda02f 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/range-sincos.c
> @@ -40,4 +40,4 @@ stool (double x)
>      link_error ();
>  }
> 
> -// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } xfail s390*-*-* } } } xfail: PR114678
> +// { dg-final { scan-tree-dump-not "link_error" "evrp" { target { { *-*-linux* } && { glibc } } } } }
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> index a814a973963..4b7b75833e0 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/vrp-float-abs-1.c
> @@ -14,4 +14,4 @@ foo (double x, double y)
>      }
>  }
> 
> -// { dg-final { scan-tree-dump-not "link_error" "evrp" { xfail s390*-*-* } } } xfail: PR114678
> +// { dg-final { scan-tree-dump-not "link_error" "evrp" } }

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-12  3:17   ` HAO CHEN GUI
@ 2024-07-23 19:18     ` Jeff Law
  2024-07-23 22:39       ` Andrew MacLeod
  0 siblings, 1 reply; 16+ messages in thread
From: Jeff Law @ 2024-07-23 19:18 UTC (permalink / raw)
  To: HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner



On 7/11/24 9:17 PM, HAO CHEN GUI wrote:

>> So why the test for real_isinf on the upper/lower bound?  If op1 is known to be a NaN, then why test the bounds at all?  If a bounds test is needed, why only test the upper bound?
>>
> IMHO, logical is if the op1 is a NAN, it's not an infinite number. If the upper
> and lower bound both are finite numbers, the op1 is not an infinite number.
> Under both situations, the result should be set to 0 which means op1 isn't an
> infinite number.
Understood, but that's not what the code actually implements:

>>> +    if (op1.known_isnan ()
>>> +    || (!real_isinf (&op1.lower_bound ())
>>> +        && !real_isinf (&op1.upper_bound ())))
>>> +      {
>>> +    r.set_zero (type);
>>> +    return true;
>>> +      }
If op1 is a NaN, then it it can not be Inf.  Similarly if both of the 
bounds are known not to be Inf, then op1 is not Inf and thus we should 
be returning false instead of true.  Or am I mis-understanding this API?








>>
>>> +  virtual bool op1_range (frange &r, tree type, const irange &lhs,
>>> +              const frange &, relation_trio) const override
>>> +  {
>>> +    if (lhs.undefined_p ())
>>> +      return false;
>>> +
>>> +    if (lhs.zero_p ())
>>> +      {
>>> +    nan_state nan (true);
>>> +    r.set (type, real_min_representable (type),
>>> +           real_max_representable (type), nan);
>>> +    return true;
>>> +      }
>> If the result of a builtin_isinf is zero, that doesn't mean the input has a nan state.  It means we know it's not infinity.  The input argument could be anything but an Inf.
>>
> If the result of a builtin_isinf is zero, it means the input might be a NAN or
> a finite number. So the range should be [min_rep, max_rep] U NAN.
ACK.

jeff


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-23 19:18     ` Jeff Law
@ 2024-07-23 22:39       ` Andrew MacLeod
  2024-07-29  8:28         ` HAO CHEN GUI
  2024-08-05 14:51         ` Jeff Law
  0 siblings, 2 replies; 16+ messages in thread
From: Andrew MacLeod @ 2024-07-23 22:39 UTC (permalink / raw)
  To: Jeff Law, HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner


On 7/23/24 15:18, Jeff Law wrote:
>
>
> On 7/11/24 9:17 PM, HAO CHEN GUI wrote:
>
>>> So why the test for real_isinf on the upper/lower bound?  If op1 is 
>>> known to be a NaN, then why test the bounds at all?  If a bounds 
>>> test is needed, why only test the upper bound?
>>>
>> IMHO, logical is if the op1 is a NAN, it's not an infinite number. If 
>> the upper
>> and lower bound both are finite numbers, the op1 is not an infinite 
>> number.
>> Under both situations, the result should be set to 0 which means op1 
>> isn't an
>> infinite number.
> Understood, but that's not what the code actually implements:
>
>>>> +    if (op1.known_isnan ()
>>>> +    || (!real_isinf (&op1.lower_bound ())
>>>> +        && !real_isinf (&op1.upper_bound ())))
>>>> +      {
>>>> +    r.set_zero (type);
>>>> +    return true;
>>>> +      }
> If op1 is a NaN, then it it can not be Inf.  Similarly if both of the 
> bounds are known not to be Inf, then op1 is not Inf and thus we should 
> be returning false instead of true.  Or am I mis-understanding this API?
>
>
the range is in r, and is set to [0,0].  this is the false part of what 
is being returned for the range.

the "return true" indicates we determined a range, so use what is in R.

returning false means we did not find a range to return, so r is garbage.



^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-23 22:39       ` Andrew MacLeod
@ 2024-07-29  8:28         ` HAO CHEN GUI
  2024-08-05 14:51         ` Jeff Law
  1 sibling, 0 replies; 16+ messages in thread
From: HAO CHEN GUI @ 2024-07-29  8:28 UTC (permalink / raw)
  To: Jeff Law, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner, Andrew MacLeod

Hi Jeff,
  Do you have further questions?

Thanks
Gui Haochen

在 2024/7/24 6:39, Andrew MacLeod 写道:
> 
> On 7/23/24 15:18, Jeff Law wrote:
>>
>>
>> On 7/11/24 9:17 PM, HAO CHEN GUI wrote:
>>
>>>> So why the test for real_isinf on the upper/lower bound?  If op1 is known to be a NaN, then why test the bounds at all?  If a bounds test is needed, why only test the upper bound?
>>>>
>>> IMHO, logical is if the op1 is a NAN, it's not an infinite number. If the upper
>>> and lower bound both are finite numbers, the op1 is not an infinite number.
>>> Under both situations, the result should be set to 0 which means op1 isn't an
>>> infinite number.
>> Understood, but that's not what the code actually implements:
>>
>>>>> +    if (op1.known_isnan ()
>>>>> +    || (!real_isinf (&op1.lower_bound ())
>>>>> +        && !real_isinf (&op1.upper_bound ())))
>>>>> +      {
>>>>> +    r.set_zero (type);
>>>>> +    return true;
>>>>> +      }
>> If op1 is a NaN, then it it can not be Inf.  Similarly if both of the bounds are known not to be Inf, then op1 is not Inf and thus we should be returning false instead of true.  Or am I mis-understanding this API?
>>
>>
> the range is in r, and is set to [0,0].  this is the false part of what is being returned for the range.
> 
> the "return true" indicates we determined a range, so use what is in R.
> 
> returning false means we did not find a range to return, so r is garbage.
> 
> 

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-07-23 22:39       ` Andrew MacLeod
  2024-07-29  8:28         ` HAO CHEN GUI
@ 2024-08-05 14:51         ` Jeff Law
  2024-08-14  7:04           ` HAO CHEN GUI
  2024-08-14 18:29           ` Vineet Gupta
  1 sibling, 2 replies; 16+ messages in thread
From: Jeff Law @ 2024-08-05 14:51 UTC (permalink / raw)
  To: Andrew MacLeod, HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner



On 7/23/24 4:39 PM, Andrew MacLeod wrote:
> the range is in r, and is set to [0,0].  this is the false part of what 
> is being returned for the range.
> 
> the "return true" indicates we determined a range, so use what is in R.
> 
> returning false means we did not find a range to return, so r is garbage.
Duh.  I guess I should have realized that.  I'll have to take another 
look at Hao's patch.  It's likely OK, but let me take another looksie.

jeff


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-05 14:51         ` Jeff Law
@ 2024-08-14  7:04           ` HAO CHEN GUI
  2024-08-14 13:16             ` Jeff Law
  2024-08-14 18:29           ` Vineet Gupta
  1 sibling, 1 reply; 16+ messages in thread
From: HAO CHEN GUI @ 2024-08-14  7:04 UTC (permalink / raw)
  To: Jeff Law, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner, Andrew MacLeod

Hi Jeff,

  May I know your final decision on this patch?
https://gcc.gnu.org/pipermail/gcc-patches/2024-July/656937.html

Thanks
Gui Haochen

在 2024/8/5 22:51, Jeff Law 写道:
> 
> 
> On 7/23/24 4:39 PM, Andrew MacLeod wrote:
>> the range is in r, and is set to [0,0].  this is the false part of what is being returned for the range.
>>
>> the "return true" indicates we determined a range, so use what is in R.
>>
>> returning false means we did not find a range to return, so r is garbage.
> Duh.  I guess I should have realized that.  I'll have to take another look at Hao's patch.  It's likely OK, but let me take another looksie.
> 
> jeff
> 

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-14  7:04           ` HAO CHEN GUI
@ 2024-08-14 13:16             ` Jeff Law
  0 siblings, 0 replies; 16+ messages in thread
From: Jeff Law @ 2024-08-14 13:16 UTC (permalink / raw)
  To: HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner, Andrew MacLeod



On 8/14/24 1:04 AM, HAO CHEN GUI wrote:
> Hi Jeff,
> 
>    May I know your final decision on this patch?
> https://gcc.gnu.org/pipermail/gcc-patches/2024-July/656937.html
I thought I acked the whole set.

Jeff


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-05 14:51         ` Jeff Law
  2024-08-14  7:04           ` HAO CHEN GUI
@ 2024-08-14 18:29           ` Vineet Gupta
  2024-08-14 18:38             ` Sam James
  1 sibling, 1 reply; 16+ messages in thread
From: Vineet Gupta @ 2024-08-14 18:29 UTC (permalink / raw)
  To: Jeff Law, Andrew MacLeod, HAO CHEN GUI, gcc-patches
  Cc: Segher Boessenkool, David, Kewen.Lin, Peter Bergner

Ping - looks like this is blocking the patches for builtin_isnormal and builtin_isfinite !

Thx,
-Vineet

On 8/5/24 07:51, Jeff Law wrote:
>
> On 7/23/24 4:39 PM, Andrew MacLeod wrote:
>> the range is in r, and is set to [0,0].  this is the false part of what 
>> is being returned for the range.
>>
>> the "return true" indicates we determined a range, so use what is in R.
>>
>> returning false means we did not find a range to return, so r is garbage.
> Duh.  I guess I should have realized that.  I'll have to take another 
> look at Hao's patch.  It's likely OK, but let me take another looksie.
>
> jeff
>
>


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-14 18:29           ` Vineet Gupta
@ 2024-08-14 18:38             ` Sam James
  2024-08-14 18:49               ` Vineet Gupta
  2024-08-14 21:46               ` Jeff Law
  0 siblings, 2 replies; 16+ messages in thread
From: Sam James @ 2024-08-14 18:38 UTC (permalink / raw)
  To: Vineet Gupta
  Cc: Jeff Law, Andrew MacLeod, HAO CHEN GUI, gcc-patches,
	Segher Boessenkool, David, Kewen.Lin, Peter Bergner

Vineet Gupta <vineetg@rivosinc.com> writes:

> Ping - looks like this is blocking the patches for builtin_isnormal and builtin_isfinite !
>

See https://inbox.sourceware.org/gcc-patches/d9459db0-7301-40f6-a3cf-077017b8cdd6@gmail.com/.

It appears to be approved.

(Please also avoid topposting.)

> Thx,
> -Vineet
>
> On 8/5/24 07:51, Jeff Law wrote:
>>
>> On 7/23/24 4:39 PM, Andrew MacLeod wrote:
>>> the range is in r, and is set to [0,0].  this is the false part of what 
>>> is being returned for the range.
>>>
>>> the "return true" indicates we determined a range, so use what is in R.
>>>
>>> returning false means we did not find a range to return, so r is garbage.
>> Duh.  I guess I should have realized that.  I'll have to take another 
>> look at Hao's patch.  It's likely OK, but let me take another looksie.
>>
>> jeff
>>
>>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-14 18:38             ` Sam James
@ 2024-08-14 18:49               ` Vineet Gupta
  2024-08-14 21:46               ` Jeff Law
  1 sibling, 0 replies; 16+ messages in thread
From: Vineet Gupta @ 2024-08-14 18:49 UTC (permalink / raw)
  To: Sam James
  Cc: Jeff Law, Andrew MacLeod, HAO CHEN GUI, gcc-patches,
	Segher Boessenkool, David, Kewen.Lin, Peter Bergner



On 8/14/24 11:38, Sam James wrote:
>> Ping - looks like this is blocking the patches for builtin_isnormal and builtin_isfinite !
>>
> See https://inbox.sourceware.org/gcc-patches/d9459db0-7301-40f6-a3cf-077017b8cdd6@gmail.com/.
>
> It appears to be approved.

Sorry, should have refreshed my newsreader feed before posting.


> (Please also avoid topposting.)

Sure, I generally do, except gcc pings seem to be top posted.

Thx,
-Vineet

>
>> Thx,
>> -Vineet
>>
>> On 8/5/24 07:51, Jeff Law wrote:
>>> On 7/23/24 4:39 PM, Andrew MacLeod wrote:
>>>> the range is in r, and is set to [0,0].  this is the false part of what 
>>>> is being returned for the range.
>>>>
>>>> the "return true" indicates we determined a range, so use what is in R.
>>>>
>>>> returning false means we did not find a range to return, so r is garbage.
>>> Duh.  I guess I should have realized that.  I'll have to take another 
>>> look at Hao's patch.  It's likely OK, but let me take another looksie.
>>>
>>> jeff
>>>
>>>


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-14 18:38             ` Sam James
  2024-08-14 18:49               ` Vineet Gupta
@ 2024-08-14 21:46               ` Jeff Law
  2024-08-15  3:32                 ` HAO CHEN GUI
  1 sibling, 1 reply; 16+ messages in thread
From: Jeff Law @ 2024-08-14 21:46 UTC (permalink / raw)
  To: Sam James, Vineet Gupta
  Cc: Andrew MacLeod, HAO CHEN GUI, gcc-patches, Segher Boessenkool,
	David, Kewen.Lin, Peter Bergner



On 8/14/24 12:38 PM, Sam James wrote:
> Vineet Gupta <vineetg@rivosinc.com> writes:
> 
>> Ping - looks like this is blocking the patches for builtin_isnormal and builtin_isfinite !
>>
> 
> See https://inbox.sourceware.org/gcc-patches/d9459db0-7301-40f6-a3cf-077017b8cdd6@gmail.com/.
> 
> It appears to be approved.
> 
> (Please also avoid topposting.)
And just to be clear, the isinf patch is OK as well.

jeff


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH-1v4] Value Range: Add range op for builtin isinf
  2024-08-14 21:46               ` Jeff Law
@ 2024-08-15  3:32                 ` HAO CHEN GUI
  0 siblings, 0 replies; 16+ messages in thread
From: HAO CHEN GUI @ 2024-08-15  3:32 UTC (permalink / raw)
  To: Jeff Law, Sam James, Vineet Gupta
  Cc: Andrew MacLeod, gcc-patches, Segher Boessenkool, David,
	Kewen.Lin, Peter Bergner

Hi All,
  These three value range patches were committed as r15-2922, r15-2923 and r15-2924.

Thanks
Gui Haochen

在 2024/8/15 5:46, Jeff Law 写道:
> 
> 
> On 8/14/24 12:38 PM, Sam James wrote:
>> Vineet Gupta <vineetg@rivosinc.com> writes:
>>
>>> Ping - looks like this is blocking the patches for builtin_isnormal and builtin_isfinite !
>>>
>>
>> See https://inbox.sourceware.org/gcc-patches/d9459db0-7301-40f6-a3cf-077017b8cdd6@gmail.com/.
>>
>> It appears to be approved.
>>
>> (Please also avoid topposting.)
> And just to be clear, the isinf patch is OK as well.
> 
> jeff
> 

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2024-08-15  3:32 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-07-11  7:32 [PATCH-1v4] Value Range: Add range op for builtin isinf HAO CHEN GUI
2024-07-11 14:21 ` Andrew MacLeod
2024-07-11 22:13 ` Jeff Law
2024-07-12  3:17   ` HAO CHEN GUI
2024-07-23 19:18     ` Jeff Law
2024-07-23 22:39       ` Andrew MacLeod
2024-07-29  8:28         ` HAO CHEN GUI
2024-08-05 14:51         ` Jeff Law
2024-08-14  7:04           ` HAO CHEN GUI
2024-08-14 13:16             ` Jeff Law
2024-08-14 18:29           ` Vineet Gupta
2024-08-14 18:38             ` Sam James
2024-08-14 18:49               ` Vineet Gupta
2024-08-14 21:46               ` Jeff Law
2024-08-15  3:32                 ` HAO CHEN GUI
2024-07-22  2:07 ` Ping " HAO CHEN GUI

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).