summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ExecutionEngine
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2017-04-14 20:19:02 +0000
committerReid Kleckner <rnk@google.com>2017-04-14 20:19:02 +0000
commitfb502d2f5e20eb7bd6fb95c407ff4078a530c0fe (patch)
treece9278d3d691404cb00cdfa0932ec36c143f6b90 /llvm/unittests/ExecutionEngine
parent23f28e6c75f80afe8e9f3c3fe739071757df8e09 (diff)
downloadbcm5719-llvm-fb502d2f5e20eb7bd6fb95c407ff4078a530c0fe.tar.gz
bcm5719-llvm-fb502d2f5e20eb7bd6fb95c407ff4078a530c0fe.zip
[IR] Make paramHasAttr to use arg indices instead of attr indices
This avoids the confusing 'CS.paramHasAttr(ArgNo + 1, Foo)' pattern. Previously we were testing return value attributes with index 0, so I introduced hasReturnAttr() for that use case. llvm-svn: 300367
Diffstat (limited to 'llvm/unittests/ExecutionEngine')
-rw-r--r--llvm/unittests/ExecutionEngine/Orc/IndirectionUtilsTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/unittests/ExecutionEngine/Orc/IndirectionUtilsTest.cpp b/llvm/unittests/ExecutionEngine/Orc/IndirectionUtilsTest.cpp
index 48c9f7e6094..4af3aa707a9 100644
--- a/llvm/unittests/ExecutionEngine/Orc/IndirectionUtilsTest.cpp
+++ b/llvm/unittests/ExecutionEngine/Orc/IndirectionUtilsTest.cpp
@@ -42,7 +42,7 @@ TEST(IndirectionUtilsTest, MakeStub) {
EXPECT_TRUE(Call->isTailCall()) << "Indirect call from stub should be tail call.";
EXPECT_TRUE(Call->hasStructRetAttr())
<< "makeStub should propagate sret attr on 1st argument.";
- EXPECT_TRUE(Call->paramHasAttr(2U, Attribute::ByVal))
+ EXPECT_TRUE(Call->paramHasAttr(1U, Attribute::ByVal))
<< "makeStub should propagate byval attr on 2nd argument.";
}
OpenPOWER on IntegriCloud