Skip to content

Commit 8756044

Browse files
committed
Rename ExpandLargeFpConvertPass to ExpandFpPass (llvm#131128)
This is meant as a preparation for PR llvm#130988 "[AMDGPU] Implement IR expansion for frem instruction" which implements the expansion of another instruction in this pass. The more general name seems more appropriate given this change and quite reasonable even without it.
1 parent 66e404a commit 8756044

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

llvm/lib/CodeGen/ExpandFp.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -410,6 +410,8 @@ static bool expandFRem(BinaryOperator &I) {
410410
return true;
411411
}
412412

413+
// clang-format off: preserve formatting of the following example
414+
413415
/// Generate code to convert a fp number to integer, replacing FPToS(U)I with
414416
/// the generated code. This currently generates code similarly to compiler-rt's
415417
/// implementations.
@@ -462,6 +464,7 @@ static bool expandFRem(BinaryOperator &I) {
462464
///
463465
/// Replace fp to integer with generated code.
464466
static void expandFPToI(Instruction *FPToI) {
467+
// clang-format on
465468
IRBuilder<> Builder(FPToI);
466469
auto *FloatVal = FPToI->getOperand(0);
467470
IntegerType *IntTy = cast<IntegerType>(FPToI->getType());
@@ -598,6 +601,8 @@ static void expandFPToI(Instruction *FPToI) {
598601
FPToI->eraseFromParent();
599602
}
600603

604+
// clang-format off: preserve formatting of the following example
605+
601606
/// Generate code to convert a fp number to integer, replacing S(U)IToFP with
602607
/// the generated code. This currently generates code similarly to compiler-rt's
603608
/// implementations. This implementation has an implicit assumption that integer
@@ -681,6 +686,7 @@ static void expandFPToI(Instruction *FPToI) {
681686
///
682687
/// Replace integer to fp with generated code.
683688
static void expandIToFP(Instruction *IToFP) {
689+
// clang-format on
684690
IRBuilder<> Builder(IToFP);
685691
auto *IntVal = IToFP->getOperand(0);
686692
IntegerType *IntTy = cast<IntegerType>(IntVal->getType());

0 commit comments

Comments
 (0)