From 77034cd325fd911cd7421d53d206d2ea4ce381df Mon Sep 17 00:00:00 2001 From: Jay Foad Date: Thu, 5 Feb 2026 17:22:46 +0000 Subject: [PATCH] [CodeGen] Make use of TargetRegisterInfo::findCommonRegClass. NFC. (#179981) --- llvm/lib/CodeGen/DetectDeadLanes.cpp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/llvm/lib/CodeGen/DetectDeadLanes.cpp b/llvm/lib/CodeGen/DetectDeadLanes.cpp index d2522fd5eb0e..78111fc038b2 100644 --- a/llvm/lib/CodeGen/DetectDeadLanes.cpp +++ b/llvm/lib/CodeGen/DetectDeadLanes.cpp @@ -94,15 +94,7 @@ static bool isCrossCopy(const MachineRegisterInfo &MRI, } } - unsigned PreA, PreB; // Unused. - if (SrcSubIdx && DstSubIdx) - return !TRI.getCommonSuperRegClass(SrcRC, SrcSubIdx, DstRC, DstSubIdx, PreA, - PreB); - if (SrcSubIdx) - return !TRI.getMatchingSuperRegClass(SrcRC, DstRC, SrcSubIdx); - if (DstSubIdx) - return !TRI.getMatchingSuperRegClass(DstRC, SrcRC, DstSubIdx); - return !TRI.getCommonSubClass(SrcRC, DstRC); + return !TRI.findCommonRegClass(SrcRC, SrcSubIdx, DstRC, DstSubIdx); } void DeadLaneDetector::addUsedLanesOnOperand(const MachineOperand &MO,