Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xe: jit: gemm: reuse xe2 strategies on xe3 #2440

Merged
merged 1 commit into from
Jan 22, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/gpu/intel/jit/gemm/selector/kernel_selector.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright 2022-2024 Intel Corporation
* Copyright 2022-2025 Intel Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -207,17 +207,18 @@ const kcatalog::Entry *select(const kcatalog::Catalog &catalog, int npatterns, c
}
}

/* Temporarily reuse XeHPC strategies for Xe2 until more Xe2 strategies are
/* Temporarily reuse XeHPC/Xe2 strategies for Xe2/Xe3 until more strategies are
in the catalog*/
if (!bestEntry
&& (patterns[0].selector.hw == kcatalog::HWTagXe2
|| patterns[0].selector.hw == kcatalog::HWTagXe3
)) {
std::vector<MatchParams> override_patterns;
const bool isXe3 = patterns[0].selector.hw == kcatalog::HWTagXe3;
override_patterns.reserve(npatterns);
for (int i = 0; i < npatterns; i++) {
override_patterns.emplace_back(patterns[i]);
override_patterns.back().selector.hw = kcatalog::HWTagXeHPC;
override_patterns.back().selector.hw = isXe3 ? kcatalog::HWTagXe2 : kcatalog::HWTagXeHPC;
}
return select(catalog, npatterns, override_patterns.data(), eparams, aux);
}
Expand Down
Loading