LLVM
8.0.1
|
#include "llvm/Analysis/Lint.h"
#include "llvm/ADT/APInt.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/Analysis/AssumptionCache.h"
#include "llvm/Analysis/ConstantFolding.h"
#include "llvm/Analysis/InstructionSimplify.h"
#include "llvm/Analysis/Loads.h"
#include "llvm/Analysis/MemoryLocation.h"
#include "llvm/Analysis/Passes.h"
#include "llvm/Analysis/TargetLibraryInfo.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/IR/Argument.h"
#include "llvm/IR/BasicBlock.h"
#include "llvm/IR/CallSite.h"
#include "llvm/IR/Constant.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/GlobalVariable.h"
#include "llvm/IR/InstVisitor.h"
#include "llvm/IR/InstrTypes.h"
#include "llvm/IR/Instruction.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/LegacyPassManager.h"
#include "llvm/IR/Module.h"
#include "llvm/IR/Type.h"
#include "llvm/IR/Value.h"
#include "llvm/Pass.h"
#include "llvm/Support/Casting.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/KnownBits.h"
#include "llvm/Support/MathExtras.h"
#include "llvm/Support/raw_ostream.h"
#include <cassert>
#include <cstdint>
#include <iterator>
#include <string>
Go to the source code of this file.
Namespaces | |
MemRef | |
Macros | |
#define | Assert(C, ...) do { if (!(C)) { CheckFailed(__VA_ARGS__); return; } } while (false) |
Functions | |
INITIALIZE_PASS_BEGIN (Lint, "lint", "Statically lint-checks LLVM IR", false, true) INITIALIZE_PASS_END(Lint | |
static bool | isZero (Value *V, const DataLayout &DL, DominatorTree *DT, AssumptionCache *AC) |
Variables | |
lint | |
Statically lint checks LLVM | IR |
Statically lint checks LLVM | false |
Definition at line 197 of file Lint.cpp.
Referenced by isZero(), llvm::ValueHandleBase::ValueIsDeleted(), and llvm::ValueHandleBase::ValueIsRAUWd().
|
static |
Definition at line 546 of file Lint.cpp.
References Assert, llvm::BasicBlock::begin(), C, llvm::computeKnownBits(), llvm::ConstantFoldConstant(), llvm::DefMaxInstsToScan, llvm::dyn_cast(), llvm::BasicBlock::end(), llvm::FindAvailableLoadedValue(), llvm::FindInsertedValue(), llvm::BasicBlock::front(), llvm::UndefValue::get(), llvm::IndirectBrInst::getAddress(), llvm::Constant::getAggregateElement(), llvm::AllocaInst::getArraySize(), llvm::Module::getDataLayout(), llvm::Function::getEntryBlock(), llvm::ExtractElementInst::getIndexOperand(), llvm::ilist_node_impl< OptionsT >::getIterator(), llvm::Instruction::getModule(), llvm::IndirectBrInst::getNumDestinations(), llvm::SequentialType::getNumElements(), llvm::User::getOperand(), llvm::Instruction::getParent(), llvm::BasicBlock::getParent(), llvm::Value::getType(), llvm::InsertElementInst::getType(), llvm::GetUnderlyingObject(), llvm::BasicBlock::getUniquePredecessor(), llvm::ExtractElementInst::getVectorOperandType(), I, llvm::SmallPtrSetImpl< PtrType >::insert(), llvm::Instruction::isCast(), llvm::CastInst::isNoopCast(), llvm::KnownBits::isZero(), llvm::Constant::isZeroValue(), N, llvm::SimplifyInstruction(), llvm::Value::stripPointerCasts(), llvm::MemoryLocation::UnknownSize, and llvm::RISCVFenceField::W.
Referenced by buildGEP(), computeUnsignedMinMaxValuesFromKnownBits(), foldInsSequenceIntoBroadcast(), llvm::ConstantStruct::get(), llvm::ConstantVector::get(), getConstantPart(), getNegativeIsTrueBoolVec(), llvm::getSplatValue(), llvm::detail::IEEEFloat::isFiniteNonZero(), llvm::APFloat::isFiniteNonZero(), llvm::detail::IEEEFloat::isNegZero(), llvm::APFloat::isNegZero(), llvm::APFloat::isNonZero(), isOnlyReachableViaThisEdge(), llvm::detail::IEEEFloat::isPosZero(), llvm::APFloat::isPosZero(), LowerBUILD_VECTORAsVariablePermute(), llvm::lowerObjectSizeCall(), llvm::ScaledNumber< uint64_t >::operator!(), llvm::ScaledNumber< uint64_t >::operator*=(), llvm::ScaledNumber< uint64_t >::operator/=(), llvm::JumpThreadingPass::ProcessThreadableEdges(), selectI64Imm(), shouldRotateLoopExitingLatch(), and splitGlobal().
Definition at line 193 of file Lint.cpp.
Referenced by llvm::mca::Stage::cycleEnd(), llvm::HexagonFrameLowering::determineCalleeSaves(), llvm::mca::EntryStage::EntryStage(), llvm::detail::getAnalysisResult(), llvm::detail::getAnalysisResultUnpackTuple(), llvm::mca::RetireStage::hasWorkToComplete(), llvm::mca::InstructionTables::hasWorkToComplete(), InlineCallIfPossible(), llvm::AnalysisManager< IRUnitT, ExtraArgTs >::Invalidator::invalidate(), llvm::AnalysisManager< IRUnitT, ExtraArgTs >::invalidate(), llvm::mca::ExecuteStage::isAvailable(), llvm::mca::Scheduler::isAvailable(), isDebug(), llvm::mca::RetireControlUnit::onInstructionExecuted(), llvm::HexagonBlockRanges::IndexType::operator<=(), llvm::mca::RetireControlUnit::reserveSlot(), llvm::InlinerPass::run(), llvm::PassManager< Function >::run(), llvm::RepeatedPass< PassT >::run(), and llvm::mca::Scheduler::select().