mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-11-08 21:58:44 +00:00
9db73f74cf
* ARMeilleure: Respect Fz flag for all floating point operations. This is a change in strategy for emulating the Fz FPCR flag. Before, it was set before instructions that "needed it" and reset after. However, this missed a few hot instructions like the multiplication instruction, and the entirety of A32. The new strategy is to set the Fz flag only in the following circumstances: - Set to match FPCR before translated functions/loop are executed. - Reset when calling SoftFloat methods, set when returning. - Reset when exiting execution. This allows us to remove the code around the existing Fz aware instructions, and get the accuracy benefits on all floating point instructions executed while in translated code. Single step executions now need to be called with a context wrapper - right now it just contains the Fz flag initialization, and won't actually do anything on ARM. This fixes a bug in Breath of the Wild where some physics interactions could randomly crash the game due to subnormal values not flushing to zero. This is draft right now because I need to answer the questions: - Does dotnet avoid changing the value of Mxcsr? - Is it a good idea to assume that? Or should the flag set/restore be done on every managed method call, not just softfloat? - If we assume that, do we want a unit test to verify the behaviour? I recommend testing a bunch of games, especially games affected when this was originally added, such as #1611. * Remove unused method * Use FMA for Fmadd, Fmsub, Fnmadd, Fnmsub, Fmla, Fmls ...when available. Similar implementation to A32 * Use FMA for Frecps, Frsqrts * Don't set DAZ. * Add round mode to ARM FP mode * Fix mistakes * Add test for FP state when calling managed methods * Add explanatory comment to test. * Cleanup * Add A64 FPCR flags * Vrintx_S A32 fast path on A64 backend * Address feedback 1, re-enable DAZ * Fix FMA instructions By Elem * Address feedback |
||
---|---|---|
.. | ||
CryptoHelper.cs | ||
InstEmitAlu.cs | ||
InstEmitAlu32.cs | ||
InstEmitAluHelper.cs | ||
InstEmitBfm.cs | ||
InstEmitCcmp.cs | ||
InstEmitCsel.cs | ||
InstEmitDiv.cs | ||
InstEmitException.cs | ||
InstEmitException32.cs | ||
InstEmitFlow.cs | ||
InstEmitFlow32.cs | ||
InstEmitFlowHelper.cs | ||
InstEmitHash.cs | ||
InstEmitHash32.cs | ||
InstEmitHashHelper.cs | ||
InstEmitHelper.cs | ||
InstEmitMemory.cs | ||
InstEmitMemory32.cs | ||
InstEmitMemoryEx.cs | ||
InstEmitMemoryEx32.cs | ||
InstEmitMemoryExHelper.cs | ||
InstEmitMemoryHelper.cs | ||
InstEmitMove.cs | ||
InstEmitMul.cs | ||
InstEmitMul32.cs | ||
InstEmitSimdArithmetic.cs | ||
InstEmitSimdArithmetic32.cs | ||
InstEmitSimdCmp.cs | ||
InstEmitSimdCmp32.cs | ||
InstEmitSimdCrypto.cs | ||
InstEmitSimdCrypto32.cs | ||
InstEmitSimdCvt.cs | ||
InstEmitSimdCvt32.cs | ||
InstEmitSimdHash.cs | ||
InstEmitSimdHash32.cs | ||
InstEmitSimdHashHelper.cs | ||
InstEmitSimdHelper.cs | ||
InstEmitSimdHelper32.cs | ||
InstEmitSimdHelper32Arm64.cs | ||
InstEmitSimdHelperArm64.cs | ||
InstEmitSimdLogical.cs | ||
InstEmitSimdLogical32.cs | ||
InstEmitSimdMemory.cs | ||
InstEmitSimdMemory32.cs | ||
InstEmitSimdMove.cs | ||
InstEmitSimdMove32.cs | ||
InstEmitSimdShift.cs | ||
InstEmitSimdShift32.cs | ||
InstEmitSystem.cs | ||
InstEmitSystem32.cs | ||
InstName.cs | ||
NativeInterface.cs | ||
SoftFallback.cs | ||
SoftFloat.cs |