public inbox for libstdc++-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-23 12:44 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-23 12:44 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:64c2c61c8dbdd36f2dfff3956a110814a48958d3

commit 64c2c61c8dbdd36f2dfff3956a110814a48958d3
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 20 19:43:55 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-27 10:50 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-27 10:50 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:4a6d546dbd1dd86396645c0c9f4fc2dd0a095986

commit 4a6d546dbd1dd86396645c0c9f4fc2dd0a095986
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 27 05:30:49 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-27  9:33 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-27  9:33 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:a4ecc1ff676282c7498c6ab812cbf42f686a3d56

commit a4ecc1ff676282c7498c6ab812cbf42f686a3d56
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 27 05:30:49 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-23 12:29 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-23 12:29 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:2ef197a97136e3cf003ae554d3b8b11206572aa0

commit 2ef197a97136e3cf003ae554d3b8b11206572aa0
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 20 19:43:55 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-23 12:22 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-23 12:22 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:39ccf6e6d6810f104a5a0e708c630be0fb340f81

commit 39ccf6e6d6810f104a5a0e708c630be0fb340f81
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 20 19:43:55 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-23 10:05 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-23 10:05 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:d44fe95f964a282e8fe898b36529a323e62b5b65

commit d44fe95f964a282e8fe898b36529a323e62b5b65
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 20 19:43:55 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


^ permalink raw reply	[flat|nested] 7+ messages in thread
* [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements
@ 2022-06-23  7:15 Alexandre Oliva
  0 siblings, 0 replies; 7+ messages in thread
From: Alexandre Oliva @ 2022-06-23  7:15 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:ff5d90f41ada9318c5eb01189e6c77f88ac389a6

commit ff5d90f41ada9318c5eb01189e6c77f88ac389a6
Author: Alexandre Oliva <oliva@adacore.com>
Date:   Mon Jun 20 19:43:55 2022 -0300

    libstdc++: testsuite: complex proj requirements
    
    The template version of complex::proj returns its argument without
    testing for infinities, and that's all we have when neither C99
    complex nor C99 math functions are available, and it seems too hard to
    do better without isinf and copysign.
    
    I suppose just calling them and expecting users will supply
    specializations as needed has been ruled out, and so has refraining
    from defining it when it can't be implemented correctly.
    
    It's pointless to run the proj.cc test under these circumstances, so
    arrange for it to be skipped.  In an unusual way, after trying to
    introduce dg-require tests for ccomplex-or-cmath, and found their
    results to be misleading due to variations across -std=* versions.
    
    
    for  libstdc++-v3/ChangeLog
    
            * testsuite/26_numerics/complex/proj.cc: Skip test in the
            circumstances in which the implementation of proj is known to
            be broken.

Diff:
---
 libstdc++-v3/testsuite/26_numerics/complex/proj.cc | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
index a053119197c..69f8153c06f 100644
--- a/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
+++ b/libstdc++-v3/testsuite/26_numerics/complex/proj.cc
@@ -397,6 +397,19 @@ test03()
 int
 main()
 {
+  /* If neither of these macros is nonzero, proj calls a
+     specialization of the __complex_proj template, that just returns
+     its argument, without testing for infinities, rendering the whole
+     test pointless, and failing (as intended/noted in the
+     implementation) the cases that involve infinities.  Alas, the
+     normal ways to skip tests may not work: we don't have a test for
+     C99_COMPLEX, and these macros may vary depending on -std=*, but
+     macro tests wouldn't take them into account.  */
+#if ! (_GLIBCXX_USE_C99_COMPLEX || _GLIBCXX_USE_C99_MATH_TR1)
+  if (true)
+    return 0;
+#endif
+
   test01();
   test02();
   test03();


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

end of thread, other threads:[~2022-06-27 10:50 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-23 12:44 [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: complex proj requirements Alexandre Oliva
  -- strict thread matches above, loose matches on Subject: below --
2022-06-27 10:50 Alexandre Oliva
2022-06-27  9:33 Alexandre Oliva
2022-06-23 12:29 Alexandre Oliva
2022-06-23 12:22 Alexandre Oliva
2022-06-23 10:05 Alexandre Oliva
2022-06-23  7:15 Alexandre Oliva

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).