Skip to content

Commit 58286f9

Browse files
committed
Revert "[ConstraintElim] Treat ConstantPointerNull as constant offset 0."
This reverts commit 2362813. Revert as this is causing some test failures.
1 parent 07fdc08 commit 58286f9

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

llvm/lib/Transforms/Scalar/ConstraintElimination.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -455,9 +455,6 @@ static Decomposition decompose(Value *V,
455455
if (Ty->isPointerTy() && !IsSigned) {
456456
if (auto *GEP = dyn_cast<GEPOperator>(V))
457457
return decomposeGEP(*GEP, Preconditions, IsSigned, DL);
458-
if (isa<ConstantPointerNull>(V))
459-
return int64_t(0);
460-
461458
return V;
462459
}
463460

0 commit comments

Comments
 (0)