OK, I moved that call too.
On Tue, Oct 08, 2013 at 07:24:09AM -0700, Alex Wang wrote: > looks good to me, since the "reimplement coverage/show" patch is in, should > also call coverage_run() beforehand, > > > On Mon, Sep 23, 2013 at 10:49 AM, Ben Pfaff <b...@nicira.com> wrote: > > > time_poll() calls log_poll_interval(), which in some circumstances calls > > coverage_log(). Before this commit, time_poll() also called > > coverage_clear() after log_poll_interval(). This made sense before commit > > 857165b5fd26 (coverage: Make thread-safe.), because coverage_log() would > > log the most recent main loop's coverage counters separately and calling > > coverage_clear() beforehand would zero out those counters. However, it > > doesn't make sense any longer because the most recent loop's counters are > > no longer separately logged and in fact this practice now means that the > > most recent loop's counters are omitted from the logged counters. > > > > Therefore, this commit moves the call to coverage_clear() earlier, so that > > the most recent loop's counters are included. > > > > Signed-off-by: Ben Pfaff <b...@nicira.com> > > --- > > lib/timeval.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/lib/timeval.c b/lib/timeval.c > > index 223ed30..bd73f35 100644 > > --- a/lib/timeval.c > > +++ b/lib/timeval.c > > @@ -230,10 +230,10 @@ time_poll(struct pollfd *pollfds, int n_pollfds, > > long long int timeout_when, > > int retval; > > > > time_init(); > > + coverage_clear(); > > if (*last_wakeup) { > > log_poll_interval(*last_wakeup); > > } > > - coverage_clear(); > > start = time_msec(); > > > > timeout_when = MIN(timeout_when, deadline); > > -- > > 1.7.10.4 > > > > _______________________________________________ > > dev mailing list > > dev@openvswitch.org > > http://openvswitch.org/mailman/listinfo/dev > > _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev