diff options
| author | Nikita Popov <npopov@redhat.com> | 2024-06-25 12:57:19 +0200 |
|---|---|---|
| committer | Nikita Popov <npopov@redhat.com> | 2024-06-25 12:57:19 +0200 |
| commit | 68efc506f58776fdfcfc60707f8fe52584736d8a (patch) | |
| tree | ba16ec7eea032c42ce926bc90b4f32c86218fadf | |
| parent | 9952e00af6c93e9807c3dfe076e99e7f5a77f675 (diff) | |
[VectorBuilderTest] Use poison instead of undef for dummy values (NFC)
| -rw-r--r-- | llvm/unittests/IR/VectorBuilderTest.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/unittests/IR/VectorBuilderTest.cpp b/llvm/unittests/IR/VectorBuilderTest.cpp index 4f9e9d7c494d..e01378a2755f 100644 --- a/llvm/unittests/IR/VectorBuilderTest.cpp +++ b/llvm/unittests/IR/VectorBuilderTest.cpp @@ -65,7 +65,7 @@ TEST_F(VectorBuilderTest, TestCreateBinaryInstructions) { auto VPID = VPIntrinsic::getForOpcode(Instruction::OPCODE); \ bool IsFP = (#INSTCLASS)[0] == 'F'; \ auto *ValueTy = IsFP ? FloatVecTy : IntVecTy; \ - Value *Op = UndefValue::get(ValueTy); \ + Value *Op = PoisonValue::get(ValueTy); \ auto *I = VBuild.createVectorInstruction(Instruction::OPCODE, ValueTy, \ {Op, Op}); \ ASSERT_TRUE(isa<VPIntrinsic>(I)); \ @@ -115,7 +115,7 @@ TEST_F(VectorBuilderTest, TestCreateBinaryInstructions_FixedVector_NoMask) { auto VPID = VPIntrinsic::getForOpcode(Instruction::OPCODE); \ bool IsFP = (#INSTCLASS)[0] == 'F'; \ Type *ValueTy = IsFP ? FloatVecTy : IntVecTy; \ - Value *Op = UndefValue::get(ValueTy); \ + Value *Op = PoisonValue::get(ValueTy); \ auto *I = VBuild.createVectorInstruction(Instruction::OPCODE, ValueTy, \ {Op, Op}); \ ASSERT_TRUE(isa<VPIntrinsic>(I)); \ @@ -161,7 +161,7 @@ TEST_F(VectorBuilderTest, TestCreateBinaryInstructions_FixedVector_NoEVL) { auto VPID = VPIntrinsic::getForOpcode(Instruction::OPCODE); \ bool IsFP = (#INSTCLASS)[0] == 'F'; \ Type *ValueTy = IsFP ? FloatVecTy : IntVecTy; \ - Value *Op = UndefValue::get(ValueTy); \ + Value *Op = PoisonValue::get(ValueTy); \ auto *I = VBuild.createVectorInstruction(Instruction::OPCODE, ValueTy, \ {Op, Op}); \ ASSERT_TRUE(isa<VPIntrinsic>(I)); \ @@ -196,7 +196,7 @@ TEST_F(VectorBuilderTest, auto VPID = VPIntrinsic::getForOpcode(Instruction::OPCODE); \ bool IsFP = (#INSTCLASS)[0] == 'F'; \ Type *ValueTy = IsFP ? FloatVecTy : IntVecTy; \ - Value *Op = UndefValue::get(ValueTy); \ + Value *Op = PoisonValue::get(ValueTy); \ auto *I = VBuild.createVectorInstruction(Instruction::OPCODE, ValueTy, \ {Op, Op}); \ ASSERT_TRUE(isa<VPIntrinsic>(I)); \ @@ -222,8 +222,8 @@ TEST_F(VectorBuilderTest, TestCreateLoadStore) { auto *FloatVecTy = FixedVectorType::get(Type::getFloatTy(Context), VectorNumElements); - Value *FloatVecPtr = UndefValue::get(Builder.getPtrTy(0)); - Value *FloatVec = UndefValue::get(FloatVecTy); + Value *FloatVecPtr = PoisonValue::get(Builder.getPtrTy(0)); + Value *FloatVec = PoisonValue::get(FloatVecTy); // vp.load auto LoadVPID = VPIntrinsic::getForOpcode(Instruction::Load); |
