LLVM  6.0.0svn
Public Types | Public Member Functions | Friends | List of all members
llvm::FastMathFlags Class Reference

Convenience struct for specifying and reasoning about fast-math flags. More...

#include "llvm/IR/Operator.h"

Public Types

enum  {
  AllowReassoc = (1 << 0), NoNaNs = (1 << 1), NoInfs = (1 << 2), NoSignedZeros = (1 << 3),
  AllowReciprocal = (1 << 4), AllowContract = (1 << 5), ApproxFunc = (1 << 6)
}
 

Public Member Functions

 FastMathFlags ()=default
 
bool any () const
 
bool none () const
 
bool all () const
 
void clear ()
 
void set ()
 
bool allowReassoc () const
 Flag queries. More...
 
bool noNaNs () const
 
bool noInfs () const
 
bool noSignedZeros () const
 
bool allowReciprocal () const
 
bool allowContract () const
 
bool approxFunc () const
 
bool isFast () const
 'Fast' means all bits are set. More...
 
void setAllowReassoc ()
 Flag setters. More...
 
void setNoNaNs ()
 
void setNoInfs ()
 
void setNoSignedZeros ()
 
void setAllowReciprocal ()
 
void setAllowContract (bool B)
 
void setApproxFunc ()
 
void setFast ()
 
void operator &= (const FastMathFlags &OtherFlags)
 

Friends

class FPMathOperator
 

Detailed Description

Convenience struct for specifying and reasoning about fast-math flags.

Definition at line 160 of file Operator.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
AllowReassoc 
NoNaNs 
NoInfs 
NoSignedZeros 
AllowReciprocal 
AllowContract 
ApproxFunc 

Definition at line 179 of file Operator.h.

Constructor & Destructor Documentation

◆ FastMathFlags()

llvm::FastMathFlags::FastMathFlags ( )
default

Member Function Documentation

◆ all()

bool llvm::FastMathFlags::all ( ) const
inline

Definition at line 193 of file Operator.h.

◆ allowContract()

bool llvm::FastMathFlags::allowContract ( ) const
inline

Definition at line 204 of file Operator.h.

Referenced by isVectorReductionOp().

◆ allowReassoc()

bool llvm::FastMathFlags::allowReassoc ( ) const
inline

Flag queries.

Definition at line 199 of file Operator.h.

◆ allowReciprocal()

bool llvm::FastMathFlags::allowReciprocal ( ) const
inline

Definition at line 203 of file Operator.h.

Referenced by isVectorReductionOp(), and shouldKeepFDivF32().

◆ any()

bool llvm::FastMathFlags::any ( ) const
inline

Definition at line 191 of file Operator.h.

Referenced by FunctionNumber(), and readWideAPInt().

◆ approxFunc()

bool llvm::FastMathFlags::approxFunc ( ) const
inline

Definition at line 205 of file Operator.h.

◆ clear()

void llvm::FastMathFlags::clear ( )
inline

Definition at line 195 of file Operator.h.

Referenced by llvm::IRBuilderBase::clearFastMathFlags().

◆ isFast()

bool llvm::FastMathFlags::isFast ( ) const
inline

'Fast' means all bits are set.

Definition at line 207 of file Operator.h.

Referenced by addStackMapLiveVars(), isVectorReductionOp(), and shouldKeepFDivF32().

◆ noInfs()

bool llvm::FastMathFlags::noInfs ( ) const
inline

Definition at line 201 of file Operator.h.

Referenced by isVectorReductionOp(), and SimplifyFAddInst().

◆ noNaNs()

bool llvm::FastMathFlags::noNaNs ( ) const
inline

◆ none()

bool llvm::FastMathFlags::none ( ) const
inline

Definition at line 192 of file Operator.h.

◆ noSignedZeros()

bool llvm::FastMathFlags::noSignedZeros ( ) const
inline

◆ operator &=()

void llvm::FastMathFlags::operator&= ( const FastMathFlags OtherFlags)
inline

Definition at line 222 of file Operator.h.

◆ set()

void llvm::FastMathFlags::set ( )
inline

Definition at line 196 of file Operator.h.

◆ setAllowContract()

void llvm::FastMathFlags::setAllowContract ( bool  B)
inline

Definition at line 216 of file Operator.h.

Referenced by llvm::LLParser::getContext(), and getDecodedFastMathFlags().

◆ setAllowReassoc()

void llvm::FastMathFlags::setAllowReassoc ( )
inline

Flag setters.

Definition at line 210 of file Operator.h.

Referenced by llvm::LLParser::getContext(), and getDecodedFastMathFlags().

◆ setAllowReciprocal()

void llvm::FastMathFlags::setAllowReciprocal ( )
inline

Definition at line 214 of file Operator.h.

Referenced by llvm::LLParser::getContext(), and getDecodedFastMathFlags().

◆ setApproxFunc()

void llvm::FastMathFlags::setApproxFunc ( )
inline

Definition at line 219 of file Operator.h.

Referenced by llvm::LLParser::getContext(), and getDecodedFastMathFlags().

◆ setFast()

void llvm::FastMathFlags::setFast ( )
inline

◆ setNoInfs()

void llvm::FastMathFlags::setNoInfs ( )
inline

Definition at line 212 of file Operator.h.

Referenced by llvm::LLParser::getContext(), and getDecodedFastMathFlags().

◆ setNoNaNs()

void llvm::FastMathFlags::setNoNaNs ( )
inline

◆ setNoSignedZeros()

void llvm::FastMathFlags::setNoSignedZeros ( )
inline

Definition at line 213 of file Operator.h.

Referenced by llvm::LLParser::getContext(), getDecodedFastMathFlags(), and getPow().

Friends And Related Function Documentation

◆ FPMathOperator

friend class FPMathOperator
friend

Definition at line 162 of file Operator.h.


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