diff options
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/emit-rtl.c | 24 |
2 files changed, 24 insertions, 6 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f6d63f2..fd1731e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2013-04-15 Andreas Krebbel <Andreas.Krebbel@de.ibm.com> + + * emit-rtl.c (reset_all_used_flags): New function. + (verify_rtl_sharing): Call reset_all_used_flags before and after + performing the checks. + 2013-04-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com> * config/arm/arm.c (const_ok_for_dimode_op): Handle AND case. diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c index 82e4766..5a24a791 100644 --- a/gcc/emit-rtl.c +++ b/gcc/emit-rtl.c @@ -2596,16 +2596,13 @@ verify_rtx_sharing (rtx orig, rtx insn) return; } -/* Go through all the RTL insn bodies and check that there is no unexpected - sharing in between the subexpressions. */ +/* Go through all the RTL insn bodies and clear all the USED bits. */ -DEBUG_FUNCTION void -verify_rtl_sharing (void) +static void +reset_all_used_flags (void) { rtx p; - timevar_push (TV_VERIFY_RTL_SHARING); - for (p = get_insns (); p; p = NEXT_INSN (p)) if (INSN_P (p)) { @@ -2629,6 +2626,19 @@ verify_rtl_sharing (void) } } } +} + +/* Go through all the RTL insn bodies and check that there is no unexpected + sharing in between the subexpressions. */ + +DEBUG_FUNCTION void +verify_rtl_sharing (void) +{ + rtx p; + + timevar_push (TV_VERIFY_RTL_SHARING); + + reset_all_used_flags (); for (p = get_insns (); p; p = NEXT_INSN (p)) if (INSN_P (p)) @@ -2639,6 +2649,8 @@ verify_rtl_sharing (void) verify_rtx_sharing (CALL_INSN_FUNCTION_USAGE (p), p); } + reset_all_used_flags (); + timevar_pop (TV_VERIFY_RTL_SHARING); } |