diff --git a/llvm/utils/TableGen/CodeGenRegisters.cpp b/llvm/utils/TableGen/CodeGenRegisters.cpp --- a/llvm/utils/TableGen/CodeGenRegisters.cpp +++ b/llvm/utils/TableGen/CodeGenRegisters.cpp @@ -2025,7 +2025,8 @@ } } LLVM_DEBUG(dbgs() << "\n"); - assert(!RegClassUnitSets[RCIdx].empty() && "missing unit set for regclass"); + assert((!RegClassUnitSets[RCIdx].empty() || !RC.GeneratePressureSet) && + "missing unit set for regclass"); } // For each register unit, ensure that we have the list of UnitSets that