8sa1-gcc/gcc/java
Richard Henderson cedb4a1ad0 Allow libcalls to be installed for legacy __sync optabs.
This allows a target which implements the __sync interfaces
in libgcc to continue to use them transparently with the
new __atomic builtins.

It is assumed that these libgcc routines DO NOT use spinlocks.
This is true of all extant libgcc instances.

        * optabs.h (OTI_sync_compare_and_swap, OTI_sync_lock_test_and_set,
        OTI_sync_old_add, OTI_sync_old_sub, OTI_sync_old_ior,
        OTI_sync_old_and, OTI_sync_old_xor, OTI_sync_old_nand,
        OTI_sync_new_add, OTI_sync_new_sub, OTI_sync_new_ior,
        OTI_sync_new_and, OTI_sync_new_xor, OTI_sync_new_nand): Move and
        rename from the direct_optab_index enum.
        (sync_compare_and_swap_optab, sync_lock_test_and_set_optab,
        sync_old_add_optab, sync_old_sub_optab, sync_old_ior_optab,
        sync_old_and_optab, sync_old_xor_optab, sync_old_nand_optab,
        sync_new_add_optab, sync_new_sub_optab, sync_new_ior_optab,
        sync_new_and_optab, sync_new_xor_optab, sync_new_nand_optab): Read
        from the optab_table, not the direct_optab_table.
        (init_sync_libfuncs): Declare.
        (can_compare_and_swap_p): Update parameters.
        * optabs.c (init_sync_libfuncs_1, init_sync_libfuncs): New.
        (can_compare_and_swap_p): Add allow_libcall parameter; if true,
        test for the legacy compare-and-swap libcall.
        (expand_atomic_exchange): Use the legacy test-and-set libcall.
        (expand_atomic_compare_and_swap): Use the legacy CAS libcall.
        (struct atomic_op_functions): Update for optab type changes.
        (maybe_emit_op): Likewise.
        (expand_atomic_fetch_op): Use the legacy fetch-op libcalls.
        * builtins.c (fold_builtin_atomic_always_lock_free): Update call
        to can_compare_and_swap_p.
        * omp-low.c (expand_omp_atomic_fetch_op): Likewise.
        (expand_omp_atomic_pipeline): Likewise.
        * genopinit.c (optabs): Make sync_old_*_optab, sync_new_*_optab,
        sync_compare_and_swap_optab, sync_lock_test_and_set_optab regular
        optabs.

From-SVN: r181134
2011-11-07 15:11:55 -08:00
..
boehm.c
builtins.c Allow libcalls to be installed for legacy __sync optabs. 2011-11-07 15:11:55 -08:00
ChangeLog Allow libcalls to be installed for legacy __sync optabs. 2011-11-07 15:11:55 -08:00
ChangeLog.ptr
ChangeLog.tree-ssa
class.c Convert standard builtin functions from being arrays to using a functional interface 2011-10-11 19:55:09 +00:00
config-lang.in
constants.c re PR middle-end/48819 (350 execution failures in 64-bit libjava testsuite on SPARC) 2011-04-29 19:36:12 +00:00
decl.c
except.c Convert standard builtin functions from being arrays to using a functional interface 2011-10-11 19:55:09 +00:00
expr.c
gcj.texi
java-except.h java-gimplify.c: Change copyright header to refer to version 3 of the GNU General Public... 2007-07-31 16:19:49 +00:00
java-gimplify.c Update Copyright years for files modified in 2010. 2011-01-03 21:52:22 +01:00
java-opcodes.h class.c (ident_subst): Always alloca buffer. 2004-10-17 22:51:35 +00:00
java-tree.def java-gimplify.c: Change copyright header to refer to version 3 of the GNU General Public... 2007-07-31 16:19:49 +00:00
java-tree.h split tree_type 2011-05-11 13:48:55 +00:00
javaop.def
javaop.h
jcf-depend.c system.h: Include "safe-ctype.h" instead of <safe-ctype.h>. 2010-11-29 14:09:41 +00:00
jcf-dump.c
jcf-io.c
jcf-parse.c Linemap infrastructure for virtual locations 2011-10-17 11:58:56 +02:00
jcf-path.c
jcf-reader.c
jcf.h
jvgenmain.c
jvspec.c
lang-specs.h
lang.c ChangeLog gcc/ 2011-03-21 09:29:36 +01:00
lang.opt
Make-lang.in Move shlib support to toplevel libgcc 2011-11-02 10:49:46 +00:00
mangle_name.c diagnostic-core.h: Include bversion.h. 2010-11-30 11:41:24 +00:00
mangle.c
parse.h
resource.c
typeck.c
verify-glue.c
verify-impl.c system.h: Include "safe-ctype.h" instead of <safe-ctype.h>. 2010-11-29 14:09:41 +00:00
verify.h
win32-host.c
zextract.c
zipfile.h