/freebsd-9.3-release/sys/i386/i386/ |
H A D | perfmon.c | 129 perfmon_setup(int pmc, unsigned int control) argument 133 if (pmc < 0 || pmc >= NPMC) 136 perfmon_inuse |= (1 << pmc); 139 ctl_shadow[pmc] = control; 140 writectl(pmc); 141 wrmsr(msr_pmc[pmc], pmc_shadow[pmc] = 0); 147 perfmon_get(int pmc, unsigned int *control) argument 149 if (pmc < 160 perfmon_fini(int pmc) argument 175 perfmon_start(int pmc) argument 194 perfmon_stop(int pmc) argument 213 perfmon_read(int pmc, quad_t *val) argument 230 perfmon_reset(int pmc) argument 251 writectl6(int pmc) argument 267 writectl5(int pmc) argument 336 struct pmc *pmc; local [all...] |
/freebsd-9.3-release/lib/libpmc/ |
H A D | Makefile | 3 LIB= pmc 6 INCS= pmc.h pmclog.h 8 MAN= pmc.3 23 MAN+= pmc.soft.3 27 MAN+= pmc.atom.3 28 MAN+= pmc.core.3 29 MAN+= pmc.core2.3 30 MAN+= pmc.haswell.3 31 MAN+= pmc.haswelluc.3 32 MAN+= pmc [all...] |
/freebsd-9.3-release/sys/modules/pmc/ |
H A D | Makefile | 5 KMOD= pmc 6 SRCS= pmc.c
|
/freebsd-9.3-release/share/examples/perfmon/ |
H A D | perfmon.c | 56 struct pmc pmc; local 62 pmc.pmc_num = 0; 63 pmc.pmc_event = 0; 64 pmc.pmc_unit = 0; 65 pmc.pmc_flags = 0; 66 pmc.pmc_mask = 0; 74 pmc.pmc_flags |= PMCF_USR; 77 pmc.pmc_flags |= PMCF_OS; 80 pmc [all...] |
/freebsd-9.3-release/sys/amd64/amd64/ |
H A D | prof_machdep.c | 267 struct pmc pmc; local 273 pmc.pmc_val = cputime_clock_pmc_conf; 274 clock += pmc.pmc_event; 284 pmc.pmc_num = 0; 285 pmc.pmc_event = event; 286 pmc.pmc_unit = 0; 287 pmc.pmc_flags = PMCF_E | PMCF_OS | PMCF_USR; 288 pmc.pmc_mask = 0; 289 cputime_clock_pmc_conf = pmc [all...] |
/freebsd-9.3-release/sys/i386/isa/ |
H A D | prof_machdep.c | 242 struct pmc pmc; local 248 pmc.pmc_val = cputime_clock_pmc_conf; 249 clock += pmc.pmc_event; 259 pmc.pmc_num = 0; 260 pmc.pmc_event = event; 261 pmc.pmc_unit = 0; 262 pmc.pmc_flags = PMCF_E | PMCF_OS | PMCF_USR; 263 pmc.pmc_mask = 0; 264 cputime_clock_pmc_conf = pmc [all...] |
/freebsd-9.3-release/sys/dev/hwpmc/ |
H A D | hwpmc_ia64.c | 32 #include <sys/pmc.h>
|
H A D | hwpmc_sparc64.c | 32 #include <sys/pmc.h>
|
H A D | hwpmc_mips24k.c | 33 #include <sys/pmc.h> 177 mips24k_pmcn_read(unsigned int pmc) argument 181 KASSERT(pmc < mips24k_npmcs, ("[mips,%d] illegal PMC number %d", 182 __LINE__, pmc)); 185 switch (pmc) { 199 mips24k_pmcn_write(unsigned int pmc, uint32_t reg) argument 202 KASSERT(pmc < mips24k_npmcs, ("[mips,%d] illegal PMC number %d", 203 __LINE__, pmc)); 205 switch (pmc) { 219 mips24k_allocate_pmc(int cpu, int ri, struct pmc *p 388 mips24k_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
H A D | hwpmc_xscale.c | 33 #include <sys/pmc.h> 202 xscale_pmcn_read(unsigned int pmc) argument 206 KASSERT(pmc < 4, ("[xscale,%d] illegal PMC number %d", __LINE__, pmc)); 208 switch (pmc) { 227 xscale_pmcn_write(unsigned int pmc, uint32_t reg) argument 230 KASSERT(pmc < 4, ("[xscale,%d] illegal PMC number %d", __LINE__, pmc)); 232 switch (pmc) { 251 xscale_allocate_pmc(int cpu, int ri, struct pmc *p 486 xscale_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
H A D | hwpmc_mips.c | 32 #include <sys/pmc.h>
|
H A D | hwpmc_pentium.c | 33 #include <sys/pmc.h>
|
H A D | hwpmc_amd.h | 80 #define AMD_PMC_HAS_OVERFLOWED(pmc) ((rdpmc(pmc) & (1ULL << 47)) == 0) 91 /* MD extension for 'struct pmc' */
|
H A D | hwpmc_soft.c | 31 #include <sys/pmc.h> 96 soft_allocate_pmc(int cpu, int ri, struct pmc *pm, 127 /* Module unload is protected by pmc SX lock. */ 135 soft_config_pmc(int cpu, int ri, struct pmc *pm) 158 soft_describe(int cpu, int ri, struct pmc_info *pi, struct pmc **ppmc) 191 soft_get_config(int cpu, int ri, struct pmc **ppm) 268 struct pmc *pm; 280 ("[soft,%d] no owner for PHW [cpu%d,pmc%d]", __LINE__, cpu, ri)); 292 struct pmc *pm; 304 ("[soft,%d] cpu %d ri %d pmc no 314 soft_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
H A D | hwpmc_tsc.c | 31 #include <sys/pmc.h> 71 tsc_allocate_pmc(int cpu, int ri, struct pmc *pm, 98 tsc_config_pmc(int cpu, int ri, struct pmc *pm) 120 tsc_describe(int cpu, int ri, struct pmc_info *pi, struct pmc **ppmc) 152 tsc_get_config(int cpu, int ri, struct pmc **ppm) 237 struct pmc *pm; 249 ("[tsc,%d] no owner for PHW [cpu%d,pmc%d]", __LINE__, cpu, ri)); 254 ("[tsc,%d] illegal pmc mode %d", __LINE__, mode)); 264 tsc_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
H A D | hwpmc_mod.c | 46 #include <sys/pmc.h> 107 KASSERT(pmc_pmcdisp[(R)] <= 0, ("[pmc,%d] row disposition error", \ 111 ("[pmc,%d] row disposition error", __LINE__)); \ 116 KASSERT(pmc_pmcdisp[(R)] <= 0, ("[pmc,%d] row disposition error", \ 121 KASSERT(pmc_pmcdisp[(R)] >= 0, ("[pmc,%d] row disposition error", \ 128 KASSERT(pmc_pmcdisp[(R)] >= 0, ("[pmc,%d] row disposition error", \ 181 static int pmc_attach_process(struct proc *p, struct pmc *pm); 182 static struct pmc *pmc_allocate_pmc_descriptor(void); 184 static int pmc_attach_one_process(struct proc *p, struct pmc *pm); 187 static int pmc_can_attach(struct pmc *p 2158 struct pmc *pmc; local 2387 pmc_register_owner(struct proc *p, struct pmc *pmc) argument 2550 pmc_find_pmc(pmc_id_t pmcid, struct pmc **pmc) argument 3232 struct pmc *pmc; local [all...] |
H A D | hwpmc_powerpc.c | 33 #include <sys/pmc.h> 337 powerpc_pmcn_read(unsigned int pmc) argument 339 switch (pmc) { 358 panic("Invalid PMC number: %d\n", pmc); 363 powerpc_pmcn_write(unsigned int pmc, uint32_t val) argument 365 switch (pmc) { 385 panic("Invalid PMC number: %d\n", pmc); 390 powerpc_allocate_pmc(int cpu, int ri, struct pmc *pm, 440 struct pmc *pm; 462 struct pmc *p 616 powerpc_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
H A D | hwpmc_amd.c | 40 #include <sys/pmc.h> 258 * read a pmc register 266 struct pmc *pm; 280 ("[amd,%d] No owner for HWPMC [cpu%d,pmc%d]", __LINE__, 316 struct pmc *pm; 327 ("[amd,%d] PMC not owned (cpu%d,pmc%d)", __LINE__, 350 * configure hardware pmc according to the configuration recorded in 351 * pmc 'pm'. 355 amd_config_pmc(int cpu, int ri, struct pmc *pm) 381 amd_get_config(int cpu, int ri, struct pmc **pp 516 amd_release_pmc(int cpu, int ri, struct pmc *pmc) argument [all...] |
/freebsd-9.3-release/usr.sbin/pmccontrol/ |
H A D | pmccontrol.c | 41 #include <pmc.h> 94 " " PMCC_PROGRAM_NAME " [-e pmc | -d pmc | -c cpu] ..."; 141 int cpu, pmc; local 168 pmc = np->op_pmc; 174 if (pmc >= npmc) 175 errx(EX_DATAERR, "PMC id too large: \"%d\"", pmc); 193 SET_PMCS(i, pmc, op); 196 SET_PMCS(cpu, pmc, op); 357 int error, command, currentcpu, option, pmc; local [all...] |
/freebsd-9.3-release/sys/sys/ |
H A D | pmclog.h | 36 #include <sys/pmc.h> 263 void pmclog_process_callchain(struct pmc *_pm, struct pmc_sample *_ps); 270 void pmclog_process_pmcallocate(struct pmc *_pm); 271 void pmclog_process_pmcattach(struct pmc *_pm, pid_t _pid, char *_path); 272 void pmclog_process_pmcdetach(struct pmc *_pm, pid_t _pid); 273 void pmclog_process_proccsw(struct pmc *_pm, struct pmc_process *_pp, 277 void pmclog_process_procexit(struct pmc *_pm, struct pmc_process *_pp);
|
H A D | pmc.h | 385 * Data structures for system calls supported by the pmc driver. 403 pmc_id_t pm_pmcid; /* [return] process pmc id */ 458 pmc_id_t pm_pmcid; /* pmc id */ 472 char pm_name[PMC_NAME_MAX]; /* pmc name */ 525 * Retrieve pmc(4) driver-wide statistics. 569 pmc_id_t pm_pmcid; /* allocated pmc id */ 653 * struct pmc 675 struct pmc { struct 677 LIST_ENTRY(pmc) pm_next; /* owner's list */ 682 * allocated on in the 'CPU' field of the pmc I [all...] |
/freebsd-9.3-release/sys/compat/freebsd32/ |
H A D | freebsd32_ioctl.c | 253 struct pci_match_conf pmc; local 293 CP(pmc32,pmc,pc_sel); 294 strlcpy(pmc.pd_name, pmc32.pd_name, sizeof(pmc.pd_name)); 295 CP(pmc32,pmc,pd_unit); 296 CP(pmc32,pmc,pc_vendor); 297 CP(pmc32,pmc,pc_device); 298 CP(pmc32,pmc,pc_class); 299 CP(pmc32,pmc,flags); 300 if ((error = copyout(&pmc, pmc [all...] |
/freebsd-9.3-release/usr.sbin/pmcstat/ |
H A D | pmcpl_annotate.c | 45 #include <sys/pmc.h> 61 #include <pmc.h>
|
/freebsd-9.3-release/sys/i386/include/ |
H A D | perfmon.h | 47 #define PMIOSETUP _IOW('5', 1, struct pmc) 48 #define PMIOGET _IOWR('5', 7, struct pmc) 55 struct pmc { struct
|
/freebsd-9.3-release/sys/pc98/conf/ |
H A D | NOTES | 456 # pmc: Power Management Controller of NEC PC-98Note 471 device pmc 472 hint.pmc.0.at="isa" 473 hint.pmc.0.port="0x8f0"
|