diff options
author | Andreas Krebbel <Andreas.Krebbel@de.ibm.com> | 2013-04-15 13:09:50 +0000 |
---|---|---|
committer | Andreas Krebbel <krebbel@gcc.gnu.org> | 2013-04-15 13:09:50 +0000 |
commit | a24243a0e5e09bd562eeb362c1c89ee497ea67e7 (patch) | |
tree | 94663caf9a5a76bdc704a4e05844aa334b6bcd90 /gcc/emit-rtl.c | |
parent | 3c63e93e6d785c29cc80d1a3037865f678fd9c23 (diff) | |
download | gcc-a24243a0e5e09bd562eeb362c1c89ee497ea67e7.zip gcc-a24243a0e5e09bd562eeb362c1c89ee497ea67e7.tar.gz gcc-a24243a0e5e09bd562eeb362c1c89ee497ea67e7.tar.bz2 |
emit-rtl.c (reset_all_used_flags): New function.
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.
From-SVN: r197971
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r-- | gcc/emit-rtl.c | 24 |
1 files changed, 18 insertions, 6 deletions
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); } |