Jlm
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
jlm::llvm::SExtOperation Class Referencefinal

#include <ConversionOperations.hpp>

Inheritance diagram for jlm::llvm::SExtOperation:
Inheritance graph
[legend]
Collaboration diagram for jlm::llvm::SExtOperation:
Collaboration graph
[legend]

Public Member Functions

 ~SExtOperation () noexcept override
 
 SExtOperation (std::shared_ptr< const rvsdg::Type > srctype, std::shared_ptr< const rvsdg::Type > dsttype)
 
bool operator== (const Operation &other) const noexcept override
 
std::string debug_string () const override
 
std::unique_ptr< Operation > copy () const override
 
size_t nsrcbits () const noexcept
 
size_t ndstbits () const noexcept
 
- Public Member Functions inherited from jlm::rvsdg::UnaryOperation
 ~UnaryOperation () noexcept override
 
 UnaryOperation (std::shared_ptr< const Type > operand, std::shared_ptr< const Type > result)
 
- Public Member Functions inherited from jlm::rvsdg::SimpleOperation
 ~SimpleOperation () noexcept override
 
 SimpleOperation (std::vector< std::shared_ptr< const jlm::rvsdg::Type > > operands, std::vector< std::shared_ptr< const jlm::rvsdg::Type > > results)
 
size_t narguments () const noexcept
 
const std::shared_ptr< const rvsdg::Type > & argument (size_t index) const noexcept
 
size_t nresults () const noexcept
 
const std::shared_ptr< const rvsdg::Type > & result (size_t index) const noexcept
 
- Public Member Functions inherited from jlm::rvsdg::Operation
virtual ~Operation () noexcept
 
virtual bool operator== (const Operation &other) const noexcept=0
 
bool operator!= (const Operation &other) const noexcept
 

Static Public Member Functions

static std::unique_ptr< llvm::ThreeAddressCodecreateTac (const Variable *operand, const std::shared_ptr< const rvsdg::Type > &type)
 
static rvsdg::SimpleNodecreateNode (const size_t numResultBits, rvsdg::Output &operand)
 
static rvsdg::Outputcreate (size_t ndstbits, rvsdg::Output &operand)
 
static std::optional< std::vector< rvsdg::Output * > > foldConstant (const SExtOperation &operation, const std::vector< rvsdg::Output * > &operands)
 

Detailed Description

Definition at line 82 of file ConversionOperations.hpp.

Constructor & Destructor Documentation

◆ ~SExtOperation()

jlm::llvm::SExtOperation::~SExtOperation ( )
overridedefaultnoexcept

◆ SExtOperation()

jlm::llvm::SExtOperation::SExtOperation ( std::shared_ptr< const rvsdg::Type srctype,
std::shared_ptr< const rvsdg::Type dsttype 
)
inline

Definition at line 87 of file ConversionOperations.hpp.

Member Function Documentation

◆ copy()

std::unique_ptr< rvsdg::Operation > jlm::llvm::SExtOperation::copy ( ) const
overridevirtual

Implements jlm::rvsdg::Operation.

Definition at line 56 of file ConversionOperations.cpp.

◆ create()

static rvsdg::Output & jlm::llvm::SExtOperation::create ( size_t  ndstbits,
rvsdg::Output operand 
)
inlinestatic

Definition at line 142 of file ConversionOperations.hpp.

◆ createNode()

static rvsdg::SimpleNode & jlm::llvm::SExtOperation::createNode ( const size_t  numResultBits,
rvsdg::Output operand 
)
inlinestatic

Definition at line 133 of file ConversionOperations.hpp.

◆ createTac()

static std::unique_ptr< llvm::ThreeAddressCode > jlm::llvm::SExtOperation::createTac ( const Variable operand,
const std::shared_ptr< const rvsdg::Type > &  type 
)
inlinestatic

Definition at line 126 of file ConversionOperations.hpp.

◆ debug_string()

std::string jlm::llvm::SExtOperation::debug_string ( ) const
overridevirtual

Implements jlm::rvsdg::Operation.

Definition at line 50 of file ConversionOperations.cpp.

◆ foldConstant()

std::optional< std::vector< rvsdg::Output * > > jlm::llvm::SExtOperation::foldConstant ( const SExtOperation operation,
const std::vector< rvsdg::Output * > &  operands 
)
static

Performs constant folding by statically evaluating the constant operand and replacing the operations result with the resulting constant.

Parameters
operationThe SExtOperation on which the transformation is performed.
operandsThe operands of the SExtOperation node.
Returns
If the normalization could be applied, then the result of the SExtOperation after the transformation. Otherwise, std::nullopt.

Definition at line 62 of file ConversionOperations.cpp.

◆ ndstbits()

size_t jlm::llvm::SExtOperation::ndstbits ( ) const
inlinenoexcept

Definition at line 120 of file ConversionOperations.hpp.

◆ nsrcbits()

size_t jlm::llvm::SExtOperation::nsrcbits ( ) const
inlinenoexcept

Definition at line 114 of file ConversionOperations.hpp.

◆ operator==()

bool jlm::llvm::SExtOperation::operator== ( const Operation &  other) const
overridenoexcept

Definition at line 43 of file ConversionOperations.cpp.


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