Fix CPU telemetry temperature/clock speed on Windows and macOS
sample_cpu_temperature() only ever had a Linux implementation, so Windows and macOS runs recorded empty temperature data points for every sample. sample_cpu_clock_mhz() on both platforms read a static nominal frequency once (Windows: the ~MHz registry value; macOS: the hw.cpufrequency sysctl) instead of a live reading, so clock speed showed as a constant throughout the benchmark. Windows: temperature now queries the ACPI thermal zone over WMI (MSAcpi_ThermalZoneTemperature), and clock speed reads live per-core frequency via CallNtPowerInformation(ProcessorInformation). Both are XP-compatible (verified via mingw cross-compile with the existing windows-i386 XP toolchain/PE checks). macOS: temperature reads the SMC directly (AppleSMC user client), checking known CPU sensor keys across Intel and Apple Silicon (M1-M5). There is no live-frequency API on macOS at all (Apple Silicon has none, and hw.cpufrequency was always a fixed nominal value even on Intel), so clock speed now reports as unavailable instead of a misleading constant. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PcL8rcwwBeD6W3fZFCRLss
This commit is contained in:
@@ -175,5 +175,5 @@ jobs:
|
||||
release/SHA256SUMS \
|
||||
--repo "$GITHUB_REPOSITORY" \
|
||||
--title "Release $RELEASE_TAG" \
|
||||
--notes "Fixed x86/Linux builds on systems without OpenSSL development headers. Result uploads now use plain HTTP on every platform, removing the OpenSSL build and runtime dependency." \
|
||||
--notes "Hotfix: CPU telemetry (temperature and clock speed) recorded during benchmark runs was not working on Windows or macOS, showing empty temperature data points and a constant clock speed. Windows temperature now reads the ACPI thermal zone over WMI, and clock speed reads live per-core frequency via CallNtPowerInformation instead of a static registry value. macOS temperature now reads the SMC directly across Intel and Apple Silicon (M1-M5) Macs. macOS clock speed now reports as unavailable rather than the fixed nominal frequency it previously showed, since no live-frequency API exists on macOS." \
|
||||
--generate-notes
|
||||
|
||||
Reference in New Issue
Block a user