Current Path : /usr/local/lib/perl5/site_perl/5.8.9/mach/sys/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/local/lib/perl5/site_perl/5.8.9/mach/sys/pmckern.ph |
require '_h2ph_pre.ph'; no warnings 'redefine'; unless(defined(&_SYS_PMCKERN_H_)) { eval 'sub _SYS_PMCKERN_H_ () {1;}' unless defined(&_SYS_PMCKERN_H_); require 'sys/param.ph'; require 'sys/systm.ph'; require 'sys/kernel.ph'; require 'sys/lock.ph'; require 'sys/proc.ph'; require 'sys/sx.ph'; require 'sys/pmc.ph'; require 'machine/cpufunc.ph'; eval 'sub PMC_FN_PROCESS_EXEC () {1;}' unless defined(&PMC_FN_PROCESS_EXEC); eval 'sub PMC_FN_CSW_IN () {2;}' unless defined(&PMC_FN_CSW_IN); eval 'sub PMC_FN_CSW_OUT () {3;}' unless defined(&PMC_FN_CSW_OUT); eval 'sub PMC_FN_DO_SAMPLES () {4;}' unless defined(&PMC_FN_DO_SAMPLES); eval 'sub PMC_FN_KLD_LOAD () {5;}' unless defined(&PMC_FN_KLD_LOAD); eval 'sub PMC_FN_KLD_UNLOAD () {6;}' unless defined(&PMC_FN_KLD_UNLOAD); eval 'sub PMC_FN_MMAP () {7;}' unless defined(&PMC_FN_MMAP); eval 'sub PMC_FN_MUNMAP () {8;}' unless defined(&PMC_FN_MUNMAP); eval 'sub PMC_FN_USER_CALLCHAIN () {9;}' unless defined(&PMC_FN_USER_CALLCHAIN); eval 'sub PMC_FN_USER_CALLCHAIN_SOFT () {10;}' unless defined(&PMC_FN_USER_CALLCHAIN_SOFT); eval 'sub PMC_FN_SOFT_SAMPLING () {11;}' unless defined(&PMC_FN_SOFT_SAMPLING); eval 'sub PMC_HR () {0;}' unless defined(&PMC_HR); eval 'sub PMC_SR () {1;}' unless defined(&PMC_SR); eval 'sub PMC_SOFT_DEFINE { my($prov, $mod, $func, $name) = @_; eval q(\'struct pmc_soft\' &pmc_$prov &_$mod &_$func &_$name = { 0, { $prov \\"_\\" $mod \\"_\\" $func \\".\\" $name, 0} }; &SYSINIT( &pmc_$prov &_$mod &_$func &_$name &_init, &SI_SUB_KDTRACE, &SI_ORDER_SECOND + 1, &pmc_soft_ev_register, &pmc_$prov &_$mod &_$func &_$name ); &SYSUNINIT( &pmc_$prov &_$mod &_$func &_$name &_uninit, &SI_SUB_KDTRACE, &SI_ORDER_SECOND + 1, &pmc_soft_ev_deregister, &pmc_$prov &_$mod &_$func &_$name )); }' unless defined(&PMC_SOFT_DEFINE); eval 'sub PMC_SOFT_DECLARE { my($prov, $mod, $func, $name) = @_; eval q( &extern \'struct pmc_soft\' &pmc_$prov &_$mod &_$func &_$name); }' unless defined(&PMC_SOFT_DECLARE); if(defined(&PMC_FAKE_TRAPFRAME)) { eval 'sub PMC_SOFT_CALL { my($pr, $mo, $fu, $na) = @_; eval q( &do { &if ( &pmc_$pr &_$mo &_$fu &_ ($na->{ps_running})) { \'struct pmckern_soft\' &ks; ®ister_t &intr; &intr = &intr_disable(); &PMC_FAKE_TRAPFRAME( $pmc_tf[ &curcpu]); ($ks->{pm_ev}) = &pmc_$pr &_$mo &_$fu &_ ($na->{ps_ev}->{pm_ev_code}); ($ks->{pm_cpu}) = &PCPU_GET( &cpuid); ($ks->{pm_tf}) = $pmc_tf[ &curcpu]; &PMC_CALL_HOOK_UNLOCKED( &curthread, &PMC_FN_SOFT_SAMPLING, ( &void *) &ks); &intr_restore( &intr); } } &while (0)); }' unless defined(&PMC_SOFT_CALL); } else { eval 'sub PMC_SOFT_CALL { my($pr, $mo, $fu, $na) = @_; eval q( &do { } &while (0)); }' unless defined(&PMC_SOFT_CALL); } eval 'sub PMC_SOFT_CALL_TF { my($pr, $mo, $fu, $na, $tf) = @_; eval q( &do { &if ( &pmc_$pr &_$mo &_$fu &_ ($na->{ps_running})) { \'struct pmckern_soft\' &ks; ®ister_t &intr; &intr = &intr_disable(); ($ks->{pm_ev}) = &pmc_$pr &_$mo &_$fu &_ ($na->{ps_ev}->{pm_ev_code}); ($ks->{pm_cpu}) = &PCPU_GET( &cpuid); ($ks->{pm_tf}) = $tf; &PMC_CALL_HOOK_UNLOCKED( &curthread, &PMC_FN_SOFT_SAMPLING, ( &void *) &ks); &intr_restore( &intr); } } &while (0)); }' unless defined(&PMC_SOFT_CALL_TF); eval 'sub PMC_CALL_HOOK { my($t, $cmd, $arg) = @_; eval q( &do { &sx_slock( &pmc_sx); &if ( &pmc_hook != &NULL) ( &pmc_hook)(($t), ($cmd), ($arg)); &sx_sunlock( &pmc_sx); } &while (0)); }' unless defined(&PMC_CALL_HOOK); eval 'sub PMC_CALL_HOOK_X { my($t, $cmd, $arg) = @_; eval q( &do { &sx_xlock( &pmc_sx); &if ( &pmc_hook != &NULL) ( &pmc_hook)(($t), ($cmd), ($arg)); &sx_xunlock( &pmc_sx); } &while (0)); }' unless defined(&PMC_CALL_HOOK_X); eval 'sub PMC_CALL_HOOK_UNLOCKED { my($t, $cmd, $arg) = @_; eval q( &do { &if ( &pmc_hook != &NULL) ( &pmc_hook)(($t), ($cmd), ($arg)); } &while (0)); }' unless defined(&PMC_CALL_HOOK_UNLOCKED); eval 'sub PMC_SWITCH_CONTEXT { my($t,$cmd) = @_; eval q( &PMC_CALL_HOOK_UNLOCKED($t,$cmd, &NULL)); }' unless defined(&PMC_SWITCH_CONTEXT); eval 'sub PMC_PROC_IS_USING_PMCS { my($p) = @_; eval q(( &__predict_false( &atomic_load_acq_int(($p)-> &p_flag) & &P_HWPMC))); }' unless defined(&PMC_PROC_IS_USING_PMCS); eval 'sub PMC_IS_PENDING_CALLCHAIN { my($p) = @_; eval q(( &__predict_false(($p)-> &td_pflags & &TDP_CALLCHAIN))); }' unless defined(&PMC_IS_PENDING_CALLCHAIN); eval 'sub PMC_SYSTEM_SAMPLING_ACTIVE () { eval q(( &pmc_ss_count > 0)); }' unless defined(&PMC_SYSTEM_SAMPLING_ACTIVE); eval 'sub PMC_CPU_HAS_SAMPLES { my($C) = @_; eval q(( &__predict_false( &CPU_ISSET($C, &pmc_cpumask)))); }' unless defined(&PMC_CPU_HAS_SAMPLES); if(defined(&INVARIANTS)) { } } 1;