1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 12:33:33 +02:00

[llvm-exegesis] Fix failing test.

Reviewers: courbet

Subscribers: tschuett, llvm-commits

Differential Revision: https://reviews.llvm.org/D48358

llvm-svn: 335115
This commit is contained in:
Guillaume Chatelet 2018-06-20 11:09:36 +00:00
parent 4893e095df
commit 99ba2cc970

View File

@ -20,6 +20,8 @@
namespace exegesis {
namespace {
using testing::AnyOf;
using testing::ElementsAre;
using testing::HasSubstr;
using testing::Not;
using testing::SizeIs;
@ -119,8 +121,8 @@ TEST_F(LatencySnippetGeneratorTest, DependencyThroughOtherOpcode) {
const InstructionInstance &II = Proto.Snippet[0];
EXPECT_THAT(II.getOpcode(), Opcode);
ASSERT_THAT(II.VariableValues, SizeIs(2));
EXPECT_THAT(II.VariableValues[0], IsReg());
EXPECT_THAT(II.VariableValues[1], IsInvalid());
EXPECT_THAT(II.VariableValues, AnyOf(ElementsAre(IsReg(), IsInvalid()),
ElementsAre(IsInvalid(), IsReg())));
EXPECT_THAT(Proto.Snippet[1].getOpcode(), Not(Opcode));
// TODO: check that the two instructions alias each other.
}