This is an archive of the discontinued LLVM Phabricator instance.

[X86] Support some Intel CPUs for cpu_specific/dispatch feature
ClosedPublic

Authored by FreddyYe on Jul 5 2023, 4:35 AM.

Diff Detail

Event Timeline

FreddyYe created this revision.Jul 5 2023, 4:35 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 5 2023, 4:35 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
FreddyYe requested review of this revision.Jul 5 2023, 4:35 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJul 5 2023, 4:35 AM
RKSimon added inline comments.Jul 5 2023, 5:12 AM
llvm/lib/TargetParser/X86TargetParser.cpp
333

add this as well?

FreddyYe marked an inline comment as done.Jul 5 2023, 5:46 PM
FreddyYe added inline comments.
llvm/lib/TargetParser/X86TargetParser.cpp
333

cpu names contain '-' are not supported for cpu_specific/dispatch feature since '-' is not an identifier character. The solution here is creating a new name with '_' replacing and set the OnlyForCPUDispatchSpecific as true, like icelake-client, icelake-server and goldmont-plus

RKSimon accepted this revision.Jul 6 2023, 7:42 AM

LGTM

llvm/lib/TargetParser/X86TargetParser.cpp
333

Understood - cheers.

This revision is now accepted and ready to land.Jul 6 2023, 7:42 AM
skan accepted this revision.Jul 6 2023, 5:27 PM

LGTM

FreddyYe updated this revision to Diff 537957.Jul 6 2023, 8:01 PM
FreddyYe marked an inline comment as done.

Tuned some manglings. SPR should create a new mangling for its feature list.

FreddyYe added inline comments.Jul 6 2023, 8:06 PM
llvm/lib/TargetParser/X86TargetParser.cpp
419

SPR has AVX512BF16 comparing to icelake-server, which is a X86_FEATURE_COMPAT feature.

FreddyYe updated this revision to Diff 537980.Jul 6 2023, 9:44 PM

Tune test as well.

This revision was landed with ongoing or failed builds.Jul 6 2023, 10:47 PM
This revision was automatically updated to reflect the committed changes.