Instruction* Quotient = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Quotient && Quotient->getOpcode() == Instruction::Sub);
-
- Builder.SetInsertPoint(BB->end());
}
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) {
Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Remainder && Remainder->getOpcode() == Instruction::Sub);
-
- Builder.SetInsertPoint(BB->end());
}
TEST(IntegerDivision, URem) {
Instruction* Remainder = dyn_cast<Instruction>(cast<User>(Ret)->getOperand(0));
EXPECT_TRUE(Remainder && Remainder->getOpcode() == Instruction::Sub);
-
- Builder.SetInsertPoint(BB->end());
}
}