diff --git a/src/Concerns/ParallelCommand.php b/src/Concerns/ParallelCommand.php index 2a220b7e..df355929 100644 --- a/src/Concerns/ParallelCommand.php +++ b/src/Concerns/ParallelCommand.php @@ -61,7 +61,7 @@ trait ParallelCommand // perflevel0 refers to P-cores on M-series, and the entire CPU on Intel Macs if ($darwin && $ffi->sysctlbyname('hw.perflevel0.logicalcpu', FFI::addr($cores), FFI::addr($size), null, 0) === 0) { - return $size->cdata; + return $cores->cdata; } else if ($darwin) { // Reset the size in case the pointer got written to (likely shouldn't happen) $size->cdata = FFI::sizeof($cores);