This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[gcc-in-cxx] Don't pop TV_NONE
- From: Ian Lance Taylor <iant at google dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Fri, 06 Feb 2009 17:46:45 -0800
- Subject: [gcc-in-cxx] Don't pop TV_NONE
On the gcc-in-cxx branch, just as timevar_push_1 ignores TV_NONE,
timevar_pop_1 needs to ignore it as well. I committed this patch to the
gcc-in-cxx branch.
Ian
2009-02-06 Ian Lance Taylor <iant@google.com>
* timevar.c (timevar_pop_1): Ignore TV_NONE.
Index: timevar.c
===================================================================
--- timevar.c (revision 143890)
+++ timevar.c (working copy)
@@ -316,6 +316,10 @@ timevar_pop_1 (timevar_id_t timevar)
struct timevar_time_def now;
struct timevar_stack_def *popped = stack;
+ /* Completely ignore TV_NONE. */
+ if (timevar == TV_NONE)
+ return;
+
gcc_assert (&timevars[timevar] == stack->timevar);
/* What time is it? */