diff options
author | Sanjoy Das <sanjoy@playingwithpointers.com> | 2019-03-05 01:15:08 +0000 |
---|---|---|
committer | Sanjoy Das <sanjoy@playingwithpointers.com> | 2019-03-05 01:15:08 +0000 |
commit | 719e78631de30ad47ef3698e6b8356002b5729c4 (patch) | |
tree | e56822bfe1ede3d56fa44cdaf74b2ad29cfdb7ef /llvm/unittests/IR/InstructionsTest.cpp | |
parent | 6a6ce5be84ce5e611002891f9cce8a61b88c1bc5 (diff) | |
download | bcm5719-llvm-719e78631de30ad47ef3698e6b8356002b5729c4.tar.gz bcm5719-llvm-719e78631de30ad47ef3698e6b8356002b5729c4.zip |
PHI nodes are not `FPMathOperator` s
Reviewers: chandlerc, arsenm
Reviewed By: arsenm
Subscribers: wdng, arsenm, mcrosier, jlebar, bixia, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D58887
llvm-svn: 355362
Diffstat (limited to 'llvm/unittests/IR/InstructionsTest.cpp')
-rw-r--r-- | llvm/unittests/IR/InstructionsTest.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/unittests/IR/InstructionsTest.cpp b/llvm/unittests/IR/InstructionsTest.cpp index 94f37251e60..3b2bd6fa81b 100644 --- a/llvm/unittests/IR/InstructionsTest.cpp +++ b/llvm/unittests/IR/InstructionsTest.cpp @@ -993,5 +993,14 @@ TEST(InstructionsTest, SkipDebug) { EXPECT_EQ(nullptr, Term->getNextNonDebugInstruction()); } +TEST(InstructionsTest, PhiIsNotFPMathOperator) { + LLVMContext Context; + IRBuilder<> Builder(Context); + MDBuilder MDHelper(Context); + Instruction *I = Builder.CreatePHI(Builder.getDoubleTy(), 0); + EXPECT_FALSE(isa<FPMathOperator>(I)); + I->deleteValue(); +} + } // end anonymous namespace } // end namespace llvm |