MacOS : find out if a process (given a PID) is running in 32bit or in 64bit Intel mode

标签 macos unix pid mach-o

我有一个 PID,我想查明该进程是在 32 位还是 64 位 Intel 模式下运行。怎么办?

最佳答案

我可以通过 NSRunningApplication 进行.

[[NSRunningApplication runningApplicationWithProcessIdentifier:pid] executableArchitecture]

返回Mach-O architecture constant .

不过,这仅适用于 GUI 应用程序...

关于MacOS : find out if a process (given a PID) is running in 32bit or in 64bit Intel mode,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7335245/

相关文章:

ruby - 如何从 Ruby 检查具有特定 pid 的进程是否正在运行?

macos - torch.backends.mps.is_available() 为 False。我怎样才能改变它?

shell - 查找包含字符串出现次数的文件

macos - 如何CHMOD文件夹mac中的所有文件夹?

unix - 操纵电子邮件地址的路径

c - 用于数据数组的 mmap 函数

linux - Bash:从 pid 获取规范路径和参数

c - D部分PID计算

bash - 在 MacOS 中,当电池电量低于阈值时播放警告的脚本

python - Py2app 模块图中出现错误