[llvm] r321920 - [ORC] Temporarily adding some redundant asserts / debug output to aid in
Lang Hames via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 5 17:06:07 PST 2018
Author: lhames
Date: Fri Jan 5 17:06:07 2018
New Revision: 321920
URL: http://llvm.org/viewvc/llvm-project?rev=321920&view=rev
Log:
[ORC] Temporarily adding some redundant asserts / debug output to aid in
debugging a tester failure.
Modified:
llvm/trunk/lib/ExecutionEngine/Orc/Core.cpp
llvm/trunk/unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp
Modified: llvm/trunk/lib/ExecutionEngine/Orc/Core.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/Orc/Core.cpp?rev=321920&r1=321919&r2=321920&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/Orc/Core.cpp (original)
+++ llvm/trunk/lib/ExecutionEngine/Orc/Core.cpp Fri Jan 5 17:06:07 2018
@@ -40,14 +40,28 @@ void AsynchronousSymbolQuery::setDefinit
if (OutstandingResolutions == 0)
return;
+ assert(NotifySymbolsResolved && "Notify callback not set");
+
+ errs()
+ << "OutstandingResolutions = " << OutstandingResolutions << "\n"
+ << "OutstandingFinalizations = " << OutstandingFinalizations << "\n"
+ << "Symbols.size() = " << Symbols.size() << "\n"
+ << "Symbols.count(Name) = " << Symbols.count(Name) << "\n";
+
assert(!Symbols.count(Name) &&
"Symbol has already been assigned an address");
+ errs() << "Past assert\n";
Symbols.insert(std::make_pair(std::move(Name), std::move(Sym)));
+ errs() << "Past insert\n";
--OutstandingResolutions;
+ errs() << "Past subtract\n";
if (OutstandingResolutions == 0) {
+ errs() << "Past test\n";
NotifySymbolsResolved(std::move(Symbols));
// Null out NotifySymbolsResolved to indicate that we've already called it.
+ errs() << "Past callback\n";
NotifySymbolsResolved = {};
+ errs() << "Past callback-reset\n";
}
}
Modified: llvm/trunk/unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp?rev=321920&r1=321919&r2=321920&view=diff
==============================================================================
--- llvm/trunk/unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp (original)
+++ llvm/trunk/unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp Fri Jan 5 17:06:07 2018
@@ -45,6 +45,7 @@ TEST(CoreAPIsTest, AsynchronousSymbolQue
EXPECT_TRUE(OnResolutionRun) << "OnResolutionCallback was not run";
EXPECT_FALSE(OnReadyRun) << "OnReady unexpectedly run";
+ errs() << "Exiting test\n";
}
}
More information about the llvm-commits
mailing list