llvm-project/llvm/unittests/Transforms/Utils
Roman Lebedev 78b8ce40ef
Reland [SCEV] Improve modelling for (null) pointer constants
This reverts commit 329aeb5db4,
and relands commit 61f006ac65.

This is a continuation of D89456.

As it was suggested there, now that SCEV models `PtrToInt`,
we can try to improve SCEV's pointer handling.
In particular, i believe, i will need this in the future
to further fix `SCEVAddExpr`operation type handling.

This removes special handling of `ConstantPointerNull`
from `ScalarEvolution::createSCEV()`, and add constant folding
into `ScalarEvolution::getPtrToIntExpr()`.
This way, `null` constants stay as such in SCEV's,
but gracefully become zero integers when asked.

Reviewed By: Meinersbur

Differential Revision: https://reviews.llvm.org/D98147
2021-03-13 16:05:34 +03:00
..
ASanStackFrameLayoutTest.cpp
BasicBlockUtilsTest.cpp Ensure SplitEdge to return the new block between the two given blocks 2020-12-18 17:37:17 +00:00
CMakeLists.txt Reland "[Debugify] Make the debugify aware of the original (-g) Debug Info" 2021-02-18 23:29:22 -08:00
CallPromotionUtilsTest.cpp [llvm][NFC] Refactor uses of CallSite to CallBase - call promotion 2020-04-12 08:27:29 -07:00
CloningTest.cpp TransformUtils: Fix metadata handling in CloneModule (and improve CloneFunctionInto) 2021-02-15 11:56:00 -08:00
CodeExtractorTest.cpp [CodeExtractor] Replace uses of extracted bitcasts in out-of-region lifetime markers 2020-11-05 17:01:08 -08:00
CodeMoverUtilsTest.cpp [NFC] Reduce include files dependency. 2020-12-03 18:25:05 +03:00
DebugifyTest.cpp Reland "[Debugify] Make the debugify aware of the original (-g) Debug Info" 2021-02-18 23:29:22 -08:00
FunctionComparatorTest.cpp
IntegerDivisionTest.cpp
LocalTest.cpp Fix 2: [DebugInfo] Support DIArgList in DbgVariableIntrinsic 2021-03-08 15:43:39 +00:00
LoopRotationUtilsTest.cpp
LoopUtilsTest.cpp LoopUtils.h - reduce AliasAnalysis.h include to forward declarations. NFC. 2020-06-24 17:58:38 +01:00
SSAUpdaterBulkTest.cpp
ScalarEvolutionExpanderTest.cpp Reland [SCEV] Improve modelling for (null) pointer constants 2021-03-13 16:05:34 +03:00
SizeOptsTest.cpp
UnrollLoopTest.cpp [NFC][SCEV] Piping to pass TTI into SCEVExpander::isHighCostExpansionHelper() 2020-02-25 23:05:56 +03:00
VFABIUtils.cpp
ValueMapperTest.cpp ValueMapper: Rename RF_MoveDistinctMDs => RF_ReuseAndMutateDistinctMDs, NFC 2021-02-10 16:53:21 -08:00