Skip to content

Commit bf88ba0

Browse files
committed
Revert "[NFC][SROA] speculateSelectInstLoads(): play nice with typed pointers for now"
This reverts commit 9f27f45. Supposed to be NFC, but broke buildbots (test addrspacecast.ll is failing).
1 parent 05f343f commit bf88ba0

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

llvm/lib/Transforms/Scalar/SROA.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1518,14 +1518,6 @@ static void speculateSelectInstLoads(SelectInst &SI, LoadInst &LI,
15181518

15191519
assert(LI.isSimple() && "We only speculate simple loads");
15201520

1521-
if (auto *TypedPtrTy = LI.getType()->getPointerTo();
1522-
SI.getType() != TypedPtrTy) {
1523-
TV = BitCastInst::CreatePointerBitCastOrAddrSpaceCast(TV, TypedPtrTy, "",
1524-
&LI);
1525-
FV = BitCastInst::CreatePointerBitCastOrAddrSpaceCast(FV, TypedPtrTy, "",
1526-
&LI);
1527-
}
1528-
15291521
IRB.SetInsertPoint(&LI);
15301522
LoadInst *TL =
15311523
IRB.CreateAlignedLoad(LI.getType(), TV, LI.getAlign(),

0 commit comments

Comments
 (0)