Deleted Added
full compact
pmcannotate.c (185347) pmcannotate.c (201227)
1/*-
2 * Copyright (c) 2008 Nokia Corporation
3 * All rights reserved.
4 *
5 * This software was developed by Attilio Rao for the IPSO project under
6 * contract to Nokia Corporation.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 15 unchanged lines hidden (view full) ---

24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 *
29 */
30
31#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2008 Nokia Corporation
3 * All rights reserved.
4 *
5 * This software was developed by Attilio Rao for the IPSO project under
6 * contract to Nokia Corporation.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 15 unchanged lines hidden (view full) ---

24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 *
29 */
30
31#include <sys/cdefs.h>
32__FBSDID("$FreeBSD: head/usr.sbin/pmcannotate/pmcannotate.c 185347 2008-11-26 21:44:57Z attilio $");
32__FBSDID("$FreeBSD: head/usr.sbin/pmcannotate/pmcannotate.c 201227 2009-12-29 22:53:27Z ed $");
33
34#include <sys/param.h>
35#include <sys/queue.h>
36
37#include <ctype.h>
38#include <stdio.h>
39#include <stdlib.h>
40#include <string.h>

--- 279 unchanged lines hidden (view full) ---

320 if (agg->ag_nsamples < thi)
321 TAILQ_REMOVE(&fqueue, agg, ag_fiter);
322}
323
324/*
325 * Flush the first-level aggregates queue.
326 */
327static void
33
34#include <sys/param.h>
35#include <sys/queue.h>
36
37#include <ctype.h>
38#include <stdio.h>
39#include <stdlib.h>
40#include <string.h>

--- 279 unchanged lines hidden (view full) ---

320 if (agg->ag_nsamples < thi)
321 TAILQ_REMOVE(&fqueue, agg, ag_fiter);
322}
323
324/*
325 * Flush the first-level aggregates queue.
326 */
327static void
328fqueue_deleteall()
328fqueue_deleteall(void)
329{
330 struct aggent *agg;
331
332 while (TAILQ_EMPTY(&fqueue) == 0) {
333 agg = TAILQ_FIRST(&fqueue);
334 TAILQ_REMOVE(&fqueue, agg, ag_fiter);
335 }
336}

--- 130 unchanged lines hidden (view full) ---

467 return (-1);
468 return (0);
469}
470
471/*
472 * Flush the raw entries general queue.
473 */
474static void
329{
330 struct aggent *agg;
331
332 while (TAILQ_EMPTY(&fqueue) == 0) {
333 agg = TAILQ_FIRST(&fqueue);
334 TAILQ_REMOVE(&fqueue, agg, ag_fiter);
335 }
336}

--- 130 unchanged lines hidden (view full) ---

467 return (-1);
468 return (0);
469}
470
471/*
472 * Flush the raw entries general queue.
473 */
474static void
475general_deleteall()
475general_deleteall(void)
476{
477 struct entry *obj;
478
479 while (TAILQ_EMPTY(&mainlst) == 0) {
480 obj = TAILQ_FIRST(&mainlst);
481 TAILQ_REMOVE(&mainlst, obj, en_iter);
482 }
483}

--- 321 unchanged lines hidden ---
476{
477 struct entry *obj;
478
479 while (TAILQ_EMPTY(&mainlst) == 0) {
480 obj = TAILQ_FIRST(&mainlst);
481 TAILQ_REMOVE(&mainlst, obj, en_iter);
482 }
483}

--- 321 unchanged lines hidden ---