Remove unneeded and invalid SetInsertPoint calls from unittest.

BB->end() returns a sentinel value that is not a legal insert point.

llvm-svn: 164699
This commit is contained in:
Benjamin Kramer 2012-09-26 15:16:05 +00:00
parent 6b5f441814
commit 9cd31639d0

View File

@ -47,8 +47,6 @@ TEST(IntegerDivision, SDiv) {
Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Quotient && Quotient->getOpcode() == Instruction::Sub);
Builder.SetInsertPoint(BB->end());
}
TEST(IntegerDivision, UDiv) {
@ -79,8 +77,6 @@ TEST(IntegerDivision, UDiv) {
Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Quotient && Quotient->getOpcode() == Instruction::PHI);
Builder.SetInsertPoint(BB->end());
}
TEST(IntegerDivision, SRem) {
@ -111,8 +107,6 @@ TEST(IntegerDivision, SRem) {
Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Remainder && Remainder->getOpcode() == Instruction::Sub);
Builder.SetInsertPoint(BB->end());
}
TEST(IntegerDivision, URem) {
@ -143,8 +137,6 @@ TEST(IntegerDivision, URem) {
Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Remainder && Remainder->getOpcode() == Instruction::Sub);
Builder.SetInsertPoint(BB->end());
}
}