!Subtarget->inMicroMipsMode() && Subtarget->hasMips32();
TargetSupported =
ISASupported && TM.isPositionIndependent() && getABI().IsO32();
- UnsupportedFPMode = Subtarget->isFP64bit();
+ UnsupportedFPMode = Subtarget->isFP64bit() || Subtarget->useSoftFloat();
}
unsigned fastMaterializeAlloca(const AllocaInst *AI) override;
break;
case MVT::f32:
+ if (UnsupportedFPMode) {
+ DEBUG(dbgs() << ".. .. gave up (UnsupportedFPMode)\n");
+ return false;
+ }
if (NextFGR32 == FGR32ArgRegs.end()) {
DEBUG(dbgs() << ".. .. gave up (ran out of FGR32 arguments)\n");
return false;
case MVT::f64:
if (UnsupportedFPMode) {
- DEBUG(dbgs() << ".. .. gave up (UnsupportedFPMode\n");
+ DEBUG(dbgs() << ".. .. gave up (UnsupportedFPMode)\n");
return false;
}
if (NextAFGR64 == AFGR64ArgRegs.end()) {
--- /dev/null
+; RUN: not llc -march=mipsel -mcpu=mips32r2 -mattr=+soft-float \
+; RUN: -O0 -fast-isel-abort=3 -relocation-model=pic < %s
+
+; Test that FastISel aborts instead of trying to lower arguments for soft-float.
+
+define void @__signbit(double %__x) {
+entry:
+ %__x.addr = alloca double, align 8
+ store double %__x, double* %__x.addr, align 8
+ ret void
+}