LLVM API Documentation

Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Expressions.cpp File Reference

#include "llvm/Analysis/Expressions.h"
#include "llvm/Constants.h"
#include "llvm/Function.h"
#include "llvm/Type.h"
#include <iostream>

Include dependency graph for Expressions.cpp:

Go to the source code of this file.

Functions

static ConstantIntgetUnsignedConstant (uint64_t V, const Type *Ty)
static const ConstantIntAdd (const ConstantInt *Arg1, const ConstantInt *Arg2, bool DefOne)
static const ConstantIntoperator+ (const DefZero &L, const DefZero &R)
static const ConstantIntoperator+ (const DefOne &L, const DefOne &R)
static const ConstantIntMul (const ConstantInt *Arg1, const ConstantInt *Arg2, bool DefOne)
const ConstantIntoperator * (const DefZero &L, const DefZero &R)
const ConstantIntoperator * (const DefOne &L, const DefZero &R)
const ConstantIntoperator * (const DefZero &L, const DefOne &R)
static ExprType handleAddition (ExprType Left, ExprType Right, Value *V)
static ExprType negate (const ExprType &E, Value *V)
ExprType llvm::ClassifyExpr (Value *Expr)


Function Documentation

static const ConstantInt* Add const ConstantInt Arg1,
const ConstantInt Arg2,
bool  DefOne
[static]
 

Definition at line 114 of file Expressions.cpp.

References llvm::ConstantInt::equalsInt(), llvm::ConstantExpr::get(), and llvm::Value::getType().

Referenced by llvm::ClassifyExpr(), llvm::ConstantFoldBinaryInstruction(), llvm::ConstantFoldGetElementPtr(), llvm::ConvertExpressionToType(), ConvertMallocToType(), ConvertOperandToType(), DominatesMergePoint(), llvm::AsmPrinter::emitConstantValueOnly(), llvm::ExpressionConvertibleToType(), llvm::SCEVMulExpr::get(), llvm::SCEVAddExpr::get(), llvm::ConstantExpr::get(), llvm::ConstantExpr::getAdd(), llvm::Loop::getCanonicalInductionVariable(), llvm::ExecutionEngine::getConstantValue(), llvm::Instruction::getOpcodeName(), GetSelectFoldableConstant(), GetSelectFoldableOperands(), HandleCastToPointer(), llvm::IncrementCounterInBlock(), llvm::BinaryOperator::init(), llvm::Instruction::isAssociative(), llvm::Instruction::isCommutative(), NegateValue(), OperandConvertibleToType(), operator+(), and llvm::Interpreter::visitBinaryOperator().

static ConstantInt* getUnsignedConstant uint64_t  V,
const Type Ty
[static]
 

Definition at line 86 of file Expressions.cpp.

References llvm::ConstantUInt::get(), llvm::ConstantSInt::get(), llvm::ConstantUInt::isValueValidForType(), llvm::ConstantSInt::isValueValidForType(), and llvm::Type::ULongTy.

Referenced by llvm::ClassifyExpr(), negate(), operator *(), and operator+().

static ExprType handleAddition ExprType  Left,
ExprType  Right,
Value V
[static]
 

Definition at line 202 of file Expressions.cpp.

References llvm::ExprType::Constant, llvm::ExprType::ExprTy, llvm::Value::getType(), llvm::ExprType::Linear, llvm::ExprType::Offset, llvm::ExprType::Scale, llvm::ExprType::ScaledLinear, and llvm::ExprType::Var.

Referenced by llvm::ClassifyExpr().

static const ConstantInt* Mul const ConstantInt Arg1,
const ConstantInt Arg2,
bool  DefOne
[inline, static]
 

Definition at line 163 of file Expressions.cpp.

References llvm::ConstantInt::equalsInt(), llvm::ConstantExpr::get(), and llvm::Value::getType().

Referenced by llvm::ClassifyExpr(), llvm::ConstantFoldBinaryInstruction(), ConvertMallocToType(), ConvertOperandToType(), dyn_castFoldableMul(), llvm::SCEVMulExpr::get(), llvm::SCEVAddExpr::get(), llvm::ConstantExpr::get(), llvm::ConstantExpr::getMul(), llvm::Instruction::getOpcodeName(), GetSelectFoldableConstant(), GetSelectFoldableOperands(), llvm::BinaryOperator::init(), llvm::Instruction::isAssociative(), llvm::Instruction::isCommutative(), OperandConvertibleToType(), operator *(), and llvm::Interpreter::visitBinaryOperator().

static ExprType negate const ExprType E,
Value V
[inline, static]
 

Definition at line 227 of file Expressions.cpp.

References llvm::ConstantExpr::get(), llvm::Value::getType(), getUnsignedConstant(), llvm::ExprType::Offset, llvm::ExprType::Scale, and llvm::ExprType::Var.

Referenced by llvm::ClassifyExpr().

const ConstantInt* @1::operator * const DefZero &  L,
const DefOne &  R
[inline, static]
 

Definition at line 193 of file Expressions.cpp.

References Mul().

const ConstantInt* @1::operator * const DefOne &  L,
const DefZero &  R
[inline, static]
 

Definition at line 188 of file Expressions.cpp.

References getUnsignedConstant(), and Mul().

const ConstantInt* @1::operator * const DefZero &  L,
const DefZero &  R
[inline, static]
 

Definition at line 184 of file Expressions.cpp.

References Mul().

Referenced by llvm::UseListConstIteratorWrapper::operator *(), and llvm::UseListIteratorWrapper::operator *().

static const ConstantInt* operator+ const DefOne &  L,
const DefOne &  R
[inline, static]
 

Definition at line 138 of file Expressions.cpp.

References Add(), and getUnsignedConstant().

static const ConstantInt* operator+ const DefZero &  L,
const DefZero &  R
[inline, static]
 

Definition at line 132 of file Expressions.cpp.

References Add().