if (spillAlways() && lastAllocatedRefPosition != nullptr && !lastAllocatedRefPosition->IsPhysRegRef() &&
!lastAllocatedRefPosition->getInterval()->isInternal &&
+ (!lastAllocatedRefPosition->RegOptional() || (lastAllocatedRefPosition->registerAssignment != RBM_NONE)) &&
(RefTypeIsDef(lastAllocatedRefPosition->refType) || lastAllocatedRefPosition->getInterval()->isLocalVar))
{
assert(lastAllocatedRefPosition->registerAssignment != RBM_NONE);
{
// Available registers should not hold constants
assert(isRegAvailable(reg, physRegRecord->registerType));
- assert(!isRegConstant(reg, physRegRecord->registerType));
+ assert(!isRegConstant(reg, physRegRecord->registerType) || spillAlways());
assert(nextIntervalRef[reg] == MaxLocation);
assert(spillCost[reg] == 0);
}