authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-01-20 23:15:44+01:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-04-25 21:54:48+02:00
logc46a8e0d2c79e59e21ee207e849f8c4481cdd13d
tree2d10d7a233689541bfadf32035e9647bd7135d48
parenta24eee83903bc9387720fd489e6581b8afd051a2
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

std.zig.system.x86: detect Diamonds Rapids, Wildcat Lake, and Nova Lake


1 files changed, 15 insertions(+), 1 deletions(-)

lib/std/zig/system/x86.zig+15-1
...@@ -232,7 +232,7 @@ fn detectIntelProcessor(cpu: *Target.Cpu, family: u32, model: u32, brand_id: u32...@@ -232,7 +232,7 @@ fn detectIntelProcessor(cpu: *Target.Cpu, family: u32, model: u32, brand_id: u32
232 cpu.model = &Target.x86.cpu.lunarlake;232 cpu.model = &Target.x86.cpu.lunarlake;
233 return;233 return;
234 },234 },
235 0xcc => {235 0xcc, 0xd5 => {
236 cpu.model = &Target.x86.cpu.pantherlake;236 cpu.model = &Target.x86.cpu.pantherlake;
237 return;237 return;
238 },238 },
...@@ -307,6 +307,20 @@ fn detectIntelProcessor(cpu: *Target.Cpu, family: u32, model: u32, brand_id: u32...@@ -307,6 +307,20 @@ fn detectIntelProcessor(cpu: *Target.Cpu, family: u32, model: u32, brand_id: u32
307 cpu.model = &Target.x86.cpu.pentium4;307 cpu.model = &Target.x86.cpu.pentium4;
308 return;308 return;
309 },309 },
310 18 => switch (model) {
311 0x01, 0x03 => {
312 cpu.model = &Target.x86.cpu.novalake;
313 return;
314 },
315 else => return, // Unknown CPU Model
316 },
317 19 => switch (model) {
318 0x01 => {
319 cpu.model = &Target.x86.cpu.diamondrapids;
320 return;
321 },
322 else => return, // Unknown CPU Model
323 },
310 else => return, // Unknown CPU Model324 else => return, // Unknown CPU Model
311 }325 }
312}326}