mips.md (UNSPEC_COMPARE_AND_SWAP, [...]): New define_constants.
2007-09-02 David Daney <ddaney@avtrex.com>
* config/mips/mips.md (UNSPEC_COMPARE_AND_SWAP, UNSPEC_SYNC_OLD_OP,
UNSPEC_SYNC_NEW_OP, UNSPEC_SYNC_EXCHANGE): New define_constants.
(optab, insn): Add more attributes.
(fetchop_bit): New code macro.
(immediate_insn): New code macro attribute.
(sync): Change condition to ISA_HAS_SYNC.
(rdhwr): Change predicate for operand 0 to register_operand.
(memory_barrier): New expand.
(sync_compare_and_swap<mode>, sync_add<mode>, sync_sub<mode>,
sync_old_add<mode>, sync_old_sub<mode>, sync_new_add<mode>,
sync_new_sub<mode>, sync_<optab><mode>, sync_old_<optab><mode>,
sync_new_<optab><mode>, sync_nand<mode>, sync_old_nand<mode>,
sync_new_nand<mode>, sync_lock_test_and_set<mode>): New insns.
* config/mips/mips.h (ISA_HAS_SYNC, ISA_HAS_LL_SC): New ISA predicates.
(MIPS_COMPARE_AND_SWAP, MIPS_SYNC_OP, MIPS_SYNC_OLD_OP,
MIPS_SYNC_NEW_OP, MIPS_SYNC_NAND, MIPS_SYNC_OLD_NAND,
MIPS_SYNC_NEW_NAND, MIPS_SYNC_EXCHANGE): New Macros.
2007-09-02 David Daney <ddaney@avtrex.com>
* gcc.target/mips/gcc-have-sync-compare-and-swap-1.c: New test.
* gcc.target/mips/gcc-have-sync-compare-and-swap-2.c: Ditto.
* gcc.target/mips/atomic-memory-1.c: Ditto.
* testsuite/gcc.target/mips/atomic-memory-2.c: Ditto.
From-SVN: r128037