i386.c (ix86_scalar_mode_supported_p): Don't return unconditional true for decimal float modes.

* config/i386/i386.c (ix86_scalar_mode_supported_p): Don't return
	unconditional true for decimal float modes.
	* config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Ditto.
	* config/s390/s390.c (s390_scalar_mode_supported_p): Ditto.

	* lib/target-supports.exp (check_effective_target_dfp_nocache):
	Check support via mode instead of C type.
	(check_effective_target_dfprt_nocache): Ditto.
	(check_effective_target_hard_dfp): Ditto.

From-SVN: r152030
This commit is contained in:
Janis Johnson 2009-09-22 16:39:35 +00:00 committed by Janis Johnson
parent bcf11ab47f
commit a9ab39d3b4
6 changed files with 22 additions and 6 deletions

View file

@ -1,3 +1,10 @@
2009-09-22 Janis Johnson <janis187@us.ibm.com>
* config/i386/i386.c (ix86_scalar_mode_supported_p): Don't return
unconditional true for decimal float modes.
* config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Ditto.
* config/s390/s390.c (s390_scalar_mode_supported_p): Ditto.
2009-09-22 Loren J. Rittle <ljrittle@acm.org>
* unwind-dw2-fde-glibc.c: Define and use USE_PT_GNU_EH_FRAME.

View file

@ -28066,7 +28066,7 @@ static bool
ix86_scalar_mode_supported_p (enum machine_mode mode)
{
if (DECIMAL_FLOAT_MODE_P (mode))
return true;
return default_decimal_float_supported_p ();
else if (mode == TFmode)
return true;
else

View file

@ -25403,7 +25403,7 @@ static bool
rs6000_scalar_mode_supported_p (enum machine_mode mode)
{
if (DECIMAL_FLOAT_MODE_P (mode))
return true;
return default_decimal_float_supported_p ();
else
return default_scalar_mode_supported_p (mode);
}

View file

@ -366,7 +366,7 @@ static bool
s390_scalar_mode_supported_p (enum machine_mode mode)
{
if (DECIMAL_FLOAT_MODE_P (mode))
return true;
return default_decimal_float_supported_p ();
else
return default_scalar_mode_supported_p (mode);
}

View file

@ -1,3 +1,10 @@
2009-09-22 Janis Johnson <janis187@us.ibm.com>
* lib/target-supports.exp (check_effective_target_dfp_nocache):
Check support via mode instead of C type.
(check_effective_target_dfprt_nocache): Ditto.
(check_effective_target_hard_dfp): Ditto.
2009-09-22 Richard Guenther <rguenther@suse.de>
PR middle-end/41395

View file

@ -1295,7 +1295,7 @@ proc check_effective_target_fixed_point { } {
proc check_effective_target_dfp_nocache { } {
verbose "check_effective_target_dfp_nocache: compiling source" 2
set ret [check_no_compiler_messages_nocache dfp object {
_Decimal32 x; _Decimal64 y; _Decimal128 z;
float x __attribute__((mode(DD)));
}]
verbose "check_effective_target_dfp_nocache: returning $ret" 2
return $ret
@ -1303,7 +1303,8 @@ proc check_effective_target_dfp_nocache { } {
proc check_effective_target_dfprt_nocache { } {
return [check_runtime_nocache dfprt {
_Decimal32 x = 1.2df; _Decimal64 y = 2.3dd; _Decimal128 z;
typedef float d64 __attribute__((mode(DD)));
d64 x = 1.2df; y = 2.3dd; z;
int main () { z = x + y; return 0; }
}]
}
@ -3069,7 +3070,8 @@ proc check_effective_target_pow10 { } {
proc check_effective_target_hard_dfp {} {
return [check_no_messages_and_pattern hard_dfp "!adddd3" assembly {
_Decimal64 x, y, z;
typedef float d64 __attribute__((mode(DD)));
d64 x, y, z;
void foo (void) { z = x + y; }
}]
}