mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
The C cast is undefined past the int32 range, and x86 makes it INT_MIN, so round/trunc/ceil/floor/cvt.w.s of anything from 2^31 up gave 0x80000000 on x86 hosts while the PSP saturates to 0x7fffffff (cpu/fpu/roundmode). Route all of them through SaturatedFloatToInt, which also covers NaN and inf, and drop the special cases that did. Co-Authored-By: Claude Fable 5.1 <[email protected]>