LLVM API Documentation
#include "llvm/Transforms/Utils/BypassSlowDivision.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/Instructions.h"
Go to the source code of this file.
Classes | |
struct | llvm::DenseMapInfo< DivOpInfo > |
Namespaces | |
namespace | llvm |
List of target independent CodeGen pass IDs. | |
Defines | |
#define | DEBUG_TYPE "bypass-slow-division" |
Typedefs | |
typedef DenseMap< DivOpInfo, DivPhiNodes > | llvm::DivCacheTy |
Functions | |
static bool | insertFastDiv (Function &F, Function::iterator &I, BasicBlock::iterator &J, IntegerType *BypassType, bool UseDivOp, bool UseSignedOp, DivCacheTy &PerBBDivCache) |
static bool | reuseOrInsertFastDiv (Function &F, Function::iterator &I, BasicBlock::iterator &J, IntegerType *BypassType, bool UseDivOp, bool UseSignedOp, DivCacheTy &PerBBDivCache) |
#define DEBUG_TYPE "bypass-slow-division" |
Definition at line 26 of file BypassSlowDivision.cpp.
static bool insertFastDiv | ( | Function & | F, |
Function::iterator & | I, | ||
BasicBlock::iterator & | J, | ||
IntegerType * | BypassType, | ||
bool | UseDivOp, | ||
bool | UseSignedOp, | ||
DivCacheTy & | PerBBDivCache | ||
) | [static] |
Definition at line 77 of file BypassSlowDivision.cpp.
References llvm::PHINode::addIncoming(), llvm::iplist< NodeTy, Traits >::back(), llvm::BasicBlock::begin(), llvm::BasicBlock::Create(), llvm::IRBuilder< preserveNames, T, Inserter >::CreateSDiv(), llvm::IRBuilder< preserveNames, T, Inserter >::CreateUDiv(), llvm::BasicBlock::end(), llvm::Instruction::eraseFromParent(), llvm::IntegerType::getBitMask(), llvm::Function::getContext(), llvm::BasicBlock::getInstList(), llvm::User::getOperand(), llvm::BasicBlock::getParent(), llvm::ConstantInt::getSigned(), llvm::Value::getType(), I, llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::insert(), llvm::BasicBlock::moveBefore(), llvm::Value::replaceAllUsesWith(), and llvm::Trunc.
Referenced by reuseOrInsertFastDiv().
static bool reuseOrInsertFastDiv | ( | Function & | F, |
Function::iterator & | I, | ||
BasicBlock::iterator & | J, | ||
IntegerType * | BypassType, | ||
bool | UseDivOp, | ||
bool | UseSignedOp, | ||
DivCacheTy & | PerBBDivCache | ||
) | [static] |
Definition at line 185 of file BypassSlowDivision.cpp.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::Instruction::eraseFromParent(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), llvm::User::getOperand(), and insertFastDiv().
Referenced by llvm::bypassSlowDivision().