On Fri, Aug 13, 2021 at 12:09:24AM -0400, Michael Meissner wrote:
> This patch adds 3 more selections to target-supports.exp to see if we can
> specify to use a particular long double format (IEEE 128-bit, IBM extended
> double, 64-bit), and the library support will track the changes for the long
> double.  This is needed because two of the tests in the test suite use long
> double, and they are actually testing IBM extended double.
> 
> This patch also forces the two tests that explicitly require long double
> to use the IBM double-double encoding to explicitly run the test.  This
> requires GLIBC 2.32 or greater in order to do the switch.

> I did not remove the void * casts in calling memcmp, because not having those
> casts will cause the test to fail.  This is because the variables are declared
> volatile, and GCC now complains that you are discarding the volatile in doing
> the call.  Having this warning makes the test fail.

The explicit cast removes the volatile just the same, and that isn't
valid C, as the warning said when you did it implicitly.  Make a copy
from the volatile to some non-volatile storage, and do mem* on *that*?

> +proc add_options_for_long_double_ibm128 { flags } {

> +proc check_effective_target_long_double_ibm128 { } {

Swap these two maybe?  It is more obvious to read it that way (the
add_options is only used if the check returns true, that isn't so
obvious if you read it in the written order).


Okay for trunk with the casts removed.  Thanks!


Segher

Reply via email to