Skip to content
Snippets Groups Projects
Commit cb16bc3b authored by Peter Bergner's avatar Peter Bergner
Browse files

rs6000: Allow -mlong-double-64 after -mabi={ibm,ieee}longdouble [PR104208, PR87496]

The glibc build is showing a build error due to extra "error" checking from my
PR87496 fix.  That checking was overeager, disallowing setting the long double
size to 64-bits if the 128-bit long double ABI had already been specified.
Now we only emit an error if we specify a 128-bit long double ABI if our
long double size is not 128 bits.  This also fixes an erroneous error when
-mabi=ieeelongdouble is used and ISA 2.06 is not enabled, but the long double
size has been changed to 64 bits.

2022-03-04  Peter Bergner  <bergner@linux.ibm.com>

gcc/
	PR target/87496
	PR target/104208
	* config/rs6000/rs6000.cc (rs6000_option_override_internal): Make the
	ISA 2.06 requirement for -mabi=ieeelongdouble conditional on
	-mlong-double-128.
	Move the -mabi=ieeelongdouble and -mabi=ibmlongdouble error checking
	from here...
	* common/config/rs6000/rs6000-common.cc (rs6000_handle_option):
	... to here.

gcc/testsuite/
	PR target/87496
	PR target/104208
	* gcc.target/powerpc/pr104208-1.c: New test.
	* gcc.target/powerpc/pr104208-2.c: Likewise.
	* gcc.target/powerpc/pr87496-2.c: Swap long double options to trigger
	the expected error.
	* gcc.target/powerpc/pr87496-3.c: Likewise.
parent e28eb86c
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment