|
Enzyme main
|
#include "InstructionBatcher.h"


Public Member Functions | |
| InstructionBatcher (llvm::Function *oldFunc, llvm::Function *newFunc, unsigned width, llvm::ValueMap< const llvm::Value *, std::vector< llvm::Value * > > &vectorizedValues, llvm::ValueMap< const llvm::Value *, llvm::WeakTrackingVH > &originalToNewFn, llvm::SmallPtrSetImpl< llvm::Value * > &toVectorize, EnzymeLogic &Logic) | |
| void | visitInstruction (llvm::Instruction &inst) |
| void | visitPHINode (llvm::PHINode &phi) |
| void | visitSwitchInst (llvm::SwitchInst &inst) |
| void | visitBranchInst (llvm::BranchInst &branch) |
| void | visitReturnInst (llvm::ReturnInst &ret) |
| void | visitCallInst (llvm::CallInst &call) |
Public Attributes | |
| bool | hasError |
Definition at line 50 of file InstructionBatcher.h.
| InstructionBatcher::InstructionBatcher | ( | llvm::Function * | oldFunc, |
| llvm::Function * | newFunc, | ||
| unsigned | width, | ||
| llvm::ValueMap< const llvm::Value *, std::vector< llvm::Value * > > & | vectorizedValues, | ||
| llvm::ValueMap< const llvm::Value *, llvm::WeakTrackingVH > & | originalToNewFn, | ||
| llvm::SmallPtrSetImpl< llvm::Value * > & | toVectorize, | ||
| EnzymeLogic & | Logic ) |
Definition at line 49 of file InstructionBatcher.cpp.
| void InstructionBatcher::visitBranchInst | ( | llvm::BranchInst & | branch | ) |
Definition at line 181 of file InstructionBatcher.cpp.
References EmitFailure(), and hasError.
| void InstructionBatcher::visitCallInst | ( | llvm::CallInst & | call | ) |
Definition at line 217 of file InstructionBatcher.cpp.
References EnzymeLogic::CreateBatch(), getFunctionFromCall(), GradientUtils::getShadowType(), SCALAR, VECTOR, and visitInstruction().
| void InstructionBatcher::visitInstruction | ( | llvm::Instruction & | inst | ) |
Definition at line 86 of file InstructionBatcher.cpp.
References EmitFailure(), and hasError.
Referenced by visitCallInst().
| void InstructionBatcher::visitPHINode | ( | llvm::PHINode & | phi | ) |
Definition at line 147 of file InstructionBatcher.cpp.
| void InstructionBatcher::visitReturnInst | ( | llvm::ReturnInst & | ret | ) |
Definition at line 189 of file InstructionBatcher.cpp.
| void InstructionBatcher::visitSwitchInst | ( | llvm::SwitchInst & | inst | ) |
Definition at line 173 of file InstructionBatcher.cpp.
References EmitFailure(), and hasError.
| bool InstructionBatcher::hasError |
Definition at line 52 of file InstructionBatcher.h.
Referenced by visitBranchInst(), visitInstruction(), and visitSwitchInst().