Conversation
added 4 commits
February 27, 2026 20:27
- Add AppleSiliconSensors.swift for reading temperature via IOHID API - Use PMU tdie sensors for CPU/GPU temperature on Apple Silicon Macs - Skip SMC calls on arm64 to avoid assertion failures - Disable SwiftFormat build script for compatibility
- Display individual core usage with progress bars - Show P-core (blue) and E-core (green) labels on Apple Silicon - Add per-core temperature from PMU tdie sensors - Calculate real-time usage from CPU tick deltas - Add localization for cpu.cores
- Add resolvedDeviceId for Apple Silicon GPUs without device-id - Use IOAccelerator PerformanceStatistics for GPU usage - Fallback to AppleSiliconSensors for GPU temperature - Display GPU core count in menu view - Match Apple Silicon GPUs by prefix instead of PCI ID
|
我感觉你可以自己基于他仓库二开一下了 他的开源协议是MIT协议的 |
jevonmao
approved these changes
Mar 30, 2026
jevonmao
left a comment
Collaborator
There was a problem hiding this comment.
看起来没什么大问题 But I don’t have deep expertise in the low level ARM API specifics, so it’s possible I missed something there...worth a second set of eyes from someone more familiar with that layer.
realhidden
pushed a commit
to realhidden/eul
that referenced
this pull request
Sep 18, 2026
Adapts community PR gao-sun#273 onto the Xcode-26 base, with fixes: - New AppleSiliconSensors: reads M-series die temperatures via the private IOHIDEventSystemClient API (AppleVendor usage page, PMU tdie sensors) with dlsym resolution. Unlike gao-sun#273's version, the Copy-rule CF returns (event, Product string) are released per read instead of leaking two objects per sensor per tick, the owning CFArray is retained so cached service pointers cannot dangle, and sensor-name fallbacks (PMU tdie -> PMU2 tdie -> SOC MTR Temp Sensor) cover newer chip generations. - SmcControl: temperature getters fall back to IOHID when the SMC key is missing/zero, instead of gao-sun#273's exclusive #if arch(arm64) split - SMC stays open on Apple Silicon so fan readings keep working on machines that expose them. - CpuStore: per-core usage via host_processor_info with E/P-core labels (hw.perflevel1.physicalcpu; efficiency cluster enumerates first). gao-sun#273's per-core *temperature* display was dropped: it mapped alphabetically-sorted PMU sensors to core indices, which is arbitrary. - GPU on Apple Silicon: SystemProfiler gains resolvedDeviceId (AS GPUs have no PCI device ID), GPU.getInfo() no longer requires IOPCIMatch (AGXAccelerator), GpuStore matches the single shared-die GPU, and GPU core count is decoded. - CpuMenuBlockView: per-core usage bars in the CPU menu block ("cpu.cores" string added to en/zh-Hans). Verified on Apple Silicon (arm64 host, Xcode 26.3): Debug and Release both BUILD SUCCEEDED (Release universal x86_64+arm64); live run caches 64 IOHID sensor services; standalone harness reads 63 sensors with plausible values and cpuTemperature 48.0C. Known cosmetic follow-up: SMC lists two unreadable keys on AS whose failed reads log per tick before the IOHID fallback kicks in. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
realhidden
pushed a commit
to realhidden/eul
that referenced
this pull request
Sep 18, 2026
Adapts community PR gao-sun#273 onto the Xcode-26 base, with fixes: - New AppleSiliconSensors: reads M-series die temperatures via the private IOHIDEventSystemClient API (AppleVendor usage page, PMU tdie sensors) with dlsym resolution. Unlike gao-sun#273's version, the Copy-rule CF returns (event, Product string) are released per read instead of leaking two objects per sensor per tick, the owning CFArray is retained so cached service pointers cannot dangle, and sensor-name fallbacks (PMU tdie -> PMU2 tdie -> SOC MTR Temp Sensor) cover newer chip generations. - SmcControl: temperature getters fall back to IOHID when the SMC key is missing/zero, instead of gao-sun#273's exclusive #if arch(arm64) split - SMC stays open on Apple Silicon so fan readings keep working on machines that expose them. - CpuStore: per-core usage via host_processor_info with E/P-core labels (hw.perflevel1.physicalcpu; efficiency cluster enumerates first). gao-sun#273's per-core *temperature* display was dropped: it mapped alphabetically-sorted PMU sensors to core indices, which is arbitrary. - GPU on Apple Silicon: SystemProfiler gains resolvedDeviceId (AS GPUs have no PCI device ID), GPU.getInfo() no longer requires IOPCIMatch (AGXAccelerator), GpuStore matches the single shared-die GPU, and GPU core count is decoded. - CpuMenuBlockView: per-core usage bars in the CPU menu block ("cpu.cores" string added to en/zh-Hans). Verified on Apple Silicon (arm64 host, Xcode 26.3): Debug and Release both BUILD SUCCEEDED (Release universal x86_64+arm64); live run caches 64 IOHID sensor services; standalone harness reads 63 sensors with plausible values and cpuTemperature 48.0C. Known cosmetic follow-up: SMC lists two unreadable keys on AS whose failed reads log per tick before the IOHID fallback kicks in. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adapt arm cpu gpu display