diff options
author | ebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-08-09 09:13:32 +0000 |
---|---|---|
committer | ebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-08-09 09:13:32 +0000 |
commit | cbd3655d211551c213ec1d781d83626c5ffacd2b (patch) | |
tree | d1a9cb605f9623b55eb0aa9302465169641496d3 /gcc/configure.ac | |
parent | e9be77098b293610947d26d3c99f898314042ba7 (diff) | |
download | gcc-cbd3655d211551c213ec1d781d83626c5ffacd2b.tar.gz |
* configure.ac: Add GAS check for LEON instructions on SPARC.
* configure: Regenerate.
* config.in: Likewise.
* config.gcc (with_cpu): Remove sparc-leon*-* and deal with LEON in the
sparc*-*-* block.
* config/sparc/sparc.opt (LEON, LEON3): New masks.
* config/sparc/sparc.h (ASM_CPU32_DEFAULT_SPEC): Set to AS_LEON_FLAG
for LEON or LEON3.
(ASM_CPU_SPEC): Pass AS_LEON_FLAG if -mcpu=leon or -mcpu=leon3.
(AS_LEON_FLAG): New macro.
* config/sparc/sparc.c (sparc_option_override): Set MASK_LEON for leon
and MASK_LEON3 for leon3 and unset them if HAVE_AS_LEON is not defined.
Deal with LEON and LEON3 for the memory model.
* config/sparc/sync.m (atomic_compare_and_swap<mode>): Enable for LEON3
(atomic_compare_and_swap<mode>_1): Likewise.
(*atomic_compare_and_swap<mode>_1): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@201622 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/configure.ac')
-rw-r--r-- | gcc/configure.ac | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/configure.ac b/gcc/configure.ac index b279373410a..116ba133145 100644 --- a/gcc/configure.ac +++ b/gcc/configure.ac @@ -3613,6 +3613,19 @@ foo: kasumi_fi_xor %f46, %f48, %f50, %f52],, [AC_DEFINE(HAVE_AS_SPARC4, 1, [Define if your assembler supports SPARC4 instructions.])]) + + gcc_GAS_CHECK_FEATURE([LEON instructions], + gcc_cv_as_sparc_leon,, + [-Aleon], + [.text + .register %g2, #scratch + .register %g3, #scratch + .align 4 + smac %g2, %g3, %g1 + umac %g2, %g3, %g1 + cas [[%g2]], %g3, %g1],, + [AC_DEFINE(HAVE_AS_LEON, 1, + [Define if your assembler supports LEON instructions.])]) ;; changequote(,)dnl |