From de04a8c1500028c5d71dec193505ceb3377d0aab Mon Sep 17 00:00:00 2001 From: Adrian Prantl Date: Thu, 7 Mar 2019 23:30:19 +0000 Subject: [PATCH] Temporarily diasble debug output in GenericDomTreeConstruction.h to get the modules bots running again. The LLVM_DEBUG macro only plays well with a modular build of LLVM when the header is marked as textual, but doing so causes redefinition errors. llvm-svn: 355653 --- llvm/include/llvm/Support/GenericDomTreeConstruction.h | 10 ++++++++++ llvm/include/llvm/module.modulemap | 3 --- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/llvm/include/llvm/Support/GenericDomTreeConstruction.h b/llvm/include/llvm/Support/GenericDomTreeConstruction.h index 53f3f99..ccceba8 100644 --- a/llvm/include/llvm/Support/GenericDomTreeConstruction.h +++ b/llvm/include/llvm/Support/GenericDomTreeConstruction.h @@ -1185,6 +1185,10 @@ struct SemiNCAInfo { BUI.FuturePredecessors[U.getTo()].push_back({U.getFrom(), U.getKind()}); } +#if 0 + // FIXME: The LLVM_DEBUG macro only plays well with a modular + // build of LLVM when the header is marked as textual, but doing + // so causes redefinition errors. LLVM_DEBUG(dbgs() << "About to apply " << NumLegalized << " updates\n"); LLVM_DEBUG(if (NumLegalized < 32) for (const auto &U : reverse(BUI.Updates)) { @@ -1193,6 +1197,7 @@ struct SemiNCAInfo { dbgs() << "\n"; }); LLVM_DEBUG(dbgs() << "\n"); +#endif // Recalculate the DominatorTree when the number of updates // exceeds a threshold, which usually makes direct updating slower than @@ -1218,8 +1223,13 @@ struct SemiNCAInfo { static void ApplyNextUpdate(DomTreeT &DT, BatchUpdateInfo &BUI) { assert(!BUI.Updates.empty() && "No updates to apply!"); UpdateT CurrentUpdate = BUI.Updates.pop_back_val(); +#if 0 + // FIXME: The LLVM_DEBUG macro only plays well with a modular + // build of LLVM when the header is marked as textual, but doing + // so causes redefinition errors. LLVM_DEBUG(dbgs() << "Applying update: "); LLVM_DEBUG(CurrentUpdate.dump(); dbgs() << "\n"); +#endif // Move to the next snapshot of the CFG by removing the reverse-applied // current update. Since updates are performed in the same order they are diff --git a/llvm/include/llvm/module.modulemap b/llvm/include/llvm/module.modulemap index 7718250..65c9495 100644 --- a/llvm/include/llvm/module.modulemap +++ b/llvm/include/llvm/module.modulemap @@ -353,9 +353,6 @@ module LLVM_Utils { exclude header "Support/PluginLoader.h" exclude header "Support/Solaris/sys/regset.h" - // This header uses the LLVM_DEBUG macro in function bodies. - textual header "Support/GenericDomTreeConstruction.h" - // These are intended for textual inclusion. textual header "Support/ARMTargetParser.def" textual header "Support/AArch64TargetParser.def" -- 2.7.4