Skip to content

Commit bbd3696

Browse files
aslclackary
authored andcommitted
Add missed case to AssignAddressToDef. (swiftlang#72617)
Fixes swiftlang#71744 (cherry picked from commit a63078f) (cherry picked from commit 2250314)
1 parent b85988d commit bbd3696

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lib/IRGen/LoadableByAddress.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3799,6 +3799,15 @@ class AssignAddressToDef : SILInstructionVisitor<AssignAddressToDef> {
37993799
assignment.mapValueToAddress(origValue, newAddr);
38003800
assignment.markForDeletion(bc);
38013801
}
3802+
3803+
void visitUncheckedBitwiseCastInst(UncheckedBitwiseCastInst *bc) {
3804+
auto builder = assignment.getBuilder(bc->getIterator());
3805+
auto opdAddr = assignment.getAddressForValue(bc->getOperand());
3806+
auto newAddr = builder.createUncheckedAddrCast(
3807+
bc->getLoc(), opdAddr, bc->getType().getAddressType());
3808+
assignment.mapValueToAddress(origValue, newAddr);
3809+
assignment.markForDeletion(bc);
3810+
}
38023811
};
38033812
} // namespace
38043813

0 commit comments

Comments
 (0)