As per the subject. Tested by making sure there were no differences in the assembly output for the C and C++ testsuites for cris-elf. Applied as preapproved (thanks H-P).
Richard gcc/ * config/cris/cris.md: Use match_test rather than eq/ne symbol_ref throughout file. Index: gcc/config/cris/cris.md =================================================================== --- gcc/config/cris/cris.md 2011-09-03 10:05:49.000000000 +0100 +++ gcc/config/cris/cris.md 2011-09-11 18:21:13.000000000 +0100 @@ -191,10 +191,8 @@ (define_delay (eq_attr "slottable" "has_ (define_delay (eq_attr "slottable" "has_call_slot") [(and (eq_attr "slottable" "yes") - (ior (eq (symbol_ref "RTX_FRAME_RELATED_P (insn)") - (const_int 0)) - (eq (symbol_ref "flag_exceptions") - (const_int 0)))) + (ior (not (match_test "RTX_FRAME_RELATED_P (insn)")) + (not (match_test "flag_exceptions")))) (nil) (nil)]) ;; The insn in the return insn slot must not be the @@ -204,8 +202,7 @@ (define_delay (eq_attr "slottable" "has_ ;; naked RETURN in middle-end. (define_delay (eq_attr "slottable" "has_return_slot") [(and (eq_attr "slottable" "yes") - (eq (symbol_ref "dead_or_set_regno_p (insn, CRIS_SRP_REGNUM)") - (const_int 0))) + (not (match_test "dead_or_set_regno_p (insn, CRIS_SRP_REGNUM)"))) (nil) (nil)]) @@ -2578,7 +2575,7 @@ (define_insn "<u>mul<s><mode>3" "TARGET_HAS_MUL_INSNS" "%!mul<su><mm> %2,%0" [(set (attr "slottable") - (if_then_else (ne (symbol_ref "TARGET_MUL_BUG") (const_int 0)) + (if_then_else (match_test "TARGET_MUL_BUG") (const_string "no") (const_string "yes"))) ;; For umuls.[bwd] it's just N unusable here, but let's be safe. @@ -2601,7 +2598,7 @@ (define_insn "mulsi3" "TARGET_HAS_MUL_INSNS" "%!muls.d %2,%0" [(set (attr "slottable") - (if_then_else (ne (symbol_ref "TARGET_MUL_BUG") (const_int 0)) + (if_then_else (match_test "TARGET_MUL_BUG") (const_string "no") (const_string "yes"))) ;; Just N unusable here, but let's be safe. @@ -3493,9 +3490,7 @@ (define_insn "*return_expanded" } [(set (attr "slottable") (if_then_else - (ne (symbol_ref - "(cris_return_address_on_stack_for_return ())") - (const_int 0)) + (match_test "cris_return_address_on_stack_for_return ()") (const_string "no") (const_string "has_return_slot")))])