pcntl_setcpuaffinity
(PHP 8 >= 8.4.0)
pcntl_setcpuaffinity — Set the cpu affinity of a process
说明
Sets the cpu affinity for the pid
with the cpu affinity mask given by
hmask
.
参数
pid
-
If
null
, the current process ID is used. hmask
- The cpu affinity mask comprised of one or more cpu id for binding the process to.
返回值
错误/异常
A TypeError is thrown if one
of the cpu id from the hmask
is invalid.
A ValueError is thrown if
pid
is an invalid process id
or the cpu mask had failed to be created.
参见
- pcntl_setcpuaffinity()
+添加备注
用户贡献的备注
此页面尚无用户贡献的备注。
备份地址:http://www.lvesu.com/blog/php/function.pcntl-setcpuaffinity.php