summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2016-08-30 15:12:58 +0000
committerReid Kleckner <rnk@google.com>2016-08-30 15:12:58 +0000
commit9581f2dda8fac638b456f826d0f2a0e9a5fa2fea (patch)
treea17aae2ac5a6d2fa4ee012a52e60803d9c4c66e8 /llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp
parentb0abba5c329a4a8c8349c8945cf31ba5e9fe4675 (diff)
downloadbcm5719-llvm-9581f2dda8fac638b456f826d0f2a0e9a5fa2fea.tar.gz
bcm5719-llvm-9581f2dda8fac638b456f826d0f2a0e9a5fa2fea.zip
Revert "[ORC][RPC] Make the future type of an Orc RPC call Error/Expected rather than"
This reverts commit r280016, and the followups of r280017, r280027, r280051, r280058, and r280059. MSVC's implementation of std::promise does not get along with llvm::Error. It uses its promised value too much like a normal value type. llvm-svn: 280100
Diffstat (limited to 'llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp')
-rw-r--r--llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp b/llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp
index babea5ca73a..7d55641e4ce 100644
--- a/llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp
+++ b/llvm/unittests/ExecutionEngine/Orc/RPCUtilsTest.cpp
@@ -83,7 +83,7 @@ TEST_F(DummyRPC, TestAsyncVoidBool) {
QueueChannel C2(Q2, Q1);
// Make an async call.
- auto ResOrErr = callNBWithSeq<VoidBool>(C1, true);
+ auto ResOrErr = callAsyncWithSeq<VoidBool>(C1, true);
EXPECT_TRUE(!!ResOrErr) << "Simple call over queue failed";
{
@@ -102,8 +102,8 @@ TEST_F(DummyRPC, TestAsyncVoidBool) {
}
// Verify that the function returned ok.
- auto Err = ResOrErr->first.get();
- EXPECT_FALSE(!!Err) << "Remote void function failed to execute.";
+ auto Val = ResOrErr->first.get();
+ EXPECT_TRUE(Val) << "Remote void function failed to execute.";
}
TEST_F(DummyRPC, TestAsyncIntInt) {
@@ -112,7 +112,7 @@ TEST_F(DummyRPC, TestAsyncIntInt) {
QueueChannel C2(Q2, Q1);
// Make an async call.
- auto ResOrErr = callNBWithSeq<IntInt>(C1, 21);
+ auto ResOrErr = callAsyncWithSeq<IntInt>(C1, 21);
EXPECT_TRUE(!!ResOrErr) << "Simple call over queue failed";
{
@@ -143,7 +143,7 @@ TEST_F(DummyRPC, TestSerialization) {
// Make a call to Proc1.
std::vector<int> v({42, 7});
- auto ResOrErr = callNBWithSeq<AllTheTypes>(
+ auto ResOrErr = callAsyncWithSeq<AllTheTypes>(
C1, -101, 250, -10000, 10000, -1000000000, 1000000000, -10000000000,
10000000000, true, "foo", v);
EXPECT_TRUE(!!ResOrErr) << "Big (serialization test) call over queue failed";
@@ -179,8 +179,8 @@ TEST_F(DummyRPC, TestSerialization) {
}
// Verify that the function returned ok.
- auto Err = ResOrErr->first.get();
- EXPECT_FALSE(!!Err) << "Remote void function failed to execute.";
+ auto Val = ResOrErr->first.get();
+ EXPECT_TRUE(Val) << "Remote void function failed to execute.";
}
// Test the synchronous call API.
OpenPOWER on IntegriCloud