Skip to content

Commit 356f2b7

Browse files
committed
[AddressLowering] Added TODO.
1 parent b3ee1fd commit 356f2b7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/SILOptimizer/Mandatory/AddressLowering.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,11 @@ static bool isStoreCopy(SILValue value) {
377377
SmallVector<SILValue, 4> roots;
378378
findGuaranteedReferenceRoots(source, /*lookThroughNestedBorrows=*/true,
379379
roots);
380+
// TODO: Rather than checking whether the store is out of range of any
381+
// guaranteed root's SSAPrunedLiveness, instead check whether it is out of
382+
// range of ExtendedLiveness of the borrow introducers:
383+
// - visit borrow introducers via visitBorrowIntroducers
384+
// - call ExtendedLiveness.compute on each borrow introducer
380385
if (llvm::any_of(roots, [&](SILValue root) {
381386
// Handle forwarding phis conservatively rather than recursing.
382387
if (SILArgument::asPhi(root) && !BorrowedValue(root))

0 commit comments

Comments
 (0)