fallback: legalize: G_FPTOSI_SAT s16,s64

Run:main-04ca53e65f-20261014-105623
Kind:fallback
Category:legalize: G_FPTOSI_SAT s16,s64
Occurrences:10 in 6 configs, 1 test files
Snippet from:double-convert.ll @fcvt_w_s_sat_i16 via llvm-extract
Config:-mtriple=riscv32 -mattr=+d -verify-machineinstrs -target-abi=ilp32d
Local check:reproduces at 04ca53e65f
Compiler Explorer:not uploaded (over --godbolt-limit or disabled)

Snippet:

; Function Attrs: nounwind
define signext i16 @fcvt_w_s_sat_i16(double %a) #0 {
start:
  %0 = tail call i16 @llvm.fptosi.sat.i16.f64(double %a)
  ret i16 %0
}

; Function Attrs: nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none)
declare i16 @llvm.fptosi.sat.i16.f64(double) #1

attributes #0 = { nounwind }
attributes #1 = { nocallback nocreateundeforpoison nofree nosync nounwind speculatable willreturn memory(none) }

Reproduce:

llc -mtriple=riscv32 -mattr=+d -verify-machineinstrs -target-abi=ilp32d -global-isel -global-isel-abort=2 -pass-remarks-missed=gisel.* snippet.ll -o -
llc -mtriple=riscv32 -mattr=+d -verify-machineinstrs -target-abi=ilp32d -global-isel=0 snippet.ll -o -

Local llc output:

remark: <unknown>:0:0: unable to legalize instruction: %1:_(s16) = G_FPTOSI_SAT %0:_(s64) (in function: fcvt_w_s_sat_i16)
warning: Instruction selection used fallback path for fcvt_w_s_sat_i16

Occurrences (10):

InputFunctionConfig
double-convert.llfcvt_w_s_sat_i16-mtriple=riscv32 -mattr=+d -verify-machineinstrs -target-abi=ilp32d
double-convert.llfcvt_w_s_sat_i16-mtriple=riscv32 -verify-machineinstrs
double-convert.llfcvt_w_s_sat_i16-mtriple=riscv64 -mattr=+d -verify-machineinstrs -target-abi=lp64d
double-convert.llfcvt_w_s_sat_i16-mtriple=riscv64 -verify-machineinstrs
double-convert.1264a720dd.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv32 -mattr=+zdinx -verify-machineinstrs -target-abi=ilp32
double-convert.170bab03b5.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv32 -verify-machineinstrs
double-convert.18cdac309b.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv64 -verify-machineinstrs
double-convert.9b699d4fdc.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv64 -mattr=+zdinx -verify-machineinstrs -target-abi=lp64
double-convert.9c4d51c3dd.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv32 -mattr=+d -verify-machineinstrs -target-abi=ilp32d
double-convert.ea7460c7fc.ll (mutant of double-convert.ll)fcvt_w_s_sat_i16-mtriple=riscv64 -mattr=+d -verify-machineinstrs -target-abi=lp64d

Generated 2026-10-15 08:05 UTC.