diff options
author | David S. Miller <davem@davemloft.net> | 2012-11-15 21:24:22 +0000 |
---|---|---|
committer | David S. Miller <davem@gcc.gnu.org> | 2012-11-15 13:24:22 -0800 |
commit | 8b98b5fd9f9e4edb38a6b7eeb91b5a77ad91d95c (patch) | |
tree | f03d2f8dce9c22de2316eabb57bfd128e7c91f42 /gcc/configure | |
parent | 2bf33cdb91a46f5c8ead75a57ec11766f8e6863e (diff) | |
download | gcc-8b98b5fd9f9e4edb38a6b7eeb91b5a77ad91d95c.zip gcc-8b98b5fd9f9e4edb38a6b7eeb91b5a77ad91d95c.tar.gz gcc-8b98b5fd9f9e4edb38a6b7eeb91b5a77ad91d95c.tar.bz2 |
Add support for sparc fused compare-and-branch.
gcc/
2012-11-15 David S. Miller <davem@davemloft.net>
* configure.ac: Add check for assembler SPARC4 instruction
support.
* configure: Rebuild.
* config.in: Add HAVE_AS_SPARC4 section.
* config/sparc/sparc.opt (mcbcond): New option.
* doc/invoke.texi: Document it.
* config/sparc/constraints.md: New constraint 'A' for 5-bit signed
immediates.
* doc/md.texi: Document it.
* config/sparc/sparc.c (dump_target_flag_bits): Handle MASK_CBCOND.
(sparc_option_override): Likewise.
(emit_cbcond_insn): New function.
(emit_conditional_branch_insn): Call it.
(emit_cbcond_nop): New function.
(output_ubranch): Use cbcond, remove label arg.
(output_cbcond): New function.
* config/sparc/sparc-protos.h (output_ubranch): Update.
(output_cbcond): Declare it.
(emit_cbcond_nop): Likewise.
* config/sparc/sparc.md (type attribute): New types 'cbcond'
and uncond_cbcond.
(emit_cbcond_nop): New attribute.
(length attribute): Handle cbcond and uncond_cbcond.
(in_call_delay attribute): Reject cbcond and uncond_cbcond.
(in_branch_delay attribute): Likewise.
(in_uncond_branch_delay attribute): Likewise.
(in_annul_branch_delay attribute): Likewise.
(*cbcond_sp32, *cbcond_sp64): New insn patterns.
(jump): Rewrite into an expander.
(*jump_ubranch, *jump_cbcond): New patterns.
* config/sparc/niagara4.md: Match 'cbcond' in 'n4_cti'.
* config/sparc/sparc.h (AS_NIAGARA4_FLAG): New macro, use it
when target default is niagara4.
(SPARC_SIMM5_P): Define.
* config/sparc/sol2.h (AS_SPARC64_FLAG): Adjust.
(AS_SPARC32_FLAG): Define.
(ASM_CPU32_DEFAULT_SPEC, ASM_CPU64_DEFAULT_SPEC): Use
AS_NIAGARA4_FLAG as needed.
From-SVN: r193543
Diffstat (limited to 'gcc/configure')
-rwxr-xr-x | gcc/configure | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/gcc/configure b/gcc/configure index cdfbaad..76eec29 100755 --- a/gcc/configure +++ b/gcc/configure @@ -24143,6 +24143,48 @@ if test $gcc_cv_as_sparc_fmaf = yes; then $as_echo "#define HAVE_AS_FMAF_HPC_VIS3 1" >>confdefs.h fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for SPARC4 instructions" >&5 +$as_echo_n "checking assembler for SPARC4 instructions... " >&6; } +if test "${gcc_cv_as_sparc_sparc4+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + gcc_cv_as_sparc_sparc4=no + if test x$gcc_cv_as != x; then + $as_echo '.text + .register %g2, #scratch + .register %g3, #scratch + .align 4 + cxbe %g2, %g3, 1f +1: cwbneg %g2, %g3, 1f +1: sha1 + md5 + aes_kexpand0 %f4, %f6, %f8 + des_round %f38, %f40, %f42, %f44 + camellia_f %f54, %f56, %f58, %f60 + kasumi_fi_xor %f46, %f48, %f50, %f52' > conftest.s + if { ac_try='$gcc_cv_as $gcc_cv_as_flags -xarch=sparc4 -o conftest.o conftest.s >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + then + gcc_cv_as_sparc_sparc4=yes + else + echo "configure: failed program was" >&5 + cat conftest.s >&5 + fi + rm -f conftest.o conftest.s + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_sparc4" >&5 +$as_echo "$gcc_cv_as_sparc_sparc4" >&6; } +if test $gcc_cv_as_sparc_sparc4 = yes; then + +$as_echo "#define HAVE_AS_SPARC4 1" >>confdefs.h + +fi ;; i[34567]86-*-* | x86_64-*-*) |