mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Revert "New SIL instructions to support tail-allocated arrays in SIL."
This commit is contained in:
@@ -305,7 +305,6 @@ AliasResult AliasAnalysis::aliasAddressProjection(SILValue V1, SILValue V2,
|
||||
static bool isTypedAccessOracle(SILInstruction *I) {
|
||||
switch (I->getKind()) {
|
||||
case ValueKind::RefElementAddrInst:
|
||||
case ValueKind::RefTailAddrInst:
|
||||
case ValueKind::StructElementAddrInst:
|
||||
case ValueKind::TupleElementAddrInst:
|
||||
case ValueKind::UncheckedTakeEnumDataAddrInst:
|
||||
@@ -341,9 +340,7 @@ static bool isAddressRootTBAASafe(SILValue V) {
|
||||
default:
|
||||
return false;
|
||||
case ValueKind::AllocStackInst:
|
||||
case ValueKind::ProjectBoxInst:
|
||||
case ValueKind::RefElementAddrInst:
|
||||
case ValueKind::RefTailAddrInst:
|
||||
case ValueKind::AllocBoxInst:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -369,7 +366,7 @@ static SILType findTypedAccessType(SILValue V) {
|
||||
}
|
||||
|
||||
SILType swift::computeTBAAType(SILValue V) {
|
||||
if (isAddressRootTBAASafe(getUnderlyingAddressRoot(V)))
|
||||
if (isAddressRootTBAASafe(getUnderlyingObject(V)))
|
||||
return findTypedAccessType(V);
|
||||
|
||||
// FIXME: add ref_element_addr check here. TBAA says that objects cannot be
|
||||
|
||||
Reference in New Issue
Block a user