[llvm] [LLVM] Slay undead copysign code (PR #111269)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Sat Oct 5 22:22:37 PDT 2024
================
@@ -438,7 +442,15 @@ void IntrinsicLowering::LowerIntrinsicCall(CallInst *CI) {
break;
}
case Intrinsic::copysign: {
- ReplaceFPIntrinsicWithCall(CI, "copysignf", "copysign", "copysignl");
+ switch (CI->getArgOperand(0)->getType()->getTypeID()) {
+ default:
+ assert(false && "only need a copysign libcall for arch-specific floats");
----------------
topperc wrote:
Is the `break;` on a release build any better? It will exit the switch and hit the `CI->eraseFromParent() ` which will likely leave the IR in a broken state.
Maybe `report_fatal_error` would be more appropriate?
https://github.com/llvm/llvm-project/pull/111269
More information about the llvm-commits
mailing list