What are common pitfalls when trying to measure CPU usage in PHP?

One common pitfall when trying to measure CPU usage in PHP is relying solely on functions like `getrusage()` or `microtime(true)` which may not accurately reflect CPU usage. To accurately measure CPU usage, it is recommended to use a more robust tool like a profiler or a monitoring system that can provide detailed insights into CPU usage.

// Example of using a profiler to measure CPU usage
xhprof_enable();
// Code to measure CPU usage
$cpuUsage = xhprof_disable();
print_r($cpuUsage);