LLVM  4.0.0
Namespaces | Macros | Functions | Variables
Debug.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 llvm
 Compute iterated dominance frontiers using a linear time algorithm.
 

Macros

#define DEBUG_WITH_TYPE(TYPE, X)
 DEBUG_WITH_TYPE macro - This macro should be used by passes to emit debug information. More...
 
#define DEBUG(X)   DEBUG_WITH_TYPE(DEBUG_TYPE, X)
 

Functions

bool llvm::isCurrentDebugType (const char *Type)
 isCurrentDebugType - Return true if the specified string is the debug type specified on the command line, or if none was specified on the command line with the -debug-only=X option. More...
 
void llvm::setCurrentDebugType (const char *Type)
 setCurrentDebugType - Set the current debug type, as if the -debug-only=X option were specified. More...
 
void llvm::setCurrentDebugTypes (const char **Types, unsigned Count)
 setCurrentDebugTypes - Set the current debug type, as if the -debug-only=X,Y,Z option were specified. More...
 
raw_ostreamllvm::dbgs ()
 dbgs() - This returns a reference to a raw_ostream for debugging messages. More...
 

Variables

bool llvm::DebugFlag = false
 DebugFlag - This boolean is set to true if the '-debug' command line option is specified. More...
 
bool llvm::EnableDebugBuffering = false
 EnableDebugBuffering - This defaults to false. More...
 

Macro Definition Documentation

#define DEBUG (   X)    DEBUG_WITH_TYPE(DEBUG_TYPE, X)

Definition at line 100 of file Debug.h.

Referenced by llvm::InstCombineWorklist::Add(), addDiscriminators(), addForcedAttributes(), llvm::ExecutionEngine::addGlobalMapping(), llvm::InstCombineWorklist::AddInitialGroup(), addNonNullAttrs(), AddReachableCodeToWorklist(), llvm::DIEHash::addSLEB128(), llvm::BlockFrequencyInfoImplBase::addToDist(), llvm::DIEHash::addULEB128(), llvm::IVUsers::AddUsersImpl(), llvm::BlockFrequencyInfoImplBase::adjustLoopHeaderMass(), AdjustStackOffset(), llvm::HexagonHazardRecognizer::AdvanceCycle(), llvm::AggressiveAntiDepBreaker::AggressiveAntiDepBreaker(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::allocateCodeSection(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::allocateDataSection(), llvm::RegAllocBase::allocatePhysRegs(), llvm::AllocationOrder::AllocationOrder(), llvm::HexagonInstrInfo::analyzeBranch(), analyzeLoopUnrollCost(), annotateAllFunctions(), llvm::A57ChainingConstraint::apply(), llvm::RegisterBankInfo::applyDefaultMapping(), llvm::MemoryDepChecker::areDepsSafe(), llvm::LiveRegMatrix::assign(), llvm::HexagonFrameLowering::assignCalleeSavedSpillSlots(), bitTrackingDCE(), llvm::CriticalAntiDepBreaker::BreakAntiDependencies(), llvm::AggressiveAntiDepBreaker::BreakAntiDependencies(), BreakUpSubtract(), BUCompareLatency(), llvm::coro::buildCoroutineFrame(), llvm::CFGMST< Edge, BBInfo >::buildEdges(), llvm::ScheduleDAGInstrs::buildSchedGraph(), llvm::slpvectorizer::BoUpSLP::buildTree(), llvm::SchedBoundary::bumpCycle(), llvm::SchedBoundary::bumpNode(), BURRSort(), llvm::BranchProbabilityInfo::calculate(), llvm::BlockFrequencyInfoImpl< BlockT >::calculate(), calculateCXXStateNumbers(), llvm::LiveRangeEdit::calculateRegClassAndHint(), calculateSEHStateNumbers(), llvm::calculateSpillWeightsAndHints(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::callIntVoid(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::callMain(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::callVoidVoid(), llvm::HexagonPacketizerList::canPromoteToDotCur(), CanPropagatePredecessorsForPHIs(), llvm::MachineBasicBlock::canSplitCriticalEdge(), llvm::RuntimeDyldCheckerImpl::check(), llvm::GenericScheduler::checkAcyclicLatency(), llvm::SchedBoundary::checkHazard(), clampStackAlignment(), llvm::HexagonPacketizerList::cleanUpDotCur(), llvm::objcarc::PtrState::ClearKnownPositiveRefCount(), llvm::FunctionComparator::cmpConstants(), llvm::ScalarEvolution::collectParametricTerms(), combineInstructionsOverFunction(), completeEphemeralValues(), llvm::ObjectSizeOffsetVisitor::compute(), llvm::ScalarEvolution::computeAccessFunctions(), llvm::ComputeCrossModuleImport(), llvm::ComputeCrossModuleImportForModule(), llvm::ScheduleDAGMILive::computeCyclicCriticalPath(), llvm::HexagonBlockRanges::computeDeadMap(), llvm::computeDeadSymbols(), llvm::safestack::StackLayout::computeLayout(), llvm::HexagonBlockRanges::computeLiveMap(), llvm::BlockFrequencyInfoImplBase::computeLoopScale(), llvm::computePeelCount(), computeUnrollCount(), llvm::InstructionSelector::constrainSelectedInstRegOperands(), convertFloatingToInteger(), llvm::X86InstrInfo::copyPhysReg(), llvm::SchedBoundary::countResource(), createIrreducibleLoop(), deleteIfDead(), llvm::ScalarEvolution::delinearize(), llvm::DependenceInfo::depends(), llvm::ARMFrameLowering::determineCalleeSaves(), llvm::AArch64FrameLowering::determineCalleeSaves(), llvm::BlockFrequencyInfoImplBase::distributeMass(), DoPromotion(), llvm::ConstantUniqueMap< llvm::ConstantExpr >::dump(), llvm::JumpThreadingPass::DuplicateCondBranchOnPHIIntoPred(), llvm::DWARFContextInMemory::DWARFContextInMemory(), eliminateDeadStores(), EliminateDeadSwitchCases(), llvm::XCoreRegisterInfo::eliminateFrameIndex(), llvm::MipsRegisterInfo::eliminateFrameIndex(), eliminateNoopStore(), llvm::RuntimeDyldImpl::emitCommonSymbols(), llvm::PPCDispatchGroupSBHazardRecognizer::EmitInstruction(), llvm::HexagonHazardRecognizer::EmitInstruction(), llvm::SystemZHazardRecognizer::EmitInstruction(), llvm::ScoreboardHazardRecognizer::EmitInstruction(), llvm::RuntimeDyldImpl::emitSection(), llvm::HexagonMCCodeEmitter::encodeInstruction(), llvm::HexagonMCCodeEmitter::EncodeSingleInstruction(), llvm::VLIWPacketizerList::endPacket(), ensurePromotedGV(), llvm::SplitEditor::enterIntvAfter(), llvm::SplitEditor::enterIntvAtEnd(), llvm::SplitEditor::enterIntvBefore(), llvm::InstCombiner::eraseInstFromFunction(), llvm::Evaluator::EvaluateBlock(), llvm::Evaluator::EvaluateFunction(), EvaluateStaticConstructor(), expandBounds(), llvm::ARMBaseInstrInfo::expandPostRAPseudo(), extendSegmentsToUses(), llvm::CodeExtractor::extractCodeRegion(), extractInteger(), extractVector(), llvm::SchedDFSImpl::finalize(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::finalizeMemory(), llvm::BlockFrequencyInfoImplBase::finalizeMetrics(), llvm::ScalarEvolution::findArrayDimensions(), llvm::SSAUpdaterImpl< UpdaterT >::FindAvailableVals(), findBaseDefiningValueCached(), findBasePointer(), findGCD(), findIrreducibleHeaders(), llvm::SchedBoundary::findMaxLatency(), findPartitions(), llvm::RegScavenger::FindUnusedReg(), llvm::ScheduleDAGInstrs::fixupKills(), foldBlockIntoPredecessor(), llvm::FoldBranchToCommonDest(), foldReturnAndProcessPred(), llvm::InstCombiner::FoldShiftByConstant(), FoldTwoEntryPHINode(), for(), llvm::ARMTargetLowering::functionArgumentNeedsConsecutiveRegisters(), llvm::HexagonInstrInfo::genAllInsnTimingClasses(), llvm::FunctionLoweringInfo::getArgumentFrameIndex(), getBranchHint(), llvm::MemorySSA::CachingWalker::getClobberingMemoryAccess(), getCompoundInsn(), llvm::coverage::CoverageMapping::getCoverageForExpansion(), llvm::coverage::CoverageMapping::getCoverageForFile(), llvm::coverage::CoverageMapping::getCoverageForFunction(), llvm::HexagonMCInstrInfo::getDuplexPossibilties(), llvm::HexagonHazardRecognizer::getHazardType(), llvm::ScoreboardHazardRecognizer::getHazardType(), llvm::Mips16InstrInfo::getInlineAsmLength(), llvm::getInlineCost(), GetLoadValueForLoad(), getNewAlignment(), getNewAlignmentDiff(), llvm::MemoryDependenceResults::getNonLocalCallDependency(), llvm::SchedBoundary::getOtherResourceCount(), llvm::HexagonInstrInfo::getPredReg(), llvm::getPtrStride(), llvm::slpvectorizer::BoUpSLP::getSpillCost(), llvm::DependenceInfo::getSplitIteration(), llvm::MipsTargetMachine::getTargetIRAnalysis(), llvm::slpvectorizer::BoUpSLP::getTreeCost(), llvm::MachineSSAUpdater::GetValueInMiddleOfBlock(), llvm::SSAUpdater::GetValueInMiddleOfBlock(), handleADRP(), handleEndBlock(), handleFree(), llvm::objcarc::BottomUpPtrState::HandlePotentialAlterRefCount(), llvm::objcarc::TopDownPtrState::HandlePotentialAlterRefCount(), llvm::objcarc::BottomUpPtrState::HandlePotentialUse(), llvm::objcarc::TopDownPtrState::HandlePotentialUse(), hasOnlyUniformBranches(), hasOutsideLoopUser(), hasVRegCycleUse(), llvm::HexagonMCShuffle(), hoist(), llvm::hoistRegion(), llvm::FunctionImporter::importFunctions(), llvm::objcarc::BottomUpPtrState::InitBottomUp(), llvm::GenericScheduler::initCandidate(), INITIALIZE_PASS(), INITIALIZE_PASS_BEGIN(), INITIALIZE_PASS_END(), llvm::ExecutionEngine::InitializeMemory(), llvm::ScheduleDAGMILive::initRegPressure(), initVRegCycle(), inlineCallsImpl(), llvm::HexagonInstrInfo::insertBranch(), insertCopy(), insertInteger(), llvm::InsertPreheaderForLoop(), insertUniqueBackedgeBlock(), insertVector(), llvm::InternalizePass::internalizeModule(), llvm::MachineTraceMetrics::Ensemble::invalidate(), llvm::MachineTraceMetrics::invalidate(), llvm::HexagonInstrInfo::invertAndChangeJumpTarget(), isBitfieldExtractOpFromAnd(), isBitfieldExtractOpFromShr(), llvm::HexagonTargetObjectFile::isGlobalInSmallSection(), llvm::InductionDescriptor::isInductionPHI(), llvm::HexagonInstrInfo::isLateInstrFeedsEarlyInstr(), isOverwrite(), isProfitableChain(), llvm::RecurrenceDescriptor::isReductionPHI(), isSafeToPromoteArgument(), iterativelySinkInstructions(), KnuthDiv(), llvm::LazyCallGraph::LazyCallGraph(), llvm::SplitEditor::leaveIntvAfter(), llvm::SplitEditor::leaveIntvAtTop(), llvm::SplitEditor::leaveIntvBefore(), LinearizeExprTree(), LLVMSetLinkage(), loadFile(), llvm::RuntimeDyldImpl::loadObjectImpl(), lookForCompound(), llvm::HexagonTargetLowering::LowerCall(), llvm::HexagonTargetLowering::LowerDYNAMIC_STACKALLOC(), llvm::gvn::AvailableValue::MaterializeAdjustedValue(), mergeInlinedArrayAllocas(), MoveAndTeeForMultiUse(), MoveForSingleUse(), moveSpillUsesAfterCoroBegin(), moveUp(), nearest_common_dominator(), needsFP(), llvm::TargetRegisterInfo::needsStackRealignment(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::notifyObjectLoaded(), llvm::AggressiveAntiDepBreaker::Observe(), llvm::operator<<(), OptimizeAwayTrappingUsesOfLoads(), llvm::slpvectorizer::BoUpSLP::optimizeGatherSequence(), OptimizeGlobalAddressOfMalloc(), llvm::optimizeGlobalCtorsList(), llvm::OptLevelChanger::OptLevelChanger(), llvm::SplitEditor::overlapIntv(), llvm::BlockFrequencyInfoImplBase::packageLoop(), llvm::VLIWPacketizerList::PacketizeMIs(), false::LibCallsShrinkWrap::perform(), performBitcastCombine(), performConcatVectorsCombine(), llvm::MipsSETargetLowering::PerformDAGCombine(), PerformHeapAllocSRoA(), llvm::GCNMaxOccupancySchedStrategy::pickNode(), llvm::R600SchedStrategy::pickNode(), llvm::SystemZPostRASchedStrategy::pickNode(), llvm::ConvergingVLIWScheduler::pickNode(), llvm::GenericScheduler::pickNode(), llvm::PostGenericScheduler::pickNode(), llvm::GenericScheduler::pickNodeBidirectional(), llvm::ConvergingVLIWScheduler::pickNodeBidrectional(), llvm::ConvergingVLIWScheduler::pickNodeFromQueue(), llvm::GenericScheduler::pickNodeFromQueue(), llvm::PostGenericScheduler::pickNodeFromQueue(), llvm::SchedBoundary::pickOnlyChoice(), llvm::RuntimeDyldMachO::populateIndirectSymbolPointersSection(), llvm::HexagonInstrInfo::PredicateInstruction(), llvm::AlignmentFromAssumptionsPass::processAssumption(), llvm::JumpThreadingPass::ProcessBlock(), processInternalGlobal(), llvm::LoopVectorizePass::processLoop(), processPHI(), llvm::RuntimeDyldCOFFI386::processRelocationRef(), llvm::RuntimeDyldCOFFThumb::processRelocationRef(), llvm::RuntimeDyldCOFFX86_64::processRelocationRef(), llvm::RuntimeDyldELF::processRelocationRef(), llvm::JumpThreadingPass::ProcessThreadableEdges(), ProfitableToMerge(), PromoteArguments(), promoteIndirectCalls(), llvm::promoteLoopAccessesToScalars(), llvm::CachePruning::prune(), llvm::CFLAndersAAResult::query(), llvm::CFLSteensAAResult::query(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::RCMemoryManager(), llvm::RuntimeDyldImpl::reassignSectionAddress(), llvm::AArch64TargetLowering::ReconstructShuffle(), llvm::ScheduleDAGInstrs::reduceHugeMemNodeMaps(), llvm::GenericScheduler::registerRoots(), llvm::PostGenericScheduler::registerRoots(), llvm::R600SchedStrategy::releaseBottomNode(), llvm::R600SchedStrategy::releaseTopNode(), RematerializeCheapDef(), llvm::HexagonInstrInfo::removeBranch(), removeConvergentAttrs(), llvm::MemoryDependenceResults::removeInstruction(), llvm::LazyCallGraph::RefSCC::removeOutgoingEdge(), removeUseSoftFloat(), llvm::SlotIndexes::renumberIndexes(), ReplaceDominatedUses(), llvm::replaceDominatedUsesWith(), llvm::InstCombiner::replaceInstUsesWith(), llvm::replaceSymbolicStrideSCEV(), ReplaceUsesOfWith(), llvm::GenericScheduler::reschedulePhysRegCopies(), llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::reserveAllocationSpace(), llvm::VLIWResourceModel::reserveResources(), llvm::HexagonHazardRecognizer::Reset(), llvm::SystemZHazardRecognizer::Reset(), llvm::objcarc::PtrState::ResetSequenceProgress(), llvm::MipsTargetMachine::resetSubtarget(), llvm::HexagonMCShuffler::reshuffleTo(), llvm::SelectionDAGBuilder::resolveDanglingDebugInfo(), llvm::RuntimeDyldImpl::resolveExternalSymbols(), llvm::RuntimeDyldELFMips::resolveMIPSO32Relocation(), llvm::RuntimeDyldMachOX86_64::resolveRelocation(), llvm::RuntimeDyldMachOI386::resolveRelocation(), llvm::RuntimeDyldMachOARM::resolveRelocation(), llvm::RuntimeDyldCOFFI386::resolveRelocation(), llvm::RuntimeDyldCOFFThumb::resolveRelocation(), llvm::RuntimeDyldMachOAArch64::resolveRelocation(), llvm::RuntimeDyldImpl::resolveRelocations(), llvm::AArch64FrameLowering::restoreCalleeSavedRegisters(), llvm::HexagonInstrInfo::reversePredSense(), rewriteLoopExitBlock(), llvm::ThinLTOCodeGenerator::run(), llvm::safestack::StackColoring::run(), llvm::DeadArgumentEliminationPass::run(), llvm::Interpreter::run(), llvm::DAGTypeLegalizer::run(), llvm::InstCombiner::run(), NewGVN::runGVN(), llvm::Float2IntPass::runImpl(), llvm::SLPVectorizerPass::runImpl(), llvm::SpeculativeExecutionPass::runImpl(), llvm::JumpThreadingPass::runImpl(), runIPSCCP(), llvm::RGPassManager::runOnFunction(), llvm::InstructionSelect::runOnMachineFunction(), llvm::Legalizer::runOnMachineFunction(), llvm::SelectionDAGISel::runOnMachineFunction(), llvm::LiveIntervals::runOnMachineFunction(), llvm::SlotIndexes::runOnMachineFunction(), llvm::RegBankSelect::runOnMachineFunction(), runSCCP(), llvm::RegScavenger::scavengeRegister(), scavengeStackSlot(), llvm::R600SchedStrategy::schedNode(), llvm::SystemZPostRASchedStrategy::schedNode(), llvm::VLIWMachineScheduler::schedule(), llvm::ScheduleDAGMI::schedule(), llvm::SIScheduleDAGMI::schedule(), llvm::ScheduleDAGMILive::schedule(), llvm::ScheduleDAGMILive::scheduleMI(), llvm::SchedDFSResult::scheduleTree(), llvm::ConvergingVLIWScheduler::SchedulingCost(), llvm::ScoreboardHazardRecognizer::ScoreboardHazardRecognizer(), llvm::AArch64InstructionSelector::select(), llvm::SelectionDAGISel::SelectCodeCommon(), selectCopy(), llvm::FastISel::selectIntrinsicCall(), llvm::SplitEditor::selectIntv(), separateNestedLoop(), llvm::FaultMaps::serializeToFaultMapSection(), llvm::StackMaps::serializeToStackMapSection(), llvm::BranchProbabilityInfo::setEdgeProbability(), llvm::objcarc::PtrState::SetKnownPositiveRefCount(), llvm::GenericSchedulerBase::setPolicy(), llvm::objcarc::PtrState::SetSeq(), llvm::ARMBaseRegisterInfo::shouldCoalesce(), shouldInline(), llvm::LiveIntervals::shrinkToUses(), llvm::HexagonShuffler::shuffle(), SimplifyBranchOnICmpChain(), SimplifyCondBranchToCondBranch(), SimplifyCondBranchToTwoReturns(), simplifyOneLoop(), sink(), SinkInstruction(), sinkInstruction(), llvm::sinkRegion(), SinkThenElseCodeToEnd(), llvm::SIScheduleBlockScheduler::SIScheduleBlockScheduler(), llvm::BasicBlockPass::skipBasicBlock(), llvm::FunctionPass::skipFunction(), llvm::LoopPass::skipLoop(), llvm::InstCombiner::SliceUpIllegalIntegerPHI(), llvm::SparseSolver::Solve(), speculatePHINodeLoads(), speculateSelectInstLoads(), SpeculativelyExecuteBB(), llvm::AArch64FrameLowering::spillCalleeSavedRegisters(), llvm::MachineBasicBlock::SplitCriticalEdge(), llvm::SplitEditor::splitLiveThroughBlock(), llvm::SplitEditor::splitRegInBlock(), llvm::SplitEditor::splitRegOutBlock(), llvm::LiveIntervals::splitSeparateComponents(), SRAGlobal(), llvm::DbgValueHistoryMap::startInstrRange(), llvm::TailDuplicator::tailDuplicateBlocks(), llvm::thinLTOResolveWeakForLinkerModule(), llvm::JumpThreadingPass::ThreadEdge(), tracePick(), truncateIVUse(), tryLowerToSLI(), tryPromoteAllocaToVector(), tryToReplaceWithConstant(), tryToShorten(), TryToShrinkGlobalToBoolean(), llvm::TryToSimplifyUncondBranchFromEmptyBlock(), tryToUnrollLoop(), llvm::LiveRegMatrix::unassign(), llvm::UnrollLoop(), unsupportedBinOp(), unwrapLoop(), llvm::LiveIntervals::HMEditor::updateAllRanges(), llvm::ScheduleDAGMILive::updatePressureDiffs(), llvm::ScheduleDAGMILive::updateScheduledPressure(), llvm::MipsSubtarget::useConstantIslands(), llvm::SplitEditor::useIntv(), llvm::slpvectorizer::BoUpSLP::vectorizeTree(), verifyCTRBranch(), llvm::sroa::AllocaSliceRewriter::visit(), llvm::Interpreter::visitAllocaInst(), llvm::InstCombiner::visitAllocaInst(), llvm::ObjectSizeOffsetVisitor::visitInstruction(), llvm::ObjectSizeOffsetEvaluator::visitInstruction(), llvm::InstCombiner::visitSExt(), llvm::InstCombiner::visitTrunc(), llvm::InstCombiner::visitZExt(), llvm::MachObjectWriter::writeObject(), llvm::OptLevelChanger::~OptLevelChanger(), and llvm::orc::remote::OrcRemoteTargetClient< ChannelT >::RCMemoryManager::~RCMemoryManager().

#define DEBUG_WITH_TYPE (   TYPE,
  X 
)
Value:
do { if (::llvm::DebugFlag && ::llvm::isCurrentDebugType(TYPE)) { X; } \
} while (false)
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang","erlang-compatible garbage collector")
bool DebugFlag
DebugFlag - This boolean is set to true if the '-debug' command line option is specified.
Definition: Debug.cpp:43
bool isCurrentDebugType(const char *Type)
isCurrentDebugType - Return true if the specified string is the debug type specified on the command l...
Definition: Debug.cpp:50

DEBUG_WITH_TYPE macro - This macro should be used by passes to emit debug information.

In the '-debug' option is specified on the commandline, and if this is a debug build, then the code specified as the option to the macro will be executed. Otherwise it will not be. Example:

DEBUG_WITH_TYPE("bitset", dbgs() << "Bitset contains: " << Bitset << "\n");

This will emit the debug information if -debug is present, and -debug-only is not specified, or is specified as "bitset".

Definition at line 69 of file Debug.h.

Referenced by llvm::colorEHFunclets(), llvm::ARMAsmBackendDarwin::generateCompactUnwindEncoding(), llvm::MCAssembler::layout(), llvm::object::MachORebaseEntry::moveNext(), llvm::object::MachOBindEntry::moveNext(), and llvm::SCEVExpander::replaceCongruentIVs().