xref: /freebsd/usr.sbin/pmcstat/pmcpl_calltree.h (revision b3e76948)
10b86b1bbSFabien Thomas /*-
24d846d26SWarner Losh  * SPDX-License-Identifier: BSD-2-Clause
31de7b4b8SPedro F. Giffuni  *
40b86b1bbSFabien Thomas  * Copyright (c) 2009, Fabien Thomas
50b86b1bbSFabien Thomas  * All rights reserved.
60b86b1bbSFabien Thomas  *
70b86b1bbSFabien Thomas  * Redistribution and use in source and binary forms, with or without
80b86b1bbSFabien Thomas  * modification, are permitted provided that the following conditions
90b86b1bbSFabien Thomas  * are met:
100b86b1bbSFabien Thomas  * 1. Redistributions of source code must retain the above copyright
110b86b1bbSFabien Thomas  *    notice, this list of conditions and the following disclaimer.
120b86b1bbSFabien Thomas  * 2. Redistributions in binary form must reproduce the above copyright
130b86b1bbSFabien Thomas  *    notice, this list of conditions and the following disclaimer in the
140b86b1bbSFabien Thomas  *    documentation and/or other materials provided with the distribution.
150b86b1bbSFabien Thomas  *
160b86b1bbSFabien Thomas  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
170b86b1bbSFabien Thomas  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
180b86b1bbSFabien Thomas  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
190b86b1bbSFabien Thomas  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
200b86b1bbSFabien Thomas  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
210b86b1bbSFabien Thomas  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
220b86b1bbSFabien Thomas  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
230b86b1bbSFabien Thomas  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
240b86b1bbSFabien Thomas  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
250b86b1bbSFabien Thomas  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
260b86b1bbSFabien Thomas  * SUCH DAMAGE.
270b86b1bbSFabien Thomas  */
280b86b1bbSFabien Thomas 
290b86b1bbSFabien Thomas #ifndef	_PMCSTAT_PL_CALLTREE_H_
300b86b1bbSFabien Thomas #define	_PMCSTAT_PL_CALLTREE_H_
310b86b1bbSFabien Thomas 
320b86b1bbSFabien Thomas /* Function prototypes */
330b86b1bbSFabien Thomas int pmcpl_ct_init(void);
340b86b1bbSFabien Thomas void pmcpl_ct_shutdown(FILE *mf);
350b86b1bbSFabien Thomas void pmcpl_ct_process(
360b86b1bbSFabien Thomas     struct pmcstat_process *pp, struct pmcstat_pmcrecord *pmcr,
370b86b1bbSFabien Thomas     uint32_t nsamples, uintfptr_t *cc, int usermode, uint32_t cpu);
38d27927f7SRuslan Bukin int pmcpl_ct_topkeypress(int c, void *w);
390b86b1bbSFabien Thomas void pmcpl_ct_topdisplay(void);
400b86b1bbSFabien Thomas int pmcpl_ct_configure(char *opt);
410b86b1bbSFabien Thomas 
420b86b1bbSFabien Thomas #endif	/* _PMCSTAT_PL_CALLTREE_H_ */
43