Skip to content

Commit c805a45

Browse files
committed
Add more names to the reverse maps
1 parent 88db308 commit c805a45

1 file changed

Lines changed: 28 additions & 17 deletions

File tree

src/llvm_compat.cpp

Lines changed: 28 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,15 @@ static const std::unordered_map<std::string, std::string> aarch64_feature_map =
1717
{"crc32", "crc"}, {"fcma", "complxnum"}, {"fp", "fp-armv8"},
1818
{"fphp", "fullfp16"}, {"jscvt", "jsconv"}, {"lrcpc", "rcpc"},
1919
{"ilrcpc", "rcpc-immo"}, {"paca", "pauth"}, {"pacg", "pauth"},
20-
{"rng", "rand"}, {"svebf16", "sve-bf16"}, {"svei8mm", "sve-i8mm"},
20+
{"rng", "rand"},
2121
};
2222

2323
// Features to filter out (no LLVM equivalent or implied by other features)
2424
static const std::set<std::string> aarch64_filter_out = {
25-
"cpuid", "dcpodp", "dcpop",
26-
"dgh", // Data Gathering Hint - no LLVM feature
27-
"evtstrm", "flagm2", "frint", "uscat", "sha1", "sha512", "pmull",
25+
"cpuid", "dcpodp", "dcpop", "dgh", "evtstrm", "flagm2", "frint",
26+
"uscat", "sha1", "sha512", "pmull",
27+
"svebf16", // implied by sve + bf16
28+
"svei8mm", // implied by sve + i8mm
2829
};
2930

3031
// ============================================================================
@@ -261,25 +262,35 @@ static const std::unordered_map<std::string, std::string> aarch64_cpu_reverse_ma
261262
{"apple-a15", "a15"},
262263
{"apple-a16", "a16"},
263264
{"apple-a17", "a17"},
264-
// Qualcomm
265+
// Qualcomm - thunderx2 is in DB
265266
{"thunderx2t99", "thunderx2"},
266-
{"thunderx3t110", "thunderx3"},
267-
// ARM Cortex
268-
{"cortex-a53", "cortex_a53"},
269-
{"cortex-a55", "cortex_a55"},
270-
{"cortex-a57", "cortex_a57"},
267+
{"thunderx3t110", "thunderx2"}, // thunderx3 not in DB, use thunderx2
268+
// ARM Cortex - only cortex_a72 is in DB, map older ones to aarch64 base
269+
{"cortex-a35", "aarch64"},
270+
{"cortex-a53", "aarch64"},
271+
{"cortex-a55", "aarch64"},
272+
{"cortex-a57", "aarch64"},
273+
{"cortex-a65", "aarch64"},
271274
{"cortex-a72", "cortex_a72"},
272-
{"cortex-a73", "cortex_a73"},
273-
{"cortex-a75", "cortex_a75"},
274-
{"cortex-a76", "cortex_a76"},
275-
{"cortex-a77", "cortex_a77"},
276-
{"cortex-a78", "cortex_a78"},
277-
{"cortex-x1", "cortex_x1"},
278-
{"cortex-x2", "cortex_x2"},
275+
{"cortex-a73", "cortex_a72"},
276+
{"cortex-a75", "cortex_a72"},
277+
{"cortex-a76", "cortex_a72"},
278+
{"cortex-a77", "cortex_a72"},
279+
{"cortex-a78", "cortex_a72"},
280+
{"cortex-a710", "cortex_a72"},
281+
{"cortex-x1", "cortex_a72"},
282+
{"cortex-x2", "cortex_a72"},
283+
{"cortex-x3", "cortex_a72"},
284+
// Neoverse - all are in DB
279285
{"neoverse-n1", "neoverse_n1"},
280286
{"neoverse-n2", "neoverse_n2"},
281287
{"neoverse-v1", "neoverse_v1"},
282288
{"neoverse-v2", "neoverse_v2"},
289+
// Nvidia
290+
{"carmel", "aarch64"},
291+
// Ampere
292+
{"ampere1", "neoverse_n1"},
293+
{"ampere1a", "neoverse_n1"},
283294
};
284295

285296
static const std::unordered_map<std::string, std::string> x86_64_cpu_reverse_map = {

0 commit comments

Comments
 (0)