Skip to content

Commit 6a852d9

Browse files
committed
[X86][compiler-rt] Split CPU names even they have the same subtype
Fixes: #118205
1 parent 18760ce commit 6a852d9

File tree

1 file changed

+27
-2
lines changed
  • compiler-rt/lib/builtins/cpu_model

1 file changed

+27
-2
lines changed

compiler-rt/lib/builtins/cpu_model/x86.c

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -461,16 +461,31 @@ static const char *getIntelProcessorTypeAndSubtype(unsigned Family,
461461
// Alderlake:
462462
case 0x97:
463463
case 0x9a:
464+
CPU = "alderlake";
465+
*Type = INTEL_COREI7;
466+
*Subtype = INTEL_COREI7_ALDERLAKE;
467+
break;
468+
464469
// Raptorlake:
465470
case 0xb7:
466471
case 0xba:
467472
case 0xbf:
473+
CPU = "raptorlake";
474+
*Type = INTEL_COREI7;
475+
*Subtype = INTEL_COREI7_ALDERLAKE;
476+
break;
477+
468478
// Meteorlake:
469479
case 0xaa:
470480
case 0xac:
481+
CPU = "meteorlake";
482+
*Type = INTEL_COREI7;
483+
*Subtype = INTEL_COREI7_ALDERLAKE;
484+
break;
485+
471486
// Gracemont:
472487
case 0xbe:
473-
CPU = "alderlake";
488+
CPU = "gracement";
474489
*Type = INTEL_COREI7;
475490
*Subtype = INTEL_COREI7_ALDERLAKE;
476491
break;
@@ -486,9 +501,14 @@ static const char *getIntelProcessorTypeAndSubtype(unsigned Family,
486501

487502
// Arrowlake S:
488503
case 0xc6:
504+
CPU = "arrowlake-s";
505+
*Type = INTEL_COREI7;
506+
*Subtype = INTEL_COREI7_ARROWLAKE_S;
507+
break;
508+
489509
// Lunarlake:
490510
case 0xbd:
491-
CPU = "arrowlake-s";
511+
CPU = "lunarlake";
492512
*Type = INTEL_COREI7;
493513
*Subtype = INTEL_COREI7_ARROWLAKE_S;
494514
break;
@@ -510,6 +530,11 @@ static const char *getIntelProcessorTypeAndSubtype(unsigned Family,
510530

511531
// Emerald Rapids:
512532
case 0xcf:
533+
CPU = "emeraldrapids";
534+
*Type = INTEL_COREI7;
535+
*Subtype = INTEL_COREI7_SAPPHIRERAPIDS;
536+
break;
537+
513538
// Sapphire Rapids:
514539
case 0x8f:
515540
CPU = "sapphirerapids";

0 commit comments

Comments
 (0)