[Lldb-commits] [lldb] [lldb] Use TargetParser for AMDGPU architectures (PR #223192)
satyanarayana reddy janga via lldb-commits
lldb-commits at lists.llvm.org
Wed Sep 16 09:04:57 PDT 2026
================
@@ -1452,6 +1041,16 @@ bool ArchSpec::IsMatch(const ArchSpec &rhs, MatchType match) const {
const llvm::Triple &lhs_triple = GetTriple();
const llvm::Triple &rhs_triple = rhs.GetTriple();
+ if (lhs_triple.getArch() == llvm::Triple::amdgpu &&
+ rhs_triple.getArch() == llvm::Triple::amdgpu) {
+ bool sub_arches_match =
+ match == ExactMatch
+ ? lhs_triple.getSubArch() == rhs_triple.getSubArch()
+ : llvm::AMDGPU::isSubArchCompatible(lhs_triple, rhs_triple);
+ if (!sub_arches_match)
+ return false;
----------------
satyajanga wrote:
The AMDGPU special casing is still necessary because now all the models now share `eCore_amd_gpu`
and isCompatibleWith treats 2 different AMD GPU Subarchs as the same. for ExactMatch we still need to compare the SubArch as well.
Let me know if I am misunderstanding your question.
https://github.com/llvm/llvm-project/pull/223192
More information about the lldb-commits
mailing list