Jlm
Loading...
Searching...
No Matches
Functions
RegionPredicateTraceTests.cpp File Reference
#include <gtest/gtest.h>
#include <jlm/rvsdg/bitstring/arithmetic.hpp>
#include <jlm/rvsdg/bitstring/constant.hpp>
#include <jlm/rvsdg/bitstring/type.hpp>
#include <jlm/rvsdg/control.hpp>
#include <jlm/rvsdg/gamma.hpp>
#include <jlm/rvsdg/graph.hpp>
#include <jlm/rvsdg/RegionPredicateTrace.hpp>
#include <jlm/rvsdg/simple-node.hpp>
#include <jlm/rvsdg/TestNodes.hpp>
#include <jlm/rvsdg/TestOperations.hpp>
#include <jlm/rvsdg/TestType.hpp>
#include <jlm/rvsdg/theta.hpp>
Include dependency graph for RegionPredicateTraceTests.cpp:

Go to the source code of this file.

Functions

 TEST (RegionPredicateTraceTests, TestTracing)
 
 TEST (RegionPredicateTraceTests, TraceOutOfTheta)
 
 TEST (RegionPredicateTraceTests, TraceIntoGamma)
 

Function Documentation

◆ TEST() [1/3]

TEST ( RegionPredicateTraceTests  ,
TestTracing   
)

Definition at line 21 of file RegionPredicateTraceTests.cpp.

◆ TEST() [2/3]

TEST ( RegionPredicateTraceTests  ,
TraceIntoGamma   
)

Creates an RVSDG graph that looks like:

CTRL(0) v +-gamma0---------------—+------—+ | | | | CTRL(0) CTRL(1) | | | v v v | | | +-gamma1–+------—+ | | | | \ | / | | | | | \ | / | | | | | v | v | | | | +------—+------—+ | CTRL(1) | | v | v | +----------------------—+------—+ v +-gamma2—+------—+ | | | +-------—+------—+

Checks that the regions of gamma2 can only be reached from regions that provide the correct predicate value

Definition at line 194 of file RegionPredicateTraceTests.cpp.

◆ TEST() [3/3]

TEST ( RegionPredicateTraceTests  ,
TraceOutOfTheta   
)

Creates an RVSDG graph that looks like:

+-theta0---------------—x----------------------—+ | | | +-theta1—x--—+ +-theta3----------—x----—+ | | | | | v | | | | CTRL(0) INT(3) | | +-theta4—x--—+ | | | | v v | | | | | | | +-------—x--—+ | | CTRL(0) INT(7) | | | | v | | v v | | | | +-theta2—x--—+ | CTRL(0) +-------—x--—+ | | | | CTRL(0) v | | v v | | | +-------—x--—+ +-----------------—x----—+ | | | | | | -------—\ /----------—/ | | v v | | CTRL(0) ADD | | v v | +----------------------—x----------------------—+ v export("x")

and checks that all regions are considered reachable from all regions above it, both parent, child and sibling regions.

Definition at line 86 of file RegionPredicateTraceTests.cpp.