Jean-Philip Desjardins
9bcbe1f699
Update pipeTime when syncing EFU operations.
...
Fixes issues with Shinobi where WAITP is used and FDIV pipeline needs to be updated as a side-effect.
2023-05-11 10:01:48 -04:00
Jean-Philip Desjardins
2f737651fb
Add function to check for NaNs in vectors.
2023-05-10 09:07:19 -04:00
Jean-Philip Desjardins
d302c318d4
Do simple move when adding 0.
...
Avoids destructive clamping that might be against the intent of the instruction.
2023-05-10 09:07:18 -04:00
Jean-Philip Desjardins
b5d8aad96e
Use CodeGen's native MD_ClampS to clamp vectors.
2023-03-03 16:50:59 -05:00
Jean-Philip Desjardins
db6ffbc111
Support writing VU1 registers from VU0 macro mode.
2022-07-11 14:09:46 -04:00
Jean-Philip Desjardins
6708e394db
Add comment to explain why we don't use FpAddTruncate on JS.
2022-02-14 13:07:15 -05:00
Jean-Philip Desjardins
e0bfe0223c
Disable accurate ADDi on JavaScript.
...
Could be enabled later.
2022-02-14 13:07:15 -05:00
Jean-Philip Desjardins
aebd6eb9bc
Prevent clobbering of VF0.
2022-02-11 13:15:38 -05:00
Jean-Philip Desjardins
34171f12e5
Prevent VI0 clobbering.
2022-02-09 12:38:32 -05:00
Jean-Philip Desjardins
69531b84bc
Don't recompute the clamping mask.
...
Removes a few instructions in generated code.
2021-07-09 10:03:27 -04:00
Jean-Philip Desjardins
80e6554cdc
Use StoreAtRefIdx to clear flags pipeline.
...
Using PullRel would cause array items to be register allocated which is not a good thing
since they are accessed through array operations in other places.
2021-07-02 10:22:27 -04:00
darkpigeon
6dd820d734
Merge branch 'jpd002:master' into fatalframe1
2021-05-15 15:33:20 +07:00
Jean-Philip Desjardins
4ceef01615
Prevent MOVE on VF0.
2021-04-27 13:51:57 -04:00
darkpigeon
e0c3d55007
Add clamping to VU
...
Fixes Fatal Frame 1's door-blocking bug, which allows further proceeding ingame
2021-04-07 22:22:34 +07:00
Jean-Philip Desjardins
650f129545
Clamp some input vectors.
...
Fixes issues entering some areas in Samurai Legend Musashi.
2021-01-26 19:30:24 -05:00
Jean-Philip Desjardins
efbbeb057b
Merge ADD code in a single function.
...
Except for ADDi which has an exception.
2021-01-26 19:30:24 -05:00
Jean-Philip Desjardins
29ebcafec5
Preserve W component of FD in OPMSUB.
...
Fixes a ton of problems (KH2, Musashi Samurai Legends, Wild Arms 5 & probably others).
2020-11-26 16:29:46 -05:00
Jean-Philip Desjardins
935427fa6e
Remove unused include.
2020-11-25 09:54:55 -05:00
Jean-Philip Desjardins
239f6c53c7
Make sure sticky flags arrive at the proper time.
2020-06-02 15:12:27 -04:00
Jean-Philip Desjardins
d207c648ac
Formatting niceties.
2020-06-02 15:12:27 -04:00
Mahmood - Zer0xFF
e503f3eae6
improve VU MOVE/RNEXT instruction
2020-05-21 19:22:16 +01:00
Jean-Philip Desjardins
2bfe87ff52
Clamp vectors before comparing in MINI/MAX.
2020-05-15 16:44:08 -04:00
Jean-Philip Desjardins
ff488e17db
Implement ADDAq.
2020-05-15 12:37:55 -04:00
Jean-Philip Desjardins
53db596365
Prevent ITOF0 & ITOF12 from clobbering VF0.
2020-05-15 12:37:54 -04:00
Jean-Philip Desjardins
50608f6453
Use LoadFromRefIdx in ILW.
2020-05-11 13:15:21 -04:00
Jean-Philip Desjardins
ece02c072c
Use StoreAtRefIdx in ISW.
2020-05-11 13:15:21 -04:00
Jean-Philip Desjardins
cda03da746
Use StoreAtRefIdx4 in QueueInFlagPipeline.
2020-05-11 13:15:21 -04:00
Jean-Philip Desjardins
409743e6d5
Fix stylin issues.
2020-04-22 16:24:01 -04:00
Jean-Philip Desjardins
ae83c9caba
Implement MINI/MAX VU operations differently.
...
These seem to be only moving from a register to another without FP processing.
On our target CPUs (x86 & ARM), the same operations flush denormals to zero.
2020-04-22 14:53:07 -04:00
Jean-Philip Desjardins
66684a16b0
Skip flags update when we're sure result won't be used.
...
This is proof of concept, needs to be cleaned.
2020-02-10 21:40:08 -05:00
Jean-Philip Desjardins
0a39bd9827
Code style fix.
2019-11-17 10:56:21 -05:00
Jean-Philip Desjardins
9ef60706e1
Add exception for VU SUB instruction which is meant to clear a register.
...
Avoid potential NaN FPU exceptions.
2019-11-16 16:22:06 -05:00
Jean-Philip Desjardins
7a3f25dbd1
Prevent VF0 from being clobbered.
2019-10-17 21:13:32 -04:00
Jean-Philip Desjardins
21afd31033
Use new primitive to compute SZ flags.
2019-08-30 19:03:31 -04:00
Jean-Philip Desjardins
c34fe4ec11
Move operation latency definitions.
...
(cherry picked from commit 8485a66453ec75621cbfbce4091ed52f7dfb7382)
2019-08-14 20:44:51 -04:00
Jean-Philip Desjardins
cbd56aac40
Code style fixes.
2018-12-04 18:53:29 -05:00
Jean-Philip Desjardins
e32a8efbbb
Standardize handling of DIV by 0.
2018-12-04 13:00:34 -05:00
Jean-Philip Desjardins
f167c11e39
Get absolute value before computing square root.
2018-12-04 13:00:34 -05:00
Jean-Philip Desjardins
5f109ff50c
Update RSQRT code to update D flag properly.
2018-11-07 12:43:59 -05:00
Jean-Philip Desjardins
043f918f40
Use define instead of hardcoded value.
2018-11-07 12:42:46 -05:00
Jean-Philip Desjardins
8d498f65b0
Set D flag when division by 0 is encountered.
2018-11-07 12:23:15 -05:00
Jean-Philip Desjardins
658c257a58
Remove hard-coded values.
2018-11-07 12:22:46 -05:00
Jean-Philip Desjardins
d99b3a0a6d
Handle RSQRT by 0.
2018-11-06 13:10:02 -05:00
Jean-Philip Desjardins
9cf664c024
WAITP needs to flush pipeline.
2018-08-31 18:15:13 -04:00
Jean-Philip Desjardins
aeb8986b73
Fix build.
2018-08-31 17:24:03 -04:00
Jean-Philip Desjardins
b475b8ff16
Experimental P pipeline support.
2018-08-31 07:40:14 -04:00
Jean-Philip Desjardins
c12e9d8460
Prevent clobbering of VF0 when using RNEXT or RGET.
2018-05-11 09:32:50 -04:00
Clang-Format
acf75535ec
Clang format
2018-04-30 21:01:23 +01:00
Jean-Philip Desjardins
c590f37475
Add support for VMADDAq.
2017-09-04 18:40:46 -04:00
Jean-Philip Desjardins
b53a39e364
Don't do anything if dest is zero.
2017-08-09 23:05:30 -04:00