LLVM 20.0.0git
|
This pass does misc. More...
#include "AMDGPU.h"
#include "AMDGPUTargetMachine.h"
#include "SIModeRegisterDefaults.h"
#include "llvm/Analysis/AssumptionCache.h"
#include "llvm/Analysis/ConstantFolding.h"
#include "llvm/Analysis/TargetLibraryInfo.h"
#include "llvm/Analysis/UniformityAnalysis.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/CodeGen/TargetPassConfig.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/InstVisitor.h"
#include "llvm/IR/IntrinsicsAMDGPU.h"
#include "llvm/IR/PatternMatch.h"
#include "llvm/InitializePasses.h"
#include "llvm/Pass.h"
#include "llvm/Support/KnownBits.h"
#include "llvm/Transforms/Utils/IntegerDivision.h"
#include "llvm/Transforms/Utils/Local.h"
Go to the source code of this file.
Classes | |
class | VectorSlice |
Helper class for "break large PHIs" (visitPHINode). More... | |
Macros | |
#define | DEBUG_TYPE "amdgpu-codegenprepare" |
Variables | |
DEBUG_TYPE | |
AMDGPU IR | optimizations |
AMDGPU IR | false |
This pass does misc.
AMDGPU optimizations on IR before instruction selection.
Definition in file AMDGPUCodeGenPrepare.cpp.
#define DEBUG_TYPE "amdgpu-codegenprepare" |
Definition at line 35 of file AMDGPUCodeGenPrepare.cpp.
Definition at line 1750 of file AMDGPUCodeGenPrepare.cpp.
Referenced by isInterestingPHIIncomingValue().
|
static |
Definition at line 1813 of file AMDGPUCodeGenPrepare.cpp.
References collectPHINodes(), I, and llvm::SmallPtrSetImpl< PtrType >::insert().
Referenced by collectPHINodes().
Emit an expansion of 1.0 / sqrt(Src) good for 1ulp that supports denormals.
Definition at line 870 of file AMDGPUCodeGenPrepare.cpp.
References llvm::IRBuilderBase::CreateFCmpOLT(), llvm::IRBuilderBase::CreateFMul(), llvm::IRBuilderBase::CreateSelect(), llvm::IRBuilderBase::CreateUnaryIntrinsic(), llvm::Type::getFltSemantics(), and llvm::APFloat::getSmallestNormalized().
|
static |
Definition at line 609 of file AMDGPUCodeGenPrepare.cpp.
References llvm::IRBuilderBase::CreateExtractElement(), I, and llvm::SmallVectorTemplateBase< T, bool >::push_back().
|
static |
Definition at line 701 of file AMDGPUCodeGenPrepare.cpp.
References llvm::User::getOperand().
|
static |
Definition at line 1174 of file AMDGPUCodeGenPrepare.cpp.
References llvm::IRBuilderBase::CreateLShr(), llvm::IRBuilderBase::CreateMul(), llvm::IRBuilderBase::CreateTrunc(), llvm::IRBuilderBase::CreateZExt(), llvm::IRBuilderBase::getInt32Ty(), llvm::IRBuilderBase::getInt64(), llvm::IRBuilderBase::getInt64Ty(), Hi, LHS, Lo, and RHS.
Referenced by getMulHu().
Definition at line 1188 of file AMDGPUCodeGenPrepare.cpp.
References getMul64(), LHS, and RHS.
|
static |
Definition at line 1381 of file AMDGPUCodeGenPrepare.cpp.
References llvm::computeKnownBits(), llvm::IRBuilderBase::CreateAShr(), DL, llvm::Constant::getAllOnesValue(), llvm::IRBuilderBase::getInt32(), llvm::Constant::getNullValue(), llvm::KnownBits::isNegative(), and llvm::KnownBits::isNonNegative().
INITIALIZE_PASS_BEGIN | ( | AMDGPUCodeGenPrepare | , |
DEBUG_TYPE | , | ||
"AMDGPU IR optimizations" | , | ||
false | , | ||
false | |||
) |
|
static |
Definition at line 621 of file AMDGPUCodeGenPrepare.cpp.
References assert(), llvm::IRBuilderBase::CreateInsertElement(), llvm::PoisonValue::get(), I, llvm::Type::isVectorTy(), and llvm::SmallVectorBase< Size_T >::size().
Definition at line 1758 of file AMDGPUCodeGenPrepare.cpp.
References llvm::BitVector::all(), areInSameBB(), Idx, and llvm::BitVector::set().
Definition at line 2217 of file AMDGPUCodeGenPrepare.cpp.
References llvm::CallingConv::C, llvm::PatternMatch::m_APFloat(), and llvm::PatternMatch::match().
|
static |
V | Value to check |
DL | DataLayout |
TM | TargetMachine (TODO: remove once DL contains nullptr values) |
AS | Target Address Space |
V
cannot be the null value of AS
, false otherwise. Definition at line 2044 of file AMDGPUCodeGenPrepare.cpp.
References assert(), llvm::computeKnownBits(), and DL.
|
static |
Definition at line 438 of file AMDGPUCodeGenPrepare.cpp.
References I.
|
static |
Definition at line 452 of file AMDGPUCodeGenPrepare.cpp.
References I.
DEBUG_TYPE |
Definition at line 2322 of file AMDGPUCodeGenPrepare.cpp.
AMDGPU IR false |
Definition at line 2323 of file AMDGPUCodeGenPrepare.cpp.
AMDGPU IR optimizations |
Definition at line 2322 of file AMDGPUCodeGenPrepare.cpp.