Commit graph

83 commits

Author SHA1 Message Date
Herman Semenov
3c66f149d3 [Common/Core/Windows] Removed excess check pointer before delete or free() 2024-09-17 11:34:42 +02:00
Henrik Rydgård
e01ca5b057
Logging API change (refactor) (#19324)
* Rename LogType to Log

* Explicitly use the Log:: enum when logging. Allows for autocomplete when editing.

* Mac/ARM64 buildfix

* Do the same with the hle result log macros

* Rename the log names to mixed case while at it.

* iOS buildfix

* Qt buildfix attempt, ARM32 buildfix
2024-07-14 14:42:59 +02:00
Henrik Rydgård
64ee5675b8 Minor unrelated cleanup 2023-10-06 15:39:59 +02:00
Henrik Rydgård
0d06af87b6 Interpreter: Optimize ReadVector/WriteVector by removing voffset lookups
Drops these functions down the ranking of top functions by quite a bit in GTA,
speedup at most 0.5% though. But enough of these small ones and they
start adding up.

Not sure why GTA falls back to the interpreter for these so much though.
I guess some "uneaten" prefix..
2023-10-05 19:11:34 +02:00
Henrik Rydgård
60a304f29b Turn the ifs inside out 2023-10-05 18:59:56 +02:00
Henrik Rydgård
f21523ff74 WriteVector: Pluck transpose out of the loop 2023-10-05 18:56:15 +02:00
Henrik Rydgård
e852771480 Integrate the voffset shuffle in ReadVector 2023-10-05 18:52:50 +02:00
fp64
49ac4c6774 Clarify 2023-10-02 14:05:49 -04:00
fp64
23e2d0f797 Add SSE2 version of vfpu_dot
See #18249. Speedup for this function ranges 10%..100%,
depending on system. Updated verification and speed measurements:
https://godbolt.org/z/W1z3sj6hz
2023-10-02 12:53:30 -04:00
fp64
dcaca7f111 Fix vrnd to the current understanding
Followup to #17506.
2023-06-04 16:44:27 -04:00
Henrik Rydgård
1ef1478cc8 Remove more impossibilities (GetMtxSize) 2023-06-04 11:48:43 +02:00
Henrik Rydgård
a92cca2575 Don't check for impossibilities. Minor speedup for GetVecSize. 2023-06-04 11:28:39 +02:00
Henrik Rydgård
9db9fec898 VFPU: Some micro-optimizations. Don't fall back to interpreter path for vexp/vlog/vrexp. 2023-06-04 11:28:33 +02:00
fp64
a97c911d46 Address feedback 2023-05-25 17:28:38 -04:00
fp64
23ef21ba9b Fix a bug, and bump savestate version 2023-05-25 16:18:58 -04:00
fp64
71884d5843 Make vrnd match HW closer
See investigation starting
https://github.com/hrydgard/ppsspp/issues/16946#issuecomment-1467261209
for more details.
Still needs more testing.
2023-05-25 14:18:19 -04:00
Unknown W. Brackets
6da10463f9 Debugger: Make reg names safer, stop using v000.
Better to use S000, etc. as that's more clear throughout.
2023-04-29 09:48:33 -07:00
Henrik Rydgård
6945deec01 Replace a LOT of sprintf with snprintf, and a few strcpy with truncate_cpy 2023-04-28 21:04:05 +02:00
Henrik Rydgård
aba026f7e9 Add back our older VFPU approximations, as fallbacks if files are missing.
PR #16984 added more accurate versions of these functions, but they require
large lookup tables stored in assets/.

If these files are missing, PPSSPP would simply crash, which isn't good.

We should probably try to warn the user somehow that these files are
missing, though...
2023-04-03 11:33:41 +02:00
Henrik Rydgård
d996fb74d4 MSVC: Set language standard to c++17.
Noticed that we were getting some new warnings after merging the
constexpr stuff.
2023-04-02 17:55:15 +02:00
fp64
38fc21a2c0 Implement load-on-demand of vfpu tables 2023-03-12 08:21:15 -04:00
fp64
d3be0ee654 Fix tabs vs spaces, tweak comments, error on BE 2023-03-12 08:21:15 -04:00
fp64
67bb17eba3 Add more vfpu_*, move tables to assets 2023-03-12 08:21:15 -04:00
fp64
ee98603fe7 Fix the sign of cos(2*n+1)
Also fix the license text.
2023-03-12 08:21:14 -04:00
fp64
3661bb27ce Implement sin/cos as per #16946 2023-03-12 08:21:13 -04:00
Henrik Rydgård
9e736ca50c Workaround for sin/cos issue in GTA on Mac (and maybe others) 2023-02-07 17:43:12 +01:00
Unknown W. Brackets
a7b7bf7826 Global: Set many read-only params as const.
This makes what they do and which args to use clearer, if nothing else.
2022-12-10 21:13:36 -08:00
Unknown W. Brackets
3f997518f3 irjit: Handle vrot overlap more correctly.
Sine ignores overlap, cosine does not.
2022-10-29 22:25:25 -07:00
Unknown W. Brackets
3df6cb704f Global: Fix some type conversion warnings.
Hidden by some warning disables.
2022-01-30 16:09:33 -08:00
Unknown W. Brackets
a84df2536a Core: Fix vrot cos(2) typo. 2021-04-25 19:26:16 -07:00
Unknown W. Brackets
07cb37c2c1 Compat: Remove single/double sincos path.
New implementation should work for both cases.
2021-04-25 07:09:50 -07:00
Unknown W. Brackets
ad876f06f3 Core: Special case 1/-1 for cosine.
It still gets these off from zero, so let's just special case.
2021-04-24 16:29:20 -07:00
Unknown W. Brackets
8f41c78ed7 Core: Strip off lower bits of sin/cos results. 2021-04-24 16:29:20 -07:00
Unknown W. Brackets
ad9ad0f70b Core: Apply custom narrowing before VFPU sin/cos.
This makes the results much more accurate to the PSP's results.
Could narrow a bit further swapping sin/cos/neg, which might be what the
hardware does given vrot.
2021-04-24 16:29:20 -07:00
Unknown W. Brackets
e9076c90bb Core: Cleanup VFPU float bit handling.
Just to use a common union.
2021-04-24 15:49:22 -07:00
Unknown W. Brackets
f32f89dd90 Global: Remove some unused variables. 2021-02-15 11:59:45 -08:00
Henrik Rydgård
9e4c7c84ac Only use double precision sincos in Hitman Reborn Battle Arena 2. See #12900 2020-11-23 23:51:07 +01:00
Henrik Rydgård
c5e0b799d9 Remove category from _assert_msg_ functions. We don't filter these by category anyway.
Fixes the inconsistency where we _assert_ didn't take a category but
_assert_msg_ did.
2020-07-19 20:33:25 +02:00
Henrik Rydgård
f9ede96344 Address feedback 2019-08-06 16:39:28 +02:00
Henrik Rydgård
8642134419 VFPU-Int: Add a few fast-paths to ReadMatrix/WriteMatrix. Should gain back part of the speed lost in #12217
(which fixed #5399).
2019-08-06 16:29:58 +02:00
Unknown W. Brackets
c1c869df27 interp: Implement software inverse square root. 2019-08-04 21:24:13 -07:00
Unknown W. Brackets
6028b79895 interp: Oops, fix vdot bug with subnormals. 2019-08-04 21:23:19 -07:00
Unknown W. Brackets
13278dc1f4 interp: Implement software sqrt to match PSP.
This matches the PSP's square root better.

Disabled by default using a compile-time flag.
2019-08-04 21:23:04 -07:00
Unknown W. Brackets
7b84be1479 interp: Fix adding infinity in software dot. 2019-08-04 21:17:34 -07:00
Unknown W. Brackets
c61a24cef0 interp: Handle rounding in software dot. 2019-08-04 21:17:27 -07:00
Unknown W. Brackets
d5e572b82e interp: Correct INF * 0 during dot. 2019-08-04 21:17:21 -07:00
Unknown W. Brackets
2ba35c6391 interp: Use an integer multiply for dots. 2019-08-04 21:17:09 -07:00
Unknown W. Brackets
08a894abde interp: Handle NaN better in vfpu_dot. 2019-08-04 21:17:00 -07:00
Unknown W. Brackets
4bff980d34 interp: Use software dot for better accuracy.
This gets some vdot/similar tests to give more accurate results compared
to hardware.  Also added flushing of zero and NaNs.

Currently disabled, only enabled with a compile-time flag.
2019-08-04 21:14:23 -07:00
Unknown W. Brackets
c7e83cd4fa interp: Correct vfim for -inf and similar.
Was dropping the sign bit before for inf and nan.
2019-03-31 13:41:48 -07:00