Patchwork Committed: add cris-* and crisv32-* to lists in sync_int_long and sync_char_short

login
register
mail settings
Submitter Hans-Peter Nilsson
Date Aug. 16, 2012, 10:47 p.m.
Message ID <201208162247.q7GMleuF025795@ignucius.se.axis.com>
Download mbox | patch
Permalink /patch/178111/
State New
Headers show

Comments

Hans-Peter Nilsson - Aug. 16, 2012, 10:47 p.m.
See also PR54261 and gcc.dg/torture/pr54261-1.c.

I was about to also add an #elif defined (__CRIS__) in cas_int
(which commendably uses __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 but
nevertheless needs to be manually enabled because of PR54266),
but cas_int only guards test-cases that grep dumps for
tree/gimple things that for some reason are absent in absence of
MD patterns, so I'm dropping that; there's little point in
enabling cas_int and xfailing all tests using it.

Committed, all now enabled test-cases pass for cris-elf and FWIW
the local 4.7 import for crisv32-axis-linux-gnu.

gcc/testsuite:
	* lib/target-supports.exp (check_effective_target_sync_int_long)
	(check_effective_target_sync_char_short): Enable for crisv32-*
	and cris-*.


brgds, H-P

Patch

diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index e286e64..968d6e7 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -4033,6 +4033,7 @@  proc check_effective_target_sync_int_long { } {
 	     || [istarget hppa*-*linux*]
 	     || [istarget s390*-*-*] 
 	     || [istarget powerpc*-*-*]
+	     || [istarget crisv32-*-*] || [istarget cris-*-*]
 	     || ([istarget sparc*-*-*] && [check_effective_target_sparc_v9])
 	     || [check_effective_target_mips_llsc] } {
            set et_sync_int_long_saved 1
@@ -4062,6 +4063,7 @@  proc check_effective_target_sync_char_short { } {
 	     || [istarget hppa*-*linux*]
 	     || [istarget s390*-*-*] 
 	     || [istarget powerpc*-*-*]
+	     || [istarget crisv32-*-*] || [istarget cris-*-*]
 	     || ([istarget sparc*-*-*] && [check_effective_target_sparc_v9])
 	     || [check_effective_target_mips_llsc] } {
            set et_sync_char_short_saved 1