Ryan Houdek
b0b41d00ee
Various: More static analysis warnings cleanup
...
NFC
2025-03-12 17:27:41 -07:00
Ryan Houdek
a37d6a3841
JIT: Optimize CAS
...
Hey kid, want to see a sick trick?
Finally optimal codegen for 64-bit cmpxchg.
2025-03-07 14:24:45 -08:00
Ryan Houdek
031afbfb18
Various: Adds missing SPDX file headers
...
NFC
2025-03-07 11:34:31 -08:00
Ryan Houdek
66841ce35c
IR: Remove some static analysis warnings
...
NFC
2025-03-05 12:30:27 -08:00
Ryan Houdek
2bf87ff40f
Various: Removes warnings about uninitialized variables
...
NFC. These wouldn't even occur in practice.
2025-03-04 19:59:26 -08:00
Paulo Matos
b5241e0f60
Improve reciprocal estimate and tests
...
3DNow Reciprocal estimations did not have enough accuracy. Tests were enabled
to check for accurate values of reciprocals.
* where needed, reciprocal accuracy was increased.
* 3DNow sqrt reciprocal fixed for negative values.
* New helper VFCopySign IR op added.
Fixes #4319 .
2025-02-27 15:07:14 +01:00
Ryan Houdek
de6931b1f5
OpcodeDispatcher: Emulate SHA1RNDS4 with ARM sha extensions
...
```diff
"sha1rnds4 xmm0, xmm1, 10b": {
- "ExpectedInstructionCount": 55,
+ "ExpectedInstructionCount": 10,
```
So I spent a few hours glaring at this instruction. Then spent a few
more glaring in to the sunset and then found the optimization.
2025-02-22 04:57:58 -08:00
Ryan Houdek
cdf6a16efc
JIT: Implement ARM VSha1SU1 IR operation
2025-02-19 11:33:38 -08:00
Ryan Houdek
bbcd4c168c
JIT: Implement support for VSha256U1 operation
2025-02-18 18:03:31 -08:00
Ryan Houdek
7cd4d53fa9
Fixes some instances of auto usage with unintentional copy
...
Just switch the uses over to `const auto&`
2025-02-12 23:51:57 -08:00
Ryan Houdek
3ef695cf70
JIT: Optimize memory stores with zero
...
Minor optimization but I've seen it around.
2025-02-09 22:50:12 -08:00
Billy Laws
0e11a9b7ac
FEXCore: Don't copy IR after compilation
...
This wastes a significant amount of time when the copies IR is promptly
thrown away after compilation anyway.
2025-02-04 16:52:16 +00:00
Billy Laws
68c77d12d4
FEXCore: Don't delete IRListView move constructor
2025-02-04 16:51:59 +00:00
Tony Wasserka
ebb7137839
IRDumper: Allow const RA data
2025-01-31 15:20:23 +01:00
Paulo Matos
44c65c35c8
Revert "Enable RA of SVE Predicate Registers"
...
This reverts commit fcbf0de05a .
The initial user of this code has been re-implemented in b148cc6c .
This is not needed any longer so we're removing it.
2025-01-29 11:56:19 +01:00
Paulo Matos
0bccb1ece5
Ensure predicate cache is reset when control flow leaves block
...
Whenever the control float leaves the block, it might clobber the
predicate register so we reset the cache whenever that happens.
Fixes #4264
2025-01-27 20:12:43 +01:00
Tony Wasserka
da58e6a597
Fix warnings about unused variables
2025-01-21 12:07:33 +01:00
Tony Wasserka
e54b9237c6
Drop use of assume-asserting logging macros
2025-01-21 12:01:33 +01:00
Paulo Matos
2d53867668
x87 fst/fld optimization for different addrmodes
...
Includes tests and instcountci files and tests.
When the x87 optimizations were implement, we missed
optimizing different addressing modes. This commit addresses this issue.
Discussed in #4252 .
2025-01-14 16:20:33 +01:00
Ryan Houdek
8cfc016b3f
Merge pull request #4265 from pmatos/RevertPredCache
...
Revert pred cache
2025-01-10 12:25:38 -08:00
Paulo Matos
cbda688e29
Revert "Cache predicate register generation from pattern"
...
This reverts commit 72a4063651 .
Caused #4264
2025-01-10 12:52:11 +01:00
Paulo Matos
159ed07e68
Print arg type f80Bit
2025-01-10 09:14:49 +01:00
LC
a6c67ca749
Merge pull request #4251 from Sonicadvance1/ir_numelements_to_elementsize
...
IR: Change convention from number of elements to elementsize
2025-01-04 18:39:24 -05:00
Ryan Houdek
a47ed105e7
x87StackOptimizationPass: Minor opt to f80 fchs and fabs
...
It's faster to load the f80 sign mask from our named vector constants
than synthesizing the values. Changes a 4 instruction sequence to
synthesize to be 1 load.
2025-01-03 13:47:10 -08:00
Ryan Houdek
1ecfa3253d
IR: Change convention from number of elements to elementsize
...
The IR stores elementsize, where the json was wanting number of
elements. While the IR Emitter function declaration always wanted
element size. This was causing us to do a little dance from ElementSize
-> Number of elements -> ElementSize. Just pass the ElementSize directly
instead of this bogus little dance.
2025-01-03 11:01:03 -08:00
Billy Laws
efd6e95059
OpcodeDispatcher: Match x86 overflow behaviour for F2I conversions
...
ARM behaviour here is to saturate on overflow or NaN inputs, whereas
X86 returns a sentinel value of 2^(bitsize-1), explicitly emulate this.
2024-12-30 00:42:55 +00:00
Alyssa Rosenzweig
29405f2690
ConstProp: fix 32-bit masking behaviour
...
if we want to replace a node with one of its sources, we need to zero extend if
the source is 64-bit and the destination is 32-bit.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
2024-12-13 10:44:56 -05:00
Alyssa Rosenzweig
51f505acca
ConstProp: drop some unused headers
...
ycm complained.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
2024-12-13 10:44:56 -05:00
Ryan Houdek
d00d476a0a
IR/Passes: Adds missing comment that clang-format keeps complaining about locally
...
NFC
2024-12-11 15:03:28 -08:00
Paulo Matos
72a4063651
Cache predicate register generation from pattern
2024-12-06 10:15:38 +01:00
Paulo Matos
1d3ce30e50
Generate SVE for 80bit load/stores when possible
...
Fixes #4166 .
2024-12-06 10:15:29 +01:00
Paulo Matos
fcbf0de05a
Enable RA of SVE Predicate Registers
2024-12-02 18:35:31 +01:00
Ryan Houdek
9b6cc8f7e0
IR: Convert OpSize over to enum class
...
NFC
Do the final mopping up to convert the OpSize enum to an enum class!
2024-10-29 16:52:16 -07:00
Ryan Houdek
82f936cb6d
IR: Converts base IR operations to store OpSize sizes
...
NFC
Finally converts the IR operations themselves to store the OpSize for
the IR operation size and element sizes.
This also finally, FINALLY, converts that remaining `_Constant` helper
to stop using a size field that is specified in bits rather than bytes
like all the other IR op handlers. That thing was so confusing and now
it's gone.
2024-10-28 21:26:59 -07:00
Ryan Houdek
034b62292b
Passes/x86StackOptimization: Fixes implicit conversion of OpSize
2024-10-28 19:26:02 -07:00
Ryan Houdek
6cca007817
IR: Fix some missing OpSize conversions
...
Missed these in the previous PR.
2024-10-28 16:25:36 -07:00
Ryan Houdek
65ddae1b71
IR: Change F80VBSLStack to use IR::OpSize
2024-10-28 02:25:17 -07:00
Ryan Houdek
063f524084
IR: Change F80CVTToInt to use IR::OpSize
2024-10-28 02:24:25 -07:00
Ryan Houdek
2dd0a82059
IR: Change F80CVTTo to use IR::OpSize
2024-10-28 02:23:47 -07:00
Ryan Houdek
b810070e9f
IR: Change F80CVTInt to use IR::OpSize
2024-10-28 02:07:20 -07:00
Ryan Houdek
4c7ac17f7d
IR: Change F80CVT to use IR::OpSize
2024-10-28 02:06:48 -07:00
Ryan Houdek
84767c8b20
IR: Change PushStack to use IR::OpSize
2024-10-28 02:05:35 -07:00
Ryan Houdek
eccfb53bd5
IR: Change StoreStackMemory to use IR::OpSize
2024-10-28 02:01:47 -07:00
Ryan Houdek
f4e930262f
IR: Change PCLMUL to use IR::OpSize
2024-10-28 01:50:24 -07:00
Ryan Houdek
d26d9e7e03
IR: Change CRC32 to use IR::OpSize
2024-10-28 01:50:24 -07:00
Ryan Houdek
51c1998d70
IR: Change VAESDecLast to use IR::OpSize
2024-10-28 01:50:24 -07:00
Ryan Houdek
87f818249d
IR: Change VAESDec to use IR::OpSize
2024-10-28 01:50:23 -07:00
Ryan Houdek
d81f92f5e2
IR: Change VAESEncLast to use IR::OpSize
2024-10-28 01:50:23 -07:00
Ryan Houdek
29ffe02afe
IR: Change VAESEnc to use IR::OpSize
2024-10-28 01:50:23 -07:00
Ryan Houdek
dfe4076fe4
IR: Change Vector_F64ToI32 to use IR::OpSize
2024-10-28 01:50:23 -07:00