Jlm
Loading...
Searching...
No Matches
Public Attributes | Private Member Functions | List of all members
jlm::mlir::FloatBinaryTest Class Referencefinal

FloatBinaryTest class. More...

#include <TestRvsdgs.hpp>

Inheritance diagram for jlm::mlir::FloatBinaryTest:
Inheritance graph
[legend]
Collaboration diagram for jlm::mlir::FloatBinaryTest:
Collaboration graph
[legend]

Public Attributes

jlm::rvsdg::LambdaNode * lambda
 

Private Member Functions

std::unique_ptr< jlm::llvm::LlvmRvsdgModule > SetupRvsdg () override
 Create RVSDG for this test.
 

Additional Inherited Members

- Public Member Functions inherited from jlm::llvm::RvsdgTest
virtual ~RvsdgTest ()=default
 
jlm::llvm::LlvmRvsdgModule & module ()
 
const rvsdg::Graph & graph ()
 
void InitializeTest ()
 

Detailed Description

FloatBinaryTest class.

This class sets up an RVSDG representing the following function:

void f(double a, double b, double * r1, double * r2, double * r3)
{
double s = a + b;
double d = a - b;
double m = a * b;
double q = s / d;
double r = m % s;
*r1 = s + d;
*r2 = m + q;
*r3 = *r2 + r;
}

All five jlm::llvm::fpop values go through the same converter branch, so they are exercised together. The lambda returns three of the values so that every binary operation is directly reachable from a lambda result.

See also
FloatConversionTest

Definition at line 203 of file TestRvsdgs.hpp.

Member Function Documentation

◆ SetupRvsdg()

std::unique_ptr< jlm::llvm::LlvmRvsdgModule > jlm::mlir::FloatBinaryTest::SetupRvsdg ( )
overrideprivatevirtual

Create RVSDG for this test.

Implements jlm::llvm::RvsdgTest.

Definition at line 243 of file TestRvsdgs.cpp.

Member Data Documentation

◆ lambda

jlm::rvsdg::LambdaNode* jlm::mlir::FloatBinaryTest::lambda

Definition at line 210 of file TestRvsdgs.hpp.


The documentation for this class was generated from the following files: