From 7b869cc9848a30e3e5f6ed69286ce3dca8e71d15 Mon Sep 17 00:00:00 2001 From: Dor Forer Date: Tue, 17 Nov 2026 09:01:57 +0200 Subject: [PATCH] Bump cpu_features to fix UBSan misaligned loads in IsVendor cpu_features v0.10.1 (and v0.11.0) read the CPUID vendor strings through unaligned uint32_t casts in IsVendor/SetVendor, which UBSan reports as a misaligned load from GetX86Info. Upstream fixed it with memcpy in google/cpu_features#458, which is not in any release yet, so pin that commit. The public API delta from v0.10.1 is additive only. Co-Authored-By: Claude Opus 5.5 --- cmake/cpu_features.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmake/cpu_features.cmake b/cmake/cpu_features.cmake index 07f097761..f63b0c21f 100644 --- a/cmake/cpu_features.cmake +++ b/cmake/cpu_features.cmake @@ -4,6 +4,8 @@ option(CMAKE_POSITION_INDEPENDENT_CODE "" ON) FetchContent_Declare( cpu_features GIT_REPOSITORY https://github.com/google/cpu_features.git - GIT_TAG v0.10.1 + # v0.11.0 plus google/cpu_features#458, which fixes UBSan misaligned loads in + # IsVendor/SetVendor. Switch to v0.12.0 once it is released. + GIT_TAG a1c8a2fcf49d534799b966c63e0b2124cd2f60ae ) FetchContent_MakeAvailable(cpu_features)