[NFC] OwnershipUtils: Add a UsePoint type.

The type is a union of an Operand (a real use) and a SILInstruction (an
implicit use).  Such a type is needed to reflect the fact that with
incomplete lifetimes, values can be implicitly destroyed at the
terminators of blocks in dead end regions (along the vaule's
availability boundary).
This commit is contained in:
Nate Chandler
2025-08-08 15:04:45 -07:00
parent 99091c93ae
commit cbe383524c
2 changed files with 40 additions and 0 deletions

View File

@@ -992,6 +992,9 @@ bool BorrowedValue::areWithinExtendedScope(Instructions insts,
return liveness.areWithinBoundary(insts, deadEndBlocks);
}
template bool BorrowedValue::areWithinExtendedScope<UsePointInstructionRange>(
UsePointInstructionRange insts, DeadEndBlocks *deadEndBlocks) const;
template bool
BorrowedValue::areWithinExtendedScope<SILInstruction::OperandUserRange>(
SILInstruction::OperandUserRange insts, DeadEndBlocks *deadEndBlocks) const;