共用方式為


Notes on WPA Sampling

By default, sampling occurs every millisecond. The usage graph is then aggregated based on these samples. To verify the sampling rate enter the command:

xperf -ProfInt 

The sampling rate can be changed by using the -SetProfInt option. For example:

xperf -on PROC_THREAD+PROFILE -SetProfInt 20000 [cached] 

The units of SetProfInt are 100 nanosecond time intervals, or a ten-thousandth of a millisecond. This command will set the sampling interval to 2 milliseconds. If "cached" is specified, that sampling interval is cached by WPA. The cached value is applied to all kernel loggers that are subsequently started. [Default: <n> = 10000; not cached].