#include <LoadChainSeparation.hpp>
Separates chains of memory region references from each other by rendering them independent in the RVSDG through the insertion of a MemoryStateJoinOperation node.
The following example illustrates the transformation:
v1 s2 = LoadNonVolatileOperation a1 s1 v2 s3 = LoadNonVolatileOperation a2 s2
is transformed to:
v1 s2 = LoadNonVolatileOperation a1 s1 v2 s3 = LoadNonVolatileOperation a2 s1 s4 = MemoryStateJoinOperation s2 s3
Definition at line 36 of file LoadChainSeparation.hpp.
◆ ~LoadChainSeparation()
| jlm::llvm::LoadChainSeparation::~LoadChainSeparation |
( |
| ) |
|
|
overridedefaultnoexcept |
◆ LoadChainSeparation() [1/2]
| jlm::llvm::LoadChainSeparation::LoadChainSeparation |
( |
| ) |
|
◆ LoadChainSeparation() [2/2]
◆ extractReferenceSubchains()
Extracts all reference subchains of mod/ref chain modRefChain. A valid reference subchain is defined as followed:
- Must only contain mod/ref chain links of type ModRefChainLink::Type::Reference
- Must have at least two links
- Parameters
-
| modRefChain | The mod/ref chain from which to extract the reference subchains |
- Returns
- A vector of reference subchains.
Definition at line 250 of file LoadChainSeparation.cpp.
◆ mapMemoryStateOutputToInput()
Maps a memory state output of a node to the respective memory state input.
- Parameters
-
| output | The output that is mapped. |
- Returns
- A memory state input, if the output can be mapped.
Definition at line 233 of file LoadChainSeparation.cpp.
◆ operator=()
◆ Run()
Perform RVSDG transformation.
- Note
- This method is expected to be called multiple times. An implementation is required to reset the objects' internal state to ensure correct behavior after every invocation.
- Parameters
-
| module | RVSDG module the transformation is performed on. |
| statisticsCollector | Statistics collector for collecting transformation statistics. |
Implements jlm::rvsdg::Transformation.
Definition at line 69 of file LoadChainSeparation.cpp.
◆ separateRefenceChainsInGamma()
| void jlm::llvm::LoadChainSeparation::separateRefenceChainsInGamma |
( |
rvsdg::GammaNode & |
gammaNode | ) |
|
|
private |
◆ separateRefenceChainsInTheta()
◆ separateReferenceChains()
Separates the reference links of the mod/ref chain starting at memory state output startOutput.
- Parameters
-
| startOutput | The starting output of the mod/ref chain. Must be of type MemoryStateType. |
| visitedOutputs | The set of outputs that were already visited throughout the separation in the region. |
- Returns
- True, if the separated mod/ref chains had a modifier link, otherwise False.
Definition at line 190 of file LoadChainSeparation.cpp.
◆ separateReferenceChainsInLambda()
| void jlm::llvm::LoadChainSeparation::separateReferenceChainsInLambda |
( |
rvsdg::LambdaNode & |
lambdaNode | ) |
|
|
private |
◆ separateReferenceChainsInRegion()
| void jlm::llvm::LoadChainSeparation::separateReferenceChainsInRegion |
( |
rvsdg::Region & |
region | ) |
|
|
private |
◆ traceModRefChains()
Recursively traces from output startOutput upwards to find all mod/ref chains within a single region.
- Parameters
-
| startOutput | The starting output for the tracing. Must be of type MemoryStateType. |
| visitedOutputs | The set of outputs that were already visited throughout the recursive tracing. |
| summary | The tracing summary. |
Definition at line 284 of file LoadChainSeparation.cpp.
◆ Context_
| std::unique_ptr<Context> jlm::llvm::LoadChainSeparation::Context_ {} |
|
private |
The documentation for this class was generated from the following files: