Jlm
Functions
ScalarEvolutionTests.cpp File Reference
#include <jlm/llvm/ir/operators/delta.hpp>
#include <jlm/llvm/ir/operators/GetElementPtr.hpp>
#include <jlm/llvm/ir/operators/IntegerOperations.hpp>
#include <jlm/llvm/ir/operators/lambda.hpp>
#include <jlm/llvm/ir/operators/Load.hpp>
#include <jlm/llvm/ir/operators/operators.hpp>
#include <jlm/llvm/ir/operators/sext.hpp>
#include <jlm/llvm/ir/RvsdgModule.hpp>
#include <jlm/llvm/opt/ScalarEvolution.hpp>
#include <jlm/rvsdg/view.hpp>
#include <gtest/gtest.h>
Include dependency graph for ScalarEvolutionTests.cpp:

Go to the source code of this file.

Functions

static std::pair< std::unordered_map< const jlm::rvsdg::Output *, std::unique_ptr< jlm::llvm::SCEVChainRecurrence > >, std::unordered_map< const jlm::rvsdg::ThetaNode *, size_t > > RunScalarEvolution (jlm::rvsdg::RvsdgModule &rvsdgModule)
 
 TEST (ScalarEvolutionTests, NonEvolvingVariable)
 
 TEST (ScalarEvolutionTests, InductionVariable)
 
 TEST (ScalarEvolutionTests, RecursiveInductionVariable)
 
 TEST (ScalarEvolutionTests, PolynomialInductionVariable)
 
 TEST (ScalarEvolutionTests, ThirdDegreePolynomialInductionVariable)
 
 TEST (ScalarEvolutionTests, InductionVariableWithMultiplication)
 
 TEST (ScalarEvolutionTests, InvalidInductionVariableWithMultiplication)
 
 TEST (ScalarEvolutionTests, MultiplicationOfTwoAffineChrecs)
 
 TEST (ScalarEvolutionTests, MultiplicationOfTwoQuadraticChrecs)
 
 TEST (ScalarEvolutionTests, InvalidPolynomialInductionVariableWithMultiplication)
 
 TEST (ScalarEvolutionTests, InductionVariableWithSubtraction)
 
 TEST (ScalarEvolutionTests, PolynomialInductionVariableWithSubtraction)
 
 TEST (ScalarEvolutionTests, InductionVariablesWithNonConstantInitialValues)
 
 TEST (ScalarEvolutionTests, InductionVariablesWithNonConstantInitialValuesAndMultiplication)
 
 TEST (ScalarEvolutionTests, SelfRecursiveInductionVariable)
 
 TEST (ScalarEvolutionTests, DependentOnInvalidInductionVariable)
 
 TEST (ScalarEvolutionTests, MutuallyDependentInductionVariables)
 
 TEST (ScalarEvolutionTests, MultiLayeredMutuallyDependentInductionVariables)
 
 TEST (ScalarEvolutionTests, InductionVariablesInNestedLoops)
 
 TEST (ScalarEvolutionTests, InductionVariablesInNestedLoopsWithFolding)
 
 TEST (ScalarEvolutionTests, InductionVariablesInSisterLoops)
 
 TEST (ScalarEvolutionTests, ComputeRecurrenceForArrayGEP)
 
 TEST (ScalarEvolutionTests, ComputeRecurrenceForStructGEP)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForSLTComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForSLEComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForSGTComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForSGEComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForNEComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForEQComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForInfiniteSLTComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForInfiniteSGTComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForInfiniteNEComparisonWithAffineRecurrence)
 
 TEST (ScalarEvolutionTests, ComputeTripCountForSimpleQuadraticRecurrence)
 
 TEST (ScalarEvolutionTests, TestTripCountCouldNotCompute)
 

Function Documentation

◆ RunScalarEvolution()

static std::pair< std::unordered_map<const jlm::rvsdg::Output *, std::unique_ptr<jlm::llvm::SCEVChainRecurrence> >, std::unordered_map<const jlm::rvsdg::ThetaNode *, size_t> > RunScalarEvolution ( jlm::rvsdg::RvsdgModule rvsdgModule)
static

Definition at line 22 of file ScalarEvolutionTests.cpp.

◆ TEST() [1/34]

TEST ( ScalarEvolutionTests  ,
ComputeRecurrenceForArrayGEP   
)

Definition at line 1461 of file ScalarEvolutionTests.cpp.

◆ TEST() [2/34]

TEST ( ScalarEvolutionTests  ,
ComputeRecurrenceForStructGEP   
)

Definition at line 1575 of file ScalarEvolutionTests.cpp.

◆ TEST() [3/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForEQComparisonWithAffineRecurrence   
)

Definition at line 1883 of file ScalarEvolutionTests.cpp.

◆ TEST() [4/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForInfiniteNEComparisonWithAffineRecurrence   
)

Definition at line 1997 of file ScalarEvolutionTests.cpp.

◆ TEST() [5/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForInfiniteSGTComparisonWithAffineRecurrence   
)

Definition at line 1959 of file ScalarEvolutionTests.cpp.

◆ TEST() [6/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForInfiniteSLTComparisonWithAffineRecurrence   
)

Definition at line 1921 of file ScalarEvolutionTests.cpp.

◆ TEST() [7/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForNEComparisonWithAffineRecurrence   
)

Definition at line 1845 of file ScalarEvolutionTests.cpp.

◆ TEST() [8/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForSGEComparisonWithAffineRecurrence   
)

Definition at line 1806 of file ScalarEvolutionTests.cpp.

◆ TEST() [9/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForSGTComparisonWithAffineRecurrence   
)

Definition at line 1768 of file ScalarEvolutionTests.cpp.

◆ TEST() [10/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForSimpleQuadraticRecurrence   
)

Definition at line 2035 of file ScalarEvolutionTests.cpp.

◆ TEST() [11/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForSLEComparisonWithAffineRecurrence   
)

Definition at line 1728 of file ScalarEvolutionTests.cpp.

◆ TEST() [12/34]

TEST ( ScalarEvolutionTests  ,
ComputeTripCountForSLTComparisonWithAffineRecurrence   
)

Definition at line 1690 of file ScalarEvolutionTests.cpp.

◆ TEST() [13/34]

TEST ( ScalarEvolutionTests  ,
DependentOnInvalidInductionVariable   
)

Definition at line 982 of file ScalarEvolutionTests.cpp.

◆ TEST() [14/34]

TEST ( ScalarEvolutionTests  ,
InductionVariable   
)

Definition at line 68 of file ScalarEvolutionTests.cpp.

◆ TEST() [15/34]

TEST ( ScalarEvolutionTests  ,
InductionVariablesInNestedLoops   
)

Definition at line 1155 of file ScalarEvolutionTests.cpp.

◆ TEST() [16/34]

TEST ( ScalarEvolutionTests  ,
InductionVariablesInNestedLoopsWithFolding   
)

Definition at line 1228 of file ScalarEvolutionTests.cpp.

◆ TEST() [17/34]

TEST ( ScalarEvolutionTests  ,
InductionVariablesInSisterLoops   
)

Definition at line 1383 of file ScalarEvolutionTests.cpp.

◆ TEST() [18/34]

TEST ( ScalarEvolutionTests  ,
InductionVariablesWithNonConstantInitialValues   
)

Definition at line 706 of file ScalarEvolutionTests.cpp.

◆ TEST() [19/34]

TEST ( ScalarEvolutionTests  ,
InductionVariablesWithNonConstantInitialValuesAndMultiplication   
)

Definition at line 820 of file ScalarEvolutionTests.cpp.

◆ TEST() [20/34]

TEST ( ScalarEvolutionTests  ,
InductionVariableWithMultiplication   
)

Definition at line 308 of file ScalarEvolutionTests.cpp.

◆ TEST() [21/34]

TEST ( ScalarEvolutionTests  ,
InductionVariableWithSubtraction   
)

Definition at line 606 of file ScalarEvolutionTests.cpp.

◆ TEST() [22/34]

TEST ( ScalarEvolutionTests  ,
InvalidInductionVariableWithMultiplication   
)

Definition at line 369 of file ScalarEvolutionTests.cpp.

◆ TEST() [23/34]

TEST ( ScalarEvolutionTests  ,
InvalidPolynomialInductionVariableWithMultiplication   
)

Definition at line 548 of file ScalarEvolutionTests.cpp.

◆ TEST() [24/34]

TEST ( ScalarEvolutionTests  ,
MultiLayeredMutuallyDependentInductionVariables   
)

Definition at line 1086 of file ScalarEvolutionTests.cpp.

◆ TEST() [25/34]

TEST ( ScalarEvolutionTests  ,
MultiplicationOfTwoAffineChrecs   
)

Definition at line 411 of file ScalarEvolutionTests.cpp.

◆ TEST() [26/34]

TEST ( ScalarEvolutionTests  ,
MultiplicationOfTwoQuadraticChrecs   
)

Definition at line 472 of file ScalarEvolutionTests.cpp.

◆ TEST() [27/34]

TEST ( ScalarEvolutionTests  ,
MutuallyDependentInductionVariables   
)

Definition at line 1035 of file ScalarEvolutionTests.cpp.

◆ TEST() [28/34]

TEST ( ScalarEvolutionTests  ,
NonEvolvingVariable   
)

Definition at line 30 of file ScalarEvolutionTests.cpp.

◆ TEST() [29/34]

TEST ( ScalarEvolutionTests  ,
PolynomialInductionVariable   
)

Definition at line 178 of file ScalarEvolutionTests.cpp.

◆ TEST() [30/34]

TEST ( ScalarEvolutionTests  ,
PolynomialInductionVariableWithSubtraction   
)

Definition at line 649 of file ScalarEvolutionTests.cpp.

◆ TEST() [31/34]

TEST ( ScalarEvolutionTests  ,
RecursiveInductionVariable   
)

Definition at line 118 of file ScalarEvolutionTests.cpp.

◆ TEST() [32/34]

TEST ( ScalarEvolutionTests  ,
SelfRecursiveInductionVariable   
)

Definition at line 942 of file ScalarEvolutionTests.cpp.

◆ TEST() [33/34]

TEST ( ScalarEvolutionTests  ,
TestTripCountCouldNotCompute   
)

Definition at line 2079 of file ScalarEvolutionTests.cpp.

◆ TEST() [34/34]

TEST ( ScalarEvolutionTests  ,
ThirdDegreePolynomialInductionVariable   
)

Definition at line 235 of file ScalarEvolutionTests.cpp.