Compare commits

...

4256 Commits

Author SHA1 Message Date
Connor McLaughlin
99f1ad0ea6 Qt: Fix crash when autobinding controller
Regression from #7016.
2022-09-10 04:40:56 +01:00
JordanTheToaster
11d3326d73 GameDB: Beyond Good and Evil rendering fix
Fixes shield rendering on BGAE.
2022-09-10 02:59:27 +01:00
KrossX
7dd88213b1 Qt: include more entry strings in search 2022-09-09 21:25:49 +01:00
Connor McLaughlin
e0cb165927 LRUCache: Fix Evict() removing too many items 2022-09-09 21:21:14 +01:00
Connor McLaughlin
1e660c8e85 Qt: Fix possible crash when starting game while scanning 2022-09-09 21:21:14 +01:00
Connor McLaughlin
e8704adc67 GzippedFileReader: Don't double open when creating index 2022-09-09 21:21:14 +01:00
Connor McLaughlin
43d6ddd7cf VMManager: Add warning for unsafe settings on boot 2022-09-09 21:21:14 +01:00
Connor McLaughlin
6e0ac7fa75 HostDisplay: Make GL/D3D timestamp queries slightly less rubbish 2022-09-09 21:21:14 +01:00
Connor McLaughlin
800aca6f0f GS/OpenGL: Force UBO reupload on restore api state 2022-09-09 21:21:14 +01:00
Connor McLaughlin
a228582984 Host: Add GetResourceFileTimestamp() 2022-09-09 21:21:14 +01:00
Connor McLaughlin
9f9f8e0e39 GameList: Fix title for ELFs 2022-09-09 21:21:14 +01:00
Connor McLaughlin
3d6f4629e9 PAD: Fix copying input sources 2022-09-09 21:21:14 +01:00
Connor McLaughlin
6fca0dac0e VMManager: Only trigger hotkeys with valid VM 2022-09-09 21:21:14 +01:00
Connor McLaughlin
22e9aea827 Config: Fix frame rate being parsed ever-so-slightly off
Also converts from double to float, we don't need additional precision
for storing these values.
2022-09-09 21:21:14 +01:00
Connor McLaughlin
e064e96c96 HostDisplay: Make global pointer instead of function 2022-09-09 21:21:14 +01:00
Connor McLaughlin
b667236c92 Qt: Combine EmuThread.cpp and QtHost.cpp
These mostly called back between one another.
2022-09-09 21:21:14 +01:00
Connor McLaughlin
e4df563811 Qt: Implement settings reset 2022-09-09 21:21:14 +01:00
Connor McLaughlin
d86abebb50 VMManager: Add SetDefaultSettings()
Also removes the affinity control default for <=2 threads, best to let
the OS handle this.
2022-09-09 21:21:14 +01:00
Connor McLaughlin
1b3bf89ee8 PAD: Split set default controller and hotkey settings 2022-09-09 21:21:14 +01:00
noigeaR
291063bd98 GameDB: Add missing games 2022-09-09 20:04:10 +01:00
TellowKrinkle
4c298ca484 GS: Add zequal to GSScanlineSelector to_string 2022-09-08 19:55:09 -05:00
TellowKrinkle
650dc8bc6a GS: Fix zequal handling in CDrawScanline
I somehow didn't use the same algorithm as the asm version originally
2022-09-08 19:55:09 -05:00
Mrlinkwii
2ee8236365 Gamedb: upscaling fixes for 'Urbz, The - Sims in the City' 2022-09-08 22:30:00 +01:00
JordanTheToaster
4707c02a34 GameDB: Deus Ex various fixes
Adds round sprite half preload frame data and partial texture preloading to Deus Ex.
2022-09-08 21:38:01 +01:00
JordanTheToaster
d0faa14760 GameDB: Death by Degrees FMV line fixes
Adds align sprite to Death by Degrees to fix FMV lines.
2022-09-08 18:28:01 +01:00
Connor McLaughlin
19725deb7e FullscreenUI: Remove accurate DATE option
It doesn't exist anymore.
2022-09-08 12:45:48 +02:00
TellowKrinkle
81cafd21d0 GS:MTL: Don't override GSTexture::Save with a TODO
There's a working default implementation
2022-09-08 02:20:26 -05:00
TellowKrinkle
365c1c3f3e GS:MTL: Implement GPU usage tracking 2022-09-08 02:20:26 -05:00
TellowKrinkle
fbc3120c47 GS:MTL: Ensure prim id init actually writes 2022-09-08 02:20:26 -05:00
TellowKrinkle
66093c3278 GS:MTL: Add barrier counting 2022-09-08 02:20:26 -05:00
Ty Lamontagne
7d4ca441d5 clang-format: pcsx2/IopBios.cpp 2022-09-07 20:54:12 +01:00
Ty Lamontagne
cee8598b3f IOPBios: Hook iomanx library as well as ioman
Fixes fileXio incompatibility
2022-09-07 20:54:12 +01:00
Mrlinkwii
256e845e7a Gamedb: Fix 'Muppets Party Cruise' 2022-09-07 20:46:48 +01:00
lightningterror
f39ac6f58b Qt: Remove Accurate DATE from Qt gui. 2022-09-07 12:17:08 +01:00
lightningterror
a397de448b GS-wx: Remove Accurate DATE from wx gui. 2022-09-07 12:17:08 +01:00
lightningterror
62adad0739 GS-config: Remove Accurate Date from the config. 2022-09-07 12:17:08 +01:00
lightningterror
3d647fe55a GS-hw: Remove Accurate DATE option, no longer needed. 2022-09-07 12:17:08 +01:00
JordanTheToaster
65b0511d9e GameDB: Kikou graphics fixes
Disables mVU flag speedhack to fix broken graphics.
2022-09-07 09:18:30 +01:00
Connor McLaughlin
16a33e42e2 GS/Vulkan: Discard instead of clear for PrimID setup fill 2022-09-07 09:18:11 +01:00
Connor McLaughlin
81c0e000e7 GS/DX12: Discard instead of clear for PrimID setup fill
We're writing the render area anyway.
2022-09-07 09:18:11 +01:00
Connor McLaughlin
d4a5a714fb GS/DX12: Fix incorrect topology on PrimID DATE setup 2022-09-07 09:18:11 +01:00
rufotheone-fr
e60e0c02c0 GameDB: fixes letter B (#6973) 2022-09-07 09:17:28 +01:00
TellowKrinkle
5fa35c5273 CMake:MacOS: Don't strip qt binaries 2022-09-07 01:18:34 -05:00
TellowKrinkle
95ad6b8ab4 GS:DX11: Add primid destination alpha support 2022-09-06 21:07:56 +02:00
TellowKrinkle
1b34eb14f8 GS: Pass through primitive ID in geometry shaders in DX12 and VK
Fixes primid destination alpha on sprites
2022-09-06 21:07:56 +02:00
TellowKrinkle
412480b326 GS: Don't add 10 to date flag to indicate initialization
We already have 1 and 2 dedicated to the job
2022-09-06 21:07:56 +02:00
TellowKrinkle
0500824e57 GS:Vk: Change primitive_id enable to match the new meaning
A bit messy, due to the fact that its support piggybacks on support of other features, instead of having a dedicated feature flag
2022-09-06 21:07:56 +02:00
TellowKrinkle
3e0f3d05e2 GS: Rename image_load_store capability to primitive_id
The algorithm it enables has changed for all renderers, and no longer needs image_load_store
2022-09-06 21:07:56 +02:00
TellowKrinkle
62f9b16139 GS:OGL: Use blend min for primid destination alpha 2022-09-06 21:07:56 +02:00
TellowKrinkle
80523828c7 GS:HW: Properly use primid dst alpha as a fallback to barrier dst alpha
Even when we would have otherwise used barrier over primid if both were supported
2022-09-06 21:07:56 +02:00
PCSX2 Bot
979a105071 PAD: Update to latest controller database. 2022-09-05 18:22:28 +02:00
TellowKrinkle
ea81b74e3b GS:OGL: Add fetch_rt function to shader 2022-09-04 23:02:44 -05:00
TellowKrinkle
1864440f5c GS:OGL: Support disabling texture barrier 2022-09-04 14:47:39 -05:00
JordanTheToaster
b96594b17c GameDB: Corvette game fixes
Adds half pixel offset special aggressive and disables MTVU for Corvette.
2022-09-02 19:38:09 +01:00
Connor McLaughlin
97960a2232 microVU: Fix program dumping 2022-09-02 11:21:30 +01:00
refractionpcsx2
5fc73f87f4 OSD: Correct region2 parameter offset. 2022-09-01 23:19:16 +01:00
JordanTheToaster
8ca5cb18a3 GameDB: General title fixes and adds a gamefix
Corrects some more titles and adds preload frame data to "Takahashi Naoko no Marathon Shiyou yo!".
2022-09-01 16:31:53 +01:00
TellowKrinkle
517f3b7709 GS:HW: Don't skip FBW 0 2022-09-01 11:01:50 +02:00
TellowKrinkle
603f863b71 GS: Don't clamp fbw to 1
fbw zero is a thing
2022-09-01 11:01:50 +02:00
TellowKrinkle
e40a93e389 GS: Don't clamp scissor to fbw
HW tests indicate this doesn't happen
2022-09-01 11:01:50 +02:00
lightningterror
6279ae63ce GS-hw: Remove remaining 24bit destination checks for Ad. 2022-09-01 10:28:42 +02:00
Connor McLaughlin
cb2a21ef19 IopBios: Fix opening host: or host:. as a directory 2022-08-31 21:29:01 +01:00
lightningterror
edc82d77a5 GS-hw: Improve how we handle blending on 24bit with Ad factor in renderer. 2022-08-31 20:34:51 +02:00
TellowKrinkle
e89612e5b9 GS: Use accumulation blend when alpha is known to be 1 2022-08-31 18:17:43 +02:00
rufotheone-fr
9150e69783 GameDB: some title fixes letter A + SCAJ-30004 + SLPM-62346
+ fix "Attheraces Presents Gallop Racer" double space
2022-08-31 15:33:47 +01:00
JordanTheToaster
4b95112724 GameDB: Various title fixes and game fixes
Fixes various titles and adds autoflush to Yumeria.
2022-08-31 11:17:03 +01:00
PCSX2 Bot
b45748fead PAD: Update to latest controller database. 2022-08-30 18:23:29 +02:00
Mrlinkwii
0b3052ced2 Gamedb: fix incorrect korean serials 2022-08-30 14:36:16 +01:00
JordanTheToaster
aae53fb9da GameDB: Fix "Curious George" region
Changes the region from NTSC-Unk to the correct NTSC-HK.
2022-08-30 09:46:35 +01:00
Mrlinkwii
291d32bd35 GameDB: add missing serial for 'Hyper Sports 2002 Winter' 2022-08-30 01:18:51 +01:00
Connor McLaughlin
6386be09c2 CMake: Throw error when building Qt with PACKAGE_MODE
We don't support this.

1. It doesn't make sense to put data in /usr/share since it's not shared between applications.
2. Makes the application not self-contained for easily being moved/removed.
3. Means you can't have multiple versions installed.
4. Every other platform is self-contained (Windows, Mac).
2022-08-29 13:58:22 +01:00
Connor McLaughlin
05bed05afe Frontend: Add fullscreen UI implementation 2022-08-29 13:39:09 +01:00
Connor McLaughlin
5b9d197b7d 3rdparty/imgui: Include imgui_stdlib 2022-08-29 13:39:09 +01:00
Connor McLaughlin
9cce6945e6 Common: Add Image and Easing classes 2022-08-29 13:39:09 +01:00
Connor McLaughlin
33f1e51ebc 3rdparty: Move jpgd from pcsx2 to separate static lib 2022-08-29 13:39:09 +01:00
Connor McLaughlin
d466184a02 MTGS: Support 'running idle', i.e. redisplaying the current frame 2022-08-29 13:39:09 +01:00
Connor McLaughlin
be3f120548 VMManager: Support per-game controller settings
Global bindings will be ignored in such a case.
2022-08-29 13:39:09 +01:00
Connor McLaughlin
2e303da384 Qt: Move pressure modifiers to settings tab 2022-08-29 13:39:09 +01:00
Connor McLaughlin
dfc3fd8e58 VMManager: Add icons to some OSD messages 2022-08-29 13:39:09 +01:00
Connor McLaughlin
51e3ec27d8 VMManager: Clear last elf/serial on shutdown 2022-08-29 13:39:09 +01:00
Connor McLaughlin
1ec76ce248 VMManager: Move semantics for VMBootParameters 2022-08-29 13:39:09 +01:00
Connor McLaughlin
9012afc534 Qt: Forward text input to ImGui 2022-08-29 13:39:09 +01:00
Connor McLaughlin
a19045f9d6 Host: Add ConfirmMessage() and OpenURL() 2022-08-29 13:39:09 +01:00
Mrlinkwii
d18c8976b9 readme: update readme 2022-08-29 13:31:56 +01:00
Mrlinkwii
5485ef4f50 CI: update to 20.04 for WX 2022-08-29 13:31:56 +01:00
TellowKrinkle
f4a56ae106 GHActions:macOS: Use ccache 2022-08-28 18:35:03 -05:00
TellowKrinkle
280316dceb Qt: no-pch support 2022-08-28 18:35:03 -05:00
Connor McLaughlin
9094ee0dc6 D3D11HostDisplay: Migrate to wil 2022-08-27 13:52:12 +01:00
Connor McLaughlin
cad489480c Frontend: Remove unused code 2022-08-27 13:52:12 +01:00
Connor McLaughlin
9655d28a23 Common: Remove unused code 2022-08-27 13:52:12 +01:00
refractionpcsx2
76d3299690 GS-Dumps: Fix Local->Host download size 2022-08-27 02:43:03 +01:00
lightningterror
7b846b42e3 GameDB: Remove R&C 3 patch for ps2 demo disc.
Broke Jak 3 causing it to hard crash.
2022-08-27 01:43:58 +02:00
refractionpcsx2
b8ca60ebd5 DEV9: Codacy fix codacy errors and warnings 2022-08-27 00:33:59 +01:00
refractionpcsx2
ddb9f0b95d SPU2: Codacy fix codacy errors and warnings 2022-08-27 00:33:59 +01:00
refractionpcsx2
93f4277b3c UI-Files: Codacy fix codacy errors and warnings 2022-08-27 00:33:59 +01:00
refractionpcsx2
f841a8ba58 Core: Fix codacy errors and warnings 2022-08-27 00:33:59 +01:00
refractionpcsx2
4d4825de75 GS: Fix codacy warnings 2022-08-27 00:33:59 +01:00
Mrlinkwii
a71bac037c Misc: fix some codacy warnings 2022-08-26 22:58:08 +02:00
lightningterror
02e4e4da01 USB: Cleanup const reference warnings.
Codacy warning: Function parameter should be passed by const reference.
2022-08-26 20:57:57 +02:00
lightningterror
0bf6f9d596 CDVD: Cleanup const reference warning.
Codacy warning: Function parameter should be passed by const reference.
2022-08-26 20:57:57 +02:00
RedDevilus
472c6efc12 GameDB: Re-ordering gshwfix
GameDB: Star Wars Episode 3 re-ordering
2022-08-26 19:32:28 +01:00
lightningterror
66d88ed10b GS: Fix Wunused-but-set-variable, Wunused-variable warnings. 2022-08-26 14:42:37 +02:00
lightningterror
4439b3ad22 PAD: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 14:33:20 +02:00
lightningterror
7c6a838d7f GUI-Wx: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 14:33:20 +02:00
refractionpcsx2
5c951afa64 GameDB: Remove SoftwareFMV switches no longer needed 2022-08-26 09:07:42 +01:00
refractionpcsx2
878e06cd36 GS-HW: Limit BP overlap check to stop FMV flicker.
Games changing the double buffer addresses get screwed up, make sure we don't misdetect
2022-08-26 09:07:42 +01:00
refractionpcsx2
4ef879d1f2 GS-HW: Scale display texture width in TC. 2022-08-26 09:07:42 +01:00
refractionpcsx2
b74f91b868 GS-HW: Expand width on output read if DBX offset 2022-08-26 09:07:42 +01:00
TellowKrinkle
693790a19f GS:MTL: Expand lines and sprites in vertex shader 2022-08-26 01:18:00 -05:00
lightningterror
98724979cb GUI-Wx: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 02:16:00 +02:00
lightningterror
ab430355ec CDVD: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list
2022-08-26 02:16:00 +02:00
lightningterror
060a8f6345 PAD: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list
2022-08-26 02:16:00 +02:00
lightningterror
97aaf3ef9b MemoryCard: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 02:16:00 +02:00
lightningterror
6eb7f5f962 DebutTools: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 02:16:00 +02:00
lightningterror
313fe1ca2c GS: Fix variable initializations.
Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list.
2022-08-26 02:16:00 +02:00
TellowKrinkle
ce34fbe502 3rdparty: Update cubeb 2022-08-25 15:16:46 +02:00
TellowKrinkle
562e9bfebb GS:FindMinMax: sprites use flat Z and color 2022-08-25 15:15:07 +02:00
TellowKrinkle
c2fbe5c606 GS: Fix up FindMinMax handling of swapped lines and final triangles 2022-08-25 15:15:07 +02:00
TellowKrinkle
f53cb0fae7 GS: Reduce FindMinMax instantiation count 2022-08-25 15:15:07 +02:00
JordanTheToaster
9d8b93a269 Revert "GS-hw: Purge MidnightClub3 crc hacks."
This reverts commit f53fbd6282.
2022-08-25 10:39:02 +01:00
raid273
e65ef95027 GameDB: Added memcardFilters to Armored Core - Last Raven 2022-08-24 09:11:48 +01:00
refractionpcsx2
3455c2955f CDVD: Fix integer division on floats and fix logging 2022-08-24 08:43:11 +01:00
JordanTheToaster
4abd395efa GameDB: Major League Baseball 2K5 Hang fix
Adds EE Clamp Extra + Sign to MLB 2K5 and the world series edition.
2022-08-24 08:41:56 +01:00
lightningterror
c332bd198a GS-wx: Remove unused FMVSoftwareRendererSwitch config. 2022-08-24 01:42:28 +02:00
lightningterror
6c395cc07d GS-wx: Set texture preloading to full as default.
Already is on Qt.
2022-08-24 01:37:29 +02:00
lightningterror
7eea2fba9b GS-wx: Update tooltips. 2022-08-24 01:36:37 +02:00
JordanTheToaster
e89115a027 GameDB: Fixing fixes
Fixes some previous fixes so those fixes actually work or don't break the game
2022-08-23 12:18:32 +01:00
refractionpcsx2
00ffa42f50 UI-Qt: Hide Dolby Pro Logic Decoding (It doesn't do anything) 2022-08-23 10:35:55 +01:00
TellowKrinkle
e55825fd88 GHActions:Windows:CMake: Properly exit on failed build 2022-08-23 03:32:26 -05:00
TellowKrinkle
a50a9fcf9a GHActions: CMake builds are SSE4 2022-08-23 03:32:26 -05:00
TellowKrinkle
ce8679a978 CMake: Use full LTO
Speeds up Vulkan backend a bit compared to LTO_PCSX2_CORE, since Vulkan calls into a lot of common methods
2022-08-23 03:32:26 -05:00
TellowKrinkle
5d6348fbf9 CMake: Add GS- flag to MSVC bulds 2022-08-23 03:32:26 -05:00
TellowKrinkle
63e9d47f09 CMake: Add SPU and GS to LTO_PCSX2_CORE LTO 2022-08-23 03:32:26 -05:00
TellowKrinkle
8cc7343201 GHActions: Publish PDB for cmake builds 2022-08-23 03:32:26 -05:00
TellowKrinkle
2aabd54e6a GHActions: Disable buildcache on windows
Not compatible with PDB
2022-08-23 03:32:26 -05:00
TellowKrinkle
bb56f274c8 CMake: Enable PDB generation in Release builds 2022-08-23 03:32:26 -05:00
TellowKrinkle
241d7335e4 SDL2: Remove mac crash workaround for SDL 2.0.22
2.24 is here!
2022-08-23 03:24:57 -05:00
TellowKrinkle
bc7037bb52 3rdparty: Upgrade SDL to 2.24 2022-08-23 03:24:57 -05:00
TellowKrinkle
e7e5814214 3rdparty: Sort SDL vcxproj entries 2022-08-23 03:24:57 -05:00
lightningterror
4c9fbd3fba GS-hw: Cleanup GSRendererHW.cpp.
Constants,duplicate declarations, initializations, null pointers.
2022-08-23 02:38:49 +02:00
PCSX2 Bot
566d397bd1 PAD: Update to latest controller database. 2022-08-22 19:40:29 +02:00
JordanTheToaster
2da65cdd5f GameDB: Add some missing demos
Adds missing demos
2022-08-22 08:49:41 +01:00
JordanTheToaster
e3eae7fbe8 GameDB: Various game fixes and missing entrys
Adds software FMV switch to The Thing JP and texture preloading to partial for Osouji Sentai Clean Keeper H
2022-08-20 23:57:48 +01:00
TellowKrinkle
91601e5647 GS: Manually do bilinear sampling when converting RGBA to depth
Shader bilinear doesn't properly handle the case where r overflows into g (or g overflows into b, etc)
2022-08-20 10:12:24 +01:00
TellowKrinkle
882c09b870 Vulkan: Format convert.glsl 2022-08-20 10:12:24 +01:00
JordanTheToaster
1d7a130bd1 GameDB: Tomb Raider Angle of Darkness effect fixes
Adds autoflush to restore the lava fire effect
2022-08-20 09:53:16 +01:00
iMineLink
202fb5fef3 GS: improve haunting ground hw tc hack.
when clearing the render target, also discard all the dirty
rectangles previously marked, to avoid spurious uploads
later.
2022-08-19 10:55:27 +01:00
JordanTheToaster
f73d7b4cb9 GameDB: Driving Emotion Type-S fixes
Adds VUSyncHack and VU Clamp mode Extra + Sign.
2022-08-19 10:45:04 +01:00
TellowKrinkle
48d3d38e84 GS: Fix wx replayer readbacks
WX runs GS commands directly, so GS isn't open
2022-08-18 20:35:35 -05:00
lightningterror
11c903a3e9 GS: Cleanup GSState.cpp.
constants, scope, duplicate declarations, initializations.
2022-08-18 23:04:13 +02:00
iMineLink
4992659b46 GS: fix out of bounds access to index buffer. 2022-08-18 20:36:46 +01:00
JordanTheToaster
7285eca249 GameDB: Shellshock Nam 67 Upscaling fixes
Adds round sprite half to Shellshock Nam 67
2022-08-17 19:46:13 +01:00
lightningterror
dc8021e952 GS: Fix Wsign-compare warning. 2022-08-17 19:47:48 +02:00
Connor McLaughlin
fb18143791 Qt: Fix newline printed for guest printf on Linux 2022-08-17 19:38:02 +02:00
JordanTheToaster
475551b0d9 GameDB: Interlace and upscale fixes for Cocoto Fishing Master
Adds interlacing Blend BFF and half pixel offset vertex to Cocoto Fishing Master
2022-08-17 00:26:56 +01:00
refractionpcsx2
5447da0588 GS: Don't do blend_mix on HDR 2022-08-16 20:54:55 +01:00
refractionpcsx2
1b18e02fe0 GS: Add constant adjustment in blend mix when reverse subtracting. 2022-08-16 20:54:55 +01:00
KrossX
2e63a4c037 Qt: Add ProLogic decoding audio settings 2022-08-16 20:28:10 +01:00
JordanTheToaster
2d0e0c8fcc Qt: Change name of Adjust to Host Refresh Rate
Changes the name of Adjust To Host Refresh Rate to Scale to Host Refresh Rate.
2022-08-16 19:58:51 +01:00
Daisouji
2b61e10d91 QT: Changing checked to Checked 2022-08-16 19:58:37 +01:00
JordanTheToaster
97ce72ed07 Qt: Add missing description box texts
Adds missing texts descriptions to VSync Internal Resolution Screenshots and Integer Scaling.
2022-08-16 08:44:37 +01:00
refractionpcsx2
fcbf9f7d8f GameDB: Upscaling fix for Naruto Ultimate Ninja 5/Narutimate Accel 2 2022-08-15 20:41:06 +01:00
refractionpcsx2
c2a68aa0b8 GS: Fix bug where incorrect verticles were saved on flush
Probably didn't matter in most cases, but for autoflush draws, it certainly does.
2022-08-15 18:27:09 +01:00
refractionpcsx2
080c70e8a8 GS: Add shortcut for Autoflush on Tri-Strip/Fan 2022-08-15 18:27:09 +01:00
refractionpcsx2
c11030dde5 GS: Improve autoflush detection.
Old way didn't really work with triangles, especially triangle fans.  Some games will be slower, others faster.
2022-08-15 18:27:09 +01:00
JordanTheToaster
a2e6a8e41f GameDB: DBZ Budokai Tenkaichi fixes
Adds half pixel offset special and full round sprite to Dragon Ball Z Budokai Tenkaichi
2022-08-15 15:29:34 +01:00
Mrlinkwii
ec5f614a25 Gamedb: add upscaling fixes to 'Charlie's Angels' 2022-08-15 09:40:03 +01:00
lightningterror
23338319a0 PAD: Fix Wsign-compare warning. 2022-08-14 20:48:04 +02:00
lightningterror
191c7fdf30 GS: Fix Wunused-private-field warning. 2022-08-14 20:48:04 +02:00
refractionpcsx2
1342ed2afe GS: Revert #6838 2022-08-14 16:57:59 +01:00
Left-Empty
69b0193535 gameDB: Kessen 2 NTSC-J refraction patch fix (#6842) 2022-08-14 12:22:04 +01:00
Connor McLaughlin
db2489a555 GS/TextureCache: Fix texture resize in DX11 2022-08-14 03:54:19 +01:00
Silent
b191126f36 Workflows: Download cheats from pcsx2_patches repo on build time 2022-08-14 02:58:10 +01:00
JordanTheToaster
ef0de38624 GameDB: Add various Burnout fixes
Adds various Burnout fixes and adds a missing demo entry for Burnout Revenge
2022-08-14 01:56:46 +01:00
noigeaR
3d0a43d0e7 GameDB: Fix typos in game names 2022-08-13 21:27:52 +01:00
Dreadmoth
874be7ea8b GameDB: Remove half-pixel offset from Mercenaries
Remove half-pixel offset from Mercenaries - it breaks the skybox.
2022-08-13 21:26:45 +01:00
Mrlinkwii
a93034ad59 Gamedb: add fixes for 'World Rally Championship' NTSC-J versions 2022-08-13 17:02:18 +01:00
JordanTheToaster
134cee6adc WX: Change default sound module
Changes the default sound module from XAudio2 to Cubeb to prevent USB crashing and parity with Qt
2022-08-13 16:48:58 +01:00
TellowKrinkle
cb64e8d504 GS:HW: More accurate blend equation for blend mix 2022-08-13 00:01:23 +02:00
JordanTheToaster
35a6dfb52a Config: Change default dump compression
Changes default dump compression from uncompressed to LZMA (xy)
2022-08-12 19:30:08 +01:00
Mrlinkwii
1c276db76f Gamedb: add missing 'Ace Combat 04' entry 2022-08-12 18:13:04 +01:00
Mrlinkwii
400e0f1dd4 Gamedb: add missing Alpine Racer 3 entries 2022-08-11 14:05:57 +01:00
Connor McLaughlin
9a7ed81759 Qt: Improve controller settings and add macro UI 2022-08-10 17:25:11 +01:00
Connor McLaughlin
6f40cf9beb Qt: Only hide global texture offset/skipdraw in release builds 2022-08-10 17:25:11 +01:00
Connor McLaughlin
307028734f Qt: Fix several issues in SettingWidgetBinder
- Possible nullopt value().
 - Incorrect loading of some folder values.
 - Enable per-game setting of spinboxes.
2022-08-10 17:25:11 +01:00
refractionpcsx2
cd2d7c91c3 GS: Add slow path for odd width 4bpp host->local transfers 2022-08-10 16:52:07 +01:00
TellowKrinkle
8b375d66fa GHActions:MacOS: Don't fail on failed brew unlink
If brew can't unlink them, they're not there and there's no need to do anything
2022-08-10 04:28:31 -05:00
JordanTheToaster
8f367abe0b GameDB: Ace Combat 5 Fixes
Adds texture preloading partial to Ace Combat 5 for better performance.
2022-08-10 06:44:20 +01:00
Mrlinkwii
fdc84be0d9 Gamedb: upscaling fixes for Shadow of Rome 2022-08-10 06:44:00 +01:00
BreakPoints
edfceaad14 Qt: Force helpText size to avoid overflow at default size
Increase minimum size of helpText to match max
2022-08-09 15:35:52 +01:00
JordanTheToaster
40fda5067d GameDB: Add DBZ Budokai Tenkaichi 2 fixes
Adds half pixel offset normal to DBZ BT 2 and removes full round sprite to fix the insane amount of ghosting in some areas
2022-08-09 15:33:42 +01:00
lightningterror
573706e5e4 GS-hw: Don't disable second output on blend mix when using constant factor.
We don't want to disable second output when using blend mix1 above 1.0f Af.
Reason is we change Af to As and later output it on second output for hw blending.
2022-08-08 18:11:28 +02:00
PCSX2 Bot
1ef4acc2af PAD: Update to latest controller database. 2022-08-08 18:11:16 +02:00
lightningterror
6035db3231 GS-d3d11: Disable blending when color isn't written.
Fixes d3d11 crashing on mgs3 using intel igpu.
2022-08-08 12:51:17 +02:00
Mrlinkwii
2cd44412f6 Gamedb: upscaling fixes for Poison Pink/ Eternal Poison 2022-08-08 11:21:14 +01:00
JordanTheToaster
c149fe31fb GameDB: Add missing Korean serials
Adds missing Korean serials as well as the accompanying fixes
2022-08-08 04:40:02 +01:00
JordanTheToaster
0e24d638c9 GameDB: Fixes for Devil Kings
Adds Special HPO to Devil Kings
2022-08-07 20:37:31 +01:00
JordanTheToaster
5c056f0c4d GameDB: Add Disaster Report fixes
Adds auto flush to Disaster Report to correct an inaccurate blur filter
2022-08-07 18:57:35 +01:00
lightningterror
62b838427f GS-hw: Purge tri ace crc hacks.
Star Ocean 3, Valkyrie Profile 2, Radiata Stories.

The crc hacks aren't that needed anymore since right now D3D is much faster than it used to be.
2022-08-07 14:13:56 +02:00
BreakPoints
ad529c10ab Qt Updater: Copy new icon to updater
So that the updater benefits from the new icon changes in #6785 (file size, sharpness of small icon sizes)
2022-08-07 13:09:26 +01:00
noigeaR
8ef7399612 GameDB: Add missing Japanese games (#6790) 2022-08-07 13:08:59 +01:00
JordanTheToaster
939c1f0f29 GameDB: Add 007 NightFire fixes
Adds half pixel offset special to 007 NightFire
2022-08-07 13:08:22 +01:00
lightningterror
6b48cf574d GS-hw: Adjust how we handle specific blend mix cases.
Replace Cs*As + Cd*(1 - As) with Cs*As - Cd*(As - 1).
Replace Cs*F + Cd*(1 - F) with Cs*F - Cd*(F - 1).
As - 1 or F - 1 subtraction is only done for the dual source output (hw blending part)
since we are changing the equation.
Af will be replaced with As in shader and send it to dual source output.

Also check if A*Alpha in the shader overflows, if it does then adjust the
alpha that is sent for HW blending further to compensate.
2022-08-07 14:08:04 +02:00
Mrlinkwii
1478819258 GS-hw: Purge SkyGunner crc hacks. 2022-08-07 03:07:04 +02:00
Mrlinkwii
f53fbd6282 GS-hw: Purge MidnightClub3 crc hacks. 2022-08-07 03:06:51 +02:00
lightningterror
60e6e1f242 Qt: Fix Wunused-but-set-variable warnings. 2022-08-07 03:00:22 +02:00
lightningterror
7a5f63e0f5 GS-metal: Move PABE shader bit to the top of sw blending.
Early return when there is no sw blending, no need to run the blend code.
Optimization.
2022-08-06 17:36:24 +02:00
refractionpcsx2
c0e325dfbf GS-HW: Correct FBMask masks for texture shuffles 2022-08-06 12:35:16 +01:00
JordanTheToaster
62e775b7c2 GameDB: Correct The Incredible Hulks name
Corrects the name of the PAL version of The Incredible Hulk and adds missing demo version to the db
2022-08-06 11:52:44 +01:00
BreakPoints
37676a296a UI: Update all sizes of App Icon (#6785) 2022-08-06 10:12:52 +01:00
Connor McLaughlin
bcc4548f7b GS/HW: Clamp draw rect to unscaled, not scaled coordinates
Fixes broken shuffle effect in Haunting Ground when upscale is set above
1x.
2022-08-06 06:13:30 +01:00
JordanTheToaster
60714b5ca4 Qt Updater: Fix use of old icons
Fixes the updater seemingly using the old style of PCSX2 icon.
2022-08-06 00:13:59 +02:00
Mrlinkwii
d632634e56 Gamedb: add basic mipmap to Blood Omen 2 2022-08-05 19:17:14 +01:00
lightningterror
bec8b40edb GS-wx: Remove some unused upscale code for renderer tab. 2022-08-05 11:41:29 +02:00
lightningterror
ab361eef72 GS-wx: Fix Wunused-but-set-variable warning. 2022-08-05 11:37:50 +02:00
Connor McLaughlin
1f16adbca7 GS/Vulkan: Don't use clear attachments on cleared RT/DS
Redundant.
2022-08-05 07:16:53 +01:00
Connor McLaughlin
1677ef3189 GS/TextureCache: Elide copies when source matches target
Assuming everything matches up, instead of copying the target, we can just sample it directly.
It's the same as doing the copy first, except we save GPU time.
2022-08-05 07:16:53 +01:00
Connor McLaughlin
36defdfbe9 GS: Use tex-is-fb for sprites/shuffles 2022-08-05 07:16:53 +01:00
Mrlinkwii
7ba6e4adc3 Gamedb: remove not needed upscaling fixes for God of war 2022-08-05 00:19:55 +01:00
TheLastRar
ee2cbc80b8 DEV9: Sockets: Set Arp Hardware Type 2022-08-03 21:05:40 +02:00
lightningterror
b4d960e795 GS-ogl: Remove bad driver messages for intel/amd.
AMD has new gl drivers which work well now.
For intel it's not really needed as the log may be useful for broadwell or lower igpu.
2022-08-03 20:57:47 +02:00
lightningterror
0f716d9053 GS-hw: Fix dithering log. 2022-08-03 20:54:30 +02:00
JordanTheToaster
cdbfd22296 GameDB: Corrects name of Asterix & Obelix XXL2
Fixes the incorrect name of Asterix & Obelix XXL
2022-08-03 19:34:10 +01:00
Goatman13
de801a4f23 GameDB: Replace Evolution Snowboarding patches.
Instead of skipping videos, patches extend stack in problematic function. So required data is no longer overwritten. Workaround for missing EE data cache emulation.
2022-08-03 11:46:51 +02:00
JordanTheToaster
1376a615b7 GameDB: Misc compat level fixes
Fixes some out of date compat levels
2022-08-03 09:51:23 +01:00
noigeaR
1fbc9ab85e GameDB: add Panzer Elite Action upscaling fix 2022-08-03 09:51:00 +01:00
refractionpcsx2
9a8a3601a7 UI-Qt: Add Bilinear dropdown to SW options 2022-08-02 23:35:48 +01:00
refractionpcsx2
f1e68e9bd0 GS: Don't double res on No-Interlace patch when interlaced 2022-08-02 23:35:35 +01:00
ichee
5228e6e6c7 GameDB: Fixes Dual Hearts FMV's not being deinterlaced
Deinterlacing is not being applied causing the FMV's to be offset. This forces blend tff.

Fixes #6715.
2022-08-02 11:36:24 +01:00
PCSX2 Bot
5b977cef54 PAD: Update to latest controller database. 2022-08-01 23:43:45 +02:00
refractionpcsx2
a802deeb51 GameDB: Add round sprite full for DMC3, reduces blur. 2022-08-01 21:07:30 +01:00
JordanTheToaster
eaf6375410 GameDB: Maximo vs Army of Zin Fixes
Adds fixes and adds a missing entry in the DB for the Korean version.
2022-08-01 16:54:00 +01:00
JordanTheToaster
d1daf21a3f GameDB: Misc fixes
Fixes many problems with many games and adds missing hacks and fixes.
2022-08-01 14:02:13 +01:00
Risae
98c83c8509 GameDB: Add fixes for Growlanser V & Growlanser VI 2022-08-01 09:02:10 +01:00
Mrlinkwii
b25731f621 Gamedb:upscaling fixes for "dot hack Infection Part 1" 2022-07-31 19:50:01 +01:00
Mrlinkwii
563f5ec713 Gamedb: add partial preload to "Hitman Contracts" 2022-07-31 12:36:48 +01:00
refractionpcsx2
ad25ae43d5 GameDB: Disable Instant VU for Juiced 2022-07-31 10:58:51 +01:00
refractionpcsx2
b058e72fdd VIF: Wait for VU on flush + clang format
Improves performance in MTVU + Non-instant a little.
2022-07-31 10:58:51 +01:00
refractionpcsx2
38ee8ccfe3 VU: Fix some bugs, ignore VU's in EE Timing Hack 2022-07-31 10:58:51 +01:00
refractionpcsx2
53161f76a6 VU-MTVU: Simulate VU times when in MTVU w/o Instant VU. 2022-07-31 10:58:51 +01:00
Connor McLaughlin
742a929966 GS: Purge sparse texture
Only worked on a limited number of drivers, not reliable, and not
necessary now that we're reducing target sizes, which works better
anyway.
2022-07-31 10:58:39 +01:00
Connor McLaughlin
63b3646e73 GS/TextureCache: Expand perfect-matched targets for display when needed
Hitman Contracts draws a line near the bottom of the screen, presumably
with a smaller scissor, then scans out 448 lines. Which meant the merge
oversampled and smeared.
2022-07-31 10:39:35 +01:00
refractionpcsx2
794c73a613 GS-debug: Fix GSDumps when rt or ds is null. 2022-07-31 08:21:22 +01:00
JordanTheToaster
59fc2a4c15 GameDB: WRC 4 Fixes
Fixes misaligned text and car shadow softness.
2022-07-30 22:15:44 +01:00
Connor McLaughlin
6a144f86cf GS: Improve target size calcs and remove conservative framebuffer 2022-07-30 17:16:59 +01:00
refractionpcsx2
f218e11d78 GS: Rearrange GS Dump names to be less annoying to navigate 2022-07-30 17:16:35 +01:00
JordanTheToaster
f6bcd8a2c2 GameDB: Various texture preloading fixes
Fixes performance problems when texture preloading is set to Full (Hash Cache).
2022-07-30 17:08:23 +01:00
JordanTheToaster
bf0cd5a6cd Qt: Recommended text fixes
Fixes some missing or incorrect recommended boxes.
2022-07-29 13:42:31 +01:00
tellowkrinkle
fc1504f2e5 GHActions: Properly label Linux AVX2/SSE4 releases 2022-07-28 20:45:23 -05:00
Stuart Kenny
7b4d545dca GameDB: Ridge Racer V upscaling fixes. 2022-07-28 22:27:12 +01:00
JordanTheToaster
89f27d0b2d Qt: Change cycle skipping text
Changes the cycle skipping default level text from "Normal" to "None".
2022-07-28 20:54:55 +01:00
Anderson_Cardoso
3728f42185 GUI-Qt: Updated Controller Image (#6729) 2022-07-28 11:52:03 +01:00
lightningterror
2d6c4c6aee GameDB: Change halfPixelOffset normal to special for shadow hearts series.
Normal breaks shadows.
2022-07-28 12:47:14 +02:00
lightningterror
83b8ec6a99 cheats_ni: Cleanup no interlace patches. (#6717)
Remove widescreen, blur, and other crap patches that shouldn't be here.
Affected crcs 1F34E107,14DDB291,71B142EC,586EA828,64328775,A8D83239
2022-07-27 14:04:16 +02:00
Jordan
5e87f6d806 GameDB: Energy Airforce fixes (#6714)
Adds autoflush to Energy Airforce Aim Strike.
2022-07-26 18:50:27 +02:00
Mrlinkwii
f2da932777 GameDB: Correct title for Mushihimesama 2022-07-26 13:10:30 +01:00
refractionpcsx2
4b3e6d7a58 GS: Flush any pending draws on reset. 2022-07-25 22:04:16 +01:00
Mrlinkwii
c50d671bdb GameDB: add 'VUSyncHack' to Air Ranger - Rescue Helicopter 2022-07-25 19:57:33 +01:00
PCSX2 Bot
5290cbea94 PAD: Update to latest controller database. 2022-07-25 18:12:34 +02:00
Connor McLaughlin
f6b55a4e19 GS/Vulkan: Fix incorrect render pass for stencil DATE 2022-07-25 14:33:09 +01:00
Mrlinkwii
4e0d2207a3 GameDB: add gamefixes to cod 2 and fix titles 2022-07-25 00:53:13 +01:00
icup321
f089d5714f GameDB: Add mipmap fixes to Toshi engine games (#6680) 2022-07-24 16:24:00 +01:00
Connor McLaughlin
be26c04dd1 Qt: Asynchronous loading of covers 2022-07-24 16:22:37 +01:00
Connor McLaughlin
cbcfe37e28 Common: Add LRUCache 2022-07-24 16:22:37 +01:00
Connor McLaughlin
ef0fde8615 CI: Use Qt 6.3.1 for all platforms 2022-07-24 16:22:37 +01:00
Connor McLaughlin
cc728642ed Qt: Allow changing theme without recreating window 2022-07-24 15:42:29 +01:00
Connor McLaughlin
d9360a66af Qt: Fix bindings not applying after profile load/reset 2022-07-24 15:15:27 +01:00
Connor McLaughlin
4040f7afca Qt: Fix game list not resizing after resize+shutdown game 2022-07-24 15:15:27 +01:00
JordanTheToaster
758c347258 GameDB: GoW Fixes 2022-07-24 14:20:31 +01:00
JordanTheToaster
cf76a605d2 GameDB: Arean Football fixes 2022-07-24 10:00:34 +01:00
refractionpcsx2
1cfcfc465e GS: CLUT Invalidation on transfer accounts for offset. 2022-07-24 10:00:14 +01:00
refractionpcsx2
fc611dee57 GS-PCRTC: Remove frame offset from anti-blur hacks in software.
Turns out this is now more detrimental than an improvement
2022-07-24 09:59:58 +01:00
refractionpcsx2
de8b23db4e GS-SW: Fix framebuffer looping at 2048 height.
Also limit height read on hardware to 2048
2022-07-24 09:59:58 +01:00
Jordan
b036dcece6 GameDB: Urban Chaos fixes. (#6690) 2022-07-23 22:08:06 +02:00
BreakPoints
94c83245db GameDB: Missed R&C3 and R&C4 Fixes
Adds fixes for bloom from #6688 to remaining R&C3 and R&C4 entries
2022-07-23 16:15:51 +01:00
JordanTheToaster
c14146926a GameDB: Add COP2 patch 2022-07-23 00:13:43 +01:00
JordanTheToaster
29dffd06b3 GameDB: R&C3 and R&C4 Fixes 2022-07-22 21:35:11 +01:00
JordanTheToaster
9646d18624 GameDB: Urban Reign fixes 2022-07-22 16:37:20 +01:00
lightningterror
170d9a27ff cheats_ws: Disable unnecessary patches.
60 fps, progressive, interlace, ghosting, blur, drain, draw distance, skip draws and more.

Shouldn't be here to begin with.
2022-07-22 10:49:56 +02:00
JordanTheToaster
4d43374b31 GameDB: God Of War 2 Fixes 2022-07-22 09:30:41 +01:00
NicknineTheEagle
085332da27 GameDB: Fix glows in Disney-Pixar Ratatouille. (#6597)
Enable Auto Flush GS HW hack in Disney-Pixar Ratatouille.
2022-07-22 03:56:25 +02:00
rufotheone-fr
4dae3ee33b GameDB: check & fix of titles + add of missing serial (numbers) (#6681) 2022-07-21 17:44:37 +01:00
Daisouji
dd729ec649 QT: Change Pathing
Formatted MainWindow.cpp code
2022-07-21 11:59:00 +02:00
Daisouji
9ef582bd6f QT: Implements 2 Theming options
Added 2 New Theme options.
2022-07-21 11:59:00 +02:00
rufotheone-fr
a4fec6323c GameDB: Addition of missing serials and fixes of some titles. (#6678) 2022-07-21 02:23:29 +02:00
Alban Zekthi
4e9d56441a GameDB: Game title and Ace Combat updates. (#6600)
Fixed some game titles; added halfPixelOffset: 3 to Ace Combat 5 and Zero; adding mergeSprite: 1 to all Ace Combat
2022-07-21 02:20:33 +02:00
JordanTheToaster
af71ae9dd9 QT: Add missing gamefix dialog 2022-07-20 21:35:08 +01:00
Mrlinkwii
305563e44f Gamedb: GShw fixes for Spider-Man 2 2022-07-20 12:47:55 +01:00
lightningterror
f042fd2e88 GS-config: Remove AA1 toggle config leftovers. 2022-07-20 00:32:42 +02:00
lightningterror
5a13932dd9 GS: Remove AA1 gui condition, it will always be enabled. 2022-07-20 00:32:42 +02:00
lightningterror
06c9967971 Qt: Remove AA1 option from the gui. 2022-07-20 00:32:42 +02:00
lightningterror
6e8d667c6a Wx: Remove AA1 option from the gui. 2022-07-20 00:32:42 +02:00
noigeaR
0529ce2bc4 GameDB: Fix and add Japanese game names, apply upscaling fixes 2022-07-19 22:43:41 +01:00
kenshen112
639552ae8f CDVD: Change CDVDaccess to CDVDcommon 2022-07-19 22:36:31 +01:00
JordanTheToaster
0d1cc8581a QT: Change MTVU recommendation 2022-07-19 21:49:41 +01:00
PCSX2 Bot
ed54b55a63 PAD: Update to latest controller database. 2022-07-19 00:35:42 +02:00
C.W. Betts
12d8a1f92e fix build error when recording is disabled. 2022-07-18 10:49:09 +01:00
refractionpcsx2
ed76e54904 GS: Move force_a_one to IsCoverageAlpha function 2022-07-18 09:40:21 +01:00
refractionpcsx2
c2bb936586 GS-HW: Added DATE check for AA1
Also fix bug when DATE+FBA is on and alpha is masked (rare)
2022-07-18 09:40:21 +01:00
refractionpcsx2
42b334efcd GS-HW: Use correct alphas when AA1 is enabled + ABE disabled. 2022-07-18 09:40:21 +01:00
Mrlinkwii
56367f257a Gamedb: clean-up game titles 2022-07-18 09:35:04 +01:00
refractionpcsx2
55db243362 GUI-Qt: Avoid divide by zero on empty gamelist folder. 2022-07-18 08:47:57 +01:00
refractionpcsx2
395f4e904c GUI-Qt fix full screen toggle hotkey 2022-07-18 01:52:26 +01:00
Connor McLaughlin
3c5a39a99a GS/OpenGL: Fix incorrect detection of DXT/BPTC texture support 2022-07-17 23:40:24 +01:00
rufotheone-fr
572c3be647 GameDB: Update names for localisation (#6661) 2022-07-17 23:40:05 +01:00
Connor McLaughlin
06e7d6c3df Qt: Hide system console if enabled in nogui mode 2022-07-17 23:29:48 +01:00
Connor McLaughlin
bcde888257 Qt: Restore geometry before going fullscreen
Fixes fullscreen with separate window on another monitor popup switching
the fullscreen monitor case.
2022-07-17 23:29:48 +01:00
Connor McLaughlin
1767213321 Qt: Fix CRC in game list showing in lowercase 2022-07-17 23:29:48 +01:00
Connor McLaughlin
b36b4e4ad1 Qt: Hide main window when in fullscreen 2022-07-17 23:29:48 +01:00
Connor McLaughlin
8857eb4e78 Qt: Fix state not being saveable on separate window close 2022-07-17 23:29:48 +01:00
Connor McLaughlin
fce3414c65 INISettingsInterface: Don't try to save with no filename 2022-07-17 23:29:48 +01:00
Connor McLaughlin
f0f23a2c61 Qt: Elide redundant scan progress updates
Fixes UI locking up for ages when switching theme.
2022-07-17 23:29:48 +01:00
Connor McLaughlin
a77f78f08f Qt: Replace hotkey tabs with a scrollable view 2022-07-17 23:29:48 +01:00
Connor McLaughlin
9269792a8c Qt: Move hotkeys to VMManager, remove sorting 2022-07-17 23:29:48 +01:00
Connor McLaughlin
e87d507c0c GameList: Populate game list from cache in batch mode
Stop-gap until we make CDVD/scanning thread-safe, and can create game
list entries on demand.
2022-07-17 23:29:48 +01:00
Connor McLaughlin
5fc07180dd Qt: Add -nogui command line parameter 2022-07-17 23:29:48 +01:00
Connor McLaughlin
a35990ee4c Qt: Move Main.cpp to QtHost.cpp 2022-07-17 23:29:48 +01:00
Connor McLaughlin
7d71954674 Qt: Add search/filter toolbar 2022-07-17 23:29:48 +01:00
Connor McLaughlin
1cee55bf45 Qt: Fix game list glitching out in X11 2022-07-17 23:29:48 +01:00
Connor McLaughlin
c11ca2ff64 GS/TextureCache: Remove redundant CLUT read 2022-07-17 16:23:49 +01:00
Connor McLaughlin
f88756cb53 Qt: Add crop options 2022-07-17 15:34:20 +01:00
JordanTheToaster
54d284cdac GameDB: MGS 2 texture preload to partial 2022-07-17 12:23:57 +01:00
Mrlinkwii
011d6bebfa Github: clean-up issue templates 2022-07-16 21:41:58 +01:00
Mrlinkwii
447dc54710 Gamedb: missing serial 2022-07-16 21:38:34 +01:00
refractionpcsx2
e2ff6327eb IPU: Adjust timing on IDEC/BDEC after IPU0 transfer 2022-07-16 18:43:19 +01:00
macmmm81
a293b6fc77 Periodication 2022-07-16 11:16:03 +01:00
macmmm81
e56ffc689d GameDB: add The Sims 2 missing fixes 2022-07-16 11:16:03 +01:00
macmmm81
4cca6a72d8 GameDB: add The Sims 2 missing fixes 2022-07-16 11:16:03 +01:00
Mrlinkwii
6e79b29678 GameDB: various GSHWFixes 2022-07-16 04:07:39 +01:00
noigeaR
a432ffc0ce GameDB: fixes for Taiko no Tatsujin series
Correct names and add fixes for hw rendering and upscaling for the Taiko no Tatsujin series
2022-07-16 04:04:04 +01:00
lightningterror
205cb2c29d iCore: Fix more negative array index warnings.
Forgot these.
Codacy.
2022-07-15 17:50:41 +02:00
lightningterror
1594b46f68 iCore: Fix negative array index warning.
Codacy.
2022-07-15 15:55:38 +02:00
lightningterror
e1e7791dff Core: Bump savestate version. 2022-07-15 15:55:38 +02:00
lightningterror
d3accbc085 USB: Fix struct member 'structname::variable' is never used warnings.
Codacy.
2022-07-15 15:55:38 +02:00
lightningterror
69cc5a559e PAD: Fix struct member 'structname::variable' is never used warnings.
Codacy.
2022-07-15 15:55:38 +02:00
lightningterror
9f8f2f6730 GS-tc: Fix condition is always true warning.
Codacy.
2022-07-15 15:55:38 +02:00
lightningterror
498eb9330b USB: Fix array index 'i' is used before limits check warning.
Codacy.
2022-07-15 15:55:38 +02:00
lightningterror
6047322f0c USB: Fix a condition is always false warning.
Codacy.
2022-07-15 15:55:38 +02:00
rufotheone-fr
2ce6a031a4 Update GameIndex.yaml 2022-07-15 12:33:44 +01:00
rufotheone-fr
323bab7d4a Update GameIndex.yaml 2022-07-15 12:33:44 +01:00
refractionpcsx2
73f45b8772 GS-OGL: Remove wide line support (deprecated in OGL Spec). 2022-07-15 13:19:41 +02:00
BuildTools
a9407f055c GameDB: Disable texture preloading in Xenosaga Episode III 2022-07-15 11:05:33 +01:00
MetrosexualGarbodor
2eb1134828 GameDB: remove texture inside RT from Xenosaga Episode III 2022-07-14 15:14:03 +02:00
Mrlinkwii
7e35571b94 Gamedb: autoflush for Burnout Dominator/ Revenge 2022-07-13 20:13:05 +01:00
Mrlinkwii
19f7e3631a Gamedb: add missing MGS3 HWfixes 2022-07-12 21:09:08 +01:00
Mrlinkwii
094f2da774 Gamedb: add EEclamping for "Cowboy Bebop" and autoflush for burnout 3 2022-07-12 20:28:57 +01:00
Goatman13
1b9d22a491 GameDB: Remove Musashi SPS patches/fixes.
No needed anymore.
2022-07-12 10:02:28 +01:00
Goatman13
df1e19dd47 COP2: Fix CTC2 to R register
Only 23 bits are writable. Upper 9 bits are hardcoded to 001111111.
2022-07-12 10:02:28 +01:00
github-actions[bot]
8c4fa838fe PAD: Update to latest controller database. (#6610)
Co-authored-by: PCSX2 Bot <PCSX2Bot@users.noreply.github.com>
2022-07-11 18:11:17 +02:00
refractionpcsx2
2f6df2f9af GS: Fix scanmask interlace offsetting on even numbers 2022-07-11 15:16:11 +01:00
refractionpcsx2
446b0c2dfa GS: CLUT - check the whole page range of transfer for CLUT clear. 2022-07-11 12:19:32 +01:00
refractionpcsx2
0eb963d491 GS: Remove needless flush check on Host->Local write. 2022-07-10 17:50:05 +01:00
refractionpcsx2
156484ac80 GS: Invalidate CLUT by page
Some games (We Love Katamari) write offset inside the CLUT, and one block is only 32 colours (in 32bit) anyway, so by block is insufficient.

Also add check for CLUT invalidation from Z writes, because it *could* happen, weirder things have been done in games.
2022-07-10 17:50:05 +01:00
Mrlinkwii
6511d4c21c GameDB: fix memcard filters 2022-07-10 09:31:36 +01:00
BuildTools
e2a8c70f3d UI: Minor typo fixes 2022-07-09 22:26:58 +01:00
Mrlinkwii
53386e4d42 Gamedb: fix game titles 2022-07-09 22:26:39 +01:00
Jordan
d82d25cc10 Patches: Cleanup more ws patches. (#6595)
Removes more 60 fps codes.
2022-07-09 14:49:26 +02:00
Mrlinkwii
d79b4b2352 Gamedb: fix up game names and add HWfixes 2022-07-08 12:29:35 +01:00
refractionpcsx2
a206187802 GS: Improve clut testing, add test for local->local transfers.
Fixes Sagashi ni Ikouyo which does local->local transfers in to the CLUT so it needs flushing.
2022-07-08 11:58:21 +01:00
Mrlinkwii
e48e810005 QT: set Texture Offsets & Skipdraw Range per game only 2022-07-08 11:05:59 +01:00
Connor McLaughlin
fbac3ebad1 GS/TextureCache: Fix incorrect hashing of L/H/small textures
Fixes text getting garbled in Valkyrie Profile 2 with preloading on.
2022-07-07 12:09:40 +01:00
Jordan
c88a042c8b Patches: Cleanup cheats_ws. (#6577)
60 fps hacks do not belong in the widescreen patches archive.
2022-07-06 23:29:41 +02:00
Mrlinkwii
a78d76d143 QT: more missing descriptions 2022-07-06 20:57:36 +01:00
BuildTools
33ea0af06f Patches: Misc cheats_ni cleanup
Patches: Misc cheats_ni cleanup
2022-07-06 01:17:01 +01:00
Mrlinkwii
55a15f5a21 QT: more settings descriptions 2022-07-06 01:16:41 +01:00
Daisouji
3dd5a32cc0 QT: Adds descriptions to OSD/Post Processing Settings (#6571)
Co-authored-by: Ty <AmFobes@gmail.com>
2022-07-05 23:52:27 +01:00
Pyra Drake
0df86c6aaf GameDB: EA Sports BIO FolderMC Support (#6575) 2022-07-05 19:47:36 +01:00
Mrlinkwii
383ff6c234 QT: more missing descriptions 2022-07-05 18:02:27 +01:00
Connor McLaughlin
2cf920a1d4 CI: Add AppImage builder for Qt 2022-07-05 13:05:57 +01:00
Connor McLaughlin
dc8bb7cc2f Qt: Use same data directory as wx with XDG_STD enabled 2022-07-05 13:05:57 +01:00
Connor McLaughlin
cfe51035fb CMake: Drop unused ALSA dependency 2022-07-05 13:05:57 +01:00
Connor McLaughlin
a2afbd3080 Qt: Make status bar less confusing 2022-07-05 13:04:40 +01:00
Connor McLaughlin
dcb17243f8 ThreadedFileReader: Fix a low-chance race when closing file 2022-07-05 13:04:26 +01:00
Connor McLaughlin
6e706b3a8c Qt: Implement mouse wheel binding 2022-07-05 13:04:03 +01:00
PCSX2 Bot
f5e3d79cc7 PAD: Update to latest controller database. 2022-07-04 19:05:46 +02:00
Mrlinkwii
1febfa4f4e QT: settings descriptions 2022-07-04 11:39:18 +01:00
BuildTools
9601d0fc45 Patches: Update Persona 4 WS Patch 2022-07-04 09:57:33 +01:00
Connor McLaughlin
9f8f0262c7 Qt: Show disabled hw fixes in OSD 2022-07-03 03:59:04 +01:00
Mrlinkwii
e718a4f843 Gamedb: upscaling fixes for Kingdom Hearts - Final Mix 2022-07-02 23:50:41 +01:00
lightningterror
2257103ee6 GS-hw: Fix Wunused-but-set-variable warning. 2022-07-02 22:29:52 +02:00
Mrlinkwii
9e58aafa4a Gamedb: fixup wrong titles and add game fixes 2022-07-02 15:30:54 +01:00
BuildTools
a13096bdfe Config: Set texture preloading to full by default 2022-07-02 14:44:22 +01:00
Connor McLaughlin
53c3958b2b 3rdparty: Remove ghc::filesystem 2022-07-02 06:21:30 +01:00
Connor McLaughlin
bbc0bcae1e IopBios: Replace ghc::filesystem with our wrappers 2022-07-02 06:21:30 +01:00
Connor McLaughlin
2b52bf4539 DEV9: Replace ghc::filesystem with our wrappers 2022-07-02 06:21:30 +01:00
refractionpcsx2
40f315a259 GS: Fix CLUT changing bit depth.
This usually means the storage method changes with it, so it's a good idea to reload it
2022-07-01 17:10:26 +01:00
refractionpcsx2
f191915b53 GS: Adjust CLUT dirty checks to reduce false positives 2022-07-01 13:56:55 +01:00
lightningterror
cb0e79972d GS: Fix default config for UserHacks_CPUSpriteRenderBW for wx build. 2022-06-30 21:23:44 +02:00
Ty Lamontagne
2a980d9fc0 IOPBios: Make our hostfs HLE safer
For example, if you mkdir a path that is taken by an existing _file_, GHC would throw an exception and crash the emulator.
2022-06-30 01:19:12 +01:00
Connor McLaughlin
6daeb56550 GS: Support using SW renderer for texture decompression sprites 2022-06-29 14:03:16 +01:00
Connor McLaughlin
65ae3e1d8d Qt: Make mouse mapping opt-in (less annoying) 2022-06-29 11:55:58 +01:00
Connor McLaughlin
403b93daf6 Qt: Fix drag/drop of blockdumps 2022-06-29 11:55:58 +01:00
Connor McLaughlin
ff0380b456 Qt: Fix drag/drop of GS dumps/ELFs 2022-06-29 11:55:58 +01:00
Connor McLaughlin
e7bb6c8767 PAD: Adjust existing button pressure when modifier activated 2022-06-29 11:55:58 +01:00
MomosuWarosu
f9c7b4e441 GameDB: Upscaling fixes and region corrections for Armored Core 3/Silent Line 2022-06-29 09:34:43 +01:00
Connor McLaughlin
0540b8e1ad GS: Switch to placeholders for VM repeat mapping in Qt
This is not reliant on having larger gaps in the virtual address space,
and should never fail.
2022-06-29 09:18:20 +01:00
Connor McLaughlin
fcde6f686e Build: Bump _WIN32_WINNT to Windows 10 and link against OneCore
Necessary for us to utilize the new WinAPI functions. We just need to be
careful not to call any of these in wx, because otherwise it'll no
longer run on Win8.
2022-06-29 09:18:20 +01:00
Connor McLaughlin
444dce4aeb PAD: Fix incorrect MAX_KEYS check 2022-06-29 09:04:30 +01:00
Connor McLaughlin
1a0b8fb37f Qt: Fix window reopening after close 2022-06-29 09:04:30 +01:00
Connor McLaughlin
4fcc8abf55 Qt: Add pressure modifier button for pads 2022-06-29 01:09:29 +02:00
Connor McLaughlin
131b92e9fe Qt: Implement remove disc 2022-06-28 20:01:42 +01:00
Connor McLaughlin
5391b529b6 Qt: Implement start disc 2022-06-28 20:01:42 +01:00
Connor McLaughlin
92aea38230 GS: Reset stats on open
Fixes junk/bogus stats when switching to/from software renderer, and
when shutting down/starting a new game.
2022-06-28 20:01:42 +01:00
Connor McLaughlin
590ca98463 Qt: Implement pause on focus loss 2022-06-28 20:01:42 +01:00
Connor McLaughlin
16936aa452 Qt: Make UI thread VM valid/paused globally accessible 2022-06-28 20:01:42 +01:00
Connor McLaughlin
dedb1e0c80 Qt: Implement pause on start 2022-06-28 20:01:42 +01:00
Connor McLaughlin
63163737c2 Qt: Implement disable window resize 2022-06-28 20:01:42 +01:00
Connor McLaughlin
9f99e88c92 Qt: Fix game properties staying open after closing main window 2022-06-28 20:01:42 +01:00
Connor McLaughlin
b6f748ad8f Qt: Add option to hide main window when game running 2022-06-28 20:01:42 +01:00
Mrlinkwii
1f3f70a642 GameDB: fix game titles and add an entry 2022-06-28 20:01:20 +01:00
dio-gh
edfb59a87d Add MacOS badge to the README 2022-06-28 18:48:23 +01:00
refractionpcsx2
999b01c814 GS: Fix interlace offset for native. 2022-06-28 15:47:36 +01:00
refractionpcsx2
e7f52cbf98 GS: Fix interlace offsets for no-interlace patches 2022-06-28 09:57:23 +01:00
Mrlinkwii
311d1c805d Gamedb: add VUclamping to "NCAA March Madness 2003/2004" 2022-06-28 10:43:24 +02:00
lightningterror
2908c97432 Qt: Fix anti blur tooltip. 2022-06-28 10:35:48 +02:00
lightningterror
122423e535 Qt: Add tooltlips to System Settings. 2022-06-28 10:35:48 +02:00
lightningterror
639865f3e2 Qt: Add tooltlips to Advanced System Settings. 2022-06-28 10:35:48 +02:00
lightningterror
42e214eb17 Qt: Add tooltips to Emulation Settings. 2022-06-28 10:35:48 +02:00
refractionpcsx2
73c29d44c3 GS: Don't vmalloc inside fifo_alloc to avoid logic confusion.
Also remove a pointless check from my previous COP2 fix.
2022-06-28 09:29:47 +01:00
chaoticgd
ab6148f0b4 Config: Fix loading of SavestateZstdCompression setting
It seems like when the setting was originally added, the author
forgot to add a line to the Pcsx2Config::CopyConfig function which
meant that the setting was not loaded properly.
2022-06-28 09:13:41 +01:00
refractionpcsx2
bf0243c253 iR5900: Ignore Non delayed COP2 commands when not interlocked 2022-06-27 23:32:25 +01:00
PCSX2 Bot
b53c9daf50 PAD: Update to latest controller database. 2022-06-27 22:15:10 +02:00
refractionpcsx2
7fa482e5c6 GS: Adjust interlacing offsets to something more sensible. 2022-06-27 19:35:43 +01:00
refractionpcsx2
391bd119b8 VU: Don't clamp VF00 or I Reg 2022-06-27 14:44:57 +01:00
Connor McLaughlin
cdd9b1fa3b iR5900: Elide VU0 micro finish calls when safe
This makes a difference in COP2-heavy games, where a chain of
instructions will repeatedly test the VU0 idle bit unnecessarily, as it
is impossible for a micro to be started inbetween the instruction chain.

Saves a bit of code size (for register backup/restore), as well as
getting rid of branches. Seems to make a 1-2% difference in performance
in Ratchet on a 3900X, but if we're lucky, more on slower chips.
2022-06-27 14:44:48 +01:00
dependabot[bot]
99487d0e2b Bump mikehardy/buildcache-action from 1.2.2 to 1.3.0
Bumps [mikehardy/buildcache-action](https://github.com/mikehardy/buildcache-action) from 1.2.2 to 1.3.0.
- [Release notes](https://github.com/mikehardy/buildcache-action/releases)
- [Changelog](https://github.com/mikehardy/buildcache-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/mikehardy/buildcache-action/compare/v1.2.2...v1.3.0)

---
updated-dependencies:
- dependency-name: mikehardy/buildcache-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-27 12:11:32 +02:00
Mrlinkwii
5ff98258df GameDB: fix up wrong titles 2022-06-27 00:21:10 +01:00
lightningterror
41bc4832f3 USB: More variable scope warnings.
Looks like there are still more, let's see if it complains more about this file.
Codacy.
2022-06-26 19:23:49 +02:00
BuildTools
69dbb2e17c Readme: Update Linux version 2022-06-26 19:03:11 +02:00
lightningterror
3dbaf96a9a USB: Cleanup more variable scope warnings.
Codacy.
Looks like I missed some.
2022-06-26 19:02:08 +02:00
Ty Lamontagne
15d8b891d6 Core: Replace old include guard with pragma once 2022-06-26 12:42:10 +02:00
Connor McLaughlin
efc09a7b47 GS/TextureCache: Unswizzle shared texture formats when hashing
Fixes formats such as PSMT4HL giving different hashes depending on what
the overlapping/shared pixels in local memory contain.

Enable this unconditionally, rather than only when dumping, because
unswizzling and hashing is around 25% faster on AVX2 builds than hashing
the backing local memory for larger textures (e.g. Star Ocean 3 menus).
Also has the added bonus of hitting the cache more often in such cases
too.
2022-06-26 03:08:57 +01:00
refractionpcsx2
6e84e5ce9c VU: YOLO T-Bit on MTVU
More games than I expected just turn T-Bit on but never actually use it, which causes poor performance in MTVU due to threading.  If there is a game that uses it, we can disable MTVU in the GameDB, since it will break the performance of the game, even if we try to handle it correctly.

Maybe we can re-enable it in the future if some threading genius figures it out.
2022-06-25 16:54:42 +01:00
refractionpcsx2
7d5d2b86cf GS: Don't do interlace offset if de-interlacing is disabled. 2022-06-25 16:46:59 +01:00
Mrlinkwii
e887600c7e Gamedb: Fix game names 2022-06-25 16:14:35 +01:00
refractionpcsx2
8216faae6e IPU: Fix GT3 regression from #6506
BTW it was totally not my suggestion to change it and I take no responsibility for the fact I bro.. I mean LT broke it.
2022-06-25 16:01:39 +01:00
lightningterror
8c1b9e1557 GS-hw: Fix redundant condition warning.
Codacy.
2022-06-25 13:26:46 +02:00
lightningterror
57595c70b0 PAD: Fix expression is always false warning.
Codacy.
2022-06-25 13:26:22 +02:00
lightningterror
cf568d2782 iR5900: Cleanup variable scope.
Codacy.
2022-06-25 11:20:53 +02:00
lightningterror
ba07e46cf8 iR3000A: Cleanup variable scope.
Codacy.
2022-06-25 11:20:53 +02:00
lightningterror
f19ba1b0db iFPUd: Cleanup variable scope.
Codacy.
2022-06-25 11:20:53 +02:00
lightningterror
51887f1cbc BaseBlockEx: Cleanup variable scope.
Codacy.
2022-06-25 11:20:53 +02:00
refractionpcsx2
539e285f86 GS: Limit the offset for FFMD to prevent over scaling. 2022-06-25 02:53:09 +01:00
refractionpcsx2
75d57640eb GS: Rework interlace offsets 2022-06-25 02:53:09 +01:00
refractionpcsx2
56316ffcca GS: Add internal FFMD offset to interlace. 2022-06-25 02:53:09 +01:00
Mrlinkwii
580dbd0905 Gamedb:Add missing serials 2022-06-25 02:29:43 +01:00
Mrlinkwii
42a394628e GameDB: upscaling fixes for "Mike Tyson Heavyweight Boxing" 2022-06-24 23:29:51 +01:00
lightningterror
0233845994 USB: Cleanup uninitialized variable.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
f42647426b IOP: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
b54521de51 iR5900: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
d7e09167fa iMMI: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
26d20e458c iFPU: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
3099d55b40 RDebug: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
72218929b9 SPU2: Cleanup variable scope.
Codacy
2022-06-24 23:32:30 +02:00
lightningterror
f99106ccb1 MemoryCardFolder: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
dd6f9c5ad3 USB: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
7d2209860e IPU: Cleanup variable scope.
Use totalqwc instead of ipu1cycles for adding cycles.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
c82a927556 GS: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
59e9d80b18 PAD: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
732d30c919 CDVD: Cleanup variable scope.
Codacy.
2022-06-24 23:32:30 +02:00
lightningterror
8586490162 Misc: Cleanup some stuff I didn't notice in previous commits. 2022-06-24 02:22:40 +02:00
lightningterror
f8a3cf2d3d README: Update requirements. 2022-06-24 02:17:38 +02:00
lightningterror
826ca5ece5 GS-hw: Update crc hack comments. 2022-06-24 01:20:28 +02:00
refractionpcsx2
73a3542ab2 Build: Fix appimage.sh 2022-06-23 23:25:46 +01:00
lightningterror
dfbe243b4c Misc: Clean up warnings.
Wsign-compare, Wunused-variable, Wunused-variable.
2022-06-23 22:48:07 +02:00
Stuart Kenny
f7d76ebf1d GS: Add lottes crt to present shader. 2022-06-22 16:26:19 +02:00
lightningterror
34c36c09ff wx: Rename gsdx to gs for window title statistics. 2022-06-22 13:58:26 +02:00
lightningterror
765dab5d8d GS: Make sure upscaling hacks are disabled on native res.
There was a regression that caused upscaling hacks to still be enabled on native res.
2022-06-22 12:58:32 +02:00
lightningterror
063d02a9cb GS-wx: Disable TX x y offsets on native res:
We already gray out the option on Qt, and it should be an upscaling hack only.
2022-06-22 12:58:32 +02:00
lightningterror
6e5e9ab7bc GS-d3d12: Remove scale factor clamp.
Already handled in config so it's duplicate.
2022-06-22 12:58:32 +02:00
Ty Lamontagne
c8c7ac45d1 CDVD: Touch-Up GZip logging messages. 2022-06-21 23:49:27 +01:00
Connor McLaughlin
14181ec70d InputManager: Fix chord bindings when activating in reverse 2022-06-21 21:53:02 +01:00
Connor McLaughlin
b20e5a1e01 VMManager: Convert to fmt
Also adds an error message when trying to save state in the BIOS.
2022-06-21 21:53:02 +01:00
Connor McLaughlin
64d222a1e4 Qt: Support binding numpad keys independently of number row 2022-06-21 21:53:02 +01:00
refractionpcsx2
e4554fe9ca CDVD: Load GZip index location direct from ini.
Stops the Qt game list from putting indexes in the default location when a custom one is used.
2022-06-21 21:51:25 +01:00
refractionpcsx2
8ec736789c GUI: Allow memcard names shorter than 4 2022-06-21 21:51:07 +01:00
refractionpcsx2
9a323a9a8d GUI: Only add extension to new memcards on save 2022-06-21 21:51:07 +01:00
MomosuWarosu
298e626b6e GameDB: Upscaling fixes added for all retail versions of Shutokou Battle 01
GameDB: Upscaling fixes for Shutokou Battle 01

GameDB: Upscaling fixes for Shutokou Battle 01
2022-06-21 21:22:03 +01:00
Blackbird88
af7308e395 GameDB: Fix name of "The Document of Metal Gear Solid 2" 2022-06-21 21:21:43 +01:00
Mrlinkwii
7c80fcacba GameDB: add missing upscaling fixes to "Xenosaga Episode III" 2022-06-21 21:21:27 +01:00
Silent
beb23efa88 XInput: Fix axis inversion when using SCP extensions 2022-06-21 17:16:44 +01:00
Christian Murphy
1b65f5f164 PAD/Core bugfix for #6472
Bugfix for https://github.com/PCSX2/pcsx2/issues/6472 which was introduced by hold turbo changes
2022-06-21 09:36:06 +01:00
PCSX2 Bot
bb336f1bc7 PAD: Update to latest controller database. 2022-06-20 21:16:38 +02:00
Connor McLaughlin
36d386b451 Qt: Fix hide mouse cursor not working with render-to-main off 2022-06-20 15:14:23 +01:00
Connor McLaughlin
9199f48a3c HostDisplay: Remove DestroyRenderDevice()/move to destructor
Saves having to remember to call this any time you destroy the display
object.
2022-06-20 15:14:15 +01:00
Connor McLaughlin
5c88c585a0 ContextWGL: Use pbuffers when we don't have a surface
Fixes context restore error tripping when confirming shutdown while
fullscreen in Qt.
2022-06-20 15:14:15 +01:00
Connor McLaughlin
771b1490d2 Qt: Get rid of redundant resume on confirm shutdown 2022-06-20 10:34:28 +01:00
Connor McLaughlin
4bbdbf6332 Qt: Fix crash on confirm shutdown when fullscreen 2022-06-20 10:34:28 +01:00
refractionpcsx2
7dc10fbe46 Docs: Add normal readme and rename documentation readme 2022-06-20 09:12:08 +01:00
Ali Mahdavi
90ca83bd96 Qt: Change the word “Save Slot” to “Load Slot” in Load State menu
First off, I must admit, I **HAVE NOT** compiled the project to see if my change breaks the whole thing or not. I just searched the entire repository for `Save Slot` and renamed the one related to `loadSaveStateSlot`.
2022-06-20 09:56:36 +02:00
Christian Murphy
4ee92fc637 Qt: Turbo (Hold) Hotkey binding
Fixes #5538
Acts as a temporary flip-flop switch while held that either enables turbo while held or disables turbo while held if you've already toggled turbo.

Default bind is Keyboard/Period but happy to make this unbound if preferred.
2022-06-20 09:55:53 +02:00
Florin9doi
1d39488061 Gamedb: DB Updates 2022-06-20 08:50:56 +01:00
MomosuWarosu
d87cd32ff4 GameDB: Upscaling fixes for Tokyo Xtreme Racer 3 2022-06-20 07:50:00 +01:00
Connor McLaughlin
2a50ae905d VMManager: Don't try to load state when none exists 2022-06-20 07:38:19 +01:00
Connor McLaughlin
f536584d7a VulkanHostDisplay: Fix uploading unaligned texture sizes 2022-06-20 07:28:12 +01:00
Connor McLaughlin
fa3bd58b7f GS: Don't show GPU OSD when timing init fails 2022-06-20 07:28:12 +01:00
Connor McLaughlin
1f5d2c49fc Qt: Split texture replacement settings to its own page 2022-06-20 07:28:12 +01:00
Connor McLaughlin
3e585c3438 Qt: Add folder settings 2022-06-20 07:28:12 +01:00
Connor McLaughlin
c23e792f68 Qt: Add folder selection to memory card settings 2022-06-20 07:28:12 +01:00
Connor McLaughlin
02d3c93c2c Qt: Allow editing folder settings 2022-06-20 07:28:12 +01:00
Connor McLaughlin
a07ef0f5ee Qt: Move logging setup into core
Sharable between frontends this way.
2022-06-20 07:28:12 +01:00
Connor McLaughlin
e415251f30 Qt: Add pad deadzone 2022-06-20 07:28:12 +01:00
Connor McLaughlin
ddbc143178 GS/DX12: Fix creating display textures mid-frame crashing 2022-06-20 07:28:12 +01:00
CharlesThobe
d54715a9c3 Updater: Do not extract portable.ini
DIO
2022-06-19 20:18:34 +01:00
refractionpcsx2
eb9507707d GS: Unset scanmsk_used after 2 frames 2022-06-19 19:36:02 +01:00
lightningterror
3377de1fe3 gitignore: Ignore dmp files in bin directory. 2022-06-19 19:05:43 +02:00
refractionpcsx2
b5807e0788 GS-PCRTC: Add option to enable/disable Anti-Blur code.
For... accuracy?

Also clean up FIELD nonsense in the merge circuit.
Fixed up offset code for interlacing
2022-06-19 16:25:13 +01:00
Connor McLaughlin
c86e82039a GS: Fix possible crash when changing settings with readbacks disabled 2022-06-19 09:32:31 +02:00
Connor McLaughlin
999b2267c0 Wx: Remove sync to host refresh rate option
Still available in Qt obviously. Apparently there's COM reinitialization
issues on the CPU thread in wx, and I don't want to deal with that nonsense.
2022-06-19 09:31:51 +02:00
Connor McLaughlin
fbf9585b5a VMManager: Auto switch to 16:9 when ws patches are enabled/found 2022-06-19 02:18:08 +01:00
Connor McLaughlin
470365644f Qt: Implement mouse->controller binding
Also implements forwarding mouse events to imgui.
2022-06-19 02:17:42 +01:00
Connor McLaughlin
7b3847cc5c Qt: Fix incorrect input popup when no vibration sources available 2022-06-18 22:58:27 +02:00
Connor McLaughlin
2b0e1a1dec Qt: Fix compiling with spaces in path on Windows 2022-06-18 22:57:51 +02:00
kmicki
316e140329 PAD: changed freeze data size in Linux for cross-platform compatibility 2022-06-18 22:56:59 +02:00
Mrlinkwii
02c4c3b03d Gamedb: add "EETimingHack" for "Strikers 1945 1-2" and gamefixes for 'Star wars episode 3 " 2022-06-18 21:51:51 +01:00
TellowKrinkle
e5405e191b Metal: Fix ImGui renderer
Turns out those were bitcasts, not conversions
2022-06-18 15:32:46 -05:00
TheLastRar
839ea61d55 DEV9: Formatting 2022-06-17 19:12:35 +02:00
TheLastRar
02f27f8cbc DEV9: Have internal DHCP use AdapterUtils 2022-06-17 19:12:35 +02:00
TheLastRar
35b5138593 DEV9: Have internal DNS use AdapterUtils 2022-06-17 19:12:35 +02:00
TheLastRar
809c5ed051 DEV9: Have pcap backend use AdapterUtils 2022-06-17 19:12:35 +02:00
TheLastRar
412451f9d6 DEV9: Have Sockets backend use AdapterUtils 2022-06-17 19:12:35 +02:00
TheLastRar
35802f2089 DEV9: Add AdapterUtils 2022-06-17 19:12:35 +02:00
TheLastRar
8f6f0f8401 DEV9: Exclude pcap NPF_ Prefix from GUID on Windows 2022-06-17 19:12:35 +02:00
refractionpcsx2
44d95badc4 GUI-WX: Add Blit description in WX gamefix panel. 2022-06-17 00:30:06 +01:00
Mrlinkwii
d622faba17 GameDB: add autoflush and upscaling fixes for "Mega Man X8" 2022-06-16 20:29:23 +01:00
noigeaR
b5945d3d5c GameDB: add missing Japanese game serials
GameDB: add missing Japanese game serials
2022-06-16 17:52:07 +01:00
Silent
52cd6fb1dd GameDB: Port the Midnight Club 3 patch to NTSC-u v2.00 2022-06-16 15:05:25 +01:00
TellowKrinkle
04681babf1 Common: Add assertion failure message to crashlogs 2022-06-15 16:23:32 -05:00
Connor McLaughlin
e63c068720 GameDatabase: Add option to force blit-based FPS detection 2022-06-15 16:21:31 +01:00
refractionpcsx2
fb5b465a4e GS: Fix overflow calculation from errantly going off. 2022-06-15 15:48:37 +01:00
RedPanda4552
59ea3c7949 GameDB: Add HPO Special (Texture - Aggressive) to Batman Vengeance 2022-06-15 15:48:18 +01:00
Mrlinkwii
6f5306dbdc GameDB: Fix game names "ICO" and add "Monster Rancher Evo" fixes 2022-06-15 15:48:01 +01:00
refractionpcsx2
b5388fdf2f GS: Only enable scanmsk offset on frames that need it 2022-06-14 23:07:21 +01:00
lightningterror
d2904c1fd5 GS: Fix up wave filter shaders. 2022-06-14 21:25:47 +02:00
kmicki
7718feedd5 PAD Linux: correct conversion of analog stick values. 2022-06-14 20:59:11 +02:00
Riccardo Marcangelo
56add277f9 GS: Migrate function pointer to lambda
Compilers can inline lambda for superior performance.
2022-06-14 20:48:37 +02:00
refractionpcsx2
86f772ad38 GS: Avoid Div by 0 on WriteImage 2022-06-14 17:51:04 +01:00
refractionpcsx2
24c99551c7 GS: Fix God of War regression from #6389 (v1.7.2937) 2022-06-14 02:12:26 +01:00
refractionpcsx2
9441d2a33a IPU: Remove some DMA hacks 2022-06-13 23:47:47 +01:00
refractionpcsx2
3922091a58 GS: New state opt optimisation pass 2022-06-13 23:47:34 +01:00
refractionpcsx2
1107ce8fd8 GS: Check whole state before flushing draws 2022-06-13 23:47:34 +01:00
Mrlinkwii
3d10cd1adf Gamedb: fix 'Sega Sports Tennis' name 2022-06-13 23:24:22 +01:00
refractionpcsx2
02ac3943f2 INTC: Give grace period after event for reading INTC
If a game is in a tight loop waiting for a bit of INTC, we could skip a bunch of cycles incorrectly.
2022-06-13 23:02:44 +01:00
refractionpcsx2
44b672b6f5 Counters/GS: Adjust FIELD swap timing for PAL
Console tests show about 3 PAL scanlines of time.
2022-06-13 23:02:44 +01:00
PCSX2 Bot
0239d8350d PAD: Update to latest controller database. 2022-06-13 18:01:50 +02:00
Mrlinkwii
bada5fe941 Gamedb: remove gamefixes form "Axel Impact - The Extreme Racing" 2022-06-12 21:48:49 +01:00
Mrlinkwii
6db871958e Gamedb: remove no longer needed patches 2022-06-12 15:40:33 +01:00
lightningterror
0b557fe265 GS/Core: Purge frameskipping.
Get rid of frameskipping, won't be added to Qt.
2022-06-12 11:43:10 +02:00
refractionpcsx2
ce08627396 GS: Reduce false positives in dev overflow errors 2022-06-12 08:03:14 +01:00
Christian Murphy
200ec5dcfb Qt: Update GameList scrolling to be per pixel to better indicate direction of scroll
Addressing issue https://github.com/PCSX2/pcsx2/issues/6237
2022-06-12 06:47:21 +01:00
Christian Murphy
8a6f55a63e Save/Load States via hotkey in QT
Addressing https://github.com/PCSX2/pcsx2/issues/6268.

Adds the commands for loading/saving all numbered states via hotkeys, leaving them all unbound by default.
2022-06-12 02:29:24 +01:00
Mrlinkwii
e327f5e6f0 Gamedb: remove patches and add upscaling fixes for 'Onimusha - Dawn of Dreams' 2022-06-12 02:28:45 +01:00
Στέφανος "Coornio/8924th" Βλαστός
5849726913 GameDB: upscale fixes, adding missing serials, name corrections, etc
See PR for details
2022-06-12 02:10:05 +01:00
Mrlinkwii
e063613a7f GameDB: add 'Axel Impact - The Extreme Racing' 2022-06-12 02:06:34 +01:00
Connor McLaughlin
48d2cb4975 Qt: Implement input profiles 2022-06-11 14:37:57 +01:00
Connor McLaughlin
59412b1673 Qt: Implement multitap 2022-06-11 14:37:57 +01:00
Connor McLaughlin
d1a235272e SettingsInterface: Add ContainsValue() and copy helpers 2022-06-11 14:37:57 +01:00
Mrlinkwii
7db9627ff6 Gamedb: Fix games names 2022-06-10 23:23:42 +01:00
lightningterror
83550cd153 github labeler: Remove nsis. 2022-06-10 15:12:03 +02:00
TellowKrinkle
77471bd9d6 GS: Avoid using both blending and fbfetch 2022-06-10 14:40:30 +02:00
lightningterror
0e94211ff1 GS: Fix Wunused-variable warnings. 2022-06-10 14:16:11 +02:00
Mrlinkwii
f6e7bba354 GameDB: Remove patch for Panzer Dragoon 2022-06-10 11:33:27 +01:00
noigeaR
b2255e5b27 GameDB: add missing serials, upscaling fixes, name corrections (#6385) 2022-06-10 09:46:25 +01:00
Mrlinkwii
7b493ff4c8 Gamedb: add upscaling fixes to 'Fast and the Furious' 2022-06-09 15:23:33 +01:00
Mrlinkwii
aeef163349 GameDB: add missing serials 2022-06-08 19:25:30 +01:00
RedDevilus
26f2352059 GameDB: Fix flag + add missing US serial
Someone in the Discord said that they had the question mark flags for these 2 serials, 1 is Virtua Fighter 4 Evolution PAL which had a typo and another is NBA Live '09 NTSC version. Quite surprising to see a missing American release in the GameDB still.
2022-06-08 15:27:53 +01:00
arcum42
67e38d8de2 Build: Update build.sh to remove a no longer used flag and add a few more. (#6124)
* Build: Update build.sh. Remove a no longer used flag and add a few new ones.

* Fix spacing on --use-system and --use-bundled.
2022-06-07 21:45:40 -07:00
Mrlinkwii
2c3a4cbabf Gamedb: fix up 'Deadly Skies III' name 2022-06-07 19:12:10 +01:00
Connor McLaughlin
fed3ea597c Qt: Add swap memory card button 2022-06-07 15:09:41 +01:00
Connor McLaughlin
547b2fc9e8 VMManager: Cycle/autoeject memory cards when files change
Hopefully should fix card changes not getting picked up in some games.
2022-06-07 15:09:41 +01:00
Connor McLaughlin
cf07f4aef1 MemoryCardFolder: Fix empty/unplugged card detecting as folder 2022-06-07 15:09:41 +01:00
Connor McLaughlin
3dc4aea053 MemoryCardFile: Open file memcards in read share mode
Fixes cards showing up as "missing" in Qt's settings dialog if you
opened the dialog after starting a game.
2022-06-07 15:09:41 +01:00
Connor McLaughlin
afa29facc6 FileSystem: Add OpenSharedCFile() 2022-06-07 15:09:41 +01:00
Connor McLaughlin
8c0120bdbb GS/Vulkan: Fix uploading compressed replacement textures 2022-06-07 13:49:51 +02:00
Silent
a3e72c5b43 Updater: Disable Maximize and Close buttons 2022-06-07 13:14:00 +02:00
Silent
33efc86788 Updater: Thread the UI updates, add a taskbar progress bar, add a marquee progress bar for indeterminate actions 2022-06-07 13:14:00 +02:00
Mrlinkwii
ec6be34c31 Gamedb: add disablePartialInvalidation to snowblind engine games 2022-06-07 11:44:05 +01:00
iMineLink
fd49a1e80a GS: preserve target on different format write.
affects hardware texture cache.
2022-06-07 10:49:01 +01:00
Dreadmoth
d1d6855d58 Qt: Fix Disable Depth Emulation tooltip 2022-06-07 09:02:56 +01:00
lightningterror
504b9e7051 Qt: Fix Texture Offsets tooltip. 2022-06-07 02:28:12 +02:00
Mrlinkwii
9cb64fd087 GameDB: add HW fixes for 'Raging Bless' 2022-06-06 22:27:52 +01:00
refractionpcsx2
fe9ccf55c1 GS: Allow same src for DISPFB when using 32bit + 24bit 2022-06-06 21:07:08 +01:00
PCSX2 Bot
4840da2c1b PAD: Update to latest controller database. 2022-06-06 19:21:56 +02:00
Connor McLaughlin
543fb282fe VMManager: Set affinities for threads 2022-06-06 17:44:06 +01:00
Connor McLaughlin
9b7ae498d2 3rdparty: Add cpuinfo 2022-06-06 17:44:06 +01:00
refractionpcsx2
5668bcf19b IOP: Revert a change from #6267
Think this was a misunderstanding of how the interrupts worked (was actually one shot)
2022-06-06 15:06:29 +01:00
refractionpcsx2
66c25b3cb6 GS: Auto adjust aspect when using Offsets + Overscan 2022-06-05 23:12:08 +01:00
refractionpcsx2
e234fb32d9 GS Add horizontal overscan 2022-06-05 23:12:08 +01:00
refractionpcsx2
f70c67ad7f GS: Add option to show vertical overscan 2022-06-05 23:12:08 +01:00
refractionpcsx2
cf3cfdb2bc GS: Correctly handle field/deinterlace for progressive/interlaced mode.
Also correct the number of scanlines for progressive (double strike) and how long vblank is.
2022-06-05 22:37:26 +01:00
Connor McLaughlin
394f1f2049 Vulkan: Enforce 32 byte alignment for uploads
It blows up on AVX2 stores on some drivers if we don't (e.g. AMD Linux).
2022-06-05 21:29:42 +01:00
Connor McLaughlin
a9819542d4 GS: Split convert and present shaders 2022-06-05 21:27:16 +01:00
Στέφανος "Coornio/8924th" Βλαστός
d0e3b8c4ee fix dump n.1 2022-06-05 21:26:01 +01:00
refractionpcsx2
e3681cf993 GS: Be generous with the resolution for no-interlace patches 2022-06-05 21:21:13 +01:00
Mrlinkwii
26c717a1bf Gamedb:add upscaling fixes for 'Test Drive' 2022-06-05 21:00:35 +01:00
refractionpcsx2
6efdbf2950 GIF: sync GIF packet ends 2022-06-05 16:50:20 +01:00
refractionpcsx2
b45b082c06 IPU: Wait for IPU_FROM to be ready 2022-06-05 16:50:09 +01:00
lightningterror
da21a649c0 Qt: Add tooltips to Graphics section.
Most of them are ported from WX.
2022-06-05 14:00:50 +02:00
TellowKrinkle
347736f2b4 GHActions:macOS: Add Qt SVG plugin 2022-06-04 22:28:15 -05:00
lightningterror
a6649b2d6b GS: Fix SkipDuplicateFrames default config. 2022-06-05 00:01:19 +02:00
Mrlinkwii
33a78c1919 Gamedb: add missing serials 2022-06-04 22:08:12 +01:00
Mrlinkwii
3b4b669038 Gamedb: add patch for 'Transformers - Revenge of the Fallen' 2022-06-04 21:03:19 +01:00
Mrlinkwii
26b666abcd Gamedb: fixes for 'Call of Duty - Le Jour de Gloire' 2022-06-04 20:25:19 +01:00
Mrlinkwii
32e2a8ba2c GameDB: add HW fixes for snowblind engine games 2022-06-04 19:37:50 +01:00
Angel Toloza
fdc399b44c GameDB: Mana Khemia
Fixes misalignment of textures in the Pause Menu.
2022-06-04 19:20:07 +01:00
Connor McLaughlin
ec43661664 GS: Add sync to host refresh rate option 2022-06-04 18:43:07 +01:00
Connor McLaughlin
a05a655037 HostDisplay: Create swap chain in CreateRenderDevice() for D3D
Fixes starting in exclusive fullscreen mode in Qt.
2022-06-04 18:15:59 +01:00
Connor McLaughlin
ca3833e71b VulkanHostDisplay: Avoid redundant resizes 2022-06-04 18:10:46 +01:00
Connor McLaughlin
3910b047d4 InputManager: Fix incorrect default keyboard R2 binding 2022-06-04 18:10:46 +01:00
Connor McLaughlin
15c1381c1e VMManager: Add input profile loading 2022-06-04 18:10:46 +01:00
Connor McLaughlin
c0e65d9a36 vtlb: Add RAM accessors which avoid hw access 2022-06-04 18:10:46 +01:00
Connor McLaughlin
38ff490b60 HostSettings: Add writer functions 2022-06-04 18:10:46 +01:00
Connor McLaughlin
f8fa41d4bf VulkanHostDisplay: Upload textures in init command buffer 2022-06-04 18:10:46 +01:00
Connor McLaughlin
b74c65cc7c GS: Make reopen fails non-fatal
It'll restore the old configuration instead.
2022-06-04 18:10:46 +01:00
Connor McLaughlin
624e5ae633 VMManager: Force reloading of LastELF on state load 2022-06-04 18:10:46 +01:00
Connor McLaughlin
71935e7099 VMManager: Relax memory ordering for state
CST is definitely overkill here.
2022-06-04 18:10:46 +01:00
Connor McLaughlin
bb9a551318 MTVU: Use Thread wrapper 2022-06-04 18:10:46 +01:00
Connor McLaughlin
457ec7f6f5 Threading: Add lightweight thread wrapper 2022-06-04 18:10:46 +01:00
Connor McLaughlin
433b88c0bf GS/TextureReplacements: Be more lax about header flags 2022-06-04 18:10:46 +01:00
Connor McLaughlin
9f8911536a GS/OpenGL: Use feature flag for D32F/D32FS8 selection 2022-06-04 18:10:46 +01:00
Connor McLaughlin
eeb09c54d8 GS/DX12: Use correct state for texture staging buffers 2022-06-04 18:10:46 +01:00
Connor McLaughlin
52a3777aae Qt: Convert webp flags masquerading as png to png 2022-06-04 18:10:46 +01:00
Connor McLaughlin
ea1f451d35 Qt: Move flag/star icons to resources 2022-06-04 18:10:46 +01:00
Connor McLaughlin
28795e549b GS/Qt: Represent the current frame on resize when paused
Stops the frame displayed with incorrect proportions.
2022-06-04 18:10:46 +01:00
Connor McLaughlin
0a667bf18a SettingsInterface: Add optional accessors/mutators 2022-06-04 18:10:46 +01:00
Connor McLaughlin
2d8a4e13e6 GS: Fix a bunch of texture copy counters not adding 2022-06-04 18:10:46 +01:00
Connor McLaughlin
f1702b5693 Qt: Force game list column resize on window show
Fixes a regression from dbfb93a50f where
the game list columns would always be too short on open.
2022-06-04 18:00:06 +01:00
Connor McLaughlin
b89d0837a6 Qt: Avoid spamming resize events on paint
This caused long freezes on Windows when you dragged the window around,
because it was sending a paint event for every movement.
2022-06-04 17:27:55 +01:00
TellowKrinkle
cba6a6ec51 Qt: Add preferences button to menu system
Important on macOS to get the expected keyboard shortcut
2022-06-04 14:50:33 +01:00
TellowKrinkle
d74623faf9 Qt: Support DPI change events 2022-06-04 14:50:33 +01:00
TellowKrinkle
db4bf08475 GHActions:macOS: Add Qt build 2022-06-04 14:50:33 +01:00
TellowKrinkle
f9c2327bf5 Qt: Respond to dark/light mode changes 2022-06-04 14:50:33 +01:00
TellowKrinkle
beab9870cf Common: Move ObjC methods to CocoaTools 2022-06-04 14:50:33 +01:00
TellowKrinkle
dbfb93a50f Qt: Calculate icon theme from palette instead of name 2022-06-04 14:50:33 +01:00
TellowKrinkle
6b66cd7f29 Qt: Remove [Light] from Native theme
It's whatever your system theme is set to, be that light or dark
2022-06-04 14:50:33 +01:00
TellowKrinkle
08089e0654 Qt: Set isMask to true on menu items
Prevents icons from being the wrong color when the Qt theme doesn't match the macOS system theme (or when you use Native theme with dark mode)
2022-06-04 14:50:33 +01:00
TellowKrinkle
b2ef973f16 Qt: Fix game summary field size on macOS 2022-06-04 14:50:33 +01:00
TellowKrinkle
d862f8cd53 Qt: Fix SDL initialization crash on macOS 2022-06-04 14:50:33 +01:00
TellowKrinkle
9c61e9eda3 Qt: Mac build 2022-06-04 14:50:33 +01:00
Goatman13
dc000e08ab GameDB: Add more Onimusha 3 HW fixes.
Fixes textureless graphics ingame.
2022-06-04 14:27:16 +01:00
Goatman13
5469d59de9 IPU: Set ECD if start code is not 1xx
Onimusha 3 send 0x200 and expect that start code search finish on it.
Setting ECD here helps The Sims Bustin' Out
2022-06-04 14:27:16 +01:00
refractionpcsx2
37f640ece2 IPU: Always process command if busy on DMA run 2022-06-04 13:30:48 +01:00
refractionpcsx2
906898c785 Savestates: Add developers comment for commit log messages 2022-06-04 04:57:37 +01:00
TheTechnician27
30f6c5f8f1 Update README.md to reflect project's age. 2022-06-04 02:36:13 +01:00
refractionpcsx2
1a2059c0f1 IOP Counters: Fix up interrupt behaviour
Also replace some magic values with macro/enum type thingies
2022-06-04 02:28:56 +01:00
RedDevilus
4fb0050411 GameDB: Forbidden Siren 2
Fixes vertical lines in-game (merge sprite) and FMV (software renderer gamefix)
2022-06-04 02:25:26 +01:00
refractionpcsx2
5708fb1668 IPU: add slight timing to IDEC/BDEC
Modify IPU to run on internal interrupts to give some timing
2022-06-04 01:46:01 +01:00
refractionpcsx2
870604d64c Savestates: Add new IPU variable and bump version 2022-06-04 01:46:01 +01:00
refractionpcsx2
9f4bf4267d IPU: Stop early IPUProcessInterrupt fires. 2022-06-04 01:46:01 +01:00
refractionpcsx2
5c15d57f5f IPU: Reorder DMA timing for IPU_TO and IPU_FROM 2022-06-04 01:46:01 +01:00
Mrlinkwii
6e1f76185e GameDB: add patches for 'Harry Potter and the Half-Blood Prince' 2022-06-03 23:00:05 +01:00
Goatman13
7fe5ba480c GameDB: Replace Choro Q HG, and Penny/Gadget Racers patches.
Replace patches to less invasive solution. No longer need to skip movies, or skip SetVSyncFlag.
2022-06-03 18:25:56 +01:00
RedDevilus
2333ff7b2d Qt: Bump Cache + new other icon 2022-06-03 16:23:54 +01:00
RedDevilus
5063961748 Qt: Readability and prevents false matches regions
Code readability is easier if you check out this page and also prevents false matches like PAL-FI which is a Finnish game would trigger PAL-F which gives a French flag.
2022-06-03 16:23:54 +01:00
RedDevilus
815c0a394d Qt: Adding back BIOS flags
The old code was still being used for getting the icons but they were renamed and moved into another folder. Oops!
2022-06-03 16:23:54 +01:00
RedDevilus
6d3f42a441 Qt: Change array and rename flags to region 2022-06-03 16:23:54 +01:00
RedDevilus
4b76594d8d Qt: Add array and look-up for flags
Stenzek doesn't love a lot for variables which impacts code readability, put into array for ease his mind.
2022-06-03 16:23:54 +01:00
RedDevilus
f5144f33da Qt: Move flags to seperate folder 2022-06-03 16:23:54 +01:00
RedDevilus
03f7e9e15a Qt: More flags and regions + enabling more icons
In reality it will show multiple flags like Korean flag but the flags aren't correct due to the structure in the GameDB actually being the languages more than the actual region.
At least people will have Korean flags and others for now and fix GameDB later as it's still a nightly/development cycle.

Though there are about 30 country flags included for future usage as of now.
2022-06-03 16:23:54 +01:00
Blackbird88
a8baa4b67c GameDB: Added Tourist Trophy VU clamp fix 2022-06-03 13:52:50 +01:00
RedDevilus
f40bebed3b GameDB: Fix line in the sky for Jak games
Read the description...
2022-06-02 18:25:35 +01:00
RedDevilus
5a036e572b GameDB: Remove Kingdomhearts 1/2 GShwfixes
Issues with texture cache reveal themselves so best to remove it.
2022-06-02 18:25:16 +01:00
Mrlinkwii
cd31f5fceb GameDB: upscaling fixes for 'Tokyo Xtreme Racer Drift 2' 2022-06-02 00:45:08 +01:00
Mrlinkwii
f812174270 Gamedb: fix game title typos 2022-06-01 21:39:33 +01:00
nev3rfail
aeaeb8ba94 GS/TextureReplacement: Ignore replaced textures in DumpTexture 2022-06-01 20:15:16 +02:00
Florin9doi
2adeb401ff Gamedb: PlayStation BB Navigator 2022-06-01 12:38:19 +01:00
Florin9doi
52325cb7dd Gamedb: Jissen Pachi-Slot Hisshouhou 2022-06-01 12:38:19 +01:00
Florin9doi
6265bbf99a Gamedb: Web browsers 2022-06-01 12:38:19 +01:00
Mrlinkwii
8c0c9a5e29 PAD: fix typo in UI 2022-06-01 12:09:03 +01:00
Florin9doi
8638c73a4e Gamedb: DVD Player 2022-06-01 11:01:00 +01:00
Florin9doi
d2d4038357 Gamedb: Chou! Rakushii Internet Tomodachi Nowa 2022-06-01 10:36:23 +01:00
refractionpcsx2
f8fdbaf566 CheatsWS: Remove bad Herdy Gurdy WS patch 2022-05-31 19:12:53 +01:00
Stuart Kenny
0b2536dd3e GS/HW: Fix typos in wave filter shader 2022-05-31 17:36:16 +01:00
Mrlinkwii
b2b7d8d64e Gamedb: remove patch from 'Boku to Mao' 2022-05-31 16:17:22 +01:00
Stuart Kenny
67c34794e8 Qt: wire in tv shaders 2022-05-31 15:22:47 +01:00
Dreadmoth
30f0cdde6f GameDB: Add missing serial
Secret Agent Clank (PAL-M12) [SCES-55496]
2022-05-31 16:08:13 +02:00
TheLastRar
71637cc282 DEV9: Clang format Qt files 2022-05-31 13:57:24 +01:00
TheLastRar
56402db7ee DEV9: Add DNS host export/import 2022-05-31 13:57:24 +01:00
TheLastRar
3e76d380a1 DEV9: Move helper Qt classes into a separate file 2022-05-31 13:57:24 +01:00
Connor McLaughlin
4873165dbc PAD/Host: Fix unconditionally sending state for disconnected ports 2022-05-31 12:12:44 +01:00
Connor McLaughlin
277706505e PAD: Make controller info public 2022-05-31 12:12:44 +01:00
Stuart Kenny
9f09aa725b pad: Expose Analog mode button. 2022-05-31 11:35:13 +01:00
Connor McLaughlin
06fee385e1 Tests: Add unit tests for UNC paths on Win32 2022-05-31 11:01:14 +01:00
Connor McLaughlin
dc4ef1163f Qt: Add logging of early directory setup
Makes debugging this stuff easier in the future.
2022-05-31 11:01:14 +01:00
Connor McLaughlin
2928837b76 Qt: Add command line parameter to force early console log 2022-05-31 11:01:14 +01:00
Connor McLaughlin
a5124b118b FileSystem: Fix splitting UNC paths 2022-05-31 11:01:14 +01:00
Connor McLaughlin
e7db878188 GS: Clamp tex-in-rt source rectangle to rt bounds
Fixes GPU crash for DX12 in Ridge Racer V. Game still has broken car
textures.
2022-05-31 10:58:45 +01:00
lightningterror
0b164a7989 github labeler: Add/adjust renderer labels based on current renderers. 2022-05-31 01:14:20 +02:00
Mrlinkwii
a4088685a0 Gamedb: Fix up some game names and add upscaling fixes for 'Xenosaga' 2022-05-30 22:48:18 +01:00
TellowKrinkle
fc06963c56 Common: Implement screensaver prevention on macOS 2022-05-30 16:38:01 -05:00
PCSX2 Bot
9680e7460c PAD: Update to latest controller database. 2022-05-30 21:43:49 +02:00
Connor McLaughlin
271e53a6bf Assertions: Fix message not being included for pxAssert() 2022-05-30 10:20:44 +01:00
RedDevilus
3888483fb4 GameDB: Reflect some new regions + new serials
In case of new centralised way of regions like the flag icons for Qt and adding some new serials.
2022-05-30 10:00:06 +01:00
RedDevilus
d67e72912c Qt: Fix DPI scaling 125% + higher quality icons
Upscaling on Qt didn't work properly as Windows calculates it differently, it's better to give far larger pictures and icons and let it downscale.

Also added most country flags that are relevant for PCSX2.

Reduces size icons from 3.5 MB to a whopping 0.34 MB (340 KB!) but looks even better for everyone.

Hopefully fixes #6255
2022-05-30 10:00:06 +01:00
refractionpcsx2
b843989719 Clang: Format GS.h 2022-05-30 09:48:26 +01:00
refractionpcsx2
7717450044 GS: Fix CSR.FIELD for progressive mode 2022-05-30 09:48:26 +01:00
TellowKrinkle
98947c10bb wx: Fix assert on settings panel 2022-05-30 09:48:13 +01:00
TellowKrinkle
6aa7266084 Core: Fix LnxFlatFileReader FinishRead return 2022-05-30 09:46:53 +01:00
TellowKrinkle
bd5656bf89 Core: Fix DarwinFlatFileReader FinishRead return
Looks like the return value is expected to be the number of bytes read
2022-05-30 09:46:53 +01:00
TellowKrinkle
1e4795e653 CDVD: BlockDumpFileReader formatting 2022-05-30 09:46:53 +01:00
Goatman13
c8e0090870 GameDB: Remove few IPU patches
No longer needed.
2022-05-30 01:24:31 +01:00
Goatman13
2dd9d8338b IPU: Implement start code validation for BDEC/IDEC
According to MPEG specs when 8 "0" bits are found, we should check for 000001xxh. Recommended way is to check 24 bits (000001h), and if they won't match discard 8 bits and try again until valid code is found, or stream ends.
2022-05-30 01:24:31 +01:00
Mrlinkwii
8d3c82de19 Gamedb: upscaling fixes for 'Need for Speed: Hot Pursuit 2' 2022-05-30 00:37:04 +01:00
Mrlinkwii
3bff10e17d Gamedb: add upscaling fixes for ' The Sims 2 pets' 2022-05-29 23:15:44 +01:00
refractionpcsx2
6562a5191a MTGS: Fix GS reset behaviour 2022-05-29 22:03:02 +01:00
Connor McLaughlin
5ef159876a Build: Don't rewrite svnrev.h unconditionally
Stops VS from recompiling the files which include it every time you hit
run.
2022-05-29 16:19:08 +01:00
Mrlinkwii
1bb86d8984 GameDB: remove gameFixes for 'nfl street 3' 2022-05-29 16:17:15 +01:00
Connor McLaughlin
edd735ce80 GS: Read local memory without sync when readbacks are disabled 2022-05-29 16:15:34 +01:00
Connor McLaughlin
4fd06b5ea8 GS: Clear current/merge textures on hardware reset 2022-05-29 16:15:18 +01:00
Connor McLaughlin
f6d997ca87 GS: Clear local memory on hardware reset 2022-05-29 16:15:18 +01:00
Connor McLaughlin
5963efcec8 GS: Get rid of redundant pointers to VM 2022-05-29 16:15:18 +01:00
Silent
f8fbfee49d GameDB: Add Auto Flush for 24 - The Game
Fixes pause menu backgrounds.
2022-05-29 14:34:15 +01:00
Mrlinkwii
4d7ee63d77 GameDB: remove gameFixes from'NFL Street 2' 2022-05-29 14:30:16 +01:00
Mrlinkwii
21b97f68fa Config: Remove unused macro from superVU. (#6240) 2022-05-29 01:04:24 +02:00
refractionpcsx2
95c91b4dc6 GS-TC: Preserve scale when resizing target for display. 2022-05-28 23:59:31 +01:00
Mrlinkwii
ca1b35a351 GameDB: add missing serials 2022-05-28 23:27:48 +01:00
Mrlinkwii
84177d38d4 GameDB: update 'Growlanser Generations' name 2022-05-28 19:28:14 +01:00
Mrlinkwii
e21589da86 Gamedb: fix up some game titles 2022-05-28 18:56:13 +01:00
refractionpcsx2
0768971f35 GS: Bug fix Scissor Optimization 2022-05-28 14:29:37 +01:00
Mrlinkwii
6c42a7f6e4 GameDB: fix up game names 2022-05-28 13:51:57 +01:00
Connor McLaughlin
a65f3bd116 GS/DX12: Fix incorrect blend factor for primid DATE 2022-05-28 05:50:21 +01:00
Connor McLaughlin
822e508d13 D3D12: Don't call GetGPUDescriptorHandleForHeapStart() on non-shader-visible heaps 2022-05-28 05:50:21 +01:00
RedDevilus
1611aeedce GameDB: Tales of Legendia + Batman Begin + ...
- Added FMV switch for Tales of Legendia which can show garbage textures
- Added Batman Begins (Autoflush and Special Texture half pixel offset for the lighting misalignment)
- Some extra clean-up on Spartan - Total Warrior
2022-05-28 05:49:36 +01:00
refractionpcsx2
7c243756bc GS: Better swapped draw direction detection on scissor opt 2022-05-28 04:42:33 +01:00
refractionpcsx2
43b53df0a0 Patches: Make cheats_ws.zip search case insensitive 2022-05-28 03:32:43 +01:00
C.W. Betts
66c6c2400a Some Qt for Mac fixes. 2022-05-27 21:21:48 -05:00
Connor McLaughlin
30096a5ae4 Qt: Add hardware check for SSE4 and AVX2 2022-05-27 17:39:09 +01:00
refractionpcsx2
c70afc24bd GUI/Qt: Prioritize serial in cover lookup 2022-05-27 11:34:39 +01:00
Connor McLaughlin
ce53b7adb1 Qt: Implement drag/drop to main window 2022-05-27 09:55:02 +01:00
Connor McLaughlin
25fa70fe9e Qt: Fix loading save state from manual file 2022-05-27 09:55:02 +01:00
RedDevilus
724957fbec Qt: Revision default hotkeys
There has been a re-order of keybindings, new keybindings and missing Single Frame GS Dump, Multi Frame GS Dump, Input Recording mode.

To be decided for the rest.
2022-05-26 19:27:04 +01:00
TellowKrinkle
9084ef35b4 GS:SW: Restore zequal for optimization 2022-05-26 03:51:39 -05:00
TellowKrinkle
e58b1054ea GS:SW: Use restrict on DrawTriangleSection
Improves compiler optimization
2022-05-26 03:51:39 -05:00
TellowKrinkle
24de0866f7 GS:SW: Don't interpolate xy fields for scanlines
By that point, xy is what's being used to advance the scanline and won't be needed as a parameter
2022-05-26 03:51:39 -05:00
TellowKrinkle
0cec99361b GS:SW: Use floats for zskip 2022-05-26 03:51:39 -05:00
TellowKrinkle
8ba745030a GS:SW: Hold double z in registers more 2022-05-26 03:51:39 -05:00
TellowKrinkle
4ddf897719 GS:SW: Use doubles for Z calculation 2022-05-26 03:51:39 -05:00
TellowKrinkle
9be7eb67d8 GS:SW: Rearrange GSVertexSW members to better match planned DoubleZ arrangement
Note: Removes zequal.  DoubleZ will fix, but until then things will break
2022-05-26 03:51:39 -05:00
TellowKrinkle
56bba522ac GS:SW: Unvectorize unneccessarily-vectorized things 2022-05-26 03:51:39 -05:00
TellowKrinkle
b6c1b3fb96 GS: Add double operations to GSVector/GSNewCodeGenerator 2022-05-26 03:51:39 -05:00
TellowKrinkle
82de13d95a GS: Better cxpr GSVector init 2022-05-26 03:51:39 -05:00
TellowKrinkle
92dd6fb575 GHActions: Improve macOS artifact name for tagged builds 2022-05-26 03:26:12 -05:00
TellowKrinkle
ced58a047d CMake: Set fp-contract=fast
Clang defaults to off, everyone else defaults to on or fast.  Allows multiplies and adds to be merged into fma
2022-05-25 21:56:21 -05:00
refractionpcsx2
2d98b877a2 Patches-NI: Remove broken Silent Hill 3 patch 2022-05-26 00:54:59 +01:00
Master Builder
a26b91291c Common/Linux/LnxHostSys: Fixed compatibility issues with FreeBSD, made error
handling more explicit
2022-05-26 00:28:44 +02:00
Connor McLaughlin
46a649afc1 GS: Add Skip Presenting Duplicate Frames option 2022-05-25 23:24:44 +01:00
Connor McLaughlin
3ce242886b VMManager: Disable symbol map update on Qt
Until it's implemented.
2022-05-25 23:24:30 +01:00
Connor McLaughlin
3b5538a09c VMManager: Fix no ws/ni patches message showing up on reset 2022-05-25 23:24:30 +01:00
Connor McLaughlin
796519f6a7 D3D12HostDisplay: Fix vsync 2022-05-26 00:04:46 +02:00
Connor McLaughlin
2365a9caab D3D12/Texture: Fix incorrect resource state for fallback staging buffer 2022-05-26 00:04:46 +02:00
Connor McLaughlin
425b5d0478 BlockdumpFileReader: Extra error checking to detection 2022-05-25 14:08:54 +01:00
Connor McLaughlin
628560850a CDVD: Fix crash when trying to scan small gzip files 2022-05-25 14:08:54 +01:00
Tzerinas
69f058e532 GameDB: Removes missed french Tak fmv fix 2022-05-25 12:12:03 +01:00
Mrlinkwii
c66b660c10 GameDB: more removal of software FMV fixes from games 2022-05-25 11:56:38 +01:00
Mrlinkwii
4fdb3322cc Gamedb: remove software FMV fixes from games 2022-05-25 11:33:24 +01:00
Connor McLaughlin
73122400e3 GSTextureCache: Expand target to fit readout height
This handles a case where you have two images stacked on top of one another (usually FMVs), and
the size of the top framebuffer is larger than the height of the image. Usually happens when
conservative FB is on, as off it'll create a 1280 high framebuffer.

The game alternates DISPFB between the top image, where the block pointer matches the target,
but when it switches to the other buffer, LookupTarget() will score a partial match on the target
because e.g. 448 < 512, but the target doesn't actually contain the full image. This usually leads
to flickering. Test case: Neo Contra intro FMVs.

So, for these cases, we simply expand the target to include both images, based on the read height.
It won't affect normal rendering, since that doesn't go through this path.
2022-05-25 10:51:54 +01:00
refractionpcsx2
d1cdfafe22 Qt: Fix auto updater
CI didn't build it, so we missed it lol
2022-05-25 10:28:43 +01:00
Connor McLaughlin
91e8a2cf0e Qt: Fix adding multi bindings from pad 2022-05-25 10:15:48 +01:00
Connor McLaughlin
b5721a92e9 Misc: Fix a bunch of recent warnings from clang 2022-05-25 10:15:48 +01:00
Connor McLaughlin
cefe4b773c Qt: Add clear bindings button to controllers 2022-05-25 10:15:48 +01:00
Connor McLaughlin
332346449f Qt: Remove presets dropdown, hide restore defaults
Until it's implemented.
2022-05-25 10:15:48 +01:00
Connor McLaughlin
2c199e7c42 Qt: Add log timestamps 2022-05-25 10:15:48 +01:00
Connor McLaughlin
2a32864856 Qt: Get rid of duplicate base setting query helpers 2022-05-25 10:15:48 +01:00
Connor McLaughlin
9481bbd2ef Qt: Add OSD message when block dumps are enabled 2022-05-25 10:15:48 +01:00
Connor McLaughlin
08aad5461e Qt: Add block dump options 2022-05-25 10:15:48 +01:00
Connor McLaughlin
0bab9474ae Qt: Add file logging option 2022-05-25 10:15:48 +01:00
Connor McLaughlin
1f802eca46 Common: Redo assertions, purge DiagnosticOrigin 2022-05-25 10:15:48 +01:00
Mrlinkwii
a02df6c980 GameDB: add 'disablePartialInvalidation' to 'Shadow Hearts 2' 2022-05-24 23:34:57 +01:00
refractionpcsx2
e0194b2b95 GUI: Enable verbose messages for patch loading. 2022-05-24 20:31:36 +01:00
RedDevilus
74f4886ea6 GameDB: Revise serial names + GsHWFixes
With Qt being released there were still illegal characters being used in the name, also found some random typo mistakes.

Fixes #6170

GsHWFixes:
- Ratatouille
- Wild Arms series
- Tony Hawk Downhill Jam
2022-05-24 20:27:50 +01:00
refractionpcsx2
d9119921de GS: Limit interlace offset to FFMD mode.
The offset is only really needed when the game is rendering half frames and expects a certain amount of offset.
2022-05-24 18:03:07 +01:00
refractionpcsx2
4a12ec6fc0 GS: Add option to disable Interlace Offset 2022-05-24 18:03:07 +01:00
refractionpcsx2
0c855cdd6d GS: Update interlacing on Metal 2022-05-24 18:03:07 +01:00
refractionpcsx2
89d44a5f60 GS: Offset interlace when upscaling 2022-05-24 18:03:07 +01:00
Connor McLaughlin
aa47018197 Qt: Apply patches on entry point compile
Fixes WRC4's entrypoint patch not being used.
2022-05-24 18:00:59 +01:00
refractionpcsx2
d5cd2446e4 GUI/Qt: Use higher quality icon 2022-05-24 17:59:05 +01:00
lightningterror
eb386fb0fb Qt: Gray out language selection.
Not yet implemented.
2022-05-24 16:59:26 +02:00
Connor McLaughlin
cb24b84bff Add cheats_ni.zip 2022-05-24 12:50:43 +01:00
Connor McLaughlin
d65522a9b4 VMManager: Add no-interlacing patches 2022-05-24 12:50:43 +01:00
Connor McLaughlin
fa91d0b705 Qt: Make relationship between vsync queue/optimal pacing clearer 2022-05-24 11:34:56 +01:00
Connor McLaughlin
ae43cfaaf2 R5900: Fix format string for TLB misses etc 2022-05-24 11:34:56 +01:00
Connor McLaughlin
8bbcb05303 MultipartFileReader: Fix use-after-free when opening multipart files
Also fixes loading uppercase filenames on Linux.
2022-05-24 11:34:56 +01:00
Connor McLaughlin
f2713462cc Qt: Fix starting after theme change 2022-05-24 11:34:56 +01:00
refractionpcsx2
ac9d406862 Adding FUNDING file
Adds a button to the project
2022-05-23 19:20:19 +01:00
Connor McLaughlin
74738022da Qt: Use SERIAL_CRC.ini naming for per-game settings 2022-05-23 17:27:11 +01:00
PCSX2 Bot
aae8d5d639 PAD: Update to latest controller database. 2022-05-23 18:20:41 +02:00
lightningterror
372ee9b6b6 Qt: Allow to load/browse block dump files. 2022-05-23 18:19:14 +02:00
lightningterror
943e21f507 Qt: Fix link/url colours in various themes.
Fixes #6148
2022-05-23 17:11:29 +02:00
Connor McLaughlin
b6308bab4f Qt: Initialize COM ourselves on EmuThread
If we don't, SDL initializes it first in STA mode, which prevents MT
mode from being used, which prevents us from using XAudio2.
2022-05-23 15:45:53 +01:00
Connor McLaughlin
6a4df2a641 GS: Move GSinit()/GSshutdown() to GS thread
This initializes COM, so it has to be done on the thread which is
actually going to use it.
2022-05-23 15:45:53 +01:00
lightningterror
a92eb4d10a Qt: Disable/remove unused buttons.
Not implemented yet.
2022-05-23 16:32:02 +02:00
Mrlinkwii
c03e52c06f GameDB: upscaling fixes for 'KimiKiss' 2022-05-23 13:35:42 +01:00
Christian Kenny
66e663757a NSIS: Remove installer as it is is not compatible with Qt 2022-05-23 13:11:46 +01:00
Connor McLaughlin
d279f61d0b VMManager: Clear memory card eject timeout when game starts
If we don't reset the timer here, when using folder memcards
the reindex will cause an eject, which a bunch of games don't
like since they access the memory card on boot.
2022-05-23 13:11:06 +01:00
Connor McLaughlin
b59d4791cf Qt: Fix game grid scale/title setting not loading 2022-05-23 13:09:41 +01:00
Connor McLaughlin
680a3802d7 Updater: Remove update zip after committing 2022-05-23 13:09:41 +01:00
Connor McLaughlin
c3ee97103f Qt: Don't display update errors for background checks
It can be annoying, e.g. if you're not connected to the internet.
2022-05-23 13:09:41 +01:00
Connor McLaughlin
489fbe628a Qt: Remove download size from update prompt
The pcsx2.net api doesn't provide it.
2022-05-23 13:09:41 +01:00
Tyler Wilding
9ba42ec950 ci: format the GameDB and make sure it stays that way 2022-05-23 13:08:48 +01:00
Tyler Wilding
b54facdbd8 ci: catch duplicate YAML keys in the GameDB 2022-05-23 13:08:48 +01:00
Tyler Wilding
5c790b8540 ci: differentiate cmake windows build from the others 2022-05-23 13:06:35 +01:00
Tyler Wilding
ef32b49e50 input-rec: add back safeguard around controller input hook and dont deref null virtual pads 2022-05-22 22:45:01 -04:00
Tyler Wilding
8fb09d07ed input-rec: ensure controller logging is disabled by default 2022-05-22 20:29:42 -04:00
kenshen112
710d3360ac Cmake: Link InputRecording 2022-05-22 23:47:14 +01:00
lightningterror
ded036b93e Qt: Remove rich discord presence button.
Not implemented.
2022-05-23 00:34:37 +02:00
Silent
364e6a1341 GameList: Mark search directory cells as read-only 2022-05-22 23:16:10 +01:00
Tyler Wilding
2aec91d8c0 input-rec: remove frame-advance and adjust folder structure 2022-05-22 17:24:02 -04:00
Tyler Wilding
4f0c880e3e input-rec: append .p2m2 automatically when browsing for a file 2022-05-22 17:24:02 -04:00
Tyler Wilding
13d623f350 input-rec: cleanup VS and CMake project files 2022-05-22 17:24:02 -04:00
Tyler Wilding
9aecf79d7f input-rec: refactor core code, freeze wxWidgets version 2022-05-22 17:24:02 -04:00
Tyler Wilding
2e8076d909 input-rec: begin achieving parity in Qt 2022-05-22 17:24:02 -04:00
Tyler Wilding
655939147a input-rec: Remove DISABLE_RECORDING usages 2022-05-22 17:24:02 -04:00
arcum42
bf899022d7 DMAC: Testing a constant value is always true. (#6122) 2022-05-22 13:38:02 -07:00
Connor McLaughlin
ed5aa4a67d Qt: Cancel game list scanning when VM starts
Because of CDVD global state, and the fact that we hijack CDVD for
getting the game details, we have to cancel the scan. Otherwise, the
scanner will clash with the game's CDVD access.
2022-05-22 22:30:02 +02:00
Connor McLaughlin
22bf3549b6 Host: Add game list refresh/cancel calls 2022-05-22 22:30:02 +02:00
Connor McLaughlin
f260a8be66 GameList: Add region string/fix cached progress increment 2022-05-22 22:30:02 +02:00
Tyler Wilding
068ab8ab36 ci: fix windows release asset structure 2022-05-22 15:55:06 -04:00
iMineLink
6fde585504 gs-hw: remove tales of abyss cu hack.
fixes ghosting when upscaling.
2022-05-22 21:54:11 +02:00
iMineLink
c45cc6928d gs-hw-tc: add some assertions on source scale. 2022-05-22 21:54:11 +02:00
iMineLink
110b7df4d5 gs-hw-tc: set scale in missing create source path. 2022-05-22 21:54:11 +02:00
iMineLink
73eea20fcc gs-hw: fix invalid reference to target texture.
if the target texture changes after the source
lookup, correctly propagate the texture update.

fixes tales of abyss fullscreen blur when upscaling.
2022-05-22 21:54:11 +02:00
TheLastRar
4f20a68b33 Core: Fix LnxFlatFileReader compile error with Qt 2022-05-22 19:54:28 +01:00
Tyler Wilding
dafef46a1b ci: add SSE4 support for tagged Qt builds 2022-05-22 14:18:50 -04:00
Christian Kenny
e283831841 HW: Use more sensible variable names for logging 2022-05-22 17:59:15 +01:00
Christian Kenny
d13c7b6b3e DMAC: Remove some old defines, optimize case statements 2022-05-22 17:59:15 +01:00
Tyler Wilding
e7d1477a7e ci: build the right solution file for Qt builds 2022-05-22 12:54:54 -04:00
Tyler Wilding
2810f6afc1 ci: update docs 2022-05-22 12:54:54 -04:00
Tyler Wilding
821811cf0c ci: create simpler and more efficient release pipeline 2022-05-22 12:54:54 -04:00
Tyler Wilding
fea666bd1e ci: make build workflows re-usable, extract common scripts 2022-05-22 12:54:54 -04:00
Tyler Wilding
193254de94 ci: improve workflow organization 2022-05-22 12:54:54 -04:00
Connor McLaughlin
b919719aeb GzippedFileReader: Fix index creation 2022-05-22 16:13:12 +01:00
Connor McLaughlin
ea051c6d5f Everything: Get rid of wx entirely from the Qt build 2022-05-22 13:58:56 +01:00
Connor McLaughlin
893b3c629d Everything: Remove a **lot** of wx, and px nonsense
- common has no wx left except for Path.
 - pcsx2core only has it in a few places (memory cards and path related
   stuff).
2022-05-22 13:58:56 +01:00
Connor McLaughlin
c07c942659 Common/StringUtil: Handle error returns in StdStringFromFormatV() 2022-05-22 13:58:56 +01:00
Connor McLaughlin
b1d6d84e6f Qt: Get rid of wx module init
We're not using any wx thread junk anymore, so this can go.
2022-05-22 13:58:56 +01:00
tellowkrinkle
1afb248e4d Optionally use system libs (#6094)
* CMake: Make zstd and libzip optionally use system-installed versions

* CMake: Make SDL2 optionally use system version

* CMake: Disable crypto support in bundled libzip

* CMake: Fix bundled SDL build on macOS
2022-05-21 20:28:06 -07:00
Mrlinkwii
cad85d76a5 GameDB: Fix 'Hajime no Ippo - Victorious Boxers' serial 2022-05-21 00:28:52 +02:00
iMineLink
29ad851a9c gs-ogl: fix depth copy shader in stretch rect. 2022-05-20 01:12:38 +02:00
Mrlinkwii
cb9eaeeff9 GameDB: fix 'R: Racing Evolution' serial 2022-05-19 17:58:45 +01:00
Christian Kenny
7c9493cbc2 Core: Refactor code for shutting down internal PS2 components. 2022-05-16 17:30:52 +01:00
Christian Kenny
d21c01f8d1 Core: Remove unused code/includes. 2022-05-16 17:30:52 +01:00
RedDevilus
f4f06c9777 GameDB: Add new serials, GS (HW) Fixes
GS (HW) Fixes:
- R - Racing Evolution
- Lemony Snicket's A Series of Unfortunate Events
- Free Running
- Sopranos

New Serials:
- Shadow Hearts II [Demo]
- GI Jockey 2 [Demo]
- Hajime no Ippo - Victorious Boxers
2022-05-16 17:30:28 +01:00
Connor McLaughlin
437b6f3f0e Host: Reset imgui state when there's no frame to present
Prevents things getting into a messed up state internally where several
frames are buffered.
2022-05-16 17:30:11 +01:00
Connor McLaughlin
a163c90f2b 3rdparty/imgui: Update to 60bea05 2022-05-16 17:30:11 +01:00
PCSX2 Bot
9d9d22fcba PAD: Update to latest controller database. 2022-05-16 18:02:34 +02:00
Connor McLaughlin
df5e175b86 GS: Support creating/replaying dumps in zstandard format 2022-05-16 15:03:29 +01:00
Connor McLaughlin
0f8bbfd64c GS: Fix aspect ratio cycle hotkey in Qt 2022-05-16 15:03:29 +01:00
Connor McLaughlin
8c270288de GS: Refactor screenshots/GS dumping triggers
i.e. make it not rubbish and a massive race condition.

Also adds GS dump saving to Qt.
2022-05-16 15:03:29 +01:00
LargoUsagi
7bd7cdd867 GameDB: Modify .hack // games to use 'dot hack' and '-'(#6086) 2022-05-16 10:36:10 +01:00
Mrlinkwii
f618713551 GameDB: update EyeToy - Play 2 compat 2022-05-16 10:11:59 +01:00
refractionpcsx2
de329e49a8 GS: Redo a bunch of the ignore offset code
Plus clean up a bunch of stuff which isn't needed
2022-05-16 10:09:42 +01:00
Connor McLaughlin
2aa6f771a9 GS/TextureCache: Handle edge cases of paltex and texture replacement 2022-05-15 11:40:49 +01:00
Connor McLaughlin
7787fcff8e GS/TextureCache: Fix partial replacement of textures with same hash and paltex on 2022-05-15 11:40:49 +01:00
SgtSteel
6e576d208e README.md: update website links (#6073)
Updated the downloads link to point to the new page;
Changed the "Want more?" link to point to the homepage
Removed GitHub Releases link for development builds, since they are available on the website.
Also removed any reference to Windows and Linux, since binaries are now available for all three major OS
2022-05-13 16:34:37 +01:00
Connor McLaughlin
00751dc5d3 GS/TextureCache: Force hash caching for replaced textures
If we didn't do this, and preloading wasn't set to full, we'd partial
load the texture, and it wouldn't be in the hash cache. Then, when the
replacement came back (after being asynchronously loaded), there'd be
nothing for it to swap out with.
2022-05-13 12:50:08 +01:00
arcum42
e456fb8f88 Qt: Hook up screenshot button. (#6070)
Qt: Implemented hotkey as well.
2022-05-12 14:53:40 -07:00
Mrlinkwii
9dd579a6d5 GameDB: add some missing serials 2022-05-12 17:31:21 +01:00
Connor McLaughlin
fbd36a4347 Qt: Fix building on Linux 2022-05-12 17:31:06 +01:00
Connor McLaughlin
7f8bfb22de Build: Fix revision extractor for Qt auto updater 2022-05-12 17:31:06 +01:00
Connor McLaughlin
943b513a52 GS/TextureReplacements: Use aligned buffer for texture dumping 2022-05-12 15:08:45 +01:00
Connor McLaughlin
221eaf1a81 Common/AlignedMalloc: Add move constructor/assignment 2022-05-12 15:08:45 +01:00
Connor McLaughlin
41f1ec445f Qt: Add auto updater UI 2022-05-12 15:03:26 +01:00
Connor McLaughlin
a289723f66 Qt: Add update extractor source 2022-05-12 15:03:26 +01:00
Connor McLaughlin
a3f6efecb8 libchdr: Use in-tree lzma instead of bundled
Since we need it for the Qt updater.
2022-05-12 15:03:26 +01:00
Connor McLaughlin
2587cf3b95 3rdparty: Add lzma/7Z SDK 21.07 2022-05-12 15:03:26 +01:00
Connor McLaughlin
d535331b4b Misc: Remove __fastcall, __fc, __concall and friends
These have no meaning in x64 (apart from throwing compiler warnings),
and we don't do 32-bit anymore. Also saves needing to include
`Pcsx2Defs.h` in files which don't otherwise need it.
2022-05-12 14:58:03 +01:00
lightningterror
6d85399ec5 GameDB: Add OPHFlagHack to Naruto - Uzumaki Chronicles 2.
Fixes game freezing.

Fixes #6053
2022-05-12 12:58:52 +02:00
lightningterror
7a113474f0 GameDB: Add textureInsideRT to Turok Evolution.
Fixes underwater levels.

Fixes #6064
2022-05-12 12:51:38 +02:00
Connor McLaughlin
0bb7cc0a1a GS: Add texture dumping/replacement/reload replacement hotkeys
Qt only.
2022-05-11 14:44:42 +01:00
Connor McLaughlin
322ff3fcb9 GS/TextureReplacements: Add options to filter dumping to direct/palette textures 2022-05-11 14:44:42 +01:00
Connor McLaughlin
d329cabf07 GS/TextureReplacements: Fix queued items not getting purged after shutdown 2022-05-11 14:44:42 +01:00
Connor McLaughlin
38c48e8b6a Vulkan/Context: Don't write timestamp on an unreset query 2022-05-11 13:07:58 +01:00
Mrlinkwii
cd0b349496 GUI: update hyperlink in WX 2022-05-11 12:58:40 +01:00
TheLastRar
7f1932e282 DEV9: Fix double calling freeifaddrs() 2022-05-11 13:14:11 +02:00
Connor McLaughlin
17f2fb4471 Qt: Fix nightly builds not showing version in title bar 2022-05-11 13:13:39 +02:00
PCSX2 Bot
022a9cc6df PAD: Update to latest controller database. 2022-05-09 20:20:19 +02:00
Connor McLaughlin
c88db3221c GS/TextureCache: Flush dirty areas of textures during TC move
Dark Cloud does a bunch of VRAM writes overlapping the render target,
then moves over the top of it. If we didn't flush these, the target
would still be considered dirty, and later we'd trash the move
destination, and/or not use it as a source.
2022-05-09 17:45:53 +01:00
TellowKrinkle
bd3e1299a3 GS:MTL: Disable blending when color isn't written
Can come up in two-pass alpha, and Metal doesn't like it if blending uses SRC1 and your shader doesn't output it
2022-05-09 17:43:47 +01:00
TellowKrinkle
3a97688804 GS: Fix TextureMinMax when coordinates are completely outside of min/max 2022-05-09 17:43:47 +01:00
TellowKrinkle
3f027b2698 GS:SW: Clamp Z with unsigned clamp 2022-05-09 17:34:19 +01:00
Mrlinkwii
916754ea6d GameDB: add VUclamping to 'Monster Hunter 2' and 'Monster Hunter G' 2022-05-09 17:29:20 +01:00
TellowKrinkle
335633a5e0 CI: Update SDL 2022-05-09 10:28:58 -05:00
Connor McLaughlin
925bfc2a99 Tests: Set PCSX2_CORE macro
They shouldn't be using wx, and it gets rid of the pthreads4w reference.
2022-05-09 16:06:33 +01:00
Connor McLaughlin
d19c767ad1 Common/Dependencies: Use deletion for declaring non-copyable
This is the preferred method in modern C++.
2022-05-09 16:06:33 +01:00
Connor McLaughlin
d2347d9972 Common/Threading: Replace TLS macros with standard thread_local 2022-05-09 16:06:33 +01:00
Connor McLaughlin
f8dcff9fc4 Common: Remove references to pthreads4w
It's only needed for wx now.
2022-05-09 16:06:33 +01:00
Connor McLaughlin
e5716922a3 Common/Threading: Move a bunch of unnecessary wrappers to gui 2022-05-09 16:06:33 +01:00
Connor McLaughlin
65e956a01c Misc: Replace use of Threading::Mutex with std::mutex in core code 2022-05-09 16:06:33 +01:00
Connor McLaughlin
a93829557b SaveState: Misc refactoring and improvements
- Block until saves are completed when resuming.
 - Save shutdown state asynchronously.
 - Add function to read screenshot out of zip file (useful for
   previous, now we're using zstd).
2022-05-09 10:20:48 +01:00
Connor McLaughlin
c21d475bbd Qt: Implement save-state-on-shutdown 2022-05-09 10:20:48 +01:00
Connor McLaughlin
935dd046da 3rdparty/SDL2: Bump to 2.0.22 release
Fixes a crash on shutdown in Windows::Gaming::Input.
2022-05-09 10:01:45 +01:00
refractionpcsx2
1b2d9f0c5d GS: Scissor opt - handle reverse read sprites 2022-05-08 18:22:12 +01:00
Connor McLaughlin
4baea67e75 Common: Remove RwMutex
It wasn't used, and if we need it, we can use std::shared_mutex.
2022-05-08 05:40:59 +01:00
Connor McLaughlin
1e8332f36a Misc: Move pxThread and friends to gui 2022-05-08 05:40:59 +01:00
Connor McLaughlin
096696bed7 Misc: Replace core usage of Semaphore with KernelSemaphore
i.e. decouple it from the UI.
2022-05-08 05:40:59 +01:00
Connor McLaughlin
756cd1ee47 System: Move old SysThread junk to gui 2022-05-08 05:40:59 +01:00
Connor McLaughlin
64534542a9 Threading: Move a couple of function declarations to correct location 2022-05-08 05:40:59 +01:00
Connor McLaughlin
b22e31c302 Common: Add WIN32_LEAN_AND_MEAN and NOMINMAX to RedtapeWindows.h
Otherwise, it doesn't get set for cmake.
2022-05-08 05:40:59 +01:00
Connor McLaughlin
008beb4896 ThreadedFileReader: Fix possible race with synchronous reads 2022-05-08 05:10:09 +01:00
refractionpcsx2
576bcc6979 GameDB: Add HPO for Dog's Life 2022-05-08 02:54:47 +01:00
refractionpcsx2
4ec345a239 GS: Improve read heights with screen offset disabled 2022-05-08 01:16:04 +01:00
RedDevilus
972bfbcccc GameDB: Monster Hunter 1
Fixes lighting on character models as caves and other locations don't turn mobs into glow-in-the-dark creatures by themselves.
2022-05-07 23:27:46 +01:00
RedDevilus
f59fbaf0eb GameDB: Star Ocean 3
Certain areas have bloom effects which are misaligned, this should fix it. Though minor regression has to be made in the minimap as full round sprite is too aggressive for bloom filter.
2022-05-07 23:08:53 +01:00
refractionpcsx2
631ed8c0fd GUI-WX: Restore panel size override.
Fixes the panels going wonky after the recent dead code removal
2022-05-07 16:10:32 +01:00
Connor McLaughlin
41e8a2a7d1 MTGS: Purge pxThread 2022-05-07 15:43:03 +01:00
Connor McLaughlin
599626b709 MTVU: Purge pxThread 2022-05-07 15:43:03 +01:00
Immersion95
0ae17ddb1a GS: Adding KOF2002 CRC IDs
Adding:
- The King of Fighters 2002 (EUR)
- The King of Fighters 2002 (JAP)
- The King of Fighters 2002 - SNK Best Collection (JAP)
- The King of Fighters 2002 (USA) from Disc 1 of the bundle of The King of Fighters 02/03
2022-05-07 15:33:27 +01:00
Immersion95
7353c26a4f GS-TC: Don't skip depth lookup on KOF2002
Don't skip draw calls on KOF2002
2022-05-07 15:33:27 +01:00
Immersion95
b8769e954e GS: Adding KOF2002 CRC Title
Adding KOF2002 CRC Title
2022-05-07 15:33:27 +01:00
Connor McLaughlin
81cd2d9be9 Qt: Add placeholder for when no games are in list 2022-05-07 15:32:59 +01:00
Connor McLaughlin
90707c453d Qt: Rework VM pausing when popup dialogs are opened
Also cleans up fullscreen transitions further.
2022-05-07 15:32:59 +01:00
Connor McLaughlin
ec0e9f078c Qt: Confirm disc change type when switching to game list 2022-05-07 15:32:59 +01:00
Connor McLaughlin
98b537575f Qt: Rework display widget swapping 2022-05-07 15:32:59 +01:00
arcum42@gmail.com
233195b020 Remove macros that 'might be needed again in the future'. 2022-05-07 05:26:46 +01:00
arcum42@gmail.com
7d71e28bfc Delete various unused px stuff. 2022-05-07 05:26:46 +01:00
arcum42@gmail.com
13e09953af Remove unused code in Dependencies.h 2022-05-07 05:26:46 +01:00
Connor McLaughlin
a85ca4108c GS/DX11: Fix a possible texture leak with sw blend and tex-is-ds 2022-05-06 09:37:53 +01:00
Connor McLaughlin
8620febeb3 GL/Context: Load wayland-egl dynamically
Gets rid of the dependency on libwayland-egl, allowing us to always use
the system version.

Solves missing symbol issues by including it in the AppImage.
2022-05-06 01:00:24 +01:00
Connor McLaughlin
af4c047c41 MetalHostDisplay: Fix fullscreen in Qt interface 2022-05-05 23:23:48 +01:00
Connor McLaughlin
bec9b34f54 Vulkan/SwapChain: Fix crash on fullscreen toggle with Mac 2022-05-05 23:23:48 +01:00
refractionpcsx2
9989daec94 GSWindow: Remove force disable full screen hack now the GS Window doesn't suck 2022-05-05 23:19:35 +01:00
Mrlinkwii
c86dd7397d microVU : correct logging and remove not needed comments 2022-05-05 23:13:33 +01:00
Connor McLaughlin
eefc81ed8c Qt: Fix incorrect resources directory on config reset 2022-05-05 09:51:56 +01:00
Connor McLaughlin
91c717376f Qt: Use app bundle resources directory on Mac 2022-05-05 09:51:56 +01:00
Connor McLaughlin
344c918b65 Qt: Fix possible race when shutting down (Mac) 2022-05-05 09:51:56 +01:00
Connor McLaughlin
deeda519b0 Qt: Remove unused host display includes from EmuThread.cpp 2022-05-05 09:51:56 +01:00
Connor McLaughlin
2db12b9d84 Qt: Hook up axis/vibration scale in controller settings 2022-05-05 09:51:56 +01:00
Connor McLaughlin
378588c67d Qt: Implement more command line arguments 2022-05-05 09:51:56 +01:00
Connor McLaughlin
119b6bdfd5 Qt: Fix not-render-to-main after start fullscreen+toggle 2022-05-05 09:51:56 +01:00
Connor McLaughlin
8751a2d330 Qt: Make win32 console less garbage 2022-05-05 09:51:56 +01:00
Connor McLaughlin
4543ddbcc2 Common/FileSystem: Don't recompress already compressed files 2022-05-05 09:46:52 +01:00
Immersion95
77a7b18b29 GameDB: Add patches for remaining KOF series
Fix for Depth precision.
Game fills upper 16bits of depth with 0xFFFF.
This results in a really high 32 bit value which is then converted to float because both hw and sw renderers lack double precision the lower 16 bits of the initial 32 bit value lose precision.

PAL : KOF2002+KOF2003
NTSC-J : NGBC+KOF2002+KOF2003
2022-05-05 09:45:43 +01:00
lightningterror
749aef1a64 GS-d3d11: Get rid of vendor check in device.
Rely on the vendor check we already use for best renderer selection.
2022-05-04 21:31:58 +02:00
lightningterror
8091b6bc1b GS: Adjust default renderer based on vendor and feature level.
Vulkan default:
Nvidia Maxwell gen2 and higher.

OpenGL default:
From Fermi to Mawell gen1.

Everything else Direct3D11.
2022-05-04 21:31:58 +02:00
refractionpcsx2
4efa845580 GS: Add missing CRC for SNK vs Capcom Chaos (J) 2022-05-04 13:23:25 +01:00
Linus Heckemann
8c9ae90753 Wayland fixes (#5979)
* Linux/PAD: only attempt to reset X screensaver on X11

This would previously crash PCSX2 after 4096 frames on Wayland.

* Linux: only grab pointer on X11

This silently disables the functionality on Wayland, but that's one
step better than the previous behaviour: PCSX2 would crash when
Shift-F12 was pressed.
2022-05-03 23:24:47 -07:00
7oxicshadow
d1117aafac Allow commandline params to be passed through to the patched apprun file (#5777) 2022-05-03 23:24:10 -07:00
TellowKrinkle
a565182b2b GS:SW: Fix lod on C rasterizer 2022-05-04 01:02:36 -05:00
TellowKrinkle
650b0ae646 GS:SW: Prevent CDrawScanline from trashing unused Z bits 2022-05-03 21:47:57 -05:00
TellowKrinkle
b677619f32 GS: Formatting 2022-05-03 21:47:57 -05:00
TellowKrinkle
2fa8f09a21 GS:SW: Only run zclamp once
Also fixes clamping in the wrong spot in the C SW rasterizer
2022-05-03 21:47:57 -05:00
lightningterror
73c9279907 GS: Cleanup variable declarations/initalizations.
GSDevice11, 12, ogl, GSRendererHW.
2022-05-03 23:28:02 +02:00
Mrlinkwii
7d8912f170 GameDB: add 'VIF1StallHack' to 'Ikusa Gami' 2022-05-03 16:31:24 +01:00
lightningterror
2601ba53d4 GS-hw: Add brackets to the recommended crc selection just in case. 2022-05-03 11:58:51 +02:00
lightningterror
81baaaa98a GS-hw: Fix recommended crc for dx12.
Full level should be selected.
Once rov is added we can remove it.
2022-05-03 11:42:40 +02:00
TellowKrinkle
c2638131b4 GS:SW: Merge SSE and AVX implementations of CDrawScanline 2022-05-02 16:28:45 -05:00
TellowKrinkle
586486b81c GS:SW: Merge SSE and AVX implementations of CSetupPrim 2022-05-02 16:28:45 -05:00
PCSX2 Bot
af75ac00e2 PAD: Update to latest controller database. 2022-05-02 18:03:05 +02:00
RedDevilus
67b66c1780 GameDB: Sniper Elite + Naruto Shippuuden Ninja 3-5 + GT4
Adds FMV switch for both and adds special texture half pixeloffset for Sniper Elite.
Finally adding Halfpixel normal offset for Gran Turismo 4.
2022-05-02 15:04:28 +01:00
RedDevilus
b3dce680b0 GSHWHack: Comment CrashBandicoot
Explains what the actual CRC does and why.
2022-05-02 15:04:08 +01:00
RedDevilus
d01a59650f GSCrc: Add missing Crash Bandicoot 2022-05-02 15:04:08 +01:00
RedDevilus
5ae987d48e GameDB: Crash Bandicoot - Wrath of Cortex
Adds missing gamefixes that influenced random corruptions and the famous fog wall.
2022-05-02 15:04:08 +01:00
Connor McLaughlin
6a6ecbf826 Common: Remove ThreadCPUTimer as it's unused now 2022-05-02 14:25:05 +01:00
Connor McLaughlin
4bdf180145 PerformanceMetrics: Switch to ThreadHandle 2022-05-02 14:25:05 +01:00
Connor McLaughlin
6ebb8c2e91 Threading: Add ThreadHandle class 2022-05-02 14:25:05 +01:00
Connor McLaughlin
5eae7a6328 Threading/Win32: Use QueryThreadCycleTime() for thread CPU time 2022-05-02 14:25:05 +01:00
TheLastRar
7d81c979fe DEV9: Fix Auto Adapter in Socket backend on Mac and FreeBSD 2022-05-02 15:01:41 +02:00
TheLastRar
c06ac00677 DEV9: Allow DHCP Server to find Gateway on Mac and FreeBSD 2022-05-02 15:01:41 +02:00
refractionpcsx2
85c754b456 GS: Limit scissor optimisation, fix repeat condition
Only allow scissors to happen on single draws, multiple draws (likely using it as a texture map) will possibly falsely limit the range.
2022-05-02 04:58:57 +01:00
refractionpcsx2
35d3547b62 GS: Fix up SW FMV switch behaviour 2022-05-02 04:53:51 +01:00
Immersion95
8661f42fce GameDB: Add SoftwareRendererFMVHack for KOF Orochi/Nests. (#5987)
The FMV has black frames when upscaled.
2022-05-02 01:46:04 +02:00
refractionpcsx2
a28098c4f8 GS: Account for frame offset in output circuit 2022-05-01 13:15:08 +01:00
arcum42@gmail.com
d45f34ee8b Remove iMisc.cpp, and move the code to System.cpp/h. 2022-05-01 11:43:14 +01:00
Connor McLaughlin
d552f8dc43 GS/HW: Implement moves in texture cache 2022-05-01 11:40:34 +01:00
Connor McLaughlin
b45360b49e VMManager: Don't load WS patches zip multiple times 2022-05-01 11:37:35 +01:00
Connor McLaughlin
fffdf8d671 Counters: Fix software renderer FMV fix with auto renderer 2022-05-01 11:36:57 +01:00
Connor McLaughlin
2634134481 microVU: Remove unused VSync() callback 2022-05-01 11:36:37 +01:00
Connor McLaughlin
c0ac71611b GS: Remove GSState.cpp
Seems like old/unused code, and we have a replacement GSDump replayer
now anyway.
2022-05-01 11:36:37 +01:00
Mrlinkwii
63ecdfefe3 Gamedb:add 'XGKickHack' to 'WRC II Extreme' 2022-04-30 22:04:41 +01:00
lightningterror
6345e8e467 GS-hw: Cleanup Half pixel offset Normal.
Now that custom res is removed, we don't need to split modx and mody.

Also purely rely on the tc to handle the HPO hack.
2022-04-30 18:30:11 +02:00
Ziemas
e96545ca29 IopCounters: missing include 2022-04-29 09:50:29 +01:00
arcum42
dc08858e0f build: Remove i386_flag, as it is no longer used. (#5897)
* build: Remove i386_flag, as it is no longer used.

build: Put back in ncpu.

* build: Move ncpu to set_make.
2022-04-28 13:35:15 -07:00
Mrlinkwii
f5787f9ba0 GameDB: Japanese entries Batch 3 2022-04-28 17:11:32 +01:00
refractionpcsx2
a271fe11e9 GS: limit merge circuit memory read height 2022-04-28 16:32:36 +01:00
RedDevilus
a20a3866d0 Qt: Append warning for Manual Hardware Renderer Fixes
Same as the WX side where if you enable this option for doing hardware renderer or upscaling fixes it will disable the automatic settings from the GameDB.
But in tooltip version.
2022-04-27 16:14:07 +01:00
RedDevilus
28d25fdf33 WX: Append warning for Manual HW Hacks
WX and Qt both will disable renderer and upscaling fixes if you want to manually handle the renderer and upscaling fixes. For years enabling this option didn't do much harm for users even if you didn't change any other setting, but since 1.7 development series automatised these to a degree it would be nice for users to know why their game looks potentially awful.
2022-04-27 16:14:07 +01:00
Connor McLaughlin
f13ad4fcb3 InputManager: Switch InputEventHandler to std::variant 2022-04-27 15:32:52 +01:00
Connor McLaughlin
a524410b0a Qt: Fix firing multiple bindings with chords 2022-04-27 15:32:52 +01:00
TellowKrinkle
8e23d8d557 GS: Fix ReadTexture on unaligned reads
No longer reads out of bounds
2022-04-27 09:33:20 +01:00
Connor McLaughlin
59531f005e Patch: Merge patch and patchHelper 2022-04-27 09:09:38 +01:00
Connor McLaughlin
4c8cba53ef Patch: Fix incorrect format string on patch error 2022-04-27 09:09:38 +01:00
Mrlinkwii
34cd53249d GameDB: Japanese entries Batch 2 2022-04-27 09:08:13 +01:00
Connor McLaughlin
14ce344a3f GS: Merge GSRendererNew and GSRendererHW 2022-04-27 09:06:05 +01:00
TellowKrinkle
cc5142000b MTGS: Prevent the emulator from crashing if GS fails to init 2022-04-27 01:49:59 -05:00
TellowKrinkle
1ad6532f1a GS:MTL: Report error if no Metal devices are available 2022-04-27 01:49:59 -05:00
TellowKrinkle
f136a1a970 WX: Make GSDumpViewer override picker properly show only enabled options 2022-04-27 01:49:59 -05:00
TellowKrinkle
a959ec7571 CI:macOS: Disable OpenGL
It won't work
2022-04-27 01:49:59 -05:00
TellowKrinkle
e1a6304e32 CMake: Set version based on git tag 2022-04-27 01:49:59 -05:00
TellowKrinkle
be05c95026 CI:macOS: Add MoltenVK to build 2022-04-27 01:49:59 -05:00
TellowKrinkle
3983e542b2 CI: Enable macOS artifacts 2022-04-27 01:49:59 -05:00
TellowKrinkle
3d76652b5f macOS: Build dependencies manually 2022-04-27 01:49:59 -05:00
lightningterror
6532dbced4 GameDB: Add preload frame data for Ninja Assault.
Fixes intro captions not displaying.
2022-04-27 00:45:36 +02:00
refractionpcsx2
fe27ebefc8 GS: Ignore fractional parts when reducing tex ranges 2022-04-26 16:57:49 +01:00
Connor McLaughlin
6e84613a14 GS: Make renderer a global 2022-04-26 10:33:05 +01:00
Connor McLaughlin
568ebc6199 GS/HW: Don't clear temporary copies for HDR/DS
Invalidating is enough here.
2022-04-26 09:45:53 +01:00
Connor McLaughlin
cf1d67d927 GS: Adjust texture coverage based on scissor
A good test case here is Resident Evil 4, the shuffles draw over the
entire framebuffer, but get scissored to each strip.
2022-04-26 09:45:53 +01:00
Connor McLaughlin
8181cc8528 GS: Only copy texture coverage area for current FRAME/Z sources 2022-04-26 09:45:53 +01:00
Connor McLaughlin
b344ee094f GS: Make CopyRect() take a destination offset 2022-04-26 09:45:53 +01:00
TellowKrinkle
b042aeacf5 PAD: Fix race on shutdown 2022-04-26 00:01:58 -05:00
NightFyre
fea58d2271 GameDB: SOCOM Combined Assault NTSC Patch (#5964) 2022-04-26 00:43:23 +01:00
refractionpcsx2
ca5da27170 GS: Correct display offsets for Interlaced (FFMD) Framebuffers 2022-04-26 00:35:52 +01:00
RedDevilus
11eab828c4 Qt: Fix VuClamp values
This was an oversight, probably from copying the EEClamp value variables.
2022-04-25 23:28:03 +01:00
RedDevilus
8ca3f9a9c2 GameDB: SOCOM 3 + Combined Assault
Fixes SPS and invisible/flickering characters.
2022-04-25 23:28:03 +01:00
Mrlinkwii
deb044357b GameDB: game fixes for 'DMC', 'Fatal Frame' and 'MX vs. ATV - Untamed' 2022-04-25 23:04:37 +01:00
PCSX2 Bot
00c07d2dff PAD: Update to latest controller database. 2022-04-25 18:09:59 +02:00
Connor McLaughlin
185ed3ce0b MTGS: Combine init/read FIFO and remove several MTGS waits 2022-04-25 13:32:53 +01:00
BuildTools
3b043250b6 UI: Rename Ultra Blending to Maximum Blending
Rename Ultra Blending to Maximum Blending
2022-04-25 11:43:04 +02:00
Connor McLaughlin
3359b3c7ab GS/DX11: Fix possible use-after-free on cached RT/DS 2022-04-25 09:27:43 +01:00
TellowKrinkle
6b1e483d28 GS: fbfetch full_barrier and one_barrier are identical 2022-04-24 23:10:38 -05:00
TellowKrinkle
d3faa05479 GS:MTL: Avoid uchar in shaders
Intel compiler's uchar codegen is buggy
2022-04-24 23:10:38 -05:00
Connor McLaughlin
73f17be890 Qt: Implement proper data directory selection 2022-04-24 06:08:37 +01:00
refractionpcsx2
9292ceedb1 GS: Correct SetScaling when ignoring offsets (FB size) 2022-04-24 01:43:08 +01:00
refractionpcsx2
d1470a9935 GS: Clean up some code and correct heights when offset by 1 2022-04-24 01:43:08 +01:00
arcum42@gmail.com
38fa137cfd build: Include CrashHandler.cpp in cmake. Fixes #5938. 2022-04-24 01:42:10 +01:00
qurious-pixel
a7288d8ad8 BUILD: exclude libgmodule-2.0 2022-04-23 18:22:31 +02:00
Connor McLaughlin
0692517f13 ElfObject: Ignore section headers when offset is invalid
This happens in V-Rally 3:

(ELF) Section header offset 14853196 is larger than file size 5898828
2022-04-22 13:09:31 +01:00
Connor McLaughlin
4f44e3fc46 GS/SW: Get rid of extra pointers to perfmon 2022-04-22 11:37:11 +01:00
Connor McLaughlin
14398da51f GS/SW: Fix use-after-free on worker thread shutdown 2022-04-22 11:37:11 +01:00
Sam H
6e8897d62b build: use system wayland libs if available (appimage) 2022-04-21 19:27:38 +01:00
Connor McLaughlin
69da1e4559 Qt: Install crash handler on startup 2022-04-21 14:21:49 +01:00
Connor McLaughlin
abde47fa18 Common: Add CrashHandler 2022-04-21 14:21:49 +01:00
seta-san
f46b406cbd ReadMe.md: Clarify only Windows 8.0 dropped. 2022-04-20 21:16:48 +01:00
RedDevilus
48313b42a2 GameDB: Mosquito + RE Dead Aim + Ice Age
Adds some missing upscaling fixes for Mister Mosquito (blurriness when upscaling) and quite a few for Resident Evil - Dead Aim.
Along with Ice Age Meltdown upscaling and a rare SPS issue and Ice Age 3 upscaling.
2022-04-20 21:07:39 +01:00
Connor McLaughlin
1e06b57f25 VMManager: Fix disc path when specifying source type 2022-04-19 12:34:03 +01:00
lightningterror
8a6c896dde vcxproj.filters: Adjust d3d shader and source file group naming to accommodate d3d12 addition. 2022-04-19 10:54:45 +02:00
lightningterror
b3c7b07813 GS-qt: Gray out texture barriers and geometry shaders on d3d or sw renderers. 2022-04-19 10:52:59 +02:00
lightningterror
65072ddbe5 readme: Remove broken screenshots.
Ideally we should put new ones.
2022-04-18 22:38:44 +02:00
lightningterror
d42fb851a2 GS-wx: Gray out texture barriers and geometry shader options on d3d. 2022-04-18 22:01:25 +02:00
lightningterror
ea0791a3bf pine: Fix Wswitch-bool warning. 2022-04-18 21:10:35 +02:00
lightningterror
8d4df7f74b spu2: Fix Wunused-private-field warning. 2022-04-18 21:10:35 +02:00
PCSX2 Bot
4b07eae80e PAD: Update to latest controller database. 2022-04-18 18:02:26 +02:00
lightningterror
77162ff637 GS-d3d11: Purge the NVIDIA hack.
The driver issue got resolved by nvidia.
2022-04-18 17:25:32 +02:00
Timothy O'Barr
e10f414724 CDVD: Rename cdrom files to Ps1CD for clarity of function (#5907) 2022-04-18 12:15:23 +01:00
Mrlinkwii
53c3f253e6 GameDB:add 'EETimingHack' to'Harry Potter and the Chamber of Secrets' 2022-04-18 12:14:22 +01:00
Connor McLaughlin
b0f20c9973 GS/DX11: Fix MMOD=1 merge background color 2022-04-18 04:29:19 +01:00
Sam H
5c3ae656a0 GS: fix display width calculation for frame when offsets off 2022-04-17 23:21:50 +01:00
TellowKrinkle
a98efdfedd GS: Per-selector C draw scanline 2022-04-17 15:22:49 -05:00
TellowKrinkle
3b8eb6731c Add more values to GSScanlineSelector ToString 2022-04-17 15:22:49 -05:00
TellowKrinkle
89bc4707ab Add to_string to GSScanlineSelector 2022-04-17 15:22:49 -05:00
TellowKrinkle
e5a8b01980 GS: Always compile C rasterizer 2022-04-17 15:22:49 -05:00
Connor McLaughlin
7194542029 Qt: Fix fullscreening in Wayland 2022-04-17 11:56:37 +01:00
Connor McLaughlin
06beadba74 CdRom: Fix clear error bit in StartReading() 2022-04-17 11:42:48 +01:00
Connor McLaughlin
b10249af7d CdRom: Remove Speed field/add accessor instead
This way it doesn't break save states.
2022-04-17 11:42:48 +01:00
Ty Lamontagne
1f04214461 Dmac: LegacyDmac.cpp -> Dmac.cpp 2022-04-17 10:54:39 +01:00
SeraphisCain
39d611e870 GameDB: Transformers Tatakai, T3: The Redemption, Urban Reign
GameDB fixes for a few games.
2022-04-17 10:47:09 +01:00
Connor McLaughlin
b913d39a50 Common/Timer: Fix closing invalid handle on Win32
Only is an issue if you have a debugger attached and the exception
enabled.
2022-04-17 10:45:22 +01:00
TellowKrinkle
eb60e9aa9b Common: Avoid libstdc++ assert 2022-04-17 10:44:02 +01:00
Mrlinkwii
53bb0c508f GameDB: upscaling fixes and documentation updates 2022-04-16 19:40:26 +01:00
Connor McLaughlin
1c50d3e4b3 GS: Add stat for barriers 2022-04-16 19:10:18 +01:00
Connor McLaughlin
de724d9570 GS/HW: Skip unnecessary barriers (usually two pass alpha) 2022-04-16 19:10:18 +01:00
Connor McLaughlin
e8293b2e06 GS/Vulkan: PrimID DATE doesn't need feedback loop 2022-04-16 19:10:18 +01:00
refractionpcsx2
904345ff82 GS: Get display width for frame when offsets off 2022-04-16 18:21:00 +01:00
Connor McLaughlin
d16592817b Frontend/OpenGLHostDisplay: Remove unused variables
clang likes to whinge about this one.
2022-04-16 13:57:23 +02:00
Connor McLaughlin
14f1a78608 GS/DX12: Fix DATE not being set in shader macros 2022-04-16 03:57:04 +01:00
refractionpcsx2
68c2a68087 microVU: Clean up warnings 2022-04-16 03:20:54 +01:00
refractionpcsx2
ae83f729db USB: Clean up warnings 2022-04-16 03:20:54 +01:00
refractionpcsx2
c53f4d0d63 SPU2: Clean up warnings 2022-04-16 03:20:54 +01:00
refractionpcsx2
cbb3134740 App/BIOS: Clean up warnings 2022-04-16 03:20:54 +01:00
refractionpcsx2
9b97c157f2 Recording: Clean up warnings 2022-04-16 03:20:54 +01:00
refractionpcsx2
11cf244e97 GS: Clean up warnings 2022-04-16 03:20:54 +01:00
kenshen112
6673bd9212 CDVD.cpp: Remove Elf parser from ps1 mode. 2022-04-16 03:19:21 +01:00
kenshen112
02dfc5d20d cdrom: Update status flags and implementations for PSX CD-Rom.
Added SEEKERROR and IDERROR status. Set StatP to account for SEEKS, READS and shell open.
Added speed to cdrom struct instead of cdvd. Adjustments to cdlPlay to be in line with No$ description.
Added MODE_INIT. Removed old needless hack. Added ToDo in cdlPlay
2022-04-16 03:19:21 +01:00
SeraphisCain
565ff86ab4 GameDB: Several game fixes and a gamelist entry correction (#5872) 2022-04-16 02:50:36 +01:00
refractionpcsx2
5a77790859 BIOS/GUI: Mark Qt only variables as maybe unused 2022-04-16 02:59:21 +02:00
refractionpcsx2
66101f8628 SPU2: Clean up warnings 2022-04-16 02:59:21 +02:00
refractionpcsx2
2f70b153f2 GS: Clean up warnings, fix a small error. 2022-04-16 02:59:21 +02:00
refractionpcsx2
31fe9979dd GS: Fix undefined behaviour on interlacing 2022-04-15 22:12:04 +01:00
RedDevilus
4fc6e9240c OSD: Minor clean up
Fixes variable for interlacemode
2022-04-15 22:01:48 +01:00
RedDevilus
0eae59ee66 GameDB: Black
GameDB Black roundsprite to half for lighting.
2022-04-15 22:01:48 +01:00
RedDevilus
8e6cd47f25 PCSX2: Fix Interlacing Ini
Oversight in having the correct config for the ini. Replaced CycleMipmap mode with the CycleInterlace one for correct OSD message.
2022-04-15 20:34:51 +01:00
Connor McLaughlin
ecdbe17fba Wx: Fix widescreen patch loading 2022-04-15 19:44:05 +01:00
Connor McLaughlin
0e9dcf74b2 Common/Semaphore: Fix WaitWithYield() returning immediately
This caused the WaitGS() issued from the main thread when applying
renderer settings (while the core thread was paused) to return
immediately, and a massive race resuming.
2022-04-15 19:43:22 +01:00
RedDevilus
5297c2a995 GameDB: Japanese entries
Adds a bunch of gamefixes and upscaling fixes to games as well as just entries.
Fixes:
- 0 Story
- Amagami
- Bleach Blade Battlers 2nd
- Chobits
- D.C. Da Capo The Origin
- Pandora - Kimi no Namae o Boku wa Shiru
- Katekyoo Hitman Reborn! Nerae!? Ring x Vongola Trainers
- Kateikyoushi Hitman Reborn!! Let's Ansatsu! Nerawareta 10 Daime!
- Kino no Tabi - The Beautiful World
- Kyuuketsu-hime Yui - Sen'yashou
- Shikigami no Shiro - Nanayozuki Gensoukyoku
- Secret of Evangelion
2022-04-15 19:41:48 +01:00
Connor McLaughlin
edf5e2c14e Vulkan/Context: Use static loading for vk_mem_alloc
In doing so, we simplify things a bit, as we can assume Vulkan 1.1
support. It needed it before anyway, and would crash on Vulkan 1.0
drivers.
2022-04-15 19:41:12 +01:00
Connor McLaughlin
9180adb850 VulkanHostDisplay: Handle surface loss better
Just try again next frame.
2022-04-15 19:41:12 +01:00
Connor McLaughlin
1b080f1777 Vulkan/Loader: Make vkDestroyInstance() a module import 2022-04-15 19:41:12 +01:00
Connor McLaughlin
0a2584172a GS/HW: Clear blend bits for color dest blend 2022-04-15 16:55:24 +02:00
Connor McLaughlin
1993203d26 GS: Add Direct3D 12 renderer 2022-04-15 12:56:41 +01:00
Connor McLaughlin
3c18cdcb1f Frontend: Add D3D12HostDisplay 2022-04-15 12:56:41 +01:00
Connor McLaughlin
e767fb8d35 Common: Add D3D12 wrapper/helper classes 2022-04-15 12:56:41 +01:00
Connor McLaughlin
3255422836 Common/StringUtil: Optimize equal stride copy case 2022-04-15 12:56:41 +01:00
Connor McLaughlin
67fa06b933 3rdparty/imgui: Enable DX12 backend 2022-04-15 12:56:41 +01:00
Connor McLaughlin
398e468c9e 3rdparty: Add D3D12MemoryAllocator 2022-04-15 12:56:41 +01:00
Connor McLaughlin
f7ee35e578 Wx: Reset/restore API state after window resize 2022-04-15 12:56:41 +01:00
Connor McLaughlin
800b458d3d Wx: Fix incorrect OSD scale after resize on Windows 2022-04-15 12:56:41 +01:00
Connor McLaughlin
3f31a4d25b GS: Fix edge case of broken alpha with no-DSB+ATST 2022-04-15 12:56:41 +01:00
Connor McLaughlin
0592abd31b GL/ContextEGL: Fix broken surface creation
Regression from #5676.
2022-04-15 11:46:07 +01:00
refractionpcsx2
55d546b892 GS: Maintain framebuffer size when not using offsets
This reduces blurriness
2022-04-15 11:07:22 +01:00
refractionpcsx2
f28e42c4fe GS: Set correct framebuffer size for output 2022-04-15 11:07:22 +01:00
refractionpcsx2
7cdc849ffa GS: Clean up new DISPLAY Merging code. 2022-04-15 11:07:22 +01:00
refractionpcsx2
eed04b3ff3 GS: Redesign some of the offset code for FFMD
Half height buffers need to be drawn half height, not stretched to full height during the draw, it will be bad times.
2022-04-15 11:07:22 +01:00
refractionpcsx2
e2044eba66 GS/Window: Add Automatic 4:3/3:2 mode, keep 4:3 separate 2022-04-15 11:07:22 +01:00
refractionpcsx2
06e6d12e2f GS: Added automatic 3:2 aspect for 480p mode 2022-04-15 11:07:22 +01:00
refractionpcsx2
48fd68ca87 GS: Implement PCRTC Offsets
This is off by default because people will complain about black borders, but I've tried to keep it to a minimum.

Enabling this option (Screen Offsets in the graphics settings) will allow you to position the screen in games which allow you to do so, maintain correct aspect ratios, and screen shake effects which are done on PCRTC (WipEout Fusion for example) will work.
2022-04-15 11:07:22 +01:00
refractionpcsx2
7ad59a7af1 GS: Remove NTSC Saturation option (No longer required) 2022-04-15 11:07:22 +01:00
refractionpcsx2
bae2c9c1d8 GS: Saturate DISPLAY heights and limit max height 2022-04-15 11:07:22 +01:00
Connor McLaughlin
3d171686b5 CI/Windows: Switch to Qt 6.3.0 2022-04-15 08:53:02 +01:00
Connor McLaughlin
f86b3a32cd Qt: Switch to QtEntryPoint.lib instead of explicit main() 2022-04-15 08:53:02 +01:00
Connor McLaughlin
59d6113ee4 VSProps: Fix Qt TLS plugins not getting copied 2022-04-15 08:53:02 +01:00
Connor McLaughlin
f270f34865 Qt: Move to Qt 6.3.0 2022-04-15 08:53:02 +01:00
Connor McLaughlin
b2514d49d2 3rdparty/wx: Fix compilation in MSVC conformance mode 2022-04-15 08:53:02 +01:00
Tyler Wilding
2951068e0c memcard: Detect and attempt to repair broken index files from the v1.7.2115 bug 2022-04-15 08:47:46 +01:00
Ty Lamontagne
a4dcaa7c14 BiosTools: Allow BIOS region patching 2022-04-15 08:44:46 +01:00
TellowKrinkle
b90de6d89f PAD: Process keycodes the same way on Linux and macOS 2022-04-15 08:43:12 +01:00
BuildTools
532a7addd4 Documentation: Update recommended OpenGL version 2022-04-15 08:42:59 +01:00
tcoyvwac
5389178644 Common: Prefer standard algorithms
GL/ContextEGL.cpp:
Prefer std::find_if over ranged-for.
2022-04-15 08:42:29 +01:00
tcoyvwac
6cbdc8c8b7 Common: Prefer pre-built array-form to assign values.
GL/ContextEGL.cpp:
Replace raw-index manipulation / arithmetic as logic. Now a variable-length array.
2022-04-15 08:42:29 +01:00
tcoyvwac
6e6a70b8ed Common: Prefer returning std::array by lambda expression
GL/ContextEGL.cpp:
Replace raw-index manipulation / arithmetic as logic. Variable now using IIFE (Immediately invoked function expression) to strengthen immutability.
2022-04-15 08:42:29 +01:00
TellowKrinkle
1a0a0423e7 Core: Switch MTGS and SysThreadBase to WorkSema 2022-04-15 08:41:58 +01:00
TellowKrinkle
b28779b0f6 Common: Add dead thread support to WorkSema
MTGS supports having exceptions kill the thread and send their result back to a thread calling WaitGS...
2022-04-15 08:41:58 +01:00
TellowKrinkle
63fd349e3c GS: Switch GSJobQueue to WorkSema 2022-04-15 08:41:58 +01:00
TellowKrinkle
481c92c1c8 MTVU: Use WorkSema 2022-04-15 08:41:58 +01:00
TellowKrinkle
d733730950 Common: Add WorkSema 2022-04-15 08:41:58 +01:00
SeraphisCain
93a9e5dd83 GameDB: Fixes for Wrestle Kingdom 1 + 2 (#5863) 2022-04-15 08:24:14 +01:00
TellowKrinkle
db9672509c 3rdparty: Update fmt to 8.1.1 2022-04-15 08:22:13 +01:00
Mrlinkwii
ffe69d313b GameDB: add missing serials 2022-04-15 08:19:43 +01:00
Silent
502a44e9f5 XInputSource: Add support for SCP API extension
Allows to query pressure sensitive DualShock 3 buttons via
XInput when DsHidMini is used in SXS mode, with its xinput1_3.dll dropped
in the emulator directory.
2022-04-15 08:18:57 +01:00
Silent
5e913b0e9e XInputSource: Fix triggers input range 2022-04-15 08:18:57 +01:00
Connor McLaughlin
864651ce8d System: Purge WinCompressNTFS.cpp
This is the most overengineered, stupid rubbish I've ever seen.
2022-04-15 08:15:40 +01:00
Connor McLaughlin
850deed6c1 HwRegs: Swap wxString desc() for std::string 2022-04-15 08:15:40 +01:00
Connor McLaughlin
63424b765d CDVD: Purge wxString 2022-04-15 08:15:40 +01:00
Connor McLaughlin
a635e84d82 FileSystem: Add path splitting helpers 2022-04-15 08:15:40 +01:00
Connor McLaughlin
6991f819f3 SaveState: Switch to zstd compression
zstd can be 10x+ fast compressing, 2x+ decompressing at default levels,
and provides slightly better ratios.

There's a hidden option in the config, SavestateZstdCompression, which
you can set to false if you want to use deflate.
2022-04-15 08:15:40 +01:00
Connor McLaughlin
a22c634cd4 3rdparty: Add zstd 2022-04-15 08:15:40 +01:00
Connor McLaughlin
80aaa962ec Common: Move IniInterface to WX GUI
Qt doesn't use it.
2022-04-15 08:15:40 +01:00
Connor McLaughlin
876ea3db52 Common: Purge pxStreams and some other wx string routines 2022-04-15 08:15:40 +01:00
Connor McLaughlin
1bfc0f3138 CDVD: Remove wxStr from SYSTEM.CNF parsing 2022-04-15 08:15:40 +01:00
Connor McLaughlin
5fa9427323 Patch: Store gamedb patches as single string 2022-04-15 08:15:40 +01:00
Connor McLaughlin
29cea58471 Patch: Remove all wx usage 2022-04-15 08:15:40 +01:00
Connor McLaughlin
4779bc830a StringUtil: Add more whitespace cleaners and ParseAssignmentString 2022-04-15 08:15:40 +01:00
Connor McLaughlin
dd8a645986 SaveState: Use libzip instead of wx 2022-04-15 08:15:40 +01:00
Connor McLaughlin
9aa2c52b20 3rdparty: Add libzip 2022-04-15 08:15:40 +01:00
Connor McLaughlin
0914b2a474 Qt: Fix compiling without Vulkan renderer 2022-04-15 07:21:18 +01:00
Connor McLaughlin
d387a1f4dc GS: Support compiling without OpenGL renderer 2022-04-15 07:21:18 +01:00
arcum42
3488aa54be Remove wx code from build.sh and a bit of cleanup. (#5817)
* build: Fix up the menu printed by build.sh.

* build: Removed wx code from build.sh.
2022-04-14 22:04:26 -07:00
lightningterror
de541aeba9 GS: Remove unused default configs. 2022-04-14 12:07:59 +02:00
lightningterror
5fb00bd6c7 GS: Fix some log warnings. 2022-04-14 00:47:08 +02:00
kenshen112
fdabc82342 Remove IopCommon.h added proper includes to files. Removing circle includes in several files that sometimes was several layers deep 2022-04-11 21:25:20 +01:00
refractionpcsx2
e5f90f176c Emitter: Fix s8 problem with displacements 2022-04-11 21:09:12 +01:00
PCSX2 Bot
6438547edc PAD: Update to latest controller database. 2022-04-11 18:33:35 +02:00
dependabot[bot]
0f0ab25fe8 Bump actions/upload-artifact from 2 to 3
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-11 10:45:35 +01:00
TellowKrinkle
fc7a20dd0f wx: Fix compile on wx 3.1.6 2022-04-11 10:45:06 +01:00
TellowKrinkle
f8c7237bba i18n: Formatting 2022-04-11 10:45:06 +01:00
Ty Lamontagne
00af7d6835 GSState: Remove transfer direction warning 2022-04-10 07:19:52 +01:00
refractionpcsx2
86fb8e5809 GS: Flush PRIM on write if pending PRIM draw had TME 2022-04-08 11:46:27 +01:00
RedDevilus
29964c3f26 Qt: Fix interlacing
I actually made it backwards compatible but then reverted this line at the last minute, rendering the Qt variant useless. This fixes it again.
2022-04-08 08:24:54 +01:00
RedDevilus
ec787d090d Qt: Add Gzipped
WX supported this, I don't see why not add to Qt. Though no idea why anyone wants to use it above CSO or CHD if you look at filesize.
2022-04-08 08:24:54 +01:00
Connor McLaughlin
f9707e6809 LnxMisc: Use clock_gettime() instead of gettimeofday() 2022-04-07 21:22:24 +01:00
RedDevilus
5665e5e222 GameDB: Fix name + add comment
Fixes Ar Tonelico II and adds comments for Legion - The Legend of Excalibur
2022-04-06 21:06:55 +01:00
Mrlinkwii
336e5c77fe Gamedb: add 'VUSyncHack' to 'Next Generation Tennis 2003' 2022-04-06 20:36:43 +01:00
RedDevilus
d8b107f59c PCSX2: Interlacing to Deinterlacing
There are some more strings but don't want to mess around with too much
2022-04-06 19:19:01 +01:00
RedDevilus
19197fabe8 GameDB: God Of War 1 / 2
The GameDB changes were reverted but then the CRC hacks were removed so this fixes it.
2022-04-06 17:40:07 +01:00
Connor McLaughlin
3801825793 R3000A/R5900: Refactor interpreter/recompiler exits
Now, IOP breakpoints work nice and reliably in both interpreter and
recompiler, exiting as soon as possible, without leaving the event state
indeterminate.
2022-04-06 15:27:15 +01:00
Connor McLaughlin
25e15a16b1 VMManager: Add frame advance hotkey
Now that exits are consistent, this is easy.
2022-04-06 15:27:15 +01:00
Connor McLaughlin
5ac9419703 R5900: Make CPU exits consistent and safe
Previously, we would either throw an exception (ints), or longjmp out of
the recompiler when the execution state was checked. Unfortunately for
our stability, this happened at the end of the frame, just before it was
pushed to the GS, and in the middle of processing EE events (!).

Doing so not only meant that we executed a bunch of event
testing/exception code twice (once after we paused, again when we
resumed), but it also could potentially leave things in an inconsistent
state.

So instead, let's do it safely with a flag, replacing the old
iopBreakpoint flag, so there's no additional overhead on the hot path.
2022-04-06 15:27:15 +01:00
Connor McLaughlin
821e15f1ee Qt: Add QtHost::RunOnUIThread() 2022-04-06 15:22:39 +01:00
Connor McLaughlin
0efe03e726 Qt: Implement Host::RunOnCPUThread() 2022-04-06 15:22:39 +01:00
seta-san
577d6e735c Gamedb: Add Bumpy Trot Trial serial 2022-04-06 15:17:47 +01:00
Ty Lamontagne
7668123aaa gitignore: ignore bin/textures 2022-04-06 01:30:22 +02:00
Mrlinkwii
0b87d580c3 Gamedb: Add Hachi-One Diver serial. (#5828) 2022-04-05 20:40:14 +02:00
Connor McLaughlin
170a03cac6 GSDump: Drop last packet of truncated dumps 2022-04-05 12:08:06 +01:00
PCSX2 Bot
70d8acb812 PAD: Update to latest controller database. 2022-04-05 13:02:32 +02:00
TheLastRar
2670d5a9aa Core: Move Applying GameFixes into GameEntry
Also add similar logging to GS Hardware fixes (on Qt)
2022-04-05 11:12:14 +01:00
TheLastRar
44081671ac Config: Fix saving/loading EnableGameFixes in Core 2022-04-05 11:12:14 +01:00
refractionpcsx2
462b304bea GameDB: Update Simple Series entries 2022-04-05 11:06:58 +01:00
Odin Vex
059f58803c Remove erroneous unmanaged cleanup of managed code
`loadYamlFile` calls `OpenManagedCFile` which handles closing the file-handle used. Thus, closing the file-handle outside the API call to `OpenManagedCFile` is not necessary.
2022-04-05 11:04:51 +01:00
refractionpcsx2
e170e9281d GS: Fix reversed reversed GS copies. 2022-04-04 18:07:54 +01:00
Connor McLaughlin
5987e03463 GS: Force min/mag linear when trilinear is forced
Trilinear implies that min/mag will be linear. Less confusing, makes
sense, and the min/mag point + mip linear case is currently not handled
properly with regard to the GS registers.
2022-04-04 17:01:23 +01:00
Connor McLaughlin
ddbdfd47be GS: Make hardware renderer trilinear consistent
Trilinear without bilinear was inconsistent previously.
2022-04-04 17:01:23 +01:00
Connor McLaughlin
1b83e17d60 GS: Add automatic trilinear filtering level 2022-04-04 17:01:23 +01:00
AndreAuth
bc7ed4e7d0 GameDB: Metal Gear Solid 3 PAL - Fix blurry characters (#5819) 2022-04-04 11:33:16 +01:00
refractionpcsx2
283c7fa88c GS: Improve autoflush rect checks 2022-04-04 11:25:25 +01:00
Connor McLaughlin
d01ee3163d Qt: Add performance metrics to status bar 2022-04-03 23:59:05 +01:00
Mrlinkwii
90457e32b6 Gamedb: update changes to pdf 2022-04-03 10:09:05 +01:00
refractionpcsx2
4cb6c94693 CI/Docs: Update validation and document 2022-04-03 08:50:09 +01:00
refractionpcsx2
93c78a27b3 GS: Add interlace override to gamedb, revert earlier change 2022-04-03 08:50:09 +01:00
Connor McLaughlin
50452848e7 BiosTools: Bounds check strings in LoadBiosVersion() 2022-04-03 07:57:42 +01:00
Connor McLaughlin
4f70fd9583 VMManager: Make EE rec toggles reliable
Before, it'd swap out the Cpu while it was executing...
2022-04-03 07:57:02 +01:00
Connor McLaughlin
e6c8354ec8 EERec: Purge PCSX2_SEH define
No longer needed since we don't have 32-bit.
2022-04-03 07:57:02 +01:00
Connor McLaughlin
a1e77002c3 iR5900: Exit on NeedsReset not IsReset
This is an edge case which can be hit in Goemon, but also when changing
settings in Qt, as they will be applied at guest vsync time, which is
called within the JIT.

Also, do the reset before entering JIT code, rather than when the first
block is compiled.
2022-04-03 07:57:02 +01:00
Connor McLaughlin
099cd52381 gitignore: Remove unused portaudio files 2022-04-03 06:09:09 +02:00
lightningterror
0d1675fbaa GS-hw: Purge custom resolution entirely.
Code debt, not used anymore, get rid of it.
2022-04-02 16:54:26 +02:00
lightningterror
f021da5627 GS-tc-hw: Fix Normal Half pixel offset on 7x upscale. 2022-04-01 13:58:54 +02:00
refractionpcsx2
906480b8e2 GS: Only flush on PRIM if a new draw is requested 2022-04-01 10:48:22 +01:00
refractionpcsx2
38b83af714 GS: Improve interlace handling and odd frames 2022-04-01 10:48:01 +01:00
Tyler Wilding
05dab12b7c releases: simplify discord announcements, and link to the right page 2022-04-01 10:45:59 +01:00
TellowKrinkle
c0628a64a6 GS: Add Metal renderer to settings 2022-03-31 23:51:27 -05:00
TellowKrinkle
5ecaa9459d GS: Add Metal renderer 2022-03-31 23:51:27 -05:00
TellowKrinkle
24b2277206 GS: Give names to blend enums 2022-03-31 23:51:27 -05:00
TellowKrinkle
8e60d2c72e GS: Rename Int32 texture to PrimID
Not always Int32
2022-03-31 23:51:27 -05:00
TellowKrinkle
cfe2f9e6b4 Common: Add helpers for enum classes 2022-03-31 23:51:27 -05:00
TellowKrinkle
0a11b5898a CMake: Disable PCH for mm files 2022-03-31 23:51:27 -05:00
TellowKrinkle
be49de6fa0 Config: Format Pcsx2Config 2022-03-31 23:51:27 -05:00
RedDevilus
1ad52e918b GameDB: Caspian
Reduces ghosting but on normal vertex causes the rainbow corruption at the screen sides
2022-03-31 15:45:12 +01:00
Tzerinas
53388336d2 GameDB: Fixes for Tomb Raider Games
Added the FMV Hack for every game except Underworld and the missing mipmap Setting for the US version of Legend.
2022-03-31 15:44:58 +01:00
Chromaryu
4e1496e736 GameDB: Add Zwei AutoFix 2022-03-31 15:43:22 +01:00
RedDevilus
216c964d13 GameDB: Silent Hill Origins
Wildarms while making the alignment perfect in the 3D environment, messes with the maps.
2022-03-31 12:03:31 +01:00
Angel Toloza
6bb828eb8f GameDB : Atelier Marie + Elie: Salburg no Renkinjutsushi 1&2 (#5784) 2022-03-30 23:45:14 +01:00
Tzerinas
511845a1c4 GameDB: Corrected GSHW Fixes for Radiata Stories
Adds Special (Texture) and Align Sprite to Radiata Stories.
2022-03-30 23:39:28 +01:00
RedDevilus
89f10e1605 GameDB: ':' to '-' + GS and other fixes
Windows doesn't like you to use ':' in folders this caused issues for when CK1 did savestates in folders and now it's also messing with unable to add covers in Qt so better to replace them and also to avoid other issues now and the future.
GS HW Fixes and other fixes for:
- Adventures of Cookie & Cream, The
- Brothers in Arms - Earned in Blood / Road to Hill 30
- Black
- Chaos Legion
- God Hand
- Knockout Kings 2001
- Kuon
- Outrun 2006 / 2 SP
- Project Eden
- Psi-Ops - The Mindgate
- Punisher, The
- Ratchet Deadlocked (USA) / Gladiator (Europe) / 3 Up Your Arsenal
- Silent Hills Origins / Shattered Memories / 3 / 4
- SoulCalibur II / III

Also made sure that the comments and their spacing were consistent.
2022-03-30 23:38:18 +01:00
Connor McLaughlin
76b4e93604 Vulkan/ShaderCache: Don't delete cache when running 2 instances 2022-03-30 12:38:08 +02:00
Connor McLaughlin
cec089a271 D3D11/ShaderCache: Don't delete cache when running 2 instances 2022-03-30 12:38:08 +02:00
PCSX2 Bot
b4bd36c4b2 PAD: Update to latest controller database. 2022-03-28 18:04:15 +02:00
RedDevilus
338eb42b04 Qt: Reduce max SPU - Change Speed Preset
Qt has a leftover from the old SPU2-X values which is 3000 ms (3 seconds) latency meaning that if an user sets it to the max it will do something like this: Videoframe ~150 / 180 happens and it makes the first sound after 3 seconds for the first videoframe which is far too long. Also changed 1% speed as it messed with the GSdump player and too stuttery to be usable in other usecases.
2022-03-28 10:44:04 +01:00
lightningterror
8e42fce0aa gamedb: Add alignSprite to GOW 2.
Fixes water vertical lines.
2022-03-28 10:16:59 +02:00
lightningterror
a7900b342e GS-hw: Purge GodOfWar 1 and 2 crc hacks.
Not needed, can be solved with upscaling hw hacks, and gs db fixes are a thing.
2022-03-28 09:59:41 +02:00
Connor McLaughlin
506bbe1c08 GS/OpenGL: Don't emit #extension after #define for FXAA
This is technically not valid GLSL.
2022-03-28 09:24:51 +02:00
Connor McLaughlin
d32d8cc0ec Shaders/FXAA: Fix warnings with Vulkan compiler 2022-03-28 09:24:51 +02:00
Connor McLaughlin
0cb9655523 GS/Vulkan: Remove unused color attribute
Would likely be getting optimized out anyway.
2022-03-28 09:24:51 +02:00
Connor McLaughlin
3067bef82d GS/Vulkan: Implement FXAA 2022-03-28 09:24:51 +02:00
Connor McLaughlin
486764be03 GS/Vulkan: Implement shadeboost 2022-03-28 09:24:51 +02:00
Connor McLaughlin
5e336138d0 Qt: Add shadeboost settings 2022-03-28 09:24:51 +02:00
Connor McLaughlin
4a5180bc0a GS: Put shadeboost params in uniforms
Compiling variants for these is silly.
2022-03-28 09:24:51 +02:00
dependabot[bot]
dd28e33612 Bump peter-evans/create-pull-request from 3 to 4
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 3 to 4.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](https://github.com/peter-evans/create-pull-request/compare/v3...v4)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-28 09:10:03 +02:00
dependabot[bot]
b66c0411df Bump actions/cache from 2.1.7 to 3
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.7 to 3.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.7...v3)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-28 09:09:41 +02:00
arcum42
c59b114a1d Build: Remove cross compiling from build.sh. (#5713) 2022-03-27 17:38:41 -07:00
TheLastRar
352faeddb2 DEV9: Add Socket api mode 2022-03-27 16:16:19 +01:00
TheLastRar
140d44d826 DEV9: Add code for reading ARP, TCP & ICMP packets 2022-03-27 16:16:19 +01:00
TheLastRar
db220001f6 DEV9: Add cloning of packets 2022-03-27 16:16:19 +01:00
TheLastRar
5ac9b5576a DEV9: Add PayloadData classes 2022-03-27 16:16:19 +01:00
TheLastRar
b23873e0ed DEV9: Add adapter reset function 2022-03-27 16:16:19 +01:00
TheLastRar
284ec35699 DEV9: Add GetHeaderLength() to IP_Packet 2022-03-27 16:16:19 +01:00
TheLastRar
cb0e629dd3 DEV9: Make internal servers protected 2022-03-27 16:16:19 +01:00
TheLastRar
1aaadd6228 DEV9: Make DHCP_Server::GetGatewaysLinux() public
Needed for auto adapter on linux, if only to check if an adapter has a gateway
2022-03-27 16:16:19 +01:00
TheLastRar
e20a357340 DEV9: Allow user DHCP settings to be overridden 2022-03-27 16:16:19 +01:00
TheLastRar
fef2952d47 DEV9: Fix typo in DHCP_Packet 2022-03-27 16:16:19 +01:00
TheLastRar
f4b2e0dd7a DEV9: Correct PayloadPtr::WriteBytes() 2022-03-27 16:16:19 +01:00
Connor McLaughlin
d3aace98ac GS/OpenGL: Fix fb target conflict without fbfetch 2022-03-27 04:33:20 +01:00
Connor McLaughlin
3a7f82eb66 GS/HW: Fix fbmask not inserting barriers
Or, missing the fb copy for D3D/barriers off.

Regression from fbfetch PR.
2022-03-27 04:33:20 +01:00
Connor McLaughlin
3e24b678c4 Build: Don't install pcsx2 core static lib on Linux 2022-03-26 14:11:33 +00:00
Connor McLaughlin
2ab6ca06ed Qt: Fix compile issues on Linux 2022-03-26 14:11:33 +00:00
Connor McLaughlin
9ac5041b43 Qt: Fix double entries in audio output modules 2022-03-26 14:11:33 +00:00
Connor McLaughlin
9262422d01 Qt: Add missing null terminator in audio settings 2022-03-26 07:56:52 +00:00
Mrlinkwii
9f04becc7a GameDB : various game improvements 2022-03-25 17:00:57 +00:00
RedDevilus
8485af6cac GameDB: GS HW Fix XI
The game also needs round sprite half for the transitional areas and red forest because of vertical lines similar to Star Ocean 3.
+ other fixes, read the GameDB comments for more information.
Relevant games:
- Atelier Iris 3 - Grand Phantasm
- Baldur's Gate - Dark Alliance 1 / 2
- Call of Duty 2 - Big Red One
- Dark Cloud 1 / 2
- Mana Khemia 1 / 2
- Sims 2 - Castaway
- Valkyrie 2 - Silmeria
2022-03-25 16:31:07 +00:00
TheLastRar
48f7e6c63f DEV9: Add Qt UI 2022-03-25 13:50:25 +00:00
TheLastRar
e1fb84d6a3 DEV9: Separate HddCreate code from Wx
Also disable auto generating an image on boot if one is not found
2022-03-25 13:50:25 +00:00
TheLastRar
5db9a738c5 Config: Integrate internal DNS host list on Qt 2022-03-25 13:50:25 +00:00
TheLastRar
145e75624d Config: Allow setting DNS1/2 internal instead of manual/auto 2022-03-25 13:50:25 +00:00
Connor McLaughlin
d09b49e17c Qt: Hook up automatic mapping 2022-03-25 12:51:31 +00:00
Connor McLaughlin
fdc3ca1227 PAD: Add automatic mapping functions 2022-03-25 12:51:31 +00:00
Connor McLaughlin
51d47a1455 InputManager: Add generic input mappings 2022-03-25 12:51:31 +00:00
Connor McLaughlin
9504671919 PAD: Add macro buttons 2022-03-25 12:51:31 +00:00
Connor McLaughlin
e5248db844 StringUtil: Add SplitString() 2022-03-25 12:51:31 +00:00
Connor McLaughlin
551d013b63 Qt: Add shutdown hotkey 2022-03-25 12:51:18 +00:00
Connor McLaughlin
d65950cda2 VMManager: Add BIOS check on startup
Except when running GS dumps.
2022-03-25 12:51:18 +00:00
Connor McLaughlin
15c38a0a4e GSDumpReplayer: Add missing license header 2022-03-25 12:51:18 +00:00
TheLastRar
74ed14496b Qt: GS Settings Fixes 2022-03-25 10:26:23 +00:00
Connor McLaughlin
1fa6fb0a8c Qt: Add memory card settings 2022-03-25 10:26:09 +00:00
Connor McLaughlin
3dc6ae115f Qt: Implement (partial) audio settings 2022-03-25 10:26:09 +00:00
Connor McLaughlin
fa36b9b5cb MemoryCardFile: Add formatted/mtime to query, rename/delete ops 2022-03-25 10:26:09 +00:00
Connor McLaughlin
47fff9304b FileSystem: Add DeleteDirectory() and recursive variant 2022-03-25 10:26:09 +00:00
Mrlinkwii
29c0d93864 GUI/Docs : update compatibility URLs 2022-03-23 10:27:36 +00:00
RedDevilus
38ff521851 GameDB: Megaman + Nicktoons
Megaman X - Command Mission flickering FMV fix and fix for the lighting in the game Nicktoons Unite!
2022-03-22 22:02:30 +00:00
RedDevilus
34de1bffc6 GameDB: Remove outdated comments
The gameDB still had some leftover comments that aren't true anymore. In the past before 1.7.2002 / https://github.com/PCSX2/pcsx2/pull/3936 you needed to use full boot to correctly pass your chosen BIOS language to be piped to the game. Basically fast boot defaulted to the first entry in the available language list.
Full boot:
If you want to see BIOS logo - Good
Region check - Bad

Fast boot:
Immediately jump into the game - Good
Skips region check - Good
Now acts like full boot for languages - Good
2022-03-22 20:58:02 +00:00
Connor McLaughlin
8dc1592278 GSDumpReplayer: Fix ReadFIFO2 packet executing on wrong thread 2022-03-22 16:50:31 +00:00
Mrlinkwii
5b86205349 Gamedb: add 'VUSyncHack' to Totally Spies! Totally Party 2022-03-22 14:45:35 +00:00
Mrlinkwii
0d4fbd540e Gamedb: Fix 'SLES-54453' title 2022-03-22 14:27:39 +00:00
Connor McLaughlin
b9edabc236 Qt: Fix incorrect setting binding for display linear 2022-03-22 13:38:26 +00:00
Connor McLaughlin
180d9ae9c9 Qt: Correct EE/IOP console defaults 2022-03-22 13:38:26 +00:00
Connor McLaughlin
80cc2f0cb7 Qt: Log machine caps on startup 2022-03-22 13:38:26 +00:00
Connor McLaughlin
1927896442 GS: Fix some edge cases with fbfetch
Second alpha pass with A masked, DATE enabled, etc.
2022-03-21 20:24:09 +00:00
RedDevilus
bf9c1176b6 GameDB: Fix Midnightclub 3 + Add Evangelion Jo
Special texture to:
Midnight club 3
Evangelion - Jo
2022-03-21 20:23:54 +00:00
Tzerinas
166156519a GameDB: Fixes to TeamICO games.
Adds the Software Renderer FMV hack to ICO and Half-Pixel Offset (Vertex) to both games.
2022-03-21 20:16:46 +00:00
lightningterror
d89daa1b25 misc: A few more 32bit cleanups. 2022-03-21 20:56:03 +01:00
lightningterror
efc17f265c readme: Update to reflect recent drop of 32bit. 2022-03-21 20:28:33 +01:00
lightningterror
8427e6fd3e emitter test: Cleanup 32bit code. 2022-03-21 20:21:36 +01:00
lightningterror
f1ac712eba build: Remove _M_X86_64, __M_X86_64, _M_X86_32 defines.
32bit cleanup.
2022-03-21 20:21:36 +01:00
lightningterror
0d4394a749 core: Clean up 32bit code. 2022-03-21 20:21:36 +01:00
lightningterror
9dac598113 common: Clean up 32bit code. 2022-03-21 20:21:36 +01:00
lightningterror
6db573d255 emitter: Clean up 32bit code. 2022-03-21 20:21:36 +01:00
Connor McLaughlin
9b21f31b0d GS/Vulkan: Fix crash is vertex/index buffer causes exec 2022-03-21 18:36:31 +00:00
lightningterror
2fedecb809 GS-hw: Purge Evangelion crc hack.
It's broken, HPO special does the job.
Someone should add it to the hw gamefixes.
2022-03-21 17:25:25 +01:00
PCSX2 Bot
b24a8c70e3 PAD: Update to latest controller database. 2022-03-21 17:14:41 +01:00
RedDevilus
d6684efd26 GameDB: GS HW Batch X
Relevant:
Bully
Colosseum - Road to Freedom
Dark Chronicle (Dark Cloud 2)
Killzone
God of War
Gun
Midnight Club 3
Mortal Kombat - Deadly Alliance
Need for Speed Carbon / Most Wanted / Undercover
Prince of Persia - Sand of Time / The Two Thrones / Warrior Within
Resident Evil 4 (BioHazard 4)
Thrillville / Off the Rails
2022-03-21 15:04:45 +00:00
TellowKrinkle
644241959a GS: Fix inverted DSB check 2022-03-21 02:33:38 +00:00
TellowKrinkle
273c1b1922 GS: Clean up leftover definitions
Accidentally leftover during the blend op refactor
2022-03-21 02:33:38 +00:00
Connor McLaughlin
45682c382f GS: Add NO_COLOR flag to PS (depth-only) 2022-03-20 23:41:33 +00:00
Connor McLaughlin
4e6b86f8f4 GS/Vulkan: Use VK_ARM_rasterization_order_attachment_access if available 2022-03-20 23:41:33 +00:00
Connor McLaughlin
a6b4ca69db GS/Vulkan: Support rendering without D32S8 2022-03-20 23:41:33 +00:00
Connor McLaughlin
6b32e00097 GS: Make factors part of blend state
Instead of using the blend map indices.
2022-03-20 23:41:33 +00:00
Connor McLaughlin
19d310475b GS: Draw alpha pass when dual source blend is missing 2022-03-20 23:41:33 +00:00
Connor McLaughlin
a8b9df3952 GS: Utilize GL_EXT_framebuffer_fetch where available 2022-03-20 23:41:33 +00:00
Connor McLaughlin
bb75c78c1a GS: Add option to disable texture barriers/geometry shaders 2022-03-20 23:41:33 +00:00
Mrlinkwii
57ea137982 Gamedb: add missing serials 2022-03-20 23:25:42 +00:00
refractionpcsx2
9721ed0fb3 GS: Use pixel format mask for FBMSK checks 2022-03-20 23:24:42 +00:00
Mrlinkwii
224863fbd5 GameDB: adds 'VUSyncHack' to Panzer Elite Action - Fields of Glory 2022-03-20 17:40:43 +00:00
Mrlinkwii
1d459d8fab Gamedb: Remove VU rounding form 'Hitman - Contracts' 2022-03-20 15:30:00 +00:00
arcum42@gmail.com
33e0ac729e Core: Remove memcmp_mmx. 2022-03-20 12:54:58 +00:00
Connor McLaughlin
268ecf42c3 Build: Remove 32bit configs from vsprops 2022-03-20 12:53:42 +00:00
refractionpcsx2
708281f00b GS: Properly detect 16bit format on Texture Shuffle + Convert 2022-03-20 06:49:16 +00:00
RedDevilus
56b68a50e9 GameDB: Even more GS HW Fixes
Affects:
Ape Escape 3
Armored Core Last Raven
Berserk
Forever Kingdom
Front Mission 4 / 5
Need For Speed Underground 1 / 2
Kings Field 4 - The Ancient City
Test Drive Unlimited
Jak 2 / 3 / X
2022-03-20 05:57:18 +00:00
RedDevilus
e4048dc2dd CI: Update labeler to expand WX 2022-03-20 04:50:29 +00:00
TheLastRar
5949c772d1 Qt: Fix bugs relating to per-game settings 2022-03-20 04:13:45 +00:00
RafaelTrepaUnCarballo
63998b64cc fix comment format 2022-03-20 04:10:11 +00:00
RafaelTrepaUnCarballo
fbb3ea142a Add files via upload
Added gshack (wild arms hack) for all releases of Wild Arms Alter Code F
2022-03-20 04:10:11 +00:00
Tyler Wilding
435f760b5d GameDB: remove duplicate YAML keys 2022-03-20 04:03:03 +00:00
Tyler Wilding
f47129bd72 deps: update rapid-yaml to v0.4.1 2022-03-20 04:03:03 +00:00
Tyler Wilding
aa42acfe22 common: fix method name and clarify some behaviour 2022-03-20 04:03:03 +00:00
Tyler Wilding
ddfe6ac5c1 memcard: update ryml parsing for folder memory cards
also make the file handling safer
2022-03-20 04:03:03 +00:00
Tyler Wilding
624dff1b96 gamedb: move away from deprecated ryml::parse func 2022-03-20 04:03:03 +00:00
Tyler Wilding
8d498b564d deps: update rapid-yaml to latest commit
has a bug fix that we hit in folder memory cards
2022-03-20 04:03:03 +00:00
Christian Kenny
26561261bc Core: Remove unused code 2022-03-20 04:00:27 +00:00
Connor McLaughlin
44728be719 Misc: Fix incorrect printf of std::string_view 2022-03-20 04:00:13 +00:00
Tzerinas
678bb1218b GameDB: Add fixes for Tak Games
SoftwareRendererFMVHack for Tak 1&2, Half-Pixel Offset (Texture) for Guardians of Gross.
2022-03-20 04:00:04 +00:00
RedDevilus
c496e80eac PCSX2-GUI: Rename skipdraw and IDC for Partial Invalidation
Skipdraw and SkipDrawOffset isn't obvious to what it is. SkipDrawStart and SkipDrawEnd makes it obvious it's a range of values.
Also forgot to change the IDC for Disabling Partial Invalidation.
2022-03-20 03:59:38 +00:00
refractionpcsx2
269db188d0 Build: Remove 32bit from CMake. 2022-03-20 00:39:39 +00:00
refractionpcsx2
f5afbfd4f5 GS: Remove 32bit code from SW renderer 2022-03-20 00:39:39 +00:00
refractionpcsx2
ccd86a242c EE/VU JIT: Remove 32bit code 2022-03-20 00:39:39 +00:00
refractionpcsx2
42a5cb7ad2 Build: Remove 32bit targets from VS solution 2022-03-20 00:39:39 +00:00
Tyler Wilding
6977323d88 ci: remove redundant words from job names
its always 64bit now!
2022-03-19 21:19:48 +00:00
Tyler Wilding
7b1d03d45a ci: add link to previous release page in discord announcement 2022-03-19 21:19:48 +00:00
Tyler Wilding
8a4f1ef51a ci: stop building 32-bit
At this point -- not cleaning up the solution files / etc, only our actions.

Until the 32bit code itself is removed, we should still have an easy way to flip these back on.
2022-03-19 21:19:48 +00:00
Mrlinkwii
9b50bb2e81 Gamedb: remove no longer needed comments 2022-03-19 15:56:06 +00:00
Connor McLaughlin
4f27d779a1 GS/DX11: Fix incorrect format check for compressed textures 2022-03-19 03:57:20 +00:00
RedDevilus
73c6353351 Qt: Partial Invalidation
Some missing strings from the renaming.
2022-03-18 23:47:21 +00:00
Immersion95
f571b66a43 GameDB: HW fixes for Mega Man/Rockman X7 + Clamping mode fix (#5694) 2022-03-18 20:53:48 +00:00
BuildTools
901664ba44 GameDB: Rename fastTextureInvalidation
Attempt 2 renames fastTextureInvalidation to disablePartialInvalidation for more consistency with the new GUI name.
2022-03-18 13:52:36 +00:00
Immersion95
02012b5491 GameDB: HW fixes for Rockman X8
SoftwareRendererFMVHack for the NTSC-J & NTSC-K version of Megaman X8
2022-03-18 10:24:58 +00:00
TellowKrinkle
4f57e40c91 GS:SW: Fix lod on x64 2022-03-18 03:59:51 -05:00
RedDevilus
832e536a9e GameDB: Haunting Ground + 50 Cent and Level 5
Ranging from blurriness to font artifacts.
2022-03-18 08:44:33 +00:00
BuildTools
c2316ca5bc GUI: Rename Fast Texture Invalidation
Renames Fast Texture Invalidation to Disable Partial Invalidation.

Update GraphicsSettingsWidget.ui
2022-03-18 02:11:12 +00:00
refractionpcsx2
3535edcfa1 GameDB: Add partial preloading to Stolen 2022-03-17 18:40:11 +00:00
KrossX
a4932ed0f1 GameDB: Add DMABusy fix to Shining Wind 2022-03-17 14:33:07 +00:00
seta-san
515d9040a1 GameDB: Add gsHWFixes for Tales of Symphonia
Co-Authored-By: RedDevilus <martensregis@gmail.com>
2022-03-17 09:16:20 +00:00
Connor McLaughlin
fe3a743814 ImGuiManager: Cap usage percents to 100% 2022-03-17 09:10:12 +00:00
Connor McLaughlin
8e08cd772b PerformanceMetrics: Add GPU time 2022-03-17 09:10:12 +00:00
Connor McLaughlin
206f80c5f4 GS: Compute SW CPU per-thread not per-draw 2022-03-17 09:10:12 +00:00
RedDevilus
c6ce380042 GameDB: More GS HW Fixes
Some extra comments for Monster Lab and SSX Tricky.

New entries:

- Alter Echo
- Beyond Good and Evil
- Dragon Ball Z - Budokai Tenkaichi 2
- Fatal Frame 1 / 3
- Ghost in the Shell - Stand Alone Complex
- Global Defence Force
- Xenosaga 1 / 2 / 3
2022-03-17 08:57:58 +00:00
lightningterror
939d98d660 Qt: Allow skipdraw up to 10k max. 2022-03-17 02:44:14 +01:00
lightningterror
c9a3420f85 GS: Fix Wunused-variable warnings. 2022-03-17 00:50:28 +01:00
refractionpcsx2
9a1a399bac GameDB: Add a bunch of hw fixes and upscaling fixes 2022-03-16 23:40:53 +00:00
RedDevilus
c8aac1dca9 GameDB: Ace Combat + Soul Calibur + Metal Gear Solid Series
Missing mipmap from the Europese Ace Combat Zero/4/5, Align Sprite for them and Round Sprite. Align Sprite for SoulCalibur series.
Metal Gear 2 substance gets round sprite for font and Metal Gear 3 Subsistence gets Special (Texture) for blurriness.
2022-03-16 22:38:39 +00:00
lightningterror
14c17916f5 GS-hw: Optimize blending equations based on alpha value.
It will allow us to use free sw blending without texture barriers.

Will be especially helpful for opengl/vulkan.
2022-03-16 15:17:00 +01:00
RedDevilus
7b0576d7cc GameDB: Dog Island and COD Final Fronts (#5671) 2022-03-16 07:24:05 +00:00
Blackbird88
ecb118d5af GameDB: Add gsHWFixes for GTA LCS/VCS (#5662)
Co authored by @Blackbird88
2022-03-15 20:22:19 +00:00
RedDevilus
efbf187b35 GameDB: Upscaling GS Batch 2
Adds second batch of upscaling fixes.
2022-03-15 20:21:15 +00:00
Tzerinas
2ea3feba90 GameDB: Add Upscaling Fixes to Onimusha 3
Adds Half-Pixel Offset: Special (Texture) and Round Sprite (Full) to Onimusha 3: Demon Siege
2022-03-15 20:19:06 +00:00
Tzerinas
f265257efb GameDB: Add Software FMV to Grandia 2 and Xtreme
Adds the SoftwareRendererFMV hack to Grandia 2 and Xtreme. Also adjusted titles.
2022-03-15 20:18:43 +00:00
lightningterror
13cc0caed7 GS Debugger: Fix hw hacks behavior not properly disabling. 2022-03-15 15:46:24 +01:00
refractionpcsx2
2068240e1a GS: Adjust Auto Flush to catch edge cases
Affected Beyond Good and Evil water
2022-03-15 10:15:21 +00:00
Tzerinas
7f5901f022 GameDB: GS HW renderer fixes for Tales of the Abyss
Description of Changes
Add Half-Pixel Offset: Special (Texture) to Tales of the Abyss.
2022-03-15 09:38:24 +00:00
Tokman5
a022de6225 GameDB: Add gsHWFixes for Shutokou Battle 01. (#5659)
Co-authored-by: Tokman5 <isozin_1210@yahoo.co.jp>
2022-03-15 08:12:52 +00:00
RedDevilus
f5570b7f40 GameDB: Rogue Galaxy
Adds half roundsprite to make upscaled HW more like software mode such as minimap while fighting.
2022-03-15 08:11:17 +00:00
RedDevilus
7e1c48694a GameDB: Upscaling GS Batch 1
Fixes the lint and adds a bunch of upscaling fixes.
2022-03-15 00:54:38 +00:00
lightningterror
a546f61ea8 Qt: Fix Round sprite hack not applying. 2022-03-14 23:43:25 +01:00
PCSX2 Bot
7ecac10eee PAD: Update to latest controller database. 2022-03-14 22:20:49 +01:00
Mrlinkwii
ee2e10e86b GameDB: correct and update serials 2022-03-14 19:15:50 +00:00
RedDevilus
7752f44a90 GameDB: Documentation
Add values for GameDB, GUI options and the default to easier make GameDB changes
2022-03-14 19:14:40 +00:00
refractionpcsx2
e01fc3eb47 GS: Loosen requirement for half bottom 2022-03-14 19:14:26 +00:00
SaltyBet
910c8190e0 GameDB: Added missing variants of NAMCO games 2022-03-14 15:47:02 +00:00
SaltyBet
a62ccc0d69 GameDB: Auto GS HW renderer fixes for some NAMCO games
- Tekken 4
- Tekken 5
- Tekken Tag Tournament
2022-03-14 15:47:02 +00:00
Dreadmoth
4f47041108 GameDB: Metal Arms - Glitch in the System (PAL)
Force disable mVU Flag Hack to prevent SPS
2022-03-14 15:33:39 +00:00
Connor McLaughlin
16cfde0538 GS: Use single array for dump packets 2022-03-14 15:26:19 +00:00
Connor McLaughlin
6a15d46461 Qt: Improve boot filename autodetection 2022-03-14 15:26:19 +00:00
Connor McLaughlin
4331ae1925 VMManager: Support playing back GS dumps 2022-03-14 15:26:19 +00:00
Connor McLaughlin
4d85d916b7 GS: Move dump file loading to core 2022-03-14 15:26:19 +00:00
Connor McLaughlin
4f4b14dd4d GameList: Add GetEntryByCRC() 2022-03-14 15:26:19 +00:00
Connor McLaughlin
444e650711 StringUtil: Add StartsWithNoCase/EndsWithNoCase 2022-03-14 15:26:19 +00:00
refractionpcsx2
c65ccaa153 GS-Config: Clear missing manual GS fixes 2022-03-14 11:08:39 +00:00
Connor McLaughlin
6b54db9b75 GS/VertexTrace: Fix min/max when last provoking vertex unsupported
This was causing incorrect min/max alpha values due to the index swap,
which caused the sides of text boxes in KH to disappear (because the
alpha test optimized to always failing).

Closes #5639.
2022-03-14 08:47:32 +00:00
Mrlinkwii
3bab470db6 Docs : Add GS hardware fixes and MTVUSpeedHack 2022-03-13 18:33:37 +00:00
refractionpcsx2
adf01cb56a GS-Build: Fix Dump Verticles for linux 2022-03-13 05:01:51 +00:00
refractionpcsx2
bbe3af7f61 GS-Debug: Dump verticles with draws
- Move context dumping to the top so we see it as the game set, not after we've messed with it.
Thanks to tadanokojin for these changes
2022-03-13 03:46:16 +00:00
refractionpcsx2
3e7d32c807 GameDB: Give slightly clearer message for GS Fix override 2022-03-13 03:18:44 +00:00
refractionpcsx2
76e25cb738 GameDB: Add mipmapping/trilinear for Hot Shots/Everybody's Golf games 2022-03-13 02:34:29 +00:00
refractionpcsx2
8f0dc34847 GS: Improvements to MTBA address calculation 2022-03-13 01:55:08 +00:00
RedDevilus
fc6ec2cc02 GameDB: Transformers Armada: Prelude to Energon
Adds missing VIFFIFO + force disabling MTVU for not getting black screen
2022-03-13 01:53:48 +00:00
refractionpcsx2
34b7b07ff8 GameDB: Added a whole host of auto GS HW renderer fixes 2022-03-13 01:53:15 +00:00
Connor McLaughlin
6c33b73cdd GS: Make TC offset changable without recreating 2022-03-12 20:48:51 +00:00
Connor McLaughlin
1e86ba4120 GS: Append game serial/name to dump filename 2022-03-12 20:48:51 +00:00
Connor McLaughlin
89c79aa6c3 GSDump: Add embedded screenshot 2022-03-12 20:48:51 +00:00
Connor McLaughlin
4ed748fa30 GSDump: Add extensible header and serial
Serial is used to apply hw fixes.
2022-03-12 20:48:51 +00:00
Connor McLaughlin
5569e94f41 GS: Make setting change detection more fine grained
Avoids the slower full restart when it's not needed.
2022-03-12 20:48:51 +00:00
Connor McLaughlin
892eec79ed Workflows: Fix lint-gamedb for gsHWFixes 2022-03-12 20:48:51 +00:00
Connor McLaughlin
b248b4a8af GameDB: Add HW fixes for GTASA/GOW/GOW2 2022-03-12 20:48:51 +00:00
Connor McLaughlin
39fe467b64 GS: Purge CRCs of unused titles 2022-03-12 20:48:51 +00:00
Connor McLaughlin
1c301ec889 GS: Move point list palette to gamedb 2022-03-12 20:48:51 +00:00
Connor McLaughlin
de5690ddcb GS: Move texture-inside-rt flag to gamedb 2022-03-12 20:48:51 +00:00
Connor McLaughlin
f376c8f7ae GS: Remove second source of truth for HWMipmap 2022-03-12 20:48:51 +00:00
Connor McLaughlin
2e199d47a8 GS: Move automatic mipmapping override to gamedb 2022-03-12 20:48:51 +00:00
Connor McLaughlin
96269db93e GameDatabase: Add ability to override GS fixes 2022-03-12 20:48:51 +00:00
Connor McLaughlin
d35db63d73 GS: Reference GSConfig instead of using theApp
Removes multiple sources of truth, enables overrides.
2022-03-12 20:48:51 +00:00
refractionpcsx2
9d003486c2 GS-hw: Attempt to improve half screen detection 2022-03-12 12:28:18 +00:00
refractionpcsx2
0c4b85980c GS: Support local to local transfers that overwrite themselves 2022-03-12 12:27:43 +00:00
Connor McLaughlin
5961db6b9b GS/Vulkan: Elide render pass restarts on depth buffer toggle 2022-03-12 12:22:51 +00:00
Connor McLaughlin
d0039c2920 Gif_Unit: Vectorize analyzeTag() 2022-03-12 12:10:32 +00:00
TellowKrinkle
5bdec2f532 x86emitter: Fix x64 8-bit rmw codegen 2022-03-11 12:59:57 +00:00
refractionpcsx2
fd758bb307 GameDB: Added MTVU disable to InstantVU off games 2022-03-11 10:25:15 +00:00
refractionpcsx2
a11d09ebdf Git: Update GameDB Validation script 2022-03-11 10:25:15 +00:00
refractionpcsx2
d294064da6 GameDB: Disable MTVU on T-Bit games 2022-03-11 10:25:15 +00:00
refractionpcsx2
fd4a5acc40 MTVU: Try to make T-Bit more reliable.
Add MTVUSpeedHack option to GameDB so it can be forcefully disabled
2022-03-11 10:25:15 +00:00
refractionpcsx2
05a7a61257 GS/Autoflush: Handle different page widths/arrangements 2022-03-11 10:24:26 +00:00
refractionpcsx2
90a4a11d49 GS: Add Auto Flush for Z buffer draws
Adjust Burnout CRC hack
2022-03-11 10:24:26 +00:00
lightningterror
d9f914eb7c GS-hw: Move the Ad to As equation swap when alpha is masked to Basic level and higher on gl/vk.
Safer this way, otherwise need to take in to account when accumulation, non recursive, and blend mix is enabled, or manually enable them on Minimum level.

Everything that we need is enabled on Basic level.

Change is done for clamp 1 only.
2022-03-09 23:24:44 +01:00
TheLastRar
134242973b Config: Set a sane default value for HddSizeSectors 2022-03-09 10:07:54 +00:00
TheLastRar
92900d8dc8 Config: Fix manual subnet mask save/load 2022-03-09 10:07:54 +00:00
Ziemas
7a970e1d00 Filesystem: Properly convert stat return to bool.
Two of the overloads where wrong.
2022-03-09 09:33:51 +00:00
Connor McLaughlin
e8e0f355fc GS/WX: Fix default adapter causing unnecessary GS restarts 2022-03-09 09:14:36 +00:00
Mrlinkwii
3202fd88d2 Gamedb: add VU clamping to 'DT Racer' and update MGS2 hack 2022-03-09 00:10:00 +00:00
RedDevilus
1c66c904ab GameDB: Katamari games
Katamari games have become sensitive again to this hack. It's forcefully disabled for this PR to fix performance and other breaking issues.
2022-03-09 00:08:21 +00:00
lightningterror
784e090081 GS-hw: Improve how we handle blending when output is Cd.
Disable hw blending on Cd output,
Disable rgb write on Cd output.
2022-03-08 23:46:27 +01:00
Connor McLaughlin
2d08d3dc94 GL/Context: Drop GL string logging back to devbuilds 2022-03-08 10:39:50 +01:00
Connor McLaughlin
237b9754c6 Qt: Log graphics driver info on startup 2022-03-08 10:39:50 +01:00
Connor McLaughlin
74bbccdf59 Wx: Log graphics driver info on startup 2022-03-08 10:39:50 +01:00
Connor McLaughlin
062d625901 Vulkan/Context: Allow non-debug device when validation layers unavailable 2022-03-08 10:39:50 +01:00
Connor McLaughlin
3f30c2bda2 VulkanHostDisplay: Improve Vulkan version reporting 2022-03-08 10:39:50 +01:00
PCSX2 Bot
0702692746 PAD: Update to latest controller database. 2022-03-07 17:11:41 +01:00
dependabot[bot]
11a218b1aa Bump actions/checkout from 2 to 3
Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-07 14:15:25 +01:00
Connor McLaughlin
f4acff1321 Qt: Fix incorrect dropdown value in game properties 2022-03-07 14:14:49 +01:00
Connor McLaughlin
a8ee746c39 Qt: Fix live changing game settings not applying 2022-03-07 14:14:49 +01:00
Connor McLaughlin
ddd5fc7bf3 VMManager: Fix brief unpause before shutdown 2022-03-07 14:14:04 +01:00
lightningterror
22dfe05287 GS-hw: Optimize blending when ALPHA.A is equal to ALPHA.B.
Set ALPHA A B to 0 (Cs), and ALPHA.C to 0 (As).
2022-03-07 14:13:19 +01:00
refractionpcsx2
fa78e1295a GS: Handle Auto Flush across pages + scissor, add TEXFLUSH
Fixes Jak 3 shadows, partially fixes Beyond Good and Evil water, improves Auto Flush performance hugely (x3 in Jak 2 @ 3x Native)
2022-03-06 03:07:37 +00:00
refractionpcsx2
4a634ca154 GS: Fix compilation of GS SW Int Rasterizer 2022-03-05 16:55:54 +00:00
refractionpcsx2
bd1f5d0888 GS: Adjust Tekken 5 CRC hack for fire effect, fixes sun bleed.
Fixes #2766
2022-03-05 15:55:36 +00:00
Connor McLaughlin
2f028c5f40 Qt: Implement CTRL+C and confirm shutdown 2022-03-04 17:41:28 +00:00
Connor McLaughlin
56c8843406 Qt: Add log options to debug menu 2022-03-04 17:41:28 +00:00
Connor McLaughlin
37c4c596b5 Qt: Fix a few warnings on Linux 2022-03-04 17:41:28 +00:00
Connor McLaughlin
7b0bde4f1f Qt: Move section/key in setting binder
It's passed in by value, so elide the copy.
2022-03-04 17:41:28 +00:00
Connor McLaughlin
5c5c7d64a8 Qt: Remove version check macros
Not needed anymore since we require Qt6 on all platforms.
2022-03-04 17:41:28 +00:00
lightningterror
565189d08c GS-hw: Fix Wunused-variable warning in GSRendererHW. 2022-03-03 22:27:40 +01:00
lightningterror
682580e318 GS-hw: Fix Wsign-compare warnings in GSRendererNew. 2022-03-03 22:27:40 +01:00
lightningterror
74e3d6470a GS-hw: Fix Wunused-but-set-variable warnings in GSTextureCache. 2022-03-03 22:27:40 +01:00
refractionpcsx2
b4e6a715fc EE/JIT: Flush const on LDL/LDR instructions 2022-03-03 16:18:16 +00:00
Mrlinkwii
85f0d44997 Gamedb: add patch for Cars 2022-03-03 11:29:52 +00:00
TellowKrinkle
294855700d GS:OGL: Don't memset C++ objects 2022-03-02 12:10:12 +00:00
TellowKrinkle
099ddfedc7 GS:Mac: Properly init vulkan on main thread 2022-03-02 12:02:15 +00:00
TellowKrinkle
d9e2bcef6d GS:Mac: Nicer message send 2022-03-02 12:02:15 +00:00
TellowKrinkle
7a628f1a12 WX: Make texture dump location configurable 2022-03-02 11:58:44 +00:00
Mrlinkwii
75bc680934 GameDB: add 'VUSyncHack' to 'Tiger Woods PGA Tour 2002' and update documentation 2022-03-02 11:36:11 +00:00
Connor McLaughlin
0c98b5ff76 GS/TextureCache: Don't let hash cache memusage go negative 2022-03-01 17:34:59 +00:00
arcum42
11918e5846 Disable warnings on several third party libraries. (#5519) 2022-02-28 21:14:52 -08:00
refractionpcsx2
2c33bf8c6f GUI/Qt: Update VU Sync option in Qt interface 2022-02-28 19:29:53 +00:00
refractionpcsx2
e833a67bb7 VU: Rework VUKickstart in to VUSync, swap behaviour 2022-02-28 19:29:53 +00:00
refractionpcsx2
6dc5087cbd VU: Run sync ahead on small blocks 2022-02-28 19:29:53 +00:00
PCSX2 Bot
eabda670ac PAD: Update to latest controller database. 2022-02-28 17:52:52 +01:00
Connor McLaughlin
845e7930d7 microVU: Move VU0 micro flag instance setup to program start
They're only used in micro mode, so no point updating them in a cop2
chain.
2022-02-28 15:07:15 +00:00
Connor McLaughlin
d20bfa240d EE: Add COP2 flag hack 2022-02-28 15:07:15 +00:00
Connor McLaughlin
ba27a46ac6 GS/TextureCache: Don't count replacements in hash cache budget
Large replacement textures were causing the hash cache to disable
itself. There's plenty of other massive VRAM sinks in PCSX2 that we need
to consider before we can say we're managing VRAM well anyway.
2022-02-28 09:38:12 +00:00
Connor McLaughlin
866e5bd929 GS/TextureReplacements: Disable generated mipmaps on compressed textures
They should be provided in the file.
2022-02-28 09:38:12 +00:00
TellowKrinkle
1beb5517a7 Pad: Fix connection of macOS GameController framework controllers 2022-02-28 09:51:11 +01:00
TheLastRar
a12ad1f627 Config: Clang format Pcsx2Config 2022-02-28 09:44:14 +01:00
TheLastRar
c18be9dde7 Dependencies: Remove LibXml 2022-02-28 09:44:14 +01:00
TheLastRar
4eba400170 DEV9: Don't enforce MTA requirement
Also CoUninitialize() needs to be called for all successful calls to CoInitialize/Ex(), not just those that return S_OK
2022-02-28 09:44:14 +01:00
TheLastRar
dc376ab161 DEV9: Clang format net.cpp 2022-02-28 09:44:14 +01:00
TheLastRar
5ff49a78eb Config: Add DEV9 options to global struct
Additionally switch to using std::string in various locations in DEV9
2022-02-28 09:44:14 +01:00
TheLastRar
6df50992c4 DEV9: Remove old settings/log directory functions 2022-02-28 09:44:14 +01:00
TheLastRar
5d2bcfaa38 DEV9: Fix off by one error on LBA range check 2022-02-28 09:44:14 +01:00
TheLastRar
990d7ad0f7 DEV9: Correct DEV9 include in Tap 2022-02-28 09:44:14 +01:00
TheLastRar
510283cd4d DEV9: Rename DEV9's Config.h to DEV9Config.h 2022-02-28 09:44:14 +01:00
TheLastRar
dcc183179a DEV9: Use fs namespace instead of ghc 2022-02-28 09:44:14 +01:00
TheLastRar
30bc9b04c5 DEV9: Use UTF8 strings on windows for AdapterEntry 2022-02-28 09:44:14 +01:00
dependabot[bot]
8aaeb1c7ce Bump actions/setup-node from 2 to 3
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2 to 3.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-28 09:25:18 +01:00
AKuHAK
1984c68516 PCSX2: Add ability to combine CLI options --elf or --irx with --gameargs
Exception: if full path to host: contains spaces, then arguments will be ignored. To avoid this you can use relative paths when possible.
2022-02-28 09:20:01 +01:00
refractionpcsx2
c81c89d6d9 GUI/Qt: Fix startup project for debugger 2022-02-28 07:34:52 +00:00
refractionpcsx2
9ce2405f3f GUI/Qt: Fix loading ELF files from menu 2022-02-28 07:05:15 +00:00
refractionpcsx2
21fba45a3c GameDB: Added patch for PowerDrome US 2022-02-27 15:22:42 +00:00
refractionpcsx2
a0bbdcefb3 GS: Ignore 24bit on DATE and Handle Reversed Color and Z
Clamp Framebuffer width to 1-32
2022-02-27 15:22:42 +00:00
lightningterror
753da789a0 GS-hw: Adjust DATE selection.
Remove fbmask check from DATE,
Enable DATE_BARRIER with one barrier when alpha isn't written and there is no alpha test.
2022-02-26 17:48:27 +01:00
lightningterror
cd5ce6e162 GH-workflows: Remove os mentions for auto pad db update.
Not needed anymore.
2022-02-24 14:52:41 +01:00
Connor McLaughlin
5a25cc171d GS: Add texture dumping and replacement system 2022-02-24 10:18:49 +00:00
Connor McLaughlin
32dc68f103 GS: Support BC1/BC2/BC3/BC7 compressed texture formats 2022-02-24 10:18:49 +00:00
Connor McLaughlin
69a500d657 GS: Add Swap() to GSTexture 2022-02-24 10:18:49 +00:00
Connor McLaughlin
ed9f34de5f Common/FileSystem: Add EnsureDirectoryExists() 2022-02-24 10:18:49 +00:00
iMineLink
d6f1291c0b GS: skip no output draws. 2022-02-24 10:12:59 +00:00
iMineLink
01079f5162 GS: upscale regardless of PCRTC enabling. 2022-02-24 10:12:59 +00:00
RedDevilus
9b0dc287c1 PCSX2-GUI: Rename Interlacing to Deinterlacing
So to sketch what is an annoying issue is that this for years has been wrongly presented to users.
None Interlacing = Interlacing but if used with a no-interlacing patch it will look like progressive but PCSX2 or really the internal PS2 side only detects interlacing mode. Which blows my mind that the user wouldn't be wrong to assume that None Interlacing = Interlacing.
Weave = Interlacing method (saw-tooth)
Bob = Likely the sharpest but can do vertical bouncing.
Blending = A bit blurry but the most consistent and has no bouncing.

I didn't change the code just the visual presentation to the users.

Example in gif format: https://upload.wikimedia.org/wikipedia/de/1/1e/Interlaced_Animation.gif
2022-02-24 00:38:01 +00:00
lightningterror
bb92566781 GS-hw: Don't trigger no overlap check for DATE_BARRIER on d3d11.
d3d11 doesn't support DATE_BARRIER, it's better to let the Date one cases handle it as it will be more accurate.
2022-02-23 20:48:00 +01:00
Connor McLaughlin
17b1c664a8 GS: Add option to disable status indicators
Fast forward/pause icons.
2022-02-23 15:45:47 +00:00
Connor McLaughlin
2eaba084c7 GS/TextureCache: Fix target not getting invalidated in some cases
This would happen when there was a source from local memory with the
same pointer as the target.

Fixes sky getting messed up in the Jak 3 menu when the hash cache is
enabled.
2022-02-23 15:45:19 +00:00
arcum42@gmail.com
ff75ab73cc Qt: Fix qt compilation on linux. 2022-02-22 19:23:51 +00:00
RedDevilus
3c54593456 Qt: Add themes
Ranging from ColorBlind themes to flashy to pastel. Based on the Fusion factory. 3 Light and 1 Dark extra themes (2 light and 2 dark themes on master) with enough variability and choice.
It's just a placeholder for when other factories are implemented and perhaps even viable for future community-based static or dynamic ones.
2022-02-22 16:13:09 +00:00
RedDevilus
39dfb2e606 Qt: Resize default headersize BIOS
Qt: Resize default headersize BIOS

The first column was too small and visually makes it harder to see what BIOS you have.
2022-02-22 16:13:09 +00:00
PCSX2 Bot
4e7ade8612 pad-windows/unix: Update to latest controller database. 2022-02-21 21:22:07 +01:00
seta-san
664013e7ad Qt: Fix type on graphics panel (#5553) 2022-02-21 19:10:14 +00:00
Connor McLaughlin
9d51c64d92 GS: Support mipmaps in hash cache 2022-02-21 16:50:57 +01:00
Connor McLaughlin
ee82c7834d GS: Auto-disable hash cache when it's too large 2022-02-21 16:50:57 +01:00
Connor McLaughlin
b389c6e103 GS: Only allocate valid page array when needed 2022-02-21 16:50:57 +01:00
Connor McLaughlin
b3a2d3c1e4 GS: Track hash cache memory usage 2022-02-21 16:50:57 +01:00
Connor McLaughlin
5d33af13ca GS: Add full (hash cache) texture preloading option 2022-02-21 16:50:57 +01:00
Connor McLaughlin
6b2a851dec GS/Vulkan: Fix uploading large (>64MB) textures 2022-02-21 16:50:57 +01:00
Connor McLaughlin
3b3072801c GS/OpenGL: Fix uploading large (>16MB) textures 2022-02-21 16:50:57 +01:00
Connor McLaughlin
9ed33d4337 GS/HW: Fix mipmap level not updating on live config change 2022-02-21 16:50:57 +01:00
Mrlinkwii
728b3eb5db Core: remove not needed logging 2022-02-21 10:46:29 +01:00
Connor McLaughlin
f73398ea84 GS/Vulkan: Fix warning when compiling RGBA8->RGB5A1 shader
Also gets rid of the program info log length check, since that's been
long removed in glslang.
2022-02-20 14:03:33 +00:00
lightningterror
2b646c2153 GS-hw: Disable dithering if blend mix is enabled.
It breaks stuff since we do a mix of hw/sw.
2022-02-20 02:31:03 +01:00
lightningterror
f83692c0df GS-ogl: Remove GL_ARB_get_texture_sub_image.
Not used.
Also remove some not used commented out defines.
2022-02-19 18:08:05 +01:00
lightningterror
b8236b1b1c GS-hw: Partially revert #5540
Allow to wrap on colclip.
For real tho, ideal solution is sw blend, doing any clamp/wrap is wrong on blend mix.
2022-02-19 00:38:13 +01:00
lightningterror
1a3d77b2c0 GS-hw: Fix d3d11 depth sample shader.
Also adjust some comments to match updated shader names.
2022-02-18 19:21:01 +01:00
lightningterror
816ee9e545 GS-hw: Prefer sw blend for clr_blend1_2 on ultra blending.
Opengl/Vulkan: Prefer sw blend over hw for clr_blend1_2 on ultra blending, doing hw is less accurate and will introduce rounding issues.

Direct3D11: Prefer sw blend over hw for clr_blend1_2 only when primitives don't overlap.
2022-02-18 19:06:49 +01:00
lightningterror
06766ddb98 GS-hw: Don't wrap on 16bit destination format for blend mix.
Helps Dog's Life blending, we shouldn't wrap as we do more blend math afterward which will be wrong if we wrapped before.
2022-02-18 19:00:54 +01:00
lightningterror
7151848406 GS-hw: Rename alpha_clamp to blend_mix. 2022-02-18 19:00:54 +01:00
Ziemas
45b5347092 SPU2: Don't cap pitch setting on register write.
While 0x3FFF is indeed the highest playable pitch I think that the
register is 16 bits wide and that the cap is enforced by the pitch
counter algorithm.

This fixes the air time ticking sound in Jak X.
2022-02-18 12:32:04 +00:00
Ty Lamontagne
5b6986c230 Core: Export recompiler offsets 2022-02-16 17:51:40 +00:00
Connor McLaughlin
de195d9b20 Qt: Add game summary and audio/memcard placeholders 2022-02-16 17:34:53 +01:00
Connor McLaughlin
b47552c08f Qt: Add per-game settings UI 2022-02-16 17:34:53 +01:00
Mrlinkwii
48dabd3ca2 QT: Add icon for Hk BIOS. 2022-02-15 20:54:27 +01:00
lockhart
91ac0368e3 GameDB: Add Ratchet & Clank demo and Spider-Man 3 Fixes + several new entries as well as the removal of the virtual-on Ontario program fixes.
This commit fixes several entries from the GameIndex, removes the clamping fixes from Virtual On ontario program which wasn't needed, adds several rounding fixes to Ratchet 1 titles to fix the Hydrodisplacer Behaviour and adds several entries as well.

For Ratchet 1, After having done tests on actual hardware,

the results shows that even real hardware will behave badly on the retail version....

However, the demo does indeed have an issue, so let's fix that.

Also, this fixes an oversight made for Spiderman 3 in the past, now the proper fix is applied.
2022-02-15 12:58:27 +00:00
Connor McLaughlin
dfe4bc199f GS/HW: Use integers for depth conversion shaders
Fixes z-fighting in reflections in DBZ BT3, maybe others?
2022-02-15 10:41:37 +01:00
PCSX2 Bot
1630404621 pad-windows/unix: Update to latest controller database. 2022-02-14 21:06:50 +01:00
Mrlinkwii
02c66491e8 Gamedb: add 'VUKickstartHack' to 'Jet Li - Rise to Honor' 2022-02-14 18:29:57 +00:00
refractionpcsx2
d4b1d9abe5 GS-hw: Increase 32->16bit conversion accuracy
Improves Dogs life (no longer goes completely black right away, but has decal problems)
Vastly improves texture quality in Spider-Man 3 when using Framebuffer Conversion to fix the textures
2022-02-14 14:50:21 +00:00
Ty Lamontagne
6ab77be8fc COP2: Move COP2 timing messages to release builds. 2022-02-14 01:52:44 +00:00
RedDevilus
6cf518e7df actions: Add windows category for SDL
Upcoming Qt will feature native support for multiple controllers + remapping for all relevant OSes. This makes the step a bit easier.

Rationale:
Windows has cleaner code (becoming just like OnePad) and no more DS4/DualSense/Switch Pro/... wrapper such as steam or DS4Windows (ryochan7) though will still work if you want it.
Linux will have OnePad legacy remapping.
Mac will have feature parity to some extent.
2022-02-14 01:50:57 +00:00
Mrlinkwii
8f1745bf44 Gamedb: add EETimingHack to 'Obscure 2' and patch to 'Snoopy Vs Red Baron' 2022-02-14 01:50:39 +00:00
lightningterror
38f1ae34ad GS-hw: Prefer sw blend when one barrier is already enabled and prims don't overlap.
More accurate, speed will be the same.
2022-02-13 14:11:51 +01:00
refractionpcsx2
ad415945a6 GS-hw: Apply clamp/wrap when FBMask enabled 2022-02-11 19:33:38 +01:00
Frank Hartung
a44fe29b8d CMake: add back HarfBuzz to fix build (#5510)
- pango relies on HarfBuzz & pulls in its headers
2022-02-10 17:56:19 -08:00
RedDevilus
c1d96fc876 CI: Label Qt into GUI/Qt
The label has recently been changed into GUI/Qt for more clarity that it touches upon a GUI toolkit just like WX. Also added the 3rdparty for the binary.
2022-02-10 21:04:28 +01:00
Florin9doi
65db50df5d Qt: Add icon for Cn BIOS. 2022-02-10 21:02:55 +01:00
Blackbird88
f009d6f9e7 GameDB: Add missing Gran Turismo demos 2022-02-09 10:56:25 +00:00
Mrlinkwii
ed8bd18dfb GameDB: disable mVUFlagHack for Maken Shao 2022-02-09 10:21:52 +00:00
PCSX2 Bot
af648334d1 pad-linux: Update to latest controller database. 2022-02-07 17:11:12 +01:00
987123879113
8f4ce02d05 GameDB: Update Bemani game titles and add new entries for Japanese DDR X and SuperNOVA2 2022-02-07 02:52:57 +00:00
C.W. Betts
9b7e87c043 Mark static functions in headers as static inline:
This quiets unused function warnings (-Wunused-function) which is on by default on Xcode.
2022-02-07 02:32:56 +00:00
C.W. Betts
cae8e6ae79 Change a couple of includes from angle brackets to quotes:
This makes Xcode happy, as it interprets angled brackets as system headers or headers inside of frameworks.
2022-02-07 02:32:56 +00:00
iMineLink
1a2272ad43 GS: partially revert "c1e5e45431863bc206686c49b8fb4fa2775be9a2".
overwrite the target pitch when an overlapping write is detected
with the write pitch itself.
fixes the broken splashscreen in This is Football 2002.
2022-02-07 02:17:19 +00:00
iMineLink
fede91a98b GS: update target pitch on frame lookup.
fix Jurassic Park - Operation Genesis loading disk logo.
2022-02-07 01:42:54 +00:00
Connor McLaughlin
7e8c6fcc9d Wx: Fix live vsync changes not applying 2022-02-07 01:42:40 +00:00
Connor McLaughlin
0ca3167595 Vulkan: Implement adaptive vsync (FIFO-relaxed) 2022-02-07 01:42:40 +00:00
Connor McLaughlin
c74cc9bc12 HostDisplay: Fix vsync getting lost on window changes 2022-02-07 01:42:40 +00:00
iMineLink
061fff6f17 cmake: copy resources in build folder. 2022-02-06 16:01:39 +00:00
lightningterror
2aaabdd2ea GS-hw: Cleanup crc stuff.
Merge the following crc lists, gets rid of duplication since code is shared:
BurnoutDominator, BurnoutRevenge, BurnoutTakedown ->BurnoutGames

GetaWay, GetaWayBlackMonday ->GetaWayGames

GT3, GT4, GTConcept, TouristTrophy ->PolyphonyDigitalGames

Yakuza, Yakuza2 -> YakuzaGames

ValkyrieProfile2, StarOcean3, RadiataStories -> TriAceGames

Rename defines Dx_and_OGL to CRC_Partial, Dx_only to CRC_Full, Aggressive to CRC_Aggressive
2022-02-06 16:21:30 +01:00
lightningterror
2f06ed2af8 GS-hw-tc: Remove JackieChanAdv crc hack.
Game seems to work fine currently.
2022-02-06 15:45:49 +01:00
Florin9doi
52252de3a6 GameDB: Add missing NTSC-J games (#5491)
Co-authored-by: Florin9doi <Florin9doi@users.noreply.github.com>
2022-02-06 13:58:09 +00:00
Florin9doi
ff725980c3 Game DB: Add missing PAL games to GameIndex Correct AFL Football serial
PR #5490
Co-authored-by: Florin9doi <Florin9doi@users.noreply.github.com>
2022-02-06 13:57:12 +00:00
lightningterror
d6d420b1f7 QT: Add missing Texture Inside RT option. 2022-02-06 13:17:28 +01:00
TellowKrinkle
977e8a4c54 GS:HW: Fix scale of color → 8 bit converted textures 2022-02-06 05:04:56 +00:00
iMineLink
b8188a7954 GS: remove bw equality check in tex in rt.
fixes jak mipmapping.
2022-02-06 04:53:09 +00:00
refractionpcsx2
8ac57db117 GS: Don't process CLUT load condition on invalid PSM 2022-02-05 15:13:48 +00:00
RedDevilus
5cc66e4d36 Qt: Resize Windows + Change Framerate Presets + Lower OSD time
The main window will now correctly display the full Toolbar. Interface Settings will not go out of bounds. The OSD message for cheats and patches has been changed and the overall timing of the static (not dynamic) OSD messages are now 5 seconds instead of 10 seconds which is pretty long. Tested on 1920 x 1080 + 2560 x 1080 on 125% and 150% DPI scaling.
2022-02-05 14:09:34 +00:00
Connor McLaughlin
d9d2022096 InputManager: Missing motor bindings are not errors 2022-02-05 14:09:11 +00:00
Connor McLaughlin
1ea38b1981 Qt: Fix current tab resetting when switching renderers 2022-02-05 14:09:11 +00:00
Connor McLaughlin
d63a36216f Qt: Fix default values for software mipmap/AA1 2022-02-05 14:09:11 +00:00
s-andro
9ac935ed94 CRC: Gran Turismo 4 [PlayStation 2 Racing Pack] 2022-02-05 09:01:41 +01:00
s-andro
02bb2b7477 GameDB: Gran Turismo 4 [PlayStation 2 Racing Pack] 2022-02-05 09:01:41 +01:00
TheLastRar
9cfce59547 DEV9: Check for null ifa_addr in PCAPGetIfAdapter 2022-02-05 00:51:50 +00:00
lightningterror
99f0d5c685 GS-hw: Properly enable/disable each channel based on fbmask, adjust fbmask detection when to do blending for 16bit/24bit.
Optimization.
2022-02-04 23:28:24 +01:00
lightningterror
f84cb1c9cc GS-hw: Optimize fbmask on 16bit format.
Set fbmask to 0 if unused bits are the ones enabling it, they aren't used anyway.
2022-02-04 19:27:08 +01:00
lightningterror
ae4733c59d GS-hw: Purge LordOfTheRingsThirdAge crc hack.
Shadows are now rendered correctly on all renderers.
2022-02-04 18:53:28 +01:00
Connor McLaughlin
2629c92a00 GS/Vulkan: Fix HDR resolve to cleared target
Fixes shadows in LOTR: Third Age.
2022-02-04 18:32:53 +01:00
Ty Lamontagne
4ccb922d1a Debugger: Make memory search size depend on platform 2022-02-04 16:52:27 +00:00
Ty Lamontagne
8113e9a168 Debugger: Fix memory search drawing and sizing
Now it should be sized a little better
A little funky on dpis greater than 100%
(sorry wx is not easy to work with)
2022-02-04 16:52:27 +00:00
Ty Lamontagne
a632f3c5cb Core: Lighten IOP breakpoint load
standardizeBreakpintAddress calls on the IOP just return the address unmodified. Considering this is called at least once every load / store instruction when there is an IOP OR EE memcheck enabled, it's pretty hot.
2022-02-04 16:52:27 +00:00
Tokman5
e64e2f2c4e Debugger: add register name pattern 2022-02-04 15:34:46 +00:00
RedDevilus
f6d49eb5b9 Qt: More sizing + improve hotkeys code
There were other sizing issues with region and CRC that are now have better width. Taking the liberty to organise the hotkeys as it is laid on the GUI-level + adding missing hotkeys. There is still much work to be done.
2022-02-04 02:26:01 +00:00
lightningterror
ee4f498a13 GS-hw: Re add alpha c check for clr_blend1_2.
Removed it by accident, nobody saw nothing.
2022-02-03 23:37:01 +01:00
lightningterror
3bdb1f8550 GS-hw: No PABE for hw clr_blend1_2 optimization.
Will require sw blend.
2022-02-03 23:34:59 +01:00
RedDevilus
971f060029 Qt: Fix type table sizing + spaces
Type table in the main window was not wide enough. Also adding spaces in some strings and removing some redundant spaces in others.
2022-02-03 15:22:08 +00:00
Connor McLaughlin
2684fd6b62 GS: Add depth copy convert shader 2022-02-03 15:20:35 +00:00
lightningterror
6085c5bf01 GS-hw: Enable Ad to As blend swap when it detects barrier(fbmask) on d3d11..
Allow to run it on basic level, fb is already read so there is no extra cost and is more accurate.
2022-02-03 10:16:16 +01:00
lightningterror
550f0d9936 GS-hw: Cleanup some stuff from clr3 blend. 2022-02-03 01:11:08 +01:00
lightningterror
9c00554118 GS-hw: Allow to run clr_blend1 and clr_blend2 over sw blending.
As or F case only, no Ad.

Allow condition to run when there are no texture barriers (gl/vk),
or copying the fb (d3d11).
Run when colclamp is 1 as hw blend will clamp value to 0-1.
Check for texture barriers, don't run if any is enabled.
2022-02-03 01:11:08 +01:00
lightningterror
ec7e8989a6 GS-hw: Move the sw blend for BLEND_C_CLR3 to High level and upper.
Reading the frame buffer is slow, let's allow hw blend to run, can partially handle it.
2022-02-03 01:11:08 +01:00
lightningterror
3ca4272230 GS-hw: Implement hw, hw/sw, sw blending on Ad when alpha write is masked.
Idea is to replace Ad with As when alpha write is masked,
then expand/let blend mix, accumulation blend non recursive blend or hw clr blend to
do the blending with Ad swapped as As.

We are doing this to try to bring some originally higher blending modes to lower levels
where we can do the draws with less texture barriers instead (gl/vk),
as for d3d11 this allows to run blending on the draws since previously the cases weren't handled properly,
it will be slower on d3d11 since we will be reading the frame buffer but it's better than nothing.

D3D11: It is enabled on Medium blending or higher, if draw is fbmask then it will enable
it on basic blending too.

OpenGL/Vulkan:
It is enabled based on the previous blending modes:
accumulation blend -> either minimum or basic level, depending on colclamp.
non recursive blend -> either minimum or basic level, depending on colclamp.
blend mix -> basic and higher level.
hw clr blend -> minimum and higher level.

All:
Prefer full sw blend when primitives don't overlap, sw fbmask or full barrier is used, it is more accurate.
2022-02-03 01:11:08 +01:00
lightningterror
ae14afd5f7 GS-hw: Combine BLEND_C_CLR2_AF and BLEND_C_CLR3_AS in one shader bit.
Free a shader bit.
2022-02-03 01:11:08 +01:00
RedDevilus
3d40b23496 GameDB: Beatmania entries
Adding missing entries so that Ziemas can be happy.
2022-02-02 23:52:59 +00:00
TellowKrinkle
88c0c41a70 CMake: Use relative paths for package mode
Allows relocating install prefix without recompiling
2022-02-02 17:09:48 -06:00
TellowKrinkle
176917caf4 CMake: Require gettext for translations on macOS
MacOS uses modified po files, which means it can't use the precompiled mos
2022-02-02 17:09:48 -06:00
TellowKrinkle
e2e8fdafb1 CMake: Make translation macro a function
Macros can set variables in the parent scope but we don't need that here
2022-02-02 17:09:48 -06:00
TellowKrinkle
aad8b09d81 CMake: Remove all argument option from translations macro
There's no reason you wouldn't want it
2022-02-02 17:09:48 -06:00
TellowKrinkle
90e3d9e460 CMake: Move translation file processing to main pcsx2 directory
Reduces workarounds for cmake dumbness
2022-02-02 17:09:48 -06:00
TellowKrinkle
baf9e4a9af CMake: Properly use MACOSX_PACKAGE_LOCATION for translations on macOS
Translations are now properly tracked by CMake and will be regenerated if you delete them
2022-02-02 17:09:48 -06:00
TellowKrinkle
1b453d0436 GUI: Move translations to resources directory
Also fixes finding translations in package mode builds
2022-02-02 17:09:48 -06:00
TellowKrinkle
49b1a496b1 GS: Fix OSD scaling on hidpi displays 2022-02-02 16:29:19 -06:00
TellowKrinkle
50afd83bc6 GUI: Fix scale factor on macOS 2022-02-02 16:29:19 -06:00
TellowKrinkle
85934dcbe2 GS: Track DPI change events 2022-02-02 16:29:19 -06:00
Connor McLaughlin
095ff20e2b GS/DX11: Fix binding depth as tex + fbmask 2022-02-02 20:05:54 +01:00
Connor McLaughlin
3a91ed2571 Vulkan/Context: Remove unused memory type functions
VulkanMemoryAllocator takes care of this.
2022-02-02 17:39:53 +00:00
Connor McLaughlin
20c534fc46 Vulkan/Context: Fix incorrect app name/version 2022-02-02 17:39:53 +00:00
Connor McLaughlin
0c0bd8be98 GS/Vulkan: Use fence counter for upload cmdbuffer selection
Readbacks don't increment the frame number, but submit the cmdbuffer.

Fixes incorrectly rendered status bar in Devil May Cry.
2022-02-02 17:39:53 +00:00
RedDevilus
ead6f9f4cd CI: Automatically label Qt
This will label PRs that touches on Qt-related files.
2022-02-02 17:33:41 +00:00
Connor McLaughlin
2328d9e107 ImGui/Vulkan: Don't leak font image/memory on reupload 2022-02-02 11:50:34 +00:00
Connor McLaughlin
87aa8333a8 ImGuiManager: Fix double init of font texture 2022-02-02 11:50:34 +00:00
Connor McLaughlin
f1de985304 GS: Reset/restore API state when changing OSD scale
Closes https://github.com/PCSX2/pcsx2/issues/5451
2022-02-02 11:50:34 +00:00
TellowKrinkle
5d3cbf8d1a GS: ReadAndExpandBlock4H_32 improvements 2022-02-02 09:34:30 +00:00
TellowKrinkle
c24ed8d47b GS: Use smartblend on WriteColumn32 2022-02-02 09:34:30 +00:00
TellowKrinkle
cbf4a83b3f GS: Minor Zen optimizations 2022-02-02 09:34:30 +00:00
TellowKrinkle
a6887715c7 GS: Faster palette lookup for AVX2 platforms with slow VPGATHERDD 2022-02-02 09:34:30 +00:00
TellowKrinkle
e2169bc1da GS: Consolidate repeated BlockH code 2022-02-02 09:34:30 +00:00
TellowKrinkle
89f3b46a9e GS: AVX2 ReadBlock4P 2022-02-02 09:34:30 +00:00
TellowKrinkle
d64e838b6d GS: AVX2 WriteBlock functions 2022-02-02 09:34:30 +00:00
TellowKrinkle
263e495561 GS: Make xmm → ymm zext/sext functions take GSVector4i
Removes the need for casts everywhere
Also renames them to remove the `c`, the fact that they take a GSVector4i should make it clear
2022-02-02 09:34:30 +00:00
TellowKrinkle
127433628d GS: AVX2 ReadAndExpandBlock4(HH|HL)_32 2022-02-02 09:34:30 +00:00
TellowKrinkle
29e8da0944 GS: pshufb-based ReadAndExpandBlock4(HH|HL)_32 2022-02-02 09:34:30 +00:00
TellowKrinkle
a2992c86e6 GS: AVX2 ReadAndExpandBlock8[H]_32 2022-02-02 09:34:30 +00:00
TellowKrinkle
1cc796b1a7 GS: AVX2 ReadAndExpandBlock4_32 2022-02-02 09:34:30 +00:00
TellowKrinkle
679cc7af38 GS: pshufb-based ReadAndExpandBlock4_32 2022-02-02 09:34:30 +00:00
TellowKrinkle
c4b3239e33 GS: Improved ReadColumn4 2022-02-02 09:34:30 +00:00
TellowKrinkle
4139da82b9 GS: Remove special casing alignment on AVX+
Extra code, unneeded as AVX+ has fast unaligned loads
2022-02-02 09:34:30 +00:00
TellowKrinkle
bdc7dc2cd8 GS: ReadColumn8 AVX2 path 2022-02-02 09:34:30 +00:00
TellowKrinkle
244a4da28a GS: ReadBlock16 performance improvements 2022-02-02 09:34:30 +00:00
TellowKrinkle
e7e0dbd29a GS: Drop SSE3 ReadColumn16
It was no faster than the SSE2 one and requires loading an extra shuffle vector
2022-02-02 09:34:30 +00:00
TellowKrinkle
1f6b2e629b GS: Use broadcast loads on AVX2
Broadcast loads are free on AVX2 processors, might as well use them
2022-02-02 09:34:30 +00:00
Connor McLaughlin
793ba944d6 GS/Vulkan: Prefer coherent for upload and cached for download buffers 2022-02-02 00:30:56 +00:00
Connor McLaughlin
438480517b GS/Vulkan: Prevent GS state overriding present viewport/scissor 2022-02-02 00:30:56 +00:00
Connor McLaughlin
e3b4d13c47 HostDisplay: Remove levels/layers from HostDisplayTexture
Wasn't implemented for updates, and we're not going to use it any time
soon.
2022-02-02 00:30:56 +00:00
Connor McLaughlin
3caebb31ae Qt: Add save state loading/loaded/saved events 2022-02-02 00:23:49 +00:00
Connor McLaughlin
8b9eee4961 Qt: Add QtUtils::StringViewToQString() 2022-02-02 00:23:49 +00:00
Mrlinkwii
280f5adb22 Readme: add note about Vulkan drivers 2022-02-02 00:22:06 +00:00
iMineLink
16cfcad0bf GS: fully support target rescaling in TC, take 2. 2022-02-02 00:21:48 +00:00
Tyler Wilding
51431d22ba memcard: fix YAML emitting bugs 2022-02-02 00:21:07 +00:00
Tyler Wilding
ef3bc9202b memcard: don't fail on bad yaml, but this isn't the underlying issue... 2022-02-02 00:21:07 +00:00
refractionpcsx2
cdae169922 GS: Add Point Pallete SW Render for 120-en no Haru
Fixes #5211
2022-02-02 00:14:41 +00:00
RedDevilus
c45a7a2ef6 GameDB: Urban Reign
EE cyclerate +1 will fix the issue but a compromise on default is to enable EE-Timing-hack. Ee cyclerate +1 can be combined with or without EETiming.
2022-02-01 23:02:58 +00:00
Mrlinkwii
ddf16b71c2 GameDB: add eerounding to 'Neopets - The Darkest Faerie' 2022-02-01 22:59:00 +00:00
Connor McLaughlin
d29f843525 GS/HW: Don't disable depth testing for channel shuffle
Mercenaries needs it. But we can skip it when z testing is off.
2022-02-01 12:40:40 +01:00
Connor McLaughlin
8ce8ac4404 GS/Vulkan: Handle case where DS == Texture
Technically we can handle this as another feedback loop, but in my
opinion it's not worth it, since there's only two games I've seen which
do this - Ico and Mercenaries.
2022-02-01 12:40:40 +01:00
TellowKrinkle
b55e59e665 GS: Fix region repeat bounds checking for zero crossings 2022-02-01 02:58:09 -06:00
TellowKrinkle
598a3b5d7b GS:HW: Avoid REGION_REPEAT when possible
We don't support upscaling for it right now
2022-02-01 01:24:35 +00:00
TellowKrinkle
8c16e3231e GS:HW: Add a few clamp mode optimizations 2022-02-01 01:24:35 +00:00
TellowKrinkle
eca5eced63 GS:HW: Handle coordinate wrapping on target-sized sources 2022-02-01 01:24:35 +00:00
TellowKrinkle
e87d8da1fb GS:TC: Track whether or not textures use their clamp modes 2022-02-01 01:24:35 +00:00
TellowKrinkle
f5fba1cbd1 GS: Add BitScanReverse polyfill 2022-02-01 01:24:35 +00:00
TellowKrinkle
06b4c3faab GS: Fix minmax of REGION_REPEAT 2022-02-01 01:24:35 +00:00
TellowKrinkle
6d0b9b3747 GS:HW: Don't scale rt when converting to texture
Scale texture coordinates instead
2022-02-01 01:24:35 +00:00
TellowKrinkle
92f2cef4d1 GS:HW: Default rt size to 0 2022-02-01 01:24:35 +00:00
lightningterror
5fdfbd470b Revert GS-hw: Exclude triangles from no prim overlap fb read on dx11.
Issue fixed in #5422
2022-01-31 19:13:45 +01:00
Connor McLaughlin
75b5f70196 CI: Build Qt binaries 2022-01-31 16:46:23 +00:00
PCSX2 Bot
b68be77865 pad-linux: Update to latest controller database. 2022-01-31 17:11:37 +01:00
refractionpcsx2
105aab0345 QT-SDL: Fix SDL Input compilation 2022-01-31 14:29:03 +00:00
Connor McLaughlin
9c3270a2de InputManager/SDL: Drop version checks
They're not needed since we're always using the latest SDL.
2022-01-31 14:21:38 +00:00
Connor McLaughlin
5c33e9666a Qt: Enable SDL2 input source for Qt 2022-01-31 14:21:38 +00:00
Connor McLaughlin
aeb9403b67 3rdparty: Add SDL2 2022-01-31 14:21:38 +00:00
Connor McLaughlin
50735567c9 Qt: Fix crash when disconnecting controller which isn't last in list 2022-01-31 13:56:28 +00:00
Connor McLaughlin
0e83c992c3 InputManager/XInput: Fix inverted/incorrect axes 2022-01-31 13:56:28 +00:00
Connor McLaughlin
dac7106df8 Qt: Make input binding dialog match widget 2022-01-31 13:56:28 +00:00
refractionpcsx2
11b467e455 QT: Remove 32bit build targets (which don't exist)
Use a separate environment varible for our QT folder to save conflicts
2022-01-31 12:40:25 +00:00
TellowKrinkle
7cc2437ef7 Core: Enable GS Debugger with DevMode flag 2022-01-31 12:54:57 +01:00
TellowKrinkle
8d4ffc0713 GSDumpGUI: Add framelimiter 2022-01-31 12:54:57 +01:00
TellowKrinkle
5ec5fb17ca GSDumpGUI: .gs.xz support 2022-01-31 12:54:57 +01:00
TellowKrinkle
234d643dd3 GSDumpGUI: Parse all the packets in a transfer 2022-01-31 12:54:57 +01:00
TellowKrinkle
7288a1fcb2 GSDumpGUI: Don't expand everything by default 2022-01-31 12:54:57 +01:00
TellowKrinkle
b8b23cd359 GSDumpGUI: Show packet data in main entry 2022-01-31 12:54:57 +01:00
TellowKrinkle
c05eaa9382 GSDumpGUI: Make window resizable 2022-01-31 12:54:57 +01:00
TellowKrinkle
6d14bda7b0 GSDumpGUI: Format floats with %g 2022-01-31 12:54:57 +01:00
TellowKrinkle
e2fd951ff3 GSDumpGUI: Cleanup 2022-01-31 12:54:57 +01:00
Mrlinkwii
bf598d5fe9 GameDB: add 'EETimingHack' to 'Indiana Jones and the Emperor's Tomb' 2022-01-31 10:42:55 +00:00
iMineLink
32f420dbe5 GS: fix overlap check in hw tc.
Textures can span a single block indeed.
Fixes Jak 3 desert rendering.
2022-01-31 09:39:54 +00:00
TellowKrinkle
6d0e35ddcb CMake: Prevent people from doing in-tree builds
Can create weird messes with include directories
2022-01-30 20:07:34 -06:00
dependabot[bot]
f9f4557841 Bump node-fetch in /.github/workflows/scripts/releases/announce-release
Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.5 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](https://github.com/node-fetch/node-fetch/compare/v2.6.5...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-30 19:06:25 +01:00
dependabot[bot]
d441cdba71 Bump node-fetch
Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.5 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](https://github.com/node-fetch/node-fetch/compare/v2.6.5...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-30 19:06:11 +01:00
dependabot[bot]
9f24fb618f Bump node-fetch
Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.5 to 2.6.7.
- [Release notes](https://github.com/node-fetch/node-fetch/releases)
- [Commits](https://github.com/node-fetch/node-fetch/compare/v2.6.5...v2.6.7)

---
updated-dependencies:
- dependency-name: node-fetch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-30 19:05:39 +01:00
refractionpcsx2
9d43641765 Build-QT: Fix error in VS Project 2022-01-30 15:27:20 +00:00
Connor McLaughlin
93f9ae8a31 Qt: Add work in progress interface 2022-01-30 14:29:18 +00:00
Connor McLaughlin
c2ca0852d9 Build: Add pcsx2core variant for Qt 2022-01-30 14:29:18 +00:00
Connor McLaughlin
8bedfc257f Common: Don't define __i386__ on Windows
It breaks Qt.
2022-01-30 14:29:18 +00:00
Connor McLaughlin
b709810079 PAD/Host: Add default settings 2022-01-30 14:29:18 +00:00
Connor McLaughlin
d4721d50f7 VMManager: Permit setting reload without active VM 2022-01-30 14:29:18 +00:00
Connor McLaughlin
14b54e554e InputManager: Add device/motor enumeration, connect callbacks 2022-01-30 14:29:18 +00:00
Connor McLaughlin
7555091d56 InputManager: Add UpdateSettings() to sources 2022-01-30 14:29:18 +00:00
Connor McLaughlin
dbc176fe25 GS/DX11: Don't bind 16 SRVs every draw
That's just silly.
2022-01-30 14:17:12 +00:00
Connor McLaughlin
0a45385d48 GS/DX11: Only copy draw area when sampling RT/depth
Should save a decent chunk of VRAM bandwidth outside of channel
shuffles.
2022-01-30 14:17:12 +00:00
Connor McLaughlin
f33ee27f56 GS: Get rid of extra binding for channel shuffle
Having this binding was redundant, as there's no "normal" texture
sampled when we're doing a channel shuffle, and it caused issues in
Vulkan when the render target or depth buffer the source.

Also fixes the Urban Chaos HLE shader.

Fixes validation errors in GT4, NFS: Carbon, Urban Chaos, probably
others too.
2022-01-30 14:17:12 +00:00
tellowkrinkle
5444b575f3 GS: Prefer one-frame-old textures 2022-01-28 18:17:31 -06:00
iMineLink
6361cd8268 GS: add TextureInsideRt flag to selected games. 2022-01-29 00:03:10 +00:00
iMineLink
0055fcf489 GS: add tex in rt hw hack in GUI. 2022-01-29 00:03:10 +00:00
iMineLink
b7899d0c8c GS-hw, TC: search tex in wrapping RT.
Improves Beyond Good & Evil shadow.
2022-01-29 00:03:10 +00:00
iMineLink
c1e5e45431 GS-hw, TC: search tex in rt in dirty targets.
Also move any target BW update from InvalidateVideoMem to LookupTarget.
Fixes Indiana Jones map rendering in cutscenes.
2022-01-29 00:03:10 +00:00
iMineLink
44d0966892 GS: improve GSDirtyRect psm conv., add bw field. 2022-01-29 00:03:10 +00:00
iMineLink
be0932f538 GS-hw, TC: add some const modifiers. 2022-01-29 00:03:10 +00:00
iMineLink
6cfa740f90 GS-hw: reset RT size on reset. 2022-01-29 00:03:10 +00:00
iMineLink
1bd8ec786b GS-hw, TC: log InvalidateLocalMem calls. 2022-01-29 00:03:10 +00:00
iMineLink
9a276d7289 GS-hw, TC: invalidate targets from LRU to MRU. 2022-01-29 00:03:10 +00:00
iMineLink
ac63d41daf GS-hw: lookup source before target.
- this avoids the currently used target to
become the MRU in its cache and correctly keeps
the target used by the previous draw as the MRU
during the lookup source call.
2022-01-29 00:03:10 +00:00
iMineLink
bd0a8a642b GS-hw, TC: log LookupSource calls. 2022-01-29 00:03:10 +00:00
iMineLink
3e9b38044f GS-hw, TC: improve tex in rt. 2022-01-29 00:03:10 +00:00
lightningterror
d8ca9b5f39 GS-hw: Replace depth +bilinear assert with log, also do some cost, fix some logs.
Assert was annoying when debugging, being hit too often.
2022-01-27 19:57:29 +01:00
lightningterror
e9f8e5eebd GS-hw: Properly disable skipdraw when userhacks are disabled. 2022-01-27 18:55:46 +01:00
lightningterror
bf2613ee49 GS-hw: Adjust how clr_blend is handled based on blend level on d3d11.
Blend level High and lower: Prefer clr_blend.
Blend level Full, prefer clr_blend when ALPHA.C != 1, otherwise sw when primitives don't overlap.
Blend level Ultra, remains the same but we can probably prefer clr_blend when alpha again is As or F, let's play it safe and leave it as it is for now.
2022-01-27 12:09:35 +01:00
lightningterror
3b691da8d1 GS-hw: Implement alternative hw blending for Cs*Ad, Cs*Ad + Cd, Cd - Cs*Ad.
Alpha destination value is wrong so let us try to compensate.

Multiply Cs by (255/128) in shader.
Will work best if Cs is 0.5 or less,  if it's higher than 0.5 then the closer to 1 the less accurate it gets.

Ofc it is best to use sw blending but it will help if sw blending is not present/selected for specific draw, will help d3d11 quite more.
2022-01-27 12:09:35 +01:00
Ty Lamontagne
4955a4ef98 GS-wx: Add extra check for shader options when VK is selected 2022-01-27 08:46:48 +01:00
lightningterror
ca55d86187 GS-hw: Exclude triangles from no prim overlap fb read on dx11.
Fixes mgs3 regression on ultra blending.
2022-01-25 21:34:35 +01:00
refractionpcsx2
5974856924 GS: Adjust auto interlace mode with scanmask(frame) 2022-01-25 00:18:01 +00:00
Mrlinkwii
bdb7c65ab0 Gamedb: remove EETimingHack from 'Paris-Dakar 2' 2022-01-24 21:19:03 +00:00
Florin9doi
45ba8690a9 USB: CaptureEye/OV511p webcam emulation 2022-01-24 21:06:03 +00:00
refractionpcsx2
7054190832 Revert "GS: fully support target rescaling in TC."
This reverts commit 2a2564cf45.
2022-01-24 21:02:10 +00:00
PCSX2 Bot
dbd997b551 pad-linux: Update to latest controller database. 2022-01-24 17:45:11 +01:00
refractionpcsx2
369bda13f8 GS: Only autoflush on draws of same format
Move overlap check to State
2022-01-24 12:00:37 +00:00
lightningterror
c9216e5625 GS-hw: Remove useless shader line from CLR As/Af case. 2022-01-24 11:42:54 +01:00
lightningterror
93af9656d0 GS-hw: Fix clr 1 case shader.
Forgot to rename.
2022-01-24 11:11:38 +01:00
refractionpcsx2
bcade5bb9d mVU: Clean up branch chain handling 2022-01-23 20:31:08 +00:00
refractionpcsx2
59ab303c5c mVU: Rework multiple branch chaining 2022-01-23 20:31:08 +00:00
lightningterror
4ab9d1a493 GS-hw: Implement alternative hw blending for Cd*As, Cd*F.
Do hw blend for Cd*As, Cd*F, expand the clear color blend method as it is almost the same.

Most helpful for dx11 ofc, for gl/vulkan will help with rendering on lower
levels of blending without needing a barrier.
2022-01-23 20:59:35 +01:00
refractionpcsx2
f1576eeb32 GameDB: Patch for Midnight Club 2 T-Bit 2022-01-23 18:35:30 +00:00
iMineLink
1f851887d9 GS: fix Majokko A-La-Mode 2 palette rendering. 2022-01-23 17:56:46 +00:00
iMineLink
2a2564cf45 GS: fully support target rescaling in TC.
Also avoid redundant clears when the target
is going to be completely drawn when rescaling.
2022-01-23 17:56:46 +00:00
Connor McLaughlin
b5a78763f8 GameList: Add game list and scanner functions 2022-01-23 17:15:48 +00:00
Connor McLaughlin
728e1ffdd0 VMManager: Introduce new manager functions
VMManager takes the place of all the core thread stuff for Qt.
2022-01-23 17:15:48 +00:00
Connor McLaughlin
14c9cfb310 InputManager: Add InputManager implementation 2022-01-23 17:15:48 +00:00
Connor McLaughlin
b511a54445 MemoryCardFile: Add routine to enumerate cards 2022-01-23 17:15:48 +00:00
Connor McLaughlin
f446e5ad3d SaveState: Save screenshot in state archive 2022-01-23 17:15:48 +00:00
Connor McLaughlin
c263c12448 HostDisplay: Add GetDriverInfo() 2022-01-23 17:15:48 +00:00
Connor McLaughlin
ed9b6f0d3f Vulkan/Context: Get driver properties 2022-01-23 17:15:48 +00:00
Connor McLaughlin
d3152bee9c GS: Add heuristic-based internal FPS 2022-01-23 17:15:48 +00:00
Connor McLaughlin
a504b429bd GS: Use global upscale multiplier 2022-01-23 17:15:48 +00:00
refractionpcsx2
7b6db5ad7a IPU DMA: If no underflow occurs on QWC = 0, end DMA.
Explanation in changes
2022-01-23 15:52:02 +00:00
Connor McLaughlin
398f675412 GS/Vulkan: Add image format check to features 2022-01-23 15:51:37 +00:00
Connor McLaughlin
d18bf338b6 Host: Fix ReportFormattedErrorAsync() 2022-01-23 15:51:37 +00:00
Connor McLaughlin
3091d28615 GS: Release host display if GS init fails
That way we don't try to create it when it already exists next attempt.
2022-01-23 15:51:37 +00:00
lightningterror
ab2365b475 GS-hw: Disable BLEND CD when full barrier is already enabled. 2022-01-22 23:59:02 +01:00
refractionpcsx2
7d356a2d20 GS: Force Blend TFF when scanmsk is used on the frame 2022-01-22 22:03:14 +00:00
refractionpcsx2
e5a4f27e79 VU: Adjust path for conditional evil blocks
Add patch for Pac-man World Rally
2022-01-22 21:43:45 +00:00
TellowKrinkle
9cbcda0f7b GS: Fix alpha blend mode clamping 2022-01-22 19:40:20 +01:00
Mrlinkwii
93b2cd6002 GameDB: add fixes for Simple Series vol.7 and other games 2022-01-22 17:06:18 +00:00
Mrlinkwii
411ed1e0c7 GameDB: add 'SkipMPEGHack' to "David Beckham Soccer" 2022-01-22 15:12:17 +00:00
TheLastRar
e5c4fe003b Build: Use git tag for file version on windows, attempt 2 2022-01-21 23:41:07 +00:00
TellowKrinkle
d6293ab081 Revert "Build: Use git tag for file version on windows"
This reverts commit 7f2a9f6806.
2022-01-20 23:17:43 -06:00
TheLastRar
38a5431ceb Build: Update file copyright to 2022
Also update the copyright year of SysForwardDefs.h
2022-01-20 22:52:09 +00:00
TheLastRar
7f2a9f6806 Build: Use git tag for file version on windows 2022-01-20 22:52:09 +00:00
lightningterror
6ab69e5c1c GS-hw: dbg: Fix blend debug logs. 2022-01-20 21:36:16 +01:00
lightningterror
cd902a12b3 GS-hw: Always enable full sw blend on full barrier, disable accumulation mode (hw/sw blend).
Full barrier requires full sw blend, disable accumulation mode for it (sw fbmask, date_barrier).
2022-01-20 21:02:25 +01:00
lightningterror
72809e8724 GS-hw: Purge TenchuFS, TenchuWoH crc hacks.
d3d11 will require high blending to render properly.
2022-01-20 21:02:25 +01:00
lightningterror
610cad00bf GS-hw: Move fbmask for texture shuffle on Basic level.
Shouldn't be that slow, right?
Also update comments.

Previous High level is now Medium.
2022-01-20 21:02:25 +01:00
lightningterror
4f5bbebcd8 GS-hw: Move blend mix condition to blend switch case.
Cleaner.
2022-01-20 21:02:25 +01:00
lightningterror
33f88039d7 GS-hw: Disable accumulation blend when there is fbmask with no overlap.
Using a mix of hw/sw will be slower, so let's just do full sw blend, we already read the fb.
2022-01-20 21:02:25 +01:00
lightningterror
2cf6b5052d GS-hw: Enable sw blend when prims don't overlap on basic blend with fbmask.
FBMASK already reads the fb so let's allow it to run sw blending since there will be no cost, only if fbmask is already running.
2022-01-20 21:02:25 +01:00
lightningterror
8cb680f34e GS-hw: Remove fbmask check for Genji.
Fb will be read when primitives don't overlap, no need for the mask check now.
2022-01-20 21:02:25 +01:00
lightningterror
f089ef3fbe GS-hw: Allow to sample the framebuffer when primitives don't overlap on d3d11.
All: check when prims don't overlap.

High: When there is no blend mix, accu blend, recursive.

Full: When there is no accu blend, or recursive.
alpha is higher than 1.

Ultra: When there is no accu blend or recursive blend.

Allow to check for overlap on d3d11.
Support sw colclip when prims don't overlap on d3d11.
Support sw pabe when prims don't overlap on d3d11.
2022-01-20 21:02:25 +01:00
lightningterror
e1d2d4b863 GS-hw: Fix interaction with hdr and sw colclip on PABE.
PABE will do full sw blend so we need to disable hdr and enable sw colclip instead.
2022-01-20 08:10:29 +01:00
lightningterror
d0b34dc04c GS-hw: Implement BLEND CD.
Allow hw blend only to do the math, output will be Cd, no need to run costly barriers, will help Vulkan/Opengl.

Disable colclip on BLEND CD as there is no wrapping, will help all renderers, especially on hdr cases.
2022-01-20 08:10:29 +01:00
refractionpcsx2
6a8cffe615 GameDB: Correct Kessen 2 Korean patch 2022-01-19 18:00:40 +00:00
Connor McLaughlin
d08101a5f4 GS/Vulkan: Fix combining DATE/barriers with HDR 2022-01-19 14:40:42 +01:00
Connor McLaughlin
7b6a26367a R5900: Use unsigned ops for add/sub 2022-01-17 20:08:11 +01:00
Connor McLaughlin
08ecf3f582 iR5900: Use unsigned math for constant prop of add/sub
Signed overflow is undefined.
2022-01-17 20:08:11 +01:00
arcum42@gmail.com
8d38e97c0b PAD: Clean up the remains of the old logging code from when this was Onepad. 2022-01-17 20:03:23 +01:00
iMineLink
4c167cf528 GS: remove redundant clears from tc. 2022-01-17 20:02:16 +01:00
iMineLink
7d27b675d0 GS: sparse targets need to be cleared on fetch. 2022-01-17 20:02:16 +01:00
PCSX2 Bot
0ef7e82548 pad-linux: Update to latest controller database. 2022-01-17 19:34:44 +01:00
iMineLink
8db0b52821 GS: optimize xxHash usage in palette hashing. 2022-01-16 11:54:58 +00:00
Connor McLaughlin
364199916f GS: Hash local memory blocks instead of expanded textures 2022-01-16 11:54:28 +00:00
iMineLink
42066ecaba GS: use xxHash to hash palettes. 2022-01-16 03:28:28 +00:00
Connor McLaughlin
986b5a2afe GS/DX11: Use shader cache 2022-01-16 03:17:04 +00:00
Connor McLaughlin
921689aa04 Common: Add D3D11 shader cache/compiler classes 2022-01-16 03:17:04 +00:00
TellowKrinkle
283dcaffe2 GS: Support wrapping off-the-end offsets in GSOffset 2022-01-16 02:00:53 +00:00
Christian Kenny
074ffacf9d GS: Don't apply offset when using SLBG. Fixes The Suffering video monitors 2022-01-15 23:19:55 +00:00
Silent
f1d3177b69 GUI: Make aspect ratio/frame limiter OSD messages keyed
Keyed messages don't pile up so spamming turbo/frame limiter
keys will not generate multiple messages now.
2022-01-15 13:51:54 +01:00
Mrlinkwii
fa50e9dd20 GameDB: add VUKickstartHack to Ghosthunter 2022-01-15 12:12:14 +00:00
icup321
d4de43a062 GameDB: Add eeRoundMode to Teen Titans & Scaler and fixes to other games (#5338) 2022-01-14 22:13:06 +00:00
TellowKrinkle
af795985fc GS:SW: Allow up to 32 threads without breaking 2022-01-14 19:24:51 +01:00
TellowKrinkle
610b19d646 GS:SW: Fix crash when scanline count wasn't divisible by thread count 2022-01-14 19:24:51 +01:00
arcum42
95c8915d78 Fix several gcc warnings. (#5232) 2022-01-13 12:19:23 -08:00
Mrlinkwii
6bdfec743c GameDB: add EETiming to 'Kya: Dark Lineage' 2022-01-13 11:40:24 +00:00
refractionpcsx2
e270c46703 GIF: Separate GIF Reset and GIF DMA Reset
The two shouldn't be reset together anyway, the GIF has no control over the DMA.
2022-01-13 09:53:11 +00:00
Mrlinkwii
0c0a866481 GameDB: add serials from #4535
Co-Authored-By: icup321 <28464642+icup321@users.noreply.github.com>
2022-01-13 09:52:36 +00:00
Mrlinkwii
28ca0aed48 GameDB: add patch to MX Unleashed Migrated
Co-Authored-By: icup321 <28464642+icup321@users.noreply.github.com>
2022-01-13 09:52:36 +00:00
lightningterror
ca9ab100e5 GS-hw: Add crc ids for Ape Escape 2.
Sp, De, It, Fr versions.
2022-01-13 03:32:33 +01:00
icup321
73732bfb29 GS-hw: Add/remove crc ids.
Add CRCs for (almost) all versions of R&C, WOC, & J&D.
Remove all non-retail crc versions.
Re-add Crash 4 version CRC, it's retail actually.

Original PR #4535

Close #4535
2022-01-13 03:17:24 +01:00
refractionpcsx2
048e7f4c1b GUI: Convert Power plan name to UTF-8 2022-01-12 18:45:47 +00:00
lightningterror
d041df8254 GS-hw: Don't enable blending when only alpha is written.
Optimization.
2022-01-12 18:15:50 +01:00
lightningterror
8e8b9a3cff GS-wx: Add tooltip for Preload Textures. 2022-01-11 15:11:43 +01:00
lightningterror
b7b65d7361 GS: Fix tooltips, d3d11 blend, add vulkan in tooltips. 2022-01-11 15:11:43 +01:00
lightningterror
6263c8a0cd GS-wx: Fix d3d11 blend option, broke during Vulkan merge.
Merge the option with GL/VK.
2022-01-11 15:11:43 +01:00
lightningterror
3c92054a6e GS-hw: Move PABE shader bit to the top of sw blending.
Early return when there is no sw blending, no need to run the blend code.
Optimization.
2022-01-11 13:15:56 +01:00
Connor McLaughlin
cf2b6a895f GS/DX11: Get rid of local context reference in GSTexture11 2022-01-11 12:30:11 +01:00
Connor McLaughlin
5bdb34521d GS/HW: Add a field for LOD clamp to sampler
This way SampleLevel for manual LOD doesn't get clamped.
2022-01-11 12:30:11 +01:00
Connor McLaughlin
e1e83c11cc GS: Compute mipmap levels in base device
Also fixes the incorrect number of levels.
2022-01-11 12:30:11 +01:00
Connor McLaughlin
0f5b17de0f GS/DX11: Implement automatic/manual LOD in pixel shader 2022-01-11 12:30:11 +01:00
Connor McLaughlin
568d9a3e30 GS/HW: Correct min lod/minification filter for mipmaps 2022-01-11 12:30:11 +01:00
Connor McLaughlin
1518b793dc GS/DX11: Fix mipmap textures and support trilinear 2022-01-11 12:30:11 +01:00
Connor McLaughlin
6182b46033 GSState: Minimum texture size is 1x1, not 2x2
Fixes out of bounds uploads when full mipmapping is enabled.
2022-01-11 12:30:11 +01:00
refractionpcsx2
4194553450 CDVD: Centralise cdvd.Ready updates + add MECHA_INIT bit 2022-01-10 22:57:09 +00:00
PCSX2 Bot
5f5a696717 pad-linux: Update to latest controller database. 2022-01-10 20:42:54 +01:00
lightningterror
35d516e140 GS: Fix GetRecommendedCRCHackLevel for Vulkan.
Issue #5312
2022-01-10 20:42:06 +01:00
refractionpcsx2
fb5e5cc13f CDVD: Don't delay abort commands on DVDs, at least for now..
Fixes #5301
2022-01-10 11:28:10 +00:00
lightningterror
aa475a8d2e GS-hw: Rename DATE_GL42 DATE_GL45.
DATE_GL42 -> DATE_PRIMID
DATE_GL45 -> DATE_BARRIER
2022-01-09 17:54:13 +01:00
Mrlinkwii
fa5c023d33 GameDB: add game fix to Cocoto Funfair 2022-01-09 16:08:58 +00:00
Connor McLaughlin
22d8e6f79f GS/SW: Use target instead of texture for upload 2022-01-09 16:35:34 +01:00
Connor McLaughlin
126ae4a0f0 GS/Vulkan: Handle uploads to render targets 2022-01-09 16:35:34 +01:00
Connor McLaughlin
68f18245a7 GS/DX11: Implement merge feedback write 2022-01-09 16:35:34 +01:00
Mrlinkwii
e2e25b7134 GameDB: fix some entries 2022-01-09 15:35:08 +00:00
Mrlinkwii
32088647c3 GameDB: add some missing serials 2022-01-09 13:27:06 +00:00
Mrlinkwii
baf8df9597 GameDB: add patches to Koukaku Kidoutai and fixes for other games 2022-01-09 13:25:16 +00:00
lightningterror
34aa266260 vcxproj: Add vulkan shaders and group shaders in renderer category. 2022-01-08 18:22:40 +01:00
refractionpcsx2
8c887c2eee CDVD: Adjust error timing and modify error used for high sector. 2022-01-08 17:07:43 +00:00
lightningterror
a95250cabb GS-hw: Purge WildArms4 and WildArms5 crc hacks.
Issue got resolved before 1.6 release.
2022-01-08 09:27:27 +01:00
lightningterror
96bc6807ae github: auto labeler: Add GS Vulkan label. 2022-01-08 08:35:02 +01:00
Connor McLaughlin
81a139b875 Vulkan: Force textures to be allocated in device local memory 2022-01-08 05:19:45 +00:00
Connor McLaughlin
1a3c20f0f7 Vulkan: Use memory budget extension where available 2022-01-08 05:19:45 +00:00
Connor McLaughlin
4f735d0201 GS: Prevent out of bounds copy for half_right TC target copies 2022-01-08 05:19:45 +00:00
Connor McLaughlin
ec0543335e GS: Fine gained change detection for mips/trifilter/anisotropy 2022-01-08 05:19:45 +00:00
Connor McLaughlin
0872d024f9 GSDevice: Add ClearSamplerCache() method 2022-01-08 05:19:45 +00:00
Connor McLaughlin
0ce21c91ef GS: Allocate mipmaps for Basic+ and only on non-copy textures 2022-01-08 05:19:45 +00:00
Connor McLaughlin
220c7c271b GS/Vulkan: Use VK_EXT_provoking_vertex where supported 2022-01-08 05:19:45 +00:00
Connor McLaughlin
bf389b94d6 GS: Add texture preloading option 2022-01-08 05:19:45 +00:00
Connor McLaughlin
6187f36c33 Vulkan/StreamBuffer: Use VulkanMemoryAllocator 2022-01-08 05:19:45 +00:00
Connor McLaughlin
73df4e4abf GS: Only swap DATE_GL42 with DATE_GL45 when full barriers are used
Saves the expensive draw splitting/barriers when mixed software blending
is used.
2022-01-08 05:19:45 +00:00
Connor McLaughlin
1a8a5a5e8e GS: Add Vulkan renderer 2022-01-08 05:19:45 +00:00
Connor McLaughlin
c4ab6280c6 Frontend: Add VulkanHostDisplay 2022-01-08 05:19:45 +00:00
Connor McLaughlin
a27b6a113a Common: Add Vulkan helper classes 2022-01-08 05:19:45 +00:00
Connor McLaughlin
a60ded5c94 3rdparty: Add Vulkan headers 2022-01-08 05:19:45 +00:00
Connor McLaughlin
5ff67d4b2d 3rdparty: Add glslang 2022-01-08 05:19:45 +00:00
Connor McLaughlin
874e3d976f GSTexture: Implement Save() using common code 2022-01-08 05:19:45 +00:00
Connor McLaughlin
90e1284d83 GS: Move mipmap generation flag to GSTexture 2022-01-08 05:19:45 +00:00
Connor McLaughlin
75518b71ea GS: Fix forced trilinear + full mipmapping
i.e. generate mips when not provided by the game and trilinear filtering
is forced on.
2022-01-08 05:19:45 +00:00
Connor McLaughlin
b355efd73a GS: Separate shader convert for float -> 16/32bit int 2022-01-08 05:19:45 +00:00
Connor McLaughlin
8e920d727f GS: Make GL_NNN macros device independent 2022-01-08 05:19:45 +00:00
Connor McLaughlin
5976be55f4 GS: Use textures instead of render targets for target copies
Saves the clear.
2022-01-08 05:19:45 +00:00
Ty Lamontagne
4c3df1a963 CMake: Pass -fsanitize=address to the linker when USE_ASAN 2022-01-08 00:15:51 +00:00
lightningterror
5b44f495ee GS-hw: Improve DATE selection.
Check for fbmask, accurate path isn't supported so just to DATE.
Check for FBA, all pixels will be 128 or more so use Fast path DATE_one.
2022-01-08 01:15:19 +01:00
refractionpcsx2
3951e15446 VIF: If Force break + Reset requested, Reset gets priority
Fixes #5275
2022-01-07 17:37:10 +00:00
lightningterror
b9da7c6f27 GS-d3d11: Enable amd broken point sampler hack only for amd.
Intel and Nvidia don't need it, get rid of it for them.
2022-01-07 14:06:53 +01:00
refractionpcsx2
c5ae4a6957 CDVD: If you abort, actually abort. 2022-01-06 14:16:31 +00:00
Connor McLaughlin
e40c2f97f0 SysThreadBase: Fix double init of SPU2 etc 2022-01-06 11:46:01 +00:00
Connor McLaughlin
1dbc11bdd5 IPU: Fix software renderer FMV hack without AR change 2022-01-06 09:05:41 +00:00
Connor McLaughlin
299edae7c0 GSDump: Fix renderer override 2022-01-06 07:32:32 +00:00
refractionpcsx2
86309bd837 GS SW: Adjust order SW is destroyed, fixes GS Dump crash 2022-01-06 07:15:01 +00:00
refractionpcsx2
0312e9026d Core: Savestate version bump 2022-01-05 17:13:50 +00:00
refractionpcsx2
a7bafb60e9 CDVD: Improve Break/Abort handling 2022-01-05 17:13:50 +00:00
refractionpcsx2
602769b9d0 CDVD: Add Eject IRQ 2022-01-05 17:13:50 +00:00
refractionpcsx2
e76546f8e4 CDVD: Implement speed register, fix up SpindleCtrl
Also Set the drive as not spinning when ejected
2022-01-05 17:13:50 +00:00
Mrlinkwii
a9ef1680ce GameDB: Removal of some patches and adding some fixes 2022-01-04 14:10:37 +00:00
trostboot
670ddef944 GameDB: Add VU Kickstart Hack to Dark Cloud 2/Dark Chronicle (#5266)
Co-authored-by: trostboot <trostboot@gmx.de>
2022-01-04 13:56:24 +00:00
TellowKrinkle
be6b8dce25 VTLB: Fix ppmap allocation in 64-bit 2022-01-04 13:01:49 +00:00
Connor McLaughlin
75fd20f5df 3rdparty: Add xxhash.h 2022-01-04 13:00:40 +00:00
Connor McLaughlin
f0509a6631 3rdparty: Add Vulkan Memory Allocator 2022-01-04 13:00:33 +00:00
PCSX2 Bot
702319c4ca pad-linux: Update to latest controller database. 2022-01-03 17:14:01 +01:00
iMineLink
d5bd187930 GS: fix loopPagesWithBreak last iteration logic. 2022-01-03 14:21:04 +00:00
RedDevilus
753036f0c8 ProgramLog: Comment out deleted keymapping 2022-01-03 10:18:59 +00:00
iMineLink
cfc763b488 gitignore: update gs debug gl filename. 2022-01-03 09:45:56 +01:00
Connor McLaughlin
7edfeab0b7 3rdparty: Remove freetype 2022-01-03 09:45:31 +01:00
Connor McLaughlin
226b0540c5 GS: Enhance stats 2022-01-02 15:06:39 +00:00
Connor McLaughlin
0c36647506 GS: Rewrite presentation interface and OSD 2022-01-02 15:06:39 +00:00
Connor McLaughlin
1348c8880e Add font resources 2022-01-02 15:06:39 +00:00
Connor McLaughlin
9334285edd 3rdparty: Add imgui 2022-01-02 15:06:39 +00:00
Connor McLaughlin
2330d3a056 GS: Use hardware point/line expansion where supported in GL 2022-01-02 15:06:39 +00:00
Connor McLaughlin
bce54a64ff GS: Use flat/nointerpolation for IIP=0 instead of GS 2022-01-02 15:06:39 +00:00
Connor McLaughlin
bd43400ad8 GS/OpenGL: Set features in Create() instead of constructor 2022-01-02 15:06:39 +00:00
Connor McLaughlin
b16c75324e GSState: Move m_dev to base class 2022-01-02 15:06:39 +00:00
TellowKrinkle
0ddef1169d GS: Fix config default label alignment 2022-01-01 16:58:26 -06:00
TellowKrinkle
4da09bd841 GS: Fix missing space in config dialog 2022-01-01 16:58:26 -06:00
TellowKrinkle
6811cd617b GS: Add system default adapter config option 2022-01-01 16:58:26 -06:00
TellowKrinkle
4e762c75b0 GS: Move adapter list stuff to module in GSUtil
Will be helpful for when renderers other than DX that let you choose adapters are added
2022-01-01 16:58:26 -06:00
TellowKrinkle
f471c30036 GS: Default adapter_index to -1 to indicate default 2022-01-01 16:58:26 -06:00
TellowKrinkle
aaed932a67 PAD:SDL: Remove fallback code for unsupported SDL versions 2022-01-01 16:36:15 -06:00
TellowKrinkle
5f168b1a1e PAD: Store rumble intensity as float
No longer have to worry about what the max value should be
Unlocks > 50% rumble power on new rumble API
2022-01-01 16:36:15 -06:00
TellowKrinkle
5d6f0d7e47 PAD: Call SDL_GameControllerUpdate during pad testing 2022-01-01 16:36:15 -06:00
TellowKrinkle
cf176f1b99 CMake: Remove SDL1.2 option
Not sure if it worked before but it definitely doesn't work now
2022-01-01 16:36:15 -06:00
TellowKrinkle
d97e867c07 GHActions: Cache patchelf 2022-01-01 16:36:15 -06:00
TellowKrinkle
3d0654dd48 PAD:SDL: Let users set their own hints from the config 2022-01-01 16:36:15 -06:00
TellowKrinkle
e688840703 PAD:SDL: Set some hints 2022-01-01 16:36:15 -06:00
TellowKrinkle
8bf272e806 PAD:SDL: Switch to SDL_GameControllerRumble for rumble
Old method was deprecated according to https://github.com/libsdl-org/SDL/issues/4435#issuecomment-896432954
2022-01-01 16:36:15 -06:00
TellowKrinkle
0744bc4004 GHActions: Build latest SDL on linux
Package manager version too old
2022-01-01 16:36:15 -06:00
TellowKrinkle
918f8cbe16 PAD: Format some things 2022-01-01 16:36:15 -06:00
xantares
b6dafff524 Rename ConfigSoundtouch.cpp to ConfigSoundTouch.cpp (#5238)
Fixes build on a case-sensitive filesystem
2021-12-31 16:51:36 -06:00
Mrlinkwii
34686dc167 GameDB: remove patches for 'Neo Contra' and add EE rounding and clamping 2021-12-30 15:15:38 +00:00
Ty Lamontagne
c0c75bf18e Linux: Fix executable case in PCSX2-linux.sh 2021-12-30 14:04:02 +00:00
lightningterror
66cfb403c6 GS-d3d11: MaxAnisotropy value range is 1-16, clamp it. 2021-12-29 15:45:41 +01:00
lightningterror
0375f9c0ae GS-wx: Aniso can run with nearest texture filtering so let's leave it.
Option just disabled the toggle, it would still run on opengl.
2021-12-29 15:45:41 +01:00
lightningterror
11ac758d78 GS-d3d11: Mirror anisotropic filtering behavior on Direct3D11.
Don't run aniso filter on m_convert.pt and m_convert.ln samplers.
Running m_convert.pt broke shadows on color clipping.

Also use the aniso bit from hw renderer.

Aniso will now behave the same as on OpenGL.
2021-12-29 15:45:41 +01:00
Filipe da Silva Santos
9e705b2f53 FileSystem: follow c++17 and unbreak FreeBSD 2021-12-28 19:11:18 -06:00
Filipe da Silva Santos
b475108ff3 ryml: unbreak non-Linux Unices 2021-12-28 19:11:18 -06:00
Florin9doi
ab34dff152 USB: Save Sony prints in BMP format 2021-12-29 00:38:52 +00:00
Florin9doi
6a3f093cfa USB: Sony DPP-MP1 printer emulation 2021-12-29 00:38:52 +00:00
lightningterror
04ef9af703 GS-hw: Optimize PABE.
Add an early condition to check if alpha is lower than 128, if so then no blending so early exit.
2021-12-28 18:39:32 +01:00
TellowKrinkle
b773ab3fb4 GHActions: Fix game controller db updater 2021-12-28 18:04:19 +01:00
refractionpcsx2
32085dc009 CDVD: Add detection for PS2 Linux Disc 2 2021-12-28 12:17:42 +00:00
refractionpcsx2
18fdfc26aa Core: Savestate version bump 2021-12-28 12:17:42 +00:00
refractionpcsx2
f50d2fa48e CDVD: Add more error checking, set seek status 2021-12-28 12:17:42 +00:00
refractionpcsx2
e82859c979 CDVD: Separate SCMD/NCMD Fifo's set to right size 2021-12-28 12:17:42 +00:00
refractionpcsx2
99bb35f109 CDVD: Added missing busy/ready checks 2021-12-28 12:17:42 +00:00
refractionpcsx2
8637f8ee9b CDVD: Extra error handling and fix some flag details 2021-12-28 12:17:42 +00:00
refractionpcsx2
1e11d40828 CDVD: Improve status handling/implement sticky status 2021-12-28 12:17:42 +00:00
refractionpcsx2
5546b102eb CDVD: Replace cdvd.Ready handling 2021-12-28 12:17:42 +00:00
refractionpcsx2
7d9c8c9172 CDVD: Add some error handling, fix up some IRQ stuff 2021-12-28 12:17:42 +00:00
refractionpcsx2
8dd51b7207 CDVD: Zero sector handling and fix CdStop 2021-12-28 12:17:42 +00:00
lightningterror
746c5b603f GS: Try to fix -Wreorder warning. 2021-12-28 10:09:08 +01:00
qurious-pixel
d0de8d22fe MISC: codacy fixes 2021-12-28 08:54:17 +00:00
qurious-pixel
231b8e9481 reference the app-variables.sh apprun-hook file 2021-12-28 08:54:17 +00:00
qurious-pixel
f9f36700bb Update AppRun 2021-12-28 08:54:17 +00:00
qurious-pixel
ba9fced3db Create app-variables.sh 2021-12-28 08:54:17 +00:00
Connor McLaughlin
c192ecf6b7 GSDumpDialog: Cache length instead of querying every packet
Length() internally calls fseek() to end, ftell(), and fseek() back
again (really slow).

Shaves several seconds off loading large gs dumps.
2021-12-28 07:43:28 +00:00
Connor McLaughlin
6ee029e14b PAD: Add platform independent implementation 2021-12-28 05:22:45 +00:00
Connor McLaughlin
935f880fa7 USB: Fix compilation of USBNull on Windows 2021-12-28 05:22:45 +00:00
Connor McLaughlin
47d046c5fe DEV9: Prepare for Qt 2021-12-28 05:22:45 +00:00
Connor McLaughlin
4305e17cbe SPU2: Prepare for Qt (add Host wrapper) 2021-12-28 05:22:45 +00:00
Connor McLaughlin
c5c4cdd0b4 PINE: Disable for Qt (for now) 2021-12-28 05:22:45 +00:00
Connor McLaughlin
252562db90 Misc: #ifdef out last bits of wx-dependent code 2021-12-28 05:22:45 +00:00
Connor McLaughlin
a898682f3e Host: Add layered settings interface for per-game settings 2021-12-28 05:22:45 +00:00
Connor McLaughlin
7829094668 3rdparty: Add simpleini 2021-12-28 05:22:45 +00:00
Connor McLaughlin
042c23a545 Config: Add folder initializers 2021-12-28 05:22:45 +00:00
Connor McLaughlin
af2b9e3a4c Config: Add SPU2 options to global struct 2021-12-28 05:22:45 +00:00
Connor McLaughlin
b3b7c55b9a Host: Add ReportErrorAsync() and formatted variant 2021-12-28 05:22:45 +00:00
Connor McLaughlin
1859ede325 GameDatabase: Use resource abstraction to read yaml 2021-12-28 05:22:45 +00:00
Connor McLaughlin
2c32c374fb GameDatabase: Don't include rapidyaml in header
Name clashes with Qt.
2021-12-28 05:22:45 +00:00
Connor McLaughlin
65d22406a3 SettingsWrapper: Fix enums being stored as ints 2021-12-28 05:22:45 +00:00
Connor McLaughlin
92689a60ae Common/StringUtil: Add whitespace strip methods 2021-12-28 05:22:45 +00:00
Connor McLaughlin
1a598ccf0d Common/StringUtil: Add wide string conversion for non-windows 2021-12-28 05:22:45 +00:00
Italo Di Renzo
e50feb74fd Add "Clear missing files" option to recent ISO list (#4975)
* GUI: Add "Clear missing files" option to Recent ISO list

* GUI: Show list of files to remove in confirmation dialog.
2021-12-27 20:50:04 -08:00
arcum42
af067a8c84 Default to a native build. Remove --clean-plugins. (#5132) 2021-12-27 20:31:27 -08:00
tellowkrinkle
61a196bc3d GS: Move afix check to high blend level 2021-12-27 20:18:47 -06:00
lightningterror
6a431daffc GS-hw: Extend Blend mix to work when alpha is higher than 1.
Clamp the alpha(As/Af) to 1 in the shader, it is already clamped to 1 in hw blend unit.
It should allow to better render the effects, still not fully accurate but it's closer to what we want.
Hopefully it helps D3D11 more.
2021-12-27 20:22:41 +01:00
Mrlinkwii
1aad3e6cc8 GameDB: add VU clamping to "Ultimate Spider-Man" and fixes to other games 2021-12-27 18:02:16 +00:00
refractionpcsx2
c8d42e32ed GameDB: Properly use vuRoundMode child node 2021-12-27 03:47:52 +00:00
refractionpcsx2
514cc6edb8 IPU: Unbreak previous change with IDEC sync
Testing in Production y'all
2021-12-26 23:44:50 +00:00
lightningterror
208d3ffa7b GS-hw: Fix pabe regression from renderers merge.
Only OpenGL should disable accumulation and blend mix to allow reading the framebuffer next.

Also pabe will only be accurate with non recursive blend on d3d11 only so enable it for it only.
2021-12-26 19:12:28 +01:00
refractionpcsx2
25dd92f8c0 IPU: Modify IDEC sync position.
Previously broke the Onimusha patch, sorry
2021-12-26 14:56:52 +00:00
Connor McLaughlin
3f81b7e56d GL/ShaderCache: Time various shader compilation tasks 2021-12-26 13:21:51 +00:00
Connor McLaughlin
99b7333991 GS/OpenGL: Add option to disable shader cache 2021-12-26 13:21:51 +00:00
Connor McLaughlin
a2ae4ba441 GS/OpenGL: Get rid of interface blocks for convert shaders 2021-12-26 13:21:51 +00:00
Connor McLaughlin
4e1b2792c9 GS/OpenGL: Move some uniform buffers to program uniforms 2021-12-26 13:21:51 +00:00
Connor McLaughlin
55695bb5bc GS/OpenGL: Use ShaderCache 2021-12-26 13:21:51 +00:00
Connor McLaughlin
6e064da536 GS/OpenGL: Use programs instead of separate pipelines 2021-12-26 13:21:51 +00:00
Connor McLaughlin
69ff12645c Common: Add GL/ShaderCache 2021-12-26 13:21:51 +00:00
Connor McLaughlin
efb93d22d9 Common: Add GL Program wrapper class 2021-12-26 13:21:51 +00:00
Connor McLaughlin
cdb0068dcc Common: Add MD5Digest 2021-12-26 13:21:51 +00:00
Connor McLaughlin
b0a0d714c4 Common: Add HashCombine.h 2021-12-26 13:21:51 +00:00
refractionpcsx2
7e36ee243c GameDB: Fix Round/Clamp nodes 2021-12-26 11:58:27 +00:00
Sergeanur
21bc56a8ba GS: Simulate scan mask 2021-12-26 11:51:25 +00:00
refractionpcsx2
e920c0fe3e VS: Fix filters 2021-12-26 10:37:43 +00:00
refractionpcsx2
31992fb398 GameDB: Fix loading patches for some games 2021-12-26 08:43:06 +00:00
refractionpcsx2
dc65599fae GameDB: Remove no longer required patches 2021-12-26 04:48:49 +00:00
refractionpcsx2
eb9dc7b70d IPU: BDEC/IDEC wait for IPU0 to drain before proceeding 2021-12-26 04:48:49 +00:00
refractionpcsx2
06bf2502a6 IPU: Tidy up and fix up toIPU DMA, remove some hacks 2021-12-26 04:48:49 +00:00
refractionpcsx2
242655bac9 IPU: Tidy up some DMA and FIFO behaviour 2021-12-26 04:48:49 +00:00
refractionpcsx2
8335b3ee77 IPU: Only fill IPU with required data, no more. 2021-12-26 04:48:49 +00:00
refractionpcsx2
a0c8ad9511 Savestate: Bump version 2021-12-26 04:48:49 +00:00
refractionpcsx2
d775a9364b IPU: Set DMA to only transfer on request (or reset) 2021-12-26 04:48:49 +00:00
Ty Lamontagne
1695124472 Linux / Windows CMake Builds: Change output executable to lowercase
No reason to be uppercase.
2021-12-25 15:11:17 +00:00
Tyler Wilding
70145eb150 macos: add undef to fix macOS builds 2021-12-25 15:11:01 +00:00
Tyler Wilding
dacd7d94d9 memcard: fix saving and loading handling on new yaml lib 2021-12-25 15:11:01 +00:00
Tyler Wilding
85bd8555c0 common: add some file-path helpers to Path ns 2021-12-25 15:11:01 +00:00
Tyler Wilding
6920b4e366 gamedb: handle yaml parsing errors properly 2021-12-25 15:11:01 +00:00
Tyler Wilding
bda3835cb1 memcard: migrate folder memory cards to rapidyaml 2021-12-25 15:11:01 +00:00
Tyler Wilding
83e5aa6137 gamedb: migrate GameDB implementation to rapidyaml 2021-12-25 15:11:01 +00:00
Tyler Wilding
4719e52c6e fs-api: extend host API to allow retrieval of a resource file path 2021-12-25 15:11:01 +00:00
Tyler Wilding
e313eadcd2 common: pull our string functions into common 2021-12-25 15:11:01 +00:00
Tyler Wilding
be952e40ba vs: update project configuration to include rapidyaml 2021-12-25 15:11:01 +00:00
Tyler Wilding
4d4b24f8b0 cmake: support rapidyaml 2021-12-25 15:11:01 +00:00
Tyler Wilding
9533fa25c3 deps: remove yaml-cpp and add rapidyaml 2021-12-25 15:11:01 +00:00
lightningterror
013c9072b9 GS-hw: Move the blend mix alpha check after sw blending selection.
Optimization.
2021-12-25 14:52:07 +01:00
lightningterror
bf8dc05fac GS: Redo GetAlphaMinMax.
Cleaner this way, also fix recent regression on Full Blend with alpha max.
2021-12-25 14:52:07 +01:00
Connor McLaughlin
f4b38662fa GS/Null: Move methods to cpp file 2021-12-24 11:01:00 +00:00
Connor McLaughlin
ea41cce5ef GS: Add missing override specifier to a few files 2021-12-24 11:01:00 +00:00
TellowKrinkle
013c292ffb GS: Fix looping over pages of textures with massive strides 2021-12-23 19:10:19 -06:00
refractionpcsx2
cb18f11133 GS: Added auto Mipmap support in hardware for Jurassic Park 2021-12-23 08:25:52 +00:00
TellowKrinkle
ea25f49c65 Common: Fix GetWorkingDirectory on unix 2021-12-23 07:49:14 +00:00
Connor McLaughlin
5d15d5958e GS: Only copy draw area for colclip/DATE 2021-12-22 11:41:57 +01:00
Connor McLaughlin
efed92b15c GS/OpenGL: Move scaling factor to shader constant 2021-12-22 11:41:57 +01:00
Connor McLaughlin
7d39d02e98 GSDeviceOGL: Don't set scissor unconditionally 2021-12-22 11:41:57 +01:00
Connor McLaughlin
e006442e4f GSRendererNew: Remove another constant buffer copy 2021-12-22 11:41:57 +01:00
Connor McLaughlin
212848e931 GSDevice: Force inline accessor methods
Don't want to make debug builds slower.
2021-12-22 11:41:57 +01:00
Connor McLaughlin
732de53d1b GS: Get rid of second constant buffer for alpha pass 2021-12-22 11:41:57 +01:00
Connor McLaughlin
08c00eed1e GS: Unify constant buffers between renderers 2021-12-22 11:41:57 +01:00
refractionpcsx2
2a1c3d1f33 GS: Fix texture offset Y vector 2021-12-20 16:30:26 +00:00
lightningterror
5f57084ed9 GS-hw: Run GetAlphaMinMax only when required for Blend Mix.
Optimization.
2021-12-20 16:23:43 +01:00
lightningterror
9368e29d62 GS-d3d11:fx: Flip x and y dithering positions. 2021-12-19 22:24:30 +01:00
TellowKrinkle
ae8751e9ca GS:DX11: Use GSHWDrawConfig selector structs 2021-12-19 22:21:10 +01:00
TellowKrinkle
a11b8c4750 GS:OGL: Use GSHWDrawConfig selector structs 2021-12-19 22:21:10 +01:00
TellowKrinkle
1e7e23df96 GS: Less memcmp
It has a lot of work to do for its fancier return value
2021-12-19 22:21:10 +01:00
TellowKrinkle
8395e00835 GS: Remove now-unused renderers 2021-12-19 22:21:10 +01:00
TellowKrinkle
66bc1bdc77 GS: Add new shared hw renderer 2021-12-19 22:21:10 +01:00
TellowKrinkle
b8984661d9 GS: Use shared enum for blend level
Even if DX11 doesn't support all modes we can just use the ones it does support from the enum
2021-12-19 22:21:10 +01:00
Mrlinkwii
ea98a1c9f9 GameDB: change VUclamping on "Sled Storm" 2021-12-19 16:45:31 +00:00
Connor McLaughlin
9173b40e2e SPU2: Add function to pause output stream 2021-12-19 15:14:04 +00:00
Connor McLaughlin
59e5b1918f SPU2/XAudio: Get rid of exceptions 2021-12-19 15:14:04 +00:00
Connor McLaughlin
ab4b7b8ee6 SPU2: Remove unused methods from output modules 2021-12-19 15:14:04 +00:00
Connor McLaughlin
7f0f153ebd 3rdparty: Remove Portaudio 2021-12-19 15:14:04 +00:00
Connor McLaughlin
f3d51a242d SPU2: Remove Portaudio and SDL2 output modules 2021-12-19 15:14:04 +00:00
Connor McLaughlin
88ce192610 SPU2: Add Cubeb SndOut driver 2021-12-19 15:14:04 +00:00
Connor McLaughlin
bd489647e9 3rdparty: Add cubeb 2021-12-19 15:14:04 +00:00
Florin9doi
c36666b4d4 USB: Gametrak/RealPlay 2021-12-19 13:33:04 +00:00
Connor McLaughlin
97727cae2c GS/OpenGL: Don't delete null objects for PBO 2021-12-18 14:12:37 +00:00
Connor McLaughlin
f412b6818e GS/OpenGL: Fix incorrect VAO cleanup
This wasn't an issue in wx, since the whole context/device gets torn
down and recreated when you pause/unpause, or change settings.

But on Qt it is, since the context/device is preserved for a
faster/lighter settings apply.
2021-12-18 14:12:37 +00:00
Mrlinkwii
e8aea86e75 GameDB: Add EE Clamping to 'Digimon Battle Chronicle' and fixes to other games (#5178) 2021-12-18 14:04:18 +00:00
Connor McLaughlin
fac171fa95 CDVD: Check file actually opened before proceeding
If you loaded an invalid file, particularly with compression, the file
open may fail, leading to a division by zero (on block size), or trying
to read from nothing.
2021-12-18 13:41:56 +00:00
refractionpcsx2
fa1b6493da CDVD GZip: Correct type causing index creation to fail 2021-12-17 11:46:31 +00:00
refractionpcsx2
e58766745c Log: Restore BIOS Found message 2021-12-16 11:45:12 +00:00
Mrlinkwii
d8a9c5b479 Gamedb add gamefixes to 'Titeuf Mega-compet' and patch 'Yamiyo ni Sasayaku - Tantei Sagara Kyouichirou' series 2021-12-15 17:17:18 +00:00
Mrlinkwii
9a4d8ba934 Gamedb: add more 2k games patches 2021-12-15 10:52:22 +00:00
refractionpcsx2
ab816543c8 CDVD: Fixed typo opening gzip files
Fixes #5162
2021-12-15 09:38:04 +00:00
refractionpcsx2
37ccd81985 GS: Avoid some unnecessary flushes
CLUT only updates if valid index type used in PSM
2021-12-14 18:28:21 +00:00
refractionpcsx2
42dad4ade8 GS: Check CLUT dirty write on vertex kick 2021-12-14 18:28:21 +00:00
refractionpcsx2
b2ac035862 VS: Fix location of shaders in project 2021-12-14 17:47:53 +00:00
refractionpcsx2
f42d7eec74 CDVD: Don't set as Reading when buffering. 2021-12-14 10:35:12 +00:00
refractionpcsx2
e4ef41f86a CDVD: Fix some read timing logic 2021-12-14 10:35:12 +00:00
Mrlinkwii
103dd3954a missing UI and game elements. 2021-12-14 09:22:31 +00:00
Tokman5
2f9577a28e Add "Jikkyou Powerful Pro Yakyuu 2009" to GameIndex.yaml 2021-12-14 08:06:34 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
33ec4d9430 msvc: fix issues with size() not being correctly evaluated as const 2021-12-13 09:34:24 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
209f09ca7a pine: send serial without gui beautification 2021-12-13 09:34:24 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2e6af75f1d pine: add vle replies 2021-12-13 09:34:24 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f68122a380 ipc: rename to pine 2021-12-13 09:34:24 +00:00
TellowKrinkle
d51bdccf7f CMake: Remove gio dependency on macOS 2021-12-13 03:29:16 -06:00
iMineLink
7d8377b133 GS-hw: define some consts only in debug mode. 2021-12-13 08:06:52 +01:00
iMineLink
80d3a8a757 GS-hw, TC: don't linearly interpolate downloads.
Greatly improves Burnout games clouds rendering
with even (x2, x4, ...) upscaling factors.
2021-12-13 08:06:52 +01:00
iMineLink
2e6c5cde29 GS-hw: rework surface fetching.
Factorized code.
Always clear render targets and depth stencils
when being fetched.
"force_texture_clear" OGL only config removed.
2021-12-13 08:06:52 +01:00
iMineLink
0f2768dca4 GS-hw, TC: improve LookupTarget.
allow propagation of increased target size and
correct the rescaling.
2021-12-13 08:06:52 +01:00
iMineLink
d5be095482 GS-hw: fix burnout black sky and no clouds.
Achieved with a combination of OI+OO hacks that operate
during level loading to consolidate the rendering results
in the GS local memory.

* OI_BurnoutGames to perform small draws directly in local memory:
** improved OI_PointListPalette to draw clouds CLUT,
** improved SwSpriteRender to draw sky texture;
* OO_BurnoutGames used to download clouds texture from GPU.
2021-12-13 08:06:52 +01:00
iMineLink
b315625a94 GS-hw: resize rt and ds before draw if necessary. 2021-12-13 08:06:52 +01:00
iMineLink
6b51462fa0 GS-hw: use CanUpscale to check for upscaling. 2021-12-13 08:06:52 +01:00
iMineLink
373e698545 GS-hw, TC: fix tex scaling for native res draws.
The GSTextureCache::ScaleTexture method did not work
correctly when an old texture with a scale factor
different from 1 was recycled for a draw which was forced at
native resolution (the old scale factor was kept).
2021-12-13 08:06:52 +01:00
iMineLink
3b309c6d4e GS: dump alpha channel too. 2021-12-13 08:06:52 +01:00
kenshen112
8e93e9f516 CMake: Switch Wayland find script and usage to use imported targets
Also clears warning about mismatched names getting sent to FIND_PACKAGE_HANDLE_STANDARD_ARGS
2021-12-13 00:23:52 -06:00
kenshen112
ac8582eca7 CMake: Set minimum version first
Makes policy enabling based on minimum version work properly
Also increases minimum version to 3.11 because we actually do use 3.11 features
2021-12-13 00:23:52 -06:00
kenshen112
e6f72fdde7 GHActions: Enable Wayland in CI builds 2021-12-13 00:23:52 -06:00
Connor McLaughlin
9166218d07 EERec: Remove zero-distance jmp in full fpu mode 2021-12-13 00:56:50 +00:00
Mrlinkwii
c0b1bde94b Gamedb: add EEclamping to 'Dark cloud 2' 2021-12-12 22:31:30 +00:00
Mrlinkwii
756a679262 Gamdb:add EE clamping to 'Chou Saisoku! Zokusha King B.U.' 2021-12-12 21:35:54 +00:00
Mrlinkwii
13b19b35c0 GameDB: add patches to the 'Netsu Chu!' series and 'Samurai 7' series 2021-12-12 18:16:46 +00:00
Mrlinkwii
cadb70d1e4 Gamedb: add EEtiminghack to 'MGS2' and change VU and EE rounding for 'Primal' and add missing entries 2021-12-12 12:30:47 +00:00
TellowKrinkle
4cb4844e8d AppImage: Fix resource location 2021-12-12 06:10:47 -06:00
TellowKrinkle
556c7ca080 CMake: Don't include non-windows files on non-windows 2021-12-12 06:10:47 -06:00
TellowKrinkle
962db4bfc4 Resources: Move fxaa.fx to out of dx11 directory
It was used by both DX and OGL
2021-12-12 06:10:47 -06:00
TellowKrinkle
da651cabe4 Resources: Move shaders to shared shader/ directory 2021-12-12 06:10:47 -06:00
TellowKrinkle
e03076c6ff CMake: Fix macOS resource packaging
Previously was just putting in empty folders
2021-12-12 06:10:47 -06:00
refractionpcsx2
122968e63a CDVD: No rotational delay for seeks less than buffered sectors
Fixes Shadow Hearts Covenant hangs
2021-12-12 06:33:01 +00:00
Connor McLaughlin
6beac26727 GS/OpenGL: Fix an unused variable warning 2021-12-12 03:27:43 +00:00
Connor McLaughlin
3073281d13 CMake: Fix package mode 2021-12-12 03:27:43 +00:00
TellowKrinkle
0e0e23eefb PAD: Use files on disk instead of embedded resources 2021-12-12 03:27:43 +00:00
Connor McLaughlin
bcec38bd97 Patch: Make variables static 2021-12-12 03:27:43 +00:00
Connor McLaughlin
bd706f99b2 GlobalCommands: Remove FreezeGS
This was ifdefed out anyway...
2021-12-12 03:27:43 +00:00
Connor McLaughlin
501af632f7 IopBios: Use FileSystem for host access 2021-12-12 03:27:43 +00:00
Connor McLaughlin
a143122804 CI: Copy resources into AppImage 2021-12-12 03:27:43 +00:00
Connor McLaughlin
92aa426bba Move cheats_ws.zip to resources directory 2021-12-12 03:27:43 +00:00
Connor McLaughlin
96a1ce2fb2 CI: Fix path to GameIndex.yaml 2021-12-12 03:27:43 +00:00
Connor McLaughlin
c203a09435 Wx: Add check for resources directory before starting 2021-12-12 03:27:43 +00:00
Connor McLaughlin
c4084b4162 Add PerformanceMetrics to replace multiple sources of truth 2021-12-12 03:27:43 +00:00
Connor McLaughlin
2a7c948a57 GameDatabase: Store enums instead of strings 2021-12-12 03:27:43 +00:00
Connor McLaughlin
46912595ea GameDatabase: Move out of gui 2021-12-12 03:27:43 +00:00
Connor McLaughlin
120ee6c673 Get rid of wxChar in EnumToString 2021-12-12 03:27:43 +00:00
Connor McLaughlin
112238fbd7 Config: Add cache folder 2021-12-12 03:27:43 +00:00
Connor McLaughlin
38e288ef6a Common: Add utility classes 2021-12-12 03:27:43 +00:00
Connor McLaughlin
35322cf49b BiosTools: Add autoloader 2021-12-12 03:27:43 +00:00
Connor McLaughlin
8d44e1af0e CDVD: Remove wx from file access 2021-12-12 03:27:43 +00:00
Connor McLaughlin
16af078b3b BiosTools: Remove wx 2021-12-12 03:27:43 +00:00
Connor McLaughlin
3e968b4390 GS: Use files on disk instead of embedded resources 2021-12-12 03:27:43 +00:00
Connor McLaughlin
0029dac32d Host: Add the ability to read files from the resources directory 2021-12-12 03:27:43 +00:00
Connor McLaughlin
a083343c6e Common: Add FileSystem 2021-12-12 03:27:43 +00:00
refractionpcsx2
c277ee1d34 GS: D3D11 Download texture use rect 2021-12-10 11:06:36 +00:00
refractionpcsx2
ebe8592a8d GS: Fix typo on GS download
Fixes #5131
2021-12-10 09:49:50 +00:00
lightningterror
6c3e357d9e GS-ogl: Optimize fragment shader uniform buffer.
Couple MaxDepthPS with TA and Af vector.

Vectors are free so let's use them.

Optimization.
2021-12-10 03:44:47 +01:00
TellowKrinkle
64455620e8 GS: Use actual names for GL convert shaders 2021-12-09 05:26:26 -06:00
TellowKrinkle
fc799778de GS: Use actual names for DX11 convert shaders 2021-12-09 05:26:26 -06:00
TellowKrinkle
e04e0e38d1 GS:GL: Move TextureOffset to vs cb
It's used by the vs, why would you put it in the ps cb?
2021-12-09 05:26:26 -06:00
TellowKrinkle
8d6569be95 GS: Remove separate GSTextureCaches 2021-12-09 05:26:26 -06:00
TellowKrinkle
8b086a3898 Common: Clean up ScopedAlloc 2021-12-09 05:26:26 -06:00
TellowKrinkle
a4b8c33cf3 GS: Convert texture format to enum 2021-12-09 05:26:26 -06:00
TellowKrinkle
1d37ba47f4 GS: Make GSTexture::Type an enum class 2021-12-09 05:26:26 -06:00
TellowKrinkle
8d480c28ce GS: Remove unused virtuals from GSDevice 2021-12-09 05:26:26 -06:00
TellowKrinkle
6e38f40f96 GS: Convert ShaderConvert to enum class 2021-12-09 05:26:26 -06:00
arcum42
017c37f212 Only pass C++ flags to C++ files. (#5115) 2021-12-08 21:10:21 -08:00
TellowKrinkle
6eee4cb38a Core: Remove empty file
Had everything commented out and there's already a file with the same name and things not commented out in CDVD
2021-12-08 11:18:42 +00:00
TellowKrinkle
1f6a14261c VS: Add missing filters 2021-12-08 11:18:42 +00:00
refractionpcsx2
14e8d840ff GS SW: Handle flat prims without float conversion 2021-12-08 10:57:00 +00:00
lightningterror
125b9ea1e1 GS-hw: Purge SoTC crc hack.
No longer needed, fixed by #5110
2021-12-08 11:48:29 +01:00
lightningterror
e6b1e1948e GS-d3d11: Add a condition to not enable blend_mix if sw blending is already enabled.
Not yet needed but will be useful for sw blending when prims don't overlap.
2021-12-08 11:36:22 +01:00
lightningterror
ba1072f470 GS-ogl: Don't enable blend_mix if sw blend is already enabled.
Less accurate.
2021-12-08 11:36:22 +01:00
lightningterror
1fb29de082 GS-ogl: Try to use a mix of hw/sw blending in more situations.
When alpha is less than 128:
Do Cs*F or Cs*As in shader.
Do Cs*(As + 1) or Cs*(F + 1) in shader.
Do Cs*(1 - As) or Cs*(1 - F) in shader.

Optimization, might be faster as we will require less barriers.
2021-12-08 11:36:22 +01:00
lightningterror
f79e5ab559 GS-d3d11: Try to use a mix of hw/sw blending in more situations.
When alpha is less than 128:
Do Cs*F or Cs*As in shader.
Do Cs*(As + 1) or Cs*(F + 1) in shader.
Do Cs*(1 - As) or Cs*(1 - F) in shader.
2021-12-08 11:36:22 +01:00
Mrlinkwii
c3a9fd469e GameDB: add VU clamping to 'MVP Baseball 2003' 2021-12-08 10:29:05 +00:00
Mrlinkwii
c8abc909fa GameDB:add EEclamping full to 'Shinobido Takumi' 2021-12-07 20:00:15 +00:00
Mrlinkwii
401a9f4c62 GameDB: add patches to the 'K-1 World' series games and EE clamping full to 'D1 Professional Drift Grand Prix Series' 2021-12-07 15:51:13 +00:00
lightningterror
f1edb0c960 GS-ogl: Disable accumulation blend on PABE.
Requires accurate sw blending.
2021-12-07 10:12:58 +01:00
lightningterror
d73335e4d3 GS-d3d11: Don't enable PABE on accumulation blend.
Requires full sw blending.
2021-12-07 10:11:02 +01:00
TellowKrinkle
7a554be7a7 GS: Fix compiler warning and possible memory leak on exception 2021-12-06 05:44:16 +01:00
TellowKrinkle
31b6ff6046 GS: Use static_assert over assert where possible 2021-12-06 05:44:16 +01:00
lightningterror
38ab0630e6 GS-ogl: Update SetupCBMisc buffer only when GXBY channel is used, and cleanup some variables.
Optimization.
2021-12-06 03:15:48 +01:00
lightningterror
b5fa9deb30 GS-d3d11: Update ChannelShuffle buffer only when GXBY channel is used, and cleanup some variables.
Optimization.
2021-12-06 03:15:48 +01:00
lightningterror
4e8bae1703 GS-ogl: Sample depth on green channel. 2021-12-06 03:15:48 +01:00
lightningterror
464ce1c3cd GS-d3d11: Sample depth on green channel. 2021-12-06 03:15:48 +01:00
lightningterror
bb55c320c1 GS Debugger: Fix Length of dump. 2021-12-05 10:57:24 +01:00
TheLastRar
af585bffa9 DEV9: Add DEV9: prefix to "Can't open Device" log message 2021-12-05 03:53:33 +01:00
TheLastRar
bde4868b67 DEV9: Enable pcap non-blocking 2021-12-05 03:53:33 +01:00
TheLastRar
3835fc5ad1 DEV9: Don't shadow return value of GetAdaptersAddresses 2021-12-04 06:09:01 +01:00
Tyler Wilding
7b815b5f07 actions: increase linux build times as well until cache is reliable
We can rely on the cache more once the following issue is resolved - https://github.com/actions/cache/issues/342#issuecomment-673371329

Once we can, we should be able to dynamically set the timeout according to the cache-hit/miss
2021-12-04 06:05:38 +01:00
Tyler Wilding
754c6126b1 actions: Only announce pre-release releases in the discord 2021-12-04 05:57:05 +01:00
Mrlinkwii
2dc2a32e45 GameDB: add 'VUKickstartHack' to 'Crash Twinsanity' 2021-12-04 02:56:22 +00:00
lightningterror
7a579303b9 GS-d3d11:fx: Split color clamp/wrap in it's own function.
Use the function for both sw blending and dithering, less code duplication.
2021-12-03 19:59:29 +01:00
lightningterror
03401e377b GS-ogl:glsl: Split color clamp/wrap in it's own function.
Use the function for both sw blending and dithering, less code duplication.
2021-12-03 19:59:29 +01:00
Ziemas
ff4ec6d843 SPU: Change dummy SP check for consistency 2021-12-03 19:37:19 +01:00
Ziemas
0dc3dcd9ed SPU: Start the sample pointer at -1
This makes videos in Stolen work again.
2021-12-03 19:37:19 +01:00
Ziemas
ed3237f808 SPU: Use hex values for sample pointer 2021-12-03 19:37:19 +01:00
Tyler Wilding
9321c3c334 gh: remove 32-bit Windows 11, it doesn't exist 2021-12-03 19:24:05 +01:00
Tyler Wilding
adc7d41183 gh: add minimal issue template for issues that don't pertain to games
A lot of the required information we enforce is not applicable to application level bugs
2021-12-03 19:24:05 +01:00
Tyler Wilding
4ca69d8818 gh: Update issue-templates to include Win11 2021-12-03 19:24:05 +01:00
Mrlinkwii
cca52e271b Gamedb: add 'VIFFIFOHack' to 'Men in Black II: Alien Escape' 2021-12-02 19:29:28 +00:00
TellowKrinkle
a2e15bbc87 GHActions:macos: Install glib
Looks like GHActions changed what things they preinstall
2021-12-02 15:08:18 +01:00
Mrlinkwii
9d6ad0303c GameDB: Add fixes for 'Shadow Man - 2econd Coming' and 'Ghosthunter' games. 2021-12-02 14:01:47 +00:00
Mrlinkwii
bbaa23c22d Readme : update links 2021-12-01 22:43:36 +00:00
Ziemas
bacb860cc1 GUI: Allow relative elf file paths on command line. (#4451) 2021-11-30 10:06:17 +01:00
Ziemas
7a4191e16d Fix compilation with LTO on GCC 2021-11-30 02:25:06 +00:00
PCSX2 Bot
0fa620e3ba pad-linux: Update to latest controller database. 2021-11-29 17:17:26 +01:00
dependabot[bot]
96642d8bc3 Bump mathieudutour/github-tag-action from 5.6 to 6.0
Bumps [mathieudutour/github-tag-action](https://github.com/mathieudutour/github-tag-action) from 5.6 to 6.0.
- [Release notes](https://github.com/mathieudutour/github-tag-action/releases)
- [Commits](https://github.com/mathieudutour/github-tag-action/compare/v5.6...v6.0)

---
updated-dependencies:
- dependency-name: mathieudutour/github-tag-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-29 16:01:55 +01:00
dependabot[bot]
8a26c3783a Bump actions/cache from 2.1.6 to 2.1.7
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.6 to 2.1.7.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.6...v2.1.7)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-29 13:21:27 +00:00
lightningterror
d2742a177c GS-d3d11: Properly set afix in EmulateBlending.
Accumulation blend -> afix is already handled in shader, no need to set it for hw blending too.
SW blending -> done in shader.
HW blending - > set only when it is actually used, Alpha C.

GS-d3d11: Properly set afix in EmulateBlending.

Accumulation blend -> afix is already handled in shader, no need to set it for hw blending too.
SW blending -> done in shader.
HW blending - > set only when it is actually used, Alpha C.
2021-11-26 21:25:16 +01:00
TellowKrinkle
6d4713e069 GS: Alloc sw renderer things on custom heap 2021-11-26 13:44:07 -06:00
TellowKrinkle
342170b077 GS: Add new heap for SW renderer allocations 2021-11-26 13:44:07 -06:00
TellowKrinkle
df02d784d6 GS: Throw from vmalloc on failure 2021-11-26 13:44:07 -06:00
tellowkrinkle
340874996e CMake: Always default CMAKE_BUILD_PO off
Git files getting modified by build is just as much of a pain in release builds as it is in devel builds
2021-11-26 13:02:25 -06:00
lightningterror
3bd89154d3 GS-wx: Fix some gui interaction.
Fix interaction of Anisotropic filtering with Nearest Texture Filtering and GPU Palette Conversion.
Fix interaction of Trilinear Filtering with selected renderer.

Options should gray out properly now.
2021-11-26 18:32:58 +00:00
Connor McLaughlin
1e198fbb83 GS/OpenGL: Use CreateRenderTarget() for temp HDR target
Probably won't change much, except maybe with sparse textures,
where it'll use less video memory.
2021-11-25 23:26:31 +01:00
TellowKrinkle
01855fc66a GHActions: Don't shallow clone submodules
Shallow clones tend to be 5-10s slower
2021-11-24 15:43:56 -06:00
refractionpcsx2
7ac045b5e2 GS: Partial revert of #5061 2021-11-24 01:01:55 +00:00
lightningterror
03f1617ff5 GS-GSState: Mask out AA1 on triangles.
AA1 is not supported on hw renderers so ignore flushing the prims on triangles.

Should provide a nice speed boost on games that use AA1 on triangle prims.
2021-11-24 00:14:03 +01:00
lightningterror
c75b20e37d GS-hw: Also disable Blending when AA1 and ABE or PABE are both set on lines.
There's no need to blend them since there is no implementation.
2021-11-24 00:14:03 +01:00
lightningterror
08f72596d4 GS-hw: EmulateBlending move early return to the top.
Optimization.
2021-11-24 00:14:03 +01:00
lightningterror
dcd1f90ae7 GS-hw: Disable Z writes on AA1 flag when prim are lines.
When AA1 flag is enabled Z is not written on lines since coverage is always less than 0x80.
2021-11-24 00:14:03 +01:00
lightningterror
c10603d161 GS-hw: Disable alpha blending when only AA1 flag is enabled.
There is no hw implementation of AA1.

Alpha blending shouldn't be enabled by AA1 flag, only ABE and PABE flags.
2021-11-24 00:14:03 +01:00
Mrlinkwii
7ea335e59b GameDB : fix Fuuraiki 2 patch 2021-11-23 11:55:23 +00:00
lightningterror
d20cb91d90 Gs-d3d11:fx: Adjust sw blend shader a bit.
Use As and Cs in pabe code, makes more sense.

Get rid of Cv vector, use Color parameter for operations instead like on gl.
2021-11-23 09:02:54 +01:00
lightningterror
e38d754e86 Gs-ogl:glsl: Adjust sw blend shader a bit.
Get rid of Color_pabe vector, makes more sense to use As and Cs in pabe code.
2021-11-23 09:02:54 +01:00
refractionpcsx2
afacc47f33 CDVD: Adjust DMA timing based on PS1 timings.
Bus width is 16bit on the PS2 and 8bit on PS1, so serves to reason the DMA would be twice the speed. (PS1 is 24 cycle per word)
2021-11-22 22:18:32 +00:00
refractionpcsx2
5803cc441e GS: Improve FixedTEX0 accuracy 2021-11-22 22:17:59 +00:00
Mrlinkwii
d60c66deee GameDB: purge patches for 'Knockout Kings 2002' 2021-11-22 21:42:26 +00:00
PCSX2 Bot
d7797a50f5 pad-linux: Update to latest controller database. 2021-11-22 20:55:52 +01:00
Mrlinkwii
87bbebed36 Gamedb: remove the patch for Virtua Fighter 4 2021-11-22 17:51:51 +00:00
Mrlinkwii
3aa33bf0b1 Gamedb :add 'GIFFIFOHack' to 'FIFA 2005'and EE clamping for 'D1 Professional Drift Grand Prix Series 2005' 2021-11-22 15:41:25 +00:00
Christian Kenny
e37afd6976 3rdparty: Upgrade soundtouch lib to 2.3.1 2021-11-22 15:38:03 +00:00
Christian Kenny
791f2a63ac 3rdparty: Upgrade xbyak to 6.00 2021-11-22 15:37:44 +00:00
refractionpcsx2
1917f2b98a GS: Re-remove part of Clamp Repeat opt.
This is kind of not needed, it's handled above really.
2021-11-22 10:35:19 +00:00
Connor McLaughlin
78b74f1115 GLLoader: Remove glCopyTextureSubImage2D() wrapper
Not needed anymore.
2021-11-22 05:53:44 +01:00
Connor McLaughlin
8ea24d9ff9 GS/OpenGL: Use shader+draw for CopyRectConv 2021-11-22 05:53:44 +01:00
Ty Lamontagne
f36d5fdbdf Debugger: Format search hits with proper specifier 2021-11-21 22:00:49 +01:00
RedDevilus
d421fc6e6f GUI: Bring back F6 string (Aspect Ratio)
Fixes regression from https://github.com/PCSX2/pcsx2/pull/4140
2021-11-21 20:28:23 +00:00
refractionpcsx2
90c4c9e96b Build: Fix clang
Stupid thing, the actions builds were fine!
2021-11-21 18:43:37 +00:00
refractionpcsx2
0a79892923 microVU: Preserve XGKIck cycles in delay slot
Also added handling for xgkick sync on single instructions
2021-11-21 17:18:34 +00:00
refractionpcsx2
d88f638fbc GS: Redo the Texture min/max opt 2021-11-21 17:18:11 +00:00
Christian Kenny
d29121a871 Core: Reset game loaded/started variables on recompiler shutdown. 2021-11-21 03:25:37 +00:00
Christian Kenny
5b8e983478 ELFHeader: Detect CRC properly for PSX games, improve formatting of game serial output. 2021-11-21 03:25:37 +00:00
Christian Kenny
24d47cb10b Don't update saveslot info if VM isn't running yet 2021-11-21 03:25:37 +00:00
Christian Kenny
ae7b84a85f Savestates: Use folders for organizing savestates per game. 2021-11-21 03:25:37 +00:00
Mrlinkwii
161240045f Gamedb: add various fixes for various games and removal of patches 2021-11-21 03:03:21 +00:00
refractionpcsx2
fe85fc9d25 GIF: Modify fifo read behaviour
Fixes some glitching in Need for Speed Underground 2
2021-11-21 03:01:03 +00:00
arcum42
b8a2cd1b06 PAD: Call one joint pad header in most of pcsx2, not two. (#4985)
Add Gamepad.h

Cleanup.

Remove the Windows version of PAD.h as well.

Update CMakeLists.txt

Revert language changes.
2021-11-20 18:57:58 -08:00
refractionpcsx2
eee51828cb Build: Remove old unused cheatscpp.h file 2021-11-21 00:22:34 +00:00
refractionpcsx2
1eddd9017b 3rd Party: Update rogue file to correct license.
Got missed in an update as they switched to auto generation, but the license was switched prior to us last updating the library. See this commit: 819c6a8d68 (diff-dcf9d0451a6397210424fc9699e209255660a4d3b3072c2f1b35048df8df4092)
2021-11-20 23:33:48 +00:00
tellowkrinkle
9c0582a103 wx: Fix pxExplore on macOS (#4989)
* wx: Fix `pxExplore` on macOS

Trying to open file urls in a browser does not actually launch a file explorer in macOS

* wx: Remove pxExplore/pxLaunch

Was barely used
2021-11-19 18:35:50 -08:00
arcum42
6cd8b34abb Update the FAQ, as well as some general cleanup. (#5033)
* Update the FAQ, as well as some general cleanup.

* A few more adjustments.

* Change indentation.

* Minor changes.

* Remove the information about the time, which was incorrect.

* Life is like a hurricane...

* Modify Windows controller information.

* Add more ways to contribute.
2021-11-19 16:22:44 -08:00
Ty Lamontagne
47075bec49 Debugger: Make memory dialog transparent
Was supposed to do this in my initial memory search pr but ended up removing while fighting with git accidentally.
2021-11-19 00:53:05 +00:00
lightningterror
8eb6cbd400 GS-gui: Change blending option from None to Minimum.
None doesn't actually fully disable sw blending, so the option is a bit inaccurate, rename it to Minimum instead.

Also slightly update tooltip.
2021-11-17 22:44:51 +01:00
TellowKrinkle
8f394b5c3f GHActions:macos: Remove gtk3 dependency 2021-11-17 14:23:15 -06:00
TellowKrinkle
2245315b60 CMake: Remove gtk dep on macOS
We only need gio now
2021-11-17 14:23:15 -06:00
Connor McLaughlin
0d40661b33 VSProps: Set MultiProcessorCompilation in CodeGen props 2021-11-16 10:08:20 +00:00
refractionpcsx2
e015b91ed1 CDVD: Don't allow DMA read if DMA isn't running 2021-11-16 09:31:34 +00:00
PCSX2 Bot
de577709d9 pad-linux: Update to latest controller database. 2021-11-15 17:19:19 +01:00
refractionpcsx2
52c6d79975 VS: Organise filter confusion between GS and GIF files 2021-11-14 21:57:33 +00:00
refractionpcsx2
512064f1b5 GS: Only reload Auto MIPs on TEX base change 2021-11-14 21:57:33 +00:00
Ty Lamontagne
a396b50610 Debugger: Allow access to all of 0xBXXXXXXX 2021-11-14 20:19:33 +00:00
TellowKrinkle
67299fcd9f Core: Remove __packed macro 2021-11-14 13:52:20 -06:00
TellowKrinkle
f7476dfb63 Core: Replace alignment macros with alignas 2021-11-14 13:52:20 -06:00
TellowKrinkle
87f7672dbf GS: Remove windows includes from GS.h 2021-11-14 13:52:20 -06:00
TellowKrinkle
648a958290 GS: Split GS.h into multiple smaller headers 2021-11-14 13:52:20 -06:00
TellowKrinkle
ed90e2fcf9 GS: Header cleanup 2021-11-14 13:52:20 -06:00
TellowKrinkle
b74be70ffc GS: Switch integer typedefs to match rest of pcsx2
Had to capitalize the names of some struct params that had the same names
2021-11-14 13:52:20 -06:00
TellowKrinkle
2351431d71 Misc: Remove custom countof macros in favor of std::size 2021-11-14 13:52:20 -06:00
TellowKrinkle
7435f76609 Misc: Move GS preprocessor defs to main PCSX2 file 2021-11-14 13:52:20 -06:00
TellowKrinkle
d2c1a4a7fb Core: Add header for PCSX2-specific preprocessor definitions 2021-11-14 13:52:20 -06:00
TellowKrinkle
e37fbfddc3 Misc: Better GCC defs
Less warnings about fastcall being unsupported, proper __assume implementation
2021-11-14 13:52:20 -06:00
TellowKrinkle
8ab884a89e Misc: Format Pcsx2Defs.h 2021-11-14 13:52:20 -06:00
Mrlinkwii
42f438146c GameDB: add ee-rounding and vu-rounding to various entries 2021-11-14 16:31:25 +00:00
TellowKrinkle
08b1b350db wx: Remove wxString implicit conversion to std::string on windows
Can be lossy, and no one likes a lossy implicit conversion
2021-11-13 18:44:26 -06:00
TellowKrinkle
cbcd9b5004 wx: Remove wxString implicit constructor from std::string
On windows, it uses the current system's character encoding instead of utf-8, which breaks a lot of things.  We should avoid it.
2021-11-13 18:44:26 -06:00
TellowKrinkle
162a0bbe46 CMake: Fix duplicate definition of WavFile on Windows 2021-11-13 18:44:26 -06:00
refractionpcsx2
69d50e583e GameDB: Patches for MX Vs ATV Unleashed SPS 2021-11-13 18:51:11 +00:00
orbea
40a8384087 Update libchdr
Fixes https://github.com/PCSX2/pcsx2/issues/5009
2021-11-13 01:11:37 +00:00
lightningterror
6053b2b5c9 GS-wx: Adjust some checkboxes to be in alphabetical order. 2021-11-12 20:32:18 +01:00
TellowKrinkle
7e17497c1e GS: Require hardware renderer for hacks in wx config 2021-11-12 20:15:07 +01:00
TellowKrinkle
b573be918e wx:GS: Grow notebook with GS settings pane 2021-11-12 20:15:07 +01:00
TellowKrinkle
2fada14a65 GS: Fix Half Pixel Offset and Half Screen Fix config swap 2021-11-12 20:15:07 +01:00
TellowKrinkle
cf64a2bc8e GS: Rename accurate date config option 2021-11-11 18:18:28 -06:00
TellowKrinkle
39fd3479b7 Core: Add dev mode config 2021-11-11 18:18:28 -06:00
TellowKrinkle
536133289f wx:GS: Pad all the things 2021-11-11 18:18:28 -06:00
TellowKrinkle
3f280649a9 GS: Make spinners full width in wx config
Lines up nicer with other elements
2021-11-11 18:18:28 -06:00
TellowKrinkle
6c80aa8c98 GS: Add D3D11 blend mode selector to wx config 2021-11-11 18:18:28 -06:00
TellowKrinkle
65c39f600f GS: Renderer and upscale prerequisites for wx config 2021-11-11 18:18:28 -06:00
TellowKrinkle
3b5a9f6c6a GS: More generic prerequisite checking for wx config 2021-11-11 18:18:28 -06:00
TellowKrinkle
665db4bdad wx: Stop tripping wx3.1+ asserts in gs config 2021-11-11 18:18:28 -06:00
TellowKrinkle
b34e7fa303 GS: Add X and Y labels to wx settings texture offset 2021-11-11 18:18:28 -06:00
kojin
abc0458d4f GS: remove image header from wx settings dialog 2021-11-11 18:18:28 -06:00
kojin
1e35398a84 GS: new wx config dialog working on windows 2021-11-11 18:18:28 -06:00
kojin
be3253bf87 d3d: abstract some dxgi functionality
- adapters are now referenced by index instead of string matching, hopefully this will make a few things easier
- add a setting to enable dxgi/device debugging (instead of hiding it behind a compiler macro)
- improve logging
- remove some d3d cruft from gsutils
2021-11-11 18:18:28 -06:00
arcum42
241a762d04 GS: Switch to wx config dialog 2021-11-11 18:18:28 -06:00
TellowKrinkle
b944687191 GS: Clean up wx config code 2021-11-11 18:18:28 -06:00
arcum42
736c66ee31 GS: Add tooltips to the wx settings dialog 2021-11-11 18:18:28 -06:00
arcum42
d96f31d01b GS: Add new wx version of GS settings dialog 2021-11-11 18:18:28 -06:00
Mrlinkwii
e30c096d87 GameDB:add 'GIFFIFOHack' to 'Gunfighter 2 - Legend of Jesse James' 2021-11-11 09:15:35 +00:00
Ty Lamontagne
be71b98c55 Debugger: Update enums and fix 32 bit support
Also move bitcast to a proper location
2021-11-11 00:41:40 +00:00
Ty Lamontagne
6bec3162f6 Debugger: Use bit_cast where needed, cleanup some stuff 2021-11-11 00:41:40 +00:00
Ty Lamontagne
c863876dee Debugger: Implement CtrlMemorySearch 2021-11-11 00:41:40 +00:00
TellowKrinkle
f5d0542f06 DEV9-GUI: Rearrange config interface
Fixes HDD Size ticks from 1 to 10 (40,50,60,...) and less squished together.
2021-11-11 00:40:23 +00:00
RedDevilus
b1650eb503 PCSX2-GUI: Fix Groupboxes to align correctly
Make things look more symmetrical and structured.
Affects Audio Settings (SPU2) , Gamepad Settings (PAD) + Network and HDD Settings (DEV9).
For audio settings the slider will no longer do 0.5 steps when you change from TimeStretch. Reduce max audio latency from 750 to 200 (less is better if your PC can handle it).
Windows SPU2 codebase is in dire need of a rehaul on how it handles this behaviour (not convert it multiple times).
2021-11-11 00:40:23 +00:00
Mrlinkwii
82b090e234 GameDB: add nearest rounding to 'Hitman - Contracts' and various fixes 2021-11-10 14:14:52 +00:00
lightningterror
7f1e416d31 GS-ogl: Remove device, driver checks in GLLoader.
Duplicate, it is already handled elsewhere.

Also cleanup some stuff.
2021-11-10 02:27:18 +01:00
Ty Lamontagne
4312bf711c Debugger: Fix breakpoint window on linux 2021-11-09 18:07:46 +01:00
Ty Lamontagne
f8061448d1 Debugger: Reset breakpoint skip on savestate load 2021-11-09 18:06:54 +01:00
PCSX2 Bot
e934bec4b7 pad-linux: Update to latest controller database. 2021-11-08 17:27:08 +01:00
TellowKrinkle
4e5d7ba8ef GS:SW: Fix fog on x64 avx2 2021-11-08 09:19:05 +00:00
TellowKrinkle
59fd815c3d GS: Faster GSOffset::PAHelper 2021-11-07 03:44:31 +00:00
TellowKrinkle
b901c6af71 GS: Switch back to row+column for pixel lookups
Code for the full calculation was way too complicated to run for every pixel in a loop
2021-11-07 03:44:31 +00:00
TellowKrinkle
b2fb6c7804 GS: Don't calculate a pageOffset per bp 2021-11-07 03:44:31 +00:00
TellowKrinkle
84c5f8f738 GS: Remove rowOffset 2021-11-07 03:44:31 +00:00
TellowKrinkle
39c7f11b98 GS: Pixel loop optimizations 2021-11-07 03:44:31 +00:00
TellowKrinkle
86a2d73931 GS: Clean up old GSOffset remnants 2021-11-07 03:44:31 +00:00
TellowKrinkle
8eb50c3517 GS: Switch to new non-cached GSOffset 2021-11-07 03:44:31 +00:00
TellowKrinkle
d9defb19f9 GS: Add new GSOffset class 2021-11-07 03:44:31 +00:00
TellowKrinkle
874804bcfd GS: Add block/page loop functions to GSSwizzleInfo 2021-11-07 03:44:31 +00:00
TellowKrinkle
b0f9662811 GS: Add srav and blend backwards compat to GSVector4i 2021-11-07 03:44:31 +00:00
TellowKrinkle
24850823a2 GS: Use new swizzle calculation class 2021-11-07 03:44:31 +00:00
TellowKrinkle
951604475b GS: Add class for swizzle calculations 2021-11-07 03:44:31 +00:00
Ty Lamontagne
74f3bb2aa9 Debugger: Make the register list DPI aware 2021-11-07 03:43:55 +00:00
Tyler Wilding
4442b798c9 CDVD: set the correct RTC year when input recording 2021-11-07 02:21:01 +00:00
Tyler Wilding
f10a8de2c1 input-rec: Use a constant RTC for power-on recordings 2021-11-06 16:24:53 +00:00
Tokman5
329b29269b GameDB: Add and fix Power Pros series 2021-11-06 16:23:02 +00:00
Mrlinkwii
5b3ffe6bab GameDB: add EE clamping to 'Shadow of Zorro' and 'Evil Twin - Cyprien's Chronicles'
GameDB: add EE clamping to 'Shadow of Zorro' and 'Evil Twin - Cyprien's Chronicles'
2021-11-06 16:20:04 +00:00
Joey
fb14500b41 pad-linux: Abort 'set all btns' on escape key + gui fixes (#4809) 2021-11-06 00:44:08 -07:00
TellowKrinkle
ad29594d08 Use correct clock for GS fps calculations on unix 2021-11-05 23:11:53 -05:00
tellowkrinkle
37e2142cca Common: Fix Darwin thread times
Percentages will now actually be percentages instead of permille (units of 1/1000)
Was caused by trying to match Windows's returns of 100ns units, but then reporting 1µs units from `GetThreadTicksPerSecond()`
2021-11-05 23:11:53 -05:00
tellowkrinkle
1e5f1de12c CMake: Increase deployment target to 10.13
Allows use of throwing `optional` and `variant` methods
2021-11-05 23:11:53 -05:00
tellowkrinkle
0f93dbcd5e USB: Make save state non-required
Fixes save state loading for systems using a null USB plugin (macOS, BSD)
2021-11-05 23:11:53 -05:00
RedDevilus
e415d85dbe GameDB: Add and fix SingStar Entries
I noticed we had a ton of missing SingStar serial + minor other fixes.
2021-11-05 15:59:29 +00:00
Mrlinkwii
4c8bf53e69 CI:Add build date to program log of nightly builds 2021-11-05 01:16:08 +00:00
refractionpcsx2
83fcd4bd1f SPU: Kind of revert last ADMA change. Clear as reading.
This is a temporary measure while we run some hardware tests, the previous change broke Burnout 3's engine sounds.
2021-11-04 20:13:18 +00:00
TellowKrinkle
bfd960ad1b GHActions:Linux: Upgrade to Clang 9 2021-11-04 20:11:15 +00:00
qurious-pixel
6b81808ecc gcc compatibility for older distros
Add compatibility layer for using newer gcc on older distros.
- use AppImageKit-checkrt
- copy build system stdc++ and gcc_s
2021-11-04 20:11:15 +00:00
TellowKrinkle
c615a6f6e2 GHActions:Linux: Upgrade to GCC 10 2021-11-04 20:11:15 +00:00
TellowKrinkle
40b522b42f GHActions:Linux: Remove unneccessary packages 2021-11-04 20:11:15 +00:00
TellowKrinkle
f2655b763f GHActions:Linux: Clean up setup scripts 2021-11-04 20:11:15 +00:00
TellowKrinkle
fd145e65aa GS: Remove virtual destructor from GSAlignedClass
No point, and made it not a standard layout type
2021-11-04 19:32:27 +00:00
TellowKrinkle
6596b7f27e GS: Enable AVX2 on x64 2021-11-04 19:32:27 +00:00
TellowKrinkle
9d767838d6 GS: Remove old DrawScanline code generators 2021-11-04 19:32:27 +00:00
TellowKrinkle
f55219bb1b GS: Replace 6 DrawScanline code generators with one merged one 2021-11-04 19:32:27 +00:00
TellowKrinkle
805b647c73 GS: Remove old SetupPrim code generators 2021-11-04 19:32:27 +00:00
TellowKrinkle
fd0351ca8f GS: Replace 6 SetupPrim code generators with one merged one 2021-11-04 19:32:27 +00:00
TellowKrinkle
ed5a7802f3 Common: Add non-constant offsetof macro 2021-11-04 19:32:27 +00:00
TellowKrinkle
44f8317b7e GS: Add new code generator for easy native-isa codegen 2021-11-04 19:32:27 +00:00
TellowKrinkle
0200933ddd GS: Don't catch code generation exceptions
If codegen throws an exception, it ends up just crashing when you jump to the incompletely-generated code which is kind of useless
2021-11-04 19:32:27 +00:00
lightningterror
f712b2b63a GSDeviceOGL: Fix Wunused-private-field warnings. 2021-11-04 11:18:26 +01:00
Tyler Wilding
71923e7cba actions: cleanup discord embed links and add release body 2021-11-03 23:46:45 +00:00
refractionpcsx2
532d14611c GS: Properly loop when reading 32bit CLUT from offset 2021-11-03 18:24:57 +00:00
refractionpcsx2
3a91a07d51 GS: Fix up CLUT offset handling in 32bit I8 mode 2021-11-03 18:24:57 +00:00
refractionpcsx2
6a8287ea9f EE JIT: Backup shift on LDR/L if rs==rt 2021-11-03 18:03:09 +00:00
Tyler Wilding
dc051541bd actions: create automatic controller db updating workflow 2021-11-03 16:40:36 +01:00
lightningterror
3265c2a614 GS-ogl: Put GL_ARB_get_texture_sub_image code under a define.
Code is currently disabled, no need to check for the extension.
2021-11-03 16:37:55 +01:00
lightningterror
f798401e93 GS-ogl: Remove checks for extensions we don't yet use.
They serve no purpose, no need to check unless we actually use them

GL_ARB_compute_shader,
GL_ARB_shader_storage_buffer_object,
GL_ARB_texture_view,
GL_ARB_vertex_attrib_binding,
GL_ARB_multi_bind
2021-11-03 16:37:55 +01:00
tellowkrinkle
60791e4c2b GS-OGL: Add comment on m_accurate_stq usage 2021-11-03 01:21:11 +00:00
TellowKrinkle
bd8fcc8f81 GS: Remove inaccurate stq calculations from GSVertexTrace
They were the same speed or slower than full div on IvyBridge+ and Bulldozer+
2021-11-03 01:21:11 +00:00
TellowKrinkle
5d33165fa5 GS: Reduce repeated code in GSVertexTrace::FindMinMax
Why repeat things when you can make the compiler repeat them for you
2021-11-03 01:21:11 +00:00
TellowKrinkle
2e1d147135 GS: Faster accurate_stq calculations 2021-11-03 01:21:11 +00:00
refractionpcsx2
ee8d24a260 GS: Don't propagate 24bit textures on download 2021-11-03 00:54:29 +00:00
RedDevilus
81ac26c33c GameDB: Clean-up V2
Some minor typo clean-up and fix japanese serials.
2021-11-03 00:54:06 +00:00
Tyler Wilding
0a9cc924a4 actions: only run these new workflows and new steps on PCSX2/pcsx2 2021-11-01 20:07:31 -05:00
Tyler Wilding
86e12c9603 cmake: properly set the new tag variable 2021-11-01 20:07:31 -05:00
Tyler Wilding
79e56f21d1 actions: lint yaml replace semver with just version 2021-11-01 20:07:31 -05:00
Tyler Wilding
f9e4bb5288 actions-win: Remove remaining retention override 2021-11-01 20:07:31 -05:00
Tyler Wilding
d1085a40ba actions-docs: Add documentation for how this works 2021-11-01 20:07:31 -05:00
Tyler Wilding
c0f83524a9 actions-linux: Update linux workflow to upload artifacts to release 2021-11-01 20:07:31 -05:00
Tyler Wilding
9d2976cef6 actions-win: Update windows workflow to upload to release, also include symbols as an artifact 2021-11-01 20:07:31 -05:00
Tyler Wilding
b20dd73b30 actions: Add brand new workflows - creating and announcing the releases 2021-11-01 20:07:31 -05:00
Tyler Wilding
c32d5f1672 actions: Create script to announce a new release via a Discord WebHooks 2021-11-01 20:07:31 -05:00
Tyler Wilding
6eacade082 actions: Move the temporary location of the AppImages to align with the rest 2021-11-01 20:07:31 -05:00
Tyler Wilding
8baecb9c9c actions: Create script to upload artifacts from workflow and publish release if all are accounted for 2021-11-01 20:07:31 -05:00
Tyler Wilding
b7bdbffad4 actions: Create script for generating release notes 2021-11-01 20:07:31 -05:00
Tyler Wilding
c4e5a21c86 build: If available - use the current git tag for the build metadata 2021-11-01 20:07:31 -05:00
refractionpcsx2
a494e05fd9 CDVD: Left a debug message enabled. 2021-11-01 12:23:31 +00:00
refractionpcsx2
b5eed53db0 CDVD: Fix rotational delay, don't apply to seek commands.
Fixes #4955
2021-11-01 12:07:42 +00:00
refractionpcsx2
78881113b9 GS: Further state cleanup + fixes for older dump compatibility 2021-10-31 23:49:39 +00:00
refractionpcsx2
0d946d8083 GS: Let draw happen even if invalid, log invalid draws 2021-10-31 23:48:48 +00:00
lightningterror
2a20119fbb GSRenderer: Fix Wunused-variable warning. 2021-10-31 21:12:14 +01:00
refractionpcsx2
c84e56329f SPU2: Don't read sound input area if ADMA disabled 2021-10-31 02:24:35 +00:00
refractionpcsx2
6348fe7362 CDVD: Fix handling of Dual Layer disc latencies
Fixes #4962
2021-10-30 20:49:03 +01:00
Connor McLaughlin
20ab4dbf20 GL/StreamBuffer: Use partial instead of exact match for NVIDIA
It's "NVIDIA Corporation" on Macs, and on Windows we don't support any
GL3 GPUs anyway.
2021-10-30 16:01:55 +01:00
Connor McLaughlin
c09240de3b GS: Use stream buffer for VS/GS/FS uniforms 2021-10-30 16:01:55 +01:00
Connor McLaughlin
62b40b516c GS: Use stream buffer for vertices/indices 2021-10-30 16:01:55 +01:00
TellowKrinkle
9d2bdd5681 ContextAGL main thread & wx compatibility fixes 2021-10-30 02:00:21 +01:00
Connor McLaughlin
46283cd513 GS: Make Config.h include explicit 2021-10-30 02:00:21 +01:00
Connor McLaughlin
5ba70c8c20 GS: Remove GSWnd and use GL::Context 2021-10-30 02:00:21 +01:00
Connor McLaughlin
198fc2629e Common: Add GL context wrappers 2021-10-30 02:00:21 +01:00
Connor McLaughlin
5848efe03b GS: Migrate to glad 2021-10-30 02:00:21 +01:00
Connor McLaughlin
ca2a75db9c 3rdparty: Add glad 2021-10-30 02:00:21 +01:00
Connor McLaughlin
97474488d8 wx: Call XInitThreads on startup 2021-10-30 02:00:21 +01:00
Connor McLaughlin
0f5ed59e50 Replace pDsp with WindowInfo 2021-10-30 02:00:21 +01:00
Connor McLaughlin
114d78d378 CMake: Add options for building with X11/Wayland 2021-10-30 02:00:21 +01:00
Connor McLaughlin
fadd97c021 Common: Add WindowInfo 2021-10-30 02:00:21 +01:00
Connor McLaughlin
09764393e0 Common: Add align helpers 2021-10-30 02:00:21 +01:00
Connor McLaughlin
de8b4f17a1 Common: Add ScopedGuard 2021-10-30 02:00:21 +01:00
refractionpcsx2
52eab49359 Merge branch 'master' of https://github.com/PCSX2/pcsx2 2021-10-28 20:03:03 +01:00
refractionpcsx2
3ac86a19ff GIF: Time transfers from FIFO correctly.
Will break FIFA Street 2 / FIFA 2005 but they can be fixed with GIF FIFO Gamefix + Cycle Rate + 3
2021-10-28 20:02:35 +01:00
TheLastRar
0dea6dbc9d DEV9: DNS logger crash fix 2021-10-28 19:48:20 +02:00
lightningterror
23283b7f0a pad-linux: Update to latest controller database. 2021-10-27 01:50:27 +02:00
lightningterror
7ac56a0d11 emitter: Fix Wsign-compare warnings. 2021-10-27 01:00:38 +02:00
lightningterror
667f98334a iR5900: Fix Wodr warnings. 2021-10-27 01:00:38 +02:00
lightningterror
6825b5d79a SaveSlots/UpdateUI: Fix Wsign-compare warning. 2021-10-27 01:00:38 +02:00
lightningterror
ac91a48182 PGIF: Fix Wunused-variable warnings. 2021-10-27 01:00:38 +02:00
refractionpcsx2
855b46edee VU: Fix Wsign-compare warnings. 2021-10-27 01:00:38 +02:00
lightningterror
8a531ad2cb VU: Fix Wsequence-point warnings. 2021-10-27 01:00:38 +02:00
lightningterror
5a1dabc293 GS: Fix Wunused-variable warnings. 2021-10-27 01:00:38 +02:00
Ty Lamontagne
3705054095 Debugger: Support multi-line assembling 2021-10-26 15:24:52 +01:00
Ty Lamontagne
0fed1cbedd clang-format: pcsx2/CDVD/CDVD.cpp 2021-10-26 09:56:41 +01:00
Ty Lamontagne
f5a9b98578 CDVD: Reset VM on sceCdPowerOff writes 2021-10-26 09:56:41 +01:00
refractionpcsx2
bfbe86a3d5 COP2: Tighten LQC2/SQC2 sync
Fixes some small glitches with the R&C games
2021-10-26 00:05:46 +01:00
kojin
d70631477d gs: remove unused path3 hack 2021-10-25 20:35:37 +02:00
kojin
936cf5b60d gs: remove unused tex flush param
keep the logging for now
2021-10-25 20:35:37 +02:00
kojin
8095490d23 gs: remove old pre-mtgs cruft 2021-10-25 20:35:37 +02:00
kojin
740b421ce8 gs: gsstate (the old gsdx one) misc cleanup
just some spring cleaning since I'm here anyway.
mostly getting rid of dead code and comments
adding some comments and logging
remove some asserts
making the code a little easier to read

stuff like that
2021-10-25 20:35:37 +02:00
TheLastRar
4273b6ce37 DEV9: Fix Windows config saving/loading 2021-10-25 20:31:39 +02:00
lightningterror
0717353069 Core: Few more warnings fixup. 2021-10-25 20:23:55 +02:00
refractionpcsx2
bb494af6b0 CDVD: Buffer up to 16 sectors 2021-10-25 09:42:00 +01:00
Mrlinkwii
05dfe0b0ac GameDB:add 'VUKickstart' to 'Maken Shao' games (#4935) 2021-10-24 23:40:09 +01:00
TellowKrinkle
b63f6e807c DEV9: Prevent saving invalid configurations 2021-10-22 20:39:44 -05:00
TellowKrinkle
18b982dc6a DEV9: Clean up config code 2021-10-22 20:39:44 -05:00
TellowKrinkle
f5cfd7e6bf DEV9: Split ethernet adapter api config selection into separate dropdown 2021-10-22 20:39:44 -05:00
TellowKrinkle
b16b759adf DEV9: Inline hdd size in config 2021-10-22 20:39:44 -05:00
TellowKrinkle
687e5d41e1 DEV9: Don't use collapsible panes for config 2021-10-22 20:39:44 -05:00
TellowKrinkle
3ba3ac5813 DEV9: Add tap adapters to new config on Windows 2021-10-22 20:39:44 -05:00
TellowKrinkle
b48ae6d519 DEV9: Translatable strings for HddCreate 2021-10-22 20:39:44 -05:00
TellowKrinkle
e068d24920 DEV9: Switch Windows config dialog to wx 2021-10-22 20:39:44 -05:00
TellowKrinkle
85bc4f1027 DEV9: Switch Linux config dialog to wx 2021-10-22 20:39:44 -05:00
Connor McLaughlin
005f8c7d1d Config: Fix zoom/stretch options not updating on Apply 2021-10-21 13:22:31 +02:00
refractionpcsx2
0a72e7474e GameDB: Add gamefixes for Ruff Trigger 2021-10-20 20:18:22 +01:00
refractionpcsx2
7a330340ac GameDB: Port Iridium Runners patch, update fixes 2021-10-20 20:15:46 +01:00
refractionpcsx2
24e73b3134 Savestates: Add missing things from Savestates (#4917)
Savestates: Add missing variables from Savestates
2021-10-20 10:41:50 +01:00
TellowKrinkle
c3e5b4225b GSdx:SW: Prevent thread ping-pong in software renderer sync 2021-10-19 16:04:15 -04:00
TellowKrinkle
85f1acb7b7 MTGS: Don't unlock mutex if you're just going to lock it again
Poor MTVU thread getting trolled by the GS thread.  By the time it wakes up its lock is taken again.  When under contention (GS thread behind the VU thread), this caused the GS thread to waste an additional 8% of its time pointlessly waking the VU thread
2021-10-19 16:04:15 -04:00
TellowKrinkle
881b017606 Utilities: Add TryWait and spin waits to semaphore and mutex 2021-10-19 16:04:15 -04:00
TellowKrinkle
5ff89dd695 Utilities: Add functions for spin waiting 2021-10-19 16:04:15 -04:00
TellowKrinkle
cf02893d22 macOS: faster semaphores
mach semaphore is kernel-only, and doesn't have a userspace fast path
2021-10-19 16:04:15 -04:00
refractionpcsx2
5011b9ead5 EE: Cyclerate > 1 caused some cycles to be lost 2021-10-19 20:09:07 +01:00
refractionpcsx2
6746578120 VU JIT: Include ADDi in flag calculations
Fixes #4916
2021-10-18 12:32:44 +01:00
refractionpcsx2
a85247ff9f GIF: re-re-fix FIFO behaviour
Fixes #4915
2021-10-18 12:14:21 +01:00
refractionpcsx2
c363241fad GS: Partial revert of #4891
Fixes performance problems with Baldur's Gate 2
2021-10-17 16:45:04 +01:00
lightningterror
d875bff471 pad-linux: Update to latest controller database. 2021-10-17 17:15:38 +02:00
Connor McLaughlin
44bc273590 microVU: Use uncached reg when clamping for FMAC instructions 2021-10-17 15:54:58 +01:00
arcum42
9044531a80 Add the current profile to the status bar. (#4888) 2021-10-17 01:19:18 -07:00
TellowKrinkle
f22ba886d9 Fix unparenthesized macro input 2021-10-17 04:17:58 +01:00
Ziemas
3f6ac2fa68 Debugger: Separate EE and IOP symbol maps
Previously they shared a single map which dosen't make sense.
2021-10-17 04:08:35 +01:00
Ziemas
7fd40f094a Debugger: more clang-tidy 2021-10-17 04:08:35 +01:00
Ziemas
f873e3b630 Debugger: Prefer override over virtual 2021-10-17 04:08:35 +01:00
Connor McLaughlin
6da938a714 GS: Get rid of a bunch of warnings in GSDeviceOGL 2021-10-17 03:34:44 +01:00
tellowkrinkle
934a7f70b2 Remove 30-day artifact retention on windows builds
Should revert to default of 90 days
2021-10-16 23:55:24 +01:00
refractionpcsx2
9109751ff0 CDVD: Insert step on swap for Generic Detect before type detect 2021-10-14 23:16:48 +01:00
refractionpcsx2
880107e72b BIOS/FastBoot: If OSDConfig is written, turn off HLE
Fixes #4902
Savestate bump, sorry.
2021-10-14 22:27:02 +01:00
refractionpcsx2
f14c9e7ddd CDVD: Fix tray closure on No Disc 2021-10-14 22:22:37 +01:00
refractionpcsx2
d736c8b281 CDVD: Use CD or DVD detecting types 2021-10-14 21:51:48 +01:00
refractionpcsx2
a96f900760 COP2: Simplify reg allocation 2021-10-14 10:06:13 +01:00
Ziemas
45bb57a38c IOP Recompiler: Fix BIOS trace logging on 64bit 2021-10-13 22:42:51 +02:00
refractionpcsx2
1b31eb9e4a Common: Fix AT&T mixup in FastJmp code 2021-10-12 23:08:13 +01:00
lightningterror
d36043c678 GS Debugger: Show "D3D11 HW" only on windows. 2021-10-12 03:54:35 +02:00
refractionpcsx2
54d10d21ec CDVD: Simulate 1 sector read ahead 2021-10-11 00:16:00 +01:00
Mrlinkwii
4c7a251f6d GUI : remove EE Cycle Skipping 3 2021-10-10 16:52:28 +01:00
lightningterror
e597f68620 pad-linux: Update to latest controller database. 2021-10-10 15:07:26 +02:00
lightningterror
6ed00107cf GS: Revert be7e1163b4
Completely remove the code instead of commenting it out, seems to cause
issues with several games.
2021-10-08 21:56:25 -04:00
kojin
ef2c7ac480 gs-tc: propagate texture shuffle format on readback 2021-10-08 21:43:54 -04:00
lightningterror
575b88ac04 gs: Fix recent clamp range changes.
Arguments were in wrong order by mistake.
Let's pretend that didn't happen.
2021-10-09 02:40:30 +02:00
lightningterror
2e0b8302dd GS-hw: Add Slam Tennis to automatic mipmapping.
Close #4866
2021-10-08 20:57:39 +02:00
lightningterror
a2ba0ae818 gs-d3d11: Fix Shade Boost Contrast and Saturation swapped values. 2021-10-08 13:31:17 +02:00
refractionpcsx2
ae1f1599f6 COP2: Fix reg allocation issue
Really fixes Devil May Cry which was a bug hidden by clamping hidden by a bug, yeah i think that covers it all...
2021-10-07 23:29:04 +01:00
Mrlinkwii
296911bef9 GUI: remove preset 4,5,6 2021-10-07 22:15:00 +01:00
refractionpcsx2
05dc48df07 GameDBL Add VU clamping for Devil May Cry
Also fix a COP2 arrangement issue, not sure what it fixes.

Clamping previously wasn't needed as it was masked by a bug.

Fixes #4884
2021-10-07 20:45:24 +01:00
lightningterror
660c623dd0 pad-linux: Update to latest controller database. 2021-10-05 16:29:14 +02:00
refractionpcsx2
b8f4a8ffb3 CDVD: Added simple rotational latency
Also removed DMA delay
2021-10-05 13:25:12 +01:00
refractionpcsx2
6bed14cb26 CDVD: Time reads by sectors per second instead of bytes 2021-10-05 13:25:12 +01:00
Mrlinkwii
8cad96499d GameDB :add PS2Linux Release 1.0 Runtime Environment [Disc 1] 2021-10-05 13:24:57 +01:00
Connor McLaughlin
0ccad56ee6 Wx: Reinitialize folders after running first time wizard 2021-10-05 11:54:44 +01:00
Connor McLaughlin
d440360906 clang-format Config.h and Pcsx2Config.cpp 2021-10-05 11:54:44 +01:00
Connor McLaughlin
3c522a0e60 Config: Add missing equality comparisons for a few fields
Fixes memory card changes not getting applied.
2021-10-05 11:54:44 +01:00
Connor McLaughlin
00fbc8289d Wx: Fix trace log settings getting very confused 2021-10-05 11:54:44 +01:00
kojin
1f386cf8bd recording: don't use NULL in wxChoice 2021-10-04 03:17:30 -04:00
kojin
86278b75e4 core: fix header includes for bsd 2021-10-04 03:17:30 -04:00
kojin
a94a324423 common: Don't use linux-specific OS description
wxGetLinuxDistributionInfo is linux only
2021-10-04 03:17:30 -04:00
kojin
4df3bee178 common: don't use NULL in SafeSysMunmap
BSD maps NULL to nullptr_t which is a problem because it's not a ptr type
2021-10-04 03:17:30 -04:00
kojin
e04c890018 cmake: freebsd fixup 2021-10-04 03:17:30 -04:00
kojin
e096814697 cmake: fix a bunch of override warnings 2021-10-03 18:27:19 -04:00
refractionpcsx2
a6e188692e Savestate version bump due to CDVD changes 2021-10-03 20:14:55 +01:00
refractionpcsx2
8d92c0668c CDVD: Implement Disc Swapping (#4860)
Inspired by the work by fldef, fixes up swapping support for ISO's and physical discs

CDVD: Set the disk type to none/detecting when seeking.
Also disable the skip BIOS flag if we're not skipping the BIOS
CDVD: Fix up swapping behaviour, Singstar etc
2021-10-03 17:27:15 +01:00
Mrlinkwii
759b869c1c GameDB :add VU clamping to Monster Rancher 3 2021-10-03 17:00:02 +01:00
lightningterror
c59db35ce2 GS: Fix OSD, Shade Boost slider values not showing. 2021-10-03 14:25:44 +02:00
refractionpcsx2
d0d58ded29 CDVD: Redesign and fix the Fast CDVD speedhack
Rather than setting it to a constant cycle count, it just halves all cycle counts being passed to it which aren't full seeks.
2021-10-03 10:49:51 +01:00
Mrlinkwii
65ce152e2c Gamedb :add 'SingStar ABBA' entry 2021-10-03 10:16:21 +01:00
Connor McLaughlin
4fc8a588ed Wx: clang-format AppConfig.cpp 2021-10-03 06:04:00 +01:00
Connor McLaughlin
a585a27d1e Wx: Fix regressions from settings decouple
Wx: Fix GS hotkeys losing values after reboot

Wx: Fix trace log hotkey losing value after reboot

WxSettingsInterface: Fix uint value loads

Wx: Fix presets resetting GS window settings

Common/SettingsWrapper: Fix SettingsWrapBitfield
2021-10-03 06:04:00 +01:00
Connor McLaughlin
1e703286f0 Config: Convert MemoryCardType to an enum class 2021-10-03 04:44:16 +01:00
Connor McLaughlin
d72c476483 Config: Fix folder memory cards initial load 2021-10-03 04:44:16 +01:00
Ty Lamontagne
3fdc32d9d7 Debugger: fix Goto in Disasm option for memory view
Was I drunk?
2021-10-02 22:04:11 +01:00
lightningterror
5e481951ea GS: Cleanup ini ranges for some values.
Use clamp instead of min max for OSD and Shade Boost.
Don't allow negative value for upscale multiplier.
2021-10-02 17:59:39 +02:00
TellowKrinkle
603537719e GS: Switch SW renderer statistics back to rdtsc
GetCPUTicks can be pretty low resolution on some systems
2021-10-02 00:01:19 -04:00
TellowKrinkle
c4e3bd148f GS: SW renderer statistics printout improvements 2021-10-02 00:01:19 -04:00
TellowKrinkle
91f1eca95e GS: Fix prim count in SW renderer debug stats
Previously was actually draw count, not prim count
2021-10-02 00:01:19 -04:00
TellowKrinkle
8123cc27db GS: Improved SW renderer debug stats 2021-10-02 00:01:19 -04:00
TellowKrinkle
e68fa34372 core: Force-include pch on vs
CMake does this by default.  This way we can make non-pch builds not take forever by only including what's required instead of the entire pch
2021-10-01 23:58:27 -04:00
refractionpcsx2
8476fc3b5a CDVD: Implement correct SpindleCtrl handling
Semi decouple end of CDVD DMA's
Fix alternative reading method for reading not picking the correct speeds for DVD's
2021-10-02 04:47:11 +01:00
Connor McLaughlin
a41ec422d2 Config: Move some Current fields to wx and fix UTF8 handling 2021-10-01 23:46:52 -04:00
Connor McLaughlin
ca523edf0e Config: Move folders to their own namespace
Don't duplicate in EmuOptions.
2021-10-01 23:46:52 -04:00
Connor McLaughlin
43dfbe3f29 Move more classes from common to gui 2021-10-01 23:46:52 -04:00
Connor McLaughlin
c1fc018449 Config: Use SettingsInterface for base config 2021-10-01 23:46:52 -04:00
Connor McLaughlin
6fa82da1f1 Common: Add SettingsInterface and SettingsWrapper 2021-10-01 23:46:52 -04:00
Connor McLaughlin
817524bd1c Config: Use std::string instead of wxFileName 2021-10-01 23:46:52 -04:00
Connor McLaughlin
171a395369 Common: Add StringUtil 2021-10-01 23:46:52 -04:00
Connor McLaughlin
4d8905abd6 Config: Swap out wxString for std::string
Also in CDVD.
2021-10-01 23:46:52 -04:00
Connor McLaughlin
d13982ea0e IniInterface: Support std::string entries 2021-10-01 23:46:52 -04:00
Connor McLaughlin
f79f85480b CDVD: Use ANSI variants on Windows for disc access
The drive path is not going to contain unicode characters.
2021-10-01 23:46:52 -04:00
Connor McLaughlin
17c049d7e3 SaveState: Simplify and convert to std::thread 2021-10-01 23:46:52 -04:00
Connor McLaughlin
3fdab1222b Rename keyEvent to HostKeyEvent 2021-10-01 23:46:52 -04:00
Connor McLaughlin
c234f83ca6 SaveState: Move file generation logic out of GUI 2021-10-01 23:46:52 -04:00
Connor McLaughlin
640e955c38 Move MemoryCard{File,Folder} out of GUI 2021-10-01 23:46:52 -04:00
Connor McLaughlin
307feefa87 Config: Move gzip index template to base config 2021-10-01 23:46:52 -04:00
Connor McLaughlin
15365c8702 Config: Remove unused FullBootConfig 2021-10-01 23:46:52 -04:00
Connor McLaughlin
bd9b43b482 Config: Move more GS settings to base class 2021-10-01 23:46:52 -04:00
Connor McLaughlin
77a890ff4a Config: Move Folders/BaseFilenames to base config 2021-10-01 23:46:52 -04:00
Connor McLaughlin
3f265b3f1c Config: Get rid of subset mutators and const global 2021-10-01 23:46:52 -04:00
Connor McLaughlin
4b2a81e7ff Move GetCoreThread()/GetMTGS() to AppCoreThread.cpp 2021-10-01 23:46:52 -04:00
Connor McLaughlin
6b2a865e57 Remove references to global CoreThread (use accessor) 2021-10-01 23:46:52 -04:00
Connor McLaughlin
324a3d09e6 PathUtils: Make wxDirName::{Rmdir,Mkdir} const 2021-10-01 23:46:52 -04:00
Connor McLaughlin
8b44e3d6f6 Config: Move some enums from AppConfig->Config 2021-10-01 23:46:52 -04:00
TellowKrinkle
0cc8d402d6 GHActions: Enable partial LTO 2021-10-01 23:04:42 -04:00
TellowKrinkle
83e9513623 CMake: Add option for partial LTO 2021-10-01 23:04:42 -04:00
TellowKrinkle
7ede817241 CMake: Move PCSX2 compile flags to separate target
Makes it easier to split compilation across multiple targets
2021-10-01 23:04:42 -04:00
kozarovv
a09a6db24d PGIF: Remove force fifo clear on GP1 (00-01)
Clearing GP0 fifo is handled internally in PS1DRV.

This commit additionally remove annoying log from devbuilds.
2021-10-01 22:47:17 -04:00
Connor McLaughlin
2241e635c6 gui: Use uintptr_t for storing numbers in pointers 2021-10-01 22:45:12 -04:00
Connor McLaughlin
dd3db3fc54 GS: Fix a couple of 64 bit warnings 2021-10-01 22:45:12 -04:00
Connor McLaughlin
928bf71d2a tools/bin2cpp: Fix 64-bit warnings 2021-10-01 22:45:12 -04:00
Connor McLaughlin
8e1470f637 iR5900: Use fastjmp instead of longjmp 2021-10-01 23:30:39 +01:00
Connor McLaughlin
91627b28b4 R5900: Get rid of ScopedBools 2021-10-01 23:30:39 +01:00
Connor McLaughlin
4594e02812 Common: Add Fastjmp 2021-10-01 23:30:39 +01:00
refractionpcsx2
2af8cde40d GIF: Correct GIF FIFO timing logic 2021-10-01 22:25:09 +01:00
Connor McLaughlin
97b94acd86 CDVD: Fix possible uncaught exception in CheckDiskTypeFS 2021-10-01 13:26:08 +01:00
lightningterror
e0caacfa6f GS-hw: Don't write clamped depth test value to depth buffer when ZMSK is enabled.
Fixes missing shadows in Kingdom Hearts: Chain of Memories.
2021-10-01 13:25:49 +02:00
Connor McLaughlin
6ff46a795f Common/StringHelpers: Fix printing of 64-bit pointers 2021-10-01 12:10:19 +01:00
Connor McLaughlin
9abaa1adf6 Common/Mutex: Fix compiling without wxUSE_GUI 2021-10-01 10:06:09 +01:00
jackun
42d730c80f USB: dshow: Initialize multi-threaded COM libs 2021-09-30 21:49:56 +02:00
Tokman5
c3c15a95c4 Use GetCheatsFolder() to check the path correctly when non-default folder is set. 2021-09-30 10:00:56 +01:00
lightningterror
384f87b89c locales: Fix '\v' escape sequence warnings. 2021-09-30 02:15:43 +02:00
lightningterror
a25dc9c38c ICore: Cleanup Wsign-compare warnings. 2021-09-30 01:07:59 +02:00
lightningterror
1497e894cf Debugged: Fix Wimplicit-fallthrough warning. 2021-09-30 01:07:59 +02:00
Mrlinkwii
e6728d9d55 Docs : add 'VUOverflowHack' to GameIndex documentation and corrections 2021-09-29 17:41:08 +01:00
refractionpcsx2
c0443e25f9 UI: Reorder the gamefixes panel 2021-09-29 17:33:13 +01:00
refractionpcsx2
7faa5db9e5 VU/GameDB: Move Mac/Status overflow flag checks to a gamefix
We can't really do this reliably on x86 without soft floats, but superman still needs it, but it breaks other games.
2021-09-29 17:33:13 +01:00
lightningterror
d53171e20f ci-mac: Bump macos version to 11. 2021-09-28 20:14:29 -05:00
Mrlinkwii
48eee328b9 UI: Hide Synchronous GS in release builds (#4838)
UI: make ' Synchronized MTGS'  UI settings exclusive to debug/devel
2021-09-28 12:11:12 +01:00
lightningterror
21c6bb6b59 SourceLog: Try to fix Wreorder warnings. 2021-09-26 20:42:12 +02:00
lightningterror
b0932825a9 Debugger: Try to fix Wreorder warnings. 2021-09-26 20:42:12 +02:00
TheLastRar
be9587d520 DEV9: Reuse variable in internal server 2021-09-26 17:56:42 +01:00
TheLastRar
635f411880 DEV9: Add DNS Logging 2021-09-26 17:56:42 +01:00
TheLastRar
24f97fd221 DEV9: Add internal DNS server 2021-09-26 17:56:42 +01:00
TheLastRar
ca3b857f22 DEV9: Rename config struct to avoid conflicting with USB Config struct 2021-09-26 17:56:42 +01:00
TheLastRar
bac0930591 DEV9: Correct namespace for DNS Enums 2021-09-26 17:56:42 +01:00
Ty Lamontagne
1f31edf65c Perf: Fix missing include 2021-09-26 17:26:57 +01:00
TheLastRar
39328c5c66 DEV9: Clang format tap-win32 2021-09-26 17:14:40 +01:00
TheLastRar
26ea5bcfed DEV9: Log when we fail to get adapter information for internal servers 2021-09-26 17:14:40 +01:00
TheLastRar
2d0ad7fb72 DEV9: Add missing flag to GetAdaptersAddresses call in pcap 2021-09-26 17:14:40 +01:00
Ty Lamontagne
cd22a1d00d GS-ogl: Fix regression that broke linux HW mode 2021-09-26 17:05:04 +01:00
Mrlinkwii
485e514409 SPU2:fix Wsign-compare warning
SPU2:fix Wsign-compare warning
2021-09-26 16:47:18 +01:00
Silent
71b2c17e2c SPU2: Refactor SndOut_XAudio2.cpp 2021-09-26 16:06:40 +01:00
Mrlinkwii
954688a38d Docs: improve documentation for Gameindex.md
Docs: improve  documentation  for Gameindex.md
2021-09-26 16:01:12 +01:00
lightningterror
def04c2524 pad-linux: Update to latest controller database. 2021-09-26 14:16:04 +02:00
lightningterror
963f071a70 GS-d3d11: Cleanup GSDevice11 a bit.
Use const if possible, declare and initialize HRESULT at the same time
when possible.
2021-09-26 14:09:43 +02:00
lightningterror
e45aa63a8b GS-ogl: Cleanup GSDeviceOGL a bit.
Use const, constexpr if possible,
Isolate m_debug_gl_file code in debug level only,
shorten some functions and properly initialize variables.
2021-09-26 14:09:43 +02:00
lightningterror
5627d91c17 GS: Cleanup GSDevice a bit, use const when possible. 2021-09-26 14:09:43 +02:00
Ty Lamontagne
aef731fdbe MicroVU: Fix branch type detection
amendment of 589aba
2021-09-26 05:13:28 +01:00
Mrlinkwii
5a9aeb165f GameDB:add 'VUKickstartHack' to SOCOM II entries 2021-09-26 03:20:43 +01:00
Silent
c1fea5bc16 GSTexture11::Save: Preserve the original pointers for a RAII Unmap
Fixes a regression from WIL migration, Unmap was called on
mutated pointers.
2021-09-25 14:32:10 -04:00
Silent
b5f9e14cd3 PortAudio: Uncomment Pa_Terminate
Thanks to the threading changes, proper teardown can now be allowed.
2021-09-25 14:32:10 -04:00
Silent
0ab31a2e9f GSCapture: Fix a premature GSSource release
CUnknown starts with a refcount of 0, so a "nonstandard"
assignment needs to be performed, even though it looks like
a COM reference leak at the first glance.
2021-09-25 14:32:10 -04:00
Silent
4c941f81ec Delegate systems teardown to EE Core when pausing
Fixes issues caused by Cleanup/Init on the Main Thread
instead of the EE Core thread. Now systems are only set up
and torn down on one thread.
2021-09-25 14:32:10 -04:00
Silent
e6e7a55d7e AppCoreThread: Clean up BaseSysExecEvent_ScopedCore usage
Seems like the ScopedCoreThreadPause parameter is legacy
and was only getting in the way of an upcoming change to that event.
2021-09-25 14:32:10 -04:00
refractionpcsx2
f7bcb92d9a VU: Only wait for VU sync after wait macro if VU0 still running
Makes Tekken Tag a good 2-4 FPS faster.
2021-09-25 01:51:19 +01:00
Mrlinkwii
2406ae6e07 GameDB: add EEclamping to the 'Virtual On' series
GameDB: add EEclamping to the 'Virtual On' series
2021-09-24 15:59:21 +01:00
TellowKrinkle
74b08589c4 CMake: Fix up some defines 2021-09-24 00:31:16 -05:00
TellowKrinkle
5435718167 Common: Clean up DarwinMisc 2021-09-23 22:45:37 -05:00
TellowKrinkle
87c56ccfc4 macOS: Fix async file reader error handling
Should fall back to blocking io if aio fails
2021-09-23 22:42:11 -05:00
kojin
1a29a6da1d gs: test for th for tex0 flush
previous code didn't test TH which was a problem for vampire nights because they upload a c16 texture to the same address but with a different height
2021-09-23 16:48:39 -04:00
refractionpcsx2
d73bf834b3 SIF: Kind of revert a SIF timing change made a while back to fix Parappa the Rapper 2 2021-09-23 04:44:34 +01:00
TellowKrinkle
ffbfd2c844 GUI: Check console color support before using it 2021-09-22 15:16:02 -05:00
TellowKrinkle
0f4f09c597 GUI: Enable console to stdio on macOS 2021-09-22 15:16:02 -05:00
refractionpcsx2
f5f44286bf EE: 64bit compare for 64bit mode, not 32bit 2021-09-22 19:57:40 +01:00
TellowKrinkle
65e57a8230 iR5900: Use 64-bit math on x86-64 2021-09-22 12:47:49 +01:00
TellowKrinkle
e74ba82093 iR5900: Move repeated code into functions 2021-09-22 12:47:49 +01:00
TellowKrinkle
b8eb18836f GUI: Remove ineffective alignment specifiers
WX 3.1.5 asserts on these, not fun
2021-09-21 22:04:56 -05:00
TellowKrinkle
66a1c26b77 GUI: Fix crash on asserts from outside of PCSX2 2021-09-21 22:04:56 -05:00
TellowKrinkle
f4010029f1 core: Fix up issues introduced in vtlb xmm change 2021-09-21 21:47:40 -05:00
Silent
cff9f83a45 PortAudio: Remove DirectSound backend 2021-09-21 23:14:39 +01:00
TellowKrinkle
0d7f141279 EERec: Don't load in skip case of SW[LR] 2021-09-21 22:57:41 +01:00
TellowKrinkle
23578e963f EERec: Don't load in skip case of SD[LR] 2021-09-21 22:57:41 +01:00
TellowKrinkle
e9518f78c7 vtlb: Switch read64 and read128 handlers to return in sse regs 2021-09-21 22:57:41 +01:00
TellowKrinkle
7563f54e83 EERec: Clean up [LS]D[LR] a bit 2021-09-21 22:57:41 +01:00
RedDevilus
b7f1c65f7e GameDB: Add missing chinese entries v2
Seems there were still some missing serials, it's pretty hard to track if there are dozen more but it did had a console ban there after short-lived debut.
2021-09-21 22:50:00 +01:00
refractionpcsx2
e127ca0cd1 COP2: Set correct number of XMM's per COP2 OP + Fix some hidden bugs
Corrects XMM count for COP2 ops (some might be wrong, keep an eye out in the logs)
Fixes a hidden microVU bug with a SUB shortcut + some reg allocation bugs in QMFC/QMTC hidden by flushes.
2021-09-21 22:46:33 +01:00
refractionpcsx2
752957604e COP2: Flush only needed register slots 2021-09-21 22:46:33 +01:00
refractionpcsx2
fba9c6c04d COP2: never flush EE regs but back them up conditionally 2021-09-21 22:46:33 +01:00
Mrlinkwii
05b8e80ac8 GameDB: add VU clamping to 'Battle Engine Aquila'
GameDB: add VU clamping to 'Battle Engine Aquila'
2021-09-21 18:32:21 +01:00
Mrlinkwii
5f9653d9ef Gamedb: add EE clamping to 'Max Payne 2 - The Fall of Max Payne'
Gamedb: add EE clamping to 'Max Payne 2 - The Fall of Max Payne'
2021-09-21 18:31:20 +01:00
Joey
d67caab621 Docs: correct CONTRIBUTING.md
fix spelling mistake in CONTRIBUTING.md
2021-09-21 17:59:54 +01:00
Mrlinkwii
5e9fe31f4e GameDB:fix serial for 'Panzer Elite Action - Fields of Glory'
GameDB:fix serial for 'Panzer Elite Action - Fields of Glory'
2021-09-20 21:28:10 +01:00
RedDevilus
55173bf27a GS-GUI: Add tooltip for Dithering
The PS2 and PS1 supported dithering where-as PCSX2 didn't support hardware dithering till 1.7 dev builds. Some games have no dithering, others have dithering in the shadows or others like baroque just smear it full with this affect so it's an extreme example: https://cdn.knightlab.com/libs/juxtapose/latest/embed/index.html?uid=ab92a0e0-f91e-11ea-bf88-a15b6c7adf9a
2021-09-19 21:04:53 +01:00
Ty Lamontagne
252eaa2d62 UI: Select a bios by default 2021-09-19 20:47:28 +01:00
Mrlinkwii
cfdacb900e GameDB: add VU clamping to 'Enthusia Professional Racing'
GameDB: add VU clamping to 'Enthusia Professional Racing'
2021-09-19 18:53:13 +01:00
refractionpcsx2
8fe0061751 VU: Sync tighter when VU Kickstart is disabled + Improved M-Bit Sync 2021-09-19 18:49:24 +01:00
refractionpcsx2
ee9672858c VU Int: Remove rogue value from debug logging 2021-09-19 16:30:08 +01:00
Connor McLaughlin
1ee0e23617 GS: Downgrade include AppCoreThread.h -> AppConfig.h 2021-09-17 22:03:00 -04:00
Connor McLaughlin
1dfd2e2ec1 AppCoreThread: Remove unused DisassemblyDialog.h include 2021-09-17 22:03:00 -04:00
Connor McLaughlin
65aa811344 DebugTools: Add missing Config.h include 2021-09-17 22:03:00 -04:00
Connor McLaughlin
e2992cbc02 Remove gui/ directory from target-wide includes 2021-09-17 22:03:00 -04:00
refractionpcsx2
a546cb8f7f microVU: Use 16 xmm's in x64 2021-09-17 14:37:11 +01:00
Mrlinkwii
9c24e48e68 Docs: update GameIndex .md and .pdf
Docs: update  GameIndex .md and .pdf
2021-09-17 14:29:49 +01:00
refractionpcsx2
862d606514 EE Rec: Added LDR/LDL
Also fixed slight optimisation bug in SDL
2021-09-17 13:06:47 +01:00
refractionpcsx2
5f58c325ca EE JIT: Implement SDR/SDL instructions 2021-09-17 13:06:47 +01:00
refractionpcsx2
c1d21c5513 GameDB: Added some required XGKick gamefixes 2021-09-17 13:04:26 +01:00
refractionpcsx2
d9c4ace613 VU: Put XGKick 1 cycle behind to fix sync issues with Jaws Unleashed
Also added Jaws unleashed xgkick gamefixes to the DB
2021-09-17 13:04:26 +01:00
refractionpcsx2
59dfe52b52 microVU: Replace XGKick hack with synced XGKick option
Fixes Tennis Court Smash and Love Smash games which previously couldn't be fixed.
WRC no longer requires a patch, just the xgkickhack option.

Note: it's not a hack anymore, it just has to be called that :P
2021-09-17 13:04:26 +01:00
refractionpcsx2
d3f0718001 SPU2: Disallow KeyOn within 2T of last KeyOn
Fixes Legend of Spyro New Beginning hang
2021-09-17 13:04:15 +01:00
RedDevilus
f460cac3ba GameDB: Sports (RTL)
Mostly missing RTL sports clamp modes. People knew the fixes on the forum but don't make PR or didn't tell anyone. Testers hoarding bugs :P
2021-09-17 10:24:13 +01:00
RedDevilus
4586a645fc GameDB: Katamari Games
The automatic gamefixes were incorrect as it would SPS. Fix the SPS with nearest VuRound and then Extra + Preserve sign for VuClamp. God will be pleased.
2021-09-17 10:20:15 +01:00
Mrlinkwii
beb8ec2668 GameDB :add 'VUKickstartHack' to the Full Spectrum games
GameDB :add 'VUKickstartHack' to the Full Spectrum games
2021-09-17 10:19:57 +01:00
Mrlinkwii
e68c977ecf GameDB: add 'VUKickstartHack; to path of neo
GameDB: add 'VUKickstartHack' of path of neo
2021-09-17 01:08:43 +01:00
Silent
45de8f77cd Make CheckIsUserOnHighPerfPowerPlan use WIL 2021-09-16 17:31:45 -04:00
Silent
ec9c6521fd Migrated tap-win32 2021-09-16 17:31:45 -04:00
Silent
bdb4ff0d83 Migrated SndOut_XAudio2 2021-09-16 17:31:45 -04:00
Silent
f343614640 Target Windows 8 via project settings
It's needed for the next commit, as thanks to wxWidgets
anything using the precompiled header would default to 0x0600 (Vista)
instead of 0x0602 (Win8).

Now-redundant WINNT definitions resulting in macro redefinition
warnings have been removed.
2021-09-16 17:31:45 -04:00
Silent
8841df96c0 Migrated GSDevice11, GSTexture11, GSSettingsDlg, GSUtil 2021-09-16 17:31:45 -04:00
Silent
8c6cad559e Migrated GSCapture and GSCaptureDlg 2021-09-16 17:31:45 -04:00
Silent
ed62ae124b Add Windows Implementation Libraries 2021-09-16 17:31:45 -04:00
kojin
0a7b725340 don't track local vs cmake settings 2021-09-16 14:56:10 -04:00
refractionpcsx2
ac87484acc GameDB: Patch rounding problem in Playmobil Hype The Time Quest 2021-09-14 17:45:29 +01:00
RedDevilus
8235d6cb72 GameDB: Punisher
Changes to recent VU timings have upset the punisher, this will quench his issues with VUKickstart.
2021-09-14 09:23:59 +01:00
kojin
77c961ba40 vs: fix an oversight
when I merged the utils and emitter project in #4707 I neglected to update the SVNRootDir macro so it was causing common libraries to not be written to the correct directory.

don't use this macro anymore so just remove it make output relative to solution dir instead
2021-09-13 20:51:58 -04:00
refractionpcsx2
154ed57633 VU Int: Remove need to pass VU struct to XGKick function.
It's always VU1, so we don't need to tell it.
2021-09-13 20:55:53 +01:00
refractionpcsx2
b0d1d4ff44 VU Int: Clang formatting 2021-09-12 16:12:31 +01:00
refractionpcsx2
52943d8399 VU Int: Link in clamping settings from UI
The only settings are either None or every other option is On (basically Extra + Preserve Sign)
2021-09-12 16:12:31 +01:00
refractionpcsx2
980c954bf4 GIF: Fix GIF FIFO behaviour when the FIFO drains 2021-09-12 16:12:31 +01:00
refractionpcsx2
73bb8e4fdf VU Int: Make XGKick flush on VU program end
Some games like to write directly to VU memory once the program has finished and I have no easy way to update the kick without being super slow. so for now, we'll just flush it.
2021-09-12 16:12:31 +01:00
refractionpcsx2
3f56414824 VIF/VU: Cleaned up VIF Stall behaviour, sync XGKick with Unpacks.
Also cleaned up a bunch of bad/old code
Fixed branches on E-Bit and M-Bit (VU0)
Fixed up VU Int behaviour with VU Instant on/off

Savestate bump
2021-09-12 16:12:31 +01:00
refractionpcsx2
7e29a7e5a4 VU Int: Put XGKicks through the Gif Unit directly, don't buffer
Solves problems with PATH3 masking games
2021-09-12 16:12:31 +01:00
refractionpcsx2
7966c27246 GIF: Handle PATH2 ending when VIF not running 2021-09-12 16:12:31 +01:00
refractionpcsx2
c2af477758 VU Int: Combine XGKick handling in to one function
Also fixed a situation where PATH3 could transfer a packet to the GIF and finish its DMA while PATH1 was busy, so PATH3 never finished transferring properly as it relies on the DMA to handle the pretend timing of PATH3.
2021-09-12 16:12:31 +01:00
refractionpcsx2
b4eaf3722f VU: Adjust timings of VU calls 2021-09-12 16:12:31 +01:00
refractionpcsx2
ddf305fce5 VU Int: Correct EFU stalls + explanation 2021-09-12 16:12:31 +01:00
refractionpcsx2
857ab07f1c VUInt: Fix macro flags and implement EFU ops correctly.
Also now using the microVU style Tri-Ace hack as the interpreters seem to now need it
2021-09-12 16:12:31 +01:00
refractionpcsx2
1f50dd7496 VU Int: Some formatting/logging cleanup, optimise some variable placement 2021-09-12 16:12:31 +01:00
refractionpcsx2
83143bd42e VU Int: Rewrote most of the FMAC/IALU handling, now with 2x performance 2021-09-12 16:12:31 +01:00
refractionpcsx2
e19b0bce57 VU: Improve VU0/Mbit sync with VU Interpreter. Improve Kickstart. 2021-09-12 16:12:31 +01:00
refractionpcsx2
2e2d6ba35d VU Int: IALU stalls, improve VI backup emulation 2021-09-12 16:12:31 +01:00
refractionpcsx2
aad4f3e753 VU: Tag which VU is being logged 2021-09-12 16:12:31 +01:00
refractionpcsx2
d7e6ef4ce6 VU Int: Properly limit ints when converting from float 2021-09-12 16:12:31 +01:00
refractionpcsx2
77eb380305 VU Int: Stop old versions of flags being written 2021-09-12 16:12:31 +01:00
refractionpcsx2
0326659b14 VU Int: Write back all pending pipes (will likely be ripped out later) 2021-09-12 16:12:31 +01:00
refractionpcsx2
3bad60ce84 VU Int: Fix XGKick wrapping 2021-09-12 16:12:31 +01:00
refractionpcsx2
067faccdd2 VU: Initial work to overhaul VU interpreter
Still a bit janky in some games and subject to changes
2021-09-12 16:12:31 +01:00
Ziemas
253571fd35 Delete unused vol_t type 2021-09-12 00:17:37 -04:00
Ziemas
a58fde68e6 C++-ify freezeData definition 2021-09-12 00:17:37 -04:00
Ziemas
8fe7a173cd C++-ify Pcsx2Types 2021-09-12 00:17:37 -04:00
Ziemas
fc9beafc32 Change s8 typedef to int8_t 2021-09-12 00:17:37 -04:00
Ty Lamontagne
2175814acf Debugger: CtrlRegisterList: Fix warning and screw up 2021-09-12 00:17:08 -04:00
Kojin
19072b6595 common: move some gui stuff into the main project (#4751)
* common: move ThreadingDialogs and wxAppWithHelpers to main project
* common: move CheckedStaticBox to the main project
* common: move pxCheckBox to the main project
* common: move pxRadioPanel to the main project
* common: move pxEvents.h to main project
2021-09-11 10:59:14 -04:00
kojin
43e3055d11 config: normalize limiter values before saving 2021-09-11 10:48:24 -04:00
Ty Lamontagne
ab64023e56 MicroVU: Cleanup stale comments and code 2021-09-11 01:33:02 +01:00
Connor McLaughlin
a8a50641f6 R5900: Fix LWL not sign extending in interpreter
This was zero extending because of the implicit promotion from
signed->unsigned, causing incorrect high bits in the GPR.

Funnily enough, this was noted in the source, but implemented
incorrectly.
2021-09-09 09:28:03 +01:00
refractionpcsx2
9722bcd3c3 CDVD: Revert seek status.
WRC didn't like "Seek" being on the seek... We're going to need to run tests for this.
2021-09-09 02:55:16 +01:00
Ziemas
9832a935d7 Common: Fix IniInterface warnings 2021-09-07 09:33:09 -04:00
Ty Lamontagne
b12f0d865f Debugger: Remove 64/32 bit views. Revamped VU0F titles 2021-09-06 22:24:46 +01:00
Ty Lamontagne
77e630b78a Debugger: Don't resize register view anymore
Possible workaround for broken wx or gtk or wm implementations where setting an initial size of the current size breaks the register view.
2021-09-06 22:24:46 +01:00
kojin
30e5731f14 common: fix locale oversight in IniInterface 2021-09-06 16:53:32 -04:00
Ty Lamontagne
18311d6a4c MicroVU: Purge Min/Max speedhack 2021-09-06 21:36:10 +01:00
Mrlinkwii
17fdc6a0f3 GameDB: Dropship disable InstantVU
GameDB: Dropship  disable InstantVU
2021-09-06 20:55:39 +01:00
refractionpcsx2
33ac2e7d15 CDVD: Fix up Pause and some Status behaviour 2021-09-06 20:54:16 +01:00
Ty Lamontagne
589aba3713 [MicroVU] Revert "bla"
This reverts commit 6800753f09.
2021-09-06 19:53:08 +01:00
HazNut
2e6174bd2c readme: Replace dead BIOS extraction link 2021-09-06 19:43:14 +01:00
Kojin
13dfceff48 Common: reformat (#4720)
* common: format AlignedMalloc.cpp

* common: format AppTrait.h

* common: format Assertions.h

* common: format CheckedStaticBox

* common: format Console

* common: format Dependencies.h

* common: format EmbeddedImage

* common: format EventSource

* common: format Exceptions

* common: format FastFormatString.cpp

* common: format General.h

* common: format InitInterface

* common: format MathUtils.h

* common: format MemsetFast/MemcpyFast

* common: format Mutex.cpp

* common: format PageFaultSource.h

* common: format Path.h

* common: format PathUtils.cpp

* common: format Pcsx2Types.h

* common: format Perf

* common: format PersistentThread.h

* common: format RwMutex

* common: format SafeArray

* common: format ScopedAlloc.h

* common: format ScopedPtrMT.h

* common: format Semaphore.cpp

* common: format StringHelpers

* common: format ThreadTools.cpp

* common: format Threading.h

* common: format ThreadingDialogs

* common: format ThreadingInternal.h

* common: format TraceLog.h

* common: format VirtualMemory.cpp

* common: format pxCheckBox

* common: format pxEvents.h

* common: format pxForwardDefs.h

* common: format pxRadioPanel

* common: format pxStaticText

* common: format pxStreams

* common: format pxTranslate.cpp

* common: format pxWindowTextWriter.cpp

* common: format wxAppWithHelpers

* common: format wxBaseTools.h

* common: format wxGuiTools

* common: format wxHelpers.cpp

* common: format Darwin directory

* common: format Linux directory

* common: format Windows directory

* common: format LnxCpuDetect.cpp

* common: format WinCpuDetect.cpp

* common: format bmi.cpp

* common: format cpudetect.cpp

* common: format cpu_detect_internal.h

* common: format fpu.cpp

* common: format groups.cpp

* common: format instructions.h

* common: format internal.h

* common: format jmp.cpp

* common: format legacy.cpp

* common: format legacy_instructions.h

* common: format legacy_internal.h

* common: format movs.cpp

* common: format simd.cpp

* common: format tools.h

* common: format x86emitter.cpp

* common: format x86types.h

* common: format bmi.h

* common: format dwshift.h

* common: format group1.h group2.h group3.h

* common: format incdec.h

* common: format jmpcall.h

* common: format movs.h

* common: format simd_arithmetic.h

* common: format simd_comparisons.h

* common: format simd_helpers.h

* common: format simd_moremovs.h

* common: format simd_shufflepack.h

* common: format simd_templated_helpers.h

* common: format test.h
2021-09-06 14:28:26 -04:00
Mrlinkwii
f9bf87f50d GameDB: add positive EE&VU rounding to Simple 2000 Series Vol.48
GameDB: add positive EE&VU rounding to Simple 2000 Series Vol.48
2021-09-06 17:56:09 +01:00
refractionpcsx2
0226c443e7 GameDB: Update patches for Musashi Samurai Legend/Musashiden II
These don't cause TLB misses
2021-09-05 21:18:29 +01:00
Ty Lamontagne
f91286dbf3 MicroVU: Skip VU1 instructions on VU0 2021-09-05 21:18:19 +01:00
lightningterror
aec1249481 pad-linux: Update to latest controller database. 2021-09-05 21:48:56 +02:00
refractionpcsx2
b919de9dd1 VU: Adjust sync timing for VU Kickstart
Fixes Crash Twinsanity
2021-09-05 18:14:53 +01:00
lightningterror
c2dad218e5 microVU: Combine mVU0cacheReserve and mVU1cacheReserve. 2021-09-05 18:06:46 +02:00
refractionpcsx2
ddb300027c VU: Improve sync during interlock and Scratchpad VU mem writes
Also added some setting of next block cycles to 0 in cases where we don't know ahead of compile time or the VU is ending.
2021-09-05 16:37:43 +01:00
refractionpcsx2
420b675746 GameDB: Revert Musashi - Samurai Legend (PAL-M4) patch until it's improved
Patch causes TLB misses and can make the game non-functional.  Will replace it again once the TLB misses have been corrected.
2021-09-05 06:28:17 +01:00
TellowKrinkle
1fe352d8a6 CMake: Add proper dependencies for bin2cpp invocations 2021-09-04 21:06:20 -05:00
RedDevilus
de7a92944f Add 7xMultiplier
7x was bullied for far too long (2520P / 4.5K resolution).
2021-09-04 18:31:28 -04:00
TellowKrinkle
dae8e0d233 Core: Remove unused mmx stuff 2021-09-04 18:28:24 -04:00
TellowKrinkle
5260d63565 Core: Format recompilers 2021-09-04 18:28:24 -04:00
kojin
7aa85960ba common: add vs filters 2021-09-04 18:28:07 -04:00
kojin
dcbf62a294 common: add some stuff to the pch 2021-09-04 18:28:07 -04:00
kojin
42f2210f7f common: remove unused pch 2021-09-04 18:28:07 -04:00
kojin
0717bf788a common: fix cmake on linux/macos 2021-09-04 18:28:07 -04:00
kojin
831c8b9189 common: fix cmake on win32 2021-09-04 18:28:07 -04:00
kojin
8fdaaa2eab common: reorganize 2021-09-04 18:28:07 -04:00
RedDevilus
ce8a30bf8f Gamedb:Kuon
Fixes game pieces in the mini-game
2021-09-04 23:27:33 +01:00
Mrlinkwii
0a0430051c GS : update OGL advanced settings tool tip
GS : update OGL advanced settings tool tip
2021-09-04 03:31:26 +02:00
dependabot[bot]
8ba9cc102a build(deps): bump mikehardy/buildcache-action from 1.2.1 to 1.2.2
Bumps [mikehardy/buildcache-action](https://github.com/mikehardy/buildcache-action) from 1.2.1 to 1.2.2.
- [Release notes](https://github.com/mikehardy/buildcache-action/releases)
- [Changelog](https://github.com/mikehardy/buildcache-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/mikehardy/buildcache-action/compare/v1.2.1...v1.2.2)

---
updated-dependencies:
- dependency-name: mikehardy/buildcache-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-03 16:48:16 -05:00
refractionpcsx2
bb5bfda5c6 App: Link in version number information to exe version information 2021-09-02 10:00:59 +01:00
refractionpcsx2
b61f6d517b App: Add Windows exe version information 2021-09-02 10:00:59 +01:00
kojin
38f1a9a762 util: purge fixed-point library 2021-09-01 08:32:14 -04:00
refractionpcsx2
bda80fc748 Clang Format VU files 2021-08-31 21:29:31 +01:00
refractionpcsx2
553d8ccbb4 Savestate version bump 2021-08-31 21:29:31 +01:00
refractionpcsx2
d8dfe0a1e9 VU: optimise entering VU JITs
Keeps note on how many cycles it needs for the next block to save exiting the EE JIT and entering the microVU JIT for no reason
2021-08-31 21:29:31 +01:00
refractionpcsx2
ef9c8ce877 SPU2: Don't initialise sound buffer if it's not open 2021-08-31 20:03:40 +01:00
refractionpcsx2
4dc0db6ee6 SPU2: Adjust DMA timings for IRQ's and small packets
This also gets rid of a little kinda hack thing that was in there.
2021-08-31 20:03:25 +01:00
TellowKrinkle
c93692a779 GHActions:Linux: Make ccache config global
New testing step was missing the config
2021-08-30 13:42:28 +02:00
lightningterror
756e3b4a12 pad-linux: Update to latest controller database. 2021-08-30 12:45:49 +02:00
kojin
681531d128 vs: enable mp on debug/devel builds 2021-08-29 19:51:24 -04:00
kojin
6bff64f834 vs: fix some project config associations 2021-08-29 19:51:24 -04:00
kojin
4dc26ab234 vs: remove optimizations for debug config of a few projects 2021-08-29 19:51:24 -04:00
kojin
c6fc357c43 vs: fix a few compiler warnings 2021-08-29 19:51:24 -04:00
kojin
64cc1b106c linux: remove gl optimizations from wrapper script 2021-08-29 01:17:41 -04:00
tellowkrinkle
b61619cf40 CMake: Fix builds outside of CI 2021-08-27 23:27:59 -05:00
kenshen112
14cfdafd05 Disable gl threaded optimization 2021-08-28 00:14:23 -04:00
TellowKrinkle
010893092e CMake: Match recently removed files from vcxproj 2021-08-28 04:27:16 +01:00
Christian Kenny
b5fd684160 PAD: Clean up includes, remove old code 2021-08-28 03:27:29 +01:00
Christian Kenny
a9c2409e0f PAD: Remove Force Hide (for mouse). Remove DirectInput options for mouse and keyboard 2021-08-28 03:27:29 +01:00
TellowKrinkle
6d5fedcf97 tmp: Add manifest to CMakeLists on Windows 2021-08-28 03:25:33 +01:00
TellowKrinkle
2881149f0b CMake: Add CI flag for CI builds 2021-08-28 03:25:33 +01:00
TellowKrinkle
142d91dfb5 GHActions: Run tests on Windows 2021-08-28 03:25:33 +01:00
TellowKrinkle
4d8b9aee2a CMake: Support windows for tests 2021-08-28 03:25:33 +01:00
TellowKrinkle
04df2824cf GHActions: Clean up old unused code 2021-08-28 03:25:33 +01:00
TellowKrinkle
059d856f45 CMake: Match git info to vs project 2021-08-28 03:25:33 +01:00
TellowKrinkle
2ce3a004ba GHActions: Add buildcache on windows 2021-08-28 03:25:33 +01:00
TellowKrinkle
e9e58fd791 GHActions: Use ninja for windows cmake builds 2021-08-28 03:25:33 +01:00
TellowKrinkle
4f22bc8162 GHActions: Add windows cmake build 2021-08-28 03:25:33 +01:00
TellowKrinkle
1159f6d4f8 Remove unused file 2021-08-28 03:25:33 +01:00
TellowKrinkle
315c87bd4f cmake: Windows build 2021-08-28 03:25:33 +01:00
TellowKrinkle
e1bb96cc94 cmake: Windows dependency builds 2021-08-28 03:25:33 +01:00
kojin
205c8a05c3 gs: purge clut reload before draw hack 2021-08-27 22:01:36 -04:00
refractionpcsx2
c288be3d4c COP0 PCCR: Don't update counters if counting is disabled
Gets rid of the spooky apparition in Grand Theft Auto 3 if you watch the intro.

This is kind of just enabling the old code which was kind of correct, but the old code didn't ignore the time passed, so this also updates the last cycles.
2021-08-27 19:42:28 +01:00
TheLastRar
feaf5ba5f2 DEV9: Reduce the amount of log spam from HDD access 2021-08-26 00:21:38 +01:00
TheLastRar
f7838750c9 DEV9: Reduce the amount of log spam form network traffic in Debug mode 2021-08-26 00:21:38 +01:00
TheLastRar
6051312dfb DEV9: Dev logging fixes 2021-08-26 00:21:38 +01:00
Mrlinkwii
bafb0db6d1 GameDB: Add various fixes
GameDB:  Add various fixes
2021-08-25 18:29:54 +01:00
refractionpcsx2
31dcacb941 GameDB: Added VU Kickstart for remaining Dororo (Blood Will Tell) entries 2021-08-24 23:38:10 +01:00
Ty Lamontagne
74105d6983 AppMain: Fix no$ symbol loading for elfs
Previously, we would look for (isoname.sym) even if we were loading an ELF. Just another part of the mess that CDVD is.
2021-08-24 23:15:34 +02:00
Mrlinkwii
e4e306baca SPU2: remove waveout windows
SPU2: remove waveout windows
2021-08-24 23:13:26 +02:00
Ziemas
5f3c1816f9 Cmake: Link vtune in utilities 2021-08-24 23:10:06 +02:00
Ziemas
90a198e3f1 Cmake: Update vtune paths 2021-08-24 23:10:06 +02:00
lightningterror
2dbfe9f743 gs: Cleanup remaining stuff from sse2/3 purge. 2021-08-24 12:58:18 +02:00
kojin
a68d834f8f gs: remove a bunch of unofficial crcs
stop encouraging people
2021-08-24 05:39:14 -04:00
arcum42@gmail.com
c3b45f3237 Remove MakeUnique.h, which is unused. 2021-08-24 04:33:46 -04:00
refractionpcsx2
61dca40679 GameDB: Added VU Kickstart for Dororo (Blood Will Tell) 2021-08-22 08:20:29 +01:00
Mrlinkwii
94c6814be8 GameDB: add'EE timing hack' to Spartan: Total Warrior
GameDB: add'EE timing hack' to Spartan: Total Warrior
2021-08-21 21:44:53 +01:00
RedDevilus
436e252d0e GameDB: Ratchet and Clank
Add EETiming to Ratchet and clank to avoid TLB misses.
2021-08-21 20:18:30 +01:00
RedDevilus
4032b91e72 GameDB:Powerpuff Girls
Fixes hangs in certain locations like building under construction.
2021-08-21 20:15:08 +01:00
Ty Lamontagne
509e24f966 IOPBios: Fix OOB read when IRQ line is invalid.
Fixes a PS2AutoTest where RegisterIntrHandler(-1,... ) crashes PCSX2.
2021-08-21 20:08:36 +01:00
lightningterror
d0f3c620d2 GSBlock: Cleanup warnings. 2021-08-20 13:35:01 +02:00
lightningterror
86263d05bc pgif: Cleanup warnings. 2021-08-20 13:35:01 +02:00
TellowKrinkle
cee077d1d3 cmake: Fix missing librt include 2021-08-19 20:46:37 -05:00
RedDevilus
ee0b2b1249 GS-GUI: Enable Software Edge-Aliasing by default
This will enable the checkbox for the software renderer, it has far more pros than cons (negligble performance hit)
2021-08-19 19:22:30 -04:00
refractionpcsx2
b167bd6807 GameDB: Added other versions of midnight club.
Improved the patches also as apparently was causing issues with the net config
2021-08-19 14:29:08 +01:00
refractionpcsx2
90e8923c31 GameDB: Add patch for MTVU performance in Midnight Club 3 Dub Remix 2021-08-19 11:31:19 +01:00
TellowKrinkle
7af74deaac Pad: Fix crash on shutdown in macOS 2021-08-18 17:25:37 -05:00
TellowKrinkle
d96b1ef525 Pad: Formatting 2021-08-18 17:25:37 -05:00
kojin
0bd65614d0 wx: make position validation multi-monitor aware 2021-08-18 13:40:45 -04:00
Mrlinkwii
0e3401da2c Clang: LnxMisc.cpp
Clang: LnxMisc.cpp
2021-08-18 18:24:47 +02:00
Mrlinkwii
692adbd04a Utilities : Return distro info instead of kernel version
Utilities: Return  distro info instead of kernel version
Co-Authored-By: Ty <29295048+F0bes@users.noreply.github.com>
2021-08-18 18:24:47 +02:00
lightningterror
7b587dcc9c pad-linux: Update to latest controller database. 2021-08-18 15:20:53 +02:00
Ty Lamontagne
17c66cc2d3 Misc: Fix lastpath updating when using --elf cmdline 2021-08-18 14:26:17 +02:00
Connor McLaughlin
d7de81aaaa iR5900: Make const register write clearer
This was apparently sign extending anyway, but using SD makes it clear
that the 32-bit assignment will sign extend to 64-bit.
2021-08-17 14:43:24 -04:00
Connor McLaughlin
a216f28c9d iR5900: Use a signed multiply for MULT1 const prop 2021-08-17 14:43:24 -04:00
refractionpcsx2
1180de51fd GameDB: Add clamping to True Crime: New York, fixing SPS 2021-08-16 22:32:36 +01:00
Connor McLaughlin
6844849305 microVU: Don't emit add reg, 0 in a few instructions 2021-08-15 08:02:34 +01:00
TellowKrinkle
af07d803fd cmake: Enable features by checking targets
Helpful for if targets are added as submodules in the future (hint: Windows builds)
2021-08-15 02:13:36 -04:00
TellowKrinkle
284ca6ae68 cmake: Add support for using c++ bin2cpp instead of perl 2021-08-15 02:13:36 -04:00
TellowKrinkle
122de7a7d7 cmake: Remove old add_pcsx2_* macros
No longer used
2021-08-15 02:13:36 -04:00
TellowKrinkle
e17f83c2cf bin2cpp: Remove fcloseall usage
fcloseall isn't available on macOS, and everything gets closed when the program exits anyways
2021-08-15 02:13:36 -04:00
TellowKrinkle
7ed0f38623 CMake: Define targets early instead of gathering variables 2021-08-15 02:13:36 -04:00
Tyler Wilding
ae2ae8b982 github: Switch to new issue forms (#4657)
* github: New issue forms

* remove default numbered list
2021-08-14 01:08:18 -04:00
RedDevilus
02a60acbcc 3rdparty: Update GHC 1.5.4 to 1.5.8
Make ghc act more like std::fs + consistency with C++17 and other fixes.
2021-08-13 18:53:11 -04:00
RedDevilus
69ba5b447f Update SysConfigDialog.cpp 2021-08-13 23:10:24 +02:00
RedDevilus
11c346ab02 PCSX2-GUI: Undo formatting 2021-08-13 23:10:24 +02:00
RedDevilus
88c2e9ea48 PCSX2-GUI: Remove hackfix
Future change to be made to fix the height of General Settings.
2021-08-13 23:10:24 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
52cefc5543 ftw: remove inheritance, make sure warning popup shows
Turns out we had an unneeded layer of inheritance in the name of
BasePathsPanel, whose only job was to, wait for it, be inherited.
It is an empty class inheriting wxPanel instead of the needed
BaseApplicationConfigPanel, making it all the more unecessary.

Someone _really_ loved their OOP.

Also added back the OnShown trigger for the BIOS page to ensure BIOS
confirmity.
2021-08-13 23:10:24 +02:00
RedDevilus
3e1b76c0a9 PCSX2-GUI: Rehaul BIOS / Folder Selector (#4620)
Since emulation settings has been renamed general settings, we can put BIOS and Folder in the same location where people have an overview and can just use tab key on icons or mouse. Less confusion and also fixes the speedhacks section *for the zillionth time*.
2021-08-13 23:10:24 +02:00
Silent
f45c618fc2 KeyboardQueue: Remove a Windows-specific critsec 2021-08-13 17:00:56 -04:00
refractionpcsx2
9892624242 Counters: Fix scanline count for double strike modes. 2021-08-13 16:21:13 +01:00
GiantEnemyCrab
4dee68faaf Add StartupWMClass to desktop file 2021-08-12 12:43:40 +02:00
Mrlinkwii
04aa251dee Docs: correct GameIndex.md
Update GameDB docs
2021-08-12 11:40:32 +01:00
Mrlinkwii
be6db93698 GameDB: add 'EETimingHack' for Marvel Super Hero Squad and positive EE and VU rounding forPac-Man Fever
GameDB: add 'EETimingHack' for Marvel Super Hero Squad and positive EE and VU rounding  forPac-Man Fever
2021-08-10 23:21:43 +01:00
refractionpcsx2
c61473d060 SPU2: Re-enable log file writing in dev builds 2021-08-10 18:08:13 +01:00
kozarovv
47bdc58c1a PGIF: Code refactoring/cleanup.
Improve few games like RE2, THPS2, Castlevania SOTN, FF8.
2021-08-08 19:01:35 +01:00
lightningterror
70a862fced pad-linux: Update to latest controller database. 2021-08-08 19:09:32 +02:00
RedDevilus
c6a39006d5 3rdparty: update GL headers
Update the headers to a more recent version while it brings no improvements at this moment, it can in the future.

Update glcorearb.h from 7 February 2019
Update wglext.h from 33248 (10-24-2016) to 20200813 (13 August 2020)
Update glext.h from 33248 (10-24-2016) to 20210420 ( 20 April 2021)
Creation of khrplatform.h
2021-08-07 20:58:19 -04:00
refractionpcsx2
0c5df806bf Counters: Correct H-Blank for 1080i mode 2021-08-07 14:02:12 +01:00
kozarovv
94910216f7 CDVD: Implement SCMD 0x27
Fix PS1 mode for SCPH-50009, and DTL-H50009.
2021-08-07 13:11:04 +01:00
Ty Lamontagne
f1b4bee88f X86Emitter: Use __rdtsc define on non-msvc compilers 2021-08-07 00:57:22 -04:00
Ty Lamontagne
87ee413141 Debugger: codacy warnings 2021-08-07 05:54:13 +01:00
Ty Lamontagne
823618aea8 Debugger: Properly implement VU0F titles 2021-08-07 05:54:13 +01:00
Ty Lamontagne
bb3fb35c7e clang-format: DebugInterface.cpp CtrlRegisterList.cpp CtrlRegisterList.h 2021-08-07 05:54:13 +01:00
Ty Lamontagne
8f171c70f5 Debugger: Add option to display VU0F registers as floats 2021-08-07 05:54:13 +01:00
Christian Kenny
f11334cb3b SPU2: Missed Linux WX files 2021-08-07 05:51:58 +01:00
Christian Kenny
df1461bba6 SPU2: Final GUI adjustments. It's not pretty but it'll do until the dialog gets rewritten. 2021-08-07 05:51:58 +01:00
Christian Kenny
97749e6005 SPU2: Remove awful dealias filter that made games sound like crap. 2021-08-07 05:51:58 +01:00
Christian Kenny
11ed747741 SPU2: Remove user option to disable reverb. 2021-08-07 05:51:58 +01:00
lightningterror
a982852e30 pad-linux: Update to latest controller database. 2021-08-06 07:07:31 +02:00
jackun
a811e653a7 USB: Fix HID mouse packet size and tablet poll interval 2021-08-06 03:33:34 +03:00
TellowKrinkle
0d4549a66e cmake: Mark .inl files with the right type in Xcode 2021-08-05 18:20:58 -05:00
TellowKrinkle
f3dbf24864 vcxproj: Add filters for some missing files 2021-08-05 18:20:58 -05:00
TellowKrinkle
525027f993 vcxproj: Fix filters for case sensitive matching 2021-08-05 18:20:58 -05:00
TellowKrinkle
e34116e340 cmake: Parse vcxproj filters for cmake generators 2021-08-05 18:20:58 -05:00
Christian Kenny
55d0d40697 SPU2: Restore functionality to switch modules on the fly without being tied to GS window status. 2021-08-05 23:51:11 +01:00
Christian Kenny
9d9e8a9217 SPU2: Simplify reset mode function for sample rate. 2021-08-05 23:51:11 +01:00
kozarovv
167a4b4d12 CDVD: Fix CdlReadS for PS1 games with CDDA.
Fix Legend of Dragoon, maybe more.
2021-08-05 23:04:01 +01:00
TellowKrinkle
c1e6773818 cmake: fix missing .h on header reference
Prevents cmake from bugging us about it
2021-08-05 03:00:43 -05:00
TellowKrinkle
e1a223c7c3 deps: Update gtest to 1.11.0
Prevents newer cmake from screaming at us about its ancient CMakeLists
2021-08-05 03:00:43 -05:00
Jannik Vogel
21c13a850c Misc:Debugger: Fix vmulai and vmaddai disassembly 2021-08-04 00:49:14 +01:00
Mrlinkwii
64d8b7fbe7 GameDB: add 'EEtiming hack' to Way of the Samurai Sega Soccer Slam (#4643)
GameDB: add 'EEtiming hack' to Way of the Samurai & Sega Soccer Slam
2021-08-03 22:55:26 +01:00
refractionpcsx2
8f82cd11b9 microVU: avoid half completed program loading null block 2021-08-03 11:52:15 +01:00
TellowKrinkle
958e27c782 GHActions: Run tests 2021-08-02 00:24:59 -05:00
TellowKrinkle
f032e663cd testing: Fix x86emitter includes on x86emitter tests 2021-08-02 00:24:59 -05:00
TellowKrinkle
70a1b31f5d testing: Add block swizzle tests 2021-08-02 00:24:59 -05:00
lightningterror
dc4b382b20 gs-d3d11: Move BlendEnable toggle. 2021-08-01 10:03:44 +02:00
lightningterror
4308aa29dd gs-d3d11: Set blend index to 0 when hw blending is disabled. 2021-08-01 10:03:44 +02:00
lightningterror
043b5d351f gs-d3d11: Cleanup fxaa and external shader.
Instead of relying on bools for checks rely on the pixel shader
pointer, also merge the functions.
2021-08-01 10:02:59 +02:00
refractionpcsx2
97bfe08c04 VIF: Only enable reverse FIFO hack if VIF1 is still active 2021-08-01 01:54:32 +01:00
Francisco Javier Trujillo Mata
407a64c118 HostFS: make const several no mutable variables 2021-07-31 23:23:40 +01:00
Francisco Javier Trujillo Mata
e7513c8c58 HostFS: Add remove file functionality 2021-07-31 23:23:40 +01:00
refractionpcsx2
3eda42075a Clang: Format FiFo.cpp 2021-07-29 20:33:52 +01:00
Timothy O'Barr
85d35311d0 UI: Added PGIF log source (#4564) 2021-07-29 17:56:17 +01:00
refractionpcsx2
88a53f013e Clang: Format Gif.cpp, Vif_Codes.cpp, Vif.cpp 2021-07-29 14:58:36 +01:00
refractionpcsx2
88edd1acd6 GIF: Adjusted intermittent mode split of large packets
Should be a bit more performant now in games like Tekken Tag
Adjusted for The Suffering
2021-07-29 14:58:36 +01:00
refractionpcsx2
fd1305e4da GIF: Reimplement GIF FIFO to kick in only when it is needed.
Need to adjust GameDB entries for to remove ones no longer required, added EE Timing fix for SOCOM as that seems to fix it up like its sequel.

Some misc changes too which are inconsequential (mostly formatting)
2021-07-29 14:58:36 +01:00
lightningterror
35c50e01e1 gs-hw: Sync external shader logs between gl and d3d11. 2021-07-29 12:32:39 +02:00
RedDevilus
2a409af54e GameDB: Patches for 18 games (or 15 individual games)
- Arctic Thunder
- Evolution Snowboarding
- From Software First Previews
- Growlanser Generations
- ICO
- Major League Baseball 2K5
- Major League Baseball 2K10
- Musashiden II - Blademaster
- Musashi Samurai Legend
- NHL 2K5
- NHL 2K6
- NHL 2K7
- NHL 2K8
- NHL 2K9
- Virtua Fighter 4
-- Removed patches and other miscellaneous changes
2021-07-29 10:36:02 +01:00
Christian Kenny
cf3d5bc040 SPU2: Remove unused Lowpass files 2021-07-29 10:33:53 +01:00
Christian Kenny
40da5697c5 SPU2: Remove unused includes, defs, ect. 2021-07-29 10:33:53 +01:00
lightningterror
ea759d7b68 microVU: Clean up a few warnings. 2021-07-28 22:10:47 +02:00
Connor McLaughlin
34e779a654 GS: Manage draw rectangle in GS instead of wx 2021-07-27 12:38:52 -04:00
Ty Lamontagne
8bc01eb375 IOPBios: Workaround for '\' for HLE path functions
Fixes some ulaunchelf's on *NIX platforms
2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
b373763924 Fix warning and disable dummy static analysis warnings 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
b2618ba148 HostFS: Add is_host check in the dopen_HLE method 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
6902ce007a HostFS: Improve Hle_SetElfPath method 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
e9b3b89620 HostFS: Use filesystem to make it compile in windows 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
1606a50bb4 HostFS: Improving buffers allocation 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
4402bbda55 clang-format: pcsx2/IopBios.h and pcsx2/IopBios.cpp 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
4bf3819778 HostFS: Clean functions to save host path and elf path 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
9ecda0489b HostFS: Add native mode to the open file 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
0dadda66cf HostFS: Implement getstat and dread 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
aa20220627 HostFS: Implement opendir and closedir 2021-07-27 15:37:41 +01:00
Francisco Javier Trujillo Mata
45103ec496 HostFS: Add mkdir and rmdir support 2021-07-27 15:37:41 +01:00
lightningterror
397f257b39 vcxproj: Cleanup file includes, makes the solution a bit more tidy.
Mostly mirrors how source files are oranized.
2021-07-26 14:19:51 +02:00
Ty Lamontagne
0f20a22e10 Counters: Reset Timer Count Regardless of Interrupt Enable 2021-07-25 22:56:55 +01:00
Mrlinkwii
e64567e119 GameDB: add 'XGKickHack' to Super Monkey Ball Adventure
GameDB: add 'XGKickHack' to Super Monkey Ball Adventure
2021-07-25 20:25:22 +01:00
TellowKrinkle
73116752b9 GHActions: Remove dashes from build names
If you're going to switch dashes to spaces, swich all the dashes to spaces
2021-07-23 21:02:15 -05:00
kozarovv
cd33a17584 IPU: Store thresholds for color conversions in u16, bump savestate version. 2021-07-23 18:10:56 +01:00
Mrlinkwii
1a327a73a0 SPU2: remove unused variable
SPU2: remove unused variable
2021-07-22 14:19:04 +02:00
Ziemas
c1232136c2 SPU: Remove NEVER_SKIP_VOICES
This optimization is disabled and not really safe. Lets just remove it
and clean up the function that uses it.
2021-07-22 10:17:31 +01:00
refractionpcsx2
06d6001b0c SPU2: Add rogue BIOS loop point which Megaman X7 relies on.
Thanks to Ziemas for debugging this!
2021-07-22 09:38:17 +01:00
Ziemas
080ba94ed2 CHD: Fix parent search on windows
Apparently you can't use the constructor to concat a literal and a
wxString like that.
2021-07-21 08:51:57 +01:00
TellowKrinkle
a13222f926 CMake: Fix cmake reconfigure breaking dependencies
pkg_search_module was looking at our lib_FOUND and thinking it was its own
Fixed by tracking who found the library and only invoking pkg_search_module if pkg_search_module also found the library the previous time
2021-07-20 01:14:54 -05:00
Ty Lamontagne
146f9a766e System: Check active power profile on application launch 2021-07-20 07:31:56 +02:00
lightningterror
7b495437ae GSDebugger: Rename dump load error window title. 2021-07-20 06:45:17 +02:00
lightningterror
2b95e3b48b vcxproj: Include shaders in vs project. 2021-07-20 02:45:50 +02:00
RedDevilus
22fb1e2df4 GUI: Re-order config settings
This will re-organise the config window to be more visually distinct.
Also fixes the issue where GamePad and Graphics if used with Alt, though it would still work technically if you press G again.
2021-07-20 00:39:30 +02:00
kojin
52b6ae0bc2 vs update project files with new build props 2021-07-19 17:05:52 -04:00
kojin
e293e96f00 vs: add base and avx2 build config props 2021-07-19 17:05:52 -04:00
TellowKrinkle
d4f87112ec CDVD: Add minimum buffer size to ThreadedFileReader
If buffers are smaller than the threshold PCSX2 uses to decide whether to time a read as a seek, ThreadedFileReader fails to provide data in time for the very small linear read time cutoff
2021-07-19 22:01:41 +02:00
TellowKrinkle
f3ac8ee464 CDVD: Clean up CHD initialization
Now with 100% less `delete`s
2021-07-19 22:01:41 +02:00
TellowKrinkle
286e32c012 GUI: Add CHD to macOS Info.plist 2021-07-19 22:01:41 +02:00
TellowKrinkle
c39598b98d CDVD: Make CHD file reader threaded 2021-07-19 22:01:41 +02:00
TellowKrinkle
ae945f49e3 CDVD: Make CSO file reader threaded 2021-07-19 22:01:41 +02:00
TellowKrinkle
bdcfcc65ea CDVD: Add ThreadedFileReader 2021-07-19 22:01:41 +02:00
TellowKrinkle
d8d69f2aa8 Misc: Move thread name setting to global function
Useful for things that don't want an entire pxthread
2021-07-19 22:01:41 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
70f29072bf debian: Remove debian specific packaging hooks.
We switched to appimage in an earlier commit. It makes more sense for us
to maintain a distribution agnostic packaging method than something
which is already forked by upstream anyways.
2021-07-19 20:04:12 +02:00
Ziemas
9bdf6675fc USB: Freeze mode enum for keyboardmania 2021-07-19 19:37:30 +02:00
Ziemas
3ba2ae0275 SaveState: Use enum for freeze mode
Instead of preprocessor defines.
2021-07-19 18:39:41 +02:00
TellowKrinkle
4f50e7e478 GHActions: Don't update homebrew when not necessary
It's pretty slow and if GH hasn't been updating their image, could cause huge numbers of extra dependants and dependencies to have to be installed
2021-07-18 22:49:31 -05:00
kojin
2e411a6019 vs: drop asio build configuration for portaudio 2021-07-18 12:03:21 -04:00
arcum42
6d9d39d4c8 Completely remove __rdtsc define. (#4510) 2021-07-17 19:34:33 -07:00
TellowKrinkle
dba223eb18 cmake: override yaml-cpp settings to clear warning 2021-07-17 21:08:30 -05:00
TellowKrinkle
c072c0e82b cmake: Don't overwrite cmake default flags
Also makes sure we don't push our warning settings onto 3rd party libraries
2021-07-17 21:08:30 -05:00
TellowKrinkle
7bb3f41fdc cmake: Drop X11 requirement on macOS
We don't actually benefit from it
2021-07-17 21:08:30 -05:00
TellowKrinkle
248c8b9da4 GS: Remove circular header include 2021-07-17 21:08:30 -05:00
TellowKrinkle
4213b4a409 cmake: Use imported targets 2021-07-17 21:08:30 -05:00
TellowKrinkle
e788dd352c cmake: Fix FindGTK3 not creating targets properly 2021-07-17 21:08:30 -05:00
TellowKrinkle
2c869afbc6 Upgrade libchdr
Fixes cmake includes
2021-07-17 21:08:30 -05:00
TellowKrinkle
108e8bdf0a cmake: Remove unused options 2021-07-17 21:08:30 -05:00
refractionpcsx2
7584571fbc GameDB: Removed Ratchet Dynamic patch. 2021-07-18 01:24:29 +01:00
tellowkrinkle
e92d15e459 CI: Fix avx2-pch build
Was broken when `ADDITIONAL_CMAKE_ARGS` got quoted
2021-07-17 17:39:29 -05:00
refractionpcsx2
03b0d2eb00 RatchetDynaHack: Actually enable it when enabling the gamefix 2021-07-17 16:54:59 +01:00
Florin9doi
0fcabe2b8e Change Graphical to Graphics 2021-07-17 08:57:49 -04:00
Florin9doi
2925f3635f Set missing icons and update titles 2021-07-17 08:57:49 -04:00
Margen67
8628993fb0 Build improvements
Remove unneeded quotation marks.

linux-workflow.yml:
 Checkout Submodules:
  Shorten --jobs to -j, use $(getconf _NPROCESSORS_ONLN).
 Make restore-keys into one line.
 Remove unneeded ./.

macos-workflow.yml:
 Checkout Submodules:
  Shorten --jobs to -j.
 Use $(getconf _NPROCESSORS_ONLN) instead of 2.
 Move HOMEBREW_NO_INSTALL_CLEANUP to env: and add HOMEBREW_NO_ANALYTICS.
 Remove unneeded ./.

pr-triage.yml:
 Make on: pull_request_target into one line.
 Properly capitalize GitHub.

compile.sh:
 Add warning when running outside of GitHub Actions CI.
 Use $(getconf _NPROCESSORS_ONLN).

validate-vs-filters.ps1:
 End of file newline.

windows-workflow.yml:
 Rename config to configuration.
 Opt out of PowerShell telemetry.
 Checkout Submodules:
  Shorten --jobs to -j, use $env:NUMBER_OF_PROCESSORS.
 Remove unneeded shell from Verify VS Project Files.
 setup-msbuild:
  Use v1. (always the latest version)
  Remove useless vs-version parameter.
 Remove unneeded ./ and .\.
 Add -p to mkdir.

.gitmodules:
 Make submodules shallow.

build.sh:
 Move parameters from shebang to set.
 Consistent formatting for ifs.
 Use $(getconf _NPROCESSORS_ONLN).
2021-07-17 08:07:53 -04:00
qurious-pixel
4995b13994 Build: Add Nix dependencies
Add libthai.so.0
2021-07-17 07:38:31 -04:00
qurious-pixel
f430bca472 Build: Bundle GDK/GTK modules
Fixes Manjaro and Fedora crashes
2021-07-17 07:38:31 -04:00
qurious-pixel
c3403de216 Build: Bundle GDK/GTK modules
Add pkg-config and librsvg2-dev for i386.
Fixes Manjaro and Fedora crashes
2021-07-17 07:38:31 -04:00
lubuntu
dcfe9f7aff Build: Remove plugin references 2021-07-17 07:38:31 -04:00
qurios-pixel
bac66e1e5e CI: generate appimage with linux workflow 2021-07-17 07:38:31 -04:00
kojin
4eb5d2c5ed vs: properly disable gm and warnings 2021-07-17 00:31:33 -04:00
TellowKrinkle
5bfd48c65c cmake: Convert indentation to tabs
Previously was a random mix of tabs and spaces
2021-07-16 22:05:48 -05:00
lightningterror
d1344fdd91 pad-linux: Update to latest controller database. 2021-07-17 01:31:16 +02:00
kojin
a8b392e662 vs: clean up libsamplerate project 2021-07-16 19:17:02 -04:00
kojin
9768cfb4ba 3rdparty: convert jpgd to external library 2021-07-16 06:26:32 -04:00
Ziemas
975f33df52 SPU: Delete broken/unused alsa backend (#4530) 2021-07-15 22:41:44 -07:00
Ty Lamontagne
49986bab5e IOP: Warn on branches to zero 2021-07-15 18:34:53 +01:00
RedDevilus
a949b24434 GameDB: Official Playstation Demo serials
Adds a bunch of missing magazine demos.
2021-07-15 18:17:45 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6523b0e9c2 cmake: remove leftover calls to plugin cmakefiles 2021-07-15 14:01:45 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
29f83b4364 AppCoreThread: remove unneeded includes & unneeded double init call 2021-07-15 14:01:45 +01:00
Ty Lamontagne
efd2df8a33 clang-format: Debugger files (check commit message)
gui/Debugger/CtrlDisassemblyView.cpp
gui/Debugger/CtrlMemView.cpp
gui/DebugerLists.cpp

Had to manually format wx event tables
2021-07-15 14:01:09 +01:00
Ty Lamontagne
58a9460f7c Debugger: Modify hotkeys, add delete breakpoint context menu button
Add assemble opcode hotkey as well


Update debugger docs
2021-07-15 14:01:09 +01:00
IlDucci
f9909f4226 GameDB: Adding a couple of demo discs.
Adding Forbidden Siren (PAL demo disc) as well as the Bonus Demo 8 (old) demo disc, which was included with an updated Network Disc.

NOTE: The "(old)" part is written verbatim on the disc.
2021-07-15 14:00:26 +01:00
refractionpcsx2
56372cc46d GameDB: Rename VU0Kickstart -> VUKickstart
Clean up a couple of bits in microVU
2021-07-15 13:58:34 +01:00
refractionpcsx2
c31d6b9ca3 GameDB: Add dynamic patching for Ratchet & Clank games
Removed IPUWait hack as it is no longer required
2021-07-15 13:43:16 +01:00
refractionpcsx2
6d9ace148e VU: Improve sync with VU Kickstart, loosen without kickstart 2021-07-15 13:42:52 +01:00
Víctor "IlDucci
8d167158ae GameDB: Changing some Spanish-exclusive disc content. (#4551)
- Adding the hack fix for Oni (Spanish).
- Adding the proper name for GoldenEye Rogue Agent on the Spanish disc.
2021-07-15 12:45:32 +01:00
Mrlinkwii
71a04aae23 GameDB:add missing serials
GameDB: add serials that where missing
2021-07-14 17:16:58 +01:00
lightningterror
21908bdaad libchdr: Undo recent libchdr change. 2021-07-13 17:22:39 -05:00
sonicfind
1e056ca3fa Capture: Stop a capture at the end of an input recording 2021-07-13 23:03:03 +02:00
refractionpcsx2
45c1579a15 Debug: ignore perfectly timed DIV's, cycle count is off by one 2021-07-13 10:26:42 +01:00
Florin9doi
b85ebbbc2d USB: Move jpgd files to 3rdparty 2021-07-12 23:20:01 +03:00
Florin9doi
060ca1915f USB: Add experimental support for JPEG and multiple resolutions 2021-07-12 23:20:01 +03:00
Florin9doi
de728dbefc USB: Add jpge from https://github.com/richgel999/jpeg-compressor 2021-07-12 23:20:01 +03:00
Florin9doi
bba37b1ff7 USB: EyeToy's default registers 2021-07-12 23:20:01 +03:00
Florin9doi
e5f19a4312 USB: EyeToy LED status 2021-07-12 23:20:01 +03:00
refractionpcsx2
14be2649cf Debug: Detect bad COP2 DIV Unit Timing in Devel Builds 2021-07-12 20:45:50 +01:00
jackun
1f0f584397 USB: Simplify evdev controller mapping
Remove "clever autoconfig" that possibly mapped wrong control to wrong player.
Breaks mapping analog stick's single axis to two axes, for now.
2021-07-12 18:09:39 +03:00
jackun
2925077169 USB: Remove joydev support 2021-07-12 18:09:39 +03:00
jackun
d0ada6b40a USB: Add evdev support for keyboardmania 2021-07-12 18:09:39 +03:00
Aleksander Rem
238da17196 USB: Add keyboardmania
Signed-off-by: jackun <jack.un@gmail.com>
2021-07-12 18:09:39 +03:00
refractionpcsx2
9b8239bafa gameDB: Added required gamefix for Fighting Fury 2021-07-11 18:45:13 +01:00
Mrlinkwii
6d21761a4e Gamedb: add missing serial
Gamedb: add missing serial
2021-07-11 18:43:21 +01:00
Mrlinkwii
16fcd1d1ad GameDB: add missing serials
GameDB: add serials that were missing
2021-07-11 18:43:21 +01:00
kojin
d9bd63fcb7 gs: add jakx greatest hits crc 2021-07-10 05:13:33 -04:00
refractionpcsx2
98b19656c9 VU: Fix address masking in MTVU 2021-07-10 03:31:04 +01:00
refractionpcsx2
93e5f86e24 VUs: Mask start addresses
Fixes the crash in Red Faction 2 when using the VU0 JIT
2021-07-09 23:14:26 +01:00
RedDevilus
2195ac9051 SPU2: Clean up + add Gaussian value in comment 2021-07-09 19:00:42 +02:00
RedDevilus
be2bf9faca clang-format: -pcsx2\gui\Debugger\DisassemblyDialog.cpp 2021-07-09 18:59:35 +02:00
RedDevilus
b0edc68c3d Debugger-GUI: Resize help + add 2 hotkeys
A bit easier and nicer to look at but still needs some work.
2021-07-09 18:59:35 +02:00
Silent
a4057d569f GSFrame: Pass focus to GSPanel once Frame receives focus
Passing focus on the focus message instead of the activate message
resolves an issue where external processes (e.g. NVIDIA overlay)
forced a focus change to the GS Frame, requiring the window to be
refocused in order for keyboard inputs to work again.

Currently, GSFrame rejects focus messages and instead passes it to
the child GSPanel.
2021-07-09 18:45:31 +02:00
lightningterror
f7966bd213 misc: Change gsdx to gs comments. 2021-07-09 18:03:44 +02:00
lightningterror
e8cc2df46c cmake: SearchForStuff update to match gs merge. 2021-07-09 18:03:44 +02:00
lightningterror
7283b1a177 linux various: Update/tweak stuff to match recent gs merge. 2021-07-09 18:03:44 +02:00
lightningterror
26fdc3ea4b github: Update contributing template to match gs merge. 2021-07-09 18:03:44 +02:00
lightningterror
b52a2f4962 pad-linux: Update to latest controller database. 2021-07-08 20:03:31 +02:00
lightningterror
3376722a43 gs: Add crc id for GetaWay JP. 2021-07-08 18:58:31 +02:00
kozarovv
7dd4fd16fd IPU: Fix SETTH threshold masks
Bits 8:0 for transparency, and 24:16 for translucency.
2021-07-08 09:20:59 +01:00
Ty Lamontagne
178354099d clang-format: WinMisc.cpp 2021-07-07 18:30:38 -04:00
Ty Lamontagne
d9cee7467f Utilities: remove getversionex dependency 2021-07-07 18:30:38 -04:00
Tyler Wilding
811f9c52c6 ci: Split avx2 and non-avx2 windows builds (#4522)
* ci: Split avx2 and non-avx2 windows builds

* ci: Improve workflow naming

* ci: Avoid bleeding-edge emojis 🪟

* ci: Don't include debug symbol artifacts by default
2021-07-06 21:23:04 -04:00
ty
6dd90aeaef clang-format: -BiosSelectorPanel.cpp -ConfigurationPanels.h
If you need the full paths:
-pcsx2/gui/Panels/BiosSelectorPanel.cpp
-pcsx2/gui/Panels/ConfigurationPanels.h
2021-07-05 22:14:03 +02:00
ty
24e5d909d0 UI: Async bios enumeration
Update pcsx2/gui/Panels/BiosSelectorPanel.cpp

gonna squash this 1sec

Co-authored-by: Silent <CookiePLMonster@users.noreply.github.com>
2021-07-05 22:14:03 +02:00
Ty Lamontagne
2101e17004 Misc: Suppress a warning regarding GetVersionEx 2021-07-05 22:08:48 +02:00
refractionpcsx2
627f216bf7 Core: Reset game CRC when rebooting. Avoids previous games patches being loaded. 2021-07-05 15:43:57 +01:00
lightningterror
1630805fd8 GS-hw: Enable pabe bit only when sw blending is enabled.
Minor optimization.
2021-07-05 13:14:06 +02:00
refractionpcsx2
c77e0a3a56 microVU: Enable T-Bit to work with MTVU 2021-07-05 10:26:50 +01:00
refractionpcsx2
f925c88753 Update gamedb test workflow 2021-07-05 10:26:09 +01:00
refractionpcsx2
973ebd153d microVU: Consolidate I-bit hacks in to one generic one 2021-07-05 10:26:09 +01:00
TellowKrinkle
4116aed738 MTGS: Only pause when the queue is empty
Prevents other threads from freezing waiting for the queue to empty when it never will
2021-07-05 10:25:28 +01:00
arcum42
0f917c24a5 General cleanup of various linux pad code. (#4281)
* Headers cleanup.

* Remove stray Windows code.

* Rename Gamepad.* to Device.*.

* Rename ini.cpp to Config.cpp. Get rid of controller.cpp, moving code to controller.h.

* Change controller.h to Config.h. More cleanup.

* More header cleanup.

* Switch things over to the InputManager. Didn't move the update code there for now.

* Move to pragma once. Move update code to InputManager.

* Reformatted files. Rearranged some includes and defines.

* Not sure how I missed this...

* It's 2021.

* clang-format: make sure the formatting changes are correct

Co-authored-by: Gauvain 'GovanifY' Roussel-Tarbouriech <gauvain@govanify.com>
2021-07-04 19:39:52 -07:00
arcum42@gmail.com
2feaa8adf7 Don't include GS.h twice in a row. 2021-07-04 19:11:59 -07:00
ty
54590a843a Misc: Pattern match to find the bios thread address 2021-07-05 03:17:10 +02:00
lightningterror
91acaa2555 ci: Update pr labelers to match gs merge. 2021-07-05 02:56:37 +02:00
lightningterror
a0dc71378e nsis: Update external shader file names. 2021-07-04 03:09:48 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c19f8f8997 mcd: correctly display osd message 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
bd3918bd64 settings: make emulation settings modal as it changes core state 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d85d02ac02 shaders: rename to fit new defaults 2021-07-03 18:16:11 -04:00
kojin
32c30ad9e4 vs: split target names for avx and avx2 builds 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8dd9af23d4 gs: make sure gspanel close doesn't starve corethread events 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2384a3d172 mcd: make sure to allow two resume in a row
the cleaner solution would be to make our cdvd implementation using
scopecorepausedthread cleaner but I'm probably going to hold off on
doing that until I do some major refactoring because the GS merge is
alreadying getting out of hand
2021-07-03 18:16:11 -04:00
kojin
9814d442cd vs: move the pcsx2 project
Move the pcsx2 project from pcsx2/windows/VCprojects/ to pcsx2/

This is to fix an issue that was causing the intermediate files to go to the wrong directory.
pcsx2/windows/VCprojects/Win32/Devel/../../GS/GS.o -> pcsx2/Win32/Devel/GS/GS.o
2021-07-03 18:16:11 -04:00
kojin
601241b2c7 vs: move the common props 2021-07-03 18:16:11 -04:00
TellowKrinkle
63645de85b GS: Don't include xbyak into everything
Xbyak header is massive
2021-07-03 18:16:11 -04:00
TellowKrinkle
2849f0bc81 GS: Fix some defines 2021-07-03 18:16:11 -04:00
TellowKrinkle
d2d5fcf07a gs: formatting 2021-07-03 18:16:11 -04:00
lightningterror
8281eec60e gs: change screenshot prefix from gsdx to gs. 2021-07-03 18:16:11 -04:00
lightningterror
146b33f120 misc-linux: Cleanup leftover stuff from gs merge for linux build. 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
483f28044b gs: fix freeze on close all windows 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7597ac12b6 gs: ensure the panel doesn't open at all when unneeded 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b06468e268 gs: ensure gspanel is correctly defined as in use when paused 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a3a700eeaf gs: ensure the frame is hidden if not in use 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8d56332993 misc: fix codacy warnings 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
23c0b0f7b1 settings: ensure gs settings are applied on close/make gs sstate 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3ca8ada424 gs: fix avx2 64bit compile 2021-07-03 18:16:11 -04:00
kojin
7040ad9990 gs: workaround failing avx2 compile 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a9d8a7d70f renderswitch: remove delay, fix long standing race condition 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4237ab9925 buildbot: default to non avx2 release 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
db80ff5477 mtgs: fix threading woes 2021-07-03 18:16:11 -04:00
kojin
c73769607e vs: fix some SSE/AVX stuff 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
841d0cfe0e linux_various: remove plugin ldd finder on runner 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d6e39b7ab0 gs: ensure gs has a first try at input handling before pad 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
31c70a7c38 gs: ensure the config file is set correctly 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
edaa8f7817 gs-debugger: fix gsfreeze wrong retval 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8e52dc1e22 gs: ensure closegspanel is closed after suspend, in sysexecutor 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1e84b00126 mtgs: comment the waitforopen reasoning + add closepanel 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ab02bfa7c0 buildbot: compile without plugins 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b70b3382c7 cmake: remove infinite warning spam on clang 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5a4c05607d sstate: make use of mtgs to ensure thread safety when saving 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fa4f4bca73 mtgs: make renderswitch save current state 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ab65f2ab5e gs: port renderswitch to mtgs 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
527e5a8610 gs: gui-windows: fix alignment of swthreads 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e65019a6fc sstate: use structs instead of parallel arrays + enum 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0009ff8853 gs: ensure gsclose is sent from the main mtgs thread and not sysexecutor 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
70a6c59126 gs: update windows ui to fit with pluginless system 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
90a9708619 gs: use sstate freezedata includes 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b5f50f283c gs: make sure the gs panel handler is opened when needed 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
44026aa899 sstate: major redesign, remove split freeze{out,in}, remove gsfreezedata 2021-07-03 18:16:11 -04:00
Kojin
e90fbfe138 vs: explicitly add floating point model back with note 2021-07-03 18:16:11 -04:00
Kojin
848a930e1a vs: cleanup deps 2021-07-03 18:16:11 -04:00
Kojin
2669a31171 vs: clcompile cleanup 2021-07-03 18:16:11 -04:00
Kojin
59e06c8bbd gs: silence a couple warnings 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3ed58ffde0 sstate: bump version 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0542fa527c mtgs: ensure gs is closing when necessary 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d48e4cd138 mtgs: use SysExecutor to route events back to itself for suspend operations 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f020ffabeb bin: remove spu2 replay cmd 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1317f19de2 gs: initial windows port compiles! 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
614ef4a35b gs: continuing on linker errors on windows 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c8524022b7 gs: initial windows port done up to linking issues 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9c77896f2d baseclasses: prevent collision with wxwidgets
surprisingly, GSdx never ran into this issue prior as linux didn't use
baseclasses but used wxwidgets, while windows did but used the winAPI
GUI system. Software is cursed
2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d5abf459bb windows: continue the merge, handle some subprojects linking 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
763533060a gitignore: update to ignore obj files 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8cd2da61c5 windows: remove project references to plugins 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8a7f6c8c01 windows: update the resource pre-build step to remove plugins assets 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
290ca11fc7 gs: update gui to remove logo/references to gsdx 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8281b57c56 windows: make object files relative to their directory so vs isn't drunk with 2 files sharing the same filename 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4803ed0a4e windows: add xbyak as a windows dependency 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3313acac84 windows: add gs filters 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b52063e4e0 gs: remove unneeded windows project files 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2e9349328a gs: begin preliminary windows support 2021-07-03 18:16:11 -04:00
lightningterror
94901f8be3 nsis: Remove remaining plugins (gsdx) and references. 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
06da3a1359 mtgs: fix pesky assert on gs init 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
25af4de320 cmake: remove infinite warning spam 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
80c67e2d48 pad: separate full and per-pad sstate 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9cb0093a1a docs: update them to remove mention of plugins 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
136c326059 pcsx2: clean up references to plugins 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3b56b0340d ftw: remove the plugin panel 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a7ff19ac98 gs: reimplement renderer switch sstate 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
18bc19a09c savestate: remove a bunch of dead code 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a781b4529b gs: ensure coherent use of gsfreeze 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fbf10dcdf5 gs: implement sstate handler functions 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
83a28ddab1 savestate: add back gs sstate 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
70dde551e3 gs: introspect gs state directly 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fa9b30fa9e pcsx2: remove relative imports
gosh that was a pain, please don't make me do that again
2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4f33bfb9f3 gsdump: fix reorder warning 2021-07-03 18:16:11 -04:00
TellowKrinkle
b2da348834 GS: Fix GSVector.h not seeing SSE defines 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e0499b587e gs: remove old logo 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9d4c41e051 gs: pause configuration screen when opened 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
707d2dae71 gs: add back configuration menu 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9422e32f23 gs: ensure avx2 has access to gsvector8 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d2a5e3b675 gs: fix redefinition hell on _d token concatenation 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
727693248d utilities: fix a few omissions when building on nopch 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c1e625cc4b cmake: require XCB libs and not just X11-XCB 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
77b6ce1c27 gitignore: update gs templates 2021-07-03 18:16:11 -04:00
TellowKrinkle
a207abcfc1 ghactions: Add avx2 CI
Needed until we get multi-isa working again
2021-07-03 18:16:11 -04:00
TellowKrinkle
7177bd3597 GS: Disable clang-format to keep alignment 2021-07-03 18:16:11 -04:00
TellowKrinkle
67a5c8e314 cmake: Enable sse4.1 by default 2021-07-03 18:16:11 -04:00
TellowKrinkle
fec12819fa GS: Fix warning spam in macOS 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
08419440f1 license: clarify we are licensing under LGPLv3+ 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
18e892f473 gs: update license headers 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
48aef61027 gui: fix assert with default case unreachable by removing plugin remnant 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b7c0c9589a gs: initial merge complete 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
24b9c5698e gs: initial merge complete up to linking errors 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3a5d1ace91 gs-merge: gui fixups, getting rid of the plugin selector 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4e96ed3e74 gs-merge: initial merge of the gs codebase finished 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
00ed02f831 gs-merge: fix codegen scoping/xbyak misc things for our jit 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3851014634 gs-merge: make sure x11 defines are scoped 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fef8dfd05b gs-merge: make xbyak intrinsics includes scoped, avoid cross project linking with x86_intrin 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
bbcfc0ff1d gs-merge: include hell, scoping, redefinitions 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5f0699d382 gs: xbyak and gs type incompat workarounds for the merge 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fc1e00b7ef gs: trying to sort out this include hell 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b284ab7566 gs: core code and components merged up to gs 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ada56a1c03 mtgs: ensure thread safety, reimplement coreplugins intermediate layer 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
160117ffbb mtgs: switching to a plugin-less architecture 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f04f941dbb gs: continue merge, modify plugin boundaries and expose signature 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e68a3606a9 mcd: finish to remove the remnants of the plugin interface 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
27cb700259 mcd: begin to remove the plugin interface 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f75ae3e046 gs: continue merge, remove plugin selector references 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d272334c71 plugins: cleaning up more plugin cruft, adding a note on freezeData 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9587afc5ed cmake: port glib resources for gs into core 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fd39f14b4e cmake: initial cleanup of the dep lookup 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1893bfe93d gs: initial build system additions 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c87a054b4c 3rdparty: initial addition of xbyak 2021-07-03 18:16:11 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
587a893a0e gs-merge: remove initial plugin subsystem 2021-07-03 18:16:11 -04:00
Ty Lamontagne
fbffa1c7bc Translations: Remove unnecessary warning regarding string length 2021-07-03 20:48:46 +02:00
lightningterror
e3d6e50ba0 pad-linux: Update to latest controller database. 2021-06-29 16:32:51 +02:00
Ziemas
b7dfb2c294 vsprops: Explicitly link setupapi. (#4495)
Currenty it only works because of portaudio linking it with a pragma.
2021-06-27 13:13:05 +02:00
Ilya Trukhanov
3c59221dd1 pad: Fix gamepad choice not affecting rumble test on Linux
The rumble test using either the checkbox or the slider in the gamepad
configuration GUI always causes the first gamepad to rumble, even if
other gamepads are selected in the drop-down menu.
2021-06-26 22:09:38 +01:00
Ziemas
d310ae948d SPU2: Remove SPU2setClockPtr 2021-06-23 14:30:54 +02:00
Ziemas
67cd7713b8 SPU2: Remove cycleptr and read the cycle directly
Seemed like any chance of working without grabbing this straight out of
the iop was given up on anyway.
2021-06-23 14:30:54 +02:00
TheLastRar
f5346129ae DEV9: Clang format pcap_io.cpp 2021-06-22 04:34:50 +02:00
TheLastRar
a333a65419 DEV9: Discard Jumbo Frames from pcap 2021-06-22 04:34:50 +02:00
Jonathan Li
982ef41814 cdvd: Simplify and fix disc variable handling
This fixes an issue on Windows where the previously selected disc drive
choice is cleared if there is no disc in the drive when PCSX2 is opened.
2021-06-20 10:00:31 +01:00
Jonathan Li
7f8ca17752 cdvd:windows: Fix disc path
The disc path was not always in the correct format.

Fixes a regression from the CDVD merge.
2021-06-20 10:00:31 +01:00
lightningterror
33d8290fd4 pad-linux: Update to latest controller database. 2021-06-18 04:40:34 +02:00
TellowKrinkle
f3b17cf021 iR5900: Move recConstBuf memory near recompiler memory 2021-06-18 00:44:02 +01:00
Mrlinkwii
b5a917fb08 GameDB: remove 'OPHFLagHack' for ""Naruto - Uzumaki Chronicles 2" (#4488)
No longer needed.
2021-06-09 18:47:47 +02:00
refractionpcsx2
739787e8c4 Add new hack 2021-06-08 19:07:19 +01:00
Tyler Wilding
d988e8d764 input-rec: Add warning when creating a save-state recording 2021-06-06 17:51:28 +02:00
refractionpcsx2
a6193b0a51 Core: Make DMA's instant during the BIOS 2021-06-05 02:01:10 +01:00
Mrlinkwii
8552090f50 GameDB: Adds VU clamping mode extra to 'Enthusia Professional Racing' (#4478) 2021-06-04 18:03:55 +02:00
TheLastRar
286b6448be DEV9: Always open HDD image as binary
Previously the file was only opened in binary mode if it existed before starting emulation
2021-06-02 20:28:19 +02:00
lightningterror
48961ed3df usb: Fix a few more warnings. 2021-06-02 20:27:50 +02:00
dependabot[bot]
1b4c8991c8 build(deps): bump actions/cache from 2.1.5 to 2.1.6
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.5 to 2.1.6.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.5...v2.1.6)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-31 21:15:59 +02:00
TheLastRar
a35edc95cf DEV9: Clang format DHCP_Server.cpp 2021-05-27 16:07:18 +02:00
TheLastRar
91c2f62c9e DEV9: Fix off by one error with manual DNS1, auto DNS2 2021-05-27 16:07:18 +02:00
Tyler Wilding
7a7f98955b input-rec: Allow configuring the frame advance amount 2021-05-27 16:02:06 +02:00
TheLastRar
3a877a51b5 DEV9: Sleep instead of yield in RxThread 2021-05-27 16:00:07 +02:00
refractionpcsx2
17519c21b4 SPU2: Fix hi def audio streaming 2021-05-27 00:10:33 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ead1243c61 DEV9: ensure DEV9 use wchar ghc 2021-05-26 15:52:21 +02:00
TheLastRar
fad389faab DEV9: Clang Format 2021-05-26 15:52:21 +02:00
TheLastRar
af63023d92 DEV9: GHC related changes 2021-05-26 15:52:21 +02:00
Florin9doi
0b51f09a38 Remove PSX references to distinguish between PS1 and DVR 2021-05-26 15:24:41 +02:00
Tyler Wilding
18abe94e7f ci: Make acceptable values obvious 2021-05-26 15:07:26 +02:00
Tyler Wilding
128eaf5790 ci: Add workflow_dispatch support for Windows debugging builds 2021-05-26 15:07:26 +02:00
Tyler Wilding
bfe0ba7e99 ci: Add an explicit flag to retain Windows debugging artifacts 2021-05-26 15:07:26 +02:00
Mrlinkwii
1bbc51c947 GameDB: Add missing db entries. (#4456)
Official Playstation Magazine - Demo Disc 40'entries, Official Playstation Magazine - Demo Disc 85, Singstar Boy Bands vs Girl Bands, Singstar Take That.
2021-05-26 14:52:39 +02:00
Ty Lamontagne
1097e246a4 Differentiate Impossible block clearing message from IOP & EE 2021-05-26 10:14:20 +01:00
icup321
f90a4871b4 GameDB: Add Kickstart for Rayman Raving Rabbids (#4462) 2021-05-26 10:13:52 +01:00
Nobbs66
e0111195a5 Fix Emulated PSX GPU Version
The PS2 emulates a version 0 PSX GPU rather than a version 2 GPU.  This removes the extra v2 commands
2021-05-21 00:06:16 +02:00
Ziemas
bb09d3fe74 SPU: Make SPU use the MADR from iopHw 2021-05-20 23:50:49 +02:00
Ty Lamontagne
e88f29d3ac Misc: Save ELF last path when auto-running an elf 2021-05-20 23:48:54 +02:00
TheLastRar
084c7db9ac DEV9: Increase min HDD size to 40gb 2021-05-17 14:29:03 +02:00
Mrlinkwii
1af6979e88 GUI: change 'Console to Stdio' to 'Program Log to Stdio'
GUI: change  'Console to Stdio' to 'Program Log to Stdio'
2021-05-17 14:25:59 +02:00
TheLastRar
f28bfa4ad1 DEV9: Correctly populate DNS2 field with DNS2 IP 2021-05-17 14:25:21 +02:00
lightningterror
7efa96c732 pad: Update log that mentioned plugin settings. 2021-05-12 18:20:54 +02:00
Florin9doi
2eb6d9a0fb Eyetoy: Don't send duplicate frames 2021-05-10 17:02:59 +02:00
Florin9doi
02546459ea Eyetoy: Improve logging 2021-05-10 17:02:59 +02:00
Mrlinkwii
b6ac5e3be0 GUI: Updates the 2 smaller icons to the same icon as the main icon used for the program. (#4431) 2021-05-10 16:53:29 +02:00
TheLastRar
bc25ffb52c DEV9: Better align IP fields 2021-05-10 16:24:43 +02:00
TheLastRar
3d1b79464c DEV9: Add internal DHCP Server 2021-05-10 16:24:43 +02:00
TheLastRar
221a8dc530 DEV9: Move reconfiguration code into net.cpp
Also make the internal server aware of the reconfiguration
2021-05-10 16:24:43 +02:00
TheLastRar
36406e2fd9 DEV9: Have each backend use the internal server 2021-05-10 16:24:43 +02:00
TheLastRar
7e35c7750e DEV9: Add shared internal server code 2021-05-10 16:24:43 +02:00
TheLastRar
c1ab094938 DEV9: Add internal server mac and IP 2021-05-10 16:24:43 +02:00
TheLastRar
26b954fdc6 DEV9: Add code for reading packets 2021-05-10 16:24:43 +02:00
TheLastRar
1221b5c271 DEV9: Add message in pcap GetMACAddress() for unsupported OS 2021-05-10 16:24:43 +02:00
TheLastRar
f1f888bd11 DEV9: Report blocks as true for pcap 2021-05-10 16:24:43 +02:00
TheLastRar
869bdb727a DEV9: Move ATA write queue logic into its own class 2021-05-10 16:24:43 +02:00
Tyler Wilding
076d13a7c2 lint: Address Codacy linter findings 2021-05-10 16:23:42 +02:00
Tyler Wilding
109ca396b9 ci: Create GitHub action to validate GameDB when it's modified 2021-05-10 16:23:42 +02:00
Tyler Wilding
ce0395947f ci: Create script to validate GameDB at build-time 2021-05-10 16:23:42 +02:00
Tyler Wilding
551b52922a input-rec: Remove unnecessary externs and resolve linter errors 2021-05-10 16:19:27 +02:00
Tyler Wilding
90938b100c input-rec: Cleanup inputRec namespace 2021-05-10 16:19:27 +02:00
RedDevilus
ee0ebe1c04 PCSX2-GUI: Console log rename and newline 2021-05-10 16:17:23 +02:00
ty
23f727351c Core / VU: Disable MTVU when VU1 Interpreter is selected
Also clean up Config.h a little
2021-05-10 16:15:16 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
133af79c45 CONTRIBUTING.md: removed reference to forums for development(????) 2021-05-10 16:14:25 +02:00
Margen67
704d998c7f CONTRIBUTING.md: Typo fixes, https 2021-05-10 16:14:25 +02:00
lightningterror
e50a4463a5 recording-gui: Add close box to New Input Recording. 2021-05-09 22:59:12 +02:00
macmenot
6a2ed3d078 DEV9: consistently prefix all console output with DEV9:
Around half of the debug and console output from the DEV9 tree already
had this prefix. Adding it everywhere for consistency. Also fixed
misspelling of "Unknown" whilst there.
2021-05-08 17:05:23 +02:00
kozarovv
0ad5680597 FPU: Remove FPU Compare Hack
FULL clamping mode fix games where hack was used, so is no longer required.
This commit remove hack, adjust GameDB according to that change, and rename fpuFloat4 function to fpuFloat3.
Last change is because fpuFloat3 was just wrapper for fpuFloat4 with added check for compare hack.
Additionally fpuFloat2 was only function that called fpuFloat4 directly, so that one call was changed to fpuFloat3 to respect previous changes.
2021-05-08 17:04:09 +02:00
TellowKrinkle
2e0baa7162 Update ghc::filesystem to 1.5.4
Switches to wchar on windows, which allows construction of a path from wchar*
2021-05-07 02:23:04 -05:00
lightningterror
11e08642f3 pad-linux: Update to latest controller database. 2021-05-06 01:19:38 +02:00
RedDevilus
8760214817 clang-format: -pcsx2\gui\AppRes.cpp 2021-05-05 18:10:15 +02:00
RedDevilus
d760ad7293 CDVD-GUI: Swap Browse and Ask before booting + Ask before booting is off by default 2021-05-05 18:10:15 +02:00
Mrlinkwii
0a247868df GameDB: Fix typo causing gamedb not to load (#4417) 2021-05-04 20:13:18 +01:00
Mrlinkwii
15b9e775a1 GameDB: add Nearest EErounding to SSX and SSX tricky. (#4405) 2021-05-04 17:37:26 +02:00
Tyler Wilding
82ce20210f input-rec: Resolve crash when closing emulator involving GUI elements
Gist is we paused the CoreThread without resuming it (input recording would wait until the next VSync), the shutdown routine triggers it when all required window elements are already cleaned up, hence the crash.

Reproduction Steps:
- boot game so gs window is open
- open the dialog for a new input recording, then close it
- close the GS window
- re-open the dialog for a new input recording, then close it
- close pcsx2, should error.
2021-05-04 17:35:41 +02:00
refractionpcsx2
467659200d GameDB: Add patches for Elemental Gerad and K-1 Grand Prix 2006 (SLPS) 2021-05-03 16:13:58 +01:00
RedDevilus
5639273cec readme: Add discord shield
- Discord is more obvious to endusers now with logo and corresponding blue color.

readme: Remove coverity

- Sets discord to white icon and remove coverity because it hasn't been used since 2019 and replaced by codacy.

readme: SSE4 to SSE4.1

- Make it more obvious to have atleast SSE 4.1
2021-05-01 00:34:55 +02:00
Tyler Wilding
07f2459178 github: Remove now redundant comment in PR template 2021-04-29 18:41:34 +02:00
Tyler Wilding
be6b46b793 github: Add first-time contributor message 2021-04-29 18:41:34 +02:00
Silent
bd4d04f914 clang-format: -pcsx2/gui/MemoryCardFolder.cpp -pcsx2/gui/MemoryCardFolder.h 2021-04-28 01:10:24 +02:00
Silent
c27ae16b42 Folder memcards: Suppress "file does not exist" errors for memcard index 2021-04-28 01:10:24 +02:00
Silent
affa24e596 Folder memcards: Remove an unused variable 2021-04-28 01:10:24 +02:00
Silent
52408145c1 Folder memcards: Properly handle zero sized files when writing the memcard index
fileRef is nullptr for zero sized files
2021-04-28 01:10:24 +02:00
Silent
19af887257 Folder memcards: Improve handling of legacy folder memcards (without the index file) 2021-04-28 01:10:24 +02:00
Silent
607b56be97 Folder memcards: Ensure YAML nodes are always referenced by UTF-8 2021-04-28 01:10:24 +02:00
Silent
c7ad748e98 Folder memcards: Write the file index from FlushFileEntries
Resolves issues with flushes being performed out of order,
breaking the intended order of files in the file dictionary
2021-04-28 01:10:24 +02:00
Silent
f8f783737d Folder memcards: Write metadata for directories 2021-04-28 01:10:24 +02:00
Silent
a6cec6a04e Folder memcards: Add an index file to track timestamps and file order
This resolves folder memory card incompatibilities with games assuming
the order of files in the filesystem - e.g. Grand Theft Auto games.
A newly added index file tracks the order in which files would have
landed in the FAT partition and attempts to preserve this order
upon loading.
2021-04-28 01:10:24 +02:00
Silent
8dee1a3e9f Folder memcards: Clean up FolderMemoryCard code a bit 2021-04-28 01:10:24 +02:00
ty
eef643cf63 Core: Purge OS specific CPU usage providers 2021-04-28 01:03:14 +02:00
lightningterror
290183040f gsdx-vsprops: Fix build configuration.
Fixes AVX2 build configuration on VS.
Issue was gsdx would still build as SSE4 instead of AVX2 on AVX2 configuration.

Also remove sse2.props.
2021-04-24 20:07:46 +02:00
lightningterror
ee2890517c gsdx-hw: Cleanup renderer code a bit.
Mark variables as const if applicable, initialize some as well.
2021-04-24 20:05:43 +02:00
lightningterror
46cd43ab9e gsdx-ogl: Cleanup renderer code a bit.
Mark variables as const if applicable.
2021-04-24 20:05:43 +02:00
lightningterror
4ca84e8049 gsdx-d3d11: Cleanup renderer code a bit.
Mark variables as cost if applicable.
Initialize D3D11_PRIMITIVE_TOPOLOGY.
2021-04-24 20:05:43 +02:00
tellowkrinkle
a4bb6234ac Rename main menu back to System (#4362)
There's already a `PCSX2` menu on macOS, adding a second one is incredibly confusing
2021-04-24 08:46:34 -07:00
macmenot
dac2a302ec DEV9: add ATA Idle Immediate (E1) stub
Fixes https://github.com/PCSX2/pcsx2/issues/4358
2021-04-24 14:12:16 +02:00
TheLastRar
72eddb7286 DEV9: Do not apply byteswapping to TX/RX FIFO writes/reads 2021-04-24 14:08:22 +02:00
RedDevilus
f0cdf398a6 pad-linux: Update to latest controller database. 2021-04-24 13:59:20 +02:00
Mrlinkwii
ffb1a3d11e GameDB: Fix errors in GameDB. (#4389) 2021-04-24 13:58:54 +02:00
Mrlinkwii
721253bf49 GameDB: Adds gamefixes for various games. (#4388)
Adds fixes for Energy Airforce - Aim Strike , K-1 World Grand Prix 2006.
2021-04-24 00:45:08 +02:00
Mrlinkwii
526c143eb5 GUI: rename 'show debug' to 'show debugger' and move the create blockdump' option above it above
GUI: rename 'show debug' to  'show debugger' and move the  create blockdump' option  above it  above
2021-04-23 00:17:07 +02:00
Mrlinkwii
4d2f7ae9e2 clang-format : pcsx2/gui/MainFrame.cpp
clang-format : pcsx2/gui/MainFrame.cpp
2021-04-23 00:17:07 +02:00
Mrlinkwii
d7851132c4 GUI: change window to debug and move blockdump to to debug
GUI: change window to debug and  move blockdump to  to debug
2021-04-23 00:17:07 +02:00
refractionpcsx2
6f7890b709 microVU: Fix mistake when setting Status Flag bits for Signed/Zero 2021-04-19 10:55:33 +01:00
dependabot[bot]
d3be481327 build(deps): bump actions/cache from v2.1.4 to v2.1.5
Bumps [actions/cache](https://github.com/actions/cache) from v2.1.4 to v2.1.5.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2.1.4...1a9e2138d905efd099035b49d8b7a3888c653ca8)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-19 08:34:26 +02:00
tellowkrinkle
256afa8b9d clang-format: change alignment settings 2021-04-18 17:39:09 -05:00
Tyler Wilding
770eb0bdaf github: Beef up the CONTRIBUTING file and point people there for best-practices 2021-04-19 00:37:46 +02:00
Tyler Wilding
6e8578ff6c github: Add PULL_REQUEST template 2021-04-19 00:37:46 +02:00
Tyler Wilding
5e585c69ff github: Move CONTRIBUTING file into .github folder 2021-04-19 00:37:46 +02:00
TellowKrinkle
3db5e42b96 GSdx: Add clang-format off/on to parts clang-format breaks really badly on 2021-04-17 05:11:33 -05:00
TellowKrinkle
ae1bc651d6 GSdx: Format 2021-04-17 05:11:33 -05:00
lightningterror
fafbb3cc63 gsdx: Clean up a few warnings. 2021-04-13 02:05:18 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6251c3f8ab gsvector: fix forgotten elif during purge 2021-04-13 02:04:16 +02:00
tellowkrinkle
1e60161932 ghactions: brew update before installing in macOS
Should fix issues with homebrew's old package provider shutting down
2021-04-12 15:04:05 -05:00
Tyler Wilding
6cc969a89c ci: Automatically label pull requests 2021-04-10 20:41:01 +02:00
KrossX
0235bec410 PAD: Just enable pressure on CMD 0x4F 2021-04-10 19:46:30 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
12e9ddfa2b core: change sse4 fatal error to sse4.1 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8a9ec4c706 core: purge sse2 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5509bfc003 spu2: purge sse2 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
48f51b3ce3 gs: purge sse2/sse3 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6bc31a0023 cmake: make sse4 default 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fb1f73fbd4 sln: remove SSE4 from build options, make SSE4 default 2021-04-10 19:16:42 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
970dfb9cfd buildbot: change default target because of sse2 purge 2021-04-10 19:16:42 +02:00
pgert
87daea8a06 GUI > SpeedhacksPanel: textstringcorrections 2021-04-10 13:31:58 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
edeb0d7bd7 ipc: keep previous file socket formatting 2021-04-09 11:30:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1d93cd25e5 ipc: switch to std::string, more readable code + fixes memleak 2021-04-09 11:30:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
80cd65d347 ipc: remove possible memory corruption due to strcat on provided pointer 2021-04-09 11:30:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4a2482e950 ipc: implement MsgStatus 2021-04-09 11:29:58 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
bc6e5213a0 ipc: implement MsgGameVersion 2021-04-09 11:29:58 +01:00
lightningterror
434a06cb72 gsdx-gui: Remove partial and full crc hack levels on release builds.
Normal users shouldn't really need to choose partial or full since
automatic already does that.
Keep the options on debug for testing only.
2021-04-08 21:17:07 +02:00
lightningterror
05a31bd656 pad-linux: Update to latest controller database. 2021-04-07 13:32:23 +02:00
refractionpcsx2
b60765e976 Gif: Remove MTVU spam that isn't required
Solves stuttering in MTVU mode in some games, and gets rid of some annoying asserts which mean nothing.
2021-04-05 04:45:04 +01:00
lightningterror
c61566dec0 misc: Enable GS debugger on CI artifacts. 2021-04-05 00:23:31 +02:00
RedDevilus
0fe9a9535e SPU2: Change default of latency slider
Linux: 300 to 100 (which should be fine for everyone.
Windows: Change the steps to start from 3 and increment on higher numbers instead of 0.5 steps which is just stupid to be that granular.
2021-04-04 23:18:07 +01:00
lightningterror
048356a393 pad-linux: Update to latest controller database. 2021-04-02 05:57:15 +02:00
RedDevilus
7704960e1d GUI-Speedhacks: Grayout Instant VU1 when MTVU is enabled
MTVU checked + Instant VU1 checked = MTVU is on
MTVU checked + Instant VU1 off = MTVU is on
Essentially it doesn’t matter for Instant VU1 be checked or unchecked if MTVU is checked.
MTVU off + Instant VU1 checked = Instant VU1 is on
MTVU off + Instant VU1 off = both are off

Instant VU1 enabled is the old behaviour (so think of it always being enabled in the past). Some games however don’t like this and for those few games they should be off, those kind of games should’ve normally been added as an automatic gamefix or will be in the future.
2021-04-02 00:36:51 +01:00
ty
e36199c499 Misc:Debugger: Support write-only GS priv reads 2021-04-01 16:32:47 +02:00
ty
9ea1610d37 Misc:Debugger: Bios thread view support 2021-04-01 16:30:55 +02:00
Jonathan Li
a6fac1e009 gsdx:windows: Fix incorrect printf specifier 2021-03-27 18:51:17 +00:00
Jonathan Li
157add3eea gsdx:windows: Handle capture dialog filenames properly
The capture dialog filename handling code did not handle non-English
filenames properly.

Fix the filename handling by working in Unicode only and avoiding
unnecessary and incorrect string conversions.
2021-03-27 18:51:17 +00:00
Jonathan Li
d81f236910 gsdx:windows: Handle shader dialog filenames properly
The shader dialog filename handling code had several buffer overflows
and also did not handle non-English filenames well.

Fix the filename handling by storing them as UTF-8 in the ini and
converting them to/from UTF-16 as necessary, and also fix the buffer
overflows.
2021-03-27 18:51:17 +00:00
Jonathan Li
dedd860d40 windows: Add utf-16 to utf-8 conversion function 2021-03-27 18:51:17 +00:00
KrossX
294e54c42b PAD: Add one more byte to umask. (#4305)
Seems to be enough to fix Warriors of Might and Magic.

Increased savestate version since it changes the size of the PadFreezeData struct.
2021-03-26 23:23:03 +01:00
ty
690dae5c17 Misc: Support another bios for the debugger threadlist 2021-03-26 14:26:31 +01:00
Tyler Wilding
72eafeaf40 docs: Hide PDF metadata from rendered markdown in github 2021-03-26 14:24:02 +01:00
Kojin
51253193e0 msbuild: fix libchdr include directory
I don't know what PublicIncludeDirectories is, it's not documented anywhere by MS.
Even if it doesn't fix the bot, it's at least consistent now.
2021-03-25 19:28:56 -04:00
TellowKrinkle
4a55f7b845 Upgrade libchdr
Fixes things getting built as dylibs
2021-03-25 17:12:55 -04:00
lightningterror
bc477e1ce1 pad-linux: Update to latest controller database. 2021-03-23 17:56:18 +01:00
Romain TISSERAND
b436898d2a Formatting: clang-format + copyright headers 2021-03-23 11:06:48 +00:00
Romain TISSERAND
742b829c82 MSVC: fix libchdr integration 2021-03-23 11:06:48 +00:00
Romain TISSERAND
c5196b4ebf cmake: Fix libchdr clang CI faliure 2021-03-23 11:06:48 +00:00
SleepyMan
0599e675a0 CDVD: Add support for CHD format 2021-03-23 11:06:48 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3dc5162079 gsdump: change the location of the settings button 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6c73256196 gsdump: add a settings button; add safety checks for user missing braincells 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d5b312866d gsdump: disable renderer switch keybind on debug 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
cf46e52035 gsdump: simplify a switch case and do-while 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
475e5865d7 gsdump: move all gui porcelains to main thread and code reorg 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1248aa95cb gsdump: make wxwidgets highlight selected packet on debug mode 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ce24c87a3f gsdump: implem debug button functions & disable in release & minimize 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2076b90d92 gsdump: filter fswatcher events & rename the app 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
06fa29678b gsdump: ensure q is printed as float 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
00d680f4bd gsdump: reset state when dump is invalid & ensure you can't run it if started 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d6a671d4ae gsdump: add enter+dclick selection on lv + fix rd crash lifetime switch 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
501225c630 gsdump: force close-shutdown when gsdump is the callee 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f407c5aabd gsdump: switch to Add instead of += overloading, unlink about and gsdump 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d8b52111cf gsdump: remove the list refresh when stopping the dump 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1851595aff gsdump: disable run button when already running 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6249831bb9 gsdump: implement renderer overrides, fix linux GSRT, remove GS assert 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0020568823 gsdump: make our own window, handle close event, make our own vsync timers 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a4e01d4593 gsdump: fix parsing of last packet in non debug mode and code simplification 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3cfc00b355 gsdump: move to unique_ptr & references and fix GS hanging bug 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
49f566dc9f gsdump: add automatic fs watcher for dumps list & remove todo 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4280ee1f0a gsdump: add message when failing to load dump, fix dumps without preview image 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3bb8fcf655 gsdump: various logic and code formatting improvements 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
65291ace12 gsdump: fix crash on shutdown & ui refinement work 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7674545814 gsdump: use automatically initialized vectors 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d86d9f66a9 gsdump: add missing gifreg naming, fix vsync type casting & formatting 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
db2b487247 gsdump: fix casting on vsync type field 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
29356ef465 gsdump: fix windows filters & clear up warnings & unix builds 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
dae36f59d2 gsdump: new freeze definition, the dump now gets correctly loaded in memory 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6840041ee6 gsdump: use correct plugin lifetime callbacks 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9bfc82cfc7 gsdump: switch processing into a thread 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c9201111ab gsdump; packet reg parser finalized and confirmed complete 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3ef92baa74 gsdump: wxwidgets ux improvements 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
423f677264 gsdump: finalize reg parsing, we are theoretically at feature parity 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7412d1ac43 gsdump: finish implement reg tree subparsing 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2068f3fc60 gsdump: implementing some reg packet parsers 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
82c99695d7 gsdump: enum to string mapping thanks to preprocessor magic 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f9ee7e01bf gsdump: vastly simplify string exports & beginning to work on reg browser 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8817e71c99 gsdump: packet browser fields implemented up to prim 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3beb47f8d9 gsdump: implement basics of the packet browser 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
de38219927 gsdump: parse gsdump packets into treeview 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e208c0f8cf gsdump: wiring up buttons 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ca33ccc60e gsdump: debug mode messages implemented 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7c0fc3b777 gsdump: initial implem of standard replay mode done 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
20d825b054 gsdump: initial implementation of gssdump event processing 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d579dc16f1 gsdump: dump fully parsed 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0ba7b18032 gsdump: initial parsing of the dump file 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fa0deffc5d GSDump: implement layout of dump replay 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e94b5f9e54 GSDump: initial implementation of the run feature 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f1df1de64f GSDump: implement dump preview 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1f5c0639b9 GSDump: initial windows port 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
dedd82747a GSDump: add some basic event handling 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d5e8fc6fea GSDump: further painful work on the UI, preview icon added 2021-03-22 23:37:24 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
794ef66392 GSDump: very early draft of the UI 2021-03-22 23:37:24 -04:00
Tyler Wilding
0dffc13e49 gui: Visually indicate the current savestate slot in the load/save menu 2021-03-22 08:40:53 +01:00
TellowKrinkle
9a435c1a7e GSdx: Re-add __forceinline to GSVector functions
Looks like MSVC isn't smart enough to inline things properly
2021-03-22 02:09:31 -04:00
TellowKrinkle
fcee1e5496 GSdx: Don't use constexpr vector constructors at runtime
The MSVC implementation is slow
2021-03-22 02:09:31 -04:00
TellowKrinkle
f8b8b5db13 GSdx: Compiler check for const initialization of vectors
Make sure we don't accidentally end up with a vector-based non-const initialization
2021-03-22 02:09:31 -04:00
Kojin
5ac4b41281 gs: remove some pesky asserts 2021-03-22 02:07:54 -04:00
Silent
68d8840075 USB: Improve Force Feedback test so it doesn't block UI 2021-03-20 23:01:11 +02:00
RedPanda4552
0af847bd29 Change visibility of end of file error
We want this to be visible at all times so ISO damage issues are more visible without enabling advanced logs. Conversely, we don't want this to show up as a big red error, since it is not necessarily a critical error as mentioned in li's comment.
2021-03-20 04:54:38 +00:00
Tyler Wilding
af98432881 ci: Stop caching submodules, no consistent way to detect changes
There doesn't seem to be an obvious way to detect a submodule change.  If the TAG was put inside the `gitmodules` file that would be another thing, but it isn't.  So after a new submodule is added, the cache is never evicted (for instance in this PR's case, where an existing submodule is bumped to a new commit)
2021-03-20 04:20:43 +01:00
Tyler Wilding
b819cfcbe8 cmake: Update minimum {fmt} version 2021-03-20 04:20:43 +01:00
Tyler Wilding
501a714b98 deps: Update {fmt} to 7.1.3 2021-03-20 04:20:43 +01:00
refractionpcsx2
d55ddd4795 GameDB: Elvandia Story, favour full clamping instead 2021-03-19 11:41:16 +00:00
refractionpcsx2
37221a5fe5 GameDB: Add clamp mode setting for Elvandia Story 2021-03-19 09:54:17 +00:00
lightningterror
5e27e6dd78 pad-windows: Fix a couple of warnings, make codacy happy. 2021-03-18 19:28:34 +01:00
ty
0a3f380718 Misc: Support 21 more BIOSes for the Debugger Thread View 2021-03-17 18:32:19 +00:00
ty
794e2e47d0 Debugger: Require emulator start before enabling Break/Run button 2021-03-17 15:39:11 +00:00
ty
e18ee42afc Misc: Fix various DebugTools Codacy complaints 2021-03-16 17:38:54 +00:00
Mrlinkwii
789c619169 Misc: cleanup more MD codacy issues 2021-03-15 15:48:27 +00:00
RedDevilus
ad4a5f9ef4 Misc: Fix regression in templates (#4299) 2021-03-15 13:57:46 +00:00
Florin9doi
b2b8bfc433 Change wheel type to device subtype 2021-03-14 23:29:43 +02:00
lightningterror
f6e12f82de gsdx-hw: Remove Bully crc hack.
Hack breaks a bunch of effects, upscaling issues can be fixed with
texture offset hw hack.
2021-03-14 21:19:02 +01:00
lightningterror
b68e8f059b gsdx-d3d11: Cleanup some gsdevice11.cpp warnings reported on codacy. 2021-03-14 21:08:17 +01:00
lightningterror
8d977d43bb pad-linux: Update to latest controller database. 2021-03-14 20:58:51 +01:00
Pierre GRASSER
be89e23030 GameDB: renamed Rogue Galaxy Director's Cut and added kozarovv's patch 2021-03-13 02:03:06 +00:00
RedDevilus
4840d1db93 Misc: cleanup MD codacy issues
Not the worst issues, we could still block or revise the styling rules where it's complaining.
2021-03-13 02:00:18 +00:00
sonicfind
bb39276ccc Input-recording: Prompt a file dialog when the base savestate can't be located
The chosen file (if one is made in the dialog window) will be saved and used as the base from then on (until the recording is stopped).
2021-03-12 15:58:43 +00:00
sonicfind
a74609d321 GUI: Additonal text and prompts with an active savestate recording 2021-03-12 15:58:43 +00:00
sonicfind
ceb7eaaf47 GUI: Visually alter status bar and Boot menu option while an input recording is active
+ Defines GSPanel method for generating the string keycode for a command
2021-03-12 15:58:43 +00:00
sonicfind
c664a48f26 Input-recording: Add new FirstFrame function
Jumps emulation to the initial state of an active input recording file whether boost or savestate. Makes it easier to reset savestate-based recordings.
* Overrides the Boot ISO/CDVD/Bios menu option.
2021-03-12 15:58:43 +00:00
sonicfind
7b9c8634f4 Capture: Swap int return types with bool
Additionally fix SPU2 error message
2021-03-12 13:22:40 +00:00
sonicfind
df446510da Capture: Introduce audio toggle setting
Allows a user to toggle recording an audio .wav file alongside the video .avi file before capturing.
2021-03-12 13:22:40 +00:00
sonicfind
c60cdbba07 Capture: Optimizations with filenames, audio, and capture mainFrame gui
*Resulting .wavs should get saved in the same location as the video file on linux
*Keep gui capture state consistent regardless of the method used to start recording
*Reworked mainFrame capture menu video options to route to a single toggleCapture_click function
*Split GS & SPU2 recording into start & end functions
2021-03-12 13:22:40 +00:00
sonicfind
1e5e742601 recording: Fix issue with drawing VPads 2021-03-12 13:22:29 +00:00
sonicfind
0a88fe1f3b recording: Remove frameLock check at the end of a frame 2021-03-12 13:22:29 +00:00
sonicfind
d49acfc087 recording: Complete separation of pasuing execution
Unhooks the execution of emulation pausing from pre-set static frame counts
2021-03-12 13:22:29 +00:00
sonicfind
b5b74388f4 recording: Reposition inputRecordingControl function execution in vsync
* No longer calls HandleFrameAdvanceAndPausing() more than once per frame. No need to increment frameCountTracker.
* Splits framelocking into its own function (which could harmlessly get called more than once per frame).
2021-03-12 13:22:29 +00:00
Tyler Wilding
b7d01b4889 gui: Don't check if the backup menu option should be enabled every UI event 2021-03-12 13:22:17 +00:00
Tyler Wilding
717677402c gui: Simplify function and solve unlikely edge-case
If backups are enabled, the .backup file will have already been created via renaming the original save-state. The asynchronous process is dumping the current emulation state, but by the time we've hit this function the rename has already taken place so we have a guarantee.

    This solves a potential bug in the existing code (which probably would have never been hit):
        Save to slot that has no current backup
        Rename fails
        Update method looks for the file without .backup, which is still there.
        Load backup option is enabled despite there not actually being a backup to load.
2021-03-12 13:22:17 +00:00
Tyler Wilding
288c8fedce gui: Enable backup saveslot when game is first loaded, if available 2021-03-12 13:22:17 +00:00
refractionpcsx2
f2525acedf LibSampleRate: Fix configs so Singstar mic works 2021-03-11 10:14:49 +00:00
refractionpcsx2
ec09699fb0 3rd Party: Update Libsamplerate to 0.2.1 2021-03-11 10:14:49 +00:00
Christian Kenny
693de2a9dd IPU: Remove useless define/includes 2021-03-11 10:13:44 +00:00
lightningterror
7d875076e2 cmake: Remove unused dependency logs. 2021-03-09 16:15:58 +01:00
lightningterror
880b93246c pad-linux: Update to latest controller database. 2021-03-09 16:00:46 +01:00
refractionpcsx2
b33321d6c6 GameDB: Added VU0 Kickstart for Ghosthunter 2021-03-07 19:51:47 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d24450f4a9 IPC: Fix type polymorphism & checkbox 2021-03-06 11:13:21 -05:00
TellowKrinkle
862518e7da gsdx: Use constexpr to initialize avx vectors without avx instructions 2021-03-05 17:33:26 -06:00
Tyler Wilding
8117df5644 CI: Add Codacy config file and README badge 2021-03-05 18:57:09 +01:00
ty
cb56b3f76b Debugger: Add "Go to address" for both disasm and memory view 2021-03-05 15:53:33 +00:00
Immersion95
1bb398c6c2 GameDB: Add kozarovv's KOF '94 Rebout - NTSC-J patch 2021-03-05 15:17:29 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1949c586f3 IPC: formatting & typo 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
23897eca23 IPC: windows port 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
df7ee3b166 IPC: add safety warranty on slot numbers 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0142d33d5c IPC: make dialog close when pressing enter 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
52c1d027ee IPC: add the settings dialog 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0be35a3799 IPC: make per emulator configuration a bit easier 2021-03-05 15:15:28 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
119942b7a4 IPC: add slot init 2021-03-05 15:15:28 +00:00
Ignaz Forster
b6246a7ba4 Fix compilation in path with spaces
Compilation with the default settings failed when downloading PCSX2 into
a directory with spaces somewhere in its path:
* In CompileGResources.cmake the paths had been escaped already, resulting
  in double escaping the strings (i.e. embedding them in quotes _and_
  escaping spaces with a backslash. cmake wasn't able to parse the line
  any more.
* In pcsx2/CMakeLists.txt the paths were not escaped, but also not
  embedded in quotes, resulting in an invalid Bash command.
This commit fixes these cases (but is neither a review to find all cases
or making sure other characters such as a newline character would work).
2021-03-02 22:39:26 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a40e6ba693 IPC: avoid deadlocks 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
49dc994351 IPC: specify UTF-8 to avoid variadic traps on wxwidgets 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5ea864f09d IPC: add GetGameUUID 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
30024767ea IPC: add GetGameID 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
593e44ca54 clang-format: AppCoreThread.h 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0dee88e805 IPC: add GetTitle 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5153d9a198 IPC: add LoadState 2021-03-02 11:05:18 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e651147c53 IPC: add SaveState 2021-03-02 11:05:18 +01:00
ty
047e63ee5f GSdx: Switch tooltips to unicode 2021-03-02 00:35:25 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b7bb3daa9d IPC: keep reusing the same socket to avoid windows overfill & better perf 2021-03-01 10:24:42 +00:00
jackun
3f9ea1d01b USB: remove lingering if and lock pulseaudio's recording ringbuffer earlier just in case 2021-03-01 10:07:06 +02:00
RedPanda4552
9cfe1b88fc GameDB: Add improved Xenosaga save crash prevention patch (#4259) 2021-02-28 21:30:57 +00:00
refractionpcsx2
951cce7543 microVU: move the overflow flags to the correct position... 2021-02-28 05:21:18 +00:00
refractionpcsx2
f9d96f55a5 microVU: Remove SSE4 op from Overflow flag checks + clean up the code 2021-02-28 01:20:38 +00:00
refractionpcsx2
cc9c3a2a28 GameDB: Add VU0 Kickstart for Simpsons Road Rage 2021-02-28 00:35:29 +00:00
Mrlinkwii
db4d4ed278 GameDB: Remove patches from lam manger 2003 and flipnic
GameDB: Remove patches from lam manger 2003 and flipnic
2021-02-27 21:38:59 +00:00
lightningterror
dbddc3dd75 readme: Update cpu requierements to minimum sse4. 2021-02-27 21:51:28 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d8f65dc427 GS: switch debug output to the ASCII variant by default 2021-02-27 20:43:40 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f3d31a1946 GS: fix LPARAM casted wchar transformation 2021-02-27 20:43:40 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1cbd959ae8 GS: fix unix compatibility 2021-02-27 20:43:40 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8bfe851446 GS: finish unicode conversion, fix signature inheritance and non wchar external import 2021-02-27 20:43:40 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5917029788 GS: initial switch to unicode 2021-02-27 20:43:40 +00:00
refractionpcsx2
7512c01ca6 GameDB: Removed no longer required FMV skip patches
Games are:
BDFL Manager 2005 (EU)
F1 Racing Championship (Japan and EU regions)
Paris-Dakar Rally (EU)
2021-02-27 06:11:23 +00:00
refractionpcsx2
f42befadf1 SPU: Try to recover DMA pointer after savestate load 2021-02-27 04:10:32 +00:00
Tupelov
e42d506a64 Patch System: Support Little Endian values for non-extended (#4255)
Allows users to use the leshort, leword, and ledouble datatypes inside their patches. Using these datatypes ensures that values in the memory view appear the same as the values in the patch.
This was made with easing patch development in mind as now developers can make patches without having to reverse endianness. This is especially useful when using programs like ghidra who display an instructions bytes in little endian.
2021-02-27 03:38:12 +00:00
kozarovv
9e3fb9f3ce GameDB: Fix KOF98 patches 2021-02-25 20:38:21 +00:00
TheLastRar
3806c93867 DEV9: Don't import pcap_bufsize
This got accidentally re-added in 4b722cc253
2021-02-25 19:40:15 +00:00
refractionpcsx2
4b71dd3c08 GameDB: Remove patches for Quake 3 videos, no longer required 2021-02-25 18:06:15 +00:00
ty
10e995aa06 IOP: Implement memchecks for the interpreter 2021-02-24 18:31:17 +00:00
ty
e1df43703c IOP: Execute breakpoints for the interpreter 2021-02-24 18:31:17 +00:00
ty
b088ee69cd COP0: Preserve read only fields IC and DC in the config register 2021-02-24 17:44:14 +00:00
Mrlinkwii
0a8ac3ba04 GameDB: Add entries for Tourist Trophy demo and GT3 trial (#4246) 2021-02-23 21:25:31 +00:00
lightningterror
2243b56115 spu2: Rename spu2x to SPU2 in some logs. 2021-02-23 18:18:07 +01:00
lightningterror
87eb7f1e1f build-linux: Remove EXTRA_PLUGINS flag.
There are no extra plugins.
2021-02-23 16:45:47 +01:00
KrossX
9db778a1ed Avoid presets from resetting VsyncQueueSize 2021-02-23 15:34:41 +00:00
Romain TISSERAND
7295837135 Build: Drop GSnull plugim
Fixes #4242
2021-02-23 09:19:06 +00:00
lightningterror
513f377a8f pad-linux: Update to latest controller database.
Close #4237
2021-02-23 08:34:11 +01:00
kozarovv
25628d09e6 GameDB: Add patches for KOF series
Fix for Depth precision.
Game fills upper 16bits of depth with 0xFFFF.
This results in a really high 32 bit value which is then converted to float because both hw and sw renderers lack double precision the lower 16 bits of the initial 32 bit value lose precision.
2021-02-23 00:30:29 +00:00
Oschowa
f62636e893 SPU2/SDL: Remove intermediate buffer and write samples directly to the
buffer provided by the SDL callback.
2021-02-23 00:29:58 +00:00
RedPanda4552
c5a243ba43 Prevent Vsync setting from being wiped on preset changes 2021-02-23 00:29:18 +00:00
Christian Kenny
e9e7974b15 Common: Remove obsolete/unused code 2021-02-23 00:28:53 +00:00
refractionpcsx2
e703a7b5b7 IPU: Flush DMA if BCLR called without stopping DMA
* Set VDEC Picture type to I-Picture if none selected in IPU_CTRL
2021-02-23 00:27:47 +00:00
refractionpcsx2
40d9e13334 IPU: Fill Input FIFO on command end ready for next command 2021-02-23 00:27:47 +00:00
Ziemas
32eac3ff13 SPU2: Fix windows 2021-02-23 00:27:33 +00:00
Ziemas
64c526ede2 SPU2: Optimize reverb upsampling
Skip the 0 coefs here as well.
2021-02-23 00:27:33 +00:00
Ziemas
458f22d214 SPU2: Optimize reverb downsampling.
Skip multiplying the 0's
2021-02-23 00:27:33 +00:00
Ziemas
599d25c59b SPU2: Reverb resampling, now upwards as well
Using the same filter as the downsampling
2021-02-23 00:27:33 +00:00
Ziemas
390391e119 SPU2: Downsample reverb input
These filter coefficients come from mednafen, I think they were
originally found by Neill Corlett.

I have not personally verified their accuracy.
2021-02-23 00:27:33 +00:00
ty
bbf248fc46 CDVD: Implement mechacon command 0xEF 2021-02-23 00:22:16 +00:00
Mrlinkwii
d4b1a0daa5 GameDB:corrects various singstar enteries (#4238)
GameDB: Correct and modify SingStar entries
2021-02-23 00:21:49 +00:00
jackun
edf3b43e2f USB: Don't remap R1/L1 to R2/L2 for Driving Force wheel 2021-02-22 14:18:00 +02:00
lightningterror
14edc2246e usb-gui-windows: Better align/position text and buttons.
Could be better.
2021-02-22 13:18:20 +01:00
RedDevilus
398a2dfd30 GameDB: Cleanup names + add new serials
I was expecting to add some more serials to SLUS (NTSC) but it seems to be more well maintained than the SLES (PAL). Most additions are demos but there are some normal full entries . Minor fixups on SLUS and other regions for names.
2021-02-21 21:46:49 +00:00
Romain TISSERAND
7acc51ef67 Fix Linux build not compiling afer commit a37e62337d
Missing include leads to wxTheApp macro not being defined and throw errors (GCC 10, Linux x86_64)
2021-02-21 21:04:46 +00:00
Florin9doi
7e10e4d6eb USB: eyetoy mirroring 2021-02-21 18:38:32 +00:00
lightningterror
7801682377 pad-linux: Update to latest controller database. 2021-02-21 05:46:29 +01:00
jackun
c695a7eabb USB: usb-mic: send 1ms worth of samples for 48kHz and 8kHz sample rates 2021-02-21 04:42:12 +02:00
ty
aa338d234d GSDX: Update OOM message 2021-02-20 18:42:26 +00:00
Nobbs66
1b931172fb PGIF- Fix Castlevania SoTN
PS1DRV handles bit 28 of GPU Status register, not PGIF. This fixes several games.
2021-02-20 17:53:50 +00:00
refractionpcsx2
84913da5b9 GameDB: Added Myst III - Exile patch for EU version 2021-02-20 16:15:33 +00:00
Christian Kenny
c59f1bfea6 SPU2: Add interpolate_table.h to VC project filter 2021-02-20 06:00:15 +00:00
Christian Kenny
993af8c19e SPU2: Purge SPU2Replay 2021-02-20 06:00:15 +00:00
refractionpcsx2
20e2a4055c GameDB: Remove patch for SX Superstar. No longer required 2021-02-20 01:55:19 +00:00
refractionpcsx2
8dcaa48651 GameDB: Patch for Myst 3: Exile IPU timing problems.
P.S. Game totally sucks
2021-02-20 00:31:38 +00:00
refractionpcsx2
ce8047bd8c SPU2: Reset IRQ Status when swapping game in case it got set previously 2021-02-19 10:02:45 +00:00
TheLastRar
4b722cc253 DEV9: Move Windows pcap function list to it's own file 2021-02-17 20:06:54 +00:00
TheLastRar
c121b180be DEV9: Use unique_ptr to manage buffer lifetime 2021-02-17 20:06:54 +00:00
TheLastRar
a8d1a7cba1 DEV9: Inline if in dialog code 2021-02-17 20:06:54 +00:00
TheLastRar
5d111636b4 DEV9: Clang format 2021-02-17 20:06:54 +00:00
TheLastRar
c634f2e6e3 DEV9: Retry if GetAdaptersAddresses() returns ERROR_BUFFER_OVERFLOW 2021-02-17 20:06:54 +00:00
TheLastRar
2473d626d8 DEV9: Don't import Npcap only functions
Comment out functions not present in winPcap
2021-02-17 20:06:54 +00:00
TheLastRar
4507712a72 DEV9: Re-add winpcap bridged 2021-02-17 20:06:54 +00:00
TheLastRar
2e8ca89f3d DEV9: Move Tap's packet verification into NetAdapter
Make pcap use it for addition of bridge mode
2021-02-17 20:06:54 +00:00
TheLastRar
82493343fa DEV9: Only log packets in debug mode 2021-02-17 20:06:54 +00:00
TheLastRar
33b6cbc2a9 DEV9: Use FriendlyName for Pcap adapters on windows 2021-02-17 20:06:54 +00:00
TheLastRar
802c18cb68 DEV9: Remove unneeded functions 2021-02-17 20:06:54 +00:00
TheLastRar
31606db6fe DEV9: Match Win32 adapter with Pcap adapter using GUID
When getting the source mac to generate the PS2 mac
2021-02-17 20:06:54 +00:00
TheLastRar
1144cc9ad9 DEV9: Re-enable windows support 2021-02-17 20:06:54 +00:00
TheLastRar
df6c0b610b DEV9: Add dynamic loader for pcap on windows 2021-02-17 20:06:54 +00:00
TheLastRar
e01bba4525 Deps: Add pcap includes
From Npcap SDK 1.06
2021-02-17 20:06:54 +00:00
TheLastRar
4c287191cd DEV9: Save selected api along with selected ethernet device
Also unified GetNetAdapter()
2021-02-17 20:06:54 +00:00
TheLastRar
e883e93f52 Common: Clang format PS2Ext.h 2021-02-17 15:07:10 +00:00
TheLastRar
a37e62337d Common: Allow calling SysMessage off the main thread on linux
DEV9 uses this when it can't open the selected adapter, and calls it from the EE thread
2021-02-17 15:07:10 +00:00
TheLastRar
6177f89c3f DEV9: Use PS2Ext.h SysMessage() on Linux
We still need to use the narrow char SysMessage() on windows
2021-02-17 15:07:10 +00:00
TheLastRar
81fd8e011f DEV9: Apply settings if configuration was performed during emulation 2021-02-17 14:36:21 +00:00
TheLastRar
0800cdbbc2 DEV9: Merge _DEV9open into InitNet, and check ethEnable before calling 2021-02-17 14:36:21 +00:00
lightningterror
7187b883b0 recording: Fix compilation when DISABLE_RECORDING is defined. 2021-02-12 08:10:46 +01:00
Ziemas
ef6b65afb4 SPU2: Add SPU interpolation option on windows 2021-02-11 21:49:10 +00:00
Ziemas
7f362de7db SPU2: Default to gaussian interpolation 2021-02-11 21:49:10 +00:00
Ziemas
d72a49ad5c SPU2: Add header to build files 2021-02-11 21:49:10 +00:00
Ziemas
4c166eb3e3 SPU2: SPU-style gaussian interpolation 2021-02-11 21:49:10 +00:00
Ziemas
66b2659a47 SPU2: Correct sample index advancement 2021-02-11 21:49:10 +00:00
refractionpcsx2
efe0ceb588 Counters: Add Vsync information to savestates + bump savestate version.
I honestly don't know *why* this wasn't in there already....
2021-02-11 21:34:51 +00:00
lightningterror
02bf212789 pad-linux: Update to latest controller database.
Close #4218
2021-02-09 15:50:44 +01:00
dependabot[bot]
5804af6b6c Bump actions/cache from v2 to v2.1.4
Bumps [actions/cache](https://github.com/actions/cache) from v2 to v2.1.4.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2...26968a09c0ea4f3e233fdddbafd1166051a095f6)

Signed-off-by: dependabot[bot] <support@github.com>
2021-02-08 17:35:23 +01:00
lightningterror
7c072094ae gsdx-hw: Always enable blending if env pabe is 1. 2021-02-06 15:41:10 +01:00
lightningterror
37089065ba gsdx-hw: Implement per pixel alpha blending (PABE).
Fixes Strawberry Shortcake character lighting/face shadow.
Fixes Cartoon Network Racing shadows.

Credits to Kojin.
2021-02-06 15:41:10 +01:00
lightningterror
d993e4ebc8 misc: Update feature request template.
Exclude libretro feature requests.
2021-02-06 15:36:44 +01:00
RedDevilus
0ec98e32d4 GameDB: Add missing Speed Kings patches (#4211)
GameDB: Added Speed Kings patches for ingame hang
2021-02-04 19:45:13 +00:00
Ziemas
d55c611947 SPU2: Adjust interpolation implementations.
These seems to be have been adjusted to match the output of catmull-rom
which is really the one in the wrong by being twice as loud.

As a result of the the interpolated output being at a reasonable level
we can use ApplyVolume to apply the ADSR volume.
2021-02-04 13:02:20 +00:00
kozarovv
f3b6868e51 GameDB: Add missing GoemonTLB Hack 2021-02-04 10:19:34 +00:00
TellowKrinkle
4105fe41fb Pad: formatting
Clang format why
2021-02-04 01:26:37 -06:00
TellowKrinkle
84e0f315ad Pad: fix crash on touching disabled slider in macOS 2021-02-04 01:26:37 -06:00
TellowKrinkle
4890a26ae0 Pad: Don't Destroy() modals
On macOS it prevents the parent window from regaining focus
Also remove OK/Cancel buttons JoystickConfiguration, they already obey the Cancel/Apply/OK of the parent
2021-02-04 01:26:37 -06:00
tellowkrinkle
1470315356 Fix compile of eeProfiler 2021-02-03 20:44:03 -06:00
lightningterror
456ea95794 pad-linux: Update to latest controller database. 2021-02-04 03:34:28 +01:00
refractionpcsx2
de6c1f88dc GameDB: Patch for Dragon Quest & Final Fantasy in Itadaki Street
Fixes missing board items
2021-02-04 01:18:21 +00:00
refractionpcsx2
712a922cc5 SPU2: Make sure cache hits match previous block decoded samples
Caching blocks of ADPCM is a bit sketchy because the previous samples (which it uses to generate the new ones) can change, so you can end up with blips and glitches in the sample stream, this should avoid that problem whilst not making the cache completely unusable.
2021-02-03 16:23:42 +00:00
refractionpcsx2
97ed78109c SPU: Wait 2T when keying on a voice
Just like Delay cycles used to do, but done better and tested on a PS2 to get the correct timings
2021-02-03 16:23:26 +00:00
refractionpcsx2
2415fd3415 SPU2: Ignore LSAL/H Writes after key on if voice sets loop point
Savestate bump again
2021-02-03 16:23:26 +00:00
t o
6a6fd48af9 CDVD.cpp: Cleared old reset from write14. Cleaned up logging and added comment. cdrom.cpp: fixed bad logging statements 2021-01-31 22:14:06 +00:00
kozarovv
983f6e28f5 microVU: Fix Esin opcode
Fix X2 - Wolverine's Revenge
2021-01-31 18:33:01 +00:00
lightningterror
6445af6eb2 dev9: Fix warning, add [[maybe_unused]] attribute. 2021-01-30 19:40:46 +01:00
lightningterror
376e699515 spu2: Fix a few warnings.
Cast DMAICounter to u32, hopefully it isn't negative.
2021-01-30 19:40:46 +01:00
refractionpcsx2
e0394921e9 SPU2: Tighten AutoDMA IRQ timing.
Fixes games which monitor the MADR while transferring.
Tom & Jerry War of the Whiskers was one game that suffered (Jumpy music)
2021-01-30 04:55:28 +00:00
Mrlinkwii
4624d2d175 Update GameIndex.yaml 2021-01-29 19:22:48 +00:00
RedDevilus
541dfdfc7f GSdx-GUI: Fix alignment of font
Should fix invisible characters and move hardware renderer settings 2px down.
Also make the full window and software renderer settings consistent at 2px towards the bottom.
2021-01-27 16:50:10 +01:00
refractionpcsx2
5b5b9cc6c9 SPU2: Fix up ReadInput_HiFi to proceed correctly
Make sure CDDA mode is handled separately
2021-01-27 00:03:09 +00:00
refractionpcsx2
9efcd9a096 SPU2: Improve SPDIF Bitstream Bypass on Core 0, track MADR
Required for GTA Vice City to work
2021-01-27 00:03:09 +00:00
refractionpcsx2
e15807eff8 SPU2: Minor improvements to ADMA Timing 2021-01-27 00:03:09 +00:00
refractionpcsx2
c7267d3665 SPU2: Handle partial ADMA Transfers 2021-01-27 00:03:09 +00:00
refractionpcsx2
7c37e86283 SPU2: Change input area updates for Hifi reads
Remove the no longer required InputPosRead
Bump Savestates
2021-01-27 00:03:09 +00:00
refractionpcsx2
4497532edb SPU2: Improve ADMA behaviour/timing 2021-01-27 00:03:09 +00:00
TellowKrinkle
b9a6dca4b4 i18n: Add window menu to WX string override list
WX's translation has mnemonics on macOS
2021-01-25 18:33:47 -06:00
TellowKrinkle
803bac5da0 macOS: Properly include GameIndex in app bundle 2021-01-25 18:33:47 -06:00
TellowKrinkle
91e8e0d33c macOS:i18n: Include translations in app bundle 2021-01-25 18:33:47 -06:00
TellowKrinkle
5470f7ff5e macOS: Use standard paths
Most macOS users expect applications to store their stuff in ~/Library/Application Support
Documents is protected on newer macOSes and requires users' explicit permission (and also may be cloud synced), and use of ~/ is fairly uncommon
2021-01-25 18:33:47 -06:00
lightningterror
dabfff8b35 gsdx-hw: Get rid of some extra branches/conditions in DATE selection. 2021-01-25 23:17:42 +01:00
lightningterror
e96d316d41 pad-linux: Update to latest controller database. 2021-01-25 09:31:10 +01:00
Ziemas
ff0c9334e6 SPU2: Fix pitch modulation 2021-01-24 03:47:43 +00:00
arcum42
34f665dc7e Deleted assorted unused headers and functions. (#4138) 2021-01-23 08:14:59 -08:00
lightningterror
18da716016 pad-linux: Update logs, db should be updated via upstream only. 2021-01-23 10:01:02 +01:00
jeltaqq
e3c40359d4 Repairing dead links 2021-01-23 06:55:41 +00:00
Mrlinkwii
0689f4bb36 GUI: Fix bios label capitalization. (#4165) 2021-01-21 19:57:25 +01:00
refractionpcsx2
2ffc6b3acd SPR: Wrap transfers which would have read outside of SPR memory 2021-01-20 18:41:04 +00:00
Tyler Wilding
99f8d2fa84 input-rec: Update the GS Frame's freq. properly on enabling/disabling 2021-01-19 04:37:08 +01:00
RedDevilus
cf33fb3ca1 GUI: Address review changes + Fix formatting + Misc fixes
- Change the wxitems to reflect a more appropiate name + change comment to explain the process of Custom hotkeys.
- Cycling savestates are now in the GUI but they are grayed out because it's only used like labels for now.
- The most essential custom hotkeys are now included.
- F8 Snapshot needs some future tinkering but atleast shows up correctly now
2021-01-18 16:40:38 +00:00
RedDevilus
028f468d26 pcsx2-gui: Clang format - pcsx2\gui\AppAccelerators.h - pcsx2\gui\GlobalCommands.cpp - pcsx2\gui\MainFrame.cpp - pcsx2\gui\MainFrame.h - pcsx2\gui\Panels\GSWindowPanel.cpp - pcsx2\gui\Panels\VideoPanel.cpp 2021-01-18 16:40:38 +00:00
RedDevilus
ee54396670 GUI: Implement custom hotkeys
- This will show `default hotkeys` from `PCSX2_keys.ini.default` or based on the `copy of PCSX2_keys.ini` that the user itself added to `inis folder` for changing it `for custom hotkeys`.
2021-01-18 16:40:38 +00:00
RedDevilus
5583a75eac GUI: Keyboard Shortcuts Strings
- This will add extra hotkeys to the GUI. You can look up https://wiki.pcsx2.net/Hotkeys for all of them (not everything is added from there)
2021-01-18 16:40:38 +00:00
RedDevilus
d841f27b25 GameDB: VU0Kickstart for Spartan Total Warrior
Fixes character SPS
2021-01-18 16:33:12 +00:00
ty
cebc531c13 Core: Implement proper %s handling for syscall 117 2021-01-17 18:06:18 +00:00
TheLastRar
b8858663f4 DEV9: Use DevCon/Console log functions & silence some logs 2021-01-17 14:04:45 +00:00
TheLastRar
53dfb8efb9 DEV9: Add missing pch include to linux specific files 2021-01-17 14:04:45 +00:00
TheLastRar
b501a1deae DEV9: Run clang format on ATA code 2021-01-17 14:04:45 +00:00
TheLastRar
dc3bd53f7b DEV9: Allow configuring HDD in UI & add progress UI for HDD creation 2021-01-17 14:04:45 +00:00
TheLastRar
31a3ee3cbc DEV9: Improved SPEED emulation, also hookup ATA emulation 2021-01-17 14:04:45 +00:00
TheLastRar
afc9412191 DEV9: move DMA size correction into DEV9read/writeDMA8Mem
ATA also needs the size correction, so do it in one place
2021-01-17 14:04:45 +00:00
TheLastRar
64bc5409d1 DEV9: support old config files that specify a file name, but no path 2021-01-17 14:04:45 +00:00
TheLastRar
b76abc3550 DEV9: Unicode support 2021-01-17 14:04:45 +00:00
TheLastRar
5640ee8a23 DEV9: Add ATA emulation & Hdd Creator code 2021-01-17 14:04:45 +00:00
TheLastRar
d32b583b3e DEV9: Tweak logging to ease debugging 2021-01-17 14:04:45 +00:00
TheLastRar
e0da758d1b DEV9: Add extra defines 2021-01-17 14:04:45 +00:00
TheLastRar
6c5b63707d DEV9: Fix wrong filter for net.cpp 2021-01-17 14:04:45 +00:00
refractionpcsx2
4f9ec8caa0 CDVD: Increase buffer for DVD_LAYER_DESCRIPTOR
Also added some extra messages if that fails (and not because it's a CD)
2021-01-17 13:45:39 +00:00
TheLastRar
e649ad8241 CORE: Allow ApplySettings to be called on the core thread during emulation
Needed for CDVD to apply gamefixes after a disc swap
2021-01-17 13:45:25 +00:00
TheLastRar
5826be9a74 Core: Attempt to fix CDVD regression 2021-01-17 13:45:25 +00:00
Tyler Wilding
406403cd8e docs: Automatically update links to use the latest tagged release 2021-01-16 21:56:23 +01:00
Tyler Wilding
3f8510eaae docs: Generate PDFs 2021-01-16 21:56:23 +01:00
Tyler Wilding
11eba8738c docs: Minor edits to existing markdown documentation 2021-01-16 21:56:23 +01:00
Tyler Wilding
cd0bda3ab4 docs: Add latex template for generating PDFs
From here https://github.com/Wandmalfarbe/pandoc-latex-template
Licensed under BSD-3-Clause
2021-01-16 21:56:23 +01:00
Tyler Wilding
464031e8d3 docs: Add script for generating PDFs from markdown, add usage info 2021-01-16 21:56:23 +01:00
Ziemas
6c81bb54f7 SPU2: Switch to a more accurate noise algorithm
This algorithm comes from pcsxr and is an implementation of Dr. Hell's
research. It's supposed to be very accurate.

Bumps savestate because of new SPU core struct members.
2021-01-15 21:16:06 +00:00
refractionpcsx2
f5d89062e0 SPU2: Update voices before DMA reads, reset OutPos on reset.
Improves the booting reliability of GTA VC, especially on consecutive boots without closing the emulator.
2021-01-15 20:53:04 +00:00
tellowkrinkle
0f685fbb49 ghactions:macos: Disable homebrew cleanup
Homebrew periodic cleanup and containers don't mix well, as the "every 30 days" turns into "every time", ends up wasting 1-2m of build time
2021-01-15 04:42:01 -06:00
tellowkrinkle
de3bb1b39d Fix usage of brew --cask
I guess it didn't like that
2021-01-14 23:23:56 -06:00
lightningterror
ade09b0630 pad-linux: Update to latest controller database.
Close #4137
2021-01-14 16:30:43 +01:00
refractionpcsx2
1e7b6d6dbe GameDB: Patch for Hot Wheels - Velocity X SPS issues. Fixes #4139 2021-01-14 10:10:38 +00:00
tellowkrinkle
23d436237c ghactions:macOS: Use brew --cask
brew cask was deprecated and later disabled, breaking our builds
2021-01-14 03:59:27 -06:00
refractionpcsx2
9f12d3a380 Counters: Remove additional Pad update for now, seems to break USB somewhat. 2021-01-14 08:11:43 +00:00
jackun
618940d78c USB: skip extra audio endpoint descriptor data so it doesn't get parsed twice 2021-01-14 09:04:31 +02:00
refractionpcsx2
538e5691f0 PAD/Counters: Make VSync Queue adjustable in the UI. Extra Pad update.
New UI option (ini option has been there a while) so users can choose between a little bit extra performance or better input lag. Also added the PAD Update to the VSync call in Counters as it seemed to improve Input lag marginally.
2021-01-13 23:50:38 +00:00
refractionpcsx2
9e23d15d51 GUI: Adjust description of DMA Busy hack 2021-01-13 14:22:07 +00:00
refractionpcsx2
f21fbc24cf GameFix: Modify how DMA Busy hack works
In IPU cases, it allows writes depending on what it's doing, in the case of other channels it waits until the transfer has finished.
2021-01-13 14:22:07 +00:00
jackun
efed4a07ef USB: safe_release dshow filters
Pausing/resuming could cause double-release.
2021-01-12 00:07:16 +02:00
ManDude
0d02d1e41b GameDB: Add korean Crash Bandicoot The Wrath of Cortex 2021-01-11 20:54:15 +00:00
TheLastRar
d6575ed267 GameDB: 'Network Access Disc & Hardware - Online Arena' needs InstantVU1 2021-01-11 20:32:19 +00:00
Tyler Wilding
9031c24fc7 ci: Improve windows artifact name
Add PR title if applicable, limit the length of the file to avoid file-name length issues.
Also put all contents of the artifact into a folder with the same name to simplify extraction.
2021-01-11 03:51:09 +01:00
refractionpcsx2
89991594de Vif: Clean up some old (incorrect) code. 2021-01-10 11:02:19 +00:00
refractionpcsx2
8ec4e40ae1 GameDB: Add missing rounding for Guitar Hero Metallica (US) 2021-01-10 11:00:46 +00:00
refractionpcsx2
262d36f49a GameDB: Added WRC patch by kozarovv to fix SPS 2021-01-10 10:33:44 +00:00
Pierre GRASSER
ec7116f2ed rawinput_usb.cpp: removed unused WM_ACTIVATE/SETFOCUS/KILLFOCUS logging (#4121)
* rawinput_usb.cpp: removed unneeded WM logging
2021-01-09 17:01:12 +00:00
TheLastRar
9468b04713 DEV9: adjusted logic for loading default MAC
Now a little less confusing
2021-01-09 00:06:29 +00:00
TheLastRar
5cdb6dcb12 DEV9: Replace pcap not supported messagebox with console log 2021-01-09 00:06:29 +00:00
TheLastRar
bae445d9d2 DEV9: Generate unique MAC for TAP, much like pcap backend does 2021-01-09 00:06:29 +00:00
TheLastRar
5f2441e832 DEV9: Move writing generated MAC out of winpcap 2021-01-09 00:06:29 +00:00
RedDevilus
275f5bd744 PCSX2-GUI: Move blockdump to game settings
Blockdump gets a bit too much love which hampers with playing normally.
2021-01-08 23:59:13 +00:00
TheLastRar
4aaf55b4b7 Core: Clang-format AppCorePlugins.cpp 2021-01-08 23:54:30 +00:00
TheLastRar
acd7fa90ef Core: AppCorePlugins.cpp add missing const 2021-01-08 23:54:30 +00:00
TheLastRar
0192c538ee Core: Resume plugin if suspended for configure
SysExecEvent_SaveSinglePlugin would close the plugin, but not reopen it
2021-01-08 23:54:30 +00:00
KrossX
aed639bb20 Declangify parity tables 2021-01-08 23:47:11 +00:00
KrossX
5fe01f0149 Format documents using Clang-Format 2021-01-08 23:47:11 +00:00
KrossX
3a054b9f91 Avoid malloc when converting to RAW 2021-01-08 23:47:11 +00:00
KrossX
511ceede3b Add support for OpenPS2Loader VirtualMemoryCards 2021-01-08 23:47:11 +00:00
Maxim Nikitin
7dbf01b024 Implements IOP breakpoints (#3011)
IOP: Implement IOP Breakpoints
2021-01-08 23:34:08 +00:00
RedDevilus
170d1cb94c GSdx-GUI: Conservative Buffer Allocation + GPU Palette Conversion + Misc fixes
- Conservative Buffer Allocation will be enabled by default.
- Unscaled has a lesser visual impact but will be moved to the middle so it is more consistent with the other options in the GUI.
- Monitor will hence be named Statistics Monitor which makes it more obvious that it's similar to RivaTuner Statistics Server.
- The monitor will print the stats of the emulated components EE (roughly CPU-usage) , GS (roughly GPU-usage).
- Make room for the new checkboxes with revision of names and tooltips.
- GPU (color) Palette Conversion instead of 8bit textures (the name didn't make much sense).
2021-01-08 08:51:13 -05:00
Ziemas
1f236cab75 Folder memcards: prevent out of bounds access 2021-01-07 15:17:04 -05:00
refractionpcsx2
95e7045db7 PortAudio: Upgrade PortAudio to latest master 2021-01-07 08:55:13 +00:00
TheLastRar
f45f8c9479 DEV9: Support 16bit reads/writes to SPD_R_PIO_DATA & SPD_R_PIO_DIR
Using the same code as 8bit reads/writes
2021-01-06 17:58:58 +00:00
iwilliamson
1ad5711b63 build: Update mscompile.cmd to build with VC2019. (#4084) 2021-01-06 17:48:58 +01:00
Tyler Wilding
06cf30019b gamedb: Delimit memcard filters with '/' instead of ',' 2021-01-05 23:19:59 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7a1ee439d2 README: add discord 2021-01-05 09:27:10 -05:00
refractionpcsx2
f1e44bfd47 SPU2: ADMA fix for Vice City
TFW you revert using the wrong variable..
2021-01-04 17:11:54 +00:00
lightningterror
89a33c0ab3 misc: A couple of more leftovers from SPU2 merge. 2021-01-04 02:07:30 +01:00
refractionpcsx2
a8aeeb5a6a SPU2: Change how ADMA gets cancelled, IOP handles cancelling DMA
Fixes Raw Danger
2021-01-03 23:18:29 +00:00
refractionpcsx2
a679766740 Counters: Adjust SPU async rate
Back to original value, however modified how the next SPU2 sync value is applied
2021-01-03 23:18:29 +00:00
refractionpcsx2
f5e50d4571 SPU2: Fixes for Titeuf buzzing 2021-01-03 23:18:29 +00:00
refractionpcsx2
5cf5f40c65 SPU: Fix bugs in recent commits, redesign DMA slightly
Savestate bump, sorry
2021-01-03 23:18:29 +00:00
refractionpcsx2
ddffd9acd6 VIF: Fix MPG VU Address wrapping, fixes Boogie (works for the first time)
Thanks to deus-libri for spotting that one!
2021-01-03 21:47:55 +00:00
refractionpcsx2
bc9892d324 GameDB: Corrected patch for Titeuf Mega Compet to fix game bug 2021-01-03 21:29:59 +00:00
refractionpcsx2
0f7044a90f mVU: Removed full flag optimisations
They were unused, broken and cluttering up the code, so gotten rid.
2021-01-03 16:17:19 +00:00
refractionpcsx2
c9bc6eac69 mVU: Fix P flag instance on Ebit
Also small fix for flag statuses on M-Bit on Branch
2021-01-03 12:03:55 +00:00
Timothy O'Barr
bfdfc495a3 Add GHC Filesystem (#3999)
Adds GHC filesystem to 3rdparty deps and updates cmake and vs project accordingly.
2021-01-02 13:47:09 -05:00
lightningterror
faf147d029 pad-linux: Update to latest controller database. 2021-01-02 18:49:21 +01:00
Kojin
6bcdb55f22 GS: Remove Unofficial CRCs (#4082)
* Remove ArTonelico2 Retranslation CRCs

* Remove Wild Arms and ToA undub CRCs

* Remove unused Star Ocean 3 Undub CRC
2021-01-02 11:11:13 -05:00
refractionpcsx2
413fd004da mVU: Fix jump caching when using doJumpAsSameProgram. This is by default 2021-01-02 08:35:32 +00:00
refractionpcsx2
ee07f860fc microVU: Implement Overflow checks. Fixes Superman Returns
Removed patches for Superman Returns
2021-01-01 20:55:11 +00:00
refractionpcsx2
af89879750 SPU2: Attempt 96khz sample rate if 48khz fails 2021-01-01 04:54:29 +00:00
refractionpcsx2
a94561fba7 SPU2: Improve DMA Write timing. Better sync DMA speeds with IOP
It takes 4 cycles per word, according to No$PSX documents
Also fixed an issue with when ADMA refills the buffer, fixes The Simpsons (for real this time)
2021-01-01 04:38:23 +00:00
refractionpcsx2
f07ca859e5 SPU2: Improve DMA/IRQ timing.
Tighten SPU2 sync with IOP
2021-01-01 04:38:23 +00:00
refractionpcsx2
b7f5404062 GameDB: Remove FMV skip patches no longer required 2021-01-01 04:38:02 +00:00
refractionpcsx2
a8a5d4bca9 IPU: Return contents of the bottom of the FIFO in CMD except FDEC/VDEC 2021-01-01 04:38:02 +00:00
refractionpcsx2
c998a51f71 IOP DMA: Only acknowledge SPU2 DMA interrupt if DMA hasn't been cancelled
Fixes Gregory Horror Show bad audio
2020-12-30 05:58:24 +00:00
Christian Kenny
3b771a6a94 PAD (Windows): Remove code for fullscreen and resizing the game window. Also removed code that modified the titlebar text on the output window. 2020-12-30 04:31:59 +01:00
refractionpcsx2
3d3c039596 SPU2: Fix Address masks for voices + Effect area
Fixes reverb in The Suffering
2020-12-30 01:13:52 +00:00
refractionpcsx2
2859123c47 MTVU: Actually add MTVU to savestates
On loading a savestate, restore the VIF state on the MTVU side
2020-12-29 23:15:39 +00:00
sonicfind
c278e6414c recording: Improve NewRecordingFrame window
* File browsing will be required when creating a new input recording if at any point the filename box is empty.
* Removes the "Current Frame" selection if GS is closed. Corethread check in InputRecordingFile::openNew() no longer necesaary.
2020-12-29 22:59:55 +00:00
sonicfind
a6b2d30bd0 recording: Internalize VirtualPad Windows
* Hold virtualPad window pointers solely in the g_inputRecording object
* Only inits the windows once per session and only if recording options are enabled
2020-12-29 22:59:55 +00:00
sonicfind
acb61a3cf2 recording: Disable create & play options until a game is loaded at least once
Ensures no frames are skipped on an initial load of a input recording before booting a game first.
2020-12-29 22:59:55 +00:00
sonicfind
3f359147c8 recording: Fix console logging for file read and write errors 2020-12-29 22:32:15 +00:00
sonicfind
a1b6f0b76a recording: Log all PadData and draw all VirtualPads altogether once per frame
Fixes improper virtualPad behavior for games that do not check for button pressure values (ex: Sonic Mega Collection Plus)
2020-12-29 22:32:15 +00:00
sonicfind
ca5d78e7a5 input-recording: Re-place "replaying" osd log 2020-12-29 22:10:20 +00:00
sonicfind
7431a18bbe input-recording: Wait for savestate confirmation on initial load
* Required splitting some recording menu-related code into separate public functions to work most efficiently.
2020-12-29 22:10:20 +00:00
refractionpcsx2
c9a5443539 VIF: Slightly optimise when Row/Col are written to MTVU 2020-12-28 19:01:17 +00:00
refractionpcsx2
e8c91f0537 MTVU: Stop the buffer filling up when MTVU is disabled 2020-12-28 18:40:07 +00:00
RedDevilus
8190379519 GameDB: Cleanup comments
Adding punctation, removing duplicate serial and making english language more happy for reading.
2020-12-28 14:52:08 +01:00
TellowKrinkle
4ffc0d2247 MTVU: Allow stacking of LABEL 2020-12-28 02:12:52 -06:00
TellowKrinkle
3c2f7983a5 MTVU: Cleaned up GS SIGNAL/LABEL/FINISH communication 2020-12-28 02:12:52 -06:00
Mrlinkwii
527ba52dec Update GameIndex.yaml 2020-12-26 22:57:27 +00:00
Florin9doi
17d5f8985d USB: Improve some cryptic warnings. (#4046) 2020-12-26 12:43:03 +01:00
lightningterror
232c4b482a tools: Remove GameIndex.dbf-tool.
Deprecated with yaml db, maybe a new alternative can be made in the
future.
2020-12-26 11:09:38 +01:00
lightningterror
657ce60ff8 pad-linux: Update to latest controller database. 2020-12-26 11:04:28 +01:00
refractionpcsx2
839b243bf1 VIF: Always update MTVU thread with Row/Col Changes
Fixes graphical issues in Fatal Frame 2 when swapping to MTVU
2020-12-25 00:57:37 +00:00
jackun
9534b2af1d USB: Early return from FF test in case of failure 2020-12-24 21:57:01 +02:00
TheLastRar
b8406a5b95 DEV9: Tap, remove empty blocks 2020-12-24 17:34:26 +00:00
TheLastRar
b097ca9979 DEV9: Tap, make GetOverlappedResult calls one line 2020-12-24 17:34:26 +00:00
TheLastRar
54651731f9 DEV9: Cancel read of TAP device on suspend/shutdown
CancelIo() must be performed on the thread that started the IO operation, hence the use of an event.
2020-12-24 17:34:26 +00:00
Silent
f19985c410 USB: Remove "Bypass Startup Calibration"
It wasn't hooked up to anything
2020-12-24 17:23:17 +02:00
Silent
2c1ebae039 USB: Misc code cleanup 2020-12-24 17:23:17 +02:00
Silent
a1f213cfd0 USB: Slightly decrease strength of FF Test
Right now it can be a bit too strong
2020-12-24 17:23:17 +02:00
Silent
d65c4c1892 USB: Set FF gain for a device, not effects, apply settings before Test
Fixes Test not using new settings until the next time the setting dialog
is opened, also simplifies changing Gain
2020-12-24 17:23:17 +02:00
Silent
2465b0e278 USB: Pass a top-level window to DirectInput
Fixes Force Feedback not initializing properly
2020-12-24 17:23:17 +02:00
refractionpcsx2
fa18568d62 GS: Properly mirror GS reads to CSR 2020-12-24 10:56:36 +00:00
refractionpcsx2
d78de3237c MTVU: Redesign of how to handle signals, seems more reliable
Added new variables to savestates
2020-12-24 09:03:45 +00:00
refractionpcsx2
6066f48d7c MTVU/GIF: Clang Formatting 2020-12-24 09:03:45 +00:00
refractionpcsx2
20695d6b15 MTVU: Add new savestate variables, bump savestate version 2020-12-24 09:03:45 +00:00
refractionpcsx2
3f4bb44310 MTVU: Improve compatibility with games that do GS SIGNAL/LABEL/FINISH 2020-12-24 09:03:45 +00:00
jackun
4ab7d78574 USB: Fix Seamic "failing" to load Singstar api 2020-12-24 03:56:52 +02:00
RedDevilus
74336d952d SPU2: Change VolumeSteps 42 to 5
This will change the PageUp/PageDown and also to clicks near/far but still on the slidebar and the jumps are changed from 42 to 5 , scroll wheel will still be 2 and all the arrows keys on 1. If you click and hold and  then move just outside of the slider you now get nice jumps of multitudes of 5. Dragging the slider will not be affected.
2020-12-23 22:51:18 +00:00
jackun
ade01ecb86 USB: HID: fix E0/E1 keys not sending "pressed down" event, like arrow keys etc.
RAWKEYBOARD::Flags actually _is_ a bitmap for a change
2020-12-23 19:54:00 +02:00
jackun
91d4c4aa37 USB: make dev_index u32 for simpler check if it is valid 2020-12-23 19:54:00 +02:00
jackun
17cbb835ce USB: load main settings once per startup and remove "configChanged" boolean
Let save state loading override currently selected devices
2020-12-23 19:54:00 +02:00
jackun
b2bf0301bb USB: skip parsing inputs if HID device type doesn't match
Kb/mouse event handler pointers are in the same union in HIDState struct
and overlap other variables so not usable for checking validity.
2020-12-23 19:54:00 +02:00
jackun
7a5f9e80e7 USB: remove BUILD_RAW and CALLBACK define 2020-12-23 19:54:00 +02:00
jackun
b5e561e68f USB: restore qemu hid event handler after savestate load 2020-12-23 19:54:00 +02:00
jackun
b3b272e2e2 USB: Use PAD's WndProcEater for raw input, don't reinit raw input, check WM_ENABLE
Skip reinit when swapping discs or it probably hooks dinput8 wndproc causing recursion.
If swapping discs, use WM_ENABLE to signal we have focus again.
2020-12-23 19:54:00 +02:00
jackun
df5cfb303b USB: lock raw input callbacks when adding/removing 2020-12-23 19:54:00 +02:00
jackun
191ebbcacf USB: close devices before destroying and loading save state and just allocate 64KiB for save states
USBfreezeData itself is currently ~20K so maybe 64K is enough
2020-12-23 19:54:00 +02:00
orbea
44b700a6fd cmake: Use GNUInstallDirs. 2020-12-23 01:04:26 +01:00
refractionpcsx2
97b74fa6ea VIF: MSCNT address is -1, so don't mask it. 2020-12-22 14:55:03 +00:00
refractionpcsx2
843650e79e VIF: Mask VU program address on MSCAL/MSCNT instructions 2020-12-22 14:12:27 +00:00
refractionpcsx2
a4553e821f VIF: Allow VIF1 to continue if stalled and the FIFO is reversed 2020-12-22 09:20:03 +00:00
Christian Kenny
2c7f54134e GameDB: Add GIF FIFO Hack for Fight Night Round 3. Fixes corrupted textures. 2020-12-19 23:57:53 +00:00
jeltaqq
7287dce376 GameDB: Porting patch and add Idea Factory games (#4025)
GameDB: Add patches for Idea Factory games
Ported Neo Contra and Savage Skies patches to NTSC-J
2020-12-19 17:04:05 +00:00
Christian Kenny
3143a46e4d GameDB: Add VU0 Kickstart for King Kong. Fixes bad polygons on characters 2020-12-18 23:12:33 +00:00
refractionpcsx2
155cf385bd microVU: Flush running VU1 program when toggling MTVU on 2020-12-18 20:55:02 +00:00
Kojin
ce332571dc core: fix speedhacks panel (#4007) 2020-12-18 14:22:47 -05:00
lightningterror
6a7648d2b0 misc: Cleanup remaining pad stuff from merge. (#4014) 2020-12-18 00:48:33 +01:00
refractionpcsx2
ee890c508e BIOS/CDVD: Set language defaults instead of making the user do it.
Removed message nobody read.
2020-12-17 22:56:42 +00:00
lightningterror
10afd0b684 pad-linux: Update to latest controller database. 2020-12-17 11:05:37 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
38c03ecbbb PAD: review & formatting fixes 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d8884e3a2f PAD: fix regression on MTGS scheduler close 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
80e379820d PAD: formatting fixes for linux 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d3b120fafd PAD: fix quick setup and probably other issues 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
02c028d14f PAD: ensure auto generated resources are not in the source tree 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5769ae3e78 PAD: formatting fixes 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b941d16f78 PAD: windows: fix pad reloading when core actions are done 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b8cedae527 PAD: windows: fix DInput 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
913cb296b4 PAD: windows: fix error message when uninit 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c4abe44e67 PAD: windows, fix crash on config when playing 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2c5b75a695 PAD: windows, pause config when in game and make sure it opens 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3e0f9d3931 PAD: bump sstate version on windows subsystem 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
dc5e4e61c5 PAD: fix ini on windows 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
093e19aae6 PAD: windows: fix RTL_CRITICAL_SECTION nullptr 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
83e6ecb5af PAD: s/Lily/PAD/g + logging changes 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8067a480c7 PAD: windows: clang-format 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9cdc963c97 PAD: windows: update copyright headers 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f38c132efe PAD: s/OnePad/PAD/g 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
cd70ba753e PAD: initial windows merge complete 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a0c18d97fd PAD: backport macos patches 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d05c4e60be msvc: disable warnings on 3rdparty 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
494e384d9e msvc: disable /Gm as it is deprecated 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2b4e73e885 PAD: windows merge relatively complete, linker issues left 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ce7fbe6398 PAD: windows sstates support 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
afef852609 PAD: windows removal of callbacks, merging with linux api 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7d5066bc3c PAD: windows merge pch fixes, continuing 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
140f2fc0dd PAD: continuing windows merge 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d1c6b6b789 PAD: fix macos build 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c6d6865bb9 PAD: fix nopch builds 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a9da983d02 PAD: ensure gamepad works on linux 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
eed1e4fe8a PAD: beginning windows initial merge 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a90d588167 PAD: fix ini saving 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8f7b9f609f PAD: sstate support 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
82f7a23be4 PAD: clang-format 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2e0be1f75a PAD: add back config screen, pause core when opened 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6df4fea079 PAD: implement lifecycle callbacks 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
84f838aab0 PAD: update copyright headers 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e47aa28af9 PAD: linux initial merge complete 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1703e9f8d9 PAD: more work on resources compilation, linker issues left 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
69e837c1ea PAD: initial merge relatively complete, linker issues left 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
913bb359a0 PAD: continuing merge, debugging lexer bugs 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a691abc630 PAD: continuing merge, header/export port 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
93fba0a8e7 PAD: include back resources generation 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
85231dfca6 PAD: add back some initial references 2020-12-17 09:38:21 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
01b210f42a PAD: remove initial references 2020-12-17 09:38:21 +01:00
Quinton Clark
0e13200911 gui: Apply missing recording menu option disablers. (#4001)
Fixes recording keybind menu options not disabling when pause is selected or when the ESC key is used.
2020-12-17 07:12:23 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
37b8819fc5 formatting: remove editorconfig 2020-12-17 07:05:19 +01:00
tellowkrinkle
66ed78f2c8 x86emitter: fix order of operations mixup 2020-12-16 23:40:14 -06:00
lightningterror
406ef3741c nsis: Fix uninstall path for GameIndex. 2020-12-17 05:52:58 +01:00
Tyler Wilding
e168b00ee0 GameDB: Move the documentation file one last time 2020-12-17 05:09:11 +01:00
Tellow Krinkle
1a727febe9 x86emitter: Remove unused classes
xAddressInfo was not being used
xSmartJump was not being used and is incompatible with x86-64
2020-12-16 20:31:19 -06:00
Tellow Krinkle
096bb8bf74 x86emitter: Remove virtual methods from register types
Allows methods to generate variable-sized registers
2020-12-16 20:31:19 -06:00
orbea
f33a6076dc cmake: Fix the install target. 2020-12-17 03:15:28 +01:00
Florin9doi
bf8fb7bad6 Resolve a crash when EyeToy is opened the second time (#3972)
* Resolve a crash when EyeToy is opened the second time

* Replace NULL/0 with nullptr

Co-authored-by: Florin9doi <Florin9doi@users.noreply.github.com>
2020-12-17 01:29:14 +02:00
Tyler Wilding
271f60b65a NSIS: Updated filepath from old GameDB 2020-12-16 22:42:57 +00:00
Tyler Wilding
c90eec2814 GameDB: Move the documentation file out of /bin 2020-12-16 22:42:57 +00:00
Tyler Wilding
57c7e56203 GameDB: Fix incorrect parsing around round and clamp modes 2020-12-16 22:42:57 +00:00
refractionpcsx2
7b7278bc85 VIF: Fix MPG bug incrementing addresses properly when using MTVU
Also handle wrapping
2020-12-16 14:04:54 +00:00
Tyler Wilding
4d79754f78 GameDB: Follow the same pattern for Speedhacks as for GameFixes
In preparation for #3998
GameDB: Update with current master's GameDB file
2020-12-16 09:31:58 +00:00
Tyler Wilding
34fe57d84b GameDB: Support case-insensitive serials and patch CRCs like existing GameDB impl.
GameDB: Regenerate with master's .dbf file


GameDB: Update with master's latest changes
2020-12-16 09:31:58 +00:00
Tyler Wilding
4b975efa23 GameDB: Hopefully resolve possible unicode filepath issues
GameDB: Big cleanup as a result of review feedback
2020-12-16 09:31:58 +00:00
Tyler Wilding
e90046d8a2 GameDB: key patches by their CRC or default to prevent duplicates
GameDB: Regenerate GameDB file


GameDB: Fix typos in gamefix names
2020-12-16 09:31:58 +00:00
Tyler Wilding
279dfd741a lint: Clang Format files 2020-12-16 09:31:58 +00:00
kenshen112
5ef141187a GameDB: Address string related compiler errors on linux 2020-12-16 09:31:58 +00:00
Tyler Wilding
39a4d3ce4e GameDB: Typo / remove debugging code
GameDB: Remove unneeded include
2020-12-16 09:31:58 +00:00
kenshen112
3f6193580c CMake: Add yaml-cpp to cmake 2020-12-16 09:31:58 +00:00
Tyler Wilding
18ea20e7b0 GameDB: Add markdown documentation for GameDB
cmake: Add yaml-cpp to cmake
2020-12-16 09:31:58 +00:00
Tyler Wilding
dc52ec7aec GameDB: Detect and skip patches with duplicate CRCs 2020-12-16 09:31:58 +00:00
Tyler Wilding
b800ed0a10 GameDB: Fixed invalid GameFix instances using new validation process
GameDB: Delete the .dbf file
2020-12-16 09:31:58 +00:00
Tyler Wilding
df1a8e8667 GameDB: Beef up the validation and finish refactor
GameDB: Regenerate with current master's file
2020-12-16 09:31:58 +00:00
Tyler Wilding
9fa484dbab GameDB/MSVC: renamed _Target_ to _InstrucTarget_ to avoid collisions 2020-12-16 09:31:58 +00:00
t o
b102134ae3 GameDB: Fixed return and added include 2020-12-16 09:31:58 +00:00
Tyler Wilding
675a60b3d4 GameDB: Add new GameDB implementation
vendor new yaml file, this one is OUT OF DATE!


Resolve a slew of compiler errors


Down to just the weird _Target_ usage in 5900.cpp
2020-12-16 09:31:58 +00:00
refractionpcsx2
03445d0b55 microVU: Add sanity check when loading quick block from program.
Sometimes (CoD Finest Hour) can somehow end up with blocks missing from a program, not sure how, but it still finds the current program, so we check if the block exists, if not, recompile new ones.
2020-12-15 20:26:41 +00:00
refractionpcsx2
678829a5b2 VIF: Don't rush finish VU programs, fixes remaining SPS in Shadowman 2020-12-13 23:17:07 +00:00
refractionpcsx2
7138769182 VU: Synchronise VU1, added speedhack for old behaviour 2020-12-13 22:02:37 +00:00
refractionpcsx2
4a90499ec9 CDVD: Adjust read speed depending on if in inner/outer edge
Fixes Shadowman 2 Second Coming textures
Fixes Arctic Thunder loading problems
2020-12-13 22:02:09 +00:00
refractionpcsx2
446adf1983 GameDB: Remove SkipmMPEG patch for Arctic Thunder 2020-12-13 22:02:09 +00:00
refractionpcsx2
ab0d785ab5 VIF: Don't start transfer if VIF1/0 is stalled
Fix missing VIF status check on MFIFO
2020-12-13 22:01:51 +00:00
Tyler Wilding
083380297f GUI: Resolve issue causing a crash when using Close All Windows while a game is running 2020-12-12 23:03:14 +01:00
jeltaqq
88983caaba GameDB: Add patches for Idea Factory games
Add patches for another Idea Factory games.

Info here: https://github.com/PCSX2/pcsx2/pull/3854
2020-12-11 10:56:24 +01:00
lightningterror
3e5f434df3 usb: Warnings cleanup. 2020-12-11 06:19:02 +01:00
lightningterror
cfb795c23c gsdx: Warnings cleanup. 2020-12-11 06:18:31 +01:00
TheLastRar
f25091414e USB: Fix integer overflow on IOP memory range check 2020-12-11 06:12:12 +01:00
lightningterror
85c3ee823f gsdx-hw: Remove Sly 2 3 TS crc hacks.
HPO special aggressive does a pretty good job when upscaling.
2020-12-10 15:18:02 +01:00
lightningterror
d5adcdd1b2 gsdx-hw: Remove TS crc hack for GodOfWar2.
HPO Special does a good job when upscaling.
2020-12-10 15:04:22 +01:00
lightningterror
8cbaacfe38 gsdx-hw: Remove Aggressive crc hack for Kunoichi.
Speedhack.
2020-12-10 01:49:19 +01:00
Kojin
8e191dabbd gsdx: run clang format on GSState.cpp 2020-12-09 08:14:31 -05:00
Kojin
5d01952254 gsdx: remove broken tbw code 2020-12-09 08:14:31 -05:00
lightningterror
5729230f56 gsdx-hw: Add Shadow of the Colossus to auto mipmapping.
Fixes #3981
2020-12-07 01:17:29 +01:00
refractionpcsx2
f27baec6fb GUI: Force Full Boot on first run of new version
This gets around users having crashes because they haven't configured the language in their BIOS
2020-12-06 20:20:26 +00:00
TellowKrinkle
56b0026160 macOS:cmake: build plugins directly to app bundle
Copying them afterwards ended up in the wrong order with Xcode's code signing, causing unsigned plugins to get copied, which would break the later step of signing the whole bundle
2020-12-06 14:02:43 -06:00
Tyler Wilding
2c8b2b48bd ci: Add MacOS github actions build 2020-12-06 14:02:43 -06:00
TellowKrinkle
790e0a8327 macOS: Fix things broken by plugin merges 2020-12-06 14:02:43 -06:00
TellowKrinkle
16750c19ce cmake: Fix build on newer macOS 2020-12-06 14:02:43 -06:00
TellowKrinkle
a29a4d69d9 cmake: mark Utilities as needing C++17 2020-12-06 14:02:43 -06:00
TellowKrinkle
2ec8cdb86d onepad: Fix macOS build 2020-12-06 14:02:43 -06:00
Tellow Krinkle
34425d892c onepad: Fix binding A on macOS
The key value 0 (which was being used to indicate esc) was already in use as the A key on macOS
2020-12-06 14:02:43 -06:00
Tellow Krinkle
7fa6740710 GSdx: Fix issues on macOS
Note: Doesn't add the ability to make windows, so GSdx won't actually play games on macOS with this
2020-12-06 14:02:43 -06:00
arcum42
99b8168ea8 Only search for yaml-cpp if asked to. (#3975) 2020-12-06 11:39:25 -08:00
refractionpcsx2
7bcee22890 BIOS: Don't HLE OSD Parameters if BIOS has no OSD 2020-12-06 19:30:46 +00:00
refractionpcsx2
a0ac42cf6d GameDB: Added another required gamefix for Rocky
Also added to other versions
2020-12-06 18:29:30 +00:00
refractionpcsx2
7f6e2e4bf4 GameDB: Add VIF Delay Stall hack to Rocky (E) 2020-12-06 18:12:26 +00:00
Dylan Smit
65ee46c0fb misc: Added the PlayStation name properly. (#3915) 2020-12-06 10:27:51 +01:00
refractionpcsx2
16d33f8960 VIF/MTVU: Correctly increment tag addr on VIF when using MTVU
Fixes Def Jam Fight for NY when using MTVU
2020-12-06 07:06:51 +00:00
refractionpcsx2
4595aae0de mVU: Keep start PC, modify prog search to avoid recompilation
Also fix some M-Bit stuff
2020-12-06 07:06:51 +00:00
refractionpcsx2
378eccc6ea IPU: Stop IPU0 looping when there's no data for it to read
Fixes bad slowdowns in Ratchet games when using EE Timing fix caused by bad IPU streams
2020-12-03 20:00:22 +00:00
lightningterror
d0dd60f295 gsdx-hw: Purge BleachBladeBattlers crc hack.
Not needed.
2020-12-02 23:02:20 +01:00
refractionpcsx2
3d43293a5d DMA: Correctly emulate QWC 0 on NORMAL transfers 2020-12-02 20:00:02 +00:00
refractionpcsx2
32f14f48b0 MFIFO: Maintain VIF DMA status and Empty condition on VIF reset
Also don't decrement/change VIF1 QWC on VIF1 FIFO write
2020-12-02 19:59:47 +00:00
refractionpcsx2
465aa00fc7 SPU2: Get rid of the need for delay cycles
Properly handle KeyOn/KeyOff happening in quick succession.
2020-12-02 19:59:29 +00:00
refractionpcsx2
f929d79473 SPU2: Delay DMA Reads to prevent overrun
Savestate bump
2020-12-02 19:59:08 +00:00
refractionpcsx2
7f9f7d49c6 SPU: Adjust final mix volume 2020-12-02 19:58:51 +00:00
lightningterror
55d4604d8f onepad: Update to latest controller database. 2020-12-02 19:08:02 +01:00
refractionpcsx2
5d00a845ac GameDB: Add Soul Calibur III Gamefix to other NTSC versions 2020-12-01 20:41:03 +00:00
refractionpcsx2
79a0403163 GameDB: Add EE Timing fix for Soul Calibur 3 US
Fixes the bad colours on the character select when using Progressive Scan mode
Fixes #1931
2020-12-01 20:00:56 +00:00
lightningterror
be85c568ab Build: Remove appveyor and travis leftovers. 2020-12-01 10:25:52 +01:00
lightningterror
705e39473d gsdx: Fix a couple more warnings.
Still a lot left to go on x64 build.
2020-12-01 10:21:52 +01:00
lightningterror
430fc7b596 x86emitter: Fix a few warnings. 2020-12-01 10:21:52 +01:00
refractionpcsx2
cd9a0cd1d5 GameDB: Put the WRC patch in the right place 2020-12-01 01:10:22 +00:00
refractionpcsx2
2057f3ff15 GameDB: Added EE Rounding (Nearest) for WRC, fixes Subaru crash 2020-12-01 00:52:09 +00:00
Tyler Wilding
6e47834e8a Dep/CMake: Add yaml-cpp support to CMake 2020-11-30 04:22:17 -05:00
Tyler Wilding
4a477244f1 Dep: Add yaml-cpp submodule to Windows project 2020-11-30 04:22:17 -05:00
orbea
3b073343cc Fix build without pulseaudio. 2020-11-29 01:45:20 -05:00
refractionpcsx2
76c98e7140 GameDB: Correct Tekken 5 Clamping mode to fix coin noises on Pirates Cove 2020-11-28 04:10:58 +00:00
GovanifY
047599e12c CMake: fix generation due to warnings treated as errors (#3948) 2020-11-27 07:57:28 -08:00
jackun
b5fecc49a3 USB: Release wasapi resampler's mutex
Got removed in the clean up.
2020-11-26 18:28:31 +02:00
Tyler Wilding
b8eb4c26ea CI: Remove Travis-CI and AppVeyor 2020-11-25 19:01:26 -05:00
jackun
52d88a7282 USB: check that HidD_GetPreparsedData succeeded 2020-11-24 17:57:59 +02:00
TellowKrinkle
5927cef89f GHActions: Disable PCH on clang builds
There's an incompatibility between ccache and clang's PCH that's fixed by cmake 3.17 (ubuntu 20.04 has 3.16)
2020-11-24 09:52:15 -05:00
TellowKrinkle
10a7e7a15f usb: Fix build with older libsamplerate 2020-11-24 09:52:15 -05:00
TellowKrinkle
e50efceb62 core: Fix no-pch build 2020-11-24 03:16:59 -05:00
TellowKrinkle
559f93f353 GSdx: Fix sse2 build on clang 2020-11-24 03:16:59 -05:00
TellowKrinkle
40f26cb975 GHActions: Don't use march=native
It breaks ccache
2020-11-24 03:16:59 -05:00
TellowKrinkle
12bf837eee GHActions: Actually use ccache 2020-11-24 03:16:59 -05:00
TellowKrinkle
8ef6d7ffec GHActions: Add no-pch build 2020-11-24 03:16:59 -05:00
refractionpcsx2
37f145f6bd BIOS/HLE: Write OSD config with memwrites instead of direct to physical
fixes crashes with Crash Twinsanity
2020-11-22 21:25:04 +00:00
arcum42@gmail.com
c25ae58c6f Disable a few warnings. 2020-11-21 10:29:32 -08:00
refractionpcsx2
142082837c CDVD/NVM: Plan B, force user to set up their BIOS first run. 2020-11-21 17:01:14 +00:00
refractionpcsx2
358f098b65 BIOS/HLE: Match ODS Config names to Syscalls
CDVD/NVM: Write default language/screen settings to be English, 4:3, GMT Timezone
2020-11-21 16:31:36 +00:00
Kojin
626bf27887 core: send osd log event when snapshot is taken 2020-11-19 18:42:19 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
86ed9f68f6 PNACH: combined patch effects 2020-11-19 22:51:32 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a0cb6dda94 PNACH: apply repeating codes also on load 2020-11-19 22:51:32 +00:00
RedDevilus
97a24c006a GameDB: Add new entries part 1 2020-11-19 20:59:51 +01:00
lightningterror
56893a0731 gsdx-hw: Merge TriAceGames crc hacks for dx in to one.
StarOcean3, ValkyrieProfile2, RadiataStories.
2020-11-19 20:03:23 +01:00
lightningterror
0f17734896 USB: Fix a few more warnings. 2020-11-19 16:23:24 +01:00
kozarovv
4b4fa06432 Debugger: Remove delay slot for ERET and SYSCALL opcodes 2020-11-19 13:43:00 +00:00
refractionpcsx2
5a77ed14bf BIOSHLE: Implement GetOSDParamConfig2 for DST/24h/Format settings 2020-11-19 11:22:40 +00:00
refractionpcsx2
e8ebb7d23d BIOSHLE: Get all OSDSYS Parameters. Only use when Fast Boot is enabled 2020-11-19 11:22:40 +00:00
lightningterror
ab97832a78 gsdx-ogl: Check MinMax for PSConstantBuffer. 2020-11-19 11:51:54 +01:00
TheLastRar
5d071ceebe Core: Replace Fall through comment with c++17 attribute 2020-11-18 19:44:08 +00:00
TheLastRar
9983bcfbe6 Core: clang-format SysThreadBase.cpp 2020-11-18 19:44:08 +00:00
TheLastRar
ba1497ca48 Core: Don't reopen everything when we just want to reopen the CDVD 2020-11-18 19:44:08 +00:00
lightningterror
f2fa60e56b misc: Remove more leftover stuff from plugins merge.
Bonus: Remove old_plugins solution.
2020-11-18 18:02:03 +01:00
lightningterror
27536283f2 onepad: Update to latest controller database. 2020-11-17 18:30:41 +01:00
arcum42
9d4337b7eb [USB+] Clean up Warnings (#3930)
* Suppress hardening warning spam for the moment. Get rid of a multi-line comment warning.

* Resolve a bunch of warnings about unused variables, unused labels, and sign mismatches.

* Deal with various possibly unused variables.

* Rearrange member variables to match initialization order.

* Move [[maybe_unused]] to a separate line in one spot to make it easier to read.
2020-11-15 04:37:58 -08:00
Shanoah Alkire
532e7c906d Add libsamplerate to travis. 2020-11-15 01:45:55 -08:00
lightningterror
46e8057f9c gsdx-gui-win: Disable Aniso option when 8bit textures is checked on gl. 2020-11-15 08:59:07 +01:00
lightningterror
a6e845088d gsdx-ogl: Fix anisotropic filtering.
Aniso filtering doesn't work with textureLod so use texture
(automatic_lod) instead.

Credits to KrossX.

Note: Won't work on AMD because the driver is broken.
2020-11-15 08:59:07 +01:00
refractionpcsx2
d9936dbbfb GameDB: Fix typo 2020-11-14 22:10:50 +00:00
refractionpcsx2
91292f0bfa GameDB: Fix comment on new patch 2020-11-14 22:08:30 +00:00
refractionpcsx2
5000687b10 GameDB: Added patch for MX Unleashed 2020-11-14 22:07:15 +00:00
Shanoah Alkire
20c8a11925 Okay, the USB dialogs that were merged are written in Gtk 2, causing lots of deprecation warnings if you compile with Gtk 3. I'm just going to suppress all of those for the moment until they can be dealt with properly. 2020-11-13 20:42:18 -08:00
Florin9doi
319287dbe5 USB: Resolve an EyeToy crash when no webcam is connected 2020-11-13 00:15:55 +00:00
refractionpcsx2
7117633204 Counters/Vsync: Do correct number of HBlanks per VSync for PAL/NTSC 2020-11-12 23:13:55 +00:00
Kojin
c57f861f2b counters: account for vertical frequency differences in non-interlaced anolog modes (#3862) 2020-11-12 17:15:42 -05:00
refractionpcsx2
35122e6601 GameDB: Added patch for one version Hardware - Online Arena 2020-11-12 14:39:46 +00:00
jackun
60ef26ec51 USB: revert irq hack 2020-11-11 22:07:16 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f3f50a948e USB: misc fixes on settings string conversion 2020-11-11 19:22:17 +00:00
Kojin
ce658e8a96 Update issue templates (#3917) 2020-11-11 12:14:03 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
961715ab62 CDVD: fix logic bug introduced in ada80474 2020-11-11 10:11:52 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a699e94b2b USB: remove unused logos 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b1d1783da4 USB: warnings fixups 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6bdee6a5bd USB: remove version check for plugin 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
08adfb5746 USB: purge USBnull related mentions in cmake/nsis & formatting 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3b6cdf32fc USB: various formatting nitpicks 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5b67f8528a USB: build date removal, formatting 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
613fe3740f USB/dev9: final dialog fixes & winloadconfig initial load 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d2fa215aa9 USB: fix singstar & tangling if/comments 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3279cba559 USB: windows very much like its filenames (fix various dialog bugs) 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1881d12f61 USB: dialog,windows and dev9/usb conflicts fixes 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1aa585e56b USB: clean up logging 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
47d65c3f89 USB: fix ini saves 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b5dbd794de USB: evdev mDevices clear fix 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a1c4077d83 USB: fix resume issues with wheels and unneeded init 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
5799e35327 USB: remove outdated macros instances 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
73ca53eadc USB: fix debug builds on linux by switching to devcon 2020-11-11 13:34:16 +00:00
GovanifY
ede7fa86fa USB: restore formatting of standalone third party code 2020-11-11 13:34:16 +00:00
GovanifY
9da3d9a5bf USB: fix windows sstates and dialog related bugs 2020-11-11 13:34:16 +00:00
GovanifY
9eb78a0a19 USB: windows support! 2020-11-11 13:34:16 +00:00
GovanifY
92be17986f USB: introduce back linux support 2020-11-11 13:34:16 +00:00
GovanifY
30235f49db USB: fix more linker issues on windows 2020-11-11 13:34:16 +00:00
GovanifY
395b372ef7 USB: windows mostly complete, linker issues left 2020-11-11 13:34:16 +00:00
GovanifY
bc022789fc USB: initial windows project support 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f1d1acd487 USB: backport fixes from develop branch 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
53b818ac3b USB: fix sstates when invalid USB device is selected 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
90c9686684 USB: savestate bump + initial sstate implem for usb 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0c43fa92e5 USB: clang-format 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
56e96a8ff9 USB: update copyright headers 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
37e54ebd9f USB: add back config screen, pause core when opened 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a6c67dde55 USB: implement lifecycle callbacks 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e5a7cc4a1c USB: actions and cmakelists formatting 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e2a72b2798 USB: initial merge finally complete 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d33eff635b USB: initial merge relatively complete, linking issues left 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
eb4089657e USB: cleaning up a bunch of warnings, platcompat fixes 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
50969601bf USB: continuing merge, platformcompat fixes 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
de314d253e USB: importing some references, updating handlers and c exports 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2788198b75 3rdparty: add libsamplerate cmake defs 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
8f8a83a038 USB: beginning to add back initial references 2020-11-11 13:34:16 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9dd0ef681d USB: remove initial references for merge 2020-11-11 13:34:16 +00:00
TheLastRar
3442ba7483 DEV9: net.cpp use __POSIX__ to check for pthread support 2020-11-10 18:21:32 +00:00
TheLastRar
2a921b40af DEV9: use pthreads to set priority on mac 2020-11-10 18:21:32 +00:00
TheLastRar
be67773dd7 DEV9: switch net.cpp to use std::threads
Also merge windows & linux net.ccp into one file
2020-11-10 18:21:32 +00:00
Yuri Konotopov
64010cf797 Support build with system fmt (#3838)
Signed-off-by: Yuri Konotopov <ykonotopov@gnome.org>
2020-11-08 16:28:43 -08:00
lightningterror
12c21de66c spu2: Rename SPU2 Config -> Audio Settings.
We can have a better user friendly name as the plugin is merged in to
core.
2020-11-08 14:37:00 +01:00
lightningterror
476a4ec882 dev9/spu2: remove useless defines. 2020-11-08 14:37:00 +01:00
lightningterror
3d12b33113 dev9: fix not defined macro warning. 2020-11-08 14:37:00 +01:00
lightningterror
a7c9005626 dev9-gui-linux: Rename linux buttons/texts to match previous windows changes. 2020-11-08 14:37:00 +01:00
lightningterror
a52607e346 dev9-gui-win: Cleanup DEV9 gui a bit.
Rename window title: HDD Configure -> Network and HDD Settings
Remove about dialog code.
Move around button positions.
2020-11-08 14:37:00 +01:00
lightningterror
83a5a78728 gsdx-gui-win: Adjust some tooltips to include d3d 11 version. 2020-11-08 13:01:24 +01:00
lightningterror
f6478a2c0c gsdx-gui-gtk: Change date accuracy button list to a checkbox. 2020-11-08 13:01:24 +01:00
lightningterror
6c6071b939 gsdx-gui-win: Change date accuracy button list to a checkbox. 2020-11-08 13:01:24 +01:00
lightningterror
67a7c326fc gsdx-hw: Merge Basic and Full DATE code.
gl: Do Full date accuracy when option enabled.
d3d11: Do Basic date accuracy when option is enabled, no support for
full.
2020-11-08 13:01:24 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ee25b2e5b2 SPU2: switch to ConWarn for linux fallback 2020-11-08 12:14:53 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f9b42716d2 SPU2: default to XAudio when failing to read conf 2020-11-08 12:14:53 +01:00
lightningterror
5a8c75e4a8 gsdx-hw: Don't always set MaxDepth on ps/fs.
Value will be read only when zclamp is enabled. It will avoid an extra
upload to buffer maybe.
2020-11-08 05:56:09 +01:00
lightningterror
e68674bc5e gsdx-gtk: Run clang on GSLinuxDialog.cpp 2020-11-08 05:48:22 +01:00
lightningterror
ecc37c4d1f gsdx: Remove TV Shader hotkey toggle (F7).
Plenty of users misclick this setting and don't know how to switch back
since it's a rarely used option.
Let's get rid of the hotkey toggle for a quality of life change.
2020-11-08 05:48:22 +01:00
kozarovv
a59e098b5a GSdx: Remove Star Wars - Force Unleashed CRC hack
Replaced by gamedb EE patch which work also in software mode.
2020-11-08 05:43:06 +01:00
kozarovv
268a6dc6c1 GameDB: Add SW Force Unleashed patches 2020-11-08 05:43:06 +01:00
lightningterror
306681bc93 misc: Remove merged plugins leftover stuff. 2020-11-06 21:36:04 +01:00
Tyler Wilding
ac9700f261 CI: Fix Ubuntu package installation failure (#3901)
Co-authored-by: Jonathan Li <jonathan.li@hotmail.co.uk>
2020-11-06 12:11:31 +00:00
lightningterror
0e60733537 x86emitter: Comment out unused variables.
cpudetect.cpp -> x86_64_8BITBRANDID and x86_64_12BITBRANDID.
2020-11-06 11:42:29 +01:00
lightningterror
f8fd636eac gsdx-sw: Comment out not used variables, will fix a few warnings.
GSDrawScanlineCodeGenerator.x64.avx ->_rz_r14, _rz_r15
2020-11-06 11:42:29 +01:00
Timothy O'Barr
ada8047419 PSX/CDVD: Check register 14 (ps1 status register) for cd speed and CDDA (#3899)
Fix to CD speed courtesy of Ref
Restored amount of old PCSX code for CDDA courtesy of pcsxr
2020-11-05 18:03:49 +00:00
Jonathan Li
0a312295db travis-ci: Update the build 2020-11-05 15:20:42 +00:00
Jonathan Li
dca272e12d cmake: Specify the gtk version being used with wx
Fixes potential compilation issues due to gtk3 and gtk2 being used at
the same time.
2020-11-05 15:20:42 +00:00
lightningterror
a15d3d5811 gsdx-hw: EmulateAtst -> Remove unused tex parameter 2020-11-04 07:48:58 +01:00
lightningterror
246dab3375 gsdx-hw: Move EmulateAtst in common hw renderer code.
v1 Code is identical so no need to have separate functions for gl and
d3d11.

v2 Change pass integer parameter with bool that checks for pass 2.
2020-11-04 07:48:58 +01:00
RedDevilus
f60148979f onepad: Update to latest controller database.
Support for PS5 controller (DualSense).
2020-11-04 01:04:35 +01:00
RedDevilus
a83077285f GameDB: 24 The game
-VuClamp to extra to fix minimap HUD.
2020-11-03 18:03:44 +01:00
lightningterror
9140f071f6 misc: Replace Fall through comments with c++17 attribute.
Silences warnings about not having breaks on switch cases.
Added a few missing ones too.
2020-11-02 17:39:02 +01:00
lightningterror
5dc7ef9ed1 gsdx-hw: EmulateBlending -> add [[fallthrough]] attribute to switch cases. 2020-11-01 23:21:38 +01:00
lightningterror
8831ed80df gsdx-d3d11: Clean up blending code a bit.
Directly calculate blend index in rendererdx11, and send the value to
SetupOM. Get rid of duplicate calculation and abcd variables.
Code is cleaner this way.
2020-11-01 23:21:38 +01:00
Shanoah Alkire
5e6cb22eeb Remove references to dev9ghzdrk. If dev9 is built in, we need to always do the setcap check when not disabled, not just if dev9ghzdrk is built. 2020-10-31 19:45:15 -07:00
GovanifY
86e6745f21 DEV9: remove unneeded error message 2020-10-31 16:35:38 +00:00
GovanifY
667ccfad76 DEV9: fix wide char conversion & review fixes 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ba14536441 DEV9: misc formatting 2020-10-31 16:35:38 +00:00
GovanifY
52b687dc55 DEV9: integrate lean and mean and rebase with spu2 2020-10-31 16:35:38 +00:00
GovanifY
fabef0334b DEV9: windows support unicode fixes 2020-10-31 16:35:38 +00:00
GovanifY
eea4e383f9 DEV9: windows support mostly done, unicode thingies to fix 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
149bcea2d8 DEV9: bugfix on linux when no if, config revamp 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
2c1bbd5efb DEV9: updated license headers and clang-format 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ca8bf22423 DEV9: add back configure GUI 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ab22d56735 DEV9: implement lifecycle callbacks 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a2e2ed1ecf DEV9: initial merge complete 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b3ae282522 DEV9: including back initial original references 2020-10-31 16:35:38 +00:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f430a63312 DEV9: initial work on merge, removing references 2020-10-31 16:35:38 +00:00
refractionpcsx2
7a2c94f6e1 GameDB: Added patch for Black NTSC-J to fix collisions 2020-10-30 10:28:24 +00:00
refractionpcsx2
2d9f72c2a8 GameDB: Added Black PAL-E patch for collisions 2020-10-30 09:33:20 +00:00
arcum42
540c69897e Loosen up wxwidget version restrictions. Default to Gtk 3. Cleanup. (#3832)
* Remove version and platform checks for wxwidgets. It's probably better to find *something* rather then fail because you have 3.1.2 and the build was looking for 3.0 when both work.

* Build gtk 3 by default. Replace gtk 3 flag with one for gtk 2.

* Remove two unused cmake modules.

* Forgot to change a description in build.sh.
2020-10-29 22:30:03 -07:00
Yuri Konotopov
48bff06202 Added cmake options to bypass setcap execution. (#3840)
This call became a problem with distributions (eg Gentoo GNU/Linux) that
builds PCSX2 in sandboxed environment which disallows setcap execution.

Signed-off-by: Yuri Konotopov <ykonotopov@gnome.org>
2020-10-29 22:25:41 -07:00
lightningterror
7d9d2f3982 gsdx-gui: Yeah why not, update the DATE accuracy tooltip along the way. 2020-10-30 01:41:09 +01:00
lightningterror
076b336b0f gsdx-hw: Set Full DATE accuracy as default.
GL only, D3D11 doesn't have Full level.
It is more accurate and there likely isn't any speed impact.

Rename Fast level to Basic.
2020-10-30 01:41:09 +01:00
GovanifY
a3695f1cfd JIT: fix FPU IEEE float conversion on x64 2020-10-30 00:25:03 +00:00
refractionpcsx2
44416bbf7f GameDB: Change clamping on missed versions of Black 2020-10-30 00:18:02 +00:00
refractionpcsx2
fbeb2737bd GameDB: Correct CRC for Black US patch, also comment vuclamp fix 2020-10-29 23:55:09 +00:00
refractionpcsx2
5103ef27e6 GameDB: Add patches for Black PAL-M5 and NTSC-U, fixes Collisions
Also changed the clamp mode to 3 as that also works and is preferred
2020-10-29 23:37:16 +00:00
lightningterror
fca9f7a458 MTGS: Remove old DXGI fullscreen overrides code, run clang. 2020-10-29 15:41:48 +01:00
refractionpcsx2
05f20fa664 GameDB: Added patch for Ratchet & Clank 3 demo shadows 2020-10-28 21:55:26 +00:00
kozarovv
b25bb59aea GameDB: Remove IHRA 2005 patch
Fixed in #3865
2020-10-28 20:19:54 +00:00
lightningterror
af19813d99 onepad: Update to latest controller database.
Close #3866
2020-10-28 18:06:31 +01:00
TellowKrinkle
6ad8563c16 ee: update cache emulation for 64 bits 2020-10-27 14:14:38 +00:00
kozarovv
82ea30cf3f GameDB: Add patches for Idea Factory games 2020-10-27 12:56:19 +01:00
RedDevilus
809c8bf291 GSdx: Clang format
-  plugins/GSdx/Renderers/OpenGL/GLLoader.cpp
2020-10-27 12:00:08 +01:00
RedDevilus
6366284385 pcsx2-gui: Clang format
- pcsx2/SourceLog.cpp
- pcsx2/gui/AppInit.cpp
- pcsx2/gui/ConsoleLogger.cpp
- pcsx2/gui/MainFrame.cpp
2020-10-27 12:00:08 +01:00
RedDevilus
9a50e7ea99 pcsx2-gui: Further improve with adding punctation,tooltip and formatting. 2020-10-27 12:00:08 +01:00
refractionpcsx2
3dc44bafb3 microVU: Fix program range wrapping 2020-10-26 22:44:52 +00:00
refractionpcsx2
9ebcb3b141 microVU: Sort out when the Status flag is de/normalized
Properly clear non-stick invalid/zero flags on DIV/SQRT/RSQRT COP2 instructions
2020-10-26 22:44:36 +00:00
refractionpcsx2
4b0dc9c0df microVU: properly normalise Status flags when exiting a VU program
Fixes shadows in Ratchet Gladiator
2020-10-26 22:44:36 +00:00
refractionpcsx2
f25e7ff004 microVU: Save valid flag instances at the end of a VU0 program.
Fixes State of Emergency 2 black screens and BIOS reboot in Driving Emotion Type-S
2020-10-26 22:44:36 +00:00
Kojin
d8a8b31eb4 gsdx: properly init clut ptrs v2 (#3858)
* gsdx: properly init clut ptrs v2
2020-10-26 13:22:07 -04:00
refractionpcsx2
385ae40646 GameDB: Added patch for Twisted Metal Head On fire effects 2020-10-26 12:03:01 +00:00
refractionpcsx2
0448b4902c microVU: Fixed bug in E-bit conditional branches. Fixes DT Racer
GameDB: Added VU0 Kickstart hack for DT Racer
2020-10-25 21:41:29 +00:00
lightningterror
418974a28a gsdx-hw: Add ICO to automatic mipmapping.
Improves godrays.

Needs Full mipmap with ultra trilinear for extra accuracy.
2020-10-21 17:34:33 +02:00
lightningterror
d6e06e9bc7 onepad: Update to latest controller database. 2020-10-21 17:19:40 +02:00
Kojin
ca0f15a31f Revert "gsdx: properly init gsclut function ptrs"
This reverts commit 6186676add.
2020-10-21 02:52:05 -04:00
refractionpcsx2
9bb9037e42 GameDB: Added XGKick hack to Zombie Hunters 2
Fixes blank textures
2020-10-20 17:48:34 +01:00
refractionpcsx2
99670fde76 GameDB: Ported US patches to European versions of Mafia 2020-10-19 16:39:38 +01:00
RedDevilus
d48166be64 GameDB: Multiple gamefixes to: (#3843)
ChaosLegion
vuClampMode 2. Fixes SPS in the item menu. Found by EspeonScottie.

Dragons's lair
EETimingHack, VU0KickstartHack. Fixes hang and SPS.

Astro Boy (Atom)
eeRoundMode 0. Fixes character behaviour.
2020-10-19 16:48:10 +02:00
kozarovv
51976aa06b CDVD: Fix iLink issues
Previously iLinkId was writen/overwriten to .nvm only when user not supplied own file.
But when user supplied file with empty iLinkId, then value is never set. So games fail to get correct data.
That implementation return hardcoded ilinkId when read is requested, and correct iLinkId is not found.
2020-10-18 18:05:34 +01:00
kozarovv
d87330fcca GameDB: Patch for Ecco the Dolphin PAL
PSI patch ported to PAL version (PAL use the same offset).
2020-10-18 18:04:43 +01:00
refractionpcsx2
2409486c2d VIF: Fixed undefined behaviour of Unpack V3-16 in final QW write.
Fixes Homerun
2020-10-18 17:24:43 +01:00
refractionpcsx2
f1e2a2efbb GameDB: Set vu clamping to none for Hitman - Blood Money
Fixes bump mapping issues
2020-10-18 01:55:54 +01:00
refractionpcsx2
2608673ca7 GS: Fix handling of PRIM/PRMODE on PRMODECONT switching (#3831)
* GS: Fix handling of PRIM/PRMODE on PRMODECONT switching

* GS: Correctly set PRIM on Defrost
2020-10-17 00:49:37 -04:00
Tyler Wilding
2ff231c27d CI/Travis: Fix newly introduced cmake failure in Travis-CI after adding {fmt} (#3837)
* ci: Verify Travis works with cmake fix

* ci: Scope travis-ci to only `master` branch again
2020-10-17 00:44:39 -04:00
Tyler Wilding
a4b307a3bd git: pin fmt submodule to v7.0.3 2020-10-17 04:12:50 +01:00
Tyler Wilding
397cb081c3 cmake: Add fmt to cmake configuration 2020-10-17 04:12:50 +01:00
Tyler Wilding
39ac5bff71 recording: Updated all current logging instances to use new logger 2020-10-17 04:12:50 +01:00
Tyler Wilding
0fede4cb66 recording: Add logging header to simplify input recording logging
Appends [REC] to console logs when appropriate.  Auto appends new-line.  Sends similar logs to OSD if desired.
2020-10-17 04:12:50 +01:00
Tyler Wilding
bab8bdfe47 vs: Setup fmt on Visual Studio 2020-10-17 04:12:50 +01:00
Tyler Wilding
2764474274 git: Add fmt submodule 2020-10-17 04:12:50 +01:00
Tyler Wilding
fd5378d9c1 ci: Remove now unnecessary way of cleaning up old artifacts 2020-10-17 04:12:06 +01:00
Tyler Wilding
75606fd1a9 Add clang linux build 2020-10-17 04:12:06 +01:00
Tyler Wilding
ab0fc39520 Revert "recording: Add logging header to simplify input recording logging"
This reverts commit b8f4fa0e87.
2020-10-17 01:33:18 +01:00
Tyler Wilding
aad5efa637 Revert "recording: Updated all current logging instances to use new logger"
This reverts commit 8decc44476.
2020-10-17 01:33:18 +01:00
Tyler Wilding
2c6805259e GSdx: Compare file extensions as lower-case 2020-10-16 23:29:12 +01:00
Tyler Wilding
5f62a5752e pcsx2-gui: Pause and resume emulation when using Screenshot As.. 2020-10-16 23:29:12 +01:00
Tyler Wilding
9f41f33e86 GSdx: Save PNG compressed screenshots as .png files 2020-10-16 23:29:12 +01:00
Tyler Wilding
9da0cc6a91 gui: Add Screenshot As... option 2020-10-16 23:29:12 +01:00
Tyler Wilding
152d1d8ac4 recording: Don't reload cheats/settings on every frame-advance
I believe the intention of the cheats/settings reloading is for the conventional pause/resume from the MainFrame's menu.

However, with input recording, nothing ever actually gets closed so I doubt the settings need to be reloaded.  This stops that from happening on every individual frame advance.  However, in case im wrong and it is needed, they do get re-applied when emulation is fully resumed (Shift+P by default).  This just dramatically reduces the console spam.
2020-10-16 23:28:42 +01:00
Tyler Wilding
8decc44476 recording: Updated all current logging instances to use new logger 2020-10-16 23:28:10 +01:00
Tyler Wilding
b8f4fa0e87 recording: Add logging header to simplify input recording logging
Appends [REC] to console logs when appropriate.  Auto appends new-line.  Sends similar logs to OSD if desired.
2020-10-16 23:28:10 +01:00
Tyler Wilding
e44a6dcddb recording: Skip extraneous code in SaveState handler if recording is disabled 2020-10-16 23:23:55 +01:00
Tyler Wilding
c329bae403 vs: Move the VirtualPad images into their own filter 2020-10-16 23:23:55 +01:00
orbea
f0cf1a36ed cmake: Fix the build without portaudio (Again). (#3827) 2020-10-16 13:52:50 -07:00
Ryudo300
29c7c7291c gamedb: Rename Colosseum - Road to Freedom to 21 Card Games. (#3830)
Fixed incorrect game title.
SLES-53357
2020-10-16 16:13:23 +02:00
refractionpcsx2
cf05f6ca40 Cop2: Make sure the status flag gets updated on DIV/SQRT/RSQRT (#3813)
Fixes Yanya Caballista (patches removed)
Fixes Disney's Treasure Plantet's crazy camera (that flies off) and ground displacement. Fixes #3441
2020-10-16 09:47:23 +01:00
refractionpcsx2
92171ddbaa GameDB: Add COP2 Arrangement for Everyblue 2 (EU/US) Fixes #3392 2020-10-15 15:58:22 +01:00
RedDevilus
15dfad0ebc GameDB: Patches for 12 games (or 9 individual games):
- Galerians Ash
- Gladiator: Sword of Vengeance
- IHRA Professional Drag Racing 2005
- Musashi Samurai Legend
- Pilot Down: Behind Enemy Lines
- Superman Returns
- Test Drive
- TD Overdrive: The Brotherhood of Speed
- WRC 4
2020-10-15 14:54:21 +01:00
RedDevilus
03ba36411c GameDB: Add gamefixes for the following games listed, change detail are in db comments:
- Primal
- Code veronica X
- Virtua Tennis 2
- Power Smash 2
- Sega Tennis Sports
2020-10-15 10:08:05 +01:00
Kojin
1feadc186d pcsx2: enable hostfs on release builds 2020-10-15 00:29:32 -04:00
refractionpcsx2
fb29353d5d GameDB: Patch for Dynasty Warriors 3 (C) 2020-10-11 08:22:43 +01:00
refractionpcsx2
db82744553 GameDB: Added Dynasty Warriors 3 (US) patch to sort crazy cloth in opening 2020-10-11 06:17:36 +01:00
refractionpcsx2
4a1e838220 GameDB: Patch for Yanya Caballista Japan version 2020-10-10 20:37:22 +01:00
refractionpcsx2
057791607b EE Int Cache: Fix crash when booting the BIOS in 32bit 2020-10-10 15:27:40 +01:00
refractionpcsx2
7e2ccd64e8 SIF: Fix attempting to write junk when FIFO full
Also fix the amount of words written to temporary junk
2020-10-09 23:51:12 +01:00
Kojin
da3c3a828c pcsx2: purge fmv in sw hack (#3806)
* pcsx2: purge fmv in sw hack

* gamedb: remove mention of fmv in sw hack
2020-10-09 17:19:17 -04:00
refractionpcsx2
0d1a583144 DMA: Handle undefined Chain mode tags
Fixes DT Racer speed issues
2020-10-07 14:05:27 +01:00
refractionpcsx2
49b92d956a GameDB: Added VU Kickstart gamefix for Moto GP 2020-10-06 21:44:07 +01:00
Nobbs66
981cb4c22c PGIF/PS1: Correct PGIF Register bit masks (#3791) 2020-10-06 20:45:20 +01:00
refractionpcsx2
1ea573dc54 GameDB: Apparently Extra+sign on VU still needed for Another Century's Episode 3 2020-10-06 17:05:35 +01:00
refractionpcsx2
2897494732 GameDB: Removed game fixes for Another Century's Episode 3
Were added to fix a crash going in to mission 2, but now causes it to crash instead.
2020-10-06 16:27:15 +01:00
RedPanda4552
b62270ea2e Counters: Tighten tolerances on framelimiter (#3785)
Smooths out frame pace and keeps average framerate closer to target.
2020-10-06 14:14:07 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
11bb7bdff9 SPU2: more missing PCH 2020-10-06 09:34:13 +01:00
Kojin
f5b92ecdee gsdx-osd: fix crashing on d3d11 2020-10-05 21:23:29 -04:00
Tyler Wilding
bd1cc9b4f4 ci: Automatically watch for updates on github actions 2020-10-06 00:47:53 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9c17d7687a SPU2: missing pch 2020-10-05 21:52:36 +01:00
refractionpcsx2
bec587164b microVU: Make sure flags are exact on M-bit (#3797)
* microVU: Don't break on M-Bit if previous instruction was M-Bit

Fixes Gungrave
2020-10-05 21:49:15 +01:00
Mrlinkwii
5c88d259f5 GameDB: Correct title for Sly 3 (#3796) 2020-10-05 19:05:15 +01:00
RedDevilus
c772b6a843 GameDB: VU0 Kickstart to Beyond Good and Evil
Fixes Character SPS.
2020-10-05 19:06:02 +02:00
GovanifY
f30b66522f CDVD: fix ISO swapping (#3788) 2020-10-04 22:34:06 +01:00
refractionpcsx2
2c717c3cdb GameDB: Better patch for ONI games, less invasive
On real hardware the PCR write will be completed after the BC0F instruction causing it to pass, so we simulate this now
2020-10-04 21:33:44 +01:00
Shanoah Alkire
7ca2385da2 SPU2: Cleanup. Remove a few unused variables, and make a few local that didn't need to be in classes, renaming them accordingly. 2020-10-03 18:12:38 -07:00
Gauvain 'GovanifY' Roussel-Tarbouriech
655748f2d9 SPU2: clang-format, spu close before cdvd and remove unused refs 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b11ad72473 SPU2: linux fix where config wasn't setup on init & savestate bump 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1e7b69b1ab SPU2: pause while config screen is open 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
7d917afcbb SPU2: purge DSound & log + config fix 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c8abed371b SPU2: fix nullptr crash on DSound 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
444f5ed515 SPU2: fix config path 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c36c26800b SPU2: remove logo from config 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
faae323d9d SPU2: enable portaudio on linux and additional clang-format 2020-10-04 00:13:36 +01:00
GovanifY
3d3e4ec1ba SPU2: enabling portaudio on windows 2020-10-04 00:13:36 +01:00
GovanifY
f58d9e3f39 SPU2: s/NULL/nullptr/, s/SPU-2/SPU2/ 2020-10-04 00:13:36 +01:00
GovanifY
5cf2147754 SPU2: fix DMA issues 2020-10-04 00:13:36 +01:00
GovanifY
a3a530adf6 SPU2: windows config and s/SPU2-X/SPU-2/g 2020-10-04 00:13:36 +01:00
GovanifY
7ec2eb050b SPU2: windows support! 2020-10-04 00:13:36 +01:00
GovanifY
1727c863fe SPU2: windows: fix most build issues, linker issues left 2020-10-04 00:13:36 +01:00
GovanifY
d393116fb9 SPU: adding windows filters 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
15c955c384 SPU2: preliminary windows support 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6dc3966be9 SPU2: clang-format 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b0b4adea75 SPU2: license header update 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c5b5a3039a SPU2: redesign save states into a working state, config saves now works 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e8c50aaadf SPU2: add back configuration GUI 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b6356eb5f8 SPU2: implement lifecycle callbacks 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
cb0e422228 SPU2: remove setup irq callback functions 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0ece59b710 SPU2: initial merge complete 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fe8160f3ec SPU2: merged more core callbacks 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
67738a57b7 SPU2: redesign the save state system 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
9c97092efd SPU2: merging some codebase callbacks 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
3d3ccbfcd7 SPU2: merge initial code, remove plugin exports 2020-10-04 00:13:36 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b8c3bd4fae SPU2: remove initial plugin references 2020-10-04 00:13:36 +01:00
GovanifY
cf58a32583 DEV9: fix crash when closing game window with ethernet disabled 2020-10-03 23:47:04 +01:00
Kojin
6186676add gsdx: properly init gsclut function ptrs 2020-10-02 22:30:04 -04:00
sonicfind
329a1ae59d pcsx2-gui: Disable recording shortcuts on any GS panel close, even from pausing or shutting down
Now that there's a reason for it, enable the call to the CloseGSPanel function (although it still won't delete the panel).

pcsx2-gui: Remove input recording keybinds when tools are disabled


recording: Log "Recording" > "Input Recording" consistency
2020-10-03 01:45:18 +01:00
Tyler Wilding
0df056ac61 pcsx2-gui: Enable and disable new recording menu items when appropriatewhen
pcsx2-gui: Don't attempt to modify recording items if main frame is null


pcsx2-gui: Add some help text for the recording options as well


pcsx2-gui: Disable `Toggle Recording Mode` if no recording is active
2020-10-03 01:45:18 +01:00
Tyler Wilding
1954c2ce09 pcsx2-gui: Add handlers for new menu options 2020-10-03 01:45:18 +01:00
Tyler Wilding
b39f408afc pcsx2-gui: Improve method of adding key shortcut to menu items 2020-10-03 01:45:18 +01:00
RedDevilus
d304261333 GameDB: VU0 Kickstart to Blood Will Tell
Fixes main character model SPS.
2020-10-03 01:44:24 +01:00
RedDevilus
df9a45aa14 GameDB: VU0Kickstart to 24 the game
Fixes missing textures.
2020-10-03 01:44:09 +01:00
refractionpcsx2
d2169d725b SIF: Correct IOP cycle count for SIF transfers 2020-10-03 01:42:46 +01:00
refractionpcsx2
dcbb05982a Savestates: Move variable to sif struct, bump savestate version 2020-10-03 01:42:46 +01:00
refractionpcsx2
b916ce6d30 GameDB: Remove patches for True Crime: Streets of LA 2020-10-03 01:42:46 +01:00
refractionpcsx2
1a3b532530 SIF: Transfer SIF0 junk for partial QW transfers from IOP
Fixes True Crime: Streets of LA
2020-10-03 01:42:46 +01:00
refractionpcsx2
435b7dcd2b IOP DMA: Always fire interrupts for SIF0/SIF1 (#3778)
Fixes Knockout Kings 2001 hang on boot
Also cleaned up a bit of white space
2020-10-03 01:41:59 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
85c1aca70e DEV9: fix compilation issues 2020-10-02 19:26:23 +01:00
GovanifY
b4185a96c7 DEV9: only list tap interfaces 2020-10-02 19:26:23 +01:00
GovanifY
0dbb467045 DEV9: rewrite TAP driver and switch to TAP for windows 2020-10-02 19:26:23 +01:00
GovanifY
342e114de8 DEV9: implement get_{num,desc,name} with the winapi 2020-10-02 19:26:23 +01:00
GovanifY
5e8501b5f1 DEV9: initial removal of winpcap 2020-10-02 19:26:23 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0ed46c8b74 CDVD: fix for loading games in BIOS 2020-10-02 16:24:48 +01:00
lightningterror
3231e79566 [skip ci] nsis: Update message box for minimum supported os.
Separate message boxes for v1.4.0 and v1.6.0.
2020-10-01 21:02:22 +02:00
Tyler Wilding
400ed82715 recording: Many adjustments on VirtualPad from review feedback
recording: Factor in DPIScaling when scaling VirtualPad window


recording: Add a reset button, hopefully better quality backgrounds for lower resolutions


recording: Improved VPad analog alignment

Co-authored-by: sonicfind
recording: Some final VirtualPad coordinate adjustments
2020-10-01 17:52:59 +01:00
Tyler Wilding
28a4d0390f cmake: Generate resource header files alongside .pngs just like on windows 2020-10-01 17:52:59 +01:00
Tyler Wilding
14e1ecbbf6 recording: Store VirtualPad window position in .ini file 2020-10-01 17:52:59 +01:00
Tyler Wilding
4519e32586 vs/recording: Remove the committed header files, generate them at build-time
recording: General cleanup, remove obvious code duplication

recording: Improved function arg names in VirtualPad


format: Clang-format all new files
2020-10-01 17:52:59 +01:00
Tyler Wilding
8a968a0c11 recording: set ReadOnlyMode correctly when playing/recording a movie
cmake: Update cmake file lists accordingly


cmake: debugging


cmake debugging
2020-10-01 17:52:59 +01:00
Tyler Wilding
566d0c846f recording: improvements so frame will be less likely to appear un-rendered 2020-10-01 17:52:59 +01:00
Tyler Wilding
32047c6130 recording: Disable widgets in replay mode, simplify ControllerInterrupt
recording: Added some comments to the more complex parts
2020-10-01 17:52:59 +01:00
Tyler Wilding
bbc305d2b9 recording: Linting pass on files involved in this change 2020-10-01 17:52:59 +01:00
Tyler Wilding
c89e9134f6 recording: Done micro-optimizing GUI 2020-10-01 17:52:59 +01:00
Tyler Wilding
d296f0257f recording: Removed redundant #includes and reliance on Common.h
Including Common.h was excessive (for logging) and causing compiler errors on MSVCv142, this bypasses that issue.
The only references to something similar to the errors I was seeing was this https://developercommunity.visualstudio.com/content/problem/845325/stdmake-shared-pch-virtual-method-googletest-cause.html which is resolved in the upcoming VS - 16.6 release (16.5 at the time of writing)
2020-10-01 17:52:59 +01:00
Tyler Wilding
ed829d427c recording: Update controller interrupt to handle both the VirtualPad and the movie
vs: solution updates for new folders / filters / files
2020-10-01 17:52:59 +01:00
Tyler Wilding
0728acaf55 recording: New VirtualPad implementation 2020-10-01 17:52:59 +01:00
Tyler Wilding
b53d22ae7d recording: Rewrite of PadData class
Now a pure object representation of the controller data, no longer tightly coupled to the VirtualPad
2020-10-01 17:52:59 +01:00
Tyler Wilding
1afc75d6d9 recording: Commit all new .png image files for new GUI 2020-10-01 17:52:59 +01:00
Tyler Wilding
3e0ec4ebd3 recording: script to auto-regen image header files 2020-10-01 17:52:59 +01:00
Tyler Wilding
a50d67e59e recording/core: greatly simplify Sio hook and update includes 2020-10-01 17:52:59 +01:00
Tyler Wilding
788a3c294c git: auto-collapse image header files from PR reviews 2020-10-01 17:52:59 +01:00
Ty
00cc4362e8 dev9ghzdrk: Remove obsoleted keyword for Clang. (#3768) 2020-10-01 14:38:27 +02:00
lightningterror
441602aee0 nsis: Bump minimum Windows requirement to 8.1 2020-10-01 00:08:30 +02:00
lightningterror
a0829e9a24 nsis: Remove dx runtimes. 2020-10-01 00:08:30 +02:00
lightningterror
da5da1425b nsis: Remove old v1.4 checks no longer needed.
Remove StrContains.nsh which was used for the
1.4 check.
2020-10-01 00:08:30 +02:00
lightningterror
6040f8c838 nsis: Bump version to 1.8.0 2020-10-01 00:08:30 +02:00
lightningterror
74817a52ef nsis: Remove plugins that were merged in to core.
cdvdGigaherz, FWnull.

TODO: Check if any other plugins got merged in the future.
2020-10-01 00:08:30 +02:00
kozarovv
491b6e12f7 Core: Fix recLUT_SetPage in recResetIOP for ROM1, and ROM2 (#3753) 2020-09-30 11:44:20 +01:00
Ty
5858f72748 Bump up C++ version to c++17 for gcc & clang (#3746)
Use target_compile_features to enforce c++17 standard
2020-09-29 10:30:03 -04:00
Mrlinkwii
21c9d9d020 gamedb: Add vuClampMode 3 to Legend of Kay. (#3762)
Fixes broken polygons on trees.
2020-09-29 07:42:54 +02:00
RedDevilus
0e9dcfbf31 GameDB: Fix wrong names. 2020-09-27 22:05:31 +01:00
GovanifY
5de82289dd IPC: fix windows warnings 2020-09-26 04:13:27 +02:00
refractionpcsx2
aaf1fbd83e GameDB: Change clamping for Armored Core 2. Fixes #2395 2020-09-25 21:37:51 +01:00
Tyler Wilding
5523b02718 ci: Add packages to fix linux build (#3750)
* ci: Add packages to fix linux build

* ci: Sort packages
2020-09-25 00:26:42 -04:00
refractionpcsx2
0ae5c89656 GameDB: Added patch for Jonny Moseley - Mad Trix NTSC to fix videos 2020-09-25 05:08:49 +01:00
lightningterror
dcfb6a56b3 gsdx-ogl: Move DATE_GL42 swap code after colclip.
We can avoid adding extra conditions this way.
2020-09-24 21:59:31 +02:00
Christian Kenny
ec1656f380 Vif: Remove unused variables 2020-09-24 20:12:14 +01:00
refractionpcsx2
669d6096d0 GameDB: Add VU0 Kickstart to Twisted Metal Black games Fixes #3748 2020-09-24 18:58:00 +01:00
Kojin
a60b45f481 msbuild: update project to cpp17 (#3745) 2020-09-24 06:39:30 -04:00
lightningterror
271bec0f14 gsdx-ogl: Make sure DATE_GL42 doesn't run on clamp 0 with non recursive or accu blending.
Also remove DATE_GL42 asserts.
2020-09-24 00:47:13 +02:00
lightningterror
bb4efe7a34 gsdx-ogl: Swap DATE_GL42 with DATE_GL45 on sw blending draw.
It will allow to run sw blending with DATE draw which was previously
DATE_GL42 by default.
2020-09-24 00:47:13 +02:00
C.W. Betts
9952bf285d Better Apple icon file:
* 256 px taken from Windows icon.
* Scaled down 256 to 128 for better-looking 128 px.
* Add retina versions of 16 and 128 px.
2020-09-22 14:26:44 -05:00
TheCakeIsNaOH
e479bc923e NSIS: Add support for command line flags and fix silent install (#3435) 2020-09-22 20:24:04 +01:00
arcum42
2849776054 UI: Refactored plugin loops to use lambdas. (#3569) 2020-09-22 11:07:13 +01:00
Kojin
79f2468952 GSdx: Purge D3D11 Software
F9 now has the following functionality on Windows:
- If the renderer in the config is D3D11, switch between D3D11 and SW
- If the renderer in the config is OGL, switch between OGL and SW
- If the renderer in the config is SW, switch between SW and the renderer returned by GetBestRenderer()
2020-09-21 20:30:20 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6c4ac7eb7f IPC: implement MsgVersion and fix boundings bug 2020-09-22 01:28:14 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
cb775c64b1 IPC: testing grounds for MsgVersion 2020-09-22 01:28:14 +01:00
refractionpcsx2
54bcf9a657 SPU2: Only reset output modules if the sample rate changes.
Also don't reset all SPU2 regs when entering PS1 mode, only need to set the sample rate.

Fixes issues with portaudio.
2020-09-21 15:13:51 +01:00
Tyler Wilding
c4ca10258b ci: Validate VS filter files in buiild
msbuild does not use the project in it's entirety to build the app.  This means problems can slip through, so an easy solution is just to ensure the XML is well-formed.  More sophisticated validation could be done with something like `xmllint` but seems overkill.
2020-09-21 02:45:25 +01:00
Timothy O'Barr
73b02c204b SPU2: Set sample rate correctly for PS1 mode (#3532)
* Moved ps1 init. Added Sample Rate change for SPU that gets set but not applied
* SPU: misc fixes on SPU ps1 mode init
* Init the soundbuffer to apply sample rate. Actually set the correct sample rate for the ps1 though it still won't apply

Co-authored-by: Gauvain 'GovanifY' Roussel-Tarbouriech <gauvain@govanify.com>
Co-authored-by: kenshen112 <obarrtimothy@gmail.com>
2020-09-21 01:04:40 +01:00
refractionpcsx2
551847411f CDVD: Revert change from CDVD merge which broke a few things. 2020-09-20 22:27:58 +01:00
lightningterror
2684093b5b lilypad: Default.ini
Update to reflect recent changes.
2020-09-20 19:19:26 +02:00
lightningterror
451f4267ba Lilypad: Remove saveStateIndex.
Was used in saveStateTitle.
2020-09-20 19:19:26 +02:00
lightningterror
93274bfa49 lilypad: Remove disableScreenSaver from Linux too. 2020-09-20 19:19:26 +02:00
lightningterror
c1ec6337a4 lilypad: Remove saveStateTitle and leftovers TitleHackWndProc, PCSX2_overrideConfig. 2020-09-20 19:19:26 +02:00
lightningterror
27542901c8 lilypad: Remove escapeFullscreenHack fully. 2020-09-20 19:19:26 +02:00
lightningterror
78a899b36b lilypad: Remove disableScreenSaver fully. 2020-09-20 19:19:26 +02:00
lightningterror
00e7429c5f lilypad: Remove closeHack fully, remove autoAnalog. 2020-09-20 19:19:26 +02:00
lightningterror
7f57166eea lilypad: Remove psx/ps1 emulator compatibility.
Same as https://github.com/PCSX2/pcsx2/pull/3274
2020-09-20 19:19:26 +02:00
sonicfind
0ce4f7624f GSdx-Capture: Abort capture if an invalid directory is given 2020-09-20 17:36:33 +01:00
sonicfind
7662e22665 GSdx-GUI: Add wchar_t variant of ComboBoxAppend 2020-09-20 17:36:33 +01:00
sonicfind
1ff67c6c1b Capture: Share filename between GSdx and Spu2-x
Shares a single filename between the two capture functions so that the .avi and .wav will match.
Default wavdump filename changed to "audio_recording.wav"
2020-09-20 17:36:33 +01:00
sonicfind
bd91a571a6 GSdx-Capture: Append a missing .avi extension
Filenames of zero length do not allow OK to be pressed.
2020-09-20 17:36:33 +01:00
RedDevilus
e8b16bb145 GSdx-gui: Properly grays out Dithering(PgDn) in software and none renderers. (#3722) 2020-09-20 14:12:24 +02:00
Tyler Wilding
fe10f23994 ci: Resolve git-submodules related Actions warning
The `.git/modules` folder was not being initialized, which caused the post-cleanup of the `Checkout` step to flag an error at the end.  Caching this folder and thus completely caching anything submodule related, should eliminate this warning.

Also allowed submodules to be pulled in parallel when they aren't cached.
2020-09-20 05:51:46 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
e1ff498a8e FW: fix FWirq callback bug 2020-09-19 22:38:32 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
6f98fd4b65 FW: clang-format 2020-09-19 22:38:32 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
385c698212 FW: merge into core, simplify setup and config 2020-09-19 22:38:32 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
4a3e67d143 FW: including back some references 2020-09-19 22:38:32 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
0fdef7b7d7 FW: removing initial references 2020-09-19 22:38:32 +01:00
Tyler Wilding
86639114e5 ci: Increase verbosity on msbuild logs - includes timing information and such 2020-09-19 21:54:20 +02:00
Tyler Wilding
1a79e421cd Add github actions status badges to readme 2020-09-19 21:54:20 +02:00
Tyler Wilding
2e9a32e7ec ci: Cache submodules and fix artifact naming 2020-09-19 21:54:20 +02:00
refractionpcsx2
2a292fdc05 Build: Fix filters, again. 2020-09-19 16:07:17 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ee53bd795b CDVD: fix conflicts merging 2020-09-19 06:56:25 -04:00
Gauvain 'GovanifY' Roussel-Tarbouriech
ad1cdc9122 IPC: return an error when packet is too big 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
a0aaad7ff8 IPC: per user tmp folder in macOS + logic bugs 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
cd0bf66434 IPC: conform to the XDG base specification on linux 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
136b6d8098 IPC: updating IPCMsg doc 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f0179b5be6 IPC: reply datagram splittage 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
265c9ec055 IPC: timeout on read/write operations 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f1b1babcf7 IPC: query datagram splitting 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
d70309503f IPC: implement better error handling 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
439ed9617c IPC: perform memory checks, virtually no perf hit 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
89ce774d7e IPC: implement batch command processing 2020-09-18 21:10:04 -05:00
Gauvain 'GovanifY' Roussel-Tarbouriech
86757fd36f IPC: original socket ipc implementation 2020-09-18 21:10:04 -05:00
refractionpcsx2
c422aa00aa VS Project: Fix filters 2020-09-19 02:19:18 +01:00
lightningterror
b1f0f7f2e8 ci appveyor/travis: Build only master branch.
Keep them around for now, we will remove them along the way.

Replaced by Github Actions.
2020-09-19 03:18:23 +02:00
Gauvain 'GovanifY' Roussel-Tarbouriech
1f327346f7 CDVD: remove non-fatal logging 2020-09-19 01:37:43 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
b46736836e CDVD: remove disc selector dialog 2020-09-19 01:37:43 +01:00
GovanifY
4b1467ea69 CDVD: safety fixes on hard swaps 2020-09-19 01:37:43 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
f9be4286bd CDVD: clang-format 2020-09-19 01:37:43 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
c4fa3e3304 CDVD: polishing rebase and fixing nullptr bug 2020-09-19 01:37:43 +01:00
Gauvain 'GovanifY' Roussel-Tarbouriech
fd70ddda02 CDVD: reproducing old behavior, boot in BIOS if invalid drive found 2020-09-19 01:37:43 +01:00
unknown
4df5c0ee1e CDVD: check if CDVD thread is already open 2020-09-19 01:37:43 +01:00
Filjo Abraham
656efa5e20 CDVD: drive selection submenu and OS-specific fixes 2020-09-19 01:37:43 +01:00
Filjo Abraham
2c5a23b696 CDVD: ensure thread/state is ok before proceeding 2020-09-19 01:37:43 +01:00
Filjo Abraham
029461c5ae CDVD: merging and removing remnants of plugin 2020-09-19 01:37:43 +01:00
Filjo Abraham
a70bfbdaa9 CDVD: add menu item for discReader and gui for drive selection 2020-09-19 01:37:43 +01:00
lightningterror
0c67dc99f7 gsdx-gui: Add dithering option go linux gtk gui too. 2020-09-19 01:09:25 +02:00
RedDevilus
4e13c3375b GSdx-gui: Add dithering option to windows gui. (#3706)
- Dropdown menu for 3 options: Off (No Effect/ Been always like this), Scaled (Strongest effect/obvious), Unscaled (Weakest effect/less obvious).
- Change default from Scaled to Unscaled.
2020-09-19 00:57:35 +02:00
sonicfind
11fe2619eb recording: Disable currently active frame advancing when opening a different recording 2020-09-18 23:31:23 +01:00
sonicfind
9936fc7f15 recorrding: Resolve issues with starting a new file 2020-09-18 23:31:23 +01:00
sonicfind
23dba26ba3 recording: Rearrangements + Formatting
* RecordingReset is now a function of the InputRecording class
* TotalFrames is now signed
* InputRecordingControls refactor, IsRecordingPaused -> IsPaused
* Add check to keep frameCounter from overflowing (not like someone is gonna record a year's worth of inputs though).

* Code Formatting adjustments (more to do in a separate PR)
2020-09-18 23:31:23 +01:00
sonicfind
f881bd9bd6 recording: Lock frameCounter incrementation on initial recording file load or during full/fast boot
Ensures that no frames of input are skipped over on the initial load of a recording file or during a fast/full boot when a recording file is active. Improved consistency.
2020-09-18 23:31:23 +01:00
sonicfind
5c5d3a770f recording: Handle mode toggle in InputRecordingControls 2020-09-18 23:31:23 +01:00
sonicfind
975a37f209 recording: Handle Boots & Savestates similarly
* Replaces the savestate load flag with a more general initial load flag to be used by full/fast boots and savestates.
* Have the Pcsx2App::ResetRecordingCounter() method mirror the similar method of the savestate class.
2020-09-18 23:31:23 +01:00
sonicfind
b591c5e9ab recording: Rework Frame Value & Undo Count Functions
* Handle setting frameCounter to 0 in SetStartingFrame().
* FrameCounter, signed -> unsigned.
* Have SetFrameCounter handle the calculations for the relative frame displacement from the startingFrame.
* Optimizes InputRecording::controllerInterrupt.
* Flip the order of execution in inputRecordingFreeze.
* Set framecounter properly on full/fast boot.
* More accurately increment undo count
2020-09-18 23:31:23 +01:00
sonicfind
0304b124ed recording: Recording mode-based refactors
* Recording mode enum, NoneActive -> NotActive
* Changed IsMode method names and added an IsRecording method.
* Add methods designated to setting a recording to a certain mode.

Co-authored-by: Tyler Wilding <xtvaser@gmail.com>
2020-09-18 23:31:23 +01:00
Tyler Wilding
74bba35765 recording: Resolve issues discovered while testing around savestate handling
* Add a flag to explicitly indicate if the initial SS has been loaded.
* Additionally: bracket formatting / spaces -> tabs.
2020-09-18 23:31:23 +01:00
Tyler Wilding
6c80e6b93f recording: Recording controls rename and refactor to attempt to simplify
* RecordingControls - > InputRecordingControls (+ function refactors & simplifications)
* Avoid mutating g_FrameCount - now use isolated frameCounter & startingFrame variables for input recordings
* Pause or resume emulation preemptively based on GUI actions
* Exclusively handle GS window title updates in FrameForGS
2020-09-18 23:31:23 +01:00
GovanifY
fa894d9d48 HostFS: free fds when shutting down vm (#3671)
* HostFS: free fds when shutting down vm

* HostFs: init arrays at given value
2020-09-18 15:34:43 -04:00
Kojin
db36dc2326 GSdx: Purge International Star Soccer Hack
Confirmed to be a core issue.
See: #3568
2020-09-18 14:46:27 -04:00
lightningterror
8cdd823671 build.sh/cmake: Remove OPENCL_API flag. 2020-09-18 20:04:11 +02:00
lightningterror
413d58df57 3rdparty: Remove opencl lib source files. 2020-09-18 19:14:32 +02:00
lightningterror
6529fa419f vcxproj/vsprops/sln: Remove opencl 3rdparty libs. 2020-09-18 19:14:32 +02:00
lightningterror
c50c6034c0 gsdx-hw: Remove opencl code and files from gsdx. 2020-09-18 19:14:32 +02:00
lightningterror
fb640cbdb9 build.sh: Remove opencl. 2020-09-18 19:14:32 +02:00
lightningterror
edd949583a cmake: Remove opencl. 2020-09-18 19:14:32 +02:00
lightningterror
3f99395d3b vcxproj: Remove opencl. 2020-09-18 19:14:32 +02:00
lightningterror
f86ea02594 tools: Remove dynacrchack source files. 2020-09-18 19:13:45 +02:00
lightningterror
dd5d1a1abb gsdx-hw: Remove DynamicCrcHack feature. 2020-09-18 19:13:45 +02:00
refractionpcsx2
40d02400ca DMAC: Improve DMA Stall handling (#3701)
SIF: Implemented SIF0 and SIF1 DMA Stall handling
Cleaned up some of the handling of DMA Stalls on the other channels
2020-09-18 16:23:18 +01:00
Tyler Wilding
a5cc8efb10 ci: Ignore workflows on non-code changes or irrelevant code changes 2020-09-18 03:31:13 +02:00
Tyler Wilding
645b2dc17a ci: Properly fail the linux workflows if the build fails 2020-09-18 03:31:13 +02:00
Tyler Wilding
0bd49ad778 ci: Remove clang, use GCC 10 and GTK 3 2020-09-18 03:31:13 +02:00
Tyler Wilding
81ccb637f9 ci: Remove directX downloading from windows build 2020-09-18 03:31:13 +02:00
Tyler Wilding
3fba5a2c11 ci: Add cron action to cleanup old artifacts to avoid hitting GH Actions limits 2020-09-18 03:31:13 +02:00
Tyler Wilding
359be55ce0 ci: Add working linux workflow 2020-09-18 03:31:13 +02:00
Tyler Wilding
d7beb3cdc7 ci: Add windows workflow 2020-09-18 03:31:13 +02:00
Jonathan Li
176e3609a5 ci: base github actions from turtleli 2020-09-18 03:31:13 +02:00
RedDevilus
07eb0770cd Gamedb: Remove patches and add manual gamefixes
- Spiderwick Chronicles
- Amplitude
2020-09-18 02:25:37 +02:00
lightningterror
366e7b9dbd gsdx-hw: Purge Grandia3 crc hacks.
Upscaling issues can be solved with half pixel offset. Leave the
accurate blur alone!
2020-09-17 20:10:44 +02:00
lightningterror
8d8f0f82d8 gsdx-hw: Run clang format on GSHwHack.cpp. 2020-09-17 19:53:24 +02:00
lightningterror
baabbc3c9f gsdx-hw: Purge Genji crc hacks.
Effects rendered correctly.
2020-09-16 01:22:26 +02:00
refractionpcsx2
751447a028 GameDB: Added missing rounding mode for Shin Megami Tensei: Lucifer's Call 2020-09-15 17:12:13 +01:00
refractionpcsx2
b5e3fc97dc VIF: Set decoding status on VIF stall (#3683)
* VIF: Set decoding status on VIF stall

* VIF/GIF: Remove VIF Reset hack, Let GIF Unit reset queued path data (Except MTVU)
2020-09-14 23:28:55 +01:00
refractionpcsx2
f7f9e30efc SIF DMA: Fix bug with Tag Interrupts 2020-09-14 20:26:25 +01:00
refractionpcsx2
6229b204fa GameDB: Add auto game fixes for Taxi Rider to fix white models 2020-09-12 14:59:09 +01:00
lightningterror
e5db98c137 [skip ci] Tools: Move gsdumpgui in it's own repository.
https://github.com/PCSX2/GSDumpGUI

Initial release has been published as well so developers can download
and use it without the hassle of compiling.
2020-09-12 14:16:14 +02:00
arcum42
dae2c31951 Revamp the wx spu2-x dialog. (#3670)
* Revamp the spu2-x wx dialog box to be more consistant with the wx GSdx dialog.

* Revised advanced sync text for brevity, changed it back to a label, and renamed the dialog box.

* LightningTerror thinks Spu2 looks better in uppercase.

* Change around the time stretching labels again.
2020-09-11 22:30:11 -07:00
sonicfind
4d66818746 GUI/Recording: Resolve issues around playing and creating input recordings under certain scenarios (#3669)
* recording: Only stop the current recording once the menuing hasnt been cancelled

* recording: Avoid changing menu option's state if the recording couldn't be played

* recording: Don't play a recording that uses a savestate, if no game is running

* recording: Don't modify `frameAdvance` flag when explicitly [un]pausing

These functions are only called when creating/playing a recording, and modifying the frameAdvance flag leads to unexpected behaviour (such as the game starting paused if the recording was made from "power-on")

* recording: Refactor and simplify `InputRecordingFile`

InputRecordingFile will no longer be concerned with loading the save-state when playing back an existing recording.  This makes it much easier to only load the save-state if the file is valid and manipulate the emulation state correctly.

* recording: Update play logic with new refactor, resume emulation in the event of a failure

* recording/lint: spaces to tabs

* recording: Properly only examine controller 1A & 2A

The previous controller port checks in place never actually succeeded in their designated task. A new slot check in sio.cpp will perform this task instead.

* recording: Save the savestate in OpenNew() instead of open()

Ensures that the savesate could be saved before trying to create the actual input recording file. It will overwrite any previous backup savestate.
Also, allows for a simplified & easier to read code struture of open().

* Refactor and simplify `InputRecording`

Changes the return type of Play/Create from void to bool.
Optimizes Stop(), Pause(), and Unpause() call placements

Improved handling of emulation pause state, the recording menu on failures, and the conditioning of when a recording file should actually be unloaded.
For example, a currently loaded recording should not get unloaded if a user presses Play *but* chooses cancel in the file browser. However, the emulation should be paused during the duration of this action.
On the flipside, a loaded recording *should* get unloaded if the tools get disabled in settings AND emulation should resume if not already playing.

* recording: Simplify VirtualPad_Open_Click

Co-authored-by: Tyler Wilding <xtvaser@gmail.com>
2020-09-11 21:30:56 +01:00
lightningterror
4d0650baa0 3rdparty:opencl: Remove unused opencl files.
Currently they are not used when compiling with opencl so don't include
them, entire opencl 3rdparty needs to be updated. Can be done when
someone attempts to fix the opencl renderer.
2020-09-11 02:18:02 +02:00
RedDevilus
043832abdf Console-gui: Update descriptions.
Add Input to recording. Lowercase to uppercase words.
2020-09-11 01:49:32 +02:00
RedDevilus
e079604c48 pcsx2-gui: Update main window description/tooltips.
Change 2 recordings (CaptureVideo and Recordings) to Screenrecorder and Input Recording.
2020-09-11 01:49:32 +02:00
RedDevilus
6a9a61ec68 MemoryCards-gui: Update descriptions/tooltips.
Auto-Eject checkbox is a failsave for broken saves. Card (file)name to Memory Card (like a real PS2 you need to plug a memory card in port 1 to work).
Add usable to formatted to be obvious if you can use the memory card. Changed default column width.
2020-09-11 01:49:32 +02:00
RedDevilus
3d014d28e6 EmulationSettings-gui: Update descriptions/tooltips.
FMV Aspect Ratio Override = Off is the same as the value for Aspect Ratio. Formatting fix for Zoom tooltip.
Double click on emulation windows also does fullscreen. Disable framelimiting means Uncapping the FPS.
Capped slowmotion adjust at 5% (it doesn't accept lower than 5 anyway). MTGS gets debug tag (useless for many).
2020-09-11 01:49:32 +02:00
RedDevilus
03a41fee23 GSdx-gui: Update descriptions/tooltips.
Large framebuffer should only be used in cases of stuttery FMVs (cutscenes). 4/8 bits is best used where GPU is much stronger than CPU.
Fix DPI scaling for OSD color sliders (FPS + other stats).
2020-09-11 01:49:32 +02:00
RedDevilus
4e2319c075 Lilypad-gui: Update descriptions/tooltips.(PR3457)
DS4 is finicky sometimes with Directinput enabled and is best used with Xinput + Steam (Steam is recommended for all controllers).
Alternative for DS4 is Ryochan7/DS4Windows (not main DS4Windows).
2020-09-11 01:49:32 +02:00
Tyler Wilding
79cd8d2190 GUI: Fix recording related hang when PAD plugin is open/closed while game is paused (#3299)
* recording: Resolve hang when opening PAD plugin with the game paused

* pcsx2-gui: Forbid editing the PAD settings while emulation is paused by recording tools

* pcsx2-gui: Resume emulation before configuring PAD plugin, resume on return
2020-09-10 23:05:54 +01:00
lightningterror
fe872b5caa [skip travis] ci-appveyor: Skip building commits if only the following directories/files are changed. 2020-09-10 17:08:08 +02:00
refractionpcsx2
1b6b3f692d GS/Counters: Fix CSR Swap and VBlank Interrupt timing 2020-09-10 15:47:11 +01:00
refractionpcsx2
197eaf3899 VU: Also update Status/Mac instances after COP2, just in case 2020-09-10 12:25:52 +01:00
refractionpcsx2
19ab48c280 VU: Copy CLIP flag instance back to VU0 int and microVU when COP2 modifies it
Fixes Soul Calibur 3 hair
2020-09-10 11:52:47 +01:00
Mrlinkwii
27598fecce GSdx: Console printf CRC fix for starter character 0. (#3678) 2020-09-08 22:18:27 +02:00
RedDevilus
127bdb4cef Gamedb: Remove duplicate gamefix for Primal, and rename Wilds Arms to Wild ARMs. (#3672) 2020-09-07 13:56:36 +02:00
Tyler Wilding
fd4f9aacf0 pcsx2-gui: Clear console log when theme is changed 2020-09-04 15:11:42 +02:00
Tyler Wilding
457830d65d pcsx2-gui: Change the console logger's theme on the fly 2020-09-04 15:11:42 +02:00
RedDevilus
b633b2a2d1 onepad: Update to latest controller database. 2020-09-03 11:23:23 +02:00
arcum42
a1d6cb278f Make a few settings in spu2-x stick under Linux. The whole config section should probably be rewritten, but that's for a later date. 2020-09-02 21:56:54 -07:00
lightningterror
19f153adf1 pcsx2: Remove unused cheats and browser source files.
Unimplemented since pcsx2 moved to wxWidgets (0.9.x era).
2020-09-02 13:44:56 +02:00
lightningterror
4ad60d5de5 vcxproj: Remove old cheats and browser references. 2020-09-02 13:44:56 +02:00
lightningterror
53ada061d2 cmake: Remove old cheats and browser references. 2020-09-02 13:44:56 +02:00
refractionpcsx2
4629c8363c microVU: Fix state saving when m-bit is reached
microVU: Fix range merging to encompass whole ranges of programs
2020-09-01 20:49:07 +01:00
refractionpcsx2
d3f4427ee9 GameDB: Added VU0Kickstart to Horsez 2 2020-09-01 20:31:35 +01:00
JC
23248b5293 GSdx: Add Default OSD Font Resource (#3605)
GSdx: Add Roboto font to resources and make it the default for the OSD
2020-09-01 11:50:09 -04:00
kozarovv
6a4e93db3c VU: Remove unused code in VUmicro
Some of that is not used for more than 10 years. Not even useful for testing now.
2020-09-01 15:34:18 +01:00
TellowKrinkle
a1bf677514 cmake: Don't add xsave flag 2020-09-01 09:28:31 -04:00
TellowKrinkle
19f2d96d06 x86emitter: Don't use xgetbv
All OSes now support AVX
2020-09-01 09:28:31 -04:00
lightningterror
9c0865c0f4 [skip travis] ci-appveyor: Some tweaks.
Add skip_branch_with_pr reference.
- Do not build feature branch with open Pull Requests.

Remove VS2017 32bit build, will allow appveyor to finish
jobs/work faster.
2020-09-01 14:19:03 +02:00
Silent
6f0011ac9c GameDB: Add GT Concept 2002 memcard filter 2020-08-30 21:50:20 +02:00
refractionpcsx2
87dc885a4a VU: Improved EE Cycle Skipping hack to work better with the new VU0 sync changes 2020-08-30 17:15:18 +01:00
refractionpcsx2
10aced77f0 GIF: Solve stack overflow problem on large GS packets with no data 2020-08-30 15:13:28 +01:00
TellowKrinkle
56f2d307bc microVU: Fix empty register use 2020-08-30 04:31:10 +01:00
refractionpcsx2
ecebaca3f0 VU: Fix x64 crash introduced with VU Sync PR
Thanks to TellowKrinkle for helping me debug this one
2020-08-30 04:08:23 +01:00
kozarovv
67235e9a38 GameDB: Update gamedb to match new VU changes 2020-08-29 21:56:26 +01:00
kozarovv
df79a17baa VU: Improve VU0/EE sync, Implement better M-Bit Handling, Fix VU program handing on VIF 2020-08-29 21:56:26 +01:00
RedDevilus
0354e5e710 Gamedb: Add Narnia Chapter 2 Prince Caspian to gamedb ( they didnt even bother doing more languages for 1 entry and can't proofcheck other serials) 2020-08-29 17:55:11 +02:00
kozarovv
98f87dfcc3 Gamedb: Add CTTR hack description, add P4 PAL VU clamping. (#3606)
P4: Fix flickering floor during cutscenes in school.
2020-08-29 15:44:43 +02:00
arcum42
a06ed39151 fixed (was @arcum42 plz fix :p) 2020-08-28 19:10:37 -07:00
Luminar Light
5118aba456 gsdx-hw: Updated Jak CRCs. (#3634)
Added missing CRC for Jak II PAL Preview and Review builds. Due to the protection, the CRCs are identical.
Added mention of Jak 3 Review build in comments. Same CRC as two other builds, due to its protection.
Added a missing Jak X Demo CRC.
2020-08-27 16:26:58 +02:00
lightningterror
9aab6ae7fa Lilypad: Remove Vista mention from config error popup. 2020-08-27 13:37:55 +02:00
lightningterror
13ff9ab7db gsdx-hw: Purge TimeSplitters2 crc hack.
Not needed anymore.
See https://github.com/PCSX2/pcsx2/issues/3568#issuecomment-663927379
2020-08-25 16:57:47 +02:00
TellowKrinkle
91326e1d93 cmake: Remove x86-64 warnings
It's supported now
2020-08-24 16:20:09 -05:00
Tellow Krinkle
35eac7c82f GSdx 64-Bit: Fix register misinterpretation
If the C prototype says int, the compiler might leave garbage in the top half
2020-08-24 16:20:09 -05:00
beaumanvienna (JC)
4bbf0eeb8b ci:appveyor: Add 64-bit build
Since x86-64 recompilers now work
2020-08-24 16:20:09 -05:00
beaumanvienna (JC)
556ec932fb logging: x64 boot message changed
No longer says x86-64 breaks recompilers
2020-08-24 16:20:09 -05:00
tellowkrinkle
310648fb88 recompiler: Fix exception handling on WIN64
Use VEH instead of SEH on WIN64, as SEH needs us to register all our JIT functions for it
2020-08-24 16:20:09 -05:00
TellowKrinkle
970ed11def vsprops: Add __M_X86_64 flag to win64 build
Required to build x86-64 correctly
2020-08-24 16:20:09 -05:00
Tellow Krinkle
cd813edb1b x86emitter: Remove deprecated codegen functions
Successfully moved off of all of them
2020-08-24 16:20:09 -05:00
Tellow Krinkle
0711e0cd52 recompiler: Add comments to recLUT_SetPage
It's kind of confusing
2020-08-24 16:20:09 -05:00
Tellow Krinkle
dc57270fb8 EE/IOP/VU: x86-64 recompiler support 2020-08-24 16:20:09 -05:00
arcum42
eeca29b6d3 pcsx2-gui: Some menu changes (#3597)
* Reshuffle and reorganize  menus. Add a help menu with links to the main website, forums, github page, wiki, and getting started pages.

* Change fast boot to an option.

* Make the Debug window menu option checkable, similar to the Log window.

* Move log settings to the Log menu.

* Add more information to the status bar.

* Moved a few things around. Added Compatibility to the Help menu.

* Removed Pcsx2 from the menu item names in the Help menu, and rearranged a bit.

* Fix crash on cancelling.

* Status bar changes.

* Add minimize/maximize flags to debug window.

* Don't strip out the maximize and minimize boxes on the debugger in weird Windows-only code.

* Add Help button. Fix Help dialog on Linux.

* Remove no longer used Windows code for Debug window.
2020-08-23 16:10:39 -07:00
orbea
c8042fe937 man: Silence warnings. (#3590)
man: ./PCSX2.1:65:9: STYLE: no blank before trailing delimiter: Fl h,
man: ./PCSX2.1:119:9: WARNING: skipping no-space macro
man: ./PCSX2.1:180:72: WARNING: skipping no-space macro
2020-08-23 16:05:20 -07:00
RedDevilus
f78fa2aacf Disney Golf instead of Disney's golf. Same as other regions (#3626) 2020-08-23 16:03:27 -07:00
helkaluin
a0fe237dde debian-packager: Explicitly add libx11-xcb-dev to Debian packager. (#3621)
Ubuntu 20.04 onwards stopped pulling in libx11-xcb-dev with libx11-dev
2020-08-23 19:05:33 +02:00
Timothy O'Barr
dc5bfbb470 Fixes to Arch WX length_error (#3625) 2020-08-23 04:59:15 +01:00
lightningterror
3324043d21 gamedb: Remove zerospu2 comment. 2020-08-23 05:27:22 +02:00
lightningterror
383fa03a34 Remove zerogs and zerospu2 source project files. 2020-08-23 05:27:22 +02:00
lightningterror
664559b6d4 pcsx2: Remove zerogs, zzogl code and comments. 2020-08-23 05:27:22 +02:00
lightningterror
96c057466b sln: Remove zerogs and zerospu2 from build solution. 2020-08-23 05:27:22 +02:00
lightningterror
0939c6302e cmake/linux: Remove zerogs zerospu build environments. 2020-08-23 05:27:22 +02:00
lightningterror
ee3b153d7b gitignore: Remove zerogs, zerospu2 2020-08-23 05:27:22 +02:00
refractionpcsx2
86bb50b9b7 Why is that file spaces and not tabs 2020-08-23 01:40:42 +01:00
refractionpcsx2
deed83a282 Revert bad wxString ini fix which was actually caused by a bad Arch package 2020-08-23 01:39:13 +01:00
lightningterror
f6c138ca7e Goodbye, old friend... Remove zzogl from master branch (#3614)
* cmake: Remove zzogl from cmake.

* cmake/build: Remove GLSL_API and EGL_API flags.

Only used in zzogl.

* linux various: Remove zzogl.

* sln: Remove zzogl from old plugins solution.

* zzogl: Remove source files.

* debian: Exclude zzogl from copyright.

* linux various: Remove glsl2h.pl

Used only in zzogl?

* linux various: Remove zzogl code from validate_glsl.sh

* debian: Remove zzogl mentions in create built tarball.

* gitignore: Remove zzogl paths.
2020-08-21 20:41:45 -07:00
seta-san
328e358b21 Define IPUDMAMode 2 (#3617)
Define IPUDMAMode 2
2020-08-21 19:27:56 +01:00
lightningterror
fc882c9efc debian: Remove gsdx legacy from packager. 2020-08-20 15:34:20 +02:00
lightningterror
35fa2253dd cmake/linux various: Remove remaining traces of GSdx legacy. 2020-08-20 15:34:20 +02:00
lightningterror
dc0db7c58b gsdx-legacy: Purge gsdx legacy from master branch. 2020-08-20 15:34:20 +02:00
tellowkrinkle
850efdc690 Move VTLB manipulation to class (#3524)
Another small piece of #3451

Moves all VTLB pointer manipulation into dedicated classes for the purpose, which should allow the algorithm to be changed much more easily in the future (only have to change the class and recVTLB.cpp assembly since it obviously can't use the class)

Also some of the functions that manipulated the VTLB previously used POINTER_SIGN_BIT (which 1 << 63 on 64-bit) while others used a sign-extended 0x80000000. Now they all use the same one (POINTER_SIGN_BIT)

Note: recVTLB.cpp was updated to keep it compiling but the rest of the x86-64 compatibility changes were left out

Also, Cache.cpp seems to assume VTLB entries are both sides of the union at the same time, which is impossible. Does anyone know how this actually worked (and if this patch breaks it) or if it never worked properly in the first place?
2020-08-19 09:37:23 +01:00
tellowkrinkle
75aac90452 Allocate memory in an x86-64-compatible way (#3523)
Allocate memory in an x86-64-compatible way

Another part of #3451

Note: While this shouldn't change how anything works, it's been the #1 source of breakage of 32-bit builds in #3451 (it was the cause for the failure of win32 to allocate memory and the failure of linux-32 afterward) so we should definitely make sure it gets tested

see #3523 for more information
2020-08-19 09:20:48 +01:00
tellowkrinkle
4f56db9f18 Fix codegen on x86-64 (#3512)
Fix codegen on x86-64

Part 1 of the changes being worked on in #3451

Makes x86emitter emit the x86-64 machine code you would expect it to

Also adds some unit tests to verify that things are working
2020-08-19 09:19:28 +01:00
seta-san
61f3258b96 GamesDB: Remove Eyetoy Check for Card Captor Sakura (#3595) 2020-08-13 21:35:00 +01:00
lightningterror
edc701d3fc gsdx-d3d11: Remove old nvidia hack reference. 2020-08-11 00:50:56 +02:00
Hamish
8816f4bf0d GSdx: Remove GLX in favor of EGL (#3562) 2020-08-09 04:39:56 +01:00
Mrlinkwii
bf2904d380 GameDB: Adjust KOF: Maximum Impact - Maniax naming. (#3585) 2020-08-09 01:00:29 +02:00
ichee
543bb2270e GameDB: Add gamefix patch for Rogue Galaxy. (#3547)
Fixes Vedan Myna area out of bounds glitch.
2020-08-08 23:40:43 +02:00
Tyler Wilding
9d6d7f7f63 pcsx2-tas: Corrections to recording file's header data (#3480)
* The emulator version was hard-coded to PCSX2-1.5.X which is no longer accurate, it is no longer hard-coded and will use the correct version number the same way it is calculated to display in the window title.

* When creating a recording, the game name is preferred over the ISO name. This is determined via the GameDB. When playing back the recording, a simple check occurs to see if the game running is the same one that was used to make the recording. On the playback side, it always only checked with the ISO filename.
2020-08-08 22:25:19 +02:00
lightningterror
b3d90537ba pcsx2: Adjust windows OS support logs.
List Windows 8.1 and Windows 10 as supported OSes only.
Windows 8.0 and lower as unsupported.

Simplify/clean up the code.
2020-08-08 22:22:16 +02:00
kozarovv
6794bbbd6a Add rom2: support (Fix Chinese Bios) (#3439)
* Add rom2 support

* Add rom2 support on IOP

* Valid memory range for rom2

* Add rom2 support to IopMem.cpp
2020-08-08 20:59:46 +01:00
RedDevilus
60e075d6c9 onepad: Rock Candy Nintendo Switch Controller (#3582) 2020-08-07 15:37:18 +02:00
Kojin
454704d967 vs-build: use the win10 sdk (#3560)
vs-build: use the win10 sdk
2020-08-05 14:12:00 -04:00
RedDevilus
c5470a7f53 onepad: Update to latest controller database. 2020-08-04 05:31:18 +02:00
KrossX
9222e93c40 GSdx-hw: Fix OGL line scaling 2020-08-02 14:07:31 +02:00
tellowkrinkle
95b5ab5f1f clang: Update .clang-format to better match upcoming style guide. (#3535)
People were turning it off because it was doing stupid things, hopefully it'll be more usable now.
2020-07-30 01:44:04 +02:00
RedDevilus
0bf54aa6f6 Gamedb: Cleanup/correct formatting and code comments v2. 2020-07-29 00:07:22 +02:00
lightningterror
25bf39e895 gsdx glsl/fx: Remove unused Uber_ATST shader code. 2020-07-28 01:59:53 +02:00
arcum42
f44f676cce Remove old obsolete code specific to ancient Windows versions of GSdx. 2020-07-25 19:15:03 -07:00
Tyler Wilding
ef96e050f9 Resolve Recording Issues for Linux / OnePad users (#3293)
* git: Ignore uncaught linux build artifacts

* onepad-legacy: Return legitimate key event on `PADkeyEvent` call

Onepad-legacy was the plugin that was building and being used on my linux environment.  I'm not sure if t hat's expected and normal 'onepad' has yet to take over.

* onepad: Return legitimate key event on `PADkeyEvent` call

* recording: Remove unnecessary `PadKeyDispatch(ev)` wrapping func

* recording: Cleanup key event handling when GSFrame CoreThread is paused

* recording: Refactor recording status check to be more explicit

* recording: Define additional key bindings for capitalized varient

Despite the advice of the docstrings in these files, on linux this seems to be required for the bindings to consistently fire.

* onepad: Declare `AnalyzeKeyEvent` not static

* recording: Ensure file extension is appended to recording file on linux

* recording: Correct typo in comment

* recording: Better wording around linux keybinding handling

* Remove unneeded `extern`
2020-07-25 17:58:50 -07:00
RedDevilus
aee23929dc GameDB: Test Drive Unlimited. (#3561)
Fix ordering + Region PAL.
2020-07-24 11:57:33 +01:00
refractionpcsx2
b28382632a IPU: Perform an interrupt on IPU_CTRL Reset. (#3555)
* IPU: Perform an interrupt on IPU_CTRL Reset.
Doing this reset performs a forced command end, meaning the IPU will run through the procedure of ending any command running and telling the core that it is done, even if there is no command currently active.
Fixes Fightbox

* Remove Fightbox patch
2020-07-24 08:56:46 +01:00
lightningterror
a1acaaa50c pcsx2-gui: Remove SuperVU reference from vuflaghack tooltip. 2020-07-23 21:06:55 +02:00
RedDevilus
d1af8cd806 GameDB: Patches for 22 games (or 16 individual games)
- 24 : The game
- Amplitude
- Freaky Flyers
- Free Running
- Ghosthunter
- Next Generation Tennis 2003
- NHL 2K6
- NHL 2K9
- Primal
- Ruff Trigger
- Salt Lake 2002
- Savage Skies
- SOCOM 3
- Tomb Raider: Angel of Darkness
- True Crime: Streets of LA
- Yanya Caballista: City Skater
2020-07-21 17:40:16 -04:00
lightningterror
e3f195cf5c onepad: Update to latest controller database. 2020-07-21 22:08:34 +02:00
refractionpcsx2
6a067f5cd6 GameDB: Added missing EU version of Test Drive Unlimited 2020-07-20 14:04:30 +01:00
xddxd
ee77822d22 Fix no portaudio build (#3510) 2020-07-19 19:21:54 -07:00
John Zimmermann
7e52b9550f Allow running on systems without wx stackwalker (#3519)
closes #2796
2020-07-19 19:13:15 -07:00
arcum42
e42b9ce110 More gtk removals and Onepad dialog tweaks (#3525)
* Improve secondary dialogs in Onepad. I'll do gtk stuff in this branch, too, I promise...

* More fiddling with onepad's secondary dialogs.

* Rework config.inl to use wx, getting the rest of the null plugins.

* Remove some unnecessary includes, and convert SysMessage to wx in onepad.

* Add in tellowkrinkle's Mac OS fixes.
2020-07-19 19:11:42 -07:00
lightningterror
b00c603e0b gsdx-hw: Remove aggressive crc hack for SMTDDS1, SMTDDS2, SMTNocturne.
Removed motion blur and filter on the player. Hack is awful, get rid of
it! Related
4e7e7f2dd5

Bonus: remove commented out hack for VP2.
2020-07-19 00:14:37 +02:00
refractionpcsx2
8a6d56bb29 Revert IOP Counter change. IOP counters already edge triggered based on INT flag 2020-07-18 20:54:29 +01:00
lightningterror
30e6a7a62a onepad: Update to latest controller database. 2020-07-17 21:20:05 +02:00
lightningterror
0ee3983421 gsdx-hw: Add missing crc for RatchetAndClank pal. 2020-07-17 19:51:43 +02:00
refractionpcsx2
389d664ffd Clarified my patch comment slightly 2020-07-17 14:47:55 +01:00
refractionpcsx2
adbb12befe Added patch for FightBox 2020-07-17 14:31:52 +01:00
refractionpcsx2
54f47572af EE REC: Prevent crash when DI instruction is in branch delay slot 2020-07-16 20:09:12 +01:00
refractionpcsx2
a782e03ebf GSdx-hw: Improve HW dithering (#3534)
* Improve HW dithering to stop it creating line artifacts across the screen

* Make DX dithering code OGL-like
2020-07-15 13:51:03 +01:00
refractionpcsx2
e04d86ad39 VIF MSCAL instructions wait on VU T-Bit stop (#3539)
* VIF MSCAL instructions wait on VU T-Bit stop
Fixes:
The Sims
Spiderman 3
Sharks Tale
Maybe some bits of Over the Hedge

* Removed Spiderman 3 patches

* Fix VIF DMA resuming when stalled on tag

* Remove warning which doesn't really need to be there anymore
2020-07-15 13:15:47 +01:00
refractionpcsx2
105478aa6d EE/IOP Timer Interrupt Handling
Don't interrupt if compare/overflow flag is already set

Removed patches for Harry Potter Prisoner of Azkeban and Chamber of Secrets as they should no longer be required.
Note - Some harry potter games still have the EE Timing Fix which may also not be required
2020-07-15 13:14:19 +01:00
tellowkrinkle
1e1d455a4d Use PCH with Clang (#3546) 2020-07-14 22:57:11 -07:00
tellowkrinkle
18f5deede7 Reduce header dependencies on x86Emitter (#3545) 2020-07-14 22:56:58 -07:00
Filjo Abraham
715672481b Update gitignore (#3538)
PCSX2-linux.sh is generated when building
GSdx debug files are created when running
2020-07-12 14:54:59 -07:00
tellowkrinkle
f7d84c4637 pcsx2: Fix a few crashes in macOS. (#3424)
* Fix crash on shutdown in macOS

* Fix crashing in ISO list on macOS

* Use MAP_FIXED on linux too
It works as expected and has no race conditions.
2020-07-12 23:54:21 +02:00
RedDevilus
c23f3be21f pcsx2-gui: Modern Dark Themed Console v2.Replaces old dark mode with modern dark mode to the console.
Darker than dark (#3446)
2020-07-12 18:46:50 +01:00
RedDevilus
257f8b1142 pcsx2-gui: Modern Dark Themed Console. (3446)
Replaces old dark mode with modern dark mode to the console.
2020-07-11 22:44:24 +02:00
Kojin
e0037ff709 gsdx-d3d11: remove legacy d3dcompiler code 2020-07-10 17:04:33 -04:00
RedPanda4552
1a1a338d68 GameDB: Add Xenosaga save point crash patch (#3418) 2020-07-10 18:04:44 +01:00
Kojin
210336d8c1 gsdx-d3d11: Modernize swapchain and device creation
Updates the d3d device and swapchain creation to more modern methods.

- Use CreateDXGIFactory2 to create the factory and store in member
- Use CreateSwapChainForHwnd
- Add messages for failures to the console
- Some general formatting improvements
2020-07-07 15:59:44 -04:00
Mrlinkwii
91e7c5b7f1 gamedb: Add The Ultimate World Cup Quiz. (#3522) 2020-07-04 16:47:13 +02:00
arcum42
6afee4ae0c Don't call PressButton if the key pressed isn't in the index. 2020-07-03 21:56:46 -07:00
lightningterror
b45e524b2c gsdx-d3d11: SetupIA, allow sprite conversion to be done on the cpu on d3d hw renderer when applicable.
Convert sprites on the cpu instead of the gpu when applicable. Port from
Opengl.

Lines: GPU conversion.
Triangles: CPU conversion.

Disable Geometry shader when conversion is done on the cpu.
2020-07-03 13:00:49 +02:00
RedDevilus
7d35892def GameDB: Add EETimingHack gamefix to Yakuza.
(#2774) Fixes flickering.
2020-07-02 08:37:42 +02:00
RedDevilus
4102489d84 onepad: Add Alienware controller
Fixes #3505
2020-06-29 16:41:48 +02:00
lightningterror
c7bc1c2cfa gsdx-gui: Limit spin buttons input properly.
v1 It won't allow users to try to input a value that isn't supported
osd (size, timeout, max), tc offsets (x, y), rendering threads.

v2 Use const if applicable for variables throughout
GSSettingsDlg.cpp. Will cleanup some warnings.
2020-06-28 20:48:37 +02:00
RedDevilus
711314dfd8 GameDB: Add EETimingHack gamefix to King of Colosseum Green. (#3493)
Fixes hang on opening.
2020-06-27 16:44:42 +02:00
Florin9doi
be1c97a18b Mpeg.cpp/h indentation 2020-06-27 15:03:44 +01:00
arcum42
3119e0a2e7 Rewrite the spu2-x dialog on Linux in wxwidgets. (#3454) 2020-06-27 01:00:50 -07:00
lightningterror
a2c62c30ad gsdx-hw: Remove Itadaki Street hw hack.
The hack didn't properly work and it is a core issue.
2020-06-27 09:02:18 +02:00
Mrlinkwii
0f1cbe7410 SPR spacing cleanup (#3499)
Correct spacing in SPR.cpp
2020-06-26 20:21:55 +01:00
lightningterror
3269c58c8d gsdx-hw: Improve detection of Texture Shuffle effect.
DMC3, Onimusha 3 rely on this behavior.
They do fullscreen rectangle with scissor, then shift by 8 pixels, not done with recursion.
So we check if it's a TS effect by checking the scissor value.

Credits to Kojin for figuring out the issue.
2020-06-24 22:39:06 +02:00
lightningterror
cc3c5a8efc gsdx-hw: Remove Onimusha3 and DevilMayCry3 crc hacks.
Next commit will allow to render the effects properly.
2020-06-24 22:39:06 +02:00
Víctor "IlDucci
2365e4ff7f Locales: Updating Spanish translation. (#3476)
Overhauls the previous batch of changes and adds the latest changes. Changes include:
 - Unification of terminology between all the strings.
 - Changing quotation marks with the ones used in Spanish.
 - Removal of some GT-like translations.
 - Unification of parenthesis symbols.
 - Removal of title uppercasing (Spanish language doesn't use that many uppercased words).
 - Checked fuzzy entries.
2020-06-24 13:10:26 +02:00
RedDevilus
7de8e34963 Gamedb: Cleanup/correct formatting and code comments. (#3490) 2020-06-24 13:07:30 +02:00
lightningterror
19e872453d gsdx-d3d11: Remove Alpha Stencil hack.
Hack is obsolete/replaced with accurate date/date_one option/code.

There's pretty much no usecase for it remaining other than using it as
an alternative to skipdraw which removes/breaks transparency effects.
2020-06-23 21:39:39 +02:00
lightningterror
297f91ae7d spu2-x-gui: Fix text being cut off on some options when using dpi scaling. 2020-06-21 01:50:26 +02:00
lightningterror
d7118671e6 lilypad-gui: Fix text being cut off on some options when using dpi scaling. 2020-06-21 01:50:26 +02:00
lightningterror
6032d91293 gsdx-gui: Fix text being cut off on some options when using dpi scaling. 2020-06-21 01:50:26 +02:00
iMineLink
1426dc1fc5 GSdx-hw: use CanUseSwSpriteRender in OI_JakGames. (#3463)
In GSRendererHW, reuse the method CanUseSwSpriteRender for OI_JakGames.

As in current master, 16x16 "flat" sprite draws are performed via CPU: those are palette rendering better emulated with the SwSpriteRender.

Jak games do also many 64x64 "flat" draws, but mostly for render to texture effects that are already correctly emulated in the TC, so those draws are not done via CPU (as on the contrary happens for DBZ BT games).
2020-06-20 20:22:27 +02:00
iMineLink
e2c472baa9 GSdx-hw, TC: invalidate Source w overlapping draw. (#3131)
Improve texture cache Source objects invalidation logic taking into account overlapping with current draw.
Fixes eyes rendering for the Major in Jak 1.
2020-06-19 21:36:19 +02:00
lightningterror
5362fc9c26 gsdx-ogl: Fix MaxDepthPS byte alignment.
Bigger value comes first, then smaller to fill the gap so the alignment
can be proper.
vec3
float
2020-06-19 19:37:32 +02:00
RedDevilus
5d318c9c3c [skip ci] Update PCSX2_keys.ini.default hotkey info comments for gsdx.
Revise gsdx hotkeys (dithering) and others.
2020-06-19 17:25:09 +02:00
RedDevilus
dacbe78f35 GameDB: Butt Ugly Martians (#3470)
Fixes #3466.
2020-06-18 15:33:37 +01:00
RedDevilus
8b2a3e3c10 onepad: Add PC Game Controller to db. (#3465)
Fixes #3464.
2020-06-17 16:38:10 +02:00
Alessandro Vetere
ca9e876241 GSdx-hw: use SSR in DBZBT3.
Closes #2001.
2020-06-16 22:28:51 +02:00
lightningterror
76fae2282e onepad: Update to latest controller database.
Close #3461
2020-06-16 21:45:48 +02:00
Alessandro Vetere
d05b31e91c GSdx-hw: get rid of some VS warnings. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
60e8d40492 GSdx-hw: DBZBT2, remove OO & CU, add OI.
Use SwSpriteRender to render sprites, which:
- fixes kaioken effect,
- fixes character outlines when upscaling,
- reduces frametime by up to 3ms with big upscaling factors.
2020-06-15 22:52:26 +02:00
Alessandro Vetere
e71380b82c GSdx-hw: DBZBT2, remove GSC. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
fb3eaa9eff GSdx-hw: add CanUseSwSpriteRender method. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
ff4ba6712c GSdx-hw: SwSpriteRender, improve no raster check. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
c164769eec GSdx-hw: SwSpriteRender, use m_r, correct assert. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
9b73c0eeec GSdx-hw: use PRIM enums in SwSpriteRender. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
cd0a6f05a0 GSdx-hw: SwSpriteRender, implement TEX0.TFX=1. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
f2dd92b5f8 GSRendererHW: SwSpriteRender, fix FBMSK. 2020-06-15 22:52:26 +02:00
Alessandro Vetere
09116d8964 GSdx-hw: SwSpriteRender, implement all ALPHA.C. 2020-06-15 22:52:26 +02:00
lightningterror
d648755d75 gsdx-ogl: Correct intel bad driver log.
Log should paste if either DSA or texture barrier aren't supported.
2020-06-14 00:02:26 +02:00
lightningterror
e64ae9b6bf gsdx-ogl: Adjust sparse texture handle.
Don't disable sparse texture by default before extension check, it will
display sparse texture always not supported. Do an ini check in
check_sparse_compatibility function instead.
Log should properly state if sparse texture is supported now.
2020-06-14 00:02:26 +02:00
lightningterror
5db24d4e4a gsdx-ogl: Adjust some gl debug logs.
Move Additional colclip info, dithering, FixedTEX0 to extra debug logs.
It will allow to keep track of more important stuff going on and they
can be enabled with ENABLE_EXTRA_LOG if needed.

Change context creation log type from stderr to stdout.
2020-06-14 00:02:26 +02:00
RedDevilus
d923432023 GameDB: Adds SkipMPEGHack gamefix to Tiger Woods PGA Tour 06. (#3456)
Fixes hang after EA intro (IPU).
2020-06-13 04:29:37 +02:00
prafullpcsx2
4e4a097240 Implemented memory mode check in cop0.cpp (#3324)
This makes Next Generation Tennis 2003 (Roland Garros French Open 2003) and Spongebob Battle for Bikini Bottom (PAL) work.
2020-06-09 21:50:06 +01:00
Mrlinkwii
f9f55029d1 GameDB: Add Slam Tennis. (#3453) 2020-06-09 16:57:33 +02:00
KrossX
b5625ad8b0 gsdx-hw: Add zclamping to ps/fs.
Add zclamping to ps/fs, enable vs, ps/fs clamp when needed with a macro.
2020-06-06 23:56:41 +02:00
lightningterror
5d0eefeebd gsdx-hw: Cleanup a bit EmulateZbuffer.
Update the comment to reflect recent changes,

Rename DepthMask to MaxDepth,

use a mask shift to get z format,

Do vs cb padding on d3d11.
2020-06-06 23:56:41 +02:00
lightningterror
845a3d0ab8 gsdx-hw: Remove the code block for the bad Z sise check in EmulateZbuffer.
Also fixes Itadaki Street text and F1 2004 starting lights
2020-06-06 23:56:41 +02:00
lightningterror
33678441dc gsdx-hw: Clamp zbuffer to depthmask instead of wrapping.
The behavior was verified on Dobie to be correct.
The code needs to be ported to SW renderer too to
improve rendering on SW side.

Current PR will fix plenty of games on HW renderer
that had/have zbuffer issues before.

v2. Set DepthMask to the maximum the current depth format allows.
Will properly clamp for 16bit and 24bit formats.

v3. gl: Fix uniform buffer upload/cache for VSConstantBuffer.
2020-06-06 23:56:41 +02:00
lightningterror
24f06187df gsdx-d3d11: Port/add depth mask support to EmulateZbuffer.
Add support for depthmasking to EmulateZbuffer, previous old code had
support but wasn't ported properly with the new code a few years back.

VS Constant buffer is now properly setup.
2020-06-06 23:56:41 +02:00
RedDevilus
639986faa7 GameDB: Add gamefixes for the following games listed, change details are in db comments: (#3402)
- DT Racer
- Gran Turismo Prologue
- Gretzky NHL 2005
- Hot Shots Tennis
- Justice League Heroes
- Melty Blood - Act Cadenza
- Metal Arms - Glitch in the System
- Next Generation Tennis 2003
- Official PlayStation 2 Magazine Demo 33
- Primal
- SOCOM 3
- SOCOM Combined Assault
- UFEA Euro 2004
- WRC 4
2020-06-06 23:34:39 +02:00
lightningterror
4aa8b0f977 onepad: Update to latest controller database. 2020-06-06 22:30:24 +02:00
refractionpcsx2
ca903b6b14 GSdx-sw: Add Z clamping to GSdx SW mode (#3433)
* Add Z clamping to GSdx SW mode

* Fix spacing

* Only clamp when max vertex z is greater than zfmt max

* Fix Z format switches

* Get rid of needless shuffle

* Whoops, missed a case

* Replace switches with a shift

* Disable triangle clamping for SSE2

* Implement clamping on GS Raster Interpreter

* Added SSE2 Triangle Z clamping by KrossX
2020-06-05 20:56:16 +01:00
Jonathan Li
d08e49f2df pcsx2: Remove leftover array entry from SuperVU removal
It was causing GameDB fixes to be applied wrongly.
2020-06-03 20:16:00 +01:00
Shanoah Alkire
30ffda406c Remove -Wno-char-subscripts, as it was there for supervu. 2020-06-01 16:34:31 -07:00
arcum42
8023183999 Switch over the null plugins dialog code to use wxWidgets instead of gtk on Linux. (#3420)
* Make the other null plugins use the same functions, and convert PS2Eext.h  to use wx.
2020-05-30 13:31:52 -07:00
Ryudo300
2a9451fed5 PCSX2-GUI: Update BackgroundLogo. (#3423)
Fixes the background/logo glitching out when using DPI scaling.
2020-05-30 21:19:09 +02:00
lightningterror
a9f41c6824 Revert "pcsx2: Change order of "Video (GS)" submenu. (#3265)"
This reverts commit b00792d6ce.

It confused a lot of people that were used to the previous position.
Maybe was a good idea, but bad result.
2020-05-27 22:34:48 +02:00
lightningterror
9cf54b8897 onepad: Update to latest controller database. 2020-05-27 11:57:11 +02:00
arcum42
5903ee95fe Remove unused folder in Visual Studio project. 2020-05-24 20:04:20 -07:00
arcum42
2b115d031e Remove superVU. (#3386)
* Remove superVU, as well as the VUClipFlagHack, which was SuperVU only.
2020-05-24 19:08:12 -07:00
Jonathan Li
3c65ddf72e GameDB: Remove Klonoa 2 patches
They are no longer necessary now that the PACK command has been fixed.
2020-05-25 00:20:44 +01:00
Jonathan Li
0277b69ff1 ipu: Revert Klonoa 2 workaround
This reverts commit 10ee832dc1.

The workaround should be unnecessary now that the indx4 is properly
aligned.
2020-05-25 00:20:44 +01:00
Jonathan Li
08cb843180 ipu: Use alignas to ensure 16-byte alignment of indx4 array 2020-05-25 00:20:44 +01:00
Christian Kenny
aec8e959d9 SaveStateBase: Remove unused "m_DidBios" bool. 2020-05-24 13:27:11 +01:00
Christian Kenny
5ab97eb873 Savestate: Remove unimplemented exceptions. 2020-05-24 13:27:11 +01:00
tellowkrinkle
f9771c38a6 macOS fixes (#3357)
* macOS compile

* Fix memprotect error on macOS

* Fix semaphore wait + thread cancel on macOS

* Fix timedlock timeout calculation

* spu2-x macOS

* onepad macOS support

* Add MacOS game controller db

* Disable onepad_legacy on macOS

* Fix spu2-x configuration crashes

* Make recompiler work on 32-bit macOS

* Use dylib extension for plugins on macOS

* Make app bundle on macOS

* Use git info for Info.plist version
2020-05-23 23:19:47 -07:00
Timothy O'Barr
8eb1bc1986 Fix length_error crash in basic_string in the ini code. (#3411) 2020-05-23 23:09:11 -07:00
SuperSamus
26a4ba360f Locales: Update Italian translations (it_IT). (#3412) 2020-05-23 12:55:51 +02:00
Shadix Aced
2fed813228 Locales: Update French Translations (fr_FR). (#3393) 2020-05-22 03:09:02 +02:00
lightningterror
f2560998c8 [skip ci] Misc documentation updates.
Update issue template with newer release versions.

Update readme, list windows 7 and 8 as no longer supported.
2020-05-20 16:56:17 +02:00
arcum42
c8c27cbfd1 Bump up the minimum cmake version slightly, and make older versions happy with the regex in FindHarfbuzz.cmake. 2020-05-19 22:15:47 -07:00
Jonathan Li
efe3bc1613 pcsx2: Implement IPU VQ conversion
Fixes the blue flames in Klonoa 2.
2020-05-17 21:33:41 +01:00
Jonathan Li
dca0c4ed79 pcsx2: Change IPU vqclut data type
This should improve the readability of the IPU VQ conversion.
2020-05-17 21:33:41 +01:00
Jonathan Li
c533a65764 pcsx2: Add IPU dither block SSE2 implementation 2020-05-17 21:33:41 +01:00
Jonathan Li
f9b51e2656 pcsx2: Add IPU dithering to RGB32->RGB16 conversion 2020-05-17 21:33:41 +01:00
Jonathan Li
1ac1bc9a95 pcsx2: Move IPU RGB32->RGB16 format conversion to separate file 2020-05-17 21:33:41 +01:00
Jonathan Li
cb96dec8a6 pcsx2:windows: Remove DWM code
DwmEnableMMCSS doesn't seem to make a difference.
DwmSetPresentParameters is unused and is also not implemented from
Windows 8.1 onwards.
2020-05-17 18:13:39 +01:00
lightningterror
a30a6583c1 onepad: Update to latest controller database. 2020-05-16 22:20:06 +02:00
KrossX
61c4f9399a GSdx: Dithering setting Hotkey 2020-05-16 21:53:17 +02:00
KrossX
8b1eb3b456 GSdx: Dithering on Hardware 2020-05-16 21:53:17 +02:00
lightningterror
297459c9f6 gsdx-d3d11: Remove exclusive fullscreen code used in legacy gsopen. 2020-05-16 08:43:25 +02:00
lightningterror
37c0067caf gsdx-d3d11: Remove Dispatch function, was never used. 2020-05-16 08:43:25 +02:00
Raziel Znot
a14e3c25b0 Performance fix for Primal and Ghosthunter. (#3376)
Fix for terrible performance in US versions of Primal (all the time) and Ghosthunter (when encountering Teddy Bear and in the moment of Gator-Man's rush attack, maybe few other cases), Both games use shared code with pretty dumb wait loops in the microcode, those are absolutelly unnecessary and significantly kill performance on emulator.

* Performance fix for Primal and Ghosthunter

Fix for terrible performance in US versions of Primal (all the time) and Ghosthunter (when encountering Teddy Bear and in the moment of Gator-Man's rush attack, maybe few other cases). Both games use shared code with pretty dumb wait loops in the microcode, those are absolutely unnecessary and significantly kill performance on the emulator.
2020-05-16 00:06:49 +01:00
Filjo Abraham
b00792d6ce pcsx2: Change order of "Video (GS)" submenu. (#3265) 2020-05-15 16:46:46 +02:00
lightningterror
2e06e960bb gsdx-sw: Remove s_n (draw number) parameter from GetSizeFixedTEX0.
Opengl debug macro already provides draw number so it is esentially
useless.
2020-05-14 03:28:07 +02:00
water111
94e1635882 Make recLUT not hardcoded to 32 MB. (#3095)
This change makes the EE recompiler not hardcoded to working with 32 MB of RAM, and instead work with the amount of RAM set in Ps2MemSize::MainRam. The rest of PCSX2 seems to work fine with more than 32 MB of RAM - it is only the EE recompiler that has trouble. If the Ps2MemSize::MainRam value is not changed from the default 32 MB, there should be no change: 32 MB / 0x10000 = 0x200, the value that was there previously.

This may be helpful if anybody else in the future wants to emulate a PS2 dev kit with 128 MB or RAM, or maybe the PSX dvr thing which I think has 64 MB of RAM. I've confirmed that with the change, you could set Ps2MemSize::MainRam to 128 MB, and execute code with the recompiler that's above the first 32 MB of RAM, and do VIF and scratchpad DMA transfers from this upper memory as well.
2020-05-12 23:03:38 -07:00
arcum42
3c8d4029dd Only update the backup when freezing or defrosting, not when updating the ui. Refactor saveslot code. (#3363) 2020-05-12 22:55:34 -07:00
lightningterror
333cd61c17 gsdx: Rename BLEND_NO_BAR to BLEND_NO_REC.
Since we use it on d3d too it will better fit the naming.
2020-05-13 05:38:25 +02:00
refractionpcsx2
c009a95d68 Fix situation where a VIF IRQ triggers and the game triggers a STOP causing the IRQ to never trigger. (#3385)
Fixes Nitro Bike
2020-05-12 23:59:56 +01:00
refractionpcsx2
184f0df2c5 Modify VU PC addressing so it only multiplies by 8 before entering the p… (#3362)
* Modify VU addressing so it only multiplies by 8 before entering the program
Fixes issues with VU1 TPC being read multiplied by 8 (bad)

* Removed assert on SuperVU which no longer makes sense
2020-05-12 23:59:42 +01:00
lightningterror
593d948615 gsdx-hw: Adjust PABE logs and expand the mentioned games list for it. 2020-05-12 00:11:11 +02:00
lightningterror
e860742131 gsdx-ogl: Synchronize accurate blending enumeration with gui options. 2020-05-12 00:11:11 +02:00
lightningterror
aaaf80f785 gsdx-ogl: Some colclip adjustments.
- Always enable sw colclip for BLEND_NO_BAR.
Free blending and it's faster than standard hdr algo when Blending
Accuracy is disabled.

- Enable sw colclip for Safe FBMASK SW emulated.
instead of hdr mode with accumulation blend so we don't use a mix of sw
and hw blending. It is more accurate.
Test case: Superman Shadows of Apokolips, fixes shadows when blending is enabled.

- Use const to get rid of some warnings.
2020-05-12 00:11:11 +02:00
lightningterror
3f467cae67 gsdx-d3d11: Always enable sw colclip for BLEND_NO_BAR.
- Free blending and it's faster than standard hdr algo when Blending
Accuracy is disabled.

- Add assert when disabling hw blending, hw blending should only be disabled
on free/no barrier blending. D3D11 lacks other types of blending.

- Use const to get rid of some warnings.
2020-05-12 00:11:11 +02:00
lightningterror
95e91b8f44 gsdx-hw: add crc id for The Getaway EU region. 2020-05-11 21:34:29 +02:00
Shadix Aced
6b76db2973 Locales: Update French translations (fr_FR). (#3366) 2020-05-10 17:30:49 +02:00
Jonathan Li
5a5dc7f67f cmake: Fix issue with Harfbuzz not being found 2020-05-09 17:58:19 +01:00
Filjo Abraham
9319ed1afb Remove XAudio 2.7 file refrences 2020-05-09 11:18:39 +01:00
Filjo Abraham
6ef3bfb943 Merge XAudio.inl to XAudio.cpp 2020-05-09 11:18:39 +01:00
Filjo Abraham
9f664c5f9c Drop XAudio 2.7 module 2020-05-09 11:18:39 +01:00
lightningterror
b6e95fea52 GSdx.fx: Fix Border Pass, function should only run when PX_BORDER is enabled/read from the config.
Fixes an issue where external shader broke rendering when enabled if
config wasn't loaded properly.
2020-05-09 05:14:06 +02:00
Kojin
8bf6ba1440 Merge pull request #3263 from tadanokojin/ridge-racer-v
gsdx: mirror RGBAQ to 0x11
2020-05-07 20:31:01 +01:00
refractionpcsx2
ce1955ff60 Allow reading of 8bit timers (and other hardware pages) (#3361)
Fixes Robin Hood
2020-05-07 20:30:35 +01:00
Jonathan Li
16431653e4 gsdx:windows: Use precise floating point behaviour
Fast floating point behaviour can optimise out handling for special
floating point values e.g. NaNs. As GSdx needs to handle NaNs in a few
places, precise floating point behaviour should be used instead.

Fixes a flashlight regression in Silent Hill 2/3 that was caused by
VS2019 optimising out NaN handling.
2020-05-07 19:30:29 +01:00
arcum42
5c60f66890 Fix various cmake issues (#3352)
* Change the minimum cmake version to a range. Uses the new policies of the newer versions if you are on them, taking care of CMP0054.

* Grab a newer version of FindHarfBuzz.cmake from Webkit that fixes the cmake warning the earlier one was giving.

* Add in -ftime-trace as an option on build.sh.

* Precompile PrecompiledHeader.h if you are using cmake 3.16+ and GCC. (Currently disabled on clang due to compilation issues.)

* Check if target_precompile_headers exists rather than by version.

Co-authored-by: scribam <scribam@users.noreply.github.com>
2020-05-07 08:32:34 -07:00
orbea
84d090e2fd spu2-x: Make portaudio an optional dependency. (#3110)
* spu2-x: Make portaudio an optional dependency.

v2: Fix crash in the audio settings with SDL1 and without portaudio.

* cmake: Add PORTAUDIO_API to disable portaudio support.
2020-05-07 08:31:48 -07:00
lightningterror
1a52179298 Gamedb: port CART Fury Championship Racing gamefix patch to PAL version.
SLES-50267
Same patch works for both versions.
Close #3322
2020-05-07 15:57:26 +02:00
lightningterror
6f8dbe589c gsdumpgui: Use PS2EGetLibName instead of PSEGetLibName export. 2020-05-07 14:28:31 +02:00
Ryudo300
280553b41f gsdx-gui: Update logos to match current changes.
Remove mentions of ps1 emulators,
adjust the image slightly and change the colors to match api logo
colors.
Direct3D11 green, OpenGL blue.
2020-05-07 14:28:31 +02:00
lightningterror
0b9d68e60c gsdx: Remove psx/ps1 emulator compatibility.
ePSXe for example.
There is little to no benefit in keeping it, especially when nobody was
maintaining the code. If we ever want to reintroduce it we can do so
from older branches like 1.6.
Plus if we want to integrate plugins into pcsx2 itself this is a required step.
PS1 games can ofc still be played within pcsx2.
2020-05-07 14:28:31 +02:00
lightningterror
2b884a7e7c [skip ci] GSDumpGUI: Add context menu to GSdx and Internal log.
Copy, Clear Log, Select All.
2020-05-07 12:34:37 +02:00
Vyktory Knight
1ef35e7a1e Gamedb: Add memory card filters to several games. (#3364)
Let's Make a Soccer Team!, Virtua Pro Football, Pro Soccer Club o Tsukurou! Europe Championship, World Football Climax.

Technicals:
SLES-54151 reads data from SLES-54153 to allow importing players. Same with the Japanese equivalents.
The above pairing in reverse allows importation of custom teams exported in 54151's VS mode. Again, same with the Japanese equivalents.
SLPM-66442 is listed in PCSX2 Wiki but not in GameIndex.
2020-05-07 12:11:23 +02:00
refractionpcsx2
b8ed34a277 GSState: Mask A+D addresses. Fixes network configuration tool screen. 2020-05-07 12:07:42 +02:00
lightningterror
8f3b908e38 gsdx-gui: Remove custom resolution from the windows gui.
Leave it as an ini option only.
People should never use custom resolution as it causes many issues and
many features aren't supported with it.
On linux option was removed a long time ago.
2020-05-07 12:03:05 +02:00
4158 changed files with 924933 additions and 932828 deletions

View File

@@ -1,17 +1,17 @@
---
Language: Cpp
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignAfterOpenBracket: DontAlign
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlinesLeft: false
AlignEscapedNewlines: DontAlign
AlignOperands: true
AlignTrailingComments: true
AlignTrailingComments: false
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: Never
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
@@ -20,21 +20,22 @@ AlwaysBreakTemplateDeclarations: true
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
AfterControlStatement: false
AfterEnum: false
AfterControlStatement: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterObjCDeclaration: false
AfterObjCDeclaration: true
AfterStruct: true
AfterUnion: true
BeforeCatch: false
BeforeElse: false
BeforeCatch: true
BeforeElse: true
IndentBraces: false
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Custom
BreakBeforeTernaryOperators: false
BreakConstructorInitializersBeforeComma: true
BreakConstructorInitializers: BeforeComma
ColumnLimit: 0
CommentPragmas: '^ (IWYU pragma:|NOLINT)'
ConstructorInitializerAllOnOneLineOrOnePerLine: false
@@ -60,7 +61,7 @@ KeepEmptyLinesAtTheStartOfBlocks: true
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 3
NamespaceIndentation: None
NamespaceIndentation: All
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
@@ -70,8 +71,8 @@ PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerAlignment: Right
ReflowComments: true
PointerAlignment: Left
ReflowComments: false
SortIncludes: false
SpaceAfterCStyleCast: false
SpaceBeforeAssignmentOperators: true
@@ -85,5 +86,5 @@ SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 4
UseTab: Never
UseTab: ForContinuationAndIndentation
...

3
.codacy.yaml Normal file
View File

@@ -0,0 +1,3 @@
---
exclude_paths:
- '3rdparty/**'

View File

@@ -1,12 +0,0 @@
# Should always be specified at the top of the file outside of any sections
root = true
# TODO: Add one for resource script file and other Linux specific files ?
[*.{cpp,h}]
indent_style = tab
indent_size = 4
#trim_trailing_whitespace = true
[*.md]
trim_trailing_whitespace = false

56
.github/CONTRIBUTING.md vendored Normal file
View File

@@ -0,0 +1,56 @@
# So you want to contribute to PCSX2? Great
As a first step, please review these links as they'll help you understand how the development of PCSX2 works.
* [Just Starting Out](#just-starting-out)
* [Issue Reporting](#issue-reporting)
* [Pull Request Guidelines](#pull-request-guidelines)
* [General Documentation And Coding Strategies](#general-documentation-and-coding-strategies)
* [Tasks](#tasks)
## Just Starting Out
* If you're unfamilar with git, check out this [brief introduction to Git](https://github.com/PCSX2/pcsx2/wiki/Git-survival-guide)
* [How to build PCSX2 for Windows](https://github.com/PCSX2/pcsx2/wiki/Setting-up-the-PCSX2-repository-on-Windows-\(WIP---maybe-more-useful-as-a-manpage-instead%3F\))
* [How to build PCSX2 for Linux](https://github.com/PCSX2/pcsx2/wiki/Installing-on-Linux)
## Issue Reporting
* [How to write a useful issue](https://github.com/PCSX2/pcsx2/wiki/How-to-create-useful-and-valid-issues)
## Pull Request Guidelines
The following is a list of *general* style recommendations that will make reviewing and merging easier:
* Commit Messages
* Please try to prefix your commit message, indicating what area of the project was modified.
* For example `gs: message...`.
* Looking at the project's commit history will help with keeping prefixes consistent overtime, *there is no strictly enforced list*.
* Try to keep messages brief and informative
* Remove unnecessary commits and squash commits together when appropriate.
* If you are not familiar with rebasing with git, check out the following resources:
* CLI - https://thoughtbot.com/blog/git-interactive-rebase-squash-amend-rewriting-history
* GUI (SourceTree) - https://www.atlassian.com/blog/sourcetree/interactive-rebase-sourcetree
* Code Styling and Formatting
* [Consult the style guide](https://github.com/tadanokojin/pcsx2/blob/coding-guide/pcsx2/Docs/Coding_Guidelines.md)
* Run `clang-format` using the configuration file in the root of the repository
* Visual Studio Setup - https://devblogs.microsoft.com/cppblog/clangformat-support-in-visual-studio-2017-15-7-preview-1/
* IMPORTANT - if you are running `clang-format` on unrelated changes (ie. formatting an entire file), please do so in a separate commit.
* If you cannot scope your `clang-format` to just your changes and do not want to format unrelated code. Try your best to stick with the existing formatting already established in the file in question.
## General Documentation And Coding Strategies
* [Commenting Etiquette](https://github.com/PCSX2/pcsx2/wiki/Commenting-Etiquette)
* [Coding style](https://github.com/PCSX2/pcsx2/wiki/Code-Formatting-Guidelines)
* [More comprehensive style-guide (Currently in Draft)](https://github.com/tadanokojin/pcsx2/blob/coding-guide/pcsx2/Docs/Coding_Guidelines.md)
## Tasks
* [Todo List](https://github.com/PCSX2/pcsx2/wiki/Contributing-\(TODO-List\))
* [Issues](https://github.com/PCSX2/pcsx2/issues)
* [A collection of ideas to improve GS OGL](https://github.com/PCSX2/pcsx2/wiki/Todo-List)

3
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,3 @@
# These are supported funding model platforms
github: [PCSX2]

View File

@@ -0,0 +1,78 @@
# Docs - https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
name: Application Bug Report
description: Found a problem with the application itself (ie. bad file path handling, UX issue)? Help us improve it.
title: "[BUG]: "
labels: [Bug]
# assignees:
# - octocat
body:
- type: markdown
attributes:
value: |
## Important: Read First
Please do not make support requests on GitHub. Our issue tracker is for tracking bugs and feature requests only
If you need help configuring the emulator please make a request on our forums or contact us on discord
If you are unsure, start with [discord](https://discord.com/invite/TCz3t9k) or the [forums](https://forums.pcsx2.net/index.php)
Please make an effort to make sure your issue isn't already reported
### Please Avoid Issues Pertaining to the Following:
- We are **not** accepting bug reports for **PSX mode** at this time
- If you are interested in helping contribute to PSX mode please do so on the forums. Otherwise our recommendation is that you use a [proper PSX emulator](https://emulation.gametechwiki.com/index.php/PlayStation_emulators)
- We do **not** accept issues relating to **upscaling** at this time
- We are aware of the various problems with upscaling. The issue spans many games and having hundreds of issues for the same fundamental issues isn't particularly helpful. There are several workarounds for graphical problems that come as a result of upscaling
- Please try your game at native resolution before creating an issue
- If your bug is the result of upscaling please use the forums or discord for assistance with various upscaling workarounds. Additionally, the unofficial PCSX2 [Wiki](https://wiki.pcsx2.net/Main_Page) often lists various fixes for upscaling issues
- type: textarea
id: desc
attributes:
label: Describe the Bug
description: "A clear and concise description of what the bug is"
validations:
required: true
- type: textarea
id: repro
attributes:
label: Reproduction Steps
description: "Steps to reproduce the behavior"
validations:
required: true
- type: textarea
id: expect
attributes:
label: Expected Behavior
description: "A clear and concise description of what you expected to happen"
validations:
required: false
- type: input
id: rev
attributes:
label: PCSX2 Revision
description: "Please ensure you are on the latest version before making an issue"
placeholder: "Example: v1.7.1337"
validations:
required: true
- type: dropdown
id: os
attributes:
label: Operating System
options:
- Windows 11
- Windows 10 (64bit)
- Windows 8.1 (64bit)
- Linux (64bit) - Specify Distro Below
- macOS (Monteray)
- macOS (BigSur)
- macOS (Catalina)
- macOS (Mojave)
validations:
required: true
- type: input
id: os-distro
attributes:
label: If Linux - Specify Distro
placeholder: "Example: Arch"
validations:
required: false

11
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@@ -0,0 +1,11 @@
blank_issues_enabled: false
contact_links:
- name: Support Forums
url: https://forums.pcsx2.net/index.php
about: For community support and answers
- name: Discord
url: https://discord.com/invite/TCz3t9k
about: Get direct support and hang out with us
- name: Wiki
url: https://wiki.pcsx2.net/Main_Page
about: For user provided information and reports

View File

@@ -0,0 +1,143 @@
# Docs - https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
name: Emulation Bug Report
description: Problem in a game (ie. graphical artifacts, crashes)? Help us improve it.
title: "[BUG]: "
labels: [Bug]
# assignees:
# - octocat
body:
- type: markdown
attributes:
value: |
## Important: Read First
Please do not make support requests on GitHub. Our issue tracker is for tracking bugs and feature requests only
If you need help configuring the emulator please make a request on our forums or contact us on discord
If you are unsure, start with [discord](https://discord.com/invite/TCz3t9k) or the [forums](https://forums.pcsx2.net/index.php)
Please make an effort to make sure your issue isn't already reported
### Please Avoid Issues Pertaining to the Following:
- We are **not** accepting bug reports for **PSX mode** at this time
- If you are interested in helping contribute to PSX mode please do so on the forums. Otherwise our recommendation is that you use a [proper PSX emulator](https://emulation.gametechwiki.com/index.php/PlayStation_emulators)
- We do **not** accept issues relating to **upscaling** at this time
- We are aware of the various problems with upscaling. The issue spans many games and having hundreds of issues for the same fundamental issues isn't particularly helpful. There are several workarounds for graphical problems that come as a result of upscaling
- Please try your game at native resolution before creating an issue
- If your bug is the result of upscaling please use the forums or discord for assistance with various upscaling workarounds. Additionally, the unofficial PCSX2 [Wiki](https://wiki.pcsx2.net/Main_Page) often lists various fixes for upscaling issues
- type: textarea
id: desc
attributes:
label: Describe the Bug
description: "A clear and concise description of what the bug is"
validations:
required: true
- type: textarea
id: repro
attributes:
label: Reproduction Steps
description: "Steps to reproduce the behavior"
validations:
required: true
- type: textarea
id: expect
attributes:
label: Expected Behavior
description: "A clear and concise description of what you expected to happen"
validations:
required: false
- type: markdown
attributes:
value: |
## System Info
Please make sure your system meets our requirements for OS version, CPU and GPU
- [System Requirements](https://github.com/PCSX2/pcsx2#system-requirements)
Performance issues as a result of not meeting our hardware requirements are not valid
Please read our known issues pages for AMD and Intel drivers.
- [Intel Drivers](https://github.com/PCSX2/pcsx2/wiki/OpenGL-and-Intel-GPUs-All-you-need-to-know)
- [AMD Drivers](https://github.com/PCSX2/pcsx2/wiki/OpenGL-and-AMD-GPUs---All-you-need-to-know)
We are **not** accepting issues related to the **libretro** core. The libretro core is being maintained separately at this time
- type: input
id: rev
attributes:
label: PCSX2 Revision
description: "We only accept bug reports for the latest dev version. Please try upgrading before making an issue."
placeholder: "Example: v1.7.1337"
validations:
required: true
- type: dropdown
id: os
attributes:
label: Operating System
options:
- Windows 11
- Windows 10 (64bit)
- Windows 8.1 (64bit)
- Linux (64bit) - Specify Distro Below
- macOS (Monteray)
- macOS (BigSur)
- macOS (Catalina)
- macOS (Mojave)
validations:
required: true
- type: input
id: os-distro
attributes:
label: If Linux - Specify Distro
placeholder: "Example: Arch"
validations:
required: false
- type: input
id: cpu
attributes:
label: CPU
placeholder: "Example: i5-7600"
validations:
required: true
- type: input
id: gpu
attributes:
label: GPU
placeholder: "Example: GTX 1070"
validations:
required: true
- type: textarea
id: gsSettings
attributes:
label: GS Settings
description: "Any **non-default** settings for GS. If you don't want to list them out, please provide screenshots of your configuration window (including hw hacks if enabled)."
validations:
required: false
- type: textarea
id: emuSettings
attributes:
label: Emulation Settings
description: |
Any non-default core settings. If you don't want to list them out, please provide screenshots of your configuration window
Please note that the safe preset works for most games. MTVU can have some compatibility issues so please disable it before making a report
If you need to modify the settings manually because a game requires you to do so to work, please state that explicitly
validations:
required: false
- type: textarea
id: gsScreens
attributes:
label: GS Window Screenshots
description: "If your issue is graphical in nature and you think screenshots will help illustrate your issue, you may do that here."
validations:
required: false
- type: textarea
id: logsDumps
attributes:
label: "Logs & Dumps"
description: |
Please feel free to attach any logs, block dumps, GSdump, etc here
If your problem is graphical in nature it is highly recommended that you provide a GSdump. [GSdump Guide](https://forums.pcsx2.net/Thread-How-to-create-a-proper-GS-dump)
validations:
required: false

View File

@@ -0,0 +1,41 @@
# Docs - https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema
name: Feature request
description: Suggest a new feature or improve an existing one
title: "[Feature Request]: "
labels: ["Enhancement / Feature Request"]
# assignees:
# - octocat
body:
- type: textarea
id: desc
attributes:
label: Description
description: |
A concise description of the feature you want
Include step by step examples of how the feature should work under various circumstances
validations:
required: true
- type: textarea
id: reason
attributes:
label: Reason
description: |
Give a reason why you want this feature
- How will it make things easier for you?
- How does this feature help your enjoyment of the emulator?
- What does it provide that isn't being provided currently?
We are not accepting feature requests related to the libretro core as it's being maintained separately at this time
validations:
required: true
- type: textarea
id: examples
attributes:
label: Examples
description: |
Provide examples of the feature as implemented by other software
Include screenshots or video if you like to help demonstrate how you'd like this feature to work
validations:
required: true

8
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@@ -0,0 +1,8 @@
### Description of Changes
<!-- Brief description or overview on what was changed in the PR -->
### Rationale behind Changes
<!-- Why were these changes made? What problem does it solve / area does it improve? -->
### Suggested Testing Steps
<!-- If applicable, including examples you've already tested with / recommendations for how to test further is very helpful! -->

8
.github/dependabot.yml vendored Normal file
View File

@@ -0,0 +1,8 @@
# Set update schedule for GitHub Actions
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
# Check for updates to GitHub Actions every week
interval: "weekly"

125
.github/labeler.yml vendored Normal file
View File

@@ -0,0 +1,125 @@
# Documentation - https://github.com/actions/labeler
# General Labels
'Build | Project System':
- '.github/*'
- '.github/**/*'
- '*.sln'
- '**/*.sln'
- '*.vcxproj*'
- '**/*.vcxproj*'
- 'cmake/*'
- 'cmake/**/*'
- 'CMakeLists.txt'
- '**/CMakeLists.txt'
- 'buildbot.xml'
- 'build.sh'
'Dependencies':
- '3rdparty/*'
- '3rdparty/**/*'
- '**/3rdpartyDeps.props'
- '.gitmodules'
'Documentation':
- '*.md'
- '**/*.md'
- '*.pdf'
- '**/*.pdf'
'GUI/WX':
- 'pcsx2/gui/*'
- 'pcsx2/gui/**/*'
- 'pcsx2/SPU2/wx/*'
- 'pcsx2/SPU2/wx/**/*'
- 'pcsx2/PAD/Linux/wx_dialog/*'
- 'pcsx2/PAD/Linux/wx_dialog/**/*'
- 'pcsx2/GS/Window/GSwxDialog.h'
'GUI/Qt':
- 'pcsx2-qt/*'
- 'pcsx2-qt/**/*'
- '3rdparty/Qt/*'
- '3rdparty/Qt/**/*'
'GameDB':
- '**/GameIndex.*'
'Installer | Package':
- 'build.sh'
# Tools / Features
'Debugger':
- 'pcsx2/DebugTools/*'
- 'pcsx2/DebugTools/**/*'
- 'pcsx2/gui/Debugger/*'
- 'pcsx2/gui/Debugger/**/*'
'IPC':
- 'pcsx2/IPC*'
- 'pcsx2/**/IPC*'
'TAS Functionality':
- 'pcsx2/Recording/*'
- 'pcsx2/Recording/**/*'
# Emulation Components
'Counters':
- 'pcsx2/Counters.*'
'Vector Units':
- 'pcsx2/VU*'
- 'pcsx2/**/VU*'
- 'pcsx2/*VU*'
- 'pcsx2/**/*VU*'
'VIF':
- 'pcsx2/Vif*'
- 'pcsx2/**/Vif*'
- 'pcsx2/VIF*'
- 'pcsx2/**/VIF*'
# GS Related Labels
'GS':
- 'pcsx2/GS/*'
- 'pcsx2/GS/**/*'
'GS: Direct3D 11':
- 'pcsx2/GS/Renderers/DX11/*'
- 'pcsx2/GS/Renderers/DX11/**/*'
'GS: Direct3D 12':
- 'pcsx2/GS/Renderers/DX12/*'
- 'pcsx2/GS/Renderers/DX12/**/*'
'GS: Hardware':
- 'pcsx2/GS/Renderers/HW/*'
- 'pcsx2/GS/Renderers/HW/**/*'
'GS: OpenGL':
- 'pcsx2/GS/Renderers/OpenGL/*'
- 'pcsx2/GS/Renderers/OpenGL/**/*'
'GS: Vulkan':
- 'pcsx2/GS/Renderers/Vulkan/*'
- 'pcsx2/GS/Renderers/Vulkan/**/*'
'GS: Metal':
- 'pcsx2/GS/Renderers/Metal/*'
- 'pcsx2/GS/Renderers/Metal/**/*'
'GS: Texture Cache':
- 'pcsx2/GS/Renderers/*TextureCache*.*'
- 'pcsx2/GS/Renderers/**/*TextureCache*.*'
'GS: Software':
- 'pcsx2/GS/Renderers/SW/*'
- 'pcsx2/GS/Renderers/SW/**/*'
# Other Core Components
'CDVD':
- 'pcsx2/CDVD/*'
- 'pcsx2/CDVD/**/*'
'DEV9':
- 'pcsx2/DEV9/*'
- 'pcsx2/DEV9/**/*'
'IPU':
- 'pcsx2/IPU/*'
- 'pcsx2/IPU/**/*'
'Memory Card':
- 'pcsx2/gui/MemoryCard*'
- 'pcsx2/gui/**/MemoryCard*'
'PAD: Linux/Mac':
- 'pcsx2/PAD/Linux/*'
- 'pcsx2/PAD/Linux/**/*'
'PAD: Windows':
- 'pcsx2/PAD/Windows/*'
- 'pcsx2/PAD/Windows/**/*'
'SPU2':
- 'pcsx2/SPU2/*'
- 'pcsx2/SPU2/**/*'
'USB':
- 'pcsx2/USB/*'
- 'pcsx2/USB/**/*'

View File

@@ -0,0 +1,14 @@
# CI Documentation
## Releases
```mermaid
sequenceDiagram
PCSX2 Repo->>Actions: PR is merged or commit is pushed to master
Actions->>PCSX2 Repo: Increment latest tag and push, create a draft release
Actions->>Actions: Kicked off pipeline on the tag push, build relevant configs
Actions->>PCSX2 Repo: Rename and upload artifacts to draft release, publish the release
Actions->>Discord: Announce release via a WebHook
PCSX2 Repo->>Web API: POST webhook to API informing it that a new release has occurred
Web API->>Web API: Update cache with new release
```

View File

@@ -0,0 +1,29 @@
name: 🏭 Update Controller Database
on:
schedule:
- cron: "0 16 * * 1" # every monday @ 12pm EST - https://crontab.guru/#0_16_*_*_1
jobs:
update-controller-db:
if: github.repository == 'PCSX2/pcsx2'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Get Latest DB and Prepare DB File
run: |
cd .github/workflows/scripts/controller-db/
wget -O game_controller_db.txt https://raw.githubusercontent.com/gabomdq/SDL_GameControllerDB/master/gamecontrollerdb.txt
python ./update-db.py
mv ./game_controller_db.txt ${{github.workspace}}/bin/resources/game_controller_db.txt
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
title: "PAD: Update to latest controller database"
commit-message: "PAD: Update to latest controller database."
committer: "PCSX2 Bot <PCSX2Bot@users.noreply.github.com>"
author: "PCSX2 Bot <PCSX2Bot@users.noreply.github.com>"
body: "Weekly automatic update of SDL Controller DB"
reviewers: lightningterror

34
.github/workflows/lint_gamedb.yml vendored Normal file
View File

@@ -0,0 +1,34 @@
name: 📝 Validate GameDB
on:
push:
branches:
- master
paths:
- '**/GameIndex.yaml'
pull_request:
branches:
- master
paths:
- '**/GameIndex.yaml'
jobs:
lint:
name: Lint and Validate GameDB
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Validate Contents
env:
GAMEDB_PATH: ./bin/resources/GameIndex.yaml
SCRIPT_DIR: .github/workflows/scripts/lint/gamedb
run: |
pip install -r "${SCRIPT_DIR}/requirements.txt"
python "${SCRIPT_DIR}/lint.py"
- name: Check Formatting
run: |
npm install -g prettier
prettier --check ./bin/resources/GameIndex.yaml

View File

@@ -0,0 +1,74 @@
name: 🐧 Linux Builds
on:
push:
branches:
- '*'
pull_request:
branches:
- master
jobs:
build_gcc_lto:
name: "GCC"
uses: ./.github/workflows/linux_build_wx.yml
with:
jobName: "with LTO"
compiler: gcc
cmakeflags: "-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON"
buildAppImage: true
secrets: inherit
# (PCH conflicts with ccache, fixed by https://gitlab.kitware.com/cmake/cmake/-/merge_requests/4400)
build_gcc_nopch:
name: "GCC"
uses: ./.github/workflows/linux_build_wx.yml
with:
jobName: "No PCH"
compiler: gcc
cmakeflags: "-DCMAKE_DISABLE_PRECOMPILE_HEADERS=ON"
detail: " nopch"
secrets: inherit
build_gcc_nopch_avx2:
name: "GCC"
uses: ./.github/workflows/linux_build_wx.yml
with:
jobName: "AVX2 and No PCH"
compiler: gcc
cmakeflags: "-DCMAKE_DISABLE_PRECOMPILE_HEADERS=ON -DARCH_FLAG=-march=haswell"
detail: " avx2 nopch"
secrets: inherit
build_clang_nopch:
name: "Clang"
uses: ./.github/workflows/linux_build_wx.yml
with:
jobName: "No PCH"
compiler: clang
cmakeflags: ""
detail: " nopch"
secrets: inherit
build_linux_qt_sse4:
name: "AppImage"
uses: ./.github/workflows/linux_build_qt.yml
with:
jobName: "Qt SSE4"
compiler: clang
cmakeflags: ""
simd: "SSE4"
buildAppImage: true
secrets: inherit
build_linux_qt_avx2:
name: "AppImage"
uses: ./.github/workflows/linux_build_qt.yml
with:
jobName: "Qt AVX2"
detail: ""
compiler: clang
cmakeflags: "-DARCH_FLAG=-march=haswell"
simd: "AVX2"
buildAppImage: true
secrets: inherit

138
.github/workflows/linux_build_qt.yml vendored Normal file
View File

@@ -0,0 +1,138 @@
name: Linux Build Steps
on:
workflow_call:
inputs:
jobName:
required: true
type: string
os:
required: false
type: string
default: ubuntu-20.04
platform:
required: false
type: string
default: x64
compiler:
required: true
type: string
cmakeflags:
required: true
type: string
buildAppImage:
required: false
type: boolean
default: false
detail:
required: false
type: string
default: ""
simd:
required: false
type: string
default: ""
cheats_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2_patches/releases/latest/download
jobs:
build_linux:
name: ${{ inputs.jobName }}
runs-on: ${{ inputs.os }}
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
timeout-minutes: 60
env:
CCACHE_BASEDIR: ${{ github.workspace }}
CCACHE_DIR: ${{ github.workspace }}/.ccache
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 9
CCACHE_MAXSIZE: 100M
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Prepare Artifact Metadata
id: artifact-metadata
shell: bash
env:
OS: linux
GUI_FRAMEWORK: QT
ARCH: ${{ inputs.platform }}
SIMD: ${{ inputs.simd }}
EVENT_NAME: ${{ github.event_name }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_NUM: ${{ github.event.pull_request.number }}
PR_SHA: ${{ github.event.pull_request.head.sha }}
run: ./.github/workflows/scripts/common/name-artifacts.sh
# -- SETUP CCACHE - https://cristianadam.eu/20200113/speeding-up-c-plus-plus-github-actions-using-ccache/
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v3
with:
path: .ccache
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.compiler }} ${{ inputs.simd }} ${{ inputs.detail }} ccache ${{ steps.ccache_cache_timestamp.outputs.timestamp }}
restore-keys: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.compiler }} ${{ inputs.simd }} ${{ inputs.detail }} ccache
- name: Install Packages
env:
COMPILER: ${{ inputs.compiler }}
run: .github/workflows/scripts/linux/install-packages-qt.sh
- name: Cache Dependencies
id: cache-deps
uses: actions/cache@v3
with:
path: ~/deps
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.gui }} deps ${{ hashFiles('.github/workflows/scripts/linux/build-dependencies-qt.sh') }}
- name: Build Dependencies
if: steps.cache-deps.outputs.cache-hit != 'true'
run: .github/workflows/scripts/linux/build-dependencies-qt.sh
- name: Download cheats
run: |
cd bin/resources
aria2c -Z "${{ inputs.cheats_url }}/cheats_ni.zip" "${{ inputs.cheats_url }}/cheats_ws.zip"
- name: Generate CMake
env:
COMPILER: ${{ inputs.compiler }}
ADDITIONAL_CMAKE_ARGS: ${{ inputs.cmakeflags }}
run: .github/workflows/scripts/linux/generate-cmake-qt.sh
- name: Build PCSX2
working-directory: build
run: ../.github/workflows/scripts/linux/compile.sh
- name: Run Tests
working-directory: ./build
run: ninja unittests
- name: Package AppImage
if: inputs.buildAppImage == true
env:
NAME: ${{ steps.artifact-metadata.outputs.artifact-name }}
run: |
ninja -C build install
.github/workflows/scripts/linux/appimage-qt.sh "$(realpath .)" "$HOME/deps" "$NAME"
mkdir -p "$GITHUB_WORKSPACE"/ci-artifacts/
mv "${NAME}.AppImage" "$GITHUB_WORKSPACE"/ci-artifacts/
- name: Upload artifact
if: inputs.buildAppImage == true
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
path: ci-artifacts

155
.github/workflows/linux_build_wx.yml vendored Normal file
View File

@@ -0,0 +1,155 @@
name: Linux Build Steps
on:
workflow_call:
inputs:
jobName:
required: true
type: string
os:
required: false
type: string
default: ubuntu-20.04
platform:
required: false
type: string
default: x64
compiler:
required: true
type: string
cmakeflags:
required: true
type: string
buildAppImage:
required: false
type: boolean
default: false
detail:
required: false
type: string
default: ""
cheats_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2_patches/releases/latest/download
jobs:
build_linux:
name: ${{ inputs.jobName }}
runs-on: ${{ inputs.os }}
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
timeout-minutes: 60
env:
CCACHE_BASEDIR: ${{ github.workspace }}
CCACHE_DIR: ${{ github.workspace }}/.ccache
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 9
CCACHE_MAXSIZE: 100M
SDL: SDL2-2.24.0
PATCHELF_VERSION: 0.12
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Prepare Artifact Metadata
id: artifact-metadata
shell: bash
env:
OS: linux
GUI_FRAMEWORK: wxWidgets
ARCH: ${{ inputs.platform }}
SIMD: ''
EVENT_NAME: ${{ github.event_name }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_NUM: ${{ github.event.pull_request.number }}
PR_SHA: ${{ github.event.pull_request.head.sha }}
run: ./.github/workflows/scripts/common/name-artifacts.sh
# -- SETUP CCACHE - https://cristianadam.eu/20200113/speeding-up-c-plus-plus-github-actions-using-ccache/
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v3
with:
path: .ccache
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.compiler }}${{ inputs.detail }} ccache ${{ steps.ccache_cache_timestamp.outputs.timestamp }}
restore-keys: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.compiler }}${{ inputs.detail }} ccache
- name: Install Packages
env:
PLATFORM: ${{ inputs.platform }}
COMPILER: ${{ inputs.compiler }}
run: .github/workflows/scripts/linux/install-packages.sh
- name: Cache Dependencies
uses: actions/cache@v3
with:
path: |
3rdparty/${{ env.SDL }}
3rdparty/patchelf-${{ env.PATCHELF_VERSION }}
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ env.SDL }} patchelf-${{ env.PATCHELF_VERSION }}
- name: Build Dependencies
run: |
if [[ ! -e 3rdparty/patchelf-${{ env.PATCHELF_VERSION }} ]]; then
curl -sSfL https://github.com/NixOS/patchelf/releases/download/${{ env.PATCHELF_VERSION }}/patchelf-${{ env.PATCHELF_VERSION }}.tar.bz2 | tar -xjC 3rdparty
mv 3rdparty/patchelf-${{ env.PATCHELF_VERSION }}* 3rdparty/patchelf-${{ env.PATCHELF_VERSION }}
cd 3rdparty/patchelf-${{ env.PATCHELF_VERSION }}
./configure
make && cd ../../
fi
sudo make -C 3rdparty/patchelf-${{ env.PATCHELF_VERSION }} install
if [[ ! -e 3rdparty/${{ env.SDL }} ]]; then
curl -sL https://libsdl.org/release/${{ env.SDL }}.tar.gz | tar -xzC 3rdparty
cd 3rdparty/${{ env.SDL }}
if [ "${{ inputs.platform }}" == "x86" ]; then
./configure --build=i686-pc-linux-gnu CC=${{ inputs.compiler }} CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 --prefix=/usr --libdir=/usr/lib/i386-linux-gnu
else
./configure --prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu
fi
make -j $(getconf _NPROCESSORS_ONLN) && cd ../../
fi
sudo make -C 3rdparty/${{ env.SDL }} install
- name: Download cheats
run: |
cd bin/resources
aria2c -Z "${{ inputs.cheats_url }}/cheats_ni.zip" "${{ inputs.cheats_url }}/cheats_ws.zip"
- name: Generate CMake
env:
PLATFORM: ${{ inputs.platform }}
COMPILER: ${{ inputs.compiler }}
ADDITIONAL_CMAKE_ARGS: ${{ inputs.cmakeflags }}
run: .github/workflows/scripts/linux/generate-cmake.sh
- name: Build PCSX2
working-directory: build
run: ../.github/workflows/scripts/linux/compile.sh
- name: Run Tests
working-directory: ./build
run: ninja unittests
- name: Package AppImage
if: inputs.buildAppImage == true
env:
PLATFORM: ${{ inputs.platform }}
COMPILER: ${{ inputs.compiler }}
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
run: .github/workflows/scripts/linux/appimage.sh
- name: Upload artifact
if: inputs.buildAppImage == true
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
path: ci-artifacts

153
.github/workflows/macos_build.yml vendored Normal file
View File

@@ -0,0 +1,153 @@
name: MacOS Build Steps
on:
workflow_call:
inputs:
jobName:
required: true
type: string
os:
required: false
type: string
default: macos-11.0
platform:
required: false
type: string
default: x64
gui:
required: true
type: string
cheats_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2_patches/releases/latest/download
jobs:
build_macos:
name: ${{ inputs.jobName }}
runs-on: ${{ inputs.os }}
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
timeout-minutes: 90
env:
POWERSHELL_TELEMETRY_OPTOUT: 1
CCACHE_BASEDIR: ${{ github.workspace }}
CCACHE_DIR: ${{ github.workspace }}/.ccache
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 9
CCACHE_MAXSIZE: 100M
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Prepare Artifact Metadata
id: artifact-metadata
shell: bash
env:
OS: macos
GUI_FRAMEWORK: ${{ inputs.gui }}
ARCH: ${{ inputs.platform }}
SIMD: ''
EVENT_NAME: ${{ github.event_name }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_NUM: ${{ github.event.pull_request.number }}
PR_SHA: ${{ github.event.pull_request.head.sha }}
run: ./.github/workflows/scripts/common/name-artifacts.sh
- name: Install Packages
env:
PLATFORM: ${{ inputs.platform }}
HOMEBREW_NO_INSTALL_CLEANUP: 1
HOMEBREW_NO_ANALYTICS: 1
run: |
brew unlink libjpeg || true # Conflicts with our self-built dependencies
brew unlink libpng || true
# Unlike other packages, brew's MoltenVK build uses MoltenVK's minimum macOS version of 10.13 so we can use it
if ! brew install molten-vk ccache; then
brew update
brew install molten-vk ccache
fi
- name: Cache Dependencies
id: cache-deps
uses: actions/cache@v3
with:
path: ~/deps
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.gui }} deps ${{ hashFiles('.github/workflows/scripts/macos/build-dependencies.sh') }}
- name: Build Dependencies
if: steps.cache-deps.outputs.cache-hit != 'true'
env:
GUI: ${{ inputs.gui }}
run: .github/workflows/scripts/macos/build-dependencies.sh
- name: Download cheats
run: |
cd bin/resources
aria2c -Z "${{ inputs.cheats_url }}/cheats_ni.zip" "${{ inputs.cheats_url }}/cheats_ws.zip"
# -- SETUP CCACHE - https://cristianadam.eu/20200113/speeding-up-c-plus-plus-github-actions-using-ccache/
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: Cache ccache cache
uses: actions/cache@v3
with:
path: .ccache
key: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.gui }} ccache ${{ steps.ccache_cache_timestamp.outputs.timestamp }}
restore-keys: ${{ inputs.os }} ${{ inputs.platform }} ${{ inputs.gui }} ccache
- name: Generate CMake Files
run: |
QT_BUILD=$([ "${{ inputs.gui }}" == "Qt" ] && echo "ON" || echo "OFF")
cmake -DCMAKE_PREFIX_PATH="$HOME/deps" \
-DCMAKE_BUILD_TYPE=Release \
-DQT_BUILD="$QT_BUILD" \
-DUSE_OPENGL=OFF \
-DDISABLE_ADVANCE_SIMD=ON \
-DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON \
-DUSE_SYSTEM_LIBS=OFF \
-DUSE_SYSTEM_SDL2=ON \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_DISABLE_PRECOMPILE_HEADERS=ON \
-B build .
- name: Build PCSX2
working-directory: build
run: |
ccache -p
ccache -s
ccache -z
make -j$(getconf _NPROCESSORS_ONLN) # macOS doesn't use make install
ccache -s
- name: Run Tests
working-directory: build
run: make -j$(getconf _NPROCESSORS_ONLN) unittests
- name: Prepare Build Artifacts
run: |
cp /usr/local/lib/libMoltenVK.dylib build/pcsx2*/PCSX2.app/Contents/Frameworks/
TAG="$(git tag --points-at HEAD)"
if [ -z "$TAG" ]; then
APPNAME="${{ steps.artifact-metadata.outputs.artifact-name }}"
else
APPNAME="PCSX2-$TAG"
fi
mv build/pcsx2*/PCSX2.app "$APPNAME.app"
tar cvzf "${{ steps.artifact-metadata.outputs.artifact-name }}.tar.gz" "$APPNAME.app"
mkdir ci-artifacts
cp "${{ steps.artifact-metadata.outputs.artifact-name }}.tar.gz" ci-artifacts/macOS-${{ inputs.gui }}.tar.gz
- name: Upload Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
path: "*.tar.gz"

View File

@@ -0,0 +1,25 @@
name: 🍎 MacOS Builds
on:
push:
branches:
- '*'
pull_request:
branches:
- master
jobs:
build_macos_wx:
name: "Defaults"
uses: ./.github/workflows/macos_build.yml
with:
jobName: "wxWidgets"
gui: "wxWidgets"
secrets: inherit
build_macos_qt:
name: "Defaults"
uses: ./.github/workflows/macos_build.yml
with:
jobName: "Qt"
gui: "Qt"
secrets: inherit

24
.github/workflows/release_announce.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
name: 📢 Announce Release
on:
release:
types: [published]
jobs:
announce:
if: github.repository == 'PCSX2/pcsx2'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- name: Announce Release
env:
DISCORD_BUILD_WEBHOOK: ${{ secrets.DISCORD_BUILD_WEBHOOK }}
run: |
cd ./.github/workflows/scripts/releases/announce-release
npm ci
node index.js

71
.github/workflows/release_new_tag.yml vendored Normal file
View File

@@ -0,0 +1,71 @@
# Whenever a commit is pushed to master (ideally via a pull-request!)
# this action will create the next release, which means:
# 1. tag master with the proper version
# 2. create a new draft release (pre-released if a nightly build)
# 3. add release notes
name: 🏭 Create Release
on:
push:
branches:
- master
# TODO - future work
# workflow_dispatch:
# inputs:
# isStable:
# description: 'Should it be a stable release?'
# required: true
# default: 'false'
# versionTag:
# description: 'The version to tag with'
# required: true
jobs:
cut-release:
if: github.repository == 'PCSX2/pcsx2'
runs-on: ubuntu-latest
name: "Create Tag and Release"
steps:
- uses: actions/checkout@v3
# Docs - https://github.com/mathieudutour/github-tag-action
- name: Bump Version and Push Tag
id: tag_version
uses: mathieudutour/github-tag-action@v6.0
with:
# Workflows cannot trigger other workflows implicitly
# - https://github.community/t/github-actions-workflow-not-triggering-with-tag-push/17053/7
github_token: ${{ secrets.BOT_PAT }}
tag_prefix: v
default_bump: patch
# TODO - we could do this and remove the node.js script, but auto-generated notes only work
# with PRs -- not commits (determine how much we care).
# - name: Create Draft Release
# env:
# GITHUB_TOKEN: ${{ secrets.BOT_PAT }}
# run: |
# echo "Creating release with tag - ${{ steps.tag_version.outputs.new_tag }}"
# gh release create ${{ steps.tag_version.outputs.new_tag }} --draft --generate-notes -title ${{ steps.tag_version.outputs.new_tag }}
- name: Generate Release Notes
env:
OWNER: PCSX2
REPO: pcsx2
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMMIT_SHA: ${{ github.SHA }}
run: |
cd ./.github/workflows/scripts/releases/generate-release-notes
npm ci
node index.js
mv ./release-notes.md ${GITHUB_WORKSPACE}/release-notes.md
- name: Create a GitHub Release
uses: softprops/action-gh-release@v1
if: steps.tag_version.outputs.new_tag
with:
body_path: ./release-notes.md
draft: true
prerelease: true
tag_name: ${{ steps.tag_version.outputs.new_tag }}

162
.github/workflows/release_pipeline.yml vendored Normal file
View File

@@ -0,0 +1,162 @@
name: 🏭 Release Pipeline
on:
push:
tags:
- v*
jobs:
# Build Everything
# Linux
build_gcc_lto:
if: github.repository == 'PCSX2/pcsx2'
name: "Linux - AppImage"
uses: ./.github/workflows/linux_build_wx.yml
with:
jobName: "wxWidgets"
compiler: gcc
cmakeflags: "-DLTO_PCSX2_CORE=ON"
buildAppImage: true
secrets: inherit
build_linux_qt_sse4:
if: github.repository == 'PCSX2/pcsx2'
name: "Linux - AppImage SSE4"
uses: ./.github/workflows/linux_build_qt.yml
with:
jobName: "Qt"
compiler: clang
cmakeflags: ""
simd: "SSE4"
buildAppImage: true
secrets: inherit
build_linux_qt_avx2:
if: github.repository == 'PCSX2/pcsx2'
name: "Linux - AppImage AVX2"
uses: ./.github/workflows/linux_build_qt.yml
with:
jobName: "Qt"
detail: ""
compiler: clang
cmakeflags: "-DARCH_FLAG=-march=haswell"
simd: "AVX2"
buildAppImage: true
secrets: inherit
# Windows
build_wx_sse4:
if: github.repository == 'PCSX2/pcsx2'
name: "Windows - SSE4"
uses: ./.github/workflows/windows_build_wx.yml
with:
jobName: wxWidgets
configuration: Release
simd: "SSE4"
secrets: inherit
build_wx_avx2:
if: github.repository == 'PCSX2/pcsx2'
name: "Windows - AVX2"
uses: ./.github/workflows/windows_build_wx.yml
with:
jobName: wxWidgets
configuration: Release AVX2
secrets: inherit
build_qt_sse4:
if: github.repository == 'PCSX2/pcsx2'
name: "Windows - SSE4"
uses: ./.github/workflows/windows_build_qt.yml
with:
jobName: Qt
configuration: Release
simd: "SSE4"
secrets: inherit
build_qt_avx2:
if: github.repository == 'PCSX2/pcsx2'
name: "Windows - AVX2"
uses: ./.github/workflows/windows_build_qt.yml
with:
jobName: Qt
configuration: Release AVX2
secrets: inherit
# MacOS
build_macos_wx:
if: github.repository == 'PCSX2/pcsx2'
name: "MacOS"
uses: ./.github/workflows/macos_build.yml
with:
jobName: "wxWidgets"
gui: "wxWidgets"
secrets: inherit
build_macos_qt:
if: github.repository == 'PCSX2/pcsx2'
name: "MacOS"
uses: ./.github/workflows/macos_build.yml
with:
jobName: "Qt"
gui: "Qt"
secrets: inherit
# Upload the Artifacts
upload_artifacts:
if: github.repository == 'PCSX2/pcsx2'
needs:
- build_gcc_lto
- build_linux_qt_sse4
- build_linux_qt_avx2
- build_wx_sse4
- build_wx_avx2
- build_qt_sse4
- build_qt_avx2
- build_macos_wx
- build_macos_qt
name: "Upload Artifacts"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Prepare Artifact Folder
run: mkdir ./ci-artifacts/
- uses: actions/download-artifact@v3
name: Download all Artifacts
with:
path: ./ci-artifacts/
- name: Display structure of downloaded files
run: ls ./ci-artifacts/
# Prepare artifacts, they are all zips from github!
- name: Prepare Artifacts
working-directory: ./ci-artifacts/
run: for d in *windows*/; do 7z a "${d}asset.7z" ./$d/*; done
# Artifact Naming:
# MacOS: PCSX2-<tag>-macOS-[additional hyphen seperated tags]
# Windows|Linux: PCSX2-<tag>-<windows|linux>-<32bit|64bit>--[additional hyphen seperated tags]
- name: Name and Upload the Release Assets
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG: ${{ github.REF }}
SCAN_DIR: ${{ github.WORKSPACE }}/ci-artifacts
OUT_DIR: ${{ github.WORKSPACE }}/ci-artifacts/out
run: |
gh release list --repo PCSX2/pcsx2
mkdir -p ${{ github.WORKSPACE }}/ci-artifacts/out
python ./.github/workflows/scripts/releases/rename-release-assets.py
ls ${{ github.WORKSPACE }}/ci-artifacts/out
TAG_VAL=$(echo ${{ github.REF }} | awk -F'refs/tags/' '{print $2}')
gh release upload "${TAG_VAL}" ${{ github.WORKSPACE }}/ci-artifacts/out/* --repo PCSX2/pcsx2 --clobber
- name: Publish Release
env:
GITHUB_TOKEN: ${{ secrets.BOT_PAT }}
run: |
TAG_VAL=$(echo ${{ github.REF }} | awk -F'refs/tags/' '{print $2}')
gh release edit ${TAG_VAL} --draft=false --repo PCSX2/pcsx2

View File

@@ -0,0 +1,57 @@
#!/bin/bash
# Artifact Naming Scheme:
# PCSX2-<OS>-<GUI>-[ARCH]-[SIMD]-[pr\[PR_NUM\]]-[title|sha\[SHA|PR_TITLE\]
# -- limited to 200 chars
# Outputs:
# - artifact-name
# Inputs as env-vars
# OS
# BUILD_SYSTEM
# GUI_FRAMEWORK
# ARCH
# SIMD
# EVENT_NAME
# PR_TITLE
# PR_NUM
# PR_SHA
NAME=""
if [ "${OS}" == "macos" ]; then
NAME="PCSX2-${OS}-${GUI_FRAMEWORK}"
elif [[ ("${OS}" == "windows" && "$BUILD_SYSTEM" != "cmake") || ("$OS" == "linux" && "$GUI_FRAMEWORK" == "QT") ]]; then
NAME="PCSX2-${OS}-${GUI_FRAMEWORK}-${ARCH}-${SIMD}"
else
NAME="PCSX2-${OS}-${GUI_FRAMEWORK}-${ARCH}"
fi
# Add cmake if used to differentate it from msbuild builds
# Else the two artifacts will have the same name and the files will be merged
if [[ ! -z "${BUILD_SYSTEM}" ]]; then
if [ "${BUILD_SYSTEM}" == "cmake" ]; then
NAME="${NAME}-${BUILD_SYSTEM}"
fi
fi
# Add PR / Commit Metadata
if [ "$EVENT_NAME" == "pull_request" ]; then
PR_SHA=$(git rev-parse --short "${PR_SHA}")
if [ ! -z "${PR_NUM}" ]; then
NAME="${NAME}-pr[${PR_NUM}]"
fi
NAME="${NAME}-sha[${PR_SHA}]"
if [ ! -z "${PR_TITLE}" ]; then
PR_TITLE=$(echo "${PR_TITLE}" | tr -cd '[a-zA-Z0-9[:space:]]_-')
NAME="${NAME}-title[${PR_TITLE}"
fi
else
SHA=$(git rev-parse --short "$GITHUB_SHA")
NAME="${NAME}-sha[${SHA}"
fi
# Trim the Name
NAME=$(printf "%.199s]" "$NAME")
echo "${NAME}"
echo "##[set-output name=artifact-name;]${NAME}"

View File

@@ -0,0 +1 @@
*.txt

View File

@@ -0,0 +1,39 @@
import os
relevant_categories = [
"# Windows",
"# Mac OS X",
"# Linux"
]
header_lines = []
new_db_contents = []
def is_relevant_category(line):
for category in relevant_categories:
if category in line:
return True
return False
with open("./game_controller_db.txt") as file:
lines = file.readlines()
finished_header = False
processing_section = False
for line in lines:
if finished_header is False:
header_lines.append(line)
if line == "\n":
finished_header = True
if processing_section and line == "\n":
processing_section = False
new_db_contents.append("\n")
if is_relevant_category(line) and processing_section is False:
processing_section = True
new_db_contents.append(line)
elif processing_section:
new_db_contents.append(line)
os.remove("./game_controller_db.txt")
with open("./game_controller_db.txt", "w") as f:
f.writelines(header_lines)
f.writelines(new_db_contents)

View File

@@ -0,0 +1,270 @@
import os
import yaml
# Assumes this is ran from the root of the repository
file_path = os.environ['GAMEDB_PATH']
# These settings have to be manually kept in sync with the emulator code unfortunately.
# up to date validation should ALWAYS be provided via the application!
allowed_game_options = [
"name",
"region",
"compat",
"roundModes",
"clampModes",
"gameFixes",
"gsHWFixes",
"speedHacks",
"memcardFilters",
"patches",
]
allowed_round_modes = ["eeRoundMode", "vuRoundMode"]
allowed_clamp_modes = ["eeClampMode", "vuClampMode"]
allowed_game_fixes = [
"FpuMulHack",
"FpuNegDivHack",
"GoemonTlbHack",
"SoftwareRendererFMVHack",
"SkipMPEGHack",
"OPHFlagHack",
"EETimingHack",
"DMABusyHack",
"GIFFIFOHack",
"VIFFIFOHack",
"VIF1StallHack",
"VuAddSubHack",
"IbitHack",
"VUSyncHack",
"VUOverflowHack",
"XGKickHack",
"BlitInternalFPSHack",
]
allowed_gs_hw_fixes = [
"autoFlush",
"conservativeFramebuffer",
"cpuFramebufferConversion",
"disableDepthSupport",
"wrapGSMem",
"preloadFrameData",
"disablePartialInvalidation",
"textureInsideRT",
"alignSprite",
"mergeSprite",
"wildArmsHack",
"pointListPalette",
"mipmap",
"trilinearFiltering",
"skipDrawStart",
"skipDrawEnd",
"halfBottomOverride",
"halfPixelOffset",
"roundSprite",
"texturePreloading",
"deinterlace",
"cpuSpriteRenderBW",
]
gs_hw_fix_ranges = {
"mipmap": (0, 2),
"trilinearFiltering": (0, 2),
"skipDrawStart": (0, 100000),
"skipDrawEnd": (0, 100000),
"halfPixelOffset": (0, 3),
"roundSprite": (0, 2),
"deinterlace": (0, 7),
"cpuSpriteRenderBW": (1, 10),
}
allowed_speed_hacks = ["mvuFlagSpeedHack", "InstantVU1SpeedHack", "MTVUSpeedHack"]
# Patches are allowed to have a 'default' key or a crc-32 key, followed by
allowed_patch_options = ["author", "content"]
issue_list = []
def is_hex_number(string):
try:
int(string, 16)
return True
except Exception:
return False
def validate_string_option(serial, key, value):
if not isinstance(value, str):
issue_list.append("[{}]: '{}' must be a string".format(serial, key))
def validate_int_option(serial, key, value, low, high):
if not isinstance(value, int) or (value < low or value > high):
issue_list.append(
"[{}]: '{}' must be an int and between {}-{} (inclusive)".format(
serial, key, low, high
)
)
def validate_list_of_strings(serial, key, value):
if not isinstance(value, list) or not all(isinstance(item, str) for item in value):
issue_list.append("[{}]: '{}' must be a list of strings".format(serial, key))
def validate_valid_options(serial, key, value, allowed_values):
if value not in allowed_values:
issue_list.append("[{}]: Invalid '{}' option [{}]".format(serial, key, value))
def validate_clamp_round_modes(serial, key, value, allowed_values):
if not isinstance(value, dict):
issue_list.append("[{}]: '{}' must be a valid object".format(serial, key))
return
for mode_key, mode_value in value.items():
validate_valid_options(serial, key, mode_key, allowed_values)
validate_int_option(serial, key, mode_value, 0, 3)
def validate_game_fixes(serial, key, value):
if not isinstance(value, list):
issue_list.append(
"[{}]: 'gameFixes' must be a list of valid gameFixes".format(serial)
)
return
for gamefix in value:
validate_valid_options(serial, key, gamefix, allowed_game_fixes)
def validate_gs_hw_fix_value(serial, key, value):
low, high = 0, 1
if key in gs_hw_fix_ranges:
low, high = gs_hw_fix_ranges[key]
validate_int_option(serial, key, value, low, high)
def validate_gs_hw_fixes(serial, key, value):
if not isinstance(value, dict):
issue_list.append("[{}]: 'gsHWFixes' must be a valid object".format(serial))
return
for fix, fix_value in value.items():
validate_valid_options(serial, key, fix, allowed_gs_hw_fixes)
validate_gs_hw_fix_value(serial, fix, fix_value)
# skipdraw range must have end >= start
skip_draw_start = value["skipDrawStart"] if "skipDrawStart" in value else 0
skip_draw_end = value["skipDrawEnd"] if "skipDrawEnd" in value else 0
if isinstance(skip_draw_start, int) and isinstance(skip_draw_end, int) and skip_draw_end < skip_draw_start:
issue_list.append("[{}]: skipDrawStart({}) must be greater or equal to skipDrawEnd({})".format(
serial, skip_draw_start, skip_draw_end))
def validate_speed_hacks(serial, key, value):
if not isinstance(value, dict):
issue_list.append("[{}]: 'speedHacks' must be a valid object".format(serial))
return
for speedhack, speedhack_value in value.items():
validate_valid_options(serial, key, speedhack, allowed_speed_hacks)
validate_int_option(serial, speedhack, speedhack_value, 0, 1)
def validate_patches(serial, key, value):
if not isinstance(value, dict):
issue_list.append(
"[{}]: 'patches' must be valid mapping of CRC32 -> Patch Objects".format(
serial
)
)
return
for crc, patch in value.items():
if crc != "default" and not is_hex_number(str(crc)):
issue_list.append(
"[{}]: Patches must either be key'd with 'default' or a valid CRC-32 Hex String".format(
serial
)
)
continue
for patch_option, option_value in patch.items():
validate_valid_options(serial, key, patch_option, allowed_patch_options)
if patch_option == "author":
validate_string_option(serial, patch_option, option_value)
if patch_option == "content":
validate_string_option(serial, patch_option, option_value)
# pylint:disable=unnecessary-lambda
option_validation_handlers = {
"name": (lambda serial, key, value: validate_string_option(serial, key, value)),
"region": (lambda serial, key, value: validate_string_option(serial, key, value)),
"compat": (
lambda serial, key, value: validate_int_option(serial, key, value, 0, 6)
),
"roundModes": (
lambda serial, key, value: validate_clamp_round_modes(
serial, key, value, allowed_round_modes
)
),
"clampModes": (
lambda serial, key, value: validate_clamp_round_modes(
serial, key, value, allowed_clamp_modes
)
),
"gameFixes": (lambda serial, key, value: validate_game_fixes(serial, key, value)),
"gsHWFixes": (lambda serial, key, value: validate_gs_hw_fixes(serial, key, value)),
"speedHacks": (lambda serial, key, value: validate_speed_hacks(serial, key, value)),
"memcardFilters": (
lambda serial, key, value: validate_list_of_strings(serial, key, value)
),
"patches": (lambda serial, key, value: validate_patches(serial, key, value)),
}
class UniqueKeyLoader(yaml.FullLoader):
def construct_mapping(self, node, deep=False):
mapping = set()
for key_node, _ in node.value:
key = self.construct_object(key_node, deep=deep)
if key in mapping:
raise ValueError(f"Duplicate {key!r} key found in YAML.")
mapping.add(key)
return super().construct_mapping(node, deep)
print("Opening {}...".format(file_path))
with open(file_path, encoding="utf-8") as f:
try:
print("Attempting to parse GameDB file...")
gamedb = yaml.load(f, Loader=UniqueKeyLoader)
except Exception as err:
print(err)
print(
"Unable to parse GameDB. Exiting, verify that the file indeed is valid YAML."
)
exit(1)
print("File loaded successfully, validating schema...")
progress_counter = 0
for serial, game_options in gamedb.items():
progress_counter = progress_counter + 1
if progress_counter % 500 == 0 or progress_counter >= len(gamedb.items()):
print(
"[{}/{}] Processing GameDB Entries...".format(
progress_counter, len(gamedb.items())
)
)
# Check for required values
if not "name" in game_options.keys():
issue_list.append("[{}]: 'name' is a required value".format(serial))
if not "region" in game_options.keys():
issue_list.append("[{}]: 'region' is a required value".format(serial))
# Check the options
for key, value in game_options.items():
if key not in allowed_game_options:
issue_list.append("[{}]: Invalid option [{}]".format(serial, key))
continue
if key in option_validation_handlers:
option_validation_handlers[key](serial, key, value)
if len(issue_list) > 0:
print("Issues found during validation:")
print(*issue_list, sep="\n")
exit(1)
else:
print("GameDB Validated Successfully!")
exit(0)

View File

@@ -0,0 +1 @@
PyYAML==5.4.1

3
.github/workflows/scripts/linux/AppRun vendored Executable file
View File

@@ -0,0 +1,3 @@
#!/bin/bash
$APPDIR/AppRun-patched "$@"

4
.github/workflows/scripts/linux/AppRun-qt vendored Executable file
View File

@@ -0,0 +1,4 @@
#!/bin/sh
cd "$(dirname "$0")"
exec ./usr/bin/pcsx2-qt "$@"

View File

@@ -0,0 +1,16 @@
#!/bin/bash
export LD_LIBRARY_PATH="$APPDIR/usr/lib:$LD_LIBRARY_PATH"
# use system wayland if available otherwise use the appimage provided wayland
if [[ $(ldconfig -p | grep libwayland-client | wc -l) -lt 1 ]]; then
export LD_LIBRARY_PATH="$APPDIR/usr/lib/wayland:$LD_LIBRARY_PATH"
fi
export BINARY_NAME=$(basename "$ARGV0")
if [[ ! -e "$PWD/$BINARY_NAME.config" ]]; then
mkdir "$PWD/$BINARY_NAME.config"
fi
export XDG_CONFIG_HOME="$PWD/$BINARY_NAME.config"
mkdir -p "$HOME"/.local/share/icons/hicolor/scalable/apps && cp "$APPDIR"/PCSX2.png "$HOME"/.local/share/icons/hicolor/scalable/apps

253
.github/workflows/scripts/linux/appimage-qt.sh vendored Executable file
View File

@@ -0,0 +1,253 @@
#!/usr/bin/env bash
# This is free and unencumbered software released into the public domain.
#
# Anyone is free to copy, modify, publish, use, compile, sell, or
# distribute this software, either in source code form or as a compiled
# binary, for any purpose, commercial or non-commercial, and by any
# means.
#
# In jurisdictions that recognize copyright laws, the author or authors
# of this software dedicate any and all copyright interest in the
# software to the public domain. We make this dedication for the benefit
# of the public at large and to the detriment of our heirs and
# successors. We intend this dedication to be an overt act of
# relinquishment in perpetuity of all present and future rights to this
# software under copyright law.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
# IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
# OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
# OTHER DEALINGS IN THE SOFTWARE.
#
# For more information, please refer to <http://unlicense.org/>
if [ "$#" -ne 3 ]; then
echo "Syntax: $0 <path to PCSX2 directory> <deps prefix> <output name>"
exit 1
fi
PCSX2DIR=$1
DEPSDIR=$2
NAME=$3
BINDIR="$PCSX2DIR/bin"
BINARY=pcsx2-qt
APPDIRNAME=PCSX2.AppDir
STRIP=llvm-strip-12
declare -a SYSLIBS=(
"libaio.so.1"
"libz.so.1"
"libuuid.so.1"
"libapparmor.so.1"
"libblkid.so.1"
"libbsd.so.0"
"libdbus-1.so.3"
"libgcrypt.so.20"
"liblzma.so.5"
"libmount.so.1"
"libnsl.so.1"
"libpcre.so.3"
"libselinux.so.1"
"libsystemd.so.0"
"libudev.so.1"
"libwrap.so.0"
"libharfbuzz.so.0"
"libFLAC.so.8"
"libSoundTouch.so.1"
"libXau.so.6"
"libXcomposite.so.1"
"libXcursor.so.1"
"libXdamage.so.1"
"libXdmcp.so.6"
"libXext.so.6"
"libXfixes.so.3"
"libXi.so.6"
"libXinerama.so.1"
"libXrandr.so.2"
"libXrender.so.1"
"libXxf86vm.so.1"
"libasyncns.so.0"
"libcrypto.so.1.1"
"libjpeg.so.8"
"liblz4.so.1"
"libogg.so.0"
"libpcap.so.0.8"
"libpng16.so.16"
"libpulse.so.0"
"libsamplerate.so.0"
"libsndfile.so.1"
"libvorbis.so.0"
"libvorbisenc.so.2"
"libxcb.so.1"
"libxcb-render.so.0"
"libxcb-shm.so.0"
"libxkbcommon.so.0"
"libxkbcommon-x11.so.0"
"pulseaudio/libpulsecommon-13.99.so"
"libfreetype.so.6"
"libpcre2-16.so.0"
"libexpat.so.1"
"libffi.so.7"
"libgraphite2.so.3"
"libresolv.so.2"
"libgpg-error.so.0"
"libpcre2-16.so.0"
"libpng16.so.16"
"libxcb-icccm.so.4"
"libxcb-image.so.0"
"libxcb-keysyms.so.1"
"libxcb-randr.so.0"
"libxcb-render.so.0"
"libxcb-render-util.so.0"
"libxcb-shape.so.0"
"libxcb-sync.so.1"
"libxcb-util.so.1"
"libxcb-xfixes.so.0"
"libxcb-xkb.so.1"
"libevdev.so.2"
"libgudev-1.0.so.0"
"libinput.so.10"
"libjpeg.so.8"
"libmtdev.so.1"
"libpng16.so.16"
"libudev.so.1"
"libuuid.so.1"
)
declare -a DEPLIBS=(
"libSDL2-2.0.so.0"
)
declare -a QTLIBS=(
"libQt6Core.so.6"
"libQt6Gui.so.6"
"libQt6Network.so.6"
"libQt6OpenGL.so.6"
"libQt6Svg.so.6"
"libQt6WaylandClient.so.6"
"libQt6WaylandCompositor.so.6"
"libQt6WaylandEglClientHwIntegration.so.6"
"libQt6WaylandEglCompositorHwIntegration.so.6"
"libQt6Widgets.so.6"
"libQt6XcbQpa.so.6"
)
declare -a QTPLUGINS=(
"plugins/iconengines"
"plugins/imageformats"
"plugins/platforms"
#"plugins/platformthemes" # Enable this if we want to ship GTK+ themes at any point.
"plugins/wayland-decoration-client"
"plugins/wayland-graphics-integration-client"
"plugins/wayland-graphics-integration-server"
"plugins/wayland-shell-integration"
"plugins/xcbglintegrations"
)
set -e
if [ ! -f appimagetool-x86_64.AppImage ]; then
wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage
chmod +x appimagetool-x86_64.AppImage
fi
OUTDIR=$(realpath "./$APPDIRNAME")
SCRIPTDIR=$(dirname "${BASH_SOURCE[0]}")
rm -fr "$OUTDIR"
mkdir "$OUTDIR"
mkdir -p "$OUTDIR/usr/bin" "$OUTDIR/usr/lib" "$OUTDIR/usr/lib/pulseaudio"
echo "Copying binary and resources..."
cp -a "$BINDIR/$BINARY" "$BINDIR/resources" "$BINDIR/shaders" "$OUTDIR/usr/bin"
# Don't need old wx locales.
rm -fr "$OUTDIR/usr/bin/resources/locale"
# Patch RPATH so the binary goes hunting for shared libraries in the AppDir instead of system.
echo "Patching RPATH in ${BINARY}..."
patchelf --set-rpath '$ORIGIN/../lib' "$OUTDIR/usr/bin/$BINARY"
# Currently we leave the main binary unstripped, uncomment if this is not desired.
#$STRIP "$OUTDIR/usr/bin/$BINARY"
# Libraries we pull in from the system.
echo "Copying system libraries..."
for lib in "${SYSLIBS[@]}"; do
blib=$(basename "$lib")
if [ -f "/lib/x86_64-linux-gnu/$lib" ]; then
cp "/lib/x86_64-linux-gnu/$lib" "$OUTDIR/usr/lib/$blib"
elif [ -f "$CHROOT/usr/lib/x86_64-linux-gnu/$lib" ]; then
cp "$CHROOT/usr/lib/x86_64-linux-gnu/$lib" "$OUTDIR/usr/lib/$blib"
elif [ -f "$CHROOT/lib/$lib" ]; then
cp "$CHROOT/lib/$lib" "$OUTDIR/usr/lib/$blib"
elif [ -f "$CHROOT/usr/lib/$lib" ]; then
cp "$CHROOT/usr/lib/$lib" "$OUTDIR/usr/lib/$blib"
else
echo "*** Failed to find '$blib'"
exit 1
fi
$STRIP "$OUTDIR/usr/lib/$blib"
done
# Dependencies we built, at this point it's just SDL.
echo "Copying dependency libraries..."
for lib in "${DEPLIBS[@]}"; do
blib=$(basename "$lib")
if [ -f "$DEPSDIR/lib/$lib" ]; then
cp "$DEPSDIR/lib/$lib" "$OUTDIR/usr/lib/$blib"
else
echo "*** Failed to find '$blib'"
exit 1
fi
$STRIP "$OUTDIR/usr/lib/$blib"
done
echo "Copying Qt libraries..."
for lib in "${QTLIBS[@]}"; do
cp -aL "$DEPSDIR/lib/$lib" "$OUTDIR/usr/lib"
$STRIP "$OUTDIR/usr/lib/$lib"
done
echo "Copying Qt plugins..."
mkdir -p "$OUTDIR/usr/lib/plugins"
for plugin in "${QTPLUGINS[@]}"; do
mkdir -p "$OUTDIR/usr/lib/$plugin"
cp -aL "$DEPSDIR/$plugin"/*.so "$OUTDIR/usr/lib/$plugin/"
done
for so in $(find "$OUTDIR/usr/lib/plugins" -iname '*.so'); do
# This is ../../ because it's usually plugins/group/name.so
echo "Patching RPATH in ${so}..."
patchelf --set-rpath '$ORIGIN/../..' "$so"
$STRIP "$so"
done
for so in $(find "$OUTDIR/usr/lib" -maxdepth 1); do
if [ -f "$so" ]; then
echo "Patching RPATH in ${so}"
patchelf --set-rpath '$ORIGIN' "$so"
fi
done
echo "Creating qt.conf..."
cat > "$OUTDIR/usr/bin/qt.conf" << EOF
[Paths]
Plugins = ../lib/plugins
EOF
echo "Copy desktop/icon..."
cp "$PCSX2DIR/pcsx2/gui/Resources/AppIcon64.png" "$OUTDIR/PCSX2.png"
cp "$SCRIPTDIR/pcsx2-qt.desktop" "$OUTDIR/PCSX2.desktop"
cp "$SCRIPTDIR/AppRun-qt" "$OUTDIR/AppRun"
echo "Generate AppImage"
./appimagetool-x86_64.AppImage -v "$OUTDIR" "$NAME.AppImage"

66
.github/workflows/scripts/linux/appimage.sh vendored Executable file
View File

@@ -0,0 +1,66 @@
#!/bin/bash
set -ex
echo "${PLATFORM}"
if [ "${PLATFORM}" == "x86" ]; then
APPARCH="i686"
ARCH="i386"
LIBARCH="i386-linux-gnu"
else
APPARCH="x86_64"
ARCH="x86_64"
LIBARCH="x86_64-linux-gnu"
fi
cd /tmp
curl -sSfLO "https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-$ARCH.AppImage"
chmod a+x linuxdeploy*.AppImage
./linuxdeploy-"$ARCH".AppImage --appimage-extract
curl -sSfL "https://raw.githubusercontent.com/linuxdeploy/linuxdeploy-plugin-gtk/master/linuxdeploy-plugin-gtk.sh" -o /tmp/squashfs-root/usr/bin/linuxdeploy-plugin-gtk.sh
chmod a+x /tmp/squashfs-root/usr/bin/linuxdeploy-plugin-gtk.sh
mv /tmp/squashfs-root/usr/bin/patchelf /tmp/squashfs-root/usr/bin/patchelf.orig
sudo cp /usr/local/bin/patchelf /tmp/squashfs-root/usr/bin/patchelf
cd "$GITHUB_WORKSPACE"
ninja -C build install
cp ./pcsx2/gui/Resources/AppIcon64.png ./squashfs-root/PCSX2.png
cp ./linux_various/PCSX2.desktop.in ./squashfs-root/PCSX2.desktop
sed -i -e 's|Categories=@PCSX2_MENU_CATEGORIES@|Categories=Game;Emulator;|g' ./squashfs-root/PCSX2.desktop
sed -i -e 's|__GL_THREADED_OPTIMIZATIONS=1|__GL_THREADED_OPTIMIZATIONS=0|g' ./squashfs-root/PCSX2.desktop
curl -sSfL "https://github.com/AppImage/AppImageKit/releases/download/continuous/runtime-$APPARCH" -o ./squashfs-root/runtime
mkdir -p squashfs-root/usr/share/applications && cp ./squashfs-root/PCSX2.desktop ./squashfs-root/usr/share/applications
mkdir -p squashfs-root/usr/share/icons && cp ./squashfs-root/PCSX2.png ./squashfs-root/usr/share/icons
mkdir -p squashfs-root/usr/share/icons/hicolor/scalable/apps && cp ./squashfs-root/PCSX2.png ./squashfs-root/usr/share/icons/hicolor/scalable/apps
mkdir -p squashfs-root/usr/share/pixmaps && cp ./squashfs-root/PCSX2.png ./squashfs-root/usr/share/pixmaps
mkdir -p squashfs-root/usr/lib/
mkdir -p squashfs-root/usr/optional/libstdc++
mkdir -p squashfs-root/usr/optional/libgcc_s
cp ./.github/workflows/scripts/linux/AppRun "$GITHUB_WORKSPACE"/squashfs-root/AppRun
curl -sSfL "https://github.com/PCSX2/appimage-checkrt-branch/releases/download/AppImage-checkrt/AppRun_patched" -o "$GITHUB_WORKSPACE"/squashfs-root/AppRun-patched
curl -sSfL "https://github.com/PCSX2/appimage-checkrt-branch/releases/download/AppImage-checkrt/exec.so" -o "$GITHUB_WORKSPACE"/squashfs-root/usr/optional/exec.so
chmod a+x ./squashfs-root/AppRun
chmod a+x ./squashfs-root/runtime
chmod a+x ./squashfs-root/AppRun-patched
chmod a+x ./squashfs-root/usr/optional/exec.so
echo "$name" > "$GITHUB_WORKSPACE"/squashfs-root/version.txt
mkdir -p "$GITHUB_WORKSPACE"/squashfs-root/apprun-hooks
cp /usr/lib/$LIBARCH/libthai.so.0 "$GITHUB_WORKSPACE"/squashfs-root/usr/lib/
cp --dereference /usr/lib/"$LIBARCH"/libstdc++.so.6 "$GITHUB_WORKSPACE"/squashfs-root/usr/optional/libstdc++/libstdc++.so.6
cp --dereference /lib/"$LIBARCH"/libgcc_s.so.1 "$GITHUB_WORKSPACE"/squashfs-root/usr/optional/libgcc_s/libgcc_s.so.1
chmod +x .github/workflows/scripts/linux/app-variables.sh
cp .github/workflows/scripts/linux/app-variables.sh "$GITHUB_WORKSPACE"/squashfs-root/apprun-hooks
export UPD_INFO="gh-releases-zsync|PCSX2|pcsx2|latest|$name.AppImage.zsync"
/tmp/squashfs-root/AppRun --appdir="$GITHUB_WORKSPACE"/squashfs-root/ --plugin gtk -d "$GITHUB_WORKSPACE"/squashfs-root/PCSX2.desktop -i "$GITHUB_WORKSPACE"/squashfs-root/PCSX2.png
# see LD_LIBRARY_PATH in app-variables.sh - the intent is to use system wayland if available but fall back to app-image provided
# a little bit hacky but should ensure maximum compatibility
mkdir -p squashfs-root/usr/lib/wayland
mv squashfs-root/usr/lib/libwayland-* squashfs-root/usr/lib/wayland
rm squashfs-root/usr/lib/libgmodule-2.0.so.0
curl -sSfL "https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-$ARCH.AppImage" -o ./appimagetool-"$ARCH".AppImage
chmod a+x appimagetool*.AppImage
./appimagetool-"$ARCH".AppImage "$GITHUB_WORKSPACE"/squashfs-root "$name.AppImage"
mkdir -p "$GITHUB_WORKSPACE"/ci-artifacts/
ls -al .
mv "$name.AppImage" "$GITHUB_WORKSPACE"/ci-artifacts # && mv "$name.AppImage.zsync" "$GITHUB_WORKSPACE"/ci-artifacts
chmod -R 777 ./ci-artifacts
cd ./ci-artifacts
ls -al .

View File

@@ -0,0 +1,125 @@
#!/usr/bin/env bash
set -e
INSTALLDIR="$HOME/deps"
NPROCS="$(getconf _NPROCESSORS_ONLN)"
SDL=SDL2-2.24.0
QT=6.3.1
mkdir -p deps-build
cd deps-build
cat > SHASUMS <<EOF
91e4c34b1768f92d399b078e171448c6af18cafda743987ed2064a28954d6d97 $SDL.tar.gz
0a64421d9c2469c2c48490a032ab91d547017c9cc171f3f8070bc31888f24e03 qtbase-everywhere-src-$QT.tar.xz
7b19f418e6f7b8e23344082dd04440aacf5da23c5a73980ba22ae4eba4f87df7 qtsvg-everywhere-src-$QT.tar.xz
c412750f2aa3beb93fce5f30517c607f55daaeb7d0407af206a8adf917e126c1 qttools-everywhere-src-$QT.tar.xz
d7bdd55e2908ded901dcc262157100af2a490bf04d31e32995f6d91d78dfdb97 qttranslations-everywhere-src-$QT.tar.xz
6f14fea2d172a5b4170be3efcb0e58535f6605b61bcd823f6d5c9d165bb8c0f0 qtwayland-everywhere-src-$QT.tar.xz
EOF
curl -L \
-O "https://libsdl.org/release/$SDL.tar.gz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qtbase-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qtsvg-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qttools-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qttranslations-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qtwayland-everywhere-src-$QT.tar.xz"
shasum -a 256 --check SHASUMS
echo "Building SDL..."
tar xf "$SDL.tar.gz"
cd "$SDL"
./configure --prefix "$INSTALLDIR" --disable-dbus --without-x --disable-video-opengl --disable-video-opengles --disable-video-vulkan --disable-wayland-shared --disable-ime --disable-oss --disable-alsa --disable-jack --disable-esd --disable-pipewire --disable-pulseaudio --disable-arts --disable-nas --disable-sndio --disable-fusionsound --disable-diskaudio
make "-j$NPROCS"
make install
cd ..
# Couple notes:
# -fontconfig is needed otherwise Qt Widgets render only boxes.
# -qt-doubleconversion avoids a dependency on libdouble-conversion.
# ICU avoids pulling in a bunch of large libraries, and hopefully we can get away without it.
# OpenGL is needed to render window decorations in Wayland, apparently.
echo "Building Qt Base..."
tar xf "qtbase-everywhere-src-$QT.tar.xz"
cd "qtbase-everywhere-src-$QT"
mkdir build
cd build
../configure -prefix "$INSTALLDIR" -release -no-dbus -gui -widgets -fontconfig -qt-doubleconversion -openssl-runtime -opengl desktop -qpa xcb,wayland -xkbcommon -- -DFEATURE_dbus=OFF -DFEATURE_icu=OFF -DFEATURE_printsupport=OFF -DFEATURE_sql=OFF
cmake --build . --parallel
cmake --install .
cd ../../
echo "Building Qt SVG..."
tar xf "qtsvg-everywhere-src-$QT.tar.xz"
cd "qtsvg-everywhere-src-$QT"
mkdir build
cd build
cmake -G Ninja -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release ..
cmake --build . --parallel
cmake --install .
cd ../../
echo "Building Qt Wayland..."
tar xf "qtwayland-everywhere-src-$QT.tar.xz"
cd "qtwayland-everywhere-src-$QT"
# qtwayland does not build without qml/qtdeclarative in 6.3.1. Work around it.
patch -u src/compositor/CMakeLists.txt <<EOF
--- src/compositor/CMakeLists.txt 2022-06-08 13:44:30.000000000 +1000
+++ src/compositor/CMakeLists.txt 2022-07-17 20:05:25.461881785 +1000
@@ -46,7 +46,6 @@
global/qtwaylandcompositorglobal.h
global/qtwaylandqmlinclude.h
global/qwaylandcompositorextension.cpp global/qwaylandcompositorextension.h global/qwaylandcompositorextension_p.h
- global/qwaylandquickextension.cpp global/qwaylandquickextension.h
global/qwaylandutils_p.h
hardware_integration/qwlclientbufferintegration.cpp hardware_integration/qwlclientbufferintegration_p.h
wayland_wrapper/qwlbuffermanager.cpp wayland_wrapper/qwlbuffermanager_p.h
EOF
mkdir build
cd build
cmake -G Ninja -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release ..
cmake --build . --parallel
cmake --install .
cd ../../
echo "Installing Qt Tools..."
tar xf "qttools-everywhere-src-$QT.tar.xz"
cd "qttools-everywhere-src-$QT"
# From Mac build-dependencies.sh:
# Linguist relies on a library in the Designer target, which takes 5-7 minutes to build on the CI
# Avoid it by not building Linguist, since we only need the tools that come with it
patch -u src/linguist/CMakeLists.txt <<EOF
--- src/linguist/CMakeLists.txt
+++ src/linguist/CMakeLists.txt
@@ -14,7 +14,7 @@
add_subdirectory(lrelease-pro)
add_subdirectory(lupdate)
add_subdirectory(lupdate-pro)
-if(QT_FEATURE_process AND QT_FEATURE_pushbutton AND QT_FEATURE_toolbutton AND TARGET Qt::Widgets AND NOT no-png)
+if(QT_FEATURE_process AND QT_FEATURE_pushbutton AND QT_FEATURE_toolbutton AND TARGET Qt::Widgets AND TARGET Qt::PrintSupport AND NOT no-png)
add_subdirectory(linguist)
endif()
EOF
mkdir build
cd build
cmake -G Ninja -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release -DFEATURE_assistant=OFF -DFEATURE_clang=OFF -DFEATURE_designer=OFF -DFEATURE_kmap2qmap=OFF -DFEATURE_pixeltool=OFF -DFEATURE_pkg_config=OFF -DFEATURE_qev=OFF -DFEATURE_qtattributionsscanner=OFF -DFEATURE_qtdiag=OFF -DFEATURE_qtplugininfo=OFF ..
cmake --build . --parallel
cmake --install .
cd ../../
echo "Installing Qt Translations..."
tar xf "qttranslations-everywhere-src-$QT.tar.xz"
cd "qttranslations-everywhere-src-$QT"
mkdir build
cd build
cmake -G Ninja -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release ..
cmake --build . --parallel
cmake --install .
cd ../../
echo "Cleaning up..."
cd ..
rm -r deps-build

15
.github/workflows/scripts/linux/compile.sh vendored Executable file
View File

@@ -0,0 +1,15 @@
#!/bin/bash
set -e
if [ -n "${GITHUB_ACTIONS}" ]; then
echo "Warning: Running this script outside of GitHub Actions isn't recommended."
fi
# Prepare the Cache
ccache -p
ccache -z
# Build
ninja
# Save the Cache
ccache -s

View File

@@ -0,0 +1,38 @@
#!/usr/bin/env bash
set -e
if [ "${COMPILER}" = "clang" ]; then
echo "Using clang toolchain"
cat > "$HOME/clang-toolchain.cmake" << EOF
set(CMAKE_C_COMPILER /usr/bin/clang-12)
set(CMAKE_CXX_COMPILER /usr/bin/clang++-12)
set(CMAKE_EXE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_MODULE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_SHARED_LINKER_FLAGS_INIT "-fuse-ld=lld")
EOF
ADDITIONAL_CMAKE_ARGS="$ADDITIONAL_CMAKE_ARGS -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON -DCMAKE_TOOLCHAIN_FILE=$HOME/clang-toolchain.cmake"
fi
echo "Additional CMake Args - ${ADDITIONAL_CMAKE_ARGS}"
# Generate CMake into ./build
# DISABLE_ADVANCE_SIMD is needed otherwise we end up doing -march=native.
# shellcheck disable=SC2086
cmake \
-B build \
-G Ninja \
$ADDITIONAL_CMAKE_ARGS \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_BUILD_TYPE=Release \
-DQT_BUILD=ON \
-DWAYLAND_API=ON \
-DXDG_STD=TRUE \
-DDISABLE_PCSX2_WRAPPER=ON \
-DDISABLE_SETCAP=ON \
-DCMAKE_PREFIX_PATH="$HOME/deps" \
-DUSE_SYSTEM_SDL2=ON \
-DUSE_SYSTEM_ZSTD=OFF \
-DDISABLE_ADVANCE_SIMD=TRUE

View File

@@ -0,0 +1,33 @@
#!/bin/bash
set -e
if [ "${COMPILER}" = "gcc" ]; then
export CC=gcc-10
export CXX=g++-10
else
export CC=clang
export CXX=clang++
fi
if [ "${PLATFORM}" = x86 ]; then
ADDITIONAL_CMAKE_ARGS="$ADDITIONAL_CMAKE_ARGS -DCMAKE_TOOLCHAIN_FILE=cmake/linux-compiler-i386-multilib.cmake"
fi
echo "Additional CMake Args - ${ADDITIONAL_CMAKE_ARGS}"
# Generate CMake into ./build
cmake \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_BUILD_TYPE=Release \
-DPACKAGE_MODE=TRUE \
-DWAYLAND_API=TRUE \
-DDISABLE_ADVANCE_SIMD=TRUE \
-DDISABLE_PCSX2_WRAPPER=TRUE \
-DCMAKE_INSTALL_PREFIX="squashfs-root/usr/" \
-DOpenGL_GL_PREFERENCE="LEGACY" \
-DOPENGL_opengl_LIBRARY="" \
-DXDG_STD=TRUE \
-DUSE_SYSTEM_ZSTD=FALSE \
$ADDITIONAL_CMAKE_ARGS \
-GNinja \
-B build

View File

@@ -0,0 +1,72 @@
#!/bin/bash
set -e
# Packages - Build and Qt
declare -a BUILD_PACKAGES=(
"build-essential"
"git"
"cmake"
"ccache"
"ninja-build"
"libclang-dev" # Qt goes hunting for libclang-11 specifically.
"libclang-11-dev"
"libclang-12-dev"
"patchelf"
"libglib2.0-dev"
"libfontconfig1-dev"
"libharfbuzz-dev"
"libjpeg-dev"
"libpng-dev"
"libfreetype-dev"
"libinput-dev"
"libxcb-*-dev"
"libxkbcommon-dev"
"libxkbcommon-x11-dev"
"libxrender-dev"
"libwayland-dev"
"libgl1-mesa-dev"
"libegl-dev"
"libegl1-mesa-dev"
"libgl1-mesa-dev"
"libssl-dev"
)
# Packages - PCSX2
declare -a PCSX2_PACKAGES=(
"libaio-dev"
"libbz2-dev"
"libegl1-mesa-dev"
"libgl1-mesa-dev"
"libgtk-3-dev"
"libharfbuzz-dev"
"libjpeg-dev"
"liblzma-dev"
"libpcap0.8-dev"
"libpng-dev"
"libpulse-dev"
"librsvg2-dev"
"libsamplerate0-dev"
"libsoundtouch-dev"
"libudev-dev"
"libx11-xcb-dev"
"pkg-config"
"zlib1g-dev"
)
if [ "${COMPILER}" = "gcc" ]; then
BUILD_PACKAGES+=("g++-10")
else
BUILD_PACKAGES+=("llvm-12" "lld-12" "clang-12")
fi
sudo apt-get -qq update
# Install packages needed for building
echo "Will install the following packages for building - ${BUILD_PACKAGES[*]}"
sudo apt-get -y install "${BUILD_PACKAGES[@]}"
# Install packages needed by pcsx2
PCSX2_PACKAGES=("${PCSX2_PACKAGES[@]}")
echo "Will install the following packages for pcsx2 - ${PCSX2_PACKAGES[*]}"
sudo apt-get -y install "${PCSX2_PACKAGES[@]}"

View File

@@ -0,0 +1,62 @@
#!/bin/bash
set -e
# Packages - Build Environment
declare -a BUILD_PACKAGES=(
"ccache"
"cmake"
"ninja-build"
)
# Packages - PCSX2
declare -a PCSX2_PACKAGES=(
"libaio-dev"
"libbz2-dev"
"libegl1-mesa-dev"
"libgdk-pixbuf2.0-dev"
"libgl1-mesa-dev"
"libgtk-3-dev"
"libharfbuzz-dev"
"libjpeg-dev"
"liblzma-dev"
"libpcap0.8-dev"
"libpng-dev"
"libpulse-dev"
"librsvg2-dev"
"libsamplerate0-dev"
"libsoundtouch-dev"
"libudev-dev"
"libwxgtk3.0-gtk3-dev"
"libx11-xcb-dev"
"pkg-config"
"portaudio19-dev"
"zlib1g-dev"
)
if [ "${COMPILER}" = "gcc" ]; then
BUILD_PACKAGES+=("g++-10-multilib")
else
BUILD_PACKAGES+=("clang-9")
PCSX2_PACKAGES+=("libstdc++-10-dev")
fi
# - https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-README.md
ARCH=""
echo "${PLATFORM}"
if [ "${PLATFORM}" == "x86" ]; then
ARCH=":i386"
sudo dpkg --add-architecture i386
fi
sudo apt-get -qq update
# Install packages needed for building
echo "Will install the following packages for building - ${BUILD_PACKAGES[*]}"
#sudo apt remove gcc-9 g++-9
sudo apt-get -y install "${BUILD_PACKAGES[@]}"
# Install packages needed by pcsx2
PCSX2_PACKAGES=("${PCSX2_PACKAGES[@]/%/"${ARCH}"}")
echo "Will install the following packages for pcsx2 - ${PCSX2_PACKAGES[*]}"
sudo apt-get -y install "${PCSX2_PACKAGES[@]}"

View File

@@ -0,0 +1,12 @@
[Desktop Entry]
Version=1.0
Terminal=false
Type=Application
Name=PCSX2
StartupWMClass=PCSX2
GenericName=PlayStation 2 Emulator
Comment=Sony PlayStation 2 emulator
Exec=pcsx2-qt
Icon=PCSX2
Keywords=game;emulator;
Categories=Game;Emulator;

View File

@@ -0,0 +1,164 @@
#!/bin/bash
set -e
if [ "$GUI" == "Qt" ]; then
export MACOSX_DEPLOYMENT_TARGET=10.14
else
export MACOSX_DEPLOYMENT_TARGET=10.13
fi
INSTALLDIR="$HOME/deps"
NPROCS="$(getconf _NPROCESSORS_ONLN)"
SDL=SDL2-2.24.0
PNG=1.6.37
JPG=9e
SAMPLERATE=libsamplerate-0.1.9
PORTAUDIO=pa_stable_v190700_20210406
SOUNDTOUCH=soundtouch-2.3.1
WXWIDGETS=3.1.6
QT=6.3.1
mkdir deps-build
cd deps-build
export PKG_CONFIG_PATH="$INSTALLDIR/lib/pkgconfig:$PKG_CONFIG_PATH"
export LDFLAGS="-L$INSTALLDIR/lib -dead_strip $LDFLAGS"
export CFLAGS="-I$INSTALLDIR/include -Os $CFLAGS"
export CXXFLAGS="-I$INSTALLDIR/include -Os $CXXFLAGS"
cat > SHASUMS <<EOF
91e4c34b1768f92d399b078e171448c6af18cafda743987ed2064a28954d6d97 $SDL.tar.gz
505e70834d35383537b6491e7ae8641f1a4bed1876dbfe361201fc80868d88ca libpng-$PNG.tar.xz
4077d6a6a75aeb01884f708919d25934c93305e49f7e3f36db9129320e6f4f3d jpegsrc.v$JPG.tar.gz
0a7eb168e2f21353fb6d84da152e4512126f7dc48ccb0be80578c565413444c1 $SAMPLERATE.tar.gz
47efbf42c77c19a05d22e627d42873e991ec0c1357219c0d74ce6a2948cb2def $PORTAUDIO.tgz
6900996607258496ce126924a19fe9d598af9d892cf3f33d1e4daaa9b42ae0b1 $SOUNDTOUCH.tar.gz
4980e86c6494adcd527a41fc0a4e436777ba41d1893717d7b7176c59c2061c25 wxWidgets-$WXWIDGETS.tar.bz2
0a64421d9c2469c2c48490a032ab91d547017c9cc171f3f8070bc31888f24e03 qtbase-everywhere-src-$QT.tar.xz
7b19f418e6f7b8e23344082dd04440aacf5da23c5a73980ba22ae4eba4f87df7 qtsvg-everywhere-src-$QT.tar.xz
c412750f2aa3beb93fce5f30517c607f55daaeb7d0407af206a8adf917e126c1 qttools-everywhere-src-$QT.tar.xz
d7bdd55e2908ded901dcc262157100af2a490bf04d31e32995f6d91d78dfdb97 qttranslations-everywhere-src-$QT.tar.xz
EOF
curl -L \
-O "https://libsdl.org/release/$SDL.tar.gz" \
-O "https://downloads.sourceforge.net/project/libpng/libpng16/$PNG/libpng-$PNG.tar.xz" \
-O "https://www.ijg.org/files/jpegsrc.v$JPG.tar.gz" \
-O "http://www.mega-nerd.com/SRC/$SAMPLERATE.tar.gz" \
-O "http://files.portaudio.com/archives/$PORTAUDIO.tgz" \
-O "https://www.surina.net/soundtouch/$SOUNDTOUCH.tar.gz" \
-O "https://github.com/wxWidgets/wxWidgets/releases/download/v$WXWIDGETS/wxWidgets-$WXWIDGETS.tar.bz2" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qtbase-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qtsvg-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qttools-everywhere-src-$QT.tar.xz" \
-O "https://download.qt.io/official_releases/qt/${QT%.*}/$QT/submodules/qttranslations-everywhere-src-$QT.tar.xz" \
shasum -a 256 --check SHASUMS
echo "Installing SDL..."
tar xf "$SDL.tar.gz"
cd "$SDL"
./configure --prefix "$INSTALLDIR" --without-x
make "-j$NPROCS"
make install
cd ..
echo "Installing libpng..."
tar xf "libpng-$PNG.tar.xz"
cd "libpng-$PNG"
./configure --prefix "$INSTALLDIR" --disable-dependency-tracking
make "-j$NPROCS"
make install
cd ..
echo "Installing libjpeg..."
tar xf "jpegsrc.v$JPG.tar.gz"
cd "jpeg-$JPG"
./configure --prefix "$INSTALLDIR" --disable-dependency-tracking
make "-j$NPROCS"
make install
cd ..
echo "Installing libsamplerate..."
tar xf "$SAMPLERATE.tar.gz"
cd "$SAMPLERATE"
sed -i "" "s/Carbon.h/Carbon\\/Carbon.h/" examples/audio_out.c
./configure --prefix "$INSTALLDIR" --disable-dependency-tracking --disable-sndfile
make "-j$NPROCS"
make install
cd ..
echo "Installing portaudio..."
tar xf "$PORTAUDIO.tgz"
cd portaudio
./configure --prefix "$INSTALLDIR" --enable-mac-universal=no
make "-j$NPROCS"
make install
cd ..
echo "Installing soundtouch..."
tar xf "$SOUNDTOUCH.tar.gz"
cd "$SOUNDTOUCH"
cmake -B build -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=MinSizeRel
make -C build "-j$NPROCS"
make -C build install
cd ..
if [ "$GUI" == "wxWidgets" ]; then
echo "Installing wx..."
tar xf "wxWidgets-$WXWIDGETS.tar.bz2"
cd "wxWidgets-$WXWIDGETS"
./configure --prefix "$INSTALLDIR" --with-macosx-version-min="$MACOSX_DEPLOYMENT_TARGET" --enable-clipboard --enable-dnd --enable-std_string --with-cocoa --with-libiconv --with-libjpeg --with-libpng --with-zlib --without-libtiff --without-regex
make "-j$NPROCS"
make install
cd ..
fi
if [ "$GUI" == "Qt" ]; then
echo "Installing Qt Base..."
tar xf "qtbase-everywhere-src-$QT.tar.xz"
cd "qtbase-everywhere-src-$QT"
cmake -B build -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release -DFEATURE_optimize_size=ON -DFEATURE_dbus=OFF -DFEATURE_framework=OFF -DFEATURE_icu=OFF -DFEATURE_opengl=OFF -DFEATURE_printsupport=OFF -DFEATURE_sql=OFF
make -C build "-j$NPROCS"
make -C build install
cd ..
echo "Installing Qt SVG..."
tar xf "qtsvg-everywhere-src-$QT.tar.xz"
cd "qtsvg-everywhere-src-$QT"
cmake -B build -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=MinSizeRel
make -C build "-j$NPROCS"
make -C build install
cd ..
echo "Installing Qt Tools..."
tar xf "qttools-everywhere-src-$QT.tar.xz"
cd "qttools-everywhere-src-$QT"
# Linguist relies on a library in the Designer target, which takes 5-7 minutes to build on the CI
# Avoid it by not building Linguist, since we only need the tools that come with it
patch -u src/linguist/CMakeLists.txt <<EOF
--- src/linguist/CMakeLists.txt
+++ src/linguist/CMakeLists.txt
@@ -14,7 +14,7 @@
add_subdirectory(lrelease-pro)
add_subdirectory(lupdate)
add_subdirectory(lupdate-pro)
-if(QT_FEATURE_process AND QT_FEATURE_pushbutton AND QT_FEATURE_toolbutton AND TARGET Qt::Widgets AND NOT no-png)
+if(QT_FEATURE_process AND QT_FEATURE_pushbutton AND QT_FEATURE_toolbutton AND TARGET Qt::Widgets AND TARGET Qt::PrintSupport AND NOT no-png)
add_subdirectory(linguist)
endif()
EOF
cmake -B build -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release -DFEATURE_assistant=OFF -DFEATURE_clang=OFF -DFEATURE_designer=OFF -DFEATURE_kmap2qmap=OFF -DFEATURE_pixeltool=OFF -DFEATURE_pkg_config=OFF -DFEATURE_qev=OFF -DFEATURE_qtattributionsscanner=OFF -DFEATURE_qtdiag=OFF -DFEATURE_qtplugininfo=OFF
make -C build "-j$NPROCS"
make -C build install
cd ..
echo "Installing Qt Translations..."
tar xf "qttranslations-everywhere-src-$QT.tar.xz"
cd "qttranslations-everywhere-src-$QT"
cmake -B build -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DCMAKE_BUILD_TYPE=Release
make -C build "-j$NPROCS"
make -C build install
cd ..
fi
echo "Cleaning up..."
cd ..
rm -r deps-build

View File

@@ -0,0 +1,2 @@
node_modules/
*.md

View File

@@ -0,0 +1,25 @@
import { MessageEmbed, WebhookClient } from "discord.js";
import * as github from '@actions/github';
const releaseInfo = github.context.payload.release;
if (!releaseInfo.prerelease) {
console.log("Not announcing - release was not a pre-release (aka a Nightly)");
process.exit(0);
}
// Publish Webhook
const embed = new MessageEmbed()
.setColor('#FF8000')
.setTitle('New PCSX2 Nightly Build Available!')
.setDescription("To download the latest or previous builds, [visit the official downloads page](https://pcsx2.net/downloads/).")
.addFields(
{ name: 'Version', value: releaseInfo.tag_name, inline: true },
{ name: 'Installation Steps', value: '[See Here](https://github.com/PCSX2/pcsx2/wiki/Nightly-Build-Usage-Guide)', inline: true },
{ name: 'Included Changes', value: releaseInfo.body, inline: false }
);
const webhookClient = new WebhookClient({ url: process.env.DISCORD_BUILD_WEBHOOK });
await webhookClient.send({
embeds: [embed],
});

View File

@@ -0,0 +1,814 @@
{
"name": "announce-release",
"version": "1.0.0",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"version": "1.0.0",
"license": "ISC",
"dependencies": {
"@actions/github": "^5.0.0",
"discord.js": "^13.2.0"
}
},
"node_modules/@actions/github": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/@actions/github/-/github-5.0.0.tgz",
"integrity": "sha512-QvE9eAAfEsS+yOOk0cylLBIO/d6WyWIOvsxxzdrPFaud39G6BOkUwScXZn1iBzQzHyu9SBkkLSWlohDWdsasAQ==",
"dependencies": {
"@actions/http-client": "^1.0.11",
"@octokit/core": "^3.4.0",
"@octokit/plugin-paginate-rest": "^2.13.3",
"@octokit/plugin-rest-endpoint-methods": "^5.1.1"
}
},
"node_modules/@actions/http-client": {
"version": "1.0.11",
"resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-1.0.11.tgz",
"integrity": "sha512-VRYHGQV1rqnROJqdMvGUbY/Kn8vriQe/F9HR2AlYHzmKuM/p3kjNuXhmdBfcVgsvRWTz5C5XW5xvndZrVBuAYg==",
"dependencies": {
"tunnel": "0.0.6"
}
},
"node_modules/@discordjs/builders": {
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.6.0.tgz",
"integrity": "sha512-mH3Gx61LKk2CD05laCI9K5wp+a3NyASHDUGx83DGJFkqJlRlSV5WMJNY6RS37A5SjqDtGMF4wVR9jzFaqShe6Q==",
"dependencies": {
"@sindresorhus/is": "^4.0.1",
"discord-api-types": "^0.22.0",
"ow": "^0.27.0",
"ts-mixer": "^6.0.0",
"tslib": "^2.3.1"
},
"engines": {
"node": ">=14.0.0",
"npm": ">=7.0.0"
}
},
"node_modules/@discordjs/builders/node_modules/discord-api-types": {
"version": "0.22.0",
"resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.22.0.tgz",
"integrity": "sha512-l8yD/2zRbZItUQpy7ZxBJwaLX/Bs2TGaCthRppk8Sw24LOIWg12t9JEreezPoYD0SQcC2htNNo27kYEpYW/Srg==",
"engines": {
"node": ">=12"
}
},
"node_modules/@discordjs/collection": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/@discordjs/collection/-/collection-0.2.1.tgz",
"integrity": "sha512-vhxqzzM8gkomw0TYRF3tgx7SwElzUlXT/Aa41O7mOcyN6wIJfj5JmDWaO5XGKsGSsNx7F3i5oIlrucCCWV1Nog==",
"engines": {
"node": ">=14.0.0"
}
},
"node_modules/@discordjs/form-data": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@discordjs/form-data/-/form-data-3.0.1.tgz",
"integrity": "sha512-ZfFsbgEXW71Rw/6EtBdrP5VxBJy4dthyC0tpQKGKmYFImlmmrykO14Za+BiIVduwjte0jXEBlhSKf0MWbFp9Eg==",
"dependencies": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.8",
"mime-types": "^2.1.12"
},
"engines": {
"node": ">= 6"
}
},
"node_modules/@octokit/auth-token": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-2.5.0.tgz",
"integrity": "sha512-r5FVUJCOLl19AxiuZD2VRZ/ORjp/4IN98Of6YJoJOkY75CIBuYfmiNHGrDwXr+aLGG55igl9QrxX3hbiXlLb+g==",
"dependencies": {
"@octokit/types": "^6.0.3"
}
},
"node_modules/@octokit/core": {
"version": "3.5.1",
"resolved": "https://registry.npmjs.org/@octokit/core/-/core-3.5.1.tgz",
"integrity": "sha512-omncwpLVxMP+GLpLPgeGJBF6IWJFjXDS5flY5VbppePYX9XehevbDykRH9PdCdvqt9TS5AOTiDide7h0qrkHjw==",
"dependencies": {
"@octokit/auth-token": "^2.4.4",
"@octokit/graphql": "^4.5.8",
"@octokit/request": "^5.6.0",
"@octokit/request-error": "^2.0.5",
"@octokit/types": "^6.0.3",
"before-after-hook": "^2.2.0",
"universal-user-agent": "^6.0.0"
}
},
"node_modules/@octokit/endpoint": {
"version": "6.0.12",
"resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-6.0.12.tgz",
"integrity": "sha512-lF3puPwkQWGfkMClXb4k/eUT/nZKQfxinRWJrdZaJO85Dqwo/G0yOC434Jr2ojwafWJMYqFGFa5ms4jJUgujdA==",
"dependencies": {
"@octokit/types": "^6.0.3",
"is-plain-object": "^5.0.0",
"universal-user-agent": "^6.0.0"
}
},
"node_modules/@octokit/graphql": {
"version": "4.8.0",
"resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-4.8.0.tgz",
"integrity": "sha512-0gv+qLSBLKF0z8TKaSKTsS39scVKF9dbMxJpj3U0vC7wjNWFuIpL/z76Qe2fiuCbDRcJSavkXsVtMS6/dtQQsg==",
"dependencies": {
"@octokit/request": "^5.6.0",
"@octokit/types": "^6.0.3",
"universal-user-agent": "^6.0.0"
}
},
"node_modules/@octokit/openapi-types": {
"version": "11.1.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-11.1.0.tgz",
"integrity": "sha512-dWZfYvCCdjZzDYA3lIAMF72Q0jld8xidqCq5Ryw09eBJXZdcM6he0vWBTvw/b5UnGYqexxOyHWgfrsTlUJL3Gw=="
},
"node_modules/@octokit/plugin-paginate-rest": {
"version": "2.16.9",
"resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.16.9.tgz",
"integrity": "sha512-gfSCMgz5scFKsR0dW4jaYsDJVt/UwCHp4dF7sHlmSekZvwzvLiOAGZ4MQkEsL5DW9hIk2W+UQkYZMTA1b6Wsqw==",
"dependencies": {
"@octokit/types": "^6.33.0"
}
},
"node_modules/@octokit/plugin-rest-endpoint-methods": {
"version": "5.12.1",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.12.1.tgz",
"integrity": "sha512-0nY3htfl6x9UkPcqv8pm9vOC/bTA7f4IMDWln13neHRdNWQvOQgZ9fRxK7BAc74rye4yVINEFi9Yb9rnGUvosA==",
"dependencies": {
"@octokit/types": "^6.33.0",
"deprecation": "^2.3.1"
}
},
"node_modules/@octokit/request": {
"version": "5.6.2",
"resolved": "https://registry.npmjs.org/@octokit/request/-/request-5.6.2.tgz",
"integrity": "sha512-je66CvSEVf0jCpRISxkUcCa0UkxmFs6eGDRSbfJtAVwbLH5ceqF+YEyC8lj8ystKyZTy8adWr0qmkY52EfOeLA==",
"dependencies": {
"@octokit/endpoint": "^6.0.1",
"@octokit/request-error": "^2.1.0",
"@octokit/types": "^6.16.1",
"is-plain-object": "^5.0.0",
"node-fetch": "^2.6.1",
"universal-user-agent": "^6.0.0"
}
},
"node_modules/@octokit/request-error": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-2.1.0.tgz",
"integrity": "sha512-1VIvgXxs9WHSjicsRwq8PlR2LR2x6DwsJAaFgzdi0JfJoGSO8mYI/cHJQ+9FbN21aa+DrgNLnwObmyeSC8Rmpg==",
"dependencies": {
"@octokit/types": "^6.0.3",
"deprecation": "^2.0.0",
"once": "^1.4.0"
}
},
"node_modules/@octokit/types": {
"version": "6.33.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.33.0.tgz",
"integrity": "sha512-0zffZ048M0UhthyPXQHLz4038Ak46nMWZXkzlXvXB/M/L1jYPBceq4iZj4qjKVrvveaJrrgKdJ9+3yUuITfcCw==",
"dependencies": {
"@octokit/openapi-types": "^11.1.0"
}
},
"node_modules/@sapphire/async-queue": {
"version": "1.1.6",
"resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.6.tgz",
"integrity": "sha512-M5CbgMgesemMUCQo5G/InGHvp+GZx6uuJNV1iwvSWD8EFNVrfxaTcqhcAXM3MPYkjlxvNnoDNk0R1lfzvca6LA==",
"engines": {
"node": ">=v14.18.0",
"npm": ">=7.24.2"
}
},
"node_modules/@sindresorhus/is": {
"version": "4.2.0",
"resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.2.0.tgz",
"integrity": "sha512-VkE3KLBmJwcCaVARtQpfuKcKv8gcBmUubrfHGF84dXuuW6jgsRYxPtzcIhPyK9WAPpRt2/xY6zkD9MnRaJzSyw==",
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/sindresorhus/is?sponsor=1"
}
},
"node_modules/@types/node": {
"version": "16.10.3",
"resolved": "https://registry.npmjs.org/@types/node/-/node-16.10.3.tgz",
"integrity": "sha512-ho3Ruq+fFnBrZhUYI46n/bV2GjwzSkwuT4dTf0GkuNFmnb8nq4ny2z9JEVemFi6bdEJanHLlYfy9c6FN9B9McQ=="
},
"node_modules/@types/ws": {
"version": "8.2.0",
"resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.2.0.tgz",
"integrity": "sha512-cyeefcUCgJlEk+hk2h3N+MqKKsPViQgF5boi9TTHSK+PoR9KWBb/C5ccPcDyAqgsbAYHTwulch725DV84+pSpg==",
"dependencies": {
"@types/node": "*"
}
},
"node_modules/asynckit": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
"integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"node_modules/before-after-hook": {
"version": "2.2.2",
"resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.2.tgz",
"integrity": "sha512-3pZEU3NT5BFUo/AD5ERPWOgQOCZITni6iavr5AUw5AUwQjMlI0kzu5btnyD39AF0gUEsDPwJT+oY1ORBJijPjQ=="
},
"node_modules/callsites": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
"integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==",
"engines": {
"node": ">=6"
}
},
"node_modules/combined-stream": {
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
"integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
"dependencies": {
"delayed-stream": "~1.0.0"
},
"engines": {
"node": ">= 0.8"
}
},
"node_modules/delayed-stream": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
"integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=",
"engines": {
"node": ">=0.4.0"
}
},
"node_modules/deprecation": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz",
"integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ=="
},
"node_modules/discord-api-types": {
"version": "0.23.1",
"resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.23.1.tgz",
"integrity": "sha512-igWmn+45mzXRWNEPU25I/pr8MwxHb767wAr51oy3VRLRcTlp5ADBbrBR0lq3SA1Rfw3MtM4TQu1xo3kxscfVdQ==",
"engines": {
"node": ">=12"
}
},
"node_modules/discord.js": {
"version": "13.2.0",
"resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.2.0.tgz",
"integrity": "sha512-nyxUvL8wuQG38zx13wUMkpcA8koFszyiXdkSLwwM9opKW2LC2H5gD0cTZxImeJ6GtEnKPWT8xBiE8lLBmbNIhw==",
"dependencies": {
"@discordjs/builders": "^0.6.0",
"@discordjs/collection": "^0.2.1",
"@discordjs/form-data": "^3.0.1",
"@sapphire/async-queue": "^1.1.5",
"@types/ws": "^8.2.0",
"discord-api-types": "^0.23.1",
"node-fetch": "^2.6.1",
"ws": "^8.2.3"
},
"engines": {
"node": ">=16.6.0",
"npm": ">=7.0.0"
}
},
"node_modules/dot-prop": {
"version": "6.0.1",
"resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-6.0.1.tgz",
"integrity": "sha512-tE7ztYzXHIeyvc7N+hR3oi7FIbf/NIjVP9hmAt3yMXzrQ072/fpjGLx2GxNxGxUl5V73MEqYzioOMoVhGMJ5cA==",
"dependencies": {
"is-obj": "^2.0.0"
},
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/is-obj": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz",
"integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==",
"engines": {
"node": ">=8"
}
},
"node_modules/is-plain-object": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz",
"integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/lodash.isequal": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz",
"integrity": "sha1-QVxEePK8wwEgwizhDtMib30+GOA="
},
"node_modules/mime-db": {
"version": "1.50.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.50.0.tgz",
"integrity": "sha512-9tMZCDlYHqeERXEHO9f/hKfNXhre5dK2eE/krIvUjZbS2KPcqGDfNShIWS1uW9XOTKQKqK6qbeOci18rbfW77A==",
"engines": {
"node": ">= 0.6"
}
},
"node_modules/mime-types": {
"version": "2.1.33",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.33.tgz",
"integrity": "sha512-plLElXp7pRDd0bNZHw+nMd52vRYjLwQjygaNg7ddJ2uJtTlmnTCjWuPKxVu6//AdaRuME84SvLW91sIkBqGT0g==",
"dependencies": {
"mime-db": "1.50.0"
},
"engines": {
"node": ">= 0.6"
}
},
"node_modules/node-fetch": {
"version": "2.6.7",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz",
"integrity": "sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==",
"dependencies": {
"whatwg-url": "^5.0.0"
},
"engines": {
"node": "4.x || >=6.0.0"
},
"peerDependencies": {
"encoding": "^0.1.0"
},
"peerDependenciesMeta": {
"encoding": {
"optional": true
}
}
},
"node_modules/once": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
"dependencies": {
"wrappy": "1"
}
},
"node_modules/ow": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/ow/-/ow-0.27.0.tgz",
"integrity": "sha512-SGnrGUbhn4VaUGdU0EJLMwZWSupPmF46hnTRII7aCLCrqixTAC5eKo8kI4/XXf1eaaI8YEVT+3FeGNJI9himAQ==",
"dependencies": {
"@sindresorhus/is": "^4.0.1",
"callsites": "^3.1.0",
"dot-prop": "^6.0.1",
"lodash.isequal": "^4.5.0",
"type-fest": "^1.2.1",
"vali-date": "^1.0.0"
},
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
"integrity": "sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o="
},
"node_modules/ts-mixer": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/ts-mixer/-/ts-mixer-6.0.0.tgz",
"integrity": "sha512-nXIb1fvdY5CBSrDIblLn73NW0qRDk5yJ0Sk1qPBF560OdJfQp9jhl+0tzcY09OZ9U+6GpeoI9RjwoIKFIoB9MQ=="
},
"node_modules/tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw=="
},
"node_modules/tunnel": {
"version": "0.0.6",
"resolved": "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz",
"integrity": "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==",
"engines": {
"node": ">=0.6.11 <=0.7.0 || >=0.7.3"
}
},
"node_modules/type-fest": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz",
"integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA==",
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/sponsors/sindresorhus"
}
},
"node_modules/universal-user-agent": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz",
"integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w=="
},
"node_modules/vali-date": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/vali-date/-/vali-date-1.0.0.tgz",
"integrity": "sha1-G5BKWWCfsyjvB4E4Qgk09rhnCaY=",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/webidl-conversions": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",
"integrity": "sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE="
},
"node_modules/whatwg-url": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",
"integrity": "sha1-lmRU6HZUYuN2RNNib2dCzotwll0=",
"dependencies": {
"tr46": "~0.0.3",
"webidl-conversions": "^3.0.0"
}
},
"node_modules/wrappy": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
},
"node_modules/ws": {
"version": "8.2.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz",
"integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==",
"engines": {
"node": ">=10.0.0"
},
"peerDependencies": {
"bufferutil": "^4.0.1",
"utf-8-validate": "^5.0.2"
},
"peerDependenciesMeta": {
"bufferutil": {
"optional": true
},
"utf-8-validate": {
"optional": true
}
}
}
},
"dependencies": {
"@actions/github": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/@actions/github/-/github-5.0.0.tgz",
"integrity": "sha512-QvE9eAAfEsS+yOOk0cylLBIO/d6WyWIOvsxxzdrPFaud39G6BOkUwScXZn1iBzQzHyu9SBkkLSWlohDWdsasAQ==",
"requires": {
"@actions/http-client": "^1.0.11",
"@octokit/core": "^3.4.0",
"@octokit/plugin-paginate-rest": "^2.13.3",
"@octokit/plugin-rest-endpoint-methods": "^5.1.1"
}
},
"@actions/http-client": {
"version": "1.0.11",
"resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-1.0.11.tgz",
"integrity": "sha512-VRYHGQV1rqnROJqdMvGUbY/Kn8vriQe/F9HR2AlYHzmKuM/p3kjNuXhmdBfcVgsvRWTz5C5XW5xvndZrVBuAYg==",
"requires": {
"tunnel": "0.0.6"
}
},
"@discordjs/builders": {
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-0.6.0.tgz",
"integrity": "sha512-mH3Gx61LKk2CD05laCI9K5wp+a3NyASHDUGx83DGJFkqJlRlSV5WMJNY6RS37A5SjqDtGMF4wVR9jzFaqShe6Q==",
"requires": {
"@sindresorhus/is": "^4.0.1",
"discord-api-types": "^0.22.0",
"ow": "^0.27.0",
"ts-mixer": "^6.0.0",
"tslib": "^2.3.1"
},
"dependencies": {
"discord-api-types": {
"version": "0.22.0",
"resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.22.0.tgz",
"integrity": "sha512-l8yD/2zRbZItUQpy7ZxBJwaLX/Bs2TGaCthRppk8Sw24LOIWg12t9JEreezPoYD0SQcC2htNNo27kYEpYW/Srg=="
}
}
},
"@discordjs/collection": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/@discordjs/collection/-/collection-0.2.1.tgz",
"integrity": "sha512-vhxqzzM8gkomw0TYRF3tgx7SwElzUlXT/Aa41O7mOcyN6wIJfj5JmDWaO5XGKsGSsNx7F3i5oIlrucCCWV1Nog=="
},
"@discordjs/form-data": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@discordjs/form-data/-/form-data-3.0.1.tgz",
"integrity": "sha512-ZfFsbgEXW71Rw/6EtBdrP5VxBJy4dthyC0tpQKGKmYFImlmmrykO14Za+BiIVduwjte0jXEBlhSKf0MWbFp9Eg==",
"requires": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.8",
"mime-types": "^2.1.12"
}
},
"@octokit/auth-token": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-2.5.0.tgz",
"integrity": "sha512-r5FVUJCOLl19AxiuZD2VRZ/ORjp/4IN98Of6YJoJOkY75CIBuYfmiNHGrDwXr+aLGG55igl9QrxX3hbiXlLb+g==",
"requires": {
"@octokit/types": "^6.0.3"
}
},
"@octokit/core": {
"version": "3.5.1",
"resolved": "https://registry.npmjs.org/@octokit/core/-/core-3.5.1.tgz",
"integrity": "sha512-omncwpLVxMP+GLpLPgeGJBF6IWJFjXDS5flY5VbppePYX9XehevbDykRH9PdCdvqt9TS5AOTiDide7h0qrkHjw==",
"requires": {
"@octokit/auth-token": "^2.4.4",
"@octokit/graphql": "^4.5.8",
"@octokit/request": "^5.6.0",
"@octokit/request-error": "^2.0.5",
"@octokit/types": "^6.0.3",
"before-after-hook": "^2.2.0",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/endpoint": {
"version": "6.0.12",
"resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-6.0.12.tgz",
"integrity": "sha512-lF3puPwkQWGfkMClXb4k/eUT/nZKQfxinRWJrdZaJO85Dqwo/G0yOC434Jr2ojwafWJMYqFGFa5ms4jJUgujdA==",
"requires": {
"@octokit/types": "^6.0.3",
"is-plain-object": "^5.0.0",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/graphql": {
"version": "4.8.0",
"resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-4.8.0.tgz",
"integrity": "sha512-0gv+qLSBLKF0z8TKaSKTsS39scVKF9dbMxJpj3U0vC7wjNWFuIpL/z76Qe2fiuCbDRcJSavkXsVtMS6/dtQQsg==",
"requires": {
"@octokit/request": "^5.6.0",
"@octokit/types": "^6.0.3",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/openapi-types": {
"version": "11.1.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-11.1.0.tgz",
"integrity": "sha512-dWZfYvCCdjZzDYA3lIAMF72Q0jld8xidqCq5Ryw09eBJXZdcM6he0vWBTvw/b5UnGYqexxOyHWgfrsTlUJL3Gw=="
},
"@octokit/plugin-paginate-rest": {
"version": "2.16.9",
"resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.16.9.tgz",
"integrity": "sha512-gfSCMgz5scFKsR0dW4jaYsDJVt/UwCHp4dF7sHlmSekZvwzvLiOAGZ4MQkEsL5DW9hIk2W+UQkYZMTA1b6Wsqw==",
"requires": {
"@octokit/types": "^6.33.0"
}
},
"@octokit/plugin-rest-endpoint-methods": {
"version": "5.12.1",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.12.1.tgz",
"integrity": "sha512-0nY3htfl6x9UkPcqv8pm9vOC/bTA7f4IMDWln13neHRdNWQvOQgZ9fRxK7BAc74rye4yVINEFi9Yb9rnGUvosA==",
"requires": {
"@octokit/types": "^6.33.0",
"deprecation": "^2.3.1"
}
},
"@octokit/request": {
"version": "5.6.2",
"resolved": "https://registry.npmjs.org/@octokit/request/-/request-5.6.2.tgz",
"integrity": "sha512-je66CvSEVf0jCpRISxkUcCa0UkxmFs6eGDRSbfJtAVwbLH5ceqF+YEyC8lj8ystKyZTy8adWr0qmkY52EfOeLA==",
"requires": {
"@octokit/endpoint": "^6.0.1",
"@octokit/request-error": "^2.1.0",
"@octokit/types": "^6.16.1",
"is-plain-object": "^5.0.0",
"node-fetch": "^2.6.1",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/request-error": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-2.1.0.tgz",
"integrity": "sha512-1VIvgXxs9WHSjicsRwq8PlR2LR2x6DwsJAaFgzdi0JfJoGSO8mYI/cHJQ+9FbN21aa+DrgNLnwObmyeSC8Rmpg==",
"requires": {
"@octokit/types": "^6.0.3",
"deprecation": "^2.0.0",
"once": "^1.4.0"
}
},
"@octokit/types": {
"version": "6.33.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.33.0.tgz",
"integrity": "sha512-0zffZ048M0UhthyPXQHLz4038Ak46nMWZXkzlXvXB/M/L1jYPBceq4iZj4qjKVrvveaJrrgKdJ9+3yUuITfcCw==",
"requires": {
"@octokit/openapi-types": "^11.1.0"
}
},
"@sapphire/async-queue": {
"version": "1.1.6",
"resolved": "https://registry.npmjs.org/@sapphire/async-queue/-/async-queue-1.1.6.tgz",
"integrity": "sha512-M5CbgMgesemMUCQo5G/InGHvp+GZx6uuJNV1iwvSWD8EFNVrfxaTcqhcAXM3MPYkjlxvNnoDNk0R1lfzvca6LA=="
},
"@sindresorhus/is": {
"version": "4.2.0",
"resolved": "https://registry.npmjs.org/@sindresorhus/is/-/is-4.2.0.tgz",
"integrity": "sha512-VkE3KLBmJwcCaVARtQpfuKcKv8gcBmUubrfHGF84dXuuW6jgsRYxPtzcIhPyK9WAPpRt2/xY6zkD9MnRaJzSyw=="
},
"@types/node": {
"version": "16.10.3",
"resolved": "https://registry.npmjs.org/@types/node/-/node-16.10.3.tgz",
"integrity": "sha512-ho3Ruq+fFnBrZhUYI46n/bV2GjwzSkwuT4dTf0GkuNFmnb8nq4ny2z9JEVemFi6bdEJanHLlYfy9c6FN9B9McQ=="
},
"@types/ws": {
"version": "8.2.0",
"resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.2.0.tgz",
"integrity": "sha512-cyeefcUCgJlEk+hk2h3N+MqKKsPViQgF5boi9TTHSK+PoR9KWBb/C5ccPcDyAqgsbAYHTwulch725DV84+pSpg==",
"requires": {
"@types/node": "*"
}
},
"asynckit": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
"integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k="
},
"before-after-hook": {
"version": "2.2.2",
"resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.2.tgz",
"integrity": "sha512-3pZEU3NT5BFUo/AD5ERPWOgQOCZITni6iavr5AUw5AUwQjMlI0kzu5btnyD39AF0gUEsDPwJT+oY1ORBJijPjQ=="
},
"callsites": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz",
"integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ=="
},
"combined-stream": {
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
"integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
"requires": {
"delayed-stream": "~1.0.0"
}
},
"delayed-stream": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
"integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
},
"deprecation": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz",
"integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ=="
},
"discord-api-types": {
"version": "0.23.1",
"resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.23.1.tgz",
"integrity": "sha512-igWmn+45mzXRWNEPU25I/pr8MwxHb767wAr51oy3VRLRcTlp5ADBbrBR0lq3SA1Rfw3MtM4TQu1xo3kxscfVdQ=="
},
"discord.js": {
"version": "13.2.0",
"resolved": "https://registry.npmjs.org/discord.js/-/discord.js-13.2.0.tgz",
"integrity": "sha512-nyxUvL8wuQG38zx13wUMkpcA8koFszyiXdkSLwwM9opKW2LC2H5gD0cTZxImeJ6GtEnKPWT8xBiE8lLBmbNIhw==",
"requires": {
"@discordjs/builders": "^0.6.0",
"@discordjs/collection": "^0.2.1",
"@discordjs/form-data": "^3.0.1",
"@sapphire/async-queue": "^1.1.5",
"@types/ws": "^8.2.0",
"discord-api-types": "^0.23.1",
"node-fetch": "^2.6.1",
"ws": "^8.2.3"
}
},
"dot-prop": {
"version": "6.0.1",
"resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-6.0.1.tgz",
"integrity": "sha512-tE7ztYzXHIeyvc7N+hR3oi7FIbf/NIjVP9hmAt3yMXzrQ072/fpjGLx2GxNxGxUl5V73MEqYzioOMoVhGMJ5cA==",
"requires": {
"is-obj": "^2.0.0"
}
},
"is-obj": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz",
"integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w=="
},
"is-plain-object": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz",
"integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q=="
},
"lodash.isequal": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz",
"integrity": "sha1-QVxEePK8wwEgwizhDtMib30+GOA="
},
"mime-db": {
"version": "1.50.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.50.0.tgz",
"integrity": "sha512-9tMZCDlYHqeERXEHO9f/hKfNXhre5dK2eE/krIvUjZbS2KPcqGDfNShIWS1uW9XOTKQKqK6qbeOci18rbfW77A=="
},
"mime-types": {
"version": "2.1.33",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.33.tgz",
"integrity": "sha512-plLElXp7pRDd0bNZHw+nMd52vRYjLwQjygaNg7ddJ2uJtTlmnTCjWuPKxVu6//AdaRuME84SvLW91sIkBqGT0g==",
"requires": {
"mime-db": "1.50.0"
}
},
"node-fetch": {
"version": "2.6.7",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz",
"integrity": "sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==",
"requires": {
"whatwg-url": "^5.0.0"
}
},
"once": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
"requires": {
"wrappy": "1"
}
},
"ow": {
"version": "0.27.0",
"resolved": "https://registry.npmjs.org/ow/-/ow-0.27.0.tgz",
"integrity": "sha512-SGnrGUbhn4VaUGdU0EJLMwZWSupPmF46hnTRII7aCLCrqixTAC5eKo8kI4/XXf1eaaI8YEVT+3FeGNJI9himAQ==",
"requires": {
"@sindresorhus/is": "^4.0.1",
"callsites": "^3.1.0",
"dot-prop": "^6.0.1",
"lodash.isequal": "^4.5.0",
"type-fest": "^1.2.1",
"vali-date": "^1.0.0"
}
},
"tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
"integrity": "sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o="
},
"ts-mixer": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/ts-mixer/-/ts-mixer-6.0.0.tgz",
"integrity": "sha512-nXIb1fvdY5CBSrDIblLn73NW0qRDk5yJ0Sk1qPBF560OdJfQp9jhl+0tzcY09OZ9U+6GpeoI9RjwoIKFIoB9MQ=="
},
"tslib": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz",
"integrity": "sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw=="
},
"tunnel": {
"version": "0.0.6",
"resolved": "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz",
"integrity": "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg=="
},
"type-fest": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/type-fest/-/type-fest-1.4.0.tgz",
"integrity": "sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA=="
},
"universal-user-agent": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz",
"integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w=="
},
"vali-date": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/vali-date/-/vali-date-1.0.0.tgz",
"integrity": "sha1-G5BKWWCfsyjvB4E4Qgk09rhnCaY="
},
"webidl-conversions": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",
"integrity": "sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE="
},
"whatwg-url": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",
"integrity": "sha1-lmRU6HZUYuN2RNNib2dCzotwll0=",
"requires": {
"tr46": "~0.0.3",
"webidl-conversions": "^3.0.0"
}
},
"wrappy": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
},
"ws": {
"version": "8.2.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.2.3.tgz",
"integrity": "sha512-wBuoj1BDpC6ZQ1B7DWQBYVLphPWkm8i9Y0/3YdHjHKHiohOJ1ws+3OccDWtH+PoC9DZD5WOTrJvNbWvjS6JWaA==",
"requires": {}
}
}
}

View File

@@ -0,0 +1,16 @@
{
"name": "announce-release",
"version": "1.0.0",
"description": "",
"main": "index.js",
"type": "module",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"dependencies": {
"@actions/github": "^5.0.0",
"discord.js": "^13.2.0"
}
}

View File

@@ -0,0 +1,2 @@
node_modules/
*.md

View File

@@ -0,0 +1,68 @@
import { Octokit } from "@octokit/rest";
import { throttling } from "@octokit/plugin-throttling";
import { retry } from "@octokit/plugin-retry";
let owner = process.env.OWNER;
let repo = process.env.REPO;
Octokit.plugin(throttling);
Octokit.plugin(retry);
const octokit = new Octokit({
auth: process.env.GITHUB_TOKEN,
userAgent: `${owner}/${repo}`,
log: {
debug: () => { },
info: () => { },
warn: console.warn,
error: console.error
},
throttle: {
onRateLimit: (retryAfter, options) => {
octokit.log.warn(
`Request quota exhausted for request ${options.method} ${options.url}`
);
// Retry twice after hitting a rate limit error, then give up
if (options.request.retryCount <= 2) {
console.log(`Retrying after ${retryAfter} seconds!`);
return true;
}
},
onAbuseLimit: (retryAfter, options) => {
// does not retry, only logs a warning
octokit.log.warn(
`Abuse detected for request ${options.method} ${options.url}`
);
},
}
});
var args = process.argv.slice(2);
let commitSha = process.env.COMMIT_SHA;
console.log(`Searching for Commit - ${commitSha}`);
const { data: commit } = await octokit.rest.repos.getCommit({
owner: owner,
repo: repo,
ref: commitSha,
});
const { data: associatedPulls } = await octokit.rest.repos.listPullRequestsAssociatedWithCommit({
owner: owner,
repo: repo,
commit_sha: commit.sha,
});
let releaseNotes = ``;
if (associatedPulls.length === 0) {
releaseNotes += `- ${commit.commit.message}\n`;
} else {
for (var j = 0; j < associatedPulls.length; j++) {
releaseNotes += `- [${associatedPulls[j].title}](${associatedPulls[j].html_url})\n`;
}
}
import * as fs from 'fs';
fs.writeFileSync('./release-notes.md', releaseNotes);

View File

@@ -0,0 +1,202 @@
{
"name": "generate-release-notes",
"version": "1.0.0",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
"@octokit/auth-token": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/@octokit/auth-token/-/auth-token-2.5.0.tgz",
"integrity": "sha512-r5FVUJCOLl19AxiuZD2VRZ/ORjp/4IN98Of6YJoJOkY75CIBuYfmiNHGrDwXr+aLGG55igl9QrxX3hbiXlLb+g==",
"requires": {
"@octokit/types": "^6.0.3"
}
},
"@octokit/core": {
"version": "3.5.1",
"resolved": "https://registry.npmjs.org/@octokit/core/-/core-3.5.1.tgz",
"integrity": "sha512-omncwpLVxMP+GLpLPgeGJBF6IWJFjXDS5flY5VbppePYX9XehevbDykRH9PdCdvqt9TS5AOTiDide7h0qrkHjw==",
"requires": {
"@octokit/auth-token": "^2.4.4",
"@octokit/graphql": "^4.5.8",
"@octokit/request": "^5.6.0",
"@octokit/request-error": "^2.0.5",
"@octokit/types": "^6.0.3",
"before-after-hook": "^2.2.0",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/endpoint": {
"version": "6.0.12",
"resolved": "https://registry.npmjs.org/@octokit/endpoint/-/endpoint-6.0.12.tgz",
"integrity": "sha512-lF3puPwkQWGfkMClXb4k/eUT/nZKQfxinRWJrdZaJO85Dqwo/G0yOC434Jr2ojwafWJMYqFGFa5ms4jJUgujdA==",
"requires": {
"@octokit/types": "^6.0.3",
"is-plain-object": "^5.0.0",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/graphql": {
"version": "4.8.0",
"resolved": "https://registry.npmjs.org/@octokit/graphql/-/graphql-4.8.0.tgz",
"integrity": "sha512-0gv+qLSBLKF0z8TKaSKTsS39scVKF9dbMxJpj3U0vC7wjNWFuIpL/z76Qe2fiuCbDRcJSavkXsVtMS6/dtQQsg==",
"requires": {
"@octokit/request": "^5.6.0",
"@octokit/types": "^6.0.3",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/openapi-types": {
"version": "11.1.0",
"resolved": "https://registry.npmjs.org/@octokit/openapi-types/-/openapi-types-11.1.0.tgz",
"integrity": "sha512-dWZfYvCCdjZzDYA3lIAMF72Q0jld8xidqCq5Ryw09eBJXZdcM6he0vWBTvw/b5UnGYqexxOyHWgfrsTlUJL3Gw=="
},
"@octokit/plugin-paginate-rest": {
"version": "2.16.9",
"resolved": "https://registry.npmjs.org/@octokit/plugin-paginate-rest/-/plugin-paginate-rest-2.16.9.tgz",
"integrity": "sha512-gfSCMgz5scFKsR0dW4jaYsDJVt/UwCHp4dF7sHlmSekZvwzvLiOAGZ4MQkEsL5DW9hIk2W+UQkYZMTA1b6Wsqw==",
"requires": {
"@octokit/types": "^6.33.0"
}
},
"@octokit/plugin-request-log": {
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/@octokit/plugin-request-log/-/plugin-request-log-1.0.4.tgz",
"integrity": "sha512-mLUsMkgP7K/cnFEw07kWqXGF5LKrOkD+lhCrKvPHXWDywAwuDUeDwWBpc69XK3pNX0uKiVt8g5z96PJ6z9xCFA=="
},
"@octokit/plugin-rest-endpoint-methods": {
"version": "5.12.1",
"resolved": "https://registry.npmjs.org/@octokit/plugin-rest-endpoint-methods/-/plugin-rest-endpoint-methods-5.12.1.tgz",
"integrity": "sha512-0nY3htfl6x9UkPcqv8pm9vOC/bTA7f4IMDWln13neHRdNWQvOQgZ9fRxK7BAc74rye4yVINEFi9Yb9rnGUvosA==",
"requires": {
"@octokit/types": "^6.33.0",
"deprecation": "^2.3.1"
}
},
"@octokit/plugin-retry": {
"version": "3.0.9",
"resolved": "https://registry.npmjs.org/@octokit/plugin-retry/-/plugin-retry-3.0.9.tgz",
"integrity": "sha512-r+fArdP5+TG6l1Rv/C9hVoty6tldw6cE2pRHNGmFPdyfrc696R6JjrQ3d7HdVqGwuzfyrcaLAKD7K8TX8aehUQ==",
"requires": {
"@octokit/types": "^6.0.3",
"bottleneck": "^2.15.3"
}
},
"@octokit/plugin-throttling": {
"version": "3.5.2",
"resolved": "https://registry.npmjs.org/@octokit/plugin-throttling/-/plugin-throttling-3.5.2.tgz",
"integrity": "sha512-Eu7kfJxU8vmHqWGNszWpg+GVp2tnAfax3XQV5CkYPEE69C+KvInJXW9WajgSeW+cxYe0UVdouzCtcreGNuJo7A==",
"requires": {
"@octokit/types": "^6.0.1",
"bottleneck": "^2.15.3"
}
},
"@octokit/request": {
"version": "5.6.2",
"resolved": "https://registry.npmjs.org/@octokit/request/-/request-5.6.2.tgz",
"integrity": "sha512-je66CvSEVf0jCpRISxkUcCa0UkxmFs6eGDRSbfJtAVwbLH5ceqF+YEyC8lj8ystKyZTy8adWr0qmkY52EfOeLA==",
"requires": {
"@octokit/endpoint": "^6.0.1",
"@octokit/request-error": "^2.1.0",
"@octokit/types": "^6.16.1",
"is-plain-object": "^5.0.0",
"node-fetch": "^2.6.1",
"universal-user-agent": "^6.0.0"
}
},
"@octokit/request-error": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/@octokit/request-error/-/request-error-2.1.0.tgz",
"integrity": "sha512-1VIvgXxs9WHSjicsRwq8PlR2LR2x6DwsJAaFgzdi0JfJoGSO8mYI/cHJQ+9FbN21aa+DrgNLnwObmyeSC8Rmpg==",
"requires": {
"@octokit/types": "^6.0.3",
"deprecation": "^2.0.0",
"once": "^1.4.0"
}
},
"@octokit/rest": {
"version": "18.12.0",
"resolved": "https://registry.npmjs.org/@octokit/rest/-/rest-18.12.0.tgz",
"integrity": "sha512-gDPiOHlyGavxr72y0guQEhLsemgVjwRePayJ+FcKc2SJqKUbxbkvf5kAZEWA/MKvsfYlQAMVzNJE3ezQcxMJ2Q==",
"requires": {
"@octokit/core": "^3.5.1",
"@octokit/plugin-paginate-rest": "^2.16.8",
"@octokit/plugin-request-log": "^1.0.4",
"@octokit/plugin-rest-endpoint-methods": "^5.12.0"
}
},
"@octokit/types": {
"version": "6.33.0",
"resolved": "https://registry.npmjs.org/@octokit/types/-/types-6.33.0.tgz",
"integrity": "sha512-0zffZ048M0UhthyPXQHLz4038Ak46nMWZXkzlXvXB/M/L1jYPBceq4iZj4qjKVrvveaJrrgKdJ9+3yUuITfcCw==",
"requires": {
"@octokit/openapi-types": "^11.1.0"
}
},
"before-after-hook": {
"version": "2.2.2",
"resolved": "https://registry.npmjs.org/before-after-hook/-/before-after-hook-2.2.2.tgz",
"integrity": "sha512-3pZEU3NT5BFUo/AD5ERPWOgQOCZITni6iavr5AUw5AUwQjMlI0kzu5btnyD39AF0gUEsDPwJT+oY1ORBJijPjQ=="
},
"bottleneck": {
"version": "2.19.5",
"resolved": "https://registry.npmjs.org/bottleneck/-/bottleneck-2.19.5.tgz",
"integrity": "sha512-VHiNCbI1lKdl44tGrhNfU3lup0Tj/ZBMJB5/2ZbNXRCPuRCO7ed2mgcK4r17y+KB2EfuYuRaVlwNbAeaWGSpbw=="
},
"deprecation": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/deprecation/-/deprecation-2.3.1.tgz",
"integrity": "sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ=="
},
"is-plain-object": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-5.0.0.tgz",
"integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q=="
},
"node-fetch": {
"version": "2.6.7",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz",
"integrity": "sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==",
"requires": {
"whatwg-url": "^5.0.0"
}
},
"once": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
"requires": {
"wrappy": "1"
}
},
"tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
"integrity": "sha1-gYT9NH2snNwYWZLzpmIuFLnZq2o="
},
"universal-user-agent": {
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/universal-user-agent/-/universal-user-agent-6.0.0.tgz",
"integrity": "sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w=="
},
"webidl-conversions": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",
"integrity": "sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE="
},
"whatwg-url": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",
"integrity": "sha1-lmRU6HZUYuN2RNNib2dCzotwll0=",
"requires": {
"tr46": "~0.0.3",
"webidl-conversions": "^3.0.0"
}
},
"wrappy": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
}
}
}

View File

@@ -0,0 +1,17 @@
{
"name": "generate-release-notes",
"version": "1.0.0",
"description": "",
"main": "index.js",
"type": "module",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"dependencies": {
"@octokit/plugin-retry": "^3.0.9",
"@octokit/plugin-throttling": "^3.5.2",
"@octokit/rest": "^18.12.0"
}
}

View File

@@ -0,0 +1,49 @@
import os
import shutil
tag = os.environ['TAG'].split("refs/tags/")[1]
scan_dir = os.environ['SCAN_DIR']
output_dir = os.environ['OUT_DIR']
accepted_exts = ["AppImage", "tar.gz", "7z"]
for dir_name in os.listdir(scan_dir):
asset_name = "pcsx2-{}".format(tag)
if "macos" in dir_name.lower():
asset_name += "-macos"
elif "linux" in dir_name.lower():
asset_name += "-linux-AppImage-64bit"
elif "windows" in dir_name.lower():
asset_name += "-windows-64bit"
else:
continue;
if "avx2" in dir_name.lower():
asset_name += "-AVX2"
elif "sse4" in dir_name.lower():
asset_name += "-SSE4"
if "wxwidgets" in dir_name.lower():
asset_name += "-wxWidgets"
else:
asset_name += "-Qt"
if "symbols" in dir_name.lower():
asset_name += "-symbols"
print(asset_name)
dir_handled = False
for file in os.listdir(os.path.join(scan_dir, dir_name)):
for ext in accepted_exts:
if file.endswith(ext):
dir_handled = True
print("Moving {} to out dir".format(file))
shutil.move(os.path.join(scan_dir, dir_name, file), os.path.join(output_dir, asset_name + "." + ext))
break
if dir_handled:
break
if not dir_handled:
print("Could not find asset in directory when one was expected")
exit(1)

View File

@@ -0,0 +1,19 @@
$filterFiles = Get-ChildItem $PWD -name -recurse *.vcxproj.filters
$failed = $FALSE
foreach ($file in $filterFiles) {
# Skip 3rdparty files
if ($file -NotMatch "^3rdparty") {
$expression = "python -c `"import sys, xml.dom.minidom as d; d.parse(sys.argv[1])`" $($file)"
$expression += ';$LastExitCode'
$exitCode = Invoke-Expression $expression
if($exitCode -ne 0){
Write-Host -foregroundColor red "$($file) - Invalid VS filters file. Likely missing tags"
$failed = $TRUE
}
}
}
if ($failed) {
exit 1
}

27
.github/workflows/triage_pr.yml vendored Normal file
View File

@@ -0,0 +1,27 @@
# Runs steps to triage an incoming Pull Request, for example - applying labels.
name: 🤔 Pull Request Triage
on: pull_request_target
jobs:
triage:
if: github.repository == 'PCSX2/pcsx2'
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@main
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: xTVaser/first-interaction@v1.2.4
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
debug-mode: false
pr-message: |-
## Thank you for submitting a contribution to PCSX2
As this is your first pull request, [please be aware of the contributing guidelines](https://github.com/PCSX2/pcsx2/blob/master/.github/CONTRIBUTING.md).
Additionally, as per recent changes in GitHub Actions, your pull request will need to be approved by a maintainer before GitHub Actions can run against it. [You can find more information about this change here.](https://github.blog/2021-04-22-github-actions-update-helping-maintainers-combat-bad-actors/)
Please be patient until this happens. In the meantime if you'd like to confirm the builds are passing, you have the option of opening a PR on your own fork, just make sure your fork's master branch is up to date!
pr-labels: "First Time Contribution"

View File

@@ -0,0 +1,68 @@
name: 🖥️ Windows Builds
on:
push:
branches:
- '*'
pull_request:
branches:
- master
jobs:
# MSBUILD
lint_vs_proj_files:
name: Lint VS Project Files
runs-on: windows-2019
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Verify VS Project Files
run: .github\workflows\scripts\windows\validate-vs-filters.ps1
build_wx_sse4:
needs: lint_vs_proj_files
name: "SSE4"
uses: ./.github/workflows/windows_build_wx.yml
with:
jobName: wxWidgets
configuration: Release
simd: "SSE4"
secrets: inherit
build_wx_avx2:
needs: lint_vs_proj_files
name: "AVX2"
uses: ./.github/workflows/windows_build_wx.yml
with:
jobName: wxWidgets
configuration: Release AVX2
secrets: inherit
build_qt_sse4:
needs: lint_vs_proj_files
name: "SSE4"
uses: ./.github/workflows/windows_build_qt.yml
with:
jobName: Qt
configuration: Release
simd: "SSE4"
secrets: inherit
build_qt_avx2:
needs: lint_vs_proj_files
name: "AVX2"
uses: ./.github/workflows/windows_build_qt.yml
with:
jobName: Qt
configuration: Release AVX2
secrets: inherit
# CMAKE
build_wx_sse4_cmake:
name: "CMake SSE4"
uses: ./.github/workflows/windows_build_wx.yml
with:
jobName: wxWidgets
configuration: CMake
buildSystem: cmake
secrets: inherit

119
.github/workflows/windows_build_qt.yml vendored Normal file
View File

@@ -0,0 +1,119 @@
name: Windows Build Steps - Qt
on:
workflow_call:
inputs:
jobName:
required: true
type: string
os:
required: false
type: string
default: windows-2019
platform:
required: false
type: string
default: x64
configuration:
required: true
type: string
simd:
required: false
type: string
default: AVX2
buildSystem:
required: false
type: string
default: msbuild
qt_binary_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2-windows-dependencies/releases/download/2022-07-24/qt-6.3.1-x64.7z
cheats_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2_patches/releases/latest/download
jobs:
build_windows_qt:
name: ${{ inputs.jobName }}
runs-on: ${{ inputs.os }}
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
timeout-minutes: 60
env:
POWERSHELL_TELEMETRY_OPTOUT: 1
BUILDCACHE_COMPRESS_FORMAT: ZSTD
BUILDCACHE_COMPRESS_LEVEL: 9
BUILDCACHE_MAX_CACHE_SIZE: 536870912 # 512MB
BUILDCACHE_DIRECT_MODE: true
BUILDCACHE_LOG_FILE: ${{ github.workspace }}\buildcache.log
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Prepare Artifact Metadata
id: artifact-metadata
shell: bash
env:
OS: windows
BUILD_SYSTEM: ${{ inputs.buildSystem }}
GUI_FRAMEWORK: Qt
ARCH: ${{ inputs.platform }}
SIMD: ${{ inputs.simd }}
EVENT_NAME: ${{ github.event_name }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_NUM: ${{ github.event.pull_request.number }}
PR_SHA: ${{ github.event.pull_request.head.sha }}
run: ./.github/workflows/scripts/common/name-artifacts.sh
- name: Setup msbuild
if: inputs.configuration != 'CMake'
uses: microsoft/setup-msbuild@v1
- name: Download Qt build files
shell: cmd
run: |
cd 3rdparty\qt
aria2c ${{ inputs.qt_binary_url }}
7z x qt-*-x64.7z
del qt-*-x64.7z
- name: Download cheats
shell: cmd
run: |
cd bin/resources
aria2c -Z "${{ inputs.cheats_url }}/cheats_ni.zip" "${{ inputs.cheats_url }}/cheats_ws.zip"
- name: Build PCSX2
shell: cmd
run: |
if "${{ inputs.configuration }}"=="CMake" (
call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\${{ steps.cmake.outputs.vcvars }}"
cmake --build build --config ${{ steps.cmake.outputs.buildtype }}
) else (
msbuild "PCSX2_qt.sln" /m /v:m /p:Configuration="${{ inputs.configuration }}" /p:Platform="${{ inputs.platform }}"
)
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
path: |
./bin
!./bin/**/*.bsc
!./bin/**/*.exp
!./bin/**/*.ilk
!./bin/**/*.iobj
!./bin/**/*.ipdb
!./bin/**/*.pdb
!./bin/**/*.lib
- name: Upload artifact - with symbols
if: inputs.configuration != 'CMake'
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}-symbols
path: ./bin/**/*.pdb

119
.github/workflows/windows_build_wx.yml vendored Normal file
View File

@@ -0,0 +1,119 @@
name: Windows Build Steps - wxWidgets
on:
workflow_call:
inputs:
jobName:
required: true
type: string
os:
required: false
type: string
default: windows-2019
platform:
required: false
type: string
default: x64
simd:
required: false
type: string
default: AVX2
buildSystem:
required: false
type: string
default: msbuild
configuration:
required: true
type: string
cheats_url:
required: false
type: string
default: https://github.com/PCSX2/pcsx2_patches/releases/latest/download
jobs:
build_windows_wx:
name: ${{ inputs.jobName }}
runs-on: ${{ inputs.os }}
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
timeout-minutes: 60
env:
POWERSHELL_TELEMETRY_OPTOUT: 1
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive
- name: Prepare Artifact Metadata
id: artifact-metadata
shell: bash
env:
OS: windows
BUILD_SYSTEM: ${{ inputs.buildSystem }}
GUI_FRAMEWORK: wxWidgets
ARCH: ${{ inputs.platform }}
SIMD: ${{ inputs.simd }}
EVENT_NAME: ${{ github.event_name }}
PR_TITLE: ${{ github.event.pull_request.title }}
PR_NUM: ${{ github.event.pull_request.number }}
PR_SHA: ${{ github.event.pull_request.head.sha }}
run: ./.github/workflows/scripts/common/name-artifacts.sh
- name: Setup msbuild
if: inputs.configuration != 'CMake'
uses: microsoft/setup-msbuild@v1
- name: Download cheats
shell: cmd
run: |
cd bin/resources
aria2c -Z "${{ inputs.cheats_url }}/cheats_ni.zip" "${{ inputs.cheats_url }}/cheats_ws.zip"
- name: Generate CMake
if: inputs.configuration == 'CMake'
id: cmake
shell: cmd
run: |
if "${{ inputs.platform }}"=="Win32" (SET vcvars=vcvarsamd64_x86.bat) else (SET vcvars=vcvars64.bat)
call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\%vcvars%"
echo ::set-output name=vcvars::%vcvars%
cmake . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON -G Ninja
- name: Build PCSX2
shell: cmd
run: |
if "${{ inputs.configuration }}"=="CMake" (
call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\${{ steps.cmake.outputs.vcvars }}"
cmake --build build --config Release || exit /b
cp build/pcsx2/pcsx2* bin/
) else (
msbuild "PCSX2_suite.sln" /m /v:m /p:Configuration="${{ inputs.configuration }}" /p:Platform="${{ inputs.platform }}"
)
- name: Run Tests
if: inputs.configuration == 'CMake'
shell: cmd
run: |
call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\${{ steps.cmake.outputs.vcvars }}"
cmake --build build --config Release --target unittests
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
path: |
./bin
!./bin/**/*.bsc
!./bin/**/*.exp
!./bin/**/*.ilk
!./bin/**/*.iobj
!./bin/**/*.ipdb
!./bin/**/*.pdb
!./bin/**/*.lib
- name: Upload artifact - with symbols
uses: actions/upload-artifact@v3
with:
name: ${{ steps.artifact-metadata.outputs.artifact-name }}-symbols
path: ./bin/**/*.pdb

49
.gitignore vendored
View File

@@ -19,10 +19,6 @@
*.dump
*.asm
!/plugins/zerogs/dx/x86-32.asm
!/plugins/zerogs/dx/x86-64.asm
!/plugins/zerogs/opengl/x86-32.asm
!/plugins/zzogl-pg/opengl/x86-32.asm
*.VC.db
*.VC.VC.opendb
@@ -34,12 +30,17 @@
**/x64/Debug*
**/x64/Devel*
**/bin/PCSX2-linux.sh
_ReSharper.*
pcsx2.snapshot_*
svnrev.h
/build
/build_dev
/build_dbg
/obj-*
*.obj
.DS_Store
Thumbs.db
@@ -47,6 +48,7 @@ Thumbs.db
Debug.txt
install_log.txt
padLog.txt
GS_opengl_debug.txt
Debug
Release
@@ -63,16 +65,25 @@ oprofile_data/
# Visual Studio upgrades
/Backup*
/UpgradeLog*.htm
/.vscode*
/bin/**/*.dll
/bin/**/*.dmp
/bin/**/*.exp
/bin/**/*.ilk
/bin/**/*.lib
/bin/**/*.pdb
/bin/PCSX2
/bin/pcsx2
/bin/PCSX2-linux.sh
/bin/*ReplayLoader
/bin/GS*.txt
/bin/qt.conf
/bin/bios
/bin/cache
/bin/cheats
/bin/covers
/bin/dumps
/bin/gamesettings
/bin/help
/bin/inis
/bin/logs
@@ -80,35 +91,21 @@ oprofile_data/
/bin/plugins
/bin/snaps
/bin/sstates
/bin/textures
/bin/translations
/bin/inputprofiles
/deps
/ipch
!/3rdparty/libjpeg/change.log
/3rdparty/portaudio/portaudio-2.0.pc
/3rdparty/portaudio/bin
/3rdparty/portaudio/bin-*
/3rdparty/portaudio/autom4te.cache
/3rdparty/portaudio/libtool
/3rdparty/portaudio/config.*
/3rdparty/portaudio/lib-stamp
/3rdparty/portaudio/Makefile
/3rdparty/portaudio/bindings
/3rdparty/portaudio/test
/3rdparty/portaudio/testcvs
/3rdparty/portaudio/src/hostapi/asio/ASIOSDK/common
/3rdparty/portaudio/src/hostapi/asio/ASIOSDK/host
/3rdparty/portaudio/src/hostapi/wasapi/mingw-include
/3rdparty/**/include/wx/setup.h
/3rdparty/**/wx/msw/rcdefs.h
/pcsx2/gui/Resources/*.h
!/pcsx2/gui/Resources/EmbeddedImage.h
/plugins/GSdx/Template
/plugins/USBqemu/Win32/bin
/plugins/zerospu2/Windows/dsound51.cpp
/tools/bin
/tools/GSDumpGUI/bin
/tools/GSDumpGUI/obj
.vs
/pcsx2/windows/VCprojects/GSdx_opengl_debug_hw.txt
/pcsx2/windows/VCprojects/GSdx_opengl_debug_sw.txt
/out/build/x64-Debug (default)
CMakeSettings.json
/ci-artifacts/
/out/

38
.gitmodules vendored
View File

@@ -1,3 +1,41 @@
[submodule "3rdparty/xz/xz"]
path = 3rdparty/xz/xz
url = https://github.com/PCSX2/xz.git
[submodule "3rdparty/gtest"]
path = 3rdparty/gtest
url = https://github.com/google/googletest.git
[submodule "3rdparty/fmt/fmt"]
path = 3rdparty/fmt/fmt
url = https://github.com/fmtlib/fmt.git
[submodule "3rdparty/libchdr/libchdr"]
path = 3rdparty/libchdr/libchdr
url = https://github.com/rtissera/libchdr.git
[submodule "3rdparty/wil"]
path = 3rdparty/wil
url = https://github.com/microsoft/wil.git
branch = master
[submodule "3rdparty/cubeb/cubeb"]
path = 3rdparty/cubeb/cubeb
url = https://github.com/mozilla/cubeb.git
[submodule "3rdparty/rapidyaml/rapidyaml"]
path = 3rdparty/rapidyaml/rapidyaml
url = https://github.com/biojppm/rapidyaml.git
branch = master
[submodule "3rdparty/imgui/imgui"]
path = 3rdparty/imgui/imgui
url = https://github.com/ocornut/imgui.git
[submodule "3rdparty/glslang/glslang"]
path = 3rdparty/glslang/glslang
url = https://github.com/KhronosGroup/glslang.git
[submodule "3rdparty/vulkan-headers"]
path = 3rdparty/vulkan-headers
url = https://github.com/KhronosGroup/Vulkan-Headers.git
[submodule "3rdparty/sdl2/SDL"]
path = 3rdparty/sdl2/SDL
url = https://github.com/libsdl-org/SDL.git
[submodule "3rdparty/libzip/libzip"]
path = 3rdparty/libzip/libzip
url = https://github.com/nih-at/libzip.git
[submodule "3rdparty/zstd/zstd"]
path = 3rdparty/zstd/zstd
url = https://github.com/facebook/zstd.git

8
.prettierrc.yaml Normal file
View File

@@ -0,0 +1,8 @@
overrides:
- files: "**/GameIndex.yaml"
options:
tabWidth: 2
useTabs: false
quoteProps: consistent
endOfLine: auto
proseWrap: preserve

View File

@@ -1,34 +0,0 @@
language: cpp
sudo: required
cache: ccache
dist: xenial
matrix:
include:
- env: VERSION=8 BITS=64
compiler: gcc
os: linux
- env: VERSION=8 BITS=32
compiler: gcc
os: linux
- env: VERSION=7 BITS=32
compiler: gcc
os: linux
- env: VERSION=3.8 BITS=32
compiler: clang
os: linux
before_install:
- ./travis.sh before_install
before_script:
- ./travis.sh before_script
script:
- ./travis.sh script
after_success:
- ./travis.sh after_success

View File

@@ -13,7 +13,7 @@
<StructMemberAlignment>16Bytes</StructMemberAlignment>
<FunctionLevelLinking>true</FunctionLevelLinking>
<RuntimeTypeInfo>false</RuntimeTypeInfo>
<WarningLevel>Level3</WarningLevel>
<WarningLevel>TurnOffAllWarnings</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<CompileAs>Default</CompileAs>
</ClCompile>

5866
3rdparty/GL/glcorearb.h vendored

File diff suppressed because it is too large Load Diff

12146
3rdparty/GL/glext.h vendored

File diff suppressed because it is too large Load Diff

282
3rdparty/GL/khrplatform.h vendored Normal file
View File

@@ -0,0 +1,282 @@
#ifndef __khrplatform_h_
#define __khrplatform_h_
/*
** Copyright (c) 2008-2018 The Khronos Group Inc.
**
** Permission is hereby granted, free of charge, to any person obtaining a
** copy of this software and/or associated documentation files (the
** "Materials"), to deal in the Materials without restriction, including
** without limitation the rights to use, copy, modify, merge, publish,
** distribute, sublicense, and/or sell copies of the Materials, and to
** permit persons to whom the Materials are furnished to do so, subject to
** the following conditions:
**
** The above copyright notice and this permission notice shall be included
** in all copies or substantial portions of the Materials.
**
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
*/
/* Khronos platform-specific types and definitions.
*
* The master copy of khrplatform.h is maintained in the Khronos EGL
* Registry repository at https://github.com/KhronosGroup/EGL-Registry
* The last semantic modification to khrplatform.h was at commit ID:
* 67a3e0864c2d75ea5287b9f3d2eb74a745936692
*
* Adopters may modify this file to suit their platform. Adopters are
* encouraged to submit platform specific modifications to the Khronos
* group so that they can be included in future versions of this file.
* Please submit changes by filing pull requests or issues on
* the EGL Registry repository linked above.
*
*
* See the Implementer's Guidelines for information about where this file
* should be located on your system and for more details of its use:
* http://www.khronos.org/registry/implementers_guide.pdf
*
* This file should be included as
* #include <KHR/khrplatform.h>
* by Khronos client API header files that use its types and defines.
*
* The types in khrplatform.h should only be used to define API-specific types.
*
* Types defined in khrplatform.h:
* khronos_int8_t signed 8 bit
* khronos_uint8_t unsigned 8 bit
* khronos_int16_t signed 16 bit
* khronos_uint16_t unsigned 16 bit
* khronos_int32_t signed 32 bit
* khronos_uint32_t unsigned 32 bit
* khronos_int64_t signed 64 bit
* khronos_uint64_t unsigned 64 bit
* khronos_intptr_t signed same number of bits as a pointer
* khronos_uintptr_t unsigned same number of bits as a pointer
* khronos_ssize_t signed size
* khronos_usize_t unsigned size
* khronos_float_t signed 32 bit floating point
* khronos_time_ns_t unsigned 64 bit time in nanoseconds
* khronos_utime_nanoseconds_t unsigned time interval or absolute time in
* nanoseconds
* khronos_stime_nanoseconds_t signed time interval in nanoseconds
* khronos_boolean_enum_t enumerated boolean type. This should
* only be used as a base type when a client API's boolean type is
* an enum. Client APIs which use an integer or other type for
* booleans cannot use this as the base type for their boolean.
*
* Tokens defined in khrplatform.h:
*
* KHRONOS_FALSE, KHRONOS_TRUE Enumerated boolean false/true values.
*
* KHRONOS_SUPPORT_INT64 is 1 if 64 bit integers are supported; otherwise 0.
* KHRONOS_SUPPORT_FLOAT is 1 if floats are supported; otherwise 0.
*
* Calling convention macros defined in this file:
* KHRONOS_APICALL
* KHRONOS_APIENTRY
* KHRONOS_APIATTRIBUTES
*
* These may be used in function prototypes as:
*
* KHRONOS_APICALL void KHRONOS_APIENTRY funcname(
* int arg1,
* int arg2) KHRONOS_APIATTRIBUTES;
*/
/*-------------------------------------------------------------------------
* Definition of KHRONOS_APICALL
*-------------------------------------------------------------------------
* This precedes the return type of the function in the function prototype.
*/
#if defined(_WIN32) && !defined(__SCITECH_SNAP__)
# define KHRONOS_APICALL __declspec(dllimport)
#elif defined (__SYMBIAN32__)
# define KHRONOS_APICALL IMPORT_C
#elif defined(__ANDROID__)
# define KHRONOS_APICALL __attribute__((visibility("default")))
#else
# define KHRONOS_APICALL
#endif
/*-------------------------------------------------------------------------
* Definition of KHRONOS_APIENTRY
*-------------------------------------------------------------------------
* This follows the return type of the function and precedes the function
* name in the function prototype.
*/
#if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(__SCITECH_SNAP__)
/* Win32 but not WinCE */
# define KHRONOS_APIENTRY __stdcall
#else
# define KHRONOS_APIENTRY
#endif
/*-------------------------------------------------------------------------
* Definition of KHRONOS_APIATTRIBUTES
*-------------------------------------------------------------------------
* This follows the closing parenthesis of the function prototype arguments.
*/
#if defined (__ARMCC_2__)
#define KHRONOS_APIATTRIBUTES __softfp
#else
#define KHRONOS_APIATTRIBUTES
#endif
/*-------------------------------------------------------------------------
* basic type definitions
*-----------------------------------------------------------------------*/
#if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || defined(__GNUC__) || defined(__SCO__) || defined(__USLC__)
/*
* Using <stdint.h>
*/
#include <stdint.h>
typedef int32_t khronos_int32_t;
typedef uint32_t khronos_uint32_t;
typedef int64_t khronos_int64_t;
typedef uint64_t khronos_uint64_t;
#define KHRONOS_SUPPORT_INT64 1
#define KHRONOS_SUPPORT_FLOAT 1
#elif defined(__VMS ) || defined(__sgi)
/*
* Using <inttypes.h>
*/
#include <inttypes.h>
typedef int32_t khronos_int32_t;
typedef uint32_t khronos_uint32_t;
typedef int64_t khronos_int64_t;
typedef uint64_t khronos_uint64_t;
#define KHRONOS_SUPPORT_INT64 1
#define KHRONOS_SUPPORT_FLOAT 1
#elif defined(_WIN32) && !defined(__SCITECH_SNAP__)
/*
* Win32
*/
typedef __int32 khronos_int32_t;
typedef unsigned __int32 khronos_uint32_t;
typedef __int64 khronos_int64_t;
typedef unsigned __int64 khronos_uint64_t;
#define KHRONOS_SUPPORT_INT64 1
#define KHRONOS_SUPPORT_FLOAT 1
#elif defined(__sun__) || defined(__digital__)
/*
* Sun or Digital
*/
typedef int khronos_int32_t;
typedef unsigned int khronos_uint32_t;
#if defined(__arch64__) || defined(_LP64)
typedef long int khronos_int64_t;
typedef unsigned long int khronos_uint64_t;
#else
typedef long long int khronos_int64_t;
typedef unsigned long long int khronos_uint64_t;
#endif /* __arch64__ */
#define KHRONOS_SUPPORT_INT64 1
#define KHRONOS_SUPPORT_FLOAT 1
#elif 0
/*
* Hypothetical platform with no float or int64 support
*/
typedef int khronos_int32_t;
typedef unsigned int khronos_uint32_t;
#define KHRONOS_SUPPORT_INT64 0
#define KHRONOS_SUPPORT_FLOAT 0
#else
/*
* Generic fallback
*/
#include <stdint.h>
typedef int32_t khronos_int32_t;
typedef uint32_t khronos_uint32_t;
typedef int64_t khronos_int64_t;
typedef uint64_t khronos_uint64_t;
#define KHRONOS_SUPPORT_INT64 1
#define KHRONOS_SUPPORT_FLOAT 1
#endif
/*
* Types that are (so far) the same on all platforms
*/
typedef signed char khronos_int8_t;
typedef unsigned char khronos_uint8_t;
typedef signed short int khronos_int16_t;
typedef unsigned short int khronos_uint16_t;
/*
* Types that differ between LLP64 and LP64 architectures - in LLP64,
* pointers are 64 bits, but 'long' is still 32 bits. Win64 appears
* to be the only LLP64 architecture in current use.
*/
#ifdef _WIN64
typedef signed long long int khronos_intptr_t;
typedef unsigned long long int khronos_uintptr_t;
typedef signed long long int khronos_ssize_t;
typedef unsigned long long int khronos_usize_t;
#else
typedef signed long int khronos_intptr_t;
typedef unsigned long int khronos_uintptr_t;
typedef signed long int khronos_ssize_t;
typedef unsigned long int khronos_usize_t;
#endif
#if KHRONOS_SUPPORT_FLOAT
/*
* Float type
*/
typedef float khronos_float_t;
#endif
#if KHRONOS_SUPPORT_INT64
/* Time types
*
* These types can be used to represent a time interval in nanoseconds or
* an absolute Unadjusted System Time. Unadjusted System Time is the number
* of nanoseconds since some arbitrary system event (e.g. since the last
* time the system booted). The Unadjusted System Time is an unsigned
* 64 bit value that wraps back to 0 every 584 years. Time intervals
* may be either signed or unsigned.
*/
typedef khronos_uint64_t khronos_utime_nanoseconds_t;
typedef khronos_int64_t khronos_stime_nanoseconds_t;
#endif
/*
* Dummy value used to pad enum types to 32 bits.
*/
#ifndef KHRONOS_MAX_ENUM
#define KHRONOS_MAX_ENUM 0x7FFFFFFF
#endif
/*
* Enumerated boolean type
*
* Values other than zero should be considered to be true. Therefore
* comparisons should not be made against KHRONOS_TRUE.
*/
typedef enum {
KHRONOS_FALSE = 0,
KHRONOS_TRUE = 1,
KHRONOS_BOOLEAN_ENUM_FORCE_SIZE = KHRONOS_MAX_ENUM
} khronos_boolean_enum_t;
#endif /* __khrplatform_h_ */

840
3rdparty/GL/wglext.h vendored
View File

@@ -1,840 +0,0 @@
#ifndef __wglext_h_
#define __wglext_h_ 1
#ifdef __cplusplus
extern "C" {
#endif
/*
** Copyright (c) 2013-2016 The Khronos Group Inc.
**
** Permission is hereby granted, free of charge, to any person obtaining a
** copy of this software and/or associated documentation files (the
** "Materials"), to deal in the Materials without restriction, including
** without limitation the rights to use, copy, modify, merge, publish,
** distribute, sublicense, and/or sell copies of the Materials, and to
** permit persons to whom the Materials are furnished to do so, subject to
** the following conditions:
**
** The above copyright notice and this permission notice shall be included
** in all copies or substantial portions of the Materials.
**
** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
*/
/*
** This header is generated from the Khronos OpenGL / OpenGL ES XML
** API Registry. The current version of the Registry, generator scripts
** used to make the header, and the header can be found at
** http://www.opengl.org/registry/
**
** Khronos $Revision: 33248 $ on $Date: 2016-10-24 01:22:03 -0400 (Mon, 24 Oct 2016) $
*/
#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__)
#define WIN32_LEAN_AND_MEAN 1
#include <windows.h>
#endif
#define WGL_WGLEXT_VERSION 20161024
/* Generated C header for:
* API: wgl
* Versions considered: .*
* Versions emitted: _nomatch_^
* Default extensions included: wgl
* Additional extensions included: _nomatch_^
* Extensions removed: _nomatch_^
*/
#ifndef WGL_ARB_buffer_region
#define WGL_ARB_buffer_region 1
#define WGL_FRONT_COLOR_BUFFER_BIT_ARB 0x00000001
#define WGL_BACK_COLOR_BUFFER_BIT_ARB 0x00000002
#define WGL_DEPTH_BUFFER_BIT_ARB 0x00000004
#define WGL_STENCIL_BUFFER_BIT_ARB 0x00000008
typedef HANDLE (WINAPI * PFNWGLCREATEBUFFERREGIONARBPROC) (HDC hDC, int iLayerPlane, UINT uType);
typedef VOID (WINAPI * PFNWGLDELETEBUFFERREGIONARBPROC) (HANDLE hRegion);
typedef BOOL (WINAPI * PFNWGLSAVEBUFFERREGIONARBPROC) (HANDLE hRegion, int x, int y, int width, int height);
typedef BOOL (WINAPI * PFNWGLRESTOREBUFFERREGIONARBPROC) (HANDLE hRegion, int x, int y, int width, int height, int xSrc, int ySrc);
#ifdef WGL_WGLEXT_PROTOTYPES
HANDLE WINAPI wglCreateBufferRegionARB (HDC hDC, int iLayerPlane, UINT uType);
VOID WINAPI wglDeleteBufferRegionARB (HANDLE hRegion);
BOOL WINAPI wglSaveBufferRegionARB (HANDLE hRegion, int x, int y, int width, int height);
BOOL WINAPI wglRestoreBufferRegionARB (HANDLE hRegion, int x, int y, int width, int height, int xSrc, int ySrc);
#endif
#endif /* WGL_ARB_buffer_region */
#ifndef WGL_ARB_context_flush_control
#define WGL_ARB_context_flush_control 1
#define WGL_CONTEXT_RELEASE_BEHAVIOR_ARB 0x2097
#define WGL_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB 0
#define WGL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_ARB 0x2098
#endif /* WGL_ARB_context_flush_control */
#ifndef WGL_ARB_create_context
#define WGL_ARB_create_context 1
#define WGL_CONTEXT_DEBUG_BIT_ARB 0x00000001
#define WGL_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002
#define WGL_CONTEXT_MAJOR_VERSION_ARB 0x2091
#define WGL_CONTEXT_MINOR_VERSION_ARB 0x2092
#define WGL_CONTEXT_LAYER_PLANE_ARB 0x2093
#define WGL_CONTEXT_FLAGS_ARB 0x2094
#define ERROR_INVALID_VERSION_ARB 0x2095
typedef HGLRC (WINAPI * PFNWGLCREATECONTEXTATTRIBSARBPROC) (HDC hDC, HGLRC hShareContext, const int *attribList);
#ifdef WGL_WGLEXT_PROTOTYPES
HGLRC WINAPI wglCreateContextAttribsARB (HDC hDC, HGLRC hShareContext, const int *attribList);
#endif
#endif /* WGL_ARB_create_context */
#ifndef WGL_ARB_create_context_profile
#define WGL_ARB_create_context_profile 1
#define WGL_CONTEXT_PROFILE_MASK_ARB 0x9126
#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001
#define WGL_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002
#define ERROR_INVALID_PROFILE_ARB 0x2096
#endif /* WGL_ARB_create_context_profile */
#ifndef WGL_ARB_create_context_robustness
#define WGL_ARB_create_context_robustness 1
#define WGL_CONTEXT_ROBUST_ACCESS_BIT_ARB 0x00000004
#define WGL_LOSE_CONTEXT_ON_RESET_ARB 0x8252
#define WGL_CONTEXT_RESET_NOTIFICATION_STRATEGY_ARB 0x8256
#define WGL_NO_RESET_NOTIFICATION_ARB 0x8261
#endif /* WGL_ARB_create_context_robustness */
#ifndef WGL_ARB_extensions_string
#define WGL_ARB_extensions_string 1
typedef const char *(WINAPI * PFNWGLGETEXTENSIONSSTRINGARBPROC) (HDC hdc);
#ifdef WGL_WGLEXT_PROTOTYPES
const char *WINAPI wglGetExtensionsStringARB (HDC hdc);
#endif
#endif /* WGL_ARB_extensions_string */
#ifndef WGL_ARB_framebuffer_sRGB
#define WGL_ARB_framebuffer_sRGB 1
#define WGL_FRAMEBUFFER_SRGB_CAPABLE_ARB 0x20A9
#endif /* WGL_ARB_framebuffer_sRGB */
#ifndef WGL_ARB_make_current_read
#define WGL_ARB_make_current_read 1
#define ERROR_INVALID_PIXEL_TYPE_ARB 0x2043
#define ERROR_INCOMPATIBLE_DEVICE_CONTEXTS_ARB 0x2054
typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTARBPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCARBPROC) (void);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglMakeContextCurrentARB (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
HDC WINAPI wglGetCurrentReadDCARB (void);
#endif
#endif /* WGL_ARB_make_current_read */
#ifndef WGL_ARB_multisample
#define WGL_ARB_multisample 1
#define WGL_SAMPLE_BUFFERS_ARB 0x2041
#define WGL_SAMPLES_ARB 0x2042
#endif /* WGL_ARB_multisample */
#ifndef WGL_ARB_pbuffer
#define WGL_ARB_pbuffer 1
DECLARE_HANDLE(HPBUFFERARB);
#define WGL_DRAW_TO_PBUFFER_ARB 0x202D
#define WGL_MAX_PBUFFER_PIXELS_ARB 0x202E
#define WGL_MAX_PBUFFER_WIDTH_ARB 0x202F
#define WGL_MAX_PBUFFER_HEIGHT_ARB 0x2030
#define WGL_PBUFFER_LARGEST_ARB 0x2033
#define WGL_PBUFFER_WIDTH_ARB 0x2034
#define WGL_PBUFFER_HEIGHT_ARB 0x2035
#define WGL_PBUFFER_LOST_ARB 0x2036
typedef HPBUFFERARB (WINAPI * PFNWGLCREATEPBUFFERARBPROC) (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList);
typedef HDC (WINAPI * PFNWGLGETPBUFFERDCARBPROC) (HPBUFFERARB hPbuffer);
typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCARBPROC) (HPBUFFERARB hPbuffer, HDC hDC);
typedef BOOL (WINAPI * PFNWGLDESTROYPBUFFERARBPROC) (HPBUFFERARB hPbuffer);
typedef BOOL (WINAPI * PFNWGLQUERYPBUFFERARBPROC) (HPBUFFERARB hPbuffer, int iAttribute, int *piValue);
#ifdef WGL_WGLEXT_PROTOTYPES
HPBUFFERARB WINAPI wglCreatePbufferARB (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList);
HDC WINAPI wglGetPbufferDCARB (HPBUFFERARB hPbuffer);
int WINAPI wglReleasePbufferDCARB (HPBUFFERARB hPbuffer, HDC hDC);
BOOL WINAPI wglDestroyPbufferARB (HPBUFFERARB hPbuffer);
BOOL WINAPI wglQueryPbufferARB (HPBUFFERARB hPbuffer, int iAttribute, int *piValue);
#endif
#endif /* WGL_ARB_pbuffer */
#ifndef WGL_ARB_pixel_format
#define WGL_ARB_pixel_format 1
#define WGL_NUMBER_PIXEL_FORMATS_ARB 0x2000
#define WGL_DRAW_TO_WINDOW_ARB 0x2001
#define WGL_DRAW_TO_BITMAP_ARB 0x2002
#define WGL_ACCELERATION_ARB 0x2003
#define WGL_NEED_PALETTE_ARB 0x2004
#define WGL_NEED_SYSTEM_PALETTE_ARB 0x2005
#define WGL_SWAP_LAYER_BUFFERS_ARB 0x2006
#define WGL_SWAP_METHOD_ARB 0x2007
#define WGL_NUMBER_OVERLAYS_ARB 0x2008
#define WGL_NUMBER_UNDERLAYS_ARB 0x2009
#define WGL_TRANSPARENT_ARB 0x200A
#define WGL_TRANSPARENT_RED_VALUE_ARB 0x2037
#define WGL_TRANSPARENT_GREEN_VALUE_ARB 0x2038
#define WGL_TRANSPARENT_BLUE_VALUE_ARB 0x2039
#define WGL_TRANSPARENT_ALPHA_VALUE_ARB 0x203A
#define WGL_TRANSPARENT_INDEX_VALUE_ARB 0x203B
#define WGL_SHARE_DEPTH_ARB 0x200C
#define WGL_SHARE_STENCIL_ARB 0x200D
#define WGL_SHARE_ACCUM_ARB 0x200E
#define WGL_SUPPORT_GDI_ARB 0x200F
#define WGL_SUPPORT_OPENGL_ARB 0x2010
#define WGL_DOUBLE_BUFFER_ARB 0x2011
#define WGL_STEREO_ARB 0x2012
#define WGL_PIXEL_TYPE_ARB 0x2013
#define WGL_COLOR_BITS_ARB 0x2014
#define WGL_RED_BITS_ARB 0x2015
#define WGL_RED_SHIFT_ARB 0x2016
#define WGL_GREEN_BITS_ARB 0x2017
#define WGL_GREEN_SHIFT_ARB 0x2018
#define WGL_BLUE_BITS_ARB 0x2019
#define WGL_BLUE_SHIFT_ARB 0x201A
#define WGL_ALPHA_BITS_ARB 0x201B
#define WGL_ALPHA_SHIFT_ARB 0x201C
#define WGL_ACCUM_BITS_ARB 0x201D
#define WGL_ACCUM_RED_BITS_ARB 0x201E
#define WGL_ACCUM_GREEN_BITS_ARB 0x201F
#define WGL_ACCUM_BLUE_BITS_ARB 0x2020
#define WGL_ACCUM_ALPHA_BITS_ARB 0x2021
#define WGL_DEPTH_BITS_ARB 0x2022
#define WGL_STENCIL_BITS_ARB 0x2023
#define WGL_AUX_BUFFERS_ARB 0x2024
#define WGL_NO_ACCELERATION_ARB 0x2025
#define WGL_GENERIC_ACCELERATION_ARB 0x2026
#define WGL_FULL_ACCELERATION_ARB 0x2027
#define WGL_SWAP_EXCHANGE_ARB 0x2028
#define WGL_SWAP_COPY_ARB 0x2029
#define WGL_SWAP_UNDEFINED_ARB 0x202A
#define WGL_TYPE_RGBA_ARB 0x202B
#define WGL_TYPE_COLORINDEX_ARB 0x202C
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, int *piValues);
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVARBPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, FLOAT *pfValues);
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATARBPROC) (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetPixelFormatAttribivARB (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, int *piValues);
BOOL WINAPI wglGetPixelFormatAttribfvARB (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, const int *piAttributes, FLOAT *pfValues);
BOOL WINAPI wglChoosePixelFormatARB (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
#endif
#endif /* WGL_ARB_pixel_format */
#ifndef WGL_ARB_pixel_format_float
#define WGL_ARB_pixel_format_float 1
#define WGL_TYPE_RGBA_FLOAT_ARB 0x21A0
#endif /* WGL_ARB_pixel_format_float */
#ifndef WGL_ARB_render_texture
#define WGL_ARB_render_texture 1
#define WGL_BIND_TO_TEXTURE_RGB_ARB 0x2070
#define WGL_BIND_TO_TEXTURE_RGBA_ARB 0x2071
#define WGL_TEXTURE_FORMAT_ARB 0x2072
#define WGL_TEXTURE_TARGET_ARB 0x2073
#define WGL_MIPMAP_TEXTURE_ARB 0x2074
#define WGL_TEXTURE_RGB_ARB 0x2075
#define WGL_TEXTURE_RGBA_ARB 0x2076
#define WGL_NO_TEXTURE_ARB 0x2077
#define WGL_TEXTURE_CUBE_MAP_ARB 0x2078
#define WGL_TEXTURE_1D_ARB 0x2079
#define WGL_TEXTURE_2D_ARB 0x207A
#define WGL_MIPMAP_LEVEL_ARB 0x207B
#define WGL_CUBE_MAP_FACE_ARB 0x207C
#define WGL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x207D
#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x207E
#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x207F
#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x2080
#define WGL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x2081
#define WGL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x2082
#define WGL_FRONT_LEFT_ARB 0x2083
#define WGL_FRONT_RIGHT_ARB 0x2084
#define WGL_BACK_LEFT_ARB 0x2085
#define WGL_BACK_RIGHT_ARB 0x2086
#define WGL_AUX0_ARB 0x2087
#define WGL_AUX1_ARB 0x2088
#define WGL_AUX2_ARB 0x2089
#define WGL_AUX3_ARB 0x208A
#define WGL_AUX4_ARB 0x208B
#define WGL_AUX5_ARB 0x208C
#define WGL_AUX6_ARB 0x208D
#define WGL_AUX7_ARB 0x208E
#define WGL_AUX8_ARB 0x208F
#define WGL_AUX9_ARB 0x2090
typedef BOOL (WINAPI * PFNWGLBINDTEXIMAGEARBPROC) (HPBUFFERARB hPbuffer, int iBuffer);
typedef BOOL (WINAPI * PFNWGLRELEASETEXIMAGEARBPROC) (HPBUFFERARB hPbuffer, int iBuffer);
typedef BOOL (WINAPI * PFNWGLSETPBUFFERATTRIBARBPROC) (HPBUFFERARB hPbuffer, const int *piAttribList);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglBindTexImageARB (HPBUFFERARB hPbuffer, int iBuffer);
BOOL WINAPI wglReleaseTexImageARB (HPBUFFERARB hPbuffer, int iBuffer);
BOOL WINAPI wglSetPbufferAttribARB (HPBUFFERARB hPbuffer, const int *piAttribList);
#endif
#endif /* WGL_ARB_render_texture */
#ifndef WGL_ARB_robustness_application_isolation
#define WGL_ARB_robustness_application_isolation 1
#define WGL_CONTEXT_RESET_ISOLATION_BIT_ARB 0x00000008
#endif /* WGL_ARB_robustness_application_isolation */
#ifndef WGL_ARB_robustness_share_group_isolation
#define WGL_ARB_robustness_share_group_isolation 1
#endif /* WGL_ARB_robustness_share_group_isolation */
#ifndef WGL_3DFX_multisample
#define WGL_3DFX_multisample 1
#define WGL_SAMPLE_BUFFERS_3DFX 0x2060
#define WGL_SAMPLES_3DFX 0x2061
#endif /* WGL_3DFX_multisample */
#ifndef WGL_3DL_stereo_control
#define WGL_3DL_stereo_control 1
#define WGL_STEREO_EMITTER_ENABLE_3DL 0x2055
#define WGL_STEREO_EMITTER_DISABLE_3DL 0x2056
#define WGL_STEREO_POLARITY_NORMAL_3DL 0x2057
#define WGL_STEREO_POLARITY_INVERT_3DL 0x2058
typedef BOOL (WINAPI * PFNWGLSETSTEREOEMITTERSTATE3DLPROC) (HDC hDC, UINT uState);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglSetStereoEmitterState3DL (HDC hDC, UINT uState);
#endif
#endif /* WGL_3DL_stereo_control */
#ifndef WGL_AMD_gpu_association
#define WGL_AMD_gpu_association 1
#define WGL_GPU_VENDOR_AMD 0x1F00
#define WGL_GPU_RENDERER_STRING_AMD 0x1F01
#define WGL_GPU_OPENGL_VERSION_STRING_AMD 0x1F02
#define WGL_GPU_FASTEST_TARGET_GPUS_AMD 0x21A2
#define WGL_GPU_RAM_AMD 0x21A3
#define WGL_GPU_CLOCK_AMD 0x21A4
#define WGL_GPU_NUM_PIPES_AMD 0x21A5
#define WGL_GPU_NUM_SIMD_AMD 0x21A6
#define WGL_GPU_NUM_RB_AMD 0x21A7
#define WGL_GPU_NUM_SPI_AMD 0x21A8
typedef UINT (WINAPI * PFNWGLGETGPUIDSAMDPROC) (UINT maxCount, UINT *ids);
typedef INT (WINAPI * PFNWGLGETGPUINFOAMDPROC) (UINT id, int property, GLenum dataType, UINT size, void *data);
typedef UINT (WINAPI * PFNWGLGETCONTEXTGPUIDAMDPROC) (HGLRC hglrc);
typedef HGLRC (WINAPI * PFNWGLCREATEASSOCIATEDCONTEXTAMDPROC) (UINT id);
typedef HGLRC (WINAPI * PFNWGLCREATEASSOCIATEDCONTEXTATTRIBSAMDPROC) (UINT id, HGLRC hShareContext, const int *attribList);
typedef BOOL (WINAPI * PFNWGLDELETEASSOCIATEDCONTEXTAMDPROC) (HGLRC hglrc);
typedef BOOL (WINAPI * PFNWGLMAKEASSOCIATEDCONTEXTCURRENTAMDPROC) (HGLRC hglrc);
typedef HGLRC (WINAPI * PFNWGLGETCURRENTASSOCIATEDCONTEXTAMDPROC) (void);
typedef VOID (WINAPI * PFNWGLBLITCONTEXTFRAMEBUFFERAMDPROC) (HGLRC dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
#ifdef WGL_WGLEXT_PROTOTYPES
UINT WINAPI wglGetGPUIDsAMD (UINT maxCount, UINT *ids);
INT WINAPI wglGetGPUInfoAMD (UINT id, int property, GLenum dataType, UINT size, void *data);
UINT WINAPI wglGetContextGPUIDAMD (HGLRC hglrc);
HGLRC WINAPI wglCreateAssociatedContextAMD (UINT id);
HGLRC WINAPI wglCreateAssociatedContextAttribsAMD (UINT id, HGLRC hShareContext, const int *attribList);
BOOL WINAPI wglDeleteAssociatedContextAMD (HGLRC hglrc);
BOOL WINAPI wglMakeAssociatedContextCurrentAMD (HGLRC hglrc);
HGLRC WINAPI wglGetCurrentAssociatedContextAMD (void);
VOID WINAPI wglBlitContextFramebufferAMD (HGLRC dstCtx, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
#endif
#endif /* WGL_AMD_gpu_association */
#ifndef WGL_ATI_pixel_format_float
#define WGL_ATI_pixel_format_float 1
#define WGL_TYPE_RGBA_FLOAT_ATI 0x21A0
#endif /* WGL_ATI_pixel_format_float */
#ifndef WGL_EXT_create_context_es2_profile
#define WGL_EXT_create_context_es2_profile 1
#define WGL_CONTEXT_ES2_PROFILE_BIT_EXT 0x00000004
#endif /* WGL_EXT_create_context_es2_profile */
#ifndef WGL_EXT_create_context_es_profile
#define WGL_EXT_create_context_es_profile 1
#define WGL_CONTEXT_ES_PROFILE_BIT_EXT 0x00000004
#endif /* WGL_EXT_create_context_es_profile */
#ifndef WGL_EXT_depth_float
#define WGL_EXT_depth_float 1
#define WGL_DEPTH_FLOAT_EXT 0x2040
#endif /* WGL_EXT_depth_float */
#ifndef WGL_EXT_display_color_table
#define WGL_EXT_display_color_table 1
typedef GLboolean (WINAPI * PFNWGLCREATEDISPLAYCOLORTABLEEXTPROC) (GLushort id);
typedef GLboolean (WINAPI * PFNWGLLOADDISPLAYCOLORTABLEEXTPROC) (const GLushort *table, GLuint length);
typedef GLboolean (WINAPI * PFNWGLBINDDISPLAYCOLORTABLEEXTPROC) (GLushort id);
typedef VOID (WINAPI * PFNWGLDESTROYDISPLAYCOLORTABLEEXTPROC) (GLushort id);
#ifdef WGL_WGLEXT_PROTOTYPES
GLboolean WINAPI wglCreateDisplayColorTableEXT (GLushort id);
GLboolean WINAPI wglLoadDisplayColorTableEXT (const GLushort *table, GLuint length);
GLboolean WINAPI wglBindDisplayColorTableEXT (GLushort id);
VOID WINAPI wglDestroyDisplayColorTableEXT (GLushort id);
#endif
#endif /* WGL_EXT_display_color_table */
#ifndef WGL_EXT_extensions_string
#define WGL_EXT_extensions_string 1
typedef const char *(WINAPI * PFNWGLGETEXTENSIONSSTRINGEXTPROC) (void);
#ifdef WGL_WGLEXT_PROTOTYPES
const char *WINAPI wglGetExtensionsStringEXT (void);
#endif
#endif /* WGL_EXT_extensions_string */
#ifndef WGL_EXT_framebuffer_sRGB
#define WGL_EXT_framebuffer_sRGB 1
#define WGL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x20A9
#endif /* WGL_EXT_framebuffer_sRGB */
#ifndef WGL_EXT_make_current_read
#define WGL_EXT_make_current_read 1
#define ERROR_INVALID_PIXEL_TYPE_EXT 0x2043
typedef BOOL (WINAPI * PFNWGLMAKECONTEXTCURRENTEXTPROC) (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
typedef HDC (WINAPI * PFNWGLGETCURRENTREADDCEXTPROC) (void);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglMakeContextCurrentEXT (HDC hDrawDC, HDC hReadDC, HGLRC hglrc);
HDC WINAPI wglGetCurrentReadDCEXT (void);
#endif
#endif /* WGL_EXT_make_current_read */
#ifndef WGL_EXT_multisample
#define WGL_EXT_multisample 1
#define WGL_SAMPLE_BUFFERS_EXT 0x2041
#define WGL_SAMPLES_EXT 0x2042
#endif /* WGL_EXT_multisample */
#ifndef WGL_EXT_pbuffer
#define WGL_EXT_pbuffer 1
DECLARE_HANDLE(HPBUFFEREXT);
#define WGL_DRAW_TO_PBUFFER_EXT 0x202D
#define WGL_MAX_PBUFFER_PIXELS_EXT 0x202E
#define WGL_MAX_PBUFFER_WIDTH_EXT 0x202F
#define WGL_MAX_PBUFFER_HEIGHT_EXT 0x2030
#define WGL_OPTIMAL_PBUFFER_WIDTH_EXT 0x2031
#define WGL_OPTIMAL_PBUFFER_HEIGHT_EXT 0x2032
#define WGL_PBUFFER_LARGEST_EXT 0x2033
#define WGL_PBUFFER_WIDTH_EXT 0x2034
#define WGL_PBUFFER_HEIGHT_EXT 0x2035
typedef HPBUFFEREXT (WINAPI * PFNWGLCREATEPBUFFEREXTPROC) (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList);
typedef HDC (WINAPI * PFNWGLGETPBUFFERDCEXTPROC) (HPBUFFEREXT hPbuffer);
typedef int (WINAPI * PFNWGLRELEASEPBUFFERDCEXTPROC) (HPBUFFEREXT hPbuffer, HDC hDC);
typedef BOOL (WINAPI * PFNWGLDESTROYPBUFFEREXTPROC) (HPBUFFEREXT hPbuffer);
typedef BOOL (WINAPI * PFNWGLQUERYPBUFFEREXTPROC) (HPBUFFEREXT hPbuffer, int iAttribute, int *piValue);
#ifdef WGL_WGLEXT_PROTOTYPES
HPBUFFEREXT WINAPI wglCreatePbufferEXT (HDC hDC, int iPixelFormat, int iWidth, int iHeight, const int *piAttribList);
HDC WINAPI wglGetPbufferDCEXT (HPBUFFEREXT hPbuffer);
int WINAPI wglReleasePbufferDCEXT (HPBUFFEREXT hPbuffer, HDC hDC);
BOOL WINAPI wglDestroyPbufferEXT (HPBUFFEREXT hPbuffer);
BOOL WINAPI wglQueryPbufferEXT (HPBUFFEREXT hPbuffer, int iAttribute, int *piValue);
#endif
#endif /* WGL_EXT_pbuffer */
#ifndef WGL_EXT_pixel_format
#define WGL_EXT_pixel_format 1
#define WGL_NUMBER_PIXEL_FORMATS_EXT 0x2000
#define WGL_DRAW_TO_WINDOW_EXT 0x2001
#define WGL_DRAW_TO_BITMAP_EXT 0x2002
#define WGL_ACCELERATION_EXT 0x2003
#define WGL_NEED_PALETTE_EXT 0x2004
#define WGL_NEED_SYSTEM_PALETTE_EXT 0x2005
#define WGL_SWAP_LAYER_BUFFERS_EXT 0x2006
#define WGL_SWAP_METHOD_EXT 0x2007
#define WGL_NUMBER_OVERLAYS_EXT 0x2008
#define WGL_NUMBER_UNDERLAYS_EXT 0x2009
#define WGL_TRANSPARENT_EXT 0x200A
#define WGL_TRANSPARENT_VALUE_EXT 0x200B
#define WGL_SHARE_DEPTH_EXT 0x200C
#define WGL_SHARE_STENCIL_EXT 0x200D
#define WGL_SHARE_ACCUM_EXT 0x200E
#define WGL_SUPPORT_GDI_EXT 0x200F
#define WGL_SUPPORT_OPENGL_EXT 0x2010
#define WGL_DOUBLE_BUFFER_EXT 0x2011
#define WGL_STEREO_EXT 0x2012
#define WGL_PIXEL_TYPE_EXT 0x2013
#define WGL_COLOR_BITS_EXT 0x2014
#define WGL_RED_BITS_EXT 0x2015
#define WGL_RED_SHIFT_EXT 0x2016
#define WGL_GREEN_BITS_EXT 0x2017
#define WGL_GREEN_SHIFT_EXT 0x2018
#define WGL_BLUE_BITS_EXT 0x2019
#define WGL_BLUE_SHIFT_EXT 0x201A
#define WGL_ALPHA_BITS_EXT 0x201B
#define WGL_ALPHA_SHIFT_EXT 0x201C
#define WGL_ACCUM_BITS_EXT 0x201D
#define WGL_ACCUM_RED_BITS_EXT 0x201E
#define WGL_ACCUM_GREEN_BITS_EXT 0x201F
#define WGL_ACCUM_BLUE_BITS_EXT 0x2020
#define WGL_ACCUM_ALPHA_BITS_EXT 0x2021
#define WGL_DEPTH_BITS_EXT 0x2022
#define WGL_STENCIL_BITS_EXT 0x2023
#define WGL_AUX_BUFFERS_EXT 0x2024
#define WGL_NO_ACCELERATION_EXT 0x2025
#define WGL_GENERIC_ACCELERATION_EXT 0x2026
#define WGL_FULL_ACCELERATION_EXT 0x2027
#define WGL_SWAP_EXCHANGE_EXT 0x2028
#define WGL_SWAP_COPY_EXT 0x2029
#define WGL_SWAP_UNDEFINED_EXT 0x202A
#define WGL_TYPE_RGBA_EXT 0x202B
#define WGL_TYPE_COLORINDEX_EXT 0x202C
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBIVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, int *piValues);
typedef BOOL (WINAPI * PFNWGLGETPIXELFORMATATTRIBFVEXTPROC) (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, FLOAT *pfValues);
typedef BOOL (WINAPI * PFNWGLCHOOSEPIXELFORMATEXTPROC) (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetPixelFormatAttribivEXT (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, int *piValues);
BOOL WINAPI wglGetPixelFormatAttribfvEXT (HDC hdc, int iPixelFormat, int iLayerPlane, UINT nAttributes, int *piAttributes, FLOAT *pfValues);
BOOL WINAPI wglChoosePixelFormatEXT (HDC hdc, const int *piAttribIList, const FLOAT *pfAttribFList, UINT nMaxFormats, int *piFormats, UINT *nNumFormats);
#endif
#endif /* WGL_EXT_pixel_format */
#ifndef WGL_EXT_pixel_format_packed_float
#define WGL_EXT_pixel_format_packed_float 1
#define WGL_TYPE_RGBA_UNSIGNED_FLOAT_EXT 0x20A8
#endif /* WGL_EXT_pixel_format_packed_float */
#ifndef WGL_EXT_swap_control
#define WGL_EXT_swap_control 1
typedef BOOL (WINAPI * PFNWGLSWAPINTERVALEXTPROC) (int interval);
typedef int (WINAPI * PFNWGLGETSWAPINTERVALEXTPROC) (void);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglSwapIntervalEXT (int interval);
int WINAPI wglGetSwapIntervalEXT (void);
#endif
#endif /* WGL_EXT_swap_control */
#ifndef WGL_EXT_swap_control_tear
#define WGL_EXT_swap_control_tear 1
#endif /* WGL_EXT_swap_control_tear */
#ifndef WGL_I3D_digital_video_control
#define WGL_I3D_digital_video_control 1
#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_FRAMEBUFFER_I3D 0x2050
#define WGL_DIGITAL_VIDEO_CURSOR_ALPHA_VALUE_I3D 0x2051
#define WGL_DIGITAL_VIDEO_CURSOR_INCLUDED_I3D 0x2052
#define WGL_DIGITAL_VIDEO_GAMMA_CORRECTED_I3D 0x2053
typedef BOOL (WINAPI * PFNWGLGETDIGITALVIDEOPARAMETERSI3DPROC) (HDC hDC, int iAttribute, int *piValue);
typedef BOOL (WINAPI * PFNWGLSETDIGITALVIDEOPARAMETERSI3DPROC) (HDC hDC, int iAttribute, const int *piValue);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetDigitalVideoParametersI3D (HDC hDC, int iAttribute, int *piValue);
BOOL WINAPI wglSetDigitalVideoParametersI3D (HDC hDC, int iAttribute, const int *piValue);
#endif
#endif /* WGL_I3D_digital_video_control */
#ifndef WGL_I3D_gamma
#define WGL_I3D_gamma 1
#define WGL_GAMMA_TABLE_SIZE_I3D 0x204E
#define WGL_GAMMA_EXCLUDE_DESKTOP_I3D 0x204F
typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, int *piValue);
typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEPARAMETERSI3DPROC) (HDC hDC, int iAttribute, const int *piValue);
typedef BOOL (WINAPI * PFNWGLGETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, USHORT *puRed, USHORT *puGreen, USHORT *puBlue);
typedef BOOL (WINAPI * PFNWGLSETGAMMATABLEI3DPROC) (HDC hDC, int iEntries, const USHORT *puRed, const USHORT *puGreen, const USHORT *puBlue);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetGammaTableParametersI3D (HDC hDC, int iAttribute, int *piValue);
BOOL WINAPI wglSetGammaTableParametersI3D (HDC hDC, int iAttribute, const int *piValue);
BOOL WINAPI wglGetGammaTableI3D (HDC hDC, int iEntries, USHORT *puRed, USHORT *puGreen, USHORT *puBlue);
BOOL WINAPI wglSetGammaTableI3D (HDC hDC, int iEntries, const USHORT *puRed, const USHORT *puGreen, const USHORT *puBlue);
#endif
#endif /* WGL_I3D_gamma */
#ifndef WGL_I3D_genlock
#define WGL_I3D_genlock 1
#define WGL_GENLOCK_SOURCE_MULTIVIEW_I3D 0x2044
#define WGL_GENLOCK_SOURCE_EXTERNAL_SYNC_I3D 0x2045
#define WGL_GENLOCK_SOURCE_EXTERNAL_FIELD_I3D 0x2046
#define WGL_GENLOCK_SOURCE_EXTERNAL_TTL_I3D 0x2047
#define WGL_GENLOCK_SOURCE_DIGITAL_SYNC_I3D 0x2048
#define WGL_GENLOCK_SOURCE_DIGITAL_FIELD_I3D 0x2049
#define WGL_GENLOCK_SOURCE_EDGE_FALLING_I3D 0x204A
#define WGL_GENLOCK_SOURCE_EDGE_RISING_I3D 0x204B
#define WGL_GENLOCK_SOURCE_EDGE_BOTH_I3D 0x204C
typedef BOOL (WINAPI * PFNWGLENABLEGENLOCKI3DPROC) (HDC hDC);
typedef BOOL (WINAPI * PFNWGLDISABLEGENLOCKI3DPROC) (HDC hDC);
typedef BOOL (WINAPI * PFNWGLISENABLEDGENLOCKI3DPROC) (HDC hDC, BOOL *pFlag);
typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEI3DPROC) (HDC hDC, UINT uSource);
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEI3DPROC) (HDC hDC, UINT *uSource);
typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEEDGEI3DPROC) (HDC hDC, UINT uEdge);
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEEDGEI3DPROC) (HDC hDC, UINT *uEdge);
typedef BOOL (WINAPI * PFNWGLGENLOCKSAMPLERATEI3DPROC) (HDC hDC, UINT uRate);
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSAMPLERATEI3DPROC) (HDC hDC, UINT *uRate);
typedef BOOL (WINAPI * PFNWGLGENLOCKSOURCEDELAYI3DPROC) (HDC hDC, UINT uDelay);
typedef BOOL (WINAPI * PFNWGLGETGENLOCKSOURCEDELAYI3DPROC) (HDC hDC, UINT *uDelay);
typedef BOOL (WINAPI * PFNWGLQUERYGENLOCKMAXSOURCEDELAYI3DPROC) (HDC hDC, UINT *uMaxLineDelay, UINT *uMaxPixelDelay);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglEnableGenlockI3D (HDC hDC);
BOOL WINAPI wglDisableGenlockI3D (HDC hDC);
BOOL WINAPI wglIsEnabledGenlockI3D (HDC hDC, BOOL *pFlag);
BOOL WINAPI wglGenlockSourceI3D (HDC hDC, UINT uSource);
BOOL WINAPI wglGetGenlockSourceI3D (HDC hDC, UINT *uSource);
BOOL WINAPI wglGenlockSourceEdgeI3D (HDC hDC, UINT uEdge);
BOOL WINAPI wglGetGenlockSourceEdgeI3D (HDC hDC, UINT *uEdge);
BOOL WINAPI wglGenlockSampleRateI3D (HDC hDC, UINT uRate);
BOOL WINAPI wglGetGenlockSampleRateI3D (HDC hDC, UINT *uRate);
BOOL WINAPI wglGenlockSourceDelayI3D (HDC hDC, UINT uDelay);
BOOL WINAPI wglGetGenlockSourceDelayI3D (HDC hDC, UINT *uDelay);
BOOL WINAPI wglQueryGenlockMaxSourceDelayI3D (HDC hDC, UINT *uMaxLineDelay, UINT *uMaxPixelDelay);
#endif
#endif /* WGL_I3D_genlock */
#ifndef WGL_I3D_image_buffer
#define WGL_I3D_image_buffer 1
#define WGL_IMAGE_BUFFER_MIN_ACCESS_I3D 0x00000001
#define WGL_IMAGE_BUFFER_LOCK_I3D 0x00000002
typedef LPVOID (WINAPI * PFNWGLCREATEIMAGEBUFFERI3DPROC) (HDC hDC, DWORD dwSize, UINT uFlags);
typedef BOOL (WINAPI * PFNWGLDESTROYIMAGEBUFFERI3DPROC) (HDC hDC, LPVOID pAddress);
typedef BOOL (WINAPI * PFNWGLASSOCIATEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const HANDLE *pEvent, const LPVOID *pAddress, const DWORD *pSize, UINT count);
typedef BOOL (WINAPI * PFNWGLRELEASEIMAGEBUFFEREVENTSI3DPROC) (HDC hDC, const LPVOID *pAddress, UINT count);
#ifdef WGL_WGLEXT_PROTOTYPES
LPVOID WINAPI wglCreateImageBufferI3D (HDC hDC, DWORD dwSize, UINT uFlags);
BOOL WINAPI wglDestroyImageBufferI3D (HDC hDC, LPVOID pAddress);
BOOL WINAPI wglAssociateImageBufferEventsI3D (HDC hDC, const HANDLE *pEvent, const LPVOID *pAddress, const DWORD *pSize, UINT count);
BOOL WINAPI wglReleaseImageBufferEventsI3D (HDC hDC, const LPVOID *pAddress, UINT count);
#endif
#endif /* WGL_I3D_image_buffer */
#ifndef WGL_I3D_swap_frame_lock
#define WGL_I3D_swap_frame_lock 1
typedef BOOL (WINAPI * PFNWGLENABLEFRAMELOCKI3DPROC) (void);
typedef BOOL (WINAPI * PFNWGLDISABLEFRAMELOCKI3DPROC) (void);
typedef BOOL (WINAPI * PFNWGLISENABLEDFRAMELOCKI3DPROC) (BOOL *pFlag);
typedef BOOL (WINAPI * PFNWGLQUERYFRAMELOCKMASTERI3DPROC) (BOOL *pFlag);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglEnableFrameLockI3D (void);
BOOL WINAPI wglDisableFrameLockI3D (void);
BOOL WINAPI wglIsEnabledFrameLockI3D (BOOL *pFlag);
BOOL WINAPI wglQueryFrameLockMasterI3D (BOOL *pFlag);
#endif
#endif /* WGL_I3D_swap_frame_lock */
#ifndef WGL_I3D_swap_frame_usage
#define WGL_I3D_swap_frame_usage 1
typedef BOOL (WINAPI * PFNWGLGETFRAMEUSAGEI3DPROC) (float *pUsage);
typedef BOOL (WINAPI * PFNWGLBEGINFRAMETRACKINGI3DPROC) (void);
typedef BOOL (WINAPI * PFNWGLENDFRAMETRACKINGI3DPROC) (void);
typedef BOOL (WINAPI * PFNWGLQUERYFRAMETRACKINGI3DPROC) (DWORD *pFrameCount, DWORD *pMissedFrames, float *pLastMissedUsage);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetFrameUsageI3D (float *pUsage);
BOOL WINAPI wglBeginFrameTrackingI3D (void);
BOOL WINAPI wglEndFrameTrackingI3D (void);
BOOL WINAPI wglQueryFrameTrackingI3D (DWORD *pFrameCount, DWORD *pMissedFrames, float *pLastMissedUsage);
#endif
#endif /* WGL_I3D_swap_frame_usage */
#ifndef WGL_NV_DX_interop
#define WGL_NV_DX_interop 1
#define WGL_ACCESS_READ_ONLY_NV 0x00000000
#define WGL_ACCESS_READ_WRITE_NV 0x00000001
#define WGL_ACCESS_WRITE_DISCARD_NV 0x00000002
typedef BOOL (WINAPI * PFNWGLDXSETRESOURCESHAREHANDLENVPROC) (void *dxObject, HANDLE shareHandle);
typedef HANDLE (WINAPI * PFNWGLDXOPENDEVICENVPROC) (void *dxDevice);
typedef BOOL (WINAPI * PFNWGLDXCLOSEDEVICENVPROC) (HANDLE hDevice);
typedef HANDLE (WINAPI * PFNWGLDXREGISTEROBJECTNVPROC) (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access);
typedef BOOL (WINAPI * PFNWGLDXUNREGISTEROBJECTNVPROC) (HANDLE hDevice, HANDLE hObject);
typedef BOOL (WINAPI * PFNWGLDXOBJECTACCESSNVPROC) (HANDLE hObject, GLenum access);
typedef BOOL (WINAPI * PFNWGLDXLOCKOBJECTSNVPROC) (HANDLE hDevice, GLint count, HANDLE *hObjects);
typedef BOOL (WINAPI * PFNWGLDXUNLOCKOBJECTSNVPROC) (HANDLE hDevice, GLint count, HANDLE *hObjects);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglDXSetResourceShareHandleNV (void *dxObject, HANDLE shareHandle);
HANDLE WINAPI wglDXOpenDeviceNV (void *dxDevice);
BOOL WINAPI wglDXCloseDeviceNV (HANDLE hDevice);
HANDLE WINAPI wglDXRegisterObjectNV (HANDLE hDevice, void *dxObject, GLuint name, GLenum type, GLenum access);
BOOL WINAPI wglDXUnregisterObjectNV (HANDLE hDevice, HANDLE hObject);
BOOL WINAPI wglDXObjectAccessNV (HANDLE hObject, GLenum access);
BOOL WINAPI wglDXLockObjectsNV (HANDLE hDevice, GLint count, HANDLE *hObjects);
BOOL WINAPI wglDXUnlockObjectsNV (HANDLE hDevice, GLint count, HANDLE *hObjects);
#endif
#endif /* WGL_NV_DX_interop */
#ifndef WGL_NV_DX_interop2
#define WGL_NV_DX_interop2 1
#endif /* WGL_NV_DX_interop2 */
#ifndef WGL_NV_copy_image
#define WGL_NV_copy_image 1
typedef BOOL (WINAPI * PFNWGLCOPYIMAGESUBDATANVPROC) (HGLRC hSrcRC, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, HGLRC hDstRC, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglCopyImageSubDataNV (HGLRC hSrcRC, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, HGLRC hDstRC, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei width, GLsizei height, GLsizei depth);
#endif
#endif /* WGL_NV_copy_image */
#ifndef WGL_NV_delay_before_swap
#define WGL_NV_delay_before_swap 1
typedef BOOL (WINAPI * PFNWGLDELAYBEFORESWAPNVPROC) (HDC hDC, GLfloat seconds);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglDelayBeforeSwapNV (HDC hDC, GLfloat seconds);
#endif
#endif /* WGL_NV_delay_before_swap */
#ifndef WGL_NV_float_buffer
#define WGL_NV_float_buffer 1
#define WGL_FLOAT_COMPONENTS_NV 0x20B0
#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_R_NV 0x20B1
#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RG_NV 0x20B2
#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGB_NV 0x20B3
#define WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGBA_NV 0x20B4
#define WGL_TEXTURE_FLOAT_R_NV 0x20B5
#define WGL_TEXTURE_FLOAT_RG_NV 0x20B6
#define WGL_TEXTURE_FLOAT_RGB_NV 0x20B7
#define WGL_TEXTURE_FLOAT_RGBA_NV 0x20B8
#endif /* WGL_NV_float_buffer */
#ifndef WGL_NV_gpu_affinity
#define WGL_NV_gpu_affinity 1
DECLARE_HANDLE(HGPUNV);
struct _GPU_DEVICE {
DWORD cb;
CHAR DeviceName[32];
CHAR DeviceString[128];
DWORD Flags;
RECT rcVirtualScreen;
};
typedef struct _GPU_DEVICE *PGPU_DEVICE;
#define ERROR_INCOMPATIBLE_AFFINITY_MASKS_NV 0x20D0
#define ERROR_MISSING_AFFINITY_MASK_NV 0x20D1
typedef BOOL (WINAPI * PFNWGLENUMGPUSNVPROC) (UINT iGpuIndex, HGPUNV *phGpu);
typedef BOOL (WINAPI * PFNWGLENUMGPUDEVICESNVPROC) (HGPUNV hGpu, UINT iDeviceIndex, PGPU_DEVICE lpGpuDevice);
typedef HDC (WINAPI * PFNWGLCREATEAFFINITYDCNVPROC) (const HGPUNV *phGpuList);
typedef BOOL (WINAPI * PFNWGLENUMGPUSFROMAFFINITYDCNVPROC) (HDC hAffinityDC, UINT iGpuIndex, HGPUNV *hGpu);
typedef BOOL (WINAPI * PFNWGLDELETEDCNVPROC) (HDC hdc);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglEnumGpusNV (UINT iGpuIndex, HGPUNV *phGpu);
BOOL WINAPI wglEnumGpuDevicesNV (HGPUNV hGpu, UINT iDeviceIndex, PGPU_DEVICE lpGpuDevice);
HDC WINAPI wglCreateAffinityDCNV (const HGPUNV *phGpuList);
BOOL WINAPI wglEnumGpusFromAffinityDCNV (HDC hAffinityDC, UINT iGpuIndex, HGPUNV *hGpu);
BOOL WINAPI wglDeleteDCNV (HDC hdc);
#endif
#endif /* WGL_NV_gpu_affinity */
#ifndef WGL_NV_multisample_coverage
#define WGL_NV_multisample_coverage 1
#define WGL_COVERAGE_SAMPLES_NV 0x2042
#define WGL_COLOR_SAMPLES_NV 0x20B9
#endif /* WGL_NV_multisample_coverage */
#ifndef WGL_NV_present_video
#define WGL_NV_present_video 1
DECLARE_HANDLE(HVIDEOOUTPUTDEVICENV);
#define WGL_NUM_VIDEO_SLOTS_NV 0x20F0
typedef int (WINAPI * PFNWGLENUMERATEVIDEODEVICESNVPROC) (HDC hDC, HVIDEOOUTPUTDEVICENV *phDeviceList);
typedef BOOL (WINAPI * PFNWGLBINDVIDEODEVICENVPROC) (HDC hDC, unsigned int uVideoSlot, HVIDEOOUTPUTDEVICENV hVideoDevice, const int *piAttribList);
typedef BOOL (WINAPI * PFNWGLQUERYCURRENTCONTEXTNVPROC) (int iAttribute, int *piValue);
#ifdef WGL_WGLEXT_PROTOTYPES
int WINAPI wglEnumerateVideoDevicesNV (HDC hDC, HVIDEOOUTPUTDEVICENV *phDeviceList);
BOOL WINAPI wglBindVideoDeviceNV (HDC hDC, unsigned int uVideoSlot, HVIDEOOUTPUTDEVICENV hVideoDevice, const int *piAttribList);
BOOL WINAPI wglQueryCurrentContextNV (int iAttribute, int *piValue);
#endif
#endif /* WGL_NV_present_video */
#ifndef WGL_NV_render_depth_texture
#define WGL_NV_render_depth_texture 1
#define WGL_BIND_TO_TEXTURE_DEPTH_NV 0x20A3
#define WGL_BIND_TO_TEXTURE_RECTANGLE_DEPTH_NV 0x20A4
#define WGL_DEPTH_TEXTURE_FORMAT_NV 0x20A5
#define WGL_TEXTURE_DEPTH_COMPONENT_NV 0x20A6
#define WGL_DEPTH_COMPONENT_NV 0x20A7
#endif /* WGL_NV_render_depth_texture */
#ifndef WGL_NV_render_texture_rectangle
#define WGL_NV_render_texture_rectangle 1
#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGB_NV 0x20A0
#define WGL_BIND_TO_TEXTURE_RECTANGLE_RGBA_NV 0x20A1
#define WGL_TEXTURE_RECTANGLE_NV 0x20A2
#endif /* WGL_NV_render_texture_rectangle */
#ifndef WGL_NV_swap_group
#define WGL_NV_swap_group 1
typedef BOOL (WINAPI * PFNWGLJOINSWAPGROUPNVPROC) (HDC hDC, GLuint group);
typedef BOOL (WINAPI * PFNWGLBINDSWAPBARRIERNVPROC) (GLuint group, GLuint barrier);
typedef BOOL (WINAPI * PFNWGLQUERYSWAPGROUPNVPROC) (HDC hDC, GLuint *group, GLuint *barrier);
typedef BOOL (WINAPI * PFNWGLQUERYMAXSWAPGROUPSNVPROC) (HDC hDC, GLuint *maxGroups, GLuint *maxBarriers);
typedef BOOL (WINAPI * PFNWGLQUERYFRAMECOUNTNVPROC) (HDC hDC, GLuint *count);
typedef BOOL (WINAPI * PFNWGLRESETFRAMECOUNTNVPROC) (HDC hDC);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglJoinSwapGroupNV (HDC hDC, GLuint group);
BOOL WINAPI wglBindSwapBarrierNV (GLuint group, GLuint barrier);
BOOL WINAPI wglQuerySwapGroupNV (HDC hDC, GLuint *group, GLuint *barrier);
BOOL WINAPI wglQueryMaxSwapGroupsNV (HDC hDC, GLuint *maxGroups, GLuint *maxBarriers);
BOOL WINAPI wglQueryFrameCountNV (HDC hDC, GLuint *count);
BOOL WINAPI wglResetFrameCountNV (HDC hDC);
#endif
#endif /* WGL_NV_swap_group */
#ifndef WGL_NV_vertex_array_range
#define WGL_NV_vertex_array_range 1
typedef void *(WINAPI * PFNWGLALLOCATEMEMORYNVPROC) (GLsizei size, GLfloat readfreq, GLfloat writefreq, GLfloat priority);
typedef void (WINAPI * PFNWGLFREEMEMORYNVPROC) (void *pointer);
#ifdef WGL_WGLEXT_PROTOTYPES
void *WINAPI wglAllocateMemoryNV (GLsizei size, GLfloat readfreq, GLfloat writefreq, GLfloat priority);
void WINAPI wglFreeMemoryNV (void *pointer);
#endif
#endif /* WGL_NV_vertex_array_range */
#ifndef WGL_NV_video_capture
#define WGL_NV_video_capture 1
DECLARE_HANDLE(HVIDEOINPUTDEVICENV);
#define WGL_UNIQUE_ID_NV 0x20CE
#define WGL_NUM_VIDEO_CAPTURE_SLOTS_NV 0x20CF
typedef BOOL (WINAPI * PFNWGLBINDVIDEOCAPTUREDEVICENVPROC) (UINT uVideoSlot, HVIDEOINPUTDEVICENV hDevice);
typedef UINT (WINAPI * PFNWGLENUMERATEVIDEOCAPTUREDEVICESNVPROC) (HDC hDc, HVIDEOINPUTDEVICENV *phDeviceList);
typedef BOOL (WINAPI * PFNWGLLOCKVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice);
typedef BOOL (WINAPI * PFNWGLQUERYVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice, int iAttribute, int *piValue);
typedef BOOL (WINAPI * PFNWGLRELEASEVIDEOCAPTUREDEVICENVPROC) (HDC hDc, HVIDEOINPUTDEVICENV hDevice);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglBindVideoCaptureDeviceNV (UINT uVideoSlot, HVIDEOINPUTDEVICENV hDevice);
UINT WINAPI wglEnumerateVideoCaptureDevicesNV (HDC hDc, HVIDEOINPUTDEVICENV *phDeviceList);
BOOL WINAPI wglLockVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice);
BOOL WINAPI wglQueryVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice, int iAttribute, int *piValue);
BOOL WINAPI wglReleaseVideoCaptureDeviceNV (HDC hDc, HVIDEOINPUTDEVICENV hDevice);
#endif
#endif /* WGL_NV_video_capture */
#ifndef WGL_NV_video_output
#define WGL_NV_video_output 1
DECLARE_HANDLE(HPVIDEODEV);
#define WGL_BIND_TO_VIDEO_RGB_NV 0x20C0
#define WGL_BIND_TO_VIDEO_RGBA_NV 0x20C1
#define WGL_BIND_TO_VIDEO_RGB_AND_DEPTH_NV 0x20C2
#define WGL_VIDEO_OUT_COLOR_NV 0x20C3
#define WGL_VIDEO_OUT_ALPHA_NV 0x20C4
#define WGL_VIDEO_OUT_DEPTH_NV 0x20C5
#define WGL_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6
#define WGL_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7
#define WGL_VIDEO_OUT_FRAME 0x20C8
#define WGL_VIDEO_OUT_FIELD_1 0x20C9
#define WGL_VIDEO_OUT_FIELD_2 0x20CA
#define WGL_VIDEO_OUT_STACKED_FIELDS_1_2 0x20CB
#define WGL_VIDEO_OUT_STACKED_FIELDS_2_1 0x20CC
typedef BOOL (WINAPI * PFNWGLGETVIDEODEVICENVPROC) (HDC hDC, int numDevices, HPVIDEODEV *hVideoDevice);
typedef BOOL (WINAPI * PFNWGLRELEASEVIDEODEVICENVPROC) (HPVIDEODEV hVideoDevice);
typedef BOOL (WINAPI * PFNWGLBINDVIDEOIMAGENVPROC) (HPVIDEODEV hVideoDevice, HPBUFFERARB hPbuffer, int iVideoBuffer);
typedef BOOL (WINAPI * PFNWGLRELEASEVIDEOIMAGENVPROC) (HPBUFFERARB hPbuffer, int iVideoBuffer);
typedef BOOL (WINAPI * PFNWGLSENDPBUFFERTOVIDEONVPROC) (HPBUFFERARB hPbuffer, int iBufferType, unsigned long *pulCounterPbuffer, BOOL bBlock);
typedef BOOL (WINAPI * PFNWGLGETVIDEOINFONVPROC) (HPVIDEODEV hpVideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetVideoDeviceNV (HDC hDC, int numDevices, HPVIDEODEV *hVideoDevice);
BOOL WINAPI wglReleaseVideoDeviceNV (HPVIDEODEV hVideoDevice);
BOOL WINAPI wglBindVideoImageNV (HPVIDEODEV hVideoDevice, HPBUFFERARB hPbuffer, int iVideoBuffer);
BOOL WINAPI wglReleaseVideoImageNV (HPBUFFERARB hPbuffer, int iVideoBuffer);
BOOL WINAPI wglSendPbufferToVideoNV (HPBUFFERARB hPbuffer, int iBufferType, unsigned long *pulCounterPbuffer, BOOL bBlock);
BOOL WINAPI wglGetVideoInfoNV (HPVIDEODEV hpVideoDevice, unsigned long *pulCounterOutputPbuffer, unsigned long *pulCounterOutputVideo);
#endif
#endif /* WGL_NV_video_output */
#ifndef WGL_OML_sync_control
#define WGL_OML_sync_control 1
typedef BOOL (WINAPI * PFNWGLGETSYNCVALUESOMLPROC) (HDC hdc, INT64 *ust, INT64 *msc, INT64 *sbc);
typedef BOOL (WINAPI * PFNWGLGETMSCRATEOMLPROC) (HDC hdc, INT32 *numerator, INT32 *denominator);
typedef INT64 (WINAPI * PFNWGLSWAPBUFFERSMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder);
typedef INT64 (WINAPI * PFNWGLSWAPLAYERBUFFERSMSCOMLPROC) (HDC hdc, int fuPlanes, INT64 target_msc, INT64 divisor, INT64 remainder);
typedef BOOL (WINAPI * PFNWGLWAITFORMSCOMLPROC) (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64 *ust, INT64 *msc, INT64 *sbc);
typedef BOOL (WINAPI * PFNWGLWAITFORSBCOMLPROC) (HDC hdc, INT64 target_sbc, INT64 *ust, INT64 *msc, INT64 *sbc);
#ifdef WGL_WGLEXT_PROTOTYPES
BOOL WINAPI wglGetSyncValuesOML (HDC hdc, INT64 *ust, INT64 *msc, INT64 *sbc);
BOOL WINAPI wglGetMscRateOML (HDC hdc, INT32 *numerator, INT32 *denominator);
INT64 WINAPI wglSwapBuffersMscOML (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder);
INT64 WINAPI wglSwapLayerBuffersMscOML (HDC hdc, int fuPlanes, INT64 target_msc, INT64 divisor, INT64 remainder);
BOOL WINAPI wglWaitForMscOML (HDC hdc, INT64 target_msc, INT64 divisor, INT64 remainder, INT64 *ust, INT64 *msc, INT64 *sbc);
BOOL WINAPI wglWaitForSbcOML (HDC hdc, INT64 target_sbc, INT64 *ust, INT64 *msc, INT64 *sbc);
#endif
#endif /* WGL_OML_sync_control */
#ifdef __cplusplus
}
#endif
#endif

55
3rdparty/baseclasses/CMakeLists.txt vendored Normal file
View File

@@ -0,0 +1,55 @@
add_library(baseclasses
amextra.cpp
amfilter.cpp
amvideo.cpp
combase.cpp
ctlutil.cpp
ddmm.cpp
mtype.cpp
outputq.cpp
pstream.cpp
pullpin.cpp
refclock.cpp
renbase.cpp
schedule.cpp
seekpt.cpp
source.cpp
strmctl.cpp
sysclock.cpp
transfrm.cpp
transip.cpp
vtrans.cpp
wxdebug.cpp
wxlist.cpp
wxutil.cpp
amextra.h
amfilter.h
cache.h
combase.h
ctlutil.h
ddmm.h
fourcc.h
measure.h
msgthrd.h
mtype.h
outputq.h
pstream.h
pullpin.h
refclock.h
reftime.h
renbase.h
schedule.h
seekpt.h
source.h
streams.h
strmctl.h
sysclock.h
transfrm.h
transip.h
vtrans.h
wxdebug.h
wxlist.h
wxutil.h
)
target_include_directories(baseclasses PUBLIC .)
target_precompile_headers(baseclasses PRIVATE streams.h)

View File

@@ -1,23 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<Import Project="$(SolutionDir)common\vsprops\BaseProjectConfig.props" />
<Import Project="$(SolutionDir)common\vsprops\WinSDK.props" />
<PropertyGroup Label="Globals">
<ProjectGuid>{27F17499-A372-4408-8AFA-4F9F4584FBD3}</ProjectGuid>
</PropertyGroup>

View File

@@ -7,8 +7,7 @@
//------------------------------------------------------------------------------
#ifndef __WXDEBUG__
#define __WXDEBUG__
#pragma once
// This library provides fairly straight forward debugging functionality, this
// is split into two main sections. The first is assertion handling, there are
@@ -352,8 +351,4 @@ public:
#define AMTRACE(_x_)
#define AMTRACEFN()
#endif
#endif // __WXDEBUG__
#endif

21
3rdparty/cpuinfo/.gitignore vendored Normal file
View File

@@ -0,0 +1,21 @@
# Ninja files
build.ninja
# Build objects and artifacts
deps/
build/
bin/
lib/
libs/
obj/
*.pyc
*.pyo
# System files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

223
3rdparty/cpuinfo/CMakeLists.txt vendored Normal file
View File

@@ -0,0 +1,223 @@
CMAKE_MINIMUM_REQUIRED(VERSION 3.5 FATAL_ERROR)
# ---[ Setup project
PROJECT(
cpuinfo
LANGUAGES C CXX
)
# ---[ Options.
SET(CPUINFO_LIBRARY_TYPE "default" CACHE STRING "Type of cpuinfo library (shared, static, or default) to build")
SET_PROPERTY(CACHE CPUINFO_LIBRARY_TYPE PROPERTY STRINGS default static shared)
SET(CPUINFO_RUNTIME_TYPE "default" CACHE STRING "Type of runtime library (shared, static, or default) to use")
SET_PROPERTY(CACHE CPUINFO_RUNTIME_TYPE PROPERTY STRINGS default static shared)
SET(CPUINFO_LOG_LEVEL "default" CACHE STRING "Minimum logging level (info with lower severity will be ignored)")
SET_PROPERTY(CACHE CPUINFO_LOG_LEVEL PROPERTY STRINGS default debug info warning error fatal none)
MACRO(CPUINFO_TARGET_ENABLE_C99 target)
SET_TARGET_PROPERTIES(${target} PROPERTIES
C_STANDARD 99
C_EXTENSIONS NO)
ENDMACRO()
MACRO(CPUINFO_TARGET_ENABLE_CXX11 target)
SET_TARGET_PROPERTIES(${target} PROPERTIES
CXX_STANDARD 11
CXX_EXTENSIONS NO)
ENDMACRO()
MACRO(CPUINFO_TARGET_RUNTIME_LIBRARY target)
IF(MSVC AND NOT CPUINFO_RUNTIME_TYPE STREQUAL "default")
IF(CPUINFO_RUNTIME_TYPE STREQUAL "shared")
TARGET_COMPILE_OPTIONS(${target} PRIVATE
"/MD$<$<CONFIG:Debug>:d>")
ELSEIF(CPUINFO_RUNTIME_TYPE STREQUAL "static")
TARGET_COMPILE_OPTIONS(${target} PRIVATE
"/MT$<$<CONFIG:Debug>:d>")
ENDIF()
ENDIF()
ENDMACRO()
# -- [ Determine target processor
SET(CPUINFO_TARGET_PROCESSOR "${CMAKE_SYSTEM_PROCESSOR}")
IF(CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND CMAKE_OSX_ARCHITECTURES MATCHES "^(x86_64|arm64)$")
SET(CPUINFO_TARGET_PROCESSOR "${CMAKE_OSX_ARCHITECTURES}")
ENDIF()
# ---[ Build flags
SET(CPUINFO_SUPPORTED_PLATFORM TRUE)
IF(NOT CMAKE_SYSTEM_PROCESSOR)
IF(NOT IOS)
MESSAGE(WARNING
"Target processor architecture is not specified. "
"cpuinfo will compile, but cpuinfo_initialize() will always fail.")
SET(CPUINFO_SUPPORTED_PLATFORM FALSE)
ENDIF()
ELSEIF(NOT CPUINFO_TARGET_PROCESSOR MATCHES "^(i[3-6]86|AMD64|x86(_64)?|armv[5-8].*|aarch64|arm64)$")
MESSAGE(WARNING
"Target processor architecture \"${CPUINFO_TARGET_PROCESSOR}\" is not supported in cpuinfo. "
"cpuinfo will compile, but cpuinfo_initialize() will always fail.")
SET(CPUINFO_SUPPORTED_PLATFORM FALSE)
ENDIF()
IF(NOT CMAKE_SYSTEM_NAME)
MESSAGE(WARNING
"Target operating system is not specified. "
"cpuinfo will compile, but cpuinfo_initialize() will always fail.")
SET(CPUINFO_SUPPORTED_PLATFORM FALSE)
ELSEIF(NOT CMAKE_SYSTEM_NAME MATCHES "^(Windows|CYGWIN|MSYS|Darwin|Linux|Android)$")
IF(${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.14" AND NOT CMAKE_SYSTEM_NAME STREQUAL "iOS")
MESSAGE(WARNING
"Target operating system \"${CMAKE_SYSTEM_NAME}\" is not supported in cpuinfo. "
"cpuinfo will compile, but cpuinfo_initialize() will always fail.")
SET(CPUINFO_SUPPORTED_PLATFORM FALSE)
ENDIF()
ENDIF()
# ---[ cpuinfo library
SET(CPUINFO_SRCS
src/init.c
src/api.c
src/cache.c)
IF(CPUINFO_SUPPORTED_PLATFORM)
IF(NOT CMAKE_SYSTEM_NAME STREQUAL "Emscripten" AND (CPUINFO_TARGET_PROCESSOR MATCHES "^(i[3-6]86|AMD64|x86(_64)?)$" OR IOS_ARCH MATCHES "^(i386|x86_64)$"))
LIST(APPEND CPUINFO_SRCS
src/x86/init.c
src/x86/info.c
src/x86/vendor.c
src/x86/uarch.c
src/x86/name.c
src/x86/topology.c
src/x86/isa.c
src/x86/cache/init.c
src/x86/cache/descriptor.c
src/x86/cache/deterministic.c)
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
LIST(APPEND CPUINFO_SRCS
src/x86/linux/init.c
src/x86/linux/cpuinfo.c)
ELSEIF(CMAKE_SYSTEM_NAME STREQUAL "Darwin" OR CMAKE_SYSTEM_NAME STREQUAL "iOS")
LIST(APPEND CPUINFO_SRCS src/x86/mach/init.c)
ELSEIF(CMAKE_SYSTEM_NAME MATCHES "^(Windows|CYGWIN|MSYS)$")
LIST(APPEND CPUINFO_SRCS src/x86/windows/init.c)
ENDIF()
ELSEIF(CPUINFO_TARGET_PROCESSOR MATCHES "^(armv[5-8].*|aarch64|arm64)$" OR IOS_ARCH MATCHES "^(armv7.*|arm64.*)$")
LIST(APPEND CPUINFO_SRCS
src/arm/uarch.c
src/arm/cache.c)
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
LIST(APPEND CPUINFO_SRCS
src/arm/linux/init.c
src/arm/linux/cpuinfo.c
src/arm/linux/clusters.c
src/arm/linux/chipset.c
src/arm/linux/midr.c
src/arm/linux/hwcap.c)
IF(CMAKE_SYSTEM_PROCESSOR MATCHES "^armv[5-8]")
LIST(APPEND CPUINFO_SRCS src/arm/linux/aarch32-isa.c)
IF(CMAKE_SYSTEM_NAME STREQUAL "Android" AND ANDROID_ABI STREQUAL "armeabi")
SET_SOURCE_FILES_PROPERTIES(src/arm/linux/aarch32-isa.c PROPERTIES COMPILE_FLAGS -marm)
ENDIF()
ELSEIF(CMAKE_SYSTEM_PROCESSOR MATCHES "^(aarch64|arm64)$")
LIST(APPEND CPUINFO_SRCS src/arm/linux/aarch64-isa.c)
ENDIF()
ELSEIF(IOS OR (CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND CPUINFO_TARGET_PROCESSOR STREQUAL "arm64"))
LIST(APPEND CPUINFO_SRCS src/arm/mach/init.c)
ENDIF()
IF(CMAKE_SYSTEM_NAME STREQUAL "Android")
LIST(APPEND CPUINFO_SRCS
src/arm/android/properties.c)
ENDIF()
ENDIF()
IF(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
LIST(APPEND CPUINFO_SRCS
src/emscripten/init.c)
ENDIF()
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
LIST(APPEND CPUINFO_SRCS
src/linux/smallfile.c
src/linux/multiline.c
src/linux/cpulist.c
src/linux/processors.c)
ELSEIF(CMAKE_SYSTEM_NAME STREQUAL "Darwin" OR CMAKE_SYSTEM_NAME STREQUAL "iOS")
LIST(APPEND CPUINFO_SRCS src/mach/topology.c)
ENDIF()
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
SET(CMAKE_THREAD_PREFER_PTHREAD TRUE)
SET(THREADS_PREFER_PTHREAD_FLAG TRUE)
FIND_PACKAGE(Threads REQUIRED)
ENDIF()
ENDIF()
IF(CPUINFO_LIBRARY_TYPE STREQUAL "default")
ADD_LIBRARY(cpuinfo ${CPUINFO_SRCS})
ELSEIF(CPUINFO_LIBRARY_TYPE STREQUAL "shared")
ADD_LIBRARY(cpuinfo SHARED ${CPUINFO_SRCS})
ELSEIF(CPUINFO_LIBRARY_TYPE STREQUAL "static")
ADD_LIBRARY(cpuinfo STATIC ${CPUINFO_SRCS})
ELSE()
MESSAGE(FATAL_ERROR "Unsupported library type ${CPUINFO_LIBRARY_TYPE}")
ENDIF()
ADD_LIBRARY(cpuinfo_internals STATIC ${CPUINFO_SRCS})
CPUINFO_TARGET_ENABLE_C99(cpuinfo)
CPUINFO_TARGET_ENABLE_C99(cpuinfo_internals)
CPUINFO_TARGET_RUNTIME_LIBRARY(cpuinfo)
IF(CMAKE_SYSTEM_NAME MATCHES "^(Windows|CYGWIN|MSYS)$")
# Target Windows 7+ API
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE _WIN32_WINNT=0x0601)
TARGET_COMPILE_DEFINITIONS(cpuinfo_internals PRIVATE _WIN32_WINNT=0x0601)
ENDIF()
SET_TARGET_PROPERTIES(cpuinfo PROPERTIES PUBLIC_HEADER include/cpuinfo.h)
TARGET_INCLUDE_DIRECTORIES(cpuinfo BEFORE PUBLIC include)
TARGET_INCLUDE_DIRECTORIES(cpuinfo BEFORE PRIVATE src)
TARGET_INCLUDE_DIRECTORIES(cpuinfo_internals BEFORE PUBLIC include src)
IF(CPUINFO_LOG_LEVEL STREQUAL "default")
# default logging level: error (subject to change)
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=2)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "debug")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=5)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "info")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=4)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "warning")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=3)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "error")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=2)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "fatal")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=1)
ELSEIF(CPUINFO_LOG_LEVEL STREQUAL "none")
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE CPUINFO_LOG_LEVEL=0)
ELSE()
MESSAGE(FATAL_ERROR "Unsupported logging level ${CPUINFO_LOG_LEVEL}")
ENDIF()
TARGET_COMPILE_DEFINITIONS(cpuinfo_internals PRIVATE CPUINFO_LOG_LEVEL=0)
IF(CPUINFO_SUPPORTED_PLATFORM)
TARGET_COMPILE_DEFINITIONS(cpuinfo INTERFACE CPUINFO_SUPPORTED_PLATFORM=1)
IF(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "Android")
TARGET_LINK_LIBRARIES(cpuinfo PUBLIC ${CMAKE_THREAD_LIBS_INIT})
TARGET_LINK_LIBRARIES(cpuinfo_internals PUBLIC ${CMAKE_THREAD_LIBS_INIT})
TARGET_COMPILE_DEFINITIONS(cpuinfo PRIVATE _GNU_SOURCE=1)
TARGET_COMPILE_DEFINITIONS(cpuinfo_internals PRIVATE _GNU_SOURCE=1)
ENDIF()
ELSE()
TARGET_COMPILE_DEFINITIONS(cpuinfo INTERFACE CPUINFO_SUPPORTED_PLATFORM=0)
ENDIF()
# ---[ cpuinfo dependencies: clog
IF(NOT DEFINED CLOG_SOURCE_DIR)
SET(CLOG_SOURCE_DIR "${PROJECT_SOURCE_DIR}/deps/clog")
ENDIF()
IF(NOT TARGET clog)
SET(CLOG_BUILD_TESTS OFF CACHE BOOL "")
SET(CLOG_RUNTIME_TYPE "${CPUINFO_RUNTIME_TYPE}" CACHE STRING "")
ADD_SUBDIRECTORY(
"${CLOG_SOURCE_DIR}")
# We build static version of clog but a dynamic library may indirectly depend on it
SET_PROPERTY(TARGET clog PROPERTY POSITION_INDEPENDENT_CODE ON)
ENDIF()
TARGET_LINK_LIBRARIES(cpuinfo PRIVATE clog)
TARGET_LINK_LIBRARIES(cpuinfo_internals PRIVATE clog)

27
3rdparty/cpuinfo/LICENSE vendored Normal file
View File

@@ -0,0 +1,27 @@
Copyright (c) 2019 Google LLC
Copyright (c) 2017-2018 Facebook Inc.
Copyright (C) 2012-2017 Georgia Institute of Technology
Copyright (C) 2010-2012 Marat Dukhan
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

283
3rdparty/cpuinfo/README.md vendored Normal file
View File

@@ -0,0 +1,283 @@
# CPU INFOrmation library
[![BSD (2 clause) License](https://img.shields.io/badge/License-BSD%202--Clause%20%22Simplified%22%20License-blue.svg)](https://github.com/pytorch/cpuinfo/blob/master/LICENSE)
[![Linux/Mac build status](https://img.shields.io/travis/pytorch/cpuinfo.svg)](https://travis-ci.org/pytorch/cpuinfo)
[![Windows build status](https://ci.appveyor.com/api/projects/status/g5khy9nr0xm458t7/branch/master?svg=true)](https://ci.appveyor.com/project/MaratDukhan/cpuinfo/branch/master)
cpuinfo is a library to detect essential for performance optimization information about host CPU.
## Features
- **Cross-platform** availability:
- Linux, Windows, macOS, Android, and iOS operating systems
- x86, x86-64, ARM, and ARM64 architectures
- Modern **C/C++ interface**
- Thread-safe
- No memory allocation after initialization
- No exceptions thrown
- Detection of **supported instruction sets**, up to AVX512 (x86) and ARMv8.3 extensions
- Detection of SoC and core information:
- **Processor (SoC) name**
- Vendor and **microarchitecture** for each CPU core
- ID (**MIDR** on ARM, **CPUID** leaf 1 EAX value on x86) for each CPU core
- Detection of **cache information**:
- Cache type (instruction/data/unified), size and line size
- Cache associativity
- Cores and logical processors (hyper-threads) sharing the cache
- Detection of **topology information** (relative between logical processors, cores, and processor packages)
- Well-tested **production-quality** code:
- 60+ mock tests based on data from real devices
- Includes work-arounds for common bugs in hardware and OS kernels
- Supports systems with heterogenous cores, such as **big.LITTLE** and Max.Med.Min
- Permissive **open-source** license (Simplified BSD)
## Examples
Log processor name:
```c
cpuinfo_initialize();
printf("Running on %s CPU\n", cpuinfo_get_package(0)->name);
```
Detect if target is a 32-bit or 64-bit ARM system:
```c
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
/* 32-bit ARM-specific code here */
#endif
```
Check if the host CPU support ARM NEON
```c
cpuinfo_initialize();
if (cpuinfo_has_arm_neon()) {
neon_implementation(arguments);
}
```
Check if the host CPU supports x86 AVX
```c
cpuinfo_initialize();
if (cpuinfo_has_x86_avx()) {
avx_implementation(arguments);
}
```
Check if the thread runs on a Cortex-A53 core
```c
cpuinfo_initialize();
switch (cpuinfo_get_current_core()->uarch) {
case cpuinfo_uarch_cortex_a53:
cortex_a53_implementation(arguments);
break;
default:
generic_implementation(arguments);
break;
}
```
Get the size of level 1 data cache on the fastest core in the processor (e.g. big core in big.LITTLE ARM systems):
```c
cpuinfo_initialize();
const size_t l1_size = cpuinfo_get_processor(0)->cache.l1d->size;
```
Pin thread to cores sharing L2 cache with the current core (Linux or Android)
```c
cpuinfo_initialize();
cpu_set_t cpu_set;
CPU_ZERO(&cpu_set);
const struct cpuinfo_cache* current_l2 = cpuinfo_get_current_processor()->cache.l2;
for (uint32_t i = 0; i < current_l2->processor_count; i++) {
CPU_SET(cpuinfo_get_processor(current_l2->processor_start + i)->linux_id, &cpu_set);
}
pthread_setaffinity_np(pthread_self(), sizeof(cpu_set_t), &cpu_set);
```
## Use via pkg-config
If you would like to provide your project's build environment with the necessary compiler and linker flags in a portable manner, the library by default when built enables `CPUINFO_BUILD_PKG_CONFIG` and will generate a [pkg-config](https://www.freedesktop.org/wiki/Software/pkg-config/) manifest (_libcpuinfo.pc_). Here are several examples of how to use it:
### Command Line
If you used your distro's package manager to install the library, you can verify that it is available to your build environment like so:
```console
$ pkg-config --cflags --libs libcpuinfo
-I/usr/include/x86_64-linux-gnu/ -L/lib/x86_64-linux-gnu/ -lcpuinfo
```
If you have installed the library from source into a non-standard prefix, pkg-config may need help finding it:
```console
$ PKG_CONFIG_PATH="/home/me/projects/cpuinfo/prefix/lib/pkgconfig/:$PKG_CONFIG_PATH" pkg-config --cflags --libs libcpuinfo
-I/home/me/projects/cpuinfo/prefix/include -L/home/me/projects/cpuinfo/prefix/lib -lcpuinfo
```
### GNU Autotools
To [use](https://autotools.io/pkgconfig/pkg_check_modules.html) with the GNU Autotools include the following snippet in your project's `configure.ac`:
```makefile
# CPU INFOrmation library...
PKG_CHECK_MODULES(
[libcpuinfo], [libcpuinfo], [],
[AC_MSG_ERROR([libcpuinfo missing...])])
YOURPROJECT_CXXFLAGS="$YOURPROJECT_CXXFLAGS $libcpuinfo_CFLAGS"
YOURPROJECT_LIBS="$YOURPROJECT_LIBS $libcpuinfo_LIBS"
```
### Meson
To use with Meson you just need to add `dependency('libcpuinfo')` as a dependency for your executable.
```meson
project(
'MyCpuInfoProject',
'cpp',
meson_version: '>=0.55.0'
)
executable(
'MyCpuInfoExecutable',
sources: 'main.cpp',
dependencies: dependency('libcpuinfo')
)
```
### CMake
To use with CMake use the [FindPkgConfig](https://cmake.org/cmake/help/latest/module/FindPkgConfig.html) module. Here is an example:
```cmake
cmake_minimum_required(VERSION 3.6)
project("MyCpuInfoProject")
find_package(PkgConfig)
pkg_check_modules(CpuInfo REQUIRED IMPORTED_TARGET libcpuinfo)
add_executable(${PROJECT_NAME} main.cpp)
target_link_libraries(${PROJECT_NAME} PkgConfig::CpuInfo)
```
### Makefile
To use within a vanilla makefile, you can call pkg-config directly to supply compiler and linker flags using shell substitution.
```makefile
CFLAGS=-g3 -Wall -Wextra -Werror ...
LDFLAGS=-lfoo ...
...
CFLAGS+= $(pkg-config --cflags libcpuinfo)
LDFLAGS+= $(pkg-config --libs libcpuinfo)
```
## Exposed information
- [x] Processor (SoC) name
- [x] Microarchitecture
- [x] Usable instruction sets
- [ ] CPU frequency
- [x] Cache
- [x] Size
- [x] Associativity
- [x] Line size
- [x] Number of partitions
- [x] Flags (unified, inclusive, complex hash function)
- [x] Topology (logical processors that share this cache level)
- [ ] TLB
- [ ] Number of entries
- [ ] Associativity
- [ ] Covered page types (instruction, data)
- [ ] Covered page sizes
- [x] Topology information
- [x] Logical processors
- [x] Cores
- [x] Packages (sockets)
## Supported environments:
- [x] Android
- [x] x86 ABI
- [x] x86_64 ABI
- [x] armeabi ABI
- [x] armeabiv7-a ABI
- [x] arm64-v8a ABI
- [ ] ~~mips ABI~~
- [ ] ~~mips64 ABI~~
- [x] Linux
- [x] x86
- [x] x86-64
- [x] 32-bit ARM (ARMv5T and later)
- [x] ARM64
- [ ] PowerPC64
- [x] iOS
- [x] x86 (iPhone simulator)
- [x] x86-64 (iPhone simulator)
- [x] ARMv7
- [x] ARM64
- [x] OS X
- [x] x86
- [x] x86-64
- [x] Windows
- [x] x86
- [x] x86-64
## Methods
- Processor (SoC) name detection
- [x] Using CPUID leaves 0x800000020x80000004 on x86/x86-64
- [x] Using `/proc/cpuinfo` on ARM
- [x] Using `ro.chipname`, `ro.board.platform`, `ro.product.board`, `ro.mediatek.platform`, `ro.arch` properties (Android)
- [ ] Using kernel log (`dmesg`) on ARM Linux
- Vendor and microarchitecture detection
- [x] Intel-designed x86/x86-64 cores (up to Sunny Cove, Goldmont Plus, and Knights Mill)
- [x] AMD-designed x86/x86-64 cores (up to Puma/Jaguar and Zen 2)
- [ ] VIA-designed x86/x86-64 cores
- [ ] Other x86 cores (DM&P, RDC, Transmeta, Cyrix, Rise)
- [x] ARM-designed ARM cores (up to Cortex-A55, Cortex-A77, and Neoverse E1/N1)
- [x] Qualcomm-designed ARM cores (Scorpion, Krait, and Kryo)
- [x] Nvidia-designed ARM cores (Denver and Carmel)
- [x] Samsung-designed ARM cores (Exynos)
- [x] Intel-designed ARM cores (XScale up to 3rd-gen)
- [x] Apple-designed ARM cores (up to Lightning and Thunder)
- [x] Cavium-designed ARM cores (ThunderX)
- [x] AppliedMicro-designed ARM cores (X-Gene)
- Instruction set detection
- [x] Using CPUID (x86/x86-64)
- [x] Using `/proc/cpuinfo` on 32-bit ARM EABI (Linux)
- [x] Using microarchitecture heuristics on (32-bit ARM)
- [x] Using `FPSID` and `WCID` registers (32-bit ARM)
- [x] Using `getauxval` (Linux/ARM)
- [x] Using `/proc/self/auxv` (Android/ARM)
- [ ] Using instruction probing on ARM (Linux)
- [ ] Using CPUID registers on ARM64 (Linux)
- Cache detection
- [x] Using CPUID leaf 0x00000002 (x86/x86-64)
- [x] Using CPUID leaf 0x00000004 (non-AMD x86/x86-64)
- [ ] Using CPUID leaves 0x80000005-0x80000006 (AMD x86/x86-64)
- [x] Using CPUID leaf 0x8000001D (AMD x86/x86-64)
- [x] Using `/proc/cpuinfo` (Linux/pre-ARMv7)
- [x] Using microarchitecture heuristics (ARM)
- [x] Using chipset name (ARM)
- [x] Using `sysctlbyname` (Mach)
- [x] Using sysfs `typology` directories (ARM/Linux)
- [ ] Using sysfs `cache` directories (Linux)
- TLB detection
- [x] Using CPUID leaf 0x00000002 (x86/x86-64)
- [ ] Using CPUID leaves 0x80000005-0x80000006 and 0x80000019 (AMD x86/x86-64)
- [x] Using microarchitecture heuristics (ARM)
- Topology detection
- [x] Using CPUID leaf 0x00000001 on x86/x86-64 (legacy APIC ID)
- [x] Using CPUID leaf 0x0000000B on x86/x86-64 (Intel APIC ID)
- [ ] Using CPUID leaf 0x8000001E on x86/x86-64 (AMD APIC ID)
- [x] Using `/proc/cpuinfo` (Linux)
- [x] Using `host_info` (Mach)
- [x] Using `GetLogicalProcessorInformationEx` (Windows)
- [x] Using sysfs (Linux)
- [x] Using chipset name (ARM/Linux)

69
3rdparty/cpuinfo/cpuinfo.vcxproj vendored Normal file
View File

@@ -0,0 +1,69 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(SolutionDir)common\vsprops\BaseProjectConfig.props" />
<Import Project="$(SolutionDir)common\vsprops\WinSDK.props" />
<PropertyGroup Label="Globals">
<ProjectGuid>{7E183337-A7E9-460C-9D3D-568BC9F9BCC1}</ProjectGuid>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<PlatformToolset>$(DefaultPlatformToolset)</PlatformToolset>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization Condition="$(Configuration.Contains(Release))">true</WholeProgramOptimization>
<UseDebugLibraries Condition="$(Configuration.Contains(Debug))">true</UseDebugLibraries>
<UseDebugLibraries Condition="!$(Configuration.Contains(Debug))">false</UseDebugLibraries>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings" />
<ImportGroup Label="PropertySheets">
<Import Project="..\DefaultProjectRootDir.props" />
<Import Project="..\3rdparty.props" />
<Import Condition="$(Configuration.Contains(Debug))" Project="..\..\common\vsprops\CodeGen_Debug.props" />
<Import Condition="$(Configuration.Contains(Devel))" Project="..\..\common\vsprops\CodeGen_Devel.props" />
<Import Condition="$(Configuration.Contains(Release))" Project="..\..\common\vsprops\CodeGen_Release.props" />
<Import Condition="!$(Configuration.Contains(Release))" Project="..\..\common\vsprops\IncrementalLinking.props" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<ClCompile Include="deps\clog\src\clog.c" />
<ClCompile Include="src\api.c" />
<ClCompile Include="src\cache.c" />
<ClCompile Include="src\init.c" />
<ClCompile Include="src\x86\cache\descriptor.c" />
<ClCompile Include="src\x86\cache\deterministic.c" />
<ClCompile Include="src\x86\cache\init.c" />
<ClCompile Include="src\x86\info.c" />
<ClCompile Include="src\x86\init.c" />
<ClCompile Include="src\x86\isa.c" />
<ClCompile Include="src\x86\name.c" />
<ClCompile Include="src\x86\topology.c" />
<ClCompile Include="src\x86\uarch.c" />
<ClCompile Include="src\x86\vendor.c" />
<ClCompile Include="src\x86\windows\init.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="deps\clog\include\clog.h" />
<ClInclude Include="include\cpuinfo.h" />
<ClInclude Include="src\cpuinfo\common.h" />
<ClInclude Include="src\cpuinfo\internal-api.h" />
<ClInclude Include="src\cpuinfo\log.h" />
<ClInclude Include="src\cpuinfo\utils.h" />
<ClInclude Include="src\x86\api.h" />
<ClInclude Include="src\x86\cpuid.h" />
<ClInclude Include="src\x86\windows\api.h" />
</ItemGroup>
<ItemDefinitionGroup>
<ClCompile>
<PreprocessorDefinitions>%(PreprocessorDefinitions)</PreprocessorDefinitions>
<WarningLevel>TurnOffAllWarnings</WarningLevel>
<AdditionalIncludeDirectories>$(ProjectDir)include;$(ProjectDir)src;$(ProjectDir)deps\clog\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ObjectFileName>$(IntDir)%(RelativeDir)</ObjectFileName>
</ClCompile>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets" />
</Project>

View File

@@ -0,0 +1,88 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="x86">
<UniqueIdentifier>{8fc9f543-ff04-48fb-ae1a-7c575a8aed13}</UniqueIdentifier>
</Filter>
<Filter Include="x86\windows">
<UniqueIdentifier>{0b540baa-aafb-4e51-8cbf-b7e7c00d9a4d}</UniqueIdentifier>
</Filter>
<Filter Include="x86\descriptor">
<UniqueIdentifier>{53ef3c40-8e03-46d1-aeb3-6446c40469da}</UniqueIdentifier>
</Filter>
<Filter Include="cpuinfo">
<UniqueIdentifier>{26002d26-399a-41bb-93cb-42fb9be21c1f}</UniqueIdentifier>
</Filter>
<Filter Include="clog">
<UniqueIdentifier>{7f0aba4c-ca06-4a7b-aed1-4f1e6976e839}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="src\x86\isa.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\name.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\topology.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\uarch.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\vendor.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\info.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\init.c">
<Filter>x86</Filter>
</ClCompile>
<ClCompile Include="src\x86\windows\init.c">
<Filter>x86\windows</Filter>
</ClCompile>
<ClCompile Include="src\x86\cache\deterministic.c">
<Filter>x86\descriptor</Filter>
</ClCompile>
<ClCompile Include="src\x86\cache\init.c">
<Filter>x86\descriptor</Filter>
</ClCompile>
<ClCompile Include="src\x86\cache\descriptor.c">
<Filter>x86\descriptor</Filter>
</ClCompile>
<ClCompile Include="src\api.c" />
<ClCompile Include="src\cache.c" />
<ClCompile Include="src\init.c" />
<ClCompile Include="deps\clog\src\clog.c">
<Filter>clog</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="src\x86\api.h">
<Filter>x86</Filter>
</ClInclude>
<ClInclude Include="src\x86\cpuid.h">
<Filter>x86</Filter>
</ClInclude>
<ClInclude Include="src\x86\windows\api.h">
<Filter>x86\windows</Filter>
</ClInclude>
<ClInclude Include="src\cpuinfo\internal-api.h">
<Filter>cpuinfo</Filter>
</ClInclude>
<ClInclude Include="src\cpuinfo\log.h">
<Filter>cpuinfo</Filter>
</ClInclude>
<ClInclude Include="src\cpuinfo\utils.h">
<Filter>cpuinfo</Filter>
</ClInclude>
<ClInclude Include="src\cpuinfo\common.h">
<Filter>cpuinfo</Filter>
</ClInclude>
<ClInclude Include="include\cpuinfo.h" />
<ClInclude Include="deps\clog\include\clog.h">
<Filter>clog</Filter>
</ClInclude>
</ItemGroup>
</Project>

19
3rdparty/cpuinfo/deps/clog/.gitignore vendored Normal file
View File

@@ -0,0 +1,19 @@
# Ninja files
build.ninja
# Build objects and artifacts
deps/
build/
bin/
lib/
*.pyc
*.pyo
# System files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

View File

@@ -0,0 +1,42 @@
CMAKE_MINIMUM_REQUIRED(VERSION 3.1 FATAL_ERROR)
# ---[ Project and semantic versioning.
PROJECT(clog C CXX)
# ---[ Options.
SET(CLOG_RUNTIME_TYPE "default" CACHE STRING "Type of runtime library (shared, static, or default) to use")
SET_PROPERTY(CACHE CLOG_RUNTIME_TYPE PROPERTY STRINGS default static shared)
IF(ANDROID)
OPTION(CLOG_LOG_TO_STDIO "Log errors, warnings, and information to stdout/stderr" OFF)
ELSE()
OPTION(CLOG_LOG_TO_STDIO "Log errors, warnings, and information to stdout/stderr" ON)
ENDIF()
MACRO(CLOG_TARGET_RUNTIME_LIBRARY target)
IF(MSVC AND NOT CLOG_RUNTIME_TYPE STREQUAL "default")
IF(CLOG_RUNTIME_TYPE STREQUAL "shared")
TARGET_COMPILE_OPTIONS(${target} PRIVATE
"/MD$<$<CONFIG:Debug>:d>")
ELSEIF(CLOG_RUNTIME_TYPE STREQUAL "static")
TARGET_COMPILE_OPTIONS(${target} PRIVATE
"/MT$<$<CONFIG:Debug>:d>")
ENDIF()
ENDIF()
ENDMACRO()
# ---[ clog library
ADD_LIBRARY(clog STATIC src/clog.c)
SET_TARGET_PROPERTIES(clog PROPERTIES
C_STANDARD 99
C_EXTENSIONS NO)
CLOG_TARGET_RUNTIME_LIBRARY(clog)
SET_TARGET_PROPERTIES(clog PROPERTIES PUBLIC_HEADER include/clog.h)
TARGET_INCLUDE_DIRECTORIES(clog BEFORE PUBLIC include)
IF(CLOG_LOG_TO_STDIO)
TARGET_COMPILE_DEFINITIONS(clog PRIVATE CLOG_LOG_TO_STDIO=1)
ELSE()
TARGET_COMPILE_DEFINITIONS(clog PRIVATE CLOG_LOG_TO_STDIO=0)
ENDIF()
IF(ANDROID AND NOT CLOG_LOG_TO_STDIO)
TARGET_LINK_LIBRARIES(clog PRIVATE log)
ENDIF()

26
3rdparty/cpuinfo/deps/clog/LICENSE vendored Normal file
View File

@@ -0,0 +1,26 @@
Copyright (C) 2018 Marat Dukhan
Copyright (c) 2017-2018 Facebook Inc.
Copyright (c) 2017 Georgia Institute of Technology
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

57
3rdparty/cpuinfo/deps/clog/README.md vendored Normal file
View File

@@ -0,0 +1,57 @@
# clog: C-style (a-la printf) logging library
[![BSD (2 clause) License](https://img.shields.io/badge/License-BSD%202--Clause%20%22Simplified%22%20License-blue.svg)](https://github.com/pytorch/cpuinfo/blob/master/deps/clog/LICENSE)
C-style library for logging errors, warnings, information notes, and debug information.
## Features
- printf-style interface for formatting variadic parameters.
- Separate functions for logging errors, warnings, information notes, and debug information.
- Independent logging settings for different modules.
- Logging to logcat on Android and stderr/stdout on other platforms.
- Compatible with C99 and C++.
- Covered with unit tests.
## Example
```c
#include <clog.h>
#ifndef MYMODULE_LOG_LEVEL
#define MYMODULE_LOG_LEVEL CLOG_DEBUG
#endif
CLOG_DEFINE_LOG_DEBUG(mymodule_, "My Module", MYMODULE_LOG_LEVEL);
CLOG_DEFINE_LOG_INFO(mymodule_, "My Module", MYMODULE_LOG_LEVEL);
CLOG_DEFINE_LOG_WARNING(mymodule_, "My Module", MYMODULE_LOG_LEVEL);
CLOG_DEFINE_LOG_ERROR(mymodule_, "My Module", MYMODULE_LOG_LEVEL);
...
void some_function(...) {
int status = ...
if (status != 0) {
mymodule_log_error(
"something really bad happened: "
"operation failed with status %d", status);
}
uint32_t expected_zero = ...
if (expected_zero != 0) {
mymodule_log_warning(
"something suspicious happened (var = %"PRIu32"), "
"fall back to generic implementation", expected_zero);
}
void* usually_non_null = ...
if (usually_non_null == NULL) {
mymodule_log_info(
"something unusual, but common, happened: "
"enabling work-around");
}
float a = ...
mymodule_log_debug("computed a = %.7f", a);
}
```

View File

@@ -0,0 +1,100 @@
#pragma once
#include <stdarg.h>
#include <stdlib.h>
#include <inttypes.h>
#define CLOG_NONE 0
#define CLOG_FATAL 1
#define CLOG_ERROR 2
#define CLOG_WARNING 3
#define CLOG_INFO 4
#define CLOG_DEBUG 5
#ifndef CLOG_VISIBILITY
#if defined(__ELF__)
#define CLOG_VISIBILITY __attribute__((__visibility__("internal")))
#elif defined(__MACH__)
#define CLOG_VISIBILITY __attribute__((__visibility__("hidden")))
#else
#define CLOG_VISIBILITY
#endif
#endif
#ifndef CLOG_ARGUMENTS_FORMAT
#if defined(__GNUC__)
#define CLOG_ARGUMENTS_FORMAT __attribute__((__format__(__printf__, 1, 2)))
#else
#define CLOG_ARGUMENTS_FORMAT
#endif
#endif
#ifdef __cplusplus
extern "C" {
#endif
CLOG_VISIBILITY void clog_vlog_debug(const char* module, const char* format, va_list args);
CLOG_VISIBILITY void clog_vlog_info(const char* module, const char* format, va_list args);
CLOG_VISIBILITY void clog_vlog_warning(const char* module, const char* format, va_list args);
CLOG_VISIBILITY void clog_vlog_error(const char* module, const char* format, va_list args);
CLOG_VISIBILITY void clog_vlog_fatal(const char* module, const char* format, va_list args);
#define CLOG_DEFINE_LOG_DEBUG(log_debug_function_name, module, level) \
CLOG_ARGUMENTS_FORMAT \
inline static void log_debug_function_name(const char* format, ...) { \
if (level >= CLOG_DEBUG) { \
va_list args; \
va_start(args, format); \
clog_vlog_debug(module, format, args); \
va_end(args); \
} \
}
#define CLOG_DEFINE_LOG_INFO(log_info_function_name, module, level) \
CLOG_ARGUMENTS_FORMAT \
inline static void log_info_function_name(const char* format, ...) { \
if (level >= CLOG_INFO) { \
va_list args; \
va_start(args, format); \
clog_vlog_info(module, format, args); \
va_end(args); \
} \
}
#define CLOG_DEFINE_LOG_WARNING(log_warning_function_name, module, level) \
CLOG_ARGUMENTS_FORMAT \
inline static void log_warning_function_name(const char* format, ...) { \
if (level >= CLOG_WARNING) { \
va_list args; \
va_start(args, format); \
clog_vlog_warning(module, format, args); \
va_end(args); \
} \
}
#define CLOG_DEFINE_LOG_ERROR(log_error_function_name, module, level) \
CLOG_ARGUMENTS_FORMAT \
inline static void log_error_function_name(const char* format, ...) { \
if (level >= CLOG_ERROR) { \
va_list args; \
va_start(args, format); \
clog_vlog_error(module, format, args); \
va_end(args); \
} \
}
#define CLOG_DEFINE_LOG_FATAL(log_fatal_function_name, module, level) \
CLOG_ARGUMENTS_FORMAT \
inline static void log_fatal_function_name(const char* format, ...) { \
if (level >= CLOG_FATAL) { \
va_list args; \
va_start(args, format); \
clog_vlog_fatal(module, format, args); \
va_end(args); \
} \
abort(); \
}
#ifdef __cplusplus
} /* extern "C" */
#endif

423
3rdparty/cpuinfo/deps/clog/src/clog.c vendored Normal file
View File

@@ -0,0 +1,423 @@
#include <stdarg.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#ifdef _WIN32
#include <windows.h>
#else
#include <unistd.h>
#endif
#ifdef __ANDROID__
#include <android/log.h>
#endif
#ifndef CLOG_LOG_TO_STDIO
#ifdef __ANDROID__
#define CLOG_LOG_TO_STDIO 0
#else
#define CLOG_LOG_TO_STDIO 1
#endif
#endif
#include <clog.h>
/* Messages up to this size are formatted entirely on-stack, and don't allocate heap memory */
#define CLOG_STACK_BUFFER_SIZE 1024
#define CLOG_FATAL_PREFIX "Fatal error: "
#define CLOG_FATAL_PREFIX_LENGTH 13
#define CLOG_FATAL_PREFIX_FORMAT "Fatal error in %s: "
#define CLOG_ERROR_PREFIX "Error: "
#define CLOG_ERROR_PREFIX_LENGTH 7
#define CLOG_ERROR_PREFIX_FORMAT "Error in %s: "
#define CLOG_WARNING_PREFIX "Warning: "
#define CLOG_WARNING_PREFIX_LENGTH 9
#define CLOG_WARNING_PREFIX_FORMAT "Warning in %s: "
#define CLOG_INFO_PREFIX "Note: "
#define CLOG_INFO_PREFIX_LENGTH 6
#define CLOG_INFO_PREFIX_FORMAT "Note (%s): "
#define CLOG_DEBUG_PREFIX "Debug: "
#define CLOG_DEBUG_PREFIX_LENGTH 7
#define CLOG_DEBUG_PREFIX_FORMAT "Debug (%s): "
#define CLOG_SUFFIX_LENGTH 1
void clog_vlog_fatal(const char* module, const char* format, va_list args) {
#if defined(__ANDROID__) && !CLOG_LOG_TO_STDIO
__android_log_vprint(ANDROID_LOG_FATAL, module, format, args);
#else
char stack_buffer[CLOG_STACK_BUFFER_SIZE];
char* heap_buffer = NULL;
char* out_buffer = &stack_buffer[0];
/* The first call to vsnprintf will clobber args, thus need a copy in case a second vsnprintf call is needed */
va_list args_copy;
va_copy(args_copy, args);
int prefix_chars = CLOG_FATAL_PREFIX_LENGTH;
if (module == NULL) {
memcpy(stack_buffer, CLOG_FATAL_PREFIX, CLOG_FATAL_PREFIX_LENGTH);
} else {
prefix_chars = snprintf(stack_buffer, CLOG_STACK_BUFFER_SIZE, CLOG_FATAL_PREFIX_FORMAT, module);
if (prefix_chars < 0) {
/* Format error in prefix (possible if prefix is modified): skip prefix and continue as if nothing happened. */
prefix_chars = 0;
}
}
int format_chars;
if (prefix_chars + CLOG_SUFFIX_LENGTH >= CLOG_STACK_BUFFER_SIZE) {
/*
* Prefix + suffix alone would overflow the on-stack buffer, thus need to use on-heap buffer.
* Do not even try to format the string into on-stack buffer.
*/
format_chars = vsnprintf(NULL, 0, format, args);
} else {
format_chars =
vsnprintf(
&stack_buffer[prefix_chars],
CLOG_STACK_BUFFER_SIZE - prefix_chars - CLOG_SUFFIX_LENGTH,
format,
args);
}
if (format_chars < 0) {
/* Format error in the message: silently ignore this particular message. */
goto cleanup;
}
if (prefix_chars + format_chars + CLOG_SUFFIX_LENGTH > CLOG_STACK_BUFFER_SIZE) {
/* Allocate a buffer on heap, and vsnprintf to this buffer */
heap_buffer = malloc(prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
if (heap_buffer == NULL) {
goto cleanup;
}
if (prefix_chars > CLOG_STACK_BUFFER_SIZE) {
/* Prefix didn't fit into on-stack buffer, re-format it again to on-heap buffer */
snprintf(heap_buffer, prefix_chars + 1 /* for '\0'-terminator */, CLOG_FATAL_PREFIX_FORMAT, module);
} else {
/* Copy pre-formatted prefix from on-stack buffer to on-heap buffer */
memcpy(heap_buffer, stack_buffer, prefix_chars);
}
vsnprintf(heap_buffer + prefix_chars, format_chars + CLOG_SUFFIX_LENGTH, format, args_copy);
out_buffer = heap_buffer;
}
out_buffer[prefix_chars + format_chars] = '\n';
#ifdef _WIN32
DWORD bytes_written;
WriteFile(
GetStdHandle(STD_ERROR_HANDLE),
out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH,
&bytes_written, NULL);
#else
write(STDERR_FILENO, out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
#endif
cleanup:
free(heap_buffer);
va_end(args_copy);
#endif
}
void clog_vlog_error(const char* module, const char* format, va_list args) {
#if defined(__ANDROID__) && !CLOG_LOG_TO_STDIO
__android_log_vprint(ANDROID_LOG_ERROR, module, format, args);
#else
char stack_buffer[CLOG_STACK_BUFFER_SIZE];
char* heap_buffer = NULL;
char* out_buffer = &stack_buffer[0];
/* The first call to vsnprintf will clobber args, thus need a copy in case a second vsnprintf call is needed */
va_list args_copy;
va_copy(args_copy, args);
int prefix_chars = CLOG_ERROR_PREFIX_LENGTH;
if (module == NULL) {
memcpy(stack_buffer, CLOG_ERROR_PREFIX, CLOG_ERROR_PREFIX_LENGTH);
} else {
prefix_chars = snprintf(stack_buffer, CLOG_STACK_BUFFER_SIZE, CLOG_ERROR_PREFIX_FORMAT, module);
if (prefix_chars < 0) {
/* Format error in prefix (possible if prefix is modified): skip prefix and continue as if nothing happened. */
prefix_chars = 0;
}
}
int format_chars;
if (prefix_chars + CLOG_SUFFIX_LENGTH >= CLOG_STACK_BUFFER_SIZE) {
/*
* Prefix + suffix alone would overflow the on-stack buffer, thus need to use on-heap buffer.
* Do not even try to format the string into on-stack buffer.
*/
format_chars = vsnprintf(NULL, 0, format, args);
} else {
format_chars =
vsnprintf(
&stack_buffer[prefix_chars],
CLOG_STACK_BUFFER_SIZE - prefix_chars - CLOG_SUFFIX_LENGTH,
format,
args);
}
if (format_chars < 0) {
/* Format error in the message: silently ignore this particular message. */
goto cleanup;
}
if (prefix_chars + format_chars + CLOG_SUFFIX_LENGTH > CLOG_STACK_BUFFER_SIZE) {
/* Allocate a buffer on heap, and vsnprintf to this buffer */
heap_buffer = malloc(prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
if (heap_buffer == NULL) {
goto cleanup;
}
if (prefix_chars > CLOG_STACK_BUFFER_SIZE) {
/* Prefix didn't fit into on-stack buffer, re-format it again to on-heap buffer */
snprintf(heap_buffer, prefix_chars + 1 /* for '\0'-terminator */, CLOG_ERROR_PREFIX_FORMAT, module);
} else {
/* Copy pre-formatted prefix from on-stack buffer to on-heap buffer */
memcpy(heap_buffer, stack_buffer, prefix_chars);
}
vsnprintf(heap_buffer + prefix_chars, format_chars + CLOG_SUFFIX_LENGTH, format, args_copy);
out_buffer = heap_buffer;
}
out_buffer[prefix_chars + format_chars] = '\n';
#ifdef _WIN32
DWORD bytes_written;
WriteFile(
GetStdHandle(STD_ERROR_HANDLE),
out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH,
&bytes_written, NULL);
#else
write(STDERR_FILENO, out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
#endif
cleanup:
free(heap_buffer);
va_end(args_copy);
#endif
}
void clog_vlog_warning(const char* module, const char* format, va_list args) {
#if defined(__ANDROID__) && !CLOG_LOG_TO_STDIO
__android_log_vprint(ANDROID_LOG_WARN, module, format, args);
#else
char stack_buffer[CLOG_STACK_BUFFER_SIZE];
char* heap_buffer = NULL;
char* out_buffer = &stack_buffer[0];
/* The first call to vsnprintf will clobber args, thus need a copy in case a second vsnprintf call is needed */
va_list args_copy;
va_copy(args_copy, args);
int prefix_chars = CLOG_WARNING_PREFIX_LENGTH;
if (module == NULL) {
memcpy(stack_buffer, CLOG_WARNING_PREFIX, CLOG_WARNING_PREFIX_LENGTH);
} else {
prefix_chars = snprintf(stack_buffer, CLOG_STACK_BUFFER_SIZE, CLOG_WARNING_PREFIX_FORMAT, module);
if (prefix_chars < 0) {
/* Format error in prefix (possible if prefix is modified): skip prefix and continue as if nothing happened. */
prefix_chars = 0;
}
}
int format_chars;
if (prefix_chars + CLOG_SUFFIX_LENGTH >= CLOG_STACK_BUFFER_SIZE) {
/*
* Prefix + suffix alone would overflow the on-stack buffer, thus need to use on-heap buffer.
* Do not even try to format the string into on-stack buffer.
*/
format_chars = vsnprintf(NULL, 0, format, args);
} else {
format_chars =
vsnprintf(
&stack_buffer[prefix_chars],
CLOG_STACK_BUFFER_SIZE - prefix_chars - CLOG_SUFFIX_LENGTH,
format,
args);
}
if (format_chars < 0) {
/* Format error in the message: silently ignore this particular message. */
goto cleanup;
}
if (prefix_chars + format_chars + CLOG_SUFFIX_LENGTH > CLOG_STACK_BUFFER_SIZE) {
/* Allocate a buffer on heap, and vsnprintf to this buffer */
heap_buffer = malloc(prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
if (heap_buffer == NULL) {
goto cleanup;
}
if (prefix_chars > CLOG_STACK_BUFFER_SIZE) {
/* Prefix didn't fit into on-stack buffer, re-format it again to on-heap buffer */
snprintf(heap_buffer, prefix_chars + 1 /* for '\0'-terminator */, CLOG_WARNING_PREFIX_FORMAT, module);
} else {
/* Copy pre-formatted prefix from on-stack buffer to on-heap buffer */
memcpy(heap_buffer, stack_buffer, prefix_chars);
}
vsnprintf(heap_buffer + prefix_chars, format_chars + CLOG_SUFFIX_LENGTH, format, args_copy);
out_buffer = heap_buffer;
}
out_buffer[prefix_chars + format_chars] = '\n';
#ifdef _WIN32
DWORD bytes_written;
WriteFile(
GetStdHandle(STD_ERROR_HANDLE),
out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH,
&bytes_written, NULL);
#else
write(STDERR_FILENO, out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
#endif
cleanup:
free(heap_buffer);
va_end(args_copy);
#endif
}
void clog_vlog_info(const char* module, const char* format, va_list args) {
#if defined(__ANDROID__) && !CLOG_LOG_TO_STDIO
__android_log_vprint(ANDROID_LOG_INFO, module, format, args);
#else
char stack_buffer[CLOG_STACK_BUFFER_SIZE];
char* heap_buffer = NULL;
char* out_buffer = &stack_buffer[0];
/* The first call to vsnprintf will clobber args, thus need a copy in case a second vsnprintf call is needed */
va_list args_copy;
va_copy(args_copy, args);
int prefix_chars = CLOG_INFO_PREFIX_LENGTH;
if (module == NULL) {
memcpy(stack_buffer, CLOG_INFO_PREFIX, CLOG_INFO_PREFIX_LENGTH);
} else {
prefix_chars = snprintf(stack_buffer, CLOG_STACK_BUFFER_SIZE, CLOG_INFO_PREFIX_FORMAT, module);
if (prefix_chars < 0) {
/* Format error in prefix (possible if prefix is modified): skip prefix and continue as if nothing happened. */
prefix_chars = 0;
}
}
int format_chars;
if (prefix_chars + CLOG_SUFFIX_LENGTH >= CLOG_STACK_BUFFER_SIZE) {
/*
* Prefix + suffix alone would overflow the on-stack buffer, thus need to use on-heap buffer.
* Do not even try to format the string into on-stack buffer.
*/
format_chars = vsnprintf(NULL, 0, format, args);
} else {
format_chars =
vsnprintf(
&stack_buffer[prefix_chars],
CLOG_STACK_BUFFER_SIZE - prefix_chars - CLOG_SUFFIX_LENGTH,
format,
args);
}
if (format_chars < 0) {
/* Format error in the message: silently ignore this particular message. */
goto cleanup;
}
if (prefix_chars + format_chars + CLOG_SUFFIX_LENGTH > CLOG_STACK_BUFFER_SIZE) {
/* Allocate a buffer on heap, and vsnprintf to this buffer */
heap_buffer = malloc(prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
if (heap_buffer == NULL) {
goto cleanup;
}
if (prefix_chars > CLOG_STACK_BUFFER_SIZE) {
/* Prefix didn't fit into on-stack buffer, re-format it again to on-heap buffer */
snprintf(heap_buffer, prefix_chars + 1 /* for '\0'-terminator */, CLOG_INFO_PREFIX_FORMAT, module);
} else {
/* Copy pre-formatted prefix from on-stack buffer to on-heap buffer */
memcpy(heap_buffer, stack_buffer, prefix_chars);
}
vsnprintf(heap_buffer + prefix_chars, format_chars + CLOG_SUFFIX_LENGTH, format, args_copy);
out_buffer = heap_buffer;
}
out_buffer[prefix_chars + format_chars] = '\n';
#ifdef _WIN32
DWORD bytes_written;
WriteFile(
GetStdHandle(STD_OUTPUT_HANDLE),
out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH,
&bytes_written, NULL);
#else
write(STDOUT_FILENO, out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
#endif
cleanup:
free(heap_buffer);
va_end(args_copy);
#endif
}
void clog_vlog_debug(const char* module, const char* format, va_list args) {
#if defined(__ANDROID__) && !CLOG_LOG_TO_STDIO
__android_log_vprint(ANDROID_LOG_DEBUG, module, format, args);
#else
char stack_buffer[CLOG_STACK_BUFFER_SIZE];
char* heap_buffer = NULL;
char* out_buffer = &stack_buffer[0];
/* The first call to vsnprintf will clobber args, thus need a copy in case a second vsnprintf call is needed */
va_list args_copy;
va_copy(args_copy, args);
int prefix_chars = CLOG_DEBUG_PREFIX_LENGTH;
if (module == NULL) {
memcpy(stack_buffer, CLOG_DEBUG_PREFIX, CLOG_DEBUG_PREFIX_LENGTH);
} else {
prefix_chars = snprintf(stack_buffer, CLOG_STACK_BUFFER_SIZE, CLOG_DEBUG_PREFIX_FORMAT, module);
if (prefix_chars < 0) {
/* Format error in prefix (possible if prefix is modified): skip prefix and continue as if nothing happened. */
prefix_chars = 0;
}
}
int format_chars;
if (prefix_chars + CLOG_SUFFIX_LENGTH >= CLOG_STACK_BUFFER_SIZE) {
/*
* Prefix + suffix alone would overflow the on-stack buffer, thus need to use on-heap buffer.
* Do not even try to format the string into on-stack buffer.
*/
format_chars = vsnprintf(NULL, 0, format, args);
} else {
format_chars =
vsnprintf(
&stack_buffer[prefix_chars],
CLOG_STACK_BUFFER_SIZE - prefix_chars - CLOG_SUFFIX_LENGTH,
format,
args);
}
if (format_chars < 0) {
/* Format error in the message: silently ignore this particular message. */
goto cleanup;
}
if (prefix_chars + format_chars + CLOG_SUFFIX_LENGTH > CLOG_STACK_BUFFER_SIZE) {
/* Allocate a buffer on heap, and vsnprintf to this buffer */
heap_buffer = malloc(prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
if (heap_buffer == NULL) {
goto cleanup;
}
if (prefix_chars > CLOG_STACK_BUFFER_SIZE) {
/* Prefix didn't fit into on-stack buffer, re-format it again to on-heap buffer */
snprintf(heap_buffer, prefix_chars + 1 /* for '\0'-terminator */, CLOG_DEBUG_PREFIX_FORMAT, module);
} else {
/* Copy pre-formatted prefix from on-stack buffer to on-heap buffer */
memcpy(heap_buffer, stack_buffer, prefix_chars);
}
vsnprintf(heap_buffer + prefix_chars, format_chars + CLOG_SUFFIX_LENGTH, format, args_copy);
out_buffer = heap_buffer;
}
out_buffer[prefix_chars + format_chars] = '\n';
#ifdef _WIN32
DWORD bytes_written;
WriteFile(
GetStdHandle(STD_OUTPUT_HANDLE),
out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH,
&bytes_written, NULL);
#else
write(STDOUT_FILENO, out_buffer, prefix_chars + format_chars + CLOG_SUFFIX_LENGTH);
#endif
cleanup:
free(heap_buffer);
va_end(args_copy);
#endif
}

78
3rdparty/cpuinfo/include/cpuinfo-mock.h vendored Normal file
View File

@@ -0,0 +1,78 @@
#pragma once
#ifndef CPUINFO_MOCK_H
#define CPUINFO_MOCK_H
#include <stddef.h>
#include <stdint.h>
#include <cpuinfo.h>
#if defined(__linux__)
#include <sys/types.h>
#endif
#if !defined(CPUINFO_MOCK) || !(CPUINFO_MOCK)
#error This header is intended only for test use
#endif
#ifdef __cplusplus
extern "C" {
#endif
#if CPUINFO_ARCH_ARM
void CPUINFO_ABI cpuinfo_set_fpsid(uint32_t fpsid);
void CPUINFO_ABI cpuinfo_set_wcid(uint32_t wcid);
#endif /* CPUINFO_ARCH_ARM */
#if CPUINFO_ARCH_X86 || CPUINFO_ARCH_X86_64
struct cpuinfo_mock_cpuid {
uint32_t input_eax;
uint32_t input_ecx;
uint32_t eax;
uint32_t ebx;
uint32_t ecx;
uint32_t edx;
};
void CPUINFO_ABI cpuinfo_mock_set_cpuid(struct cpuinfo_mock_cpuid* dump, size_t entries);
void CPUINFO_ABI cpuinfo_mock_get_cpuid(uint32_t eax, uint32_t regs[4]);
void CPUINFO_ABI cpuinfo_mock_get_cpuidex(uint32_t eax, uint32_t ecx, uint32_t regs[4]);
#endif /* CPUINFO_ARCH_X86 || CPUINFO_ARCH_X86_64 */
struct cpuinfo_mock_file {
const char* path;
size_t size;
const char* content;
size_t offset;
};
struct cpuinfo_mock_property {
const char* key;
const char* value;
};
#if defined(__linux__)
void CPUINFO_ABI cpuinfo_mock_filesystem(struct cpuinfo_mock_file* files);
int CPUINFO_ABI cpuinfo_mock_open(const char* path, int oflag);
int CPUINFO_ABI cpuinfo_mock_close(int fd);
ssize_t CPUINFO_ABI cpuinfo_mock_read(int fd, void* buffer, size_t capacity);
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
void CPUINFO_ABI cpuinfo_set_hwcap(uint32_t hwcap);
#endif
#if CPUINFO_ARCH_ARM
void CPUINFO_ABI cpuinfo_set_hwcap2(uint32_t hwcap2);
#endif
#endif
#if defined(__ANDROID__)
void CPUINFO_ABI cpuinfo_mock_android_properties(struct cpuinfo_mock_property* properties);
void CPUINFO_ABI cpuinfo_mock_gl_renderer(const char* renderer);
#endif
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif /* CPUINFO_MOCK_H */

1872
3rdparty/cpuinfo/include/cpuinfo.h vendored Normal file

File diff suppressed because it is too large Load Diff

410
3rdparty/cpuinfo/src/api.c vendored Normal file
View File

@@ -0,0 +1,410 @@
#include <stdbool.h>
#include <stddef.h>
#include <cpuinfo.h>
#include <cpuinfo/internal-api.h>
#include <cpuinfo/log.h>
#ifdef __linux__
#include <linux/api.h>
#include <unistd.h>
#include <sys/syscall.h>
#if !defined(__NR_getcpu)
#include <asm-generic/unistd.h>
#endif
#endif
bool cpuinfo_is_initialized = false;
struct cpuinfo_processor* cpuinfo_processors = NULL;
struct cpuinfo_core* cpuinfo_cores = NULL;
struct cpuinfo_cluster* cpuinfo_clusters = NULL;
struct cpuinfo_package* cpuinfo_packages = NULL;
struct cpuinfo_cache* cpuinfo_cache[cpuinfo_cache_level_max] = { NULL };
uint32_t cpuinfo_processors_count = 0;
uint32_t cpuinfo_cores_count = 0;
uint32_t cpuinfo_clusters_count = 0;
uint32_t cpuinfo_packages_count = 0;
uint32_t cpuinfo_cache_count[cpuinfo_cache_level_max] = { 0 };
uint32_t cpuinfo_max_cache_size = 0;
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
struct cpuinfo_uarch_info* cpuinfo_uarchs = NULL;
uint32_t cpuinfo_uarchs_count = 0;
#else
struct cpuinfo_uarch_info cpuinfo_global_uarch = { cpuinfo_uarch_unknown };
#endif
#ifdef __linux__
uint32_t cpuinfo_linux_cpu_max = 0;
const struct cpuinfo_processor** cpuinfo_linux_cpu_to_processor_map = NULL;
const struct cpuinfo_core** cpuinfo_linux_cpu_to_core_map = NULL;
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
const uint32_t* cpuinfo_linux_cpu_to_uarch_index_map = NULL;
#endif
#endif
const struct cpuinfo_processor* cpuinfo_get_processors(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "processors");
}
return cpuinfo_processors;
}
const struct cpuinfo_core* cpuinfo_get_cores(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "core");
}
return cpuinfo_cores;
}
const struct cpuinfo_cluster* cpuinfo_get_clusters(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "clusters");
}
return cpuinfo_clusters;
}
const struct cpuinfo_package* cpuinfo_get_packages(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "packages");
}
return cpuinfo_packages;
}
const struct cpuinfo_uarch_info* cpuinfo_get_uarchs() {
if (!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "uarchs");
}
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
return cpuinfo_uarchs;
#else
return &cpuinfo_global_uarch;
#endif
}
const struct cpuinfo_processor* cpuinfo_get_processor(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "processor");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_processors_count) {
return NULL;
}
return &cpuinfo_processors[index];
}
const struct cpuinfo_core* cpuinfo_get_core(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "core");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cores_count) {
return NULL;
}
return &cpuinfo_cores[index];
}
const struct cpuinfo_cluster* cpuinfo_get_cluster(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "cluster");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_clusters_count) {
return NULL;
}
return &cpuinfo_clusters[index];
}
const struct cpuinfo_package* cpuinfo_get_package(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "package");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_packages_count) {
return NULL;
}
return &cpuinfo_packages[index];
}
const struct cpuinfo_uarch_info* cpuinfo_get_uarch(uint32_t index) {
if (!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "uarch");
}
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
if CPUINFO_UNLIKELY(index >= cpuinfo_uarchs_count) {
return NULL;
}
return &cpuinfo_uarchs[index];
#else
if CPUINFO_UNLIKELY(index != 0) {
return NULL;
}
return &cpuinfo_global_uarch;
#endif
}
uint32_t cpuinfo_get_processors_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "processors_count");
}
return cpuinfo_processors_count;
}
uint32_t cpuinfo_get_cores_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "cores_count");
}
return cpuinfo_cores_count;
}
uint32_t cpuinfo_get_clusters_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "clusters_count");
}
return cpuinfo_clusters_count;
}
uint32_t cpuinfo_get_packages_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "packages_count");
}
return cpuinfo_packages_count;
}
uint32_t cpuinfo_get_uarchs_count(void) {
if (!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "uarchs_count");
}
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
return cpuinfo_uarchs_count;
#else
return 1;
#endif
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l1i_caches(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1i_caches");
}
return cpuinfo_cache[cpuinfo_cache_level_1i];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l1d_caches(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1d_caches");
}
return cpuinfo_cache[cpuinfo_cache_level_1d];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l2_caches(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l2_caches");
}
return cpuinfo_cache[cpuinfo_cache_level_2];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l3_caches(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l3_caches");
}
return cpuinfo_cache[cpuinfo_cache_level_3];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l4_caches(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l4_caches");
}
return cpuinfo_cache[cpuinfo_cache_level_4];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l1i_cache(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1i_cache");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cache_count[cpuinfo_cache_level_1i]) {
return NULL;
}
return &cpuinfo_cache[cpuinfo_cache_level_1i][index];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l1d_cache(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1d_cache");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cache_count[cpuinfo_cache_level_1d]) {
return NULL;
}
return &cpuinfo_cache[cpuinfo_cache_level_1d][index];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l2_cache(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l2_cache");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cache_count[cpuinfo_cache_level_2]) {
return NULL;
}
return &cpuinfo_cache[cpuinfo_cache_level_2][index];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l3_cache(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l3_cache");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cache_count[cpuinfo_cache_level_3]) {
return NULL;
}
return &cpuinfo_cache[cpuinfo_cache_level_3][index];
}
const struct cpuinfo_cache* CPUINFO_ABI cpuinfo_get_l4_cache(uint32_t index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l4_cache");
}
if CPUINFO_UNLIKELY(index >= cpuinfo_cache_count[cpuinfo_cache_level_4]) {
return NULL;
}
return &cpuinfo_cache[cpuinfo_cache_level_4][index];
}
uint32_t CPUINFO_ABI cpuinfo_get_l1i_caches_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1i_caches_count");
}
return cpuinfo_cache_count[cpuinfo_cache_level_1i];
}
uint32_t CPUINFO_ABI cpuinfo_get_l1d_caches_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l1d_caches_count");
}
return cpuinfo_cache_count[cpuinfo_cache_level_1d];
}
uint32_t CPUINFO_ABI cpuinfo_get_l2_caches_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l2_caches_count");
}
return cpuinfo_cache_count[cpuinfo_cache_level_2];
}
uint32_t CPUINFO_ABI cpuinfo_get_l3_caches_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l3_caches_count");
}
return cpuinfo_cache_count[cpuinfo_cache_level_3];
}
uint32_t CPUINFO_ABI cpuinfo_get_l4_caches_count(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "l4_caches_count");
}
return cpuinfo_cache_count[cpuinfo_cache_level_4];
}
uint32_t CPUINFO_ABI cpuinfo_get_max_cache_size(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "max_cache_size");
}
return cpuinfo_max_cache_size;
}
const struct cpuinfo_processor* CPUINFO_ABI cpuinfo_get_current_processor(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "current_processor");
}
#ifdef __linux__
/* Initializing this variable silences a MemorySanitizer error. */
unsigned cpu = 0;
if CPUINFO_UNLIKELY(syscall(__NR_getcpu, &cpu, NULL, NULL) != 0) {
return 0;
}
if CPUINFO_UNLIKELY((uint32_t) cpu >= cpuinfo_linux_cpu_max) {
return 0;
}
return cpuinfo_linux_cpu_to_processor_map[cpu];
#else
return NULL;
#endif
}
const struct cpuinfo_core* CPUINFO_ABI cpuinfo_get_current_core(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "current_core");
}
#ifdef __linux__
/* Initializing this variable silences a MemorySanitizer error. */
unsigned cpu = 0;
if CPUINFO_UNLIKELY(syscall(__NR_getcpu, &cpu, NULL, NULL) != 0) {
return 0;
}
if CPUINFO_UNLIKELY((uint32_t) cpu >= cpuinfo_linux_cpu_max) {
return 0;
}
return cpuinfo_linux_cpu_to_core_map[cpu];
#else
return NULL;
#endif
}
uint32_t CPUINFO_ABI cpuinfo_get_current_uarch_index(void) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "current_uarch_index");
}
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
#ifdef __linux__
if (cpuinfo_linux_cpu_to_uarch_index_map == NULL) {
/* Special case: avoid syscall on systems with only a single type of cores */
return 0;
}
/* General case */
/* Initializing this variable silences a MemorySanitizer error. */
unsigned cpu = 0;
if CPUINFO_UNLIKELY(syscall(__NR_getcpu, &cpu, NULL, NULL) != 0) {
return 0;
}
if CPUINFO_UNLIKELY((uint32_t) cpu >= cpuinfo_linux_cpu_max) {
return 0;
}
return cpuinfo_linux_cpu_to_uarch_index_map[cpu];
#else
/* Fallback: pretend to be on the big core. */
return 0;
#endif
#else
/* Only ARM/ARM64 processors may include cores of different types in the same package. */
return 0;
#endif
}
uint32_t CPUINFO_ABI cpuinfo_get_current_uarch_index_with_default(uint32_t default_uarch_index) {
if CPUINFO_UNLIKELY(!cpuinfo_is_initialized) {
cpuinfo_log_fatal("cpuinfo_get_%s called before cpuinfo is initialized", "current_uarch_index_with_default");
}
#if CPUINFO_ARCH_ARM || CPUINFO_ARCH_ARM64
#ifdef __linux__
if (cpuinfo_linux_cpu_to_uarch_index_map == NULL) {
/* Special case: avoid syscall on systems with only a single type of cores */
return 0;
}
/* General case */
/* Initializing this variable silences a MemorySanitizer error. */
unsigned cpu = 0;
if CPUINFO_UNLIKELY(syscall(__NR_getcpu, &cpu, NULL, NULL) != 0) {
return default_uarch_index;
}
if CPUINFO_UNLIKELY((uint32_t) cpu >= cpuinfo_linux_cpu_max) {
return default_uarch_index;
}
return cpuinfo_linux_cpu_to_uarch_index_map[cpu];
#else
/* Fallback: no API to query current core, use default uarch index. */
return default_uarch_index;
#endif
#else
/* Only ARM/ARM64 processors may include cores of different types in the same package. */
return 0;
#endif
}

20
3rdparty/cpuinfo/src/arm/android/api.h vendored Normal file
View File

@@ -0,0 +1,20 @@
#pragma once
#include <cpuinfo.h>
#include <cpuinfo/common.h>
#include <arm/api.h>
#include <arm/linux/api.h>
enum cpuinfo_android_chipset_property {
cpuinfo_android_chipset_property_proc_cpuinfo_hardware = 0,
cpuinfo_android_chipset_property_ro_product_board,
cpuinfo_android_chipset_property_ro_board_platform,
cpuinfo_android_chipset_property_ro_mediatek_platform,
cpuinfo_android_chipset_property_ro_arch,
cpuinfo_android_chipset_property_ro_chipname,
cpuinfo_android_chipset_property_ro_hardware_chipname,
cpuinfo_android_chipset_property_max,
};
CPUINFO_INTERNAL void cpuinfo_arm_android_parse_properties(
struct cpuinfo_android_properties properties[restrict static 1]);

View File

@@ -0,0 +1,67 @@
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <sys/system_properties.h>
#include <linux/api.h>
#include <arm/android/api.h>
#include <arm/linux/api.h>
#include <cpuinfo/log.h>
#if CPUINFO_MOCK
#include <cpuinfo-mock.h>
static struct cpuinfo_mock_property* cpuinfo_mock_properties = NULL;
void CPUINFO_ABI cpuinfo_mock_android_properties(struct cpuinfo_mock_property* properties) {
cpuinfo_log_info("Android properties mocking enabled");
cpuinfo_mock_properties = properties;
}
static int cpuinfo_android_property_get(const char* key, char* value) {
if (cpuinfo_mock_properties != NULL) {
for (const struct cpuinfo_mock_property* prop = cpuinfo_mock_properties; prop->key != NULL; prop++) {
if (strncmp(key, prop->key, CPUINFO_BUILD_PROP_NAME_MAX) == 0) {
strncpy(value, prop->value, CPUINFO_BUILD_PROP_VALUE_MAX);
return (int) strnlen(prop->value, CPUINFO_BUILD_PROP_VALUE_MAX);
}
}
}
*value = '\0';
return 0;
}
#else
static inline int cpuinfo_android_property_get(const char* key, char* value) {
return __system_property_get(key, value);
}
#endif
void cpuinfo_arm_android_parse_properties(struct cpuinfo_android_properties properties[restrict static 1]) {
const int ro_product_board_length =
cpuinfo_android_property_get("ro.product.board", properties->ro_product_board);
cpuinfo_log_debug("read ro.product.board = \"%.*s\"", ro_product_board_length, properties->ro_product_board);
const int ro_board_platform_length =
cpuinfo_android_property_get("ro.board.platform", properties->ro_board_platform);
cpuinfo_log_debug("read ro.board.platform = \"%.*s\"", ro_board_platform_length, properties->ro_board_platform);
const int ro_mediatek_platform_length =
cpuinfo_android_property_get("ro.mediatek.platform", properties->ro_mediatek_platform);
cpuinfo_log_debug("read ro.mediatek.platform = \"%.*s\"",
ro_mediatek_platform_length, properties->ro_mediatek_platform);
const int ro_arch_length =
cpuinfo_android_property_get("ro.arch", properties->ro_arch);
cpuinfo_log_debug("read ro.arch = \"%.*s\"", ro_arch_length, properties->ro_arch);
const int ro_chipname_length =
cpuinfo_android_property_get("ro.chipname", properties->ro_chipname);
cpuinfo_log_debug("read ro.chipname = \"%.*s\"", ro_chipname_length, properties->ro_chipname);
const int ro_hardware_chipname_length =
cpuinfo_android_property_get("ro.hardware.chipname", properties->ro_hardware_chipname);
cpuinfo_log_debug("read ro.hardware.chipname = \"%.*s\"", ro_hardware_chipname_length, properties->ro_hardware_chipname);
}

122
3rdparty/cpuinfo/src/arm/api.h vendored Normal file
View File

@@ -0,0 +1,122 @@
#pragma once
#include <stdbool.h>
#include <stdint.h>
#include <cpuinfo.h>
#include <cpuinfo/common.h>
enum cpuinfo_arm_chipset_vendor {
cpuinfo_arm_chipset_vendor_unknown = 0,
cpuinfo_arm_chipset_vendor_qualcomm,
cpuinfo_arm_chipset_vendor_mediatek,
cpuinfo_arm_chipset_vendor_samsung,
cpuinfo_arm_chipset_vendor_hisilicon,
cpuinfo_arm_chipset_vendor_actions,
cpuinfo_arm_chipset_vendor_allwinner,
cpuinfo_arm_chipset_vendor_amlogic,
cpuinfo_arm_chipset_vendor_broadcom,
cpuinfo_arm_chipset_vendor_lg,
cpuinfo_arm_chipset_vendor_leadcore,
cpuinfo_arm_chipset_vendor_marvell,
cpuinfo_arm_chipset_vendor_mstar,
cpuinfo_arm_chipset_vendor_novathor,
cpuinfo_arm_chipset_vendor_nvidia,
cpuinfo_arm_chipset_vendor_pinecone,
cpuinfo_arm_chipset_vendor_renesas,
cpuinfo_arm_chipset_vendor_rockchip,
cpuinfo_arm_chipset_vendor_spreadtrum,
cpuinfo_arm_chipset_vendor_telechips,
cpuinfo_arm_chipset_vendor_texas_instruments,
cpuinfo_arm_chipset_vendor_wondermedia,
cpuinfo_arm_chipset_vendor_max,
};
enum cpuinfo_arm_chipset_series {
cpuinfo_arm_chipset_series_unknown = 0,
cpuinfo_arm_chipset_series_qualcomm_qsd,
cpuinfo_arm_chipset_series_qualcomm_msm,
cpuinfo_arm_chipset_series_qualcomm_apq,
cpuinfo_arm_chipset_series_qualcomm_snapdragon,
cpuinfo_arm_chipset_series_mediatek_mt,
cpuinfo_arm_chipset_series_samsung_exynos,
cpuinfo_arm_chipset_series_hisilicon_k3v,
cpuinfo_arm_chipset_series_hisilicon_hi,
cpuinfo_arm_chipset_series_hisilicon_kirin,
cpuinfo_arm_chipset_series_actions_atm,
cpuinfo_arm_chipset_series_allwinner_a,
cpuinfo_arm_chipset_series_amlogic_aml,
cpuinfo_arm_chipset_series_amlogic_s,
cpuinfo_arm_chipset_series_broadcom_bcm,
cpuinfo_arm_chipset_series_lg_nuclun,
cpuinfo_arm_chipset_series_leadcore_lc,
cpuinfo_arm_chipset_series_marvell_pxa,
cpuinfo_arm_chipset_series_mstar_6a,
cpuinfo_arm_chipset_series_novathor_u,
cpuinfo_arm_chipset_series_nvidia_tegra_t,
cpuinfo_arm_chipset_series_nvidia_tegra_ap,
cpuinfo_arm_chipset_series_nvidia_tegra_sl,
cpuinfo_arm_chipset_series_pinecone_surge_s,
cpuinfo_arm_chipset_series_renesas_mp,
cpuinfo_arm_chipset_series_rockchip_rk,
cpuinfo_arm_chipset_series_spreadtrum_sc,
cpuinfo_arm_chipset_series_telechips_tcc,
cpuinfo_arm_chipset_series_texas_instruments_omap,
cpuinfo_arm_chipset_series_wondermedia_wm,
cpuinfo_arm_chipset_series_max,
};
#define CPUINFO_ARM_CHIPSET_SUFFIX_MAX 8
struct cpuinfo_arm_chipset {
enum cpuinfo_arm_chipset_vendor vendor;
enum cpuinfo_arm_chipset_series series;
uint32_t model;
char suffix[CPUINFO_ARM_CHIPSET_SUFFIX_MAX];
};
#define CPUINFO_ARM_CHIPSET_NAME_MAX CPUINFO_PACKAGE_NAME_MAX
#ifndef __cplusplus
CPUINFO_INTERNAL void cpuinfo_arm_chipset_to_string(
const struct cpuinfo_arm_chipset chipset[restrict static 1],
char name[restrict static CPUINFO_ARM_CHIPSET_NAME_MAX]);
CPUINFO_INTERNAL void cpuinfo_arm_fixup_chipset(
struct cpuinfo_arm_chipset chipset[restrict static 1], uint32_t cores, uint32_t max_cpu_freq_max);
CPUINFO_INTERNAL void cpuinfo_arm_decode_vendor_uarch(
uint32_t midr,
#if CPUINFO_ARCH_ARM
bool has_vfpv4,
#endif
enum cpuinfo_vendor vendor[restrict static 1],
enum cpuinfo_uarch uarch[restrict static 1]);
CPUINFO_INTERNAL void cpuinfo_arm_decode_cache(
enum cpuinfo_uarch uarch,
uint32_t cluster_cores,
uint32_t midr,
const struct cpuinfo_arm_chipset chipset[restrict static 1],
uint32_t cluster_id,
uint32_t arch_version,
struct cpuinfo_cache l1i[restrict static 1],
struct cpuinfo_cache l1d[restrict static 1],
struct cpuinfo_cache l2[restrict static 1],
struct cpuinfo_cache l3[restrict static 1]);
CPUINFO_INTERNAL uint32_t cpuinfo_arm_compute_max_cache_size(
const struct cpuinfo_processor processor[restrict static 1]);
#else /* defined(__cplusplus) */
CPUINFO_INTERNAL void cpuinfo_arm_decode_cache(
enum cpuinfo_uarch uarch,
uint32_t cluster_cores,
uint32_t midr,
const struct cpuinfo_arm_chipset chipset[1],
uint32_t cluster_id,
uint32_t arch_version,
struct cpuinfo_cache l1i[1],
struct cpuinfo_cache l1d[1],
struct cpuinfo_cache l2[1],
struct cpuinfo_cache l3[1]);
#endif

1676
3rdparty/cpuinfo/src/arm/cache.c vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,267 @@
#include <stdint.h>
#if CPUINFO_MOCK
#include <cpuinfo-mock.h>
#endif
#include <arm/linux/api.h>
#include <arm/linux/cp.h>
#include <arm/midr.h>
#include <cpuinfo/log.h>
#if CPUINFO_MOCK
uint32_t cpuinfo_arm_fpsid = 0;
uint32_t cpuinfo_arm_mvfr0 = 0;
uint32_t cpuinfo_arm_wcid = 0;
void cpuinfo_set_fpsid(uint32_t fpsid) {
cpuinfo_arm_fpsid = fpsid;
}
void cpuinfo_set_wcid(uint32_t wcid) {
cpuinfo_arm_wcid = wcid;
}
#endif
void cpuinfo_arm_linux_decode_isa_from_proc_cpuinfo(
uint32_t features,
uint32_t features2,
uint32_t midr,
uint32_t architecture_version,
uint32_t architecture_flags,
const struct cpuinfo_arm_chipset chipset[restrict static 1],
struct cpuinfo_arm_isa isa[restrict static 1])
{
if (architecture_version >= 8) {
/*
* ARMv7 code running on ARMv8: IDIV, VFP, NEON are always supported,
* but may be not reported in /proc/cpuinfo features.
*/
isa->armv5e = true;
isa->armv6 = true;
isa->armv6k = true;
isa->armv7 = true;
isa->armv7mp = true;
isa->armv8 = true;
isa->thumb = true;
isa->thumb2 = true;
isa->idiv = true;
isa->vfpv3 = true;
isa->d32 = true;
isa->fp16 = true;
isa->fma = true;
isa->neon = true;
/*
* NEON FP16 compute extension and VQRDMLAH/VQRDMLSH instructions are not indicated in /proc/cpuinfo.
* Use a MIDR-based heuristic to whitelist processors known to support it:
* - Processors with Cortex-A55 cores
* - Processors with Cortex-A65 cores
* - Processors with Cortex-A75 cores
* - Processors with Cortex-A76 cores
* - Processors with Cortex-A77 cores
* - Processors with Exynos M4 cores
* - Processors with Exynos M5 cores
* - Neoverse N1 cores
*/
if (chipset->series == cpuinfo_arm_chipset_series_samsung_exynos && chipset->model == 9810) {
/* Only little cores of Exynos 9810 support FP16 & RDM */
cpuinfo_log_warning("FP16 arithmetics and RDM disabled: only little cores in Exynos 9810 support these extensions");
} else {
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x4100D050): /* Cortex-A55 */
case UINT32_C(0x4100D060): /* Cortex-A65 */
case UINT32_C(0x4100D0B0): /* Cortex-A76 */
case UINT32_C(0x4100D0C0): /* Neoverse N1 */
case UINT32_C(0x4100D0D0): /* Cortex-A77 */
case UINT32_C(0x4100D0E0): /* Cortex-A76AE */
case UINT32_C(0x4800D400): /* Cortex-A76 (HiSilicon) */
case UINT32_C(0x51008020): /* Kryo 385 Gold (Cortex-A75) */
case UINT32_C(0x51008030): /* Kryo 385 Silver (Cortex-A55) */
case UINT32_C(0x51008040): /* Kryo 485 Gold (Cortex-A76) */
case UINT32_C(0x51008050): /* Kryo 485 Silver (Cortex-A55) */
case UINT32_C(0x53000030): /* Exynos M4 */
case UINT32_C(0x53000040): /* Exynos M5 */
isa->fp16arith = true;
isa->rdm = true;
break;
}
}
/*
* NEON VDOT instructions are not indicated in /proc/cpuinfo.
* Use a MIDR-based heuristic to whitelist processors known to support it.
*/
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x4100D0B0): /* Cortex-A76 */
case UINT32_C(0x4100D0D0): /* Cortex-A77 */
case UINT32_C(0x4100D0E0): /* Cortex-A76AE */
case UINT32_C(0x4800D400): /* Cortex-A76 (HiSilicon) */
case UINT32_C(0x51008040): /* Kryo 485 Gold (Cortex-A76) */
case UINT32_C(0x51008050): /* Kryo 485 Silver (Cortex-A55) */
case UINT32_C(0x53000030): /* Exynos-M4 */
case UINT32_C(0x53000040): /* Exynos-M5 */
isa->dot = true;
break;
case UINT32_C(0x4100D050): /* Cortex A55: revision 1 or later only */
isa->dot = !!(midr_get_variant(midr) >= 1);
break;
case UINT32_C(0x4100D0A0): /* Cortex A75: revision 2 or later only */
isa->dot = !!(midr_get_variant(midr) >= 2);
break;
}
} else {
/* ARMv7 or lower: use feature flags to detect optional features */
/*
* ARM11 (ARM 1136/1156/1176/11 MPCore) processors can report v7 architecture
* even though they support only ARMv6 instruction set.
*/
if (architecture_version == 7 && midr_is_arm11(midr)) {
cpuinfo_log_warning("kernel-reported architecture ARMv7 ignored due to mismatch with processor microarchitecture (ARM11)");
architecture_version = 6;
}
if (architecture_version < 7) {
const uint32_t armv7_features_mask = CPUINFO_ARM_LINUX_FEATURE_VFPV3 | CPUINFO_ARM_LINUX_FEATURE_VFPV3D16 | CPUINFO_ARM_LINUX_FEATURE_VFPD32 |
CPUINFO_ARM_LINUX_FEATURE_VFPV4 | CPUINFO_ARM_LINUX_FEATURE_NEON | CPUINFO_ARM_LINUX_FEATURE_IDIVT | CPUINFO_ARM_LINUX_FEATURE_IDIVA;
if (features & armv7_features_mask) {
architecture_version = 7;
}
}
if ((architecture_version >= 6) || (features & CPUINFO_ARM_LINUX_FEATURE_EDSP) || (architecture_flags & CPUINFO_ARM_LINUX_ARCH_E)) {
isa->armv5e = true;
}
if (architecture_version >= 6) {
isa->armv6 = true;
}
if (architecture_version >= 7) {
isa->armv6k = true;
isa->armv7 = true;
/*
* ARMv7 MP extension (PLDW instruction) is not indicated in /proc/cpuinfo.
* Use heuristic list of supporting processors:
* - Processors supporting UDIV/SDIV instructions ("idiva" + "idivt" features in /proc/cpuinfo)
* - Cortex-A5
* - Cortex-A9
* - Dual-Core Scorpion
* - Krait (supports UDIV/SDIV, but kernels may not report it in /proc/cpuinfo)
*
* TODO: check single-core Qualcomm Scorpion.
*/
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x4100C050): /* Cortex-A5 */
case UINT32_C(0x4100C090): /* Cortex-A9 */
case UINT32_C(0x510002D0): /* Scorpion (dual-core) */
case UINT32_C(0x510004D0): /* Krait (dual-core) */
case UINT32_C(0x510006F0): /* Krait (quad-core) */
isa->armv7mp = true;
break;
default:
/* In practice IDIV instruction implies ARMv7+MP ISA */
isa->armv7mp = (features & CPUINFO_ARM_LINUX_FEATURE_IDIV) == CPUINFO_ARM_LINUX_FEATURE_IDIV;
break;
}
}
if (features & CPUINFO_ARM_LINUX_FEATURE_IWMMXT) {
const uint32_t wcid = read_wcid();
cpuinfo_log_debug("WCID = 0x%08"PRIx32, wcid);
const uint32_t coprocessor_type = (wcid >> 8) & UINT32_C(0xFF);
if (coprocessor_type >= 0x10) {
isa->wmmx = true;
if (coprocessor_type >= 0x20) {
isa->wmmx2 = true;
}
} else {
cpuinfo_log_warning("WMMX ISA disabled: OS reported iwmmxt feature, "
"but WCID coprocessor type 0x%"PRIx32" indicates no WMMX support",
coprocessor_type);
}
}
if ((features & CPUINFO_ARM_LINUX_FEATURE_THUMB) || (architecture_flags & CPUINFO_ARM_LINUX_ARCH_T)) {
isa->thumb = true;
/*
* There is no separate feature flag for Thumb 2.
* All ARMv7 processors and ARM 1156 support Thumb 2.
*/
if (architecture_version >= 7 || midr_is_arm1156(midr)) {
isa->thumb2 = true;
}
}
if (features & CPUINFO_ARM_LINUX_FEATURE_THUMBEE) {
isa->thumbee = true;
}
if ((features & CPUINFO_ARM_LINUX_FEATURE_JAVA) || (architecture_flags & CPUINFO_ARM_LINUX_ARCH_J)) {
isa->jazelle = true;
}
/* Qualcomm Krait may have buggy kernel configuration that doesn't report IDIV */
if ((features & CPUINFO_ARM_LINUX_FEATURE_IDIV) == CPUINFO_ARM_LINUX_FEATURE_IDIV || midr_is_krait(midr)) {
isa->idiv = true;
}
const uint32_t vfp_mask = \
CPUINFO_ARM_LINUX_FEATURE_VFP | CPUINFO_ARM_LINUX_FEATURE_VFPV3 | CPUINFO_ARM_LINUX_FEATURE_VFPV3D16 | \
CPUINFO_ARM_LINUX_FEATURE_VFPD32 | CPUINFO_ARM_LINUX_FEATURE_VFPV4 | CPUINFO_ARM_LINUX_FEATURE_NEON;
if (features & vfp_mask) {
const uint32_t vfpv3_mask = CPUINFO_ARM_LINUX_FEATURE_VFPV3 | CPUINFO_ARM_LINUX_FEATURE_VFPV3D16 | \
CPUINFO_ARM_LINUX_FEATURE_VFPD32 | CPUINFO_ARM_LINUX_FEATURE_VFPV4 | CPUINFO_ARM_LINUX_FEATURE_NEON;
if ((architecture_version >= 7) || (features & vfpv3_mask)) {
isa->vfpv3 = true;
const uint32_t d32_mask = CPUINFO_ARM_LINUX_FEATURE_VFPD32 | CPUINFO_ARM_LINUX_FEATURE_NEON;
if (features & d32_mask) {
isa->d32 = true;
}
} else {
#if defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_8A__) || defined(__ARM_ARCH) && (__ARM_ARCH >= 7)
isa->vfpv3 = true;
#else
const uint32_t fpsid = read_fpsid();
cpuinfo_log_debug("FPSID = 0x%08"PRIx32, fpsid);
const uint32_t subarchitecture = (fpsid >> 16) & UINT32_C(0x7F);
if (subarchitecture >= 0x01) {
isa->vfpv2 = true;
}
#endif
}
}
if (features & CPUINFO_ARM_LINUX_FEATURE_NEON) {
isa->neon = true;
}
/*
* There is no separate feature flag for FP16 support.
* VFPv4 implies VFPv3-FP16 support (and in practice, NEON-HP as well).
* Additionally, ARM Cortex-A9 and Qualcomm Scorpion support FP16.
*/
if ((features & CPUINFO_ARM_LINUX_FEATURE_VFPV4) || midr_is_cortex_a9(midr) || midr_is_scorpion(midr)) {
isa->fp16 = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_VFPV4) {
isa->fma = true;
}
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_AES) {
isa->aes = true;
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_PMULL) {
isa->pmull = true;
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_SHA1) {
isa->sha1 = true;
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_SHA2) {
isa->sha2 = true;
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_CRC32) {
isa->crc32 = true;
}
}

View File

@@ -0,0 +1,127 @@
#include <stdint.h>
#include <arm/linux/api.h>
#include <cpuinfo/log.h>
void cpuinfo_arm64_linux_decode_isa_from_proc_cpuinfo(
uint32_t features,
uint32_t features2,
uint32_t midr,
const struct cpuinfo_arm_chipset chipset[restrict static 1],
struct cpuinfo_arm_isa isa[restrict static 1])
{
if (features & CPUINFO_ARM_LINUX_FEATURE_AES) {
isa->aes = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_PMULL) {
isa->pmull = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_SHA1) {
isa->sha1 = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_SHA2) {
isa->sha2 = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_CRC32) {
isa->crc32 = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_ATOMICS) {
isa->atomics = true;
}
/*
* Some phones ship with an old kernel configuration that doesn't report NEON FP16 compute extension and SQRDMLAH/SQRDMLSH/UQRDMLAH/UQRDMLSH instructions.
* Use a MIDR-based heuristic to whitelist processors known to support it:
* - Processors with Cortex-A55 cores
* - Processors with Cortex-A65 cores
* - Processors with Cortex-A75 cores
* - Processors with Cortex-A76 cores
* - Processors with Cortex-A77 cores
* - Processors with Exynos M4 cores
* - Processors with Exynos M5 cores
* - Neoverse N1 cores
*/
if (chipset->series == cpuinfo_arm_chipset_series_samsung_exynos && chipset->model == 9810) {
/* Exynos 9810 reports that it supports FP16 compute, but in fact only little cores do */
cpuinfo_log_warning("FP16 arithmetics and RDM disabled: only little cores in Exynos 9810 support these extensions");
} else {
const uint32_t fp16arith_mask = CPUINFO_ARM_LINUX_FEATURE_FPHP | CPUINFO_ARM_LINUX_FEATURE_ASIMDHP;
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x4100D050): /* Cortex-A55 */
case UINT32_C(0x4100D060): /* Cortex-A65 */
case UINT32_C(0x4100D0B0): /* Cortex-A76 */
case UINT32_C(0x4100D0C0): /* Neoverse N1 */
case UINT32_C(0x4100D0D0): /* Cortex-A77 */
case UINT32_C(0x4100D0E0): /* Cortex-A76AE */
case UINT32_C(0x4800D400): /* Cortex-A76 (HiSilicon) */
case UINT32_C(0x51008020): /* Kryo 385 Gold (Cortex-A75) */
case UINT32_C(0x51008030): /* Kryo 385 Silver (Cortex-A55) */
case UINT32_C(0x51008040): /* Kryo 485 Gold (Cortex-A76) */
case UINT32_C(0x51008050): /* Kryo 485 Silver (Cortex-A55) */
case UINT32_C(0x53000030): /* Exynos M4 */
case UINT32_C(0x53000040): /* Exynos M5 */
isa->fp16arith = true;
isa->rdm = true;
break;
default:
if ((features & fp16arith_mask) == fp16arith_mask) {
isa->fp16arith = true;
} else if (features & CPUINFO_ARM_LINUX_FEATURE_FPHP) {
cpuinfo_log_warning("FP16 arithmetics disabled: detected support only for scalar operations");
} else if (features & CPUINFO_ARM_LINUX_FEATURE_ASIMDHP) {
cpuinfo_log_warning("FP16 arithmetics disabled: detected support only for SIMD operations");
}
if (features & CPUINFO_ARM_LINUX_FEATURE_ASIMDRDM) {
isa->rdm = true;
}
break;
}
}
/*
* Many phones ship with an old kernel configuration that doesn't report UDOT/SDOT instructions.
* Use a MIDR-based heuristic to whitelist processors known to support it.
*/
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x4100D060): /* Cortex-A65 */
case UINT32_C(0x4100D0B0): /* Cortex-A76 */
case UINT32_C(0x4100D0C0): /* Neoverse N1 */
case UINT32_C(0x4100D0D0): /* Cortex-A77 */
case UINT32_C(0x4100D0E0): /* Cortex-A76AE */
case UINT32_C(0x4100D4A0): /* Neoverse E1 */
case UINT32_C(0x4800D400): /* Cortex-A76 (HiSilicon) */
case UINT32_C(0x51008040): /* Kryo 485 Gold (Cortex-A76) */
case UINT32_C(0x51008050): /* Kryo 485 Silver (Cortex-A55) */
case UINT32_C(0x53000030): /* Exynos-M4 */
case UINT32_C(0x53000040): /* Exynos-M5 */
isa->dot = true;
break;
case UINT32_C(0x4100D050): /* Cortex A55: revision 1 or later only */
isa->dot = !!(midr_get_variant(midr) >= 1);
break;
case UINT32_C(0x4100D0A0): /* Cortex A75: revision 2 or later only */
isa->dot = !!(midr_get_variant(midr) >= 2);
break;
default:
if (features & CPUINFO_ARM_LINUX_FEATURE_ASIMDDP) {
isa->dot = true;
}
break;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_JSCVT) {
isa->jscvt = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_JSCVT) {
isa->jscvt = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_FCMA) {
isa->fcma = true;
}
if (features & CPUINFO_ARM_LINUX_FEATURE_SVE) {
isa->sve = true;
}
if (features2 & CPUINFO_ARM_LINUX_FEATURE2_SVE2) {
isa->sve2 = true;
}
}

384
3rdparty/cpuinfo/src/arm/linux/api.h vendored Normal file
View File

@@ -0,0 +1,384 @@
#pragma once
#include <stdbool.h>
#include <stdint.h>
#include <cpuinfo.h>
#include <cpuinfo/common.h>
#include <arm/midr.h>
#include <arm/api.h>
#include <linux/api.h>
/* No hard limit in the kernel, maximum length observed on non-rogue kernels is 64 */
#define CPUINFO_HARDWARE_VALUE_MAX 64
/* No hard limit in the kernel, maximum length on Raspberry Pi is 8. Add 1 symbol to detect overly large revision strings */
#define CPUINFO_REVISION_VALUE_MAX 9
#ifdef __ANDROID__
/* As per include/sys/system_properties.h in Android NDK */
#define CPUINFO_BUILD_PROP_NAME_MAX 32
#define CPUINFO_BUILD_PROP_VALUE_MAX 92
struct cpuinfo_android_properties {
char proc_cpuinfo_hardware[CPUINFO_HARDWARE_VALUE_MAX];
char ro_product_board[CPUINFO_BUILD_PROP_VALUE_MAX];
char ro_board_platform[CPUINFO_BUILD_PROP_VALUE_MAX];
char ro_mediatek_platform[CPUINFO_BUILD_PROP_VALUE_MAX];
char ro_arch[CPUINFO_BUILD_PROP_VALUE_MAX];
char ro_chipname[CPUINFO_BUILD_PROP_VALUE_MAX];
char ro_hardware_chipname[CPUINFO_BUILD_PROP_VALUE_MAX];
};
#endif
#define CPUINFO_ARM_LINUX_ARCH_T UINT32_C(0x00000001)
#define CPUINFO_ARM_LINUX_ARCH_E UINT32_C(0x00000002)
#define CPUINFO_ARM_LINUX_ARCH_J UINT32_C(0x00000004)
#define CPUINFO_ARM_LINUX_ARCH_TE UINT32_C(0x00000003)
#define CPUINFO_ARM_LINUX_ARCH_TEJ UINT32_C(0x00000007)
struct cpuinfo_arm_linux_proc_cpuinfo_cache {
uint32_t i_size;
uint32_t i_assoc;
uint32_t i_line_length;
uint32_t i_sets;
uint32_t d_size;
uint32_t d_assoc;
uint32_t d_line_length;
uint32_t d_sets;
};
#if CPUINFO_ARCH_ARM
/* arch/arm/include/uapi/asm/hwcap.h */
#define CPUINFO_ARM_LINUX_FEATURE_SWP UINT32_C(0x00000001)
#define CPUINFO_ARM_LINUX_FEATURE_HALF UINT32_C(0x00000002)
#define CPUINFO_ARM_LINUX_FEATURE_THUMB UINT32_C(0x00000004)
#define CPUINFO_ARM_LINUX_FEATURE_26BIT UINT32_C(0x00000008)
#define CPUINFO_ARM_LINUX_FEATURE_FASTMULT UINT32_C(0x00000010)
#define CPUINFO_ARM_LINUX_FEATURE_FPA UINT32_C(0x00000020)
#define CPUINFO_ARM_LINUX_FEATURE_VFP UINT32_C(0x00000040)
#define CPUINFO_ARM_LINUX_FEATURE_EDSP UINT32_C(0x00000080)
#define CPUINFO_ARM_LINUX_FEATURE_JAVA UINT32_C(0x00000100)
#define CPUINFO_ARM_LINUX_FEATURE_IWMMXT UINT32_C(0x00000200)
#define CPUINFO_ARM_LINUX_FEATURE_CRUNCH UINT32_C(0x00000400)
#define CPUINFO_ARM_LINUX_FEATURE_THUMBEE UINT32_C(0x00000800)
#define CPUINFO_ARM_LINUX_FEATURE_NEON UINT32_C(0x00001000)
#define CPUINFO_ARM_LINUX_FEATURE_VFPV3 UINT32_C(0x00002000)
#define CPUINFO_ARM_LINUX_FEATURE_VFPV3D16 UINT32_C(0x00004000) /* Also set for VFPv4 with 16 double-precision registers */
#define CPUINFO_ARM_LINUX_FEATURE_TLS UINT32_C(0x00008000)
#define CPUINFO_ARM_LINUX_FEATURE_VFPV4 UINT32_C(0x00010000)
#define CPUINFO_ARM_LINUX_FEATURE_IDIVA UINT32_C(0x00020000)
#define CPUINFO_ARM_LINUX_FEATURE_IDIVT UINT32_C(0x00040000)
#define CPUINFO_ARM_LINUX_FEATURE_IDIV UINT32_C(0x00060000)
#define CPUINFO_ARM_LINUX_FEATURE_VFPD32 UINT32_C(0x00080000)
#define CPUINFO_ARM_LINUX_FEATURE_LPAE UINT32_C(0x00100000)
#define CPUINFO_ARM_LINUX_FEATURE_EVTSTRM UINT32_C(0x00200000)
#define CPUINFO_ARM_LINUX_FEATURE2_AES UINT32_C(0x00000001)
#define CPUINFO_ARM_LINUX_FEATURE2_PMULL UINT32_C(0x00000002)
#define CPUINFO_ARM_LINUX_FEATURE2_SHA1 UINT32_C(0x00000004)
#define CPUINFO_ARM_LINUX_FEATURE2_SHA2 UINT32_C(0x00000008)
#define CPUINFO_ARM_LINUX_FEATURE2_CRC32 UINT32_C(0x00000010)
#elif CPUINFO_ARCH_ARM64
/* arch/arm64/include/uapi/asm/hwcap.h */
#define CPUINFO_ARM_LINUX_FEATURE_FP UINT32_C(0x00000001)
#define CPUINFO_ARM_LINUX_FEATURE_ASIMD UINT32_C(0x00000002)
#define CPUINFO_ARM_LINUX_FEATURE_EVTSTRM UINT32_C(0x00000004)
#define CPUINFO_ARM_LINUX_FEATURE_AES UINT32_C(0x00000008)
#define CPUINFO_ARM_LINUX_FEATURE_PMULL UINT32_C(0x00000010)
#define CPUINFO_ARM_LINUX_FEATURE_SHA1 UINT32_C(0x00000020)
#define CPUINFO_ARM_LINUX_FEATURE_SHA2 UINT32_C(0x00000040)
#define CPUINFO_ARM_LINUX_FEATURE_CRC32 UINT32_C(0x00000080)
#define CPUINFO_ARM_LINUX_FEATURE_ATOMICS UINT32_C(0x00000100)
#define CPUINFO_ARM_LINUX_FEATURE_FPHP UINT32_C(0x00000200)
#define CPUINFO_ARM_LINUX_FEATURE_ASIMDHP UINT32_C(0x00000400)
#define CPUINFO_ARM_LINUX_FEATURE_CPUID UINT32_C(0x00000800)
#define CPUINFO_ARM_LINUX_FEATURE_ASIMDRDM UINT32_C(0x00001000)
#define CPUINFO_ARM_LINUX_FEATURE_JSCVT UINT32_C(0x00002000)
#define CPUINFO_ARM_LINUX_FEATURE_FCMA UINT32_C(0x00004000)
#define CPUINFO_ARM_LINUX_FEATURE_LRCPC UINT32_C(0x00008000)
#define CPUINFO_ARM_LINUX_FEATURE_DCPOP UINT32_C(0x00010000)
#define CPUINFO_ARM_LINUX_FEATURE_SHA3 UINT32_C(0x00020000)
#define CPUINFO_ARM_LINUX_FEATURE_SM3 UINT32_C(0x00040000)
#define CPUINFO_ARM_LINUX_FEATURE_SM4 UINT32_C(0x00080000)
#define CPUINFO_ARM_LINUX_FEATURE_ASIMDDP UINT32_C(0x00100000)
#define CPUINFO_ARM_LINUX_FEATURE_SHA512 UINT32_C(0x00200000)
#define CPUINFO_ARM_LINUX_FEATURE_SVE UINT32_C(0x00400000)
#define CPUINFO_ARM_LINUX_FEATURE_ASIMDFHM UINT32_C(0x00800000)
#define CPUINFO_ARM_LINUX_FEATURE_DIT UINT32_C(0x01000000)
#define CPUINFO_ARM_LINUX_FEATURE_USCAT UINT32_C(0x02000000)
#define CPUINFO_ARM_LINUX_FEATURE_ILRCPC UINT32_C(0x04000000)
#define CPUINFO_ARM_LINUX_FEATURE_FLAGM UINT32_C(0x08000000)
#define CPUINFO_ARM_LINUX_FEATURE_SSBS UINT32_C(0x10000000)
#define CPUINFO_ARM_LINUX_FEATURE_SB UINT32_C(0x20000000)
#define CPUINFO_ARM_LINUX_FEATURE_PACA UINT32_C(0x40000000)
#define CPUINFO_ARM_LINUX_FEATURE_PACG UINT32_C(0x80000000)
#define CPUINFO_ARM_LINUX_FEATURE2_DCPODP UINT32_C(0x00000001)
#define CPUINFO_ARM_LINUX_FEATURE2_SVE2 UINT32_C(0x00000002)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEAES UINT32_C(0x00000004)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEPMULL UINT32_C(0x00000008)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEBITPERM UINT32_C(0x00000010)
#define CPUINFO_ARM_LINUX_FEATURE2_SVESHA3 UINT32_C(0x00000020)
#define CPUINFO_ARM_LINUX_FEATURE2_SVESM4 UINT32_C(0x00000040)
#define CPUINFO_ARM_LINUX_FEATURE2_FLAGM2 UINT32_C(0x00000080)
#define CPUINFO_ARM_LINUX_FEATURE2_FRINT UINT32_C(0x00000100)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEI8MM UINT32_C(0x00000200)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEF32MM UINT32_C(0x00000400)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEF64MM UINT32_C(0x00000800)
#define CPUINFO_ARM_LINUX_FEATURE2_SVEBF16 UINT32_C(0x00001000)
#define CPUINFO_ARM_LINUX_FEATURE2_I8MM UINT32_C(0x00002000)
#define CPUINFO_ARM_LINUX_FEATURE2_BF16 UINT32_C(0x00004000)
#define CPUINFO_ARM_LINUX_FEATURE2_DGH UINT32_C(0x00008000)
#define CPUINFO_ARM_LINUX_FEATURE2_RNG UINT32_C(0x00010000)
#define CPUINFO_ARM_LINUX_FEATURE2_BTI UINT32_C(0x00020000)
#endif
#define CPUINFO_ARM_LINUX_VALID_ARCHITECTURE UINT32_C(0x00010000)
#define CPUINFO_ARM_LINUX_VALID_IMPLEMENTER UINT32_C(0x00020000)
#define CPUINFO_ARM_LINUX_VALID_VARIANT UINT32_C(0x00040000)
#define CPUINFO_ARM_LINUX_VALID_PART UINT32_C(0x00080000)
#define CPUINFO_ARM_LINUX_VALID_REVISION UINT32_C(0x00100000)
#define CPUINFO_ARM_LINUX_VALID_PROCESSOR UINT32_C(0x00200000)
#define CPUINFO_ARM_LINUX_VALID_FEATURES UINT32_C(0x00400000)
#if CPUINFO_ARCH_ARM
#define CPUINFO_ARM_LINUX_VALID_ICACHE_SIZE UINT32_C(0x01000000)
#define CPUINFO_ARM_LINUX_VALID_ICACHE_SETS UINT32_C(0x02000000)
#define CPUINFO_ARM_LINUX_VALID_ICACHE_WAYS UINT32_C(0x04000000)
#define CPUINFO_ARM_LINUX_VALID_ICACHE_LINE UINT32_C(0x08000000)
#define CPUINFO_ARM_LINUX_VALID_DCACHE_SIZE UINT32_C(0x10000000)
#define CPUINFO_ARM_LINUX_VALID_DCACHE_SETS UINT32_C(0x20000000)
#define CPUINFO_ARM_LINUX_VALID_DCACHE_WAYS UINT32_C(0x40000000)
#define CPUINFO_ARM_LINUX_VALID_DCACHE_LINE UINT32_C(0x80000000)
#endif
#define CPUINFO_ARM_LINUX_VALID_INFO UINT32_C(0x007F0000)
#define CPUINFO_ARM_LINUX_VALID_MIDR UINT32_C(0x003F0000)
#if CPUINFO_ARCH_ARM
#define CPUINFO_ARM_LINUX_VALID_ICACHE UINT32_C(0x0F000000)
#define CPUINFO_ARM_LINUX_VALID_DCACHE UINT32_C(0xF0000000)
#define CPUINFO_ARM_LINUX_VALID_CACHE_LINE UINT32_C(0x88000000)
#endif
struct cpuinfo_arm_linux_processor {
uint32_t architecture_version;
#if CPUINFO_ARCH_ARM
uint32_t architecture_flags;
struct cpuinfo_arm_linux_proc_cpuinfo_cache proc_cpuinfo_cache;
#endif
uint32_t features;
uint32_t features2;
/**
* Main ID Register value.
*/
uint32_t midr;
enum cpuinfo_vendor vendor;
enum cpuinfo_uarch uarch;
uint32_t uarch_index;
/**
* ID of the physical package which includes this logical processor.
* The value is parsed from /sys/devices/system/cpu/cpu<N>/topology/physical_package_id
*/
uint32_t package_id;
/**
* Minimum processor ID on the package which includes this logical processor.
* This value can serve as an ID for the cluster of logical processors: it is the
* same for all logical processors on the same package.
*/
uint32_t package_leader_id;
/**
* Number of logical processors in the package.
*/
uint32_t package_processor_count;
/**
* Maximum frequency, in kHZ.
* The value is parsed from /sys/devices/system/cpu/cpu<N>/cpufreq/cpuinfo_max_freq
* If failed to read or parse the file, the value is 0.
*/
uint32_t max_frequency;
/**
* Minimum frequency, in kHZ.
* The value is parsed from /sys/devices/system/cpu/cpu<N>/cpufreq/cpuinfo_min_freq
* If failed to read or parse the file, the value is 0.
*/
uint32_t min_frequency;
/** Linux processor ID */
uint32_t system_processor_id;
uint32_t flags;
};
struct cpuinfo_arm_linux_cluster {
uint32_t processor_id_min;
uint32_t processor_id_max;
};
/* Returns true if the two processors do belong to the same cluster */
static inline bool cpuinfo_arm_linux_processor_equals(
struct cpuinfo_arm_linux_processor processor_i[restrict static 1],
struct cpuinfo_arm_linux_processor processor_j[restrict static 1])
{
const uint32_t joint_flags = processor_i->flags & processor_j->flags;
bool same_max_frequency = false;
if (joint_flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (processor_i->max_frequency != processor_j->max_frequency) {
return false;
} else {
same_max_frequency = true;
}
}
bool same_min_frequency = false;
if (joint_flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (processor_i->min_frequency != processor_j->min_frequency) {
return false;
} else {
same_min_frequency = true;
}
}
if ((joint_flags & CPUINFO_ARM_LINUX_VALID_MIDR) == CPUINFO_ARM_LINUX_VALID_MIDR) {
if (processor_i->midr == processor_j->midr) {
if (midr_is_cortex_a53(processor_i->midr)) {
return same_min_frequency & same_max_frequency;
} else {
return true;
}
}
}
return same_max_frequency && same_min_frequency;
}
/* Returns true if the two processors certainly don't belong to the same cluster */
static inline bool cpuinfo_arm_linux_processor_not_equals(
struct cpuinfo_arm_linux_processor processor_i[restrict static 1],
struct cpuinfo_arm_linux_processor processor_j[restrict static 1])
{
const uint32_t joint_flags = processor_i->flags & processor_j->flags;
if (joint_flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (processor_i->max_frequency != processor_j->max_frequency) {
return true;
}
}
if (joint_flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (processor_i->min_frequency != processor_j->min_frequency) {
return true;
}
}
if ((joint_flags & CPUINFO_ARM_LINUX_VALID_MIDR) == CPUINFO_ARM_LINUX_VALID_MIDR) {
if (processor_i->midr != processor_j->midr) {
return true;
}
}
return false;
}
CPUINFO_INTERNAL bool cpuinfo_arm_linux_parse_proc_cpuinfo(
char hardware[restrict static CPUINFO_HARDWARE_VALUE_MAX],
char revision[restrict static CPUINFO_REVISION_VALUE_MAX],
uint32_t max_processors_count,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors_count]);
#if CPUINFO_ARCH_ARM
CPUINFO_INTERNAL bool cpuinfo_arm_linux_hwcap_from_getauxval(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1]);
CPUINFO_INTERNAL bool cpuinfo_arm_linux_hwcap_from_procfs(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1]);
CPUINFO_INTERNAL void cpuinfo_arm_linux_decode_isa_from_proc_cpuinfo(
uint32_t features,
uint32_t features2,
uint32_t midr,
uint32_t architecture_version,
uint32_t architecture_flags,
const struct cpuinfo_arm_chipset chipset[restrict static 1],
struct cpuinfo_arm_isa isa[restrict static 1]);
#elif CPUINFO_ARCH_ARM64
CPUINFO_INTERNAL void cpuinfo_arm_linux_hwcap_from_getauxval(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1]);
CPUINFO_INTERNAL void cpuinfo_arm64_linux_decode_isa_from_proc_cpuinfo(
uint32_t features,
uint32_t features2,
uint32_t midr,
const struct cpuinfo_arm_chipset chipset[restrict static 1],
struct cpuinfo_arm_isa isa[restrict static 1]);
#endif
#ifdef __ANDROID__
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset(
const struct cpuinfo_android_properties properties[restrict static 1],
uint32_t cores,
uint32_t max_cpu_freq_max);
#else
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_linux_decode_chipset(
const char hardware[restrict static CPUINFO_HARDWARE_VALUE_MAX],
const char revision[restrict static CPUINFO_REVISION_VALUE_MAX],
uint32_t cores,
uint32_t max_cpu_freq_max);
#endif
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_linux_decode_chipset_from_proc_cpuinfo_hardware(
const char proc_cpuinfo_hardware[restrict static CPUINFO_HARDWARE_VALUE_MAX],
uint32_t cores, uint32_t max_cpu_freq_max, bool is_tegra);
#ifdef __ANDROID__
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_product_board(
const char ro_product_board[restrict static CPUINFO_BUILD_PROP_VALUE_MAX],
uint32_t cores, uint32_t max_cpu_freq_max);
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_board_platform(
const char ro_board_platform[restrict static CPUINFO_BUILD_PROP_VALUE_MAX],
uint32_t cores, uint32_t max_cpu_freq_max);
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_mediatek_platform(
const char ro_mediatek_platform[restrict static CPUINFO_BUILD_PROP_VALUE_MAX]);
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_arch(
const char ro_arch[restrict static CPUINFO_BUILD_PROP_VALUE_MAX]);
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_chipname(
const char ro_chipname[restrict static CPUINFO_BUILD_PROP_VALUE_MAX]);
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_android_decode_chipset_from_ro_hardware_chipname(
const char ro_hardware_chipname[restrict static CPUINFO_BUILD_PROP_VALUE_MAX]);
#else
CPUINFO_INTERNAL struct cpuinfo_arm_chipset
cpuinfo_arm_linux_decode_chipset_from_proc_cpuinfo_revision(
const char proc_cpuinfo_revision[restrict static CPUINFO_REVISION_VALUE_MAX]);
#endif
CPUINFO_INTERNAL bool cpuinfo_arm_linux_detect_core_clusters_by_heuristic(
uint32_t usable_processors,
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors]);
CPUINFO_INTERNAL void cpuinfo_arm_linux_detect_core_clusters_by_sequential_scan(
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors]);
CPUINFO_INTERNAL void cpuinfo_arm_linux_count_cluster_processors(
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors]);
CPUINFO_INTERNAL uint32_t cpuinfo_arm_linux_detect_cluster_midr(
const struct cpuinfo_arm_chipset chipset[restrict static 1],
uint32_t max_processors,
uint32_t usable_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors]);
extern CPUINFO_INTERNAL const uint32_t* cpuinfo_linux_cpu_to_uarch_index_map;
extern CPUINFO_INTERNAL uint32_t cpuinfo_linux_cpu_to_uarch_index_map_entries;

3860
3rdparty/cpuinfo/src/arm/linux/chipset.c vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,493 @@
#include <stdint.h>
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <cpuinfo.h>
#include <arm/linux/api.h>
#if defined(__ANDROID__)
#include <arm/android/api.h>
#endif
#include <arm/api.h>
#include <arm/midr.h>
#include <linux/api.h>
#include <cpuinfo/internal-api.h>
#include <cpuinfo/log.h>
static inline bool bitmask_all(uint32_t bitfield, uint32_t mask) {
return (bitfield & mask) == mask;
}
/*
* Assigns logical processors to clusters of cores using heuristic based on the typical configuration of clusters for
* 5, 6, 8, and 10 cores:
* - 5 cores (ARM32 Android only): 2 clusters of 4+1 cores
* - 6 cores: 2 clusters of 4+2 cores
* - 8 cores: 2 clusters of 4+4 cores
* - 10 cores: 3 clusters of 4+4+2 cores
*
* The function must be called after parsing OS-provided information on core clusters.
* Its purpose is to detect clusters of cores when OS-provided information is lacking or incomplete, i.e.
* - Linux kernel is not configured to report information in sysfs topology leaf.
* - Linux kernel reports topology information only for online cores, and only cores on one cluster are online, e.g.:
* - Exynos 8890 has 8 cores in 4+4 clusters, but only the first cluster of 4 cores is reported, and cluster
* configuration of logical processors 4-7 is not reported (all remaining processors 4-7 form cluster 1)
* - MT6797 has 10 cores in 4+4+2, but only the first cluster of 4 cores is reported, and cluster configuration
* of logical processors 4-9 is not reported (processors 4-7 form cluster 1, and processors 8-9 form cluster 2).
*
* Heuristic assignment of processors to the above pre-defined clusters fails if such assignment would contradict
* information provided by the operating system:
* - Any of the OS-reported processor clusters is different than the corresponding heuristic cluster.
* - Processors in a heuristic cluster have no OS-provided cluster siblings information, but have known and different
* minimum/maximum frequency.
* - Processors in a heuristic cluster have no OS-provided cluster siblings information, but have known and different
* MIDR components.
*
* If the heuristic assignment of processors to clusters of cores fails, all processors' clusters are unchanged.
*
* @param usable_processors - number of processors in the @p processors array with CPUINFO_LINUX_FLAG_VALID flags.
* @param max_processors - number of elements in the @p processors array.
* @param[in,out] processors - processor descriptors with pre-parsed POSSIBLE and PRESENT flags, minimum/maximum
* frequency, MIDR infromation, and core cluster (package siblings list) information.
*
* @retval true if the heuristic successfully assigned all processors into clusters of cores.
* @retval false if known details about processors contradict the heuristic configuration of core clusters.
*/
bool cpuinfo_arm_linux_detect_core_clusters_by_heuristic(
uint32_t usable_processors,
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors])
{
uint32_t cluster_processors[3];
switch (usable_processors) {
case 10:
cluster_processors[0] = 4;
cluster_processors[1] = 4;
cluster_processors[2] = 2;
break;
case 8:
cluster_processors[0] = 4;
cluster_processors[1] = 4;
break;
case 6:
cluster_processors[0] = 4;
cluster_processors[1] = 2;
break;
#if defined(__ANDROID__) && CPUINFO_ARCH_ARM
case 5:
/*
* The only processor with 5 cores is Leadcore L1860C (ARMv7, mobile),
* but this configuration is not too unreasonable for a virtualized ARM server.
*/
cluster_processors[0] = 4;
cluster_processors[1] = 1;
break;
#endif
default:
return false;
}
/*
* Assignment of processors to core clusters is done in two passes:
* 1. Verify that the clusters proposed by heuristic are compatible with known details about processors.
* 2. If verification passed, update core clusters for the processors.
*/
uint32_t cluster = 0;
uint32_t expected_cluster_processors = 0;
uint32_t cluster_start, cluster_flags, cluster_midr, cluster_max_frequency, cluster_min_frequency;
bool expected_cluster_exists;
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (expected_cluster_processors == 0) {
/* Expect this processor to start a new cluster */
expected_cluster_exists = !!(processors[i].flags & CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER);
if (expected_cluster_exists) {
if (processors[i].package_leader_id != i) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"processor %"PRIu32" is expected to start a new cluster #%"PRIu32" with %"PRIu32" cores, "
"but system siblings lists reported it as a sibling of processor %"PRIu32,
i, cluster, cluster_processors[cluster], processors[i].package_leader_id);
return false;
}
} else {
cluster_flags = 0;
}
cluster_start = i;
expected_cluster_processors = cluster_processors[cluster++];
} else {
/* Expect this processor to belong to the same cluster as processor */
if (expected_cluster_exists) {
/*
* The cluster suggested by the heuristic was already parsed from system siblings lists.
* For all processors we expect in the cluster, check that:
* - They have pre-assigned cluster from siblings lists (CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER flag).
* - They were assigned to the same cluster based on siblings lists
* (package_leader_id points to the first processor in the cluster).
*/
if ((processors[i].flags & CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER) == 0) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"processor %"PRIu32" is expected to belong to the cluster of processor %"PRIu32", "
"but system siblings lists did not report it as a sibling of processor %"PRIu32,
i, cluster_start, cluster_start);
return false;
}
if (processors[i].package_leader_id != cluster_start) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"processor %"PRIu32" is expected to belong to the cluster of processor %"PRIu32", "
"but system siblings lists reported it to belong to the cluster of processor %"PRIu32,
i, cluster_start, cluster_start);
return false;
}
} else {
/*
* The cluster suggest by the heuristic was not parsed from system siblings lists.
* For all processors we expect in the cluster, check that:
* - They have no pre-assigned cluster from siblings lists.
* - If their min/max CPU frequency is known, it is the same.
* - If any part of their MIDR (Implementer, Variant, Part, Revision) is known, it is the same.
*/
if (processors[i].flags & CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"processor %"PRIu32" is expected to be unassigned to any cluster, "
"but system siblings lists reported it to belong to the cluster of processor %"PRIu32,
i, processors[i].package_leader_id);
return false;
}
if (processors[i].flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (cluster_flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (cluster_min_frequency != processors[i].min_frequency) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"minimum frequency of processor %"PRIu32" (%"PRIu32" KHz) is different than of its expected cluster (%"PRIu32" KHz)",
i, processors[i].min_frequency, cluster_min_frequency);
return false;
}
} else {
cluster_min_frequency = processors[i].min_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MIN_FREQUENCY;
}
}
if (processors[i].flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (cluster_flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (cluster_max_frequency != processors[i].max_frequency) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"maximum frequency of processor %"PRIu32" (%"PRIu32" KHz) is different than of its expected cluster (%"PRIu32" KHz)",
i, processors[i].max_frequency, cluster_max_frequency);
return false;
}
} else {
cluster_max_frequency = processors[i].max_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MAX_FREQUENCY;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
if ((cluster_midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK)) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"CPU Implementer of processor %"PRIu32" (0x%02"PRIx32") is different than of its expected cluster (0x%02"PRIx32")",
i, midr_get_implementer(processors[i].midr), midr_get_implementer(cluster_midr));
return false;
}
} else {
cluster_midr = midr_copy_implementer(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_IMPLEMENTER;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
if ((cluster_midr & CPUINFO_ARM_MIDR_VARIANT_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_VARIANT_MASK)) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"CPU Variant of processor %"PRIu32" (0x%"PRIx32") is different than of its expected cluster (0x%"PRIx32")",
i, midr_get_variant(processors[i].midr), midr_get_variant(cluster_midr));
return false;
}
} else {
cluster_midr = midr_copy_variant(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_VARIANT;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_PART) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_PART) {
if ((cluster_midr & CPUINFO_ARM_MIDR_PART_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_PART_MASK)) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"CPU Part of processor %"PRIu32" (0x%03"PRIx32") is different than of its expected cluster (0x%03"PRIx32")",
i, midr_get_part(processors[i].midr), midr_get_part(cluster_midr));
return false;
}
} else {
cluster_midr = midr_copy_part(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_PART;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
if ((cluster_midr & CPUINFO_ARM_MIDR_REVISION_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_REVISION_MASK)) {
cpuinfo_log_debug(
"heuristic detection of core clusters failed: "
"CPU Revision of processor %"PRIu32" (0x%"PRIx32") is different than of its expected cluster (0x%"PRIx32")",
i, midr_get_revision(cluster_midr), midr_get_revision(processors[i].midr));
return false;
}
} else {
cluster_midr = midr_copy_revision(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_REVISION;
}
}
}
}
expected_cluster_processors--;
}
}
/* Verification passed, assign all processors to new clusters */
cluster = 0;
expected_cluster_processors = 0;
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (expected_cluster_processors == 0) {
/* Expect this processor to start a new cluster */
cluster_start = i;
expected_cluster_processors = cluster_processors[cluster++];
} else {
/* Expect this processor to belong to the same cluster as processor */
if (!(processors[i].flags & CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER)) {
cpuinfo_log_debug("assigned processor %"PRIu32" to cluster of processor %"PRIu32" based on heuristic",
i, cluster_start);
}
processors[i].package_leader_id = cluster_start;
processors[i].flags |= CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER;
}
expected_cluster_processors--;
}
}
return true;
}
/*
* Assigns logical processors to clusters of cores in sequential manner:
* - Clusters detected from OS-provided information are unchanged:
* - Processors assigned to these clusters stay assigned to the same clusters
* - No new processors are added to these clusters
* - Processors without pre-assigned cluster are clustered in one sequential scan:
* - If known details (min/max frequency, MIDR components) of a processor are compatible with a preceeding
* processor, without pre-assigned cluster, the processor is assigned to the cluster of the preceeding processor.
* - If known details (min/max frequency, MIDR components) of a processor are not compatible with a preceeding
* processor, the processor is assigned to a newly created cluster.
*
* The function must be called after parsing OS-provided information on core clusters, and usually is called only
* if heuristic assignment of processors to clusters (cpuinfo_arm_linux_cluster_processors_by_heuristic) failed.
*
* Its purpose is to detect clusters of cores when OS-provided information is lacking or incomplete, i.e.
* - Linux kernel is not configured to report information in sysfs topology leaf.
* - Linux kernel reports topology information only for online cores, and all cores on some of the clusters are offline.
*
* Sequential assignment of processors to clusters always succeeds, and upon exit, all usable processors in the
* @p processors array have cluster information.
*
* @param max_processors - number of elements in the @p processors array.
* @param[in,out] processors - processor descriptors with pre-parsed POSSIBLE and PRESENT flags, minimum/maximum
* frequency, MIDR infromation, and core cluster (package siblings list) information.
*
* @retval true if the heuristic successfully assigned all processors into clusters of cores.
* @retval false if known details about processors contradict the heuristic configuration of core clusters.
*/
void cpuinfo_arm_linux_detect_core_clusters_by_sequential_scan(
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors])
{
uint32_t cluster_flags = 0;
uint32_t cluster_processors = 0;
uint32_t cluster_start, cluster_midr, cluster_max_frequency, cluster_min_frequency;
for (uint32_t i = 0; i < max_processors; i++) {
if ((processors[i].flags & (CPUINFO_LINUX_FLAG_VALID | CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER)) == CPUINFO_LINUX_FLAG_VALID) {
if (cluster_processors == 0) {
goto new_cluster;
}
if (processors[i].flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (cluster_flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
if (cluster_min_frequency != processors[i].min_frequency) {
cpuinfo_log_info(
"minimum frequency of processor %"PRIu32" (%"PRIu32" KHz) is different than of preceeding cluster (%"PRIu32" KHz); "
"processor %"PRIu32" starts to a new cluster",
i, processors[i].min_frequency, cluster_min_frequency, i);
goto new_cluster;
}
} else {
cluster_min_frequency = processors[i].min_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MIN_FREQUENCY;
}
}
if (processors[i].flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (cluster_flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (cluster_max_frequency != processors[i].max_frequency) {
cpuinfo_log_debug(
"maximum frequency of processor %"PRIu32" (%"PRIu32" KHz) is different than of preceeding cluster (%"PRIu32" KHz); "
"processor %"PRIu32" starts a new cluster",
i, processors[i].max_frequency, cluster_max_frequency, i);
goto new_cluster;
}
} else {
cluster_max_frequency = processors[i].max_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MAX_FREQUENCY;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
if ((cluster_midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK)) {
cpuinfo_log_debug(
"CPU Implementer of processor %"PRIu32" (0x%02"PRIx32") is different than of preceeding cluster (0x%02"PRIx32"); "
"processor %"PRIu32" starts to a new cluster",
i, midr_get_implementer(processors[i].midr), midr_get_implementer(cluster_midr), i);
goto new_cluster;
}
} else {
cluster_midr = midr_copy_implementer(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_IMPLEMENTER;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
if ((cluster_midr & CPUINFO_ARM_MIDR_VARIANT_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_VARIANT_MASK)) {
cpuinfo_log_debug(
"CPU Variant of processor %"PRIu32" (0x%"PRIx32") is different than of its expected cluster (0x%"PRIx32")"
"processor %"PRIu32" starts to a new cluster",
i, midr_get_variant(processors[i].midr), midr_get_variant(cluster_midr), i);
goto new_cluster;
}
} else {
cluster_midr = midr_copy_variant(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_VARIANT;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_PART) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_PART) {
if ((cluster_midr & CPUINFO_ARM_MIDR_PART_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_PART_MASK)) {
cpuinfo_log_debug(
"CPU Part of processor %"PRIu32" (0x%03"PRIx32") is different than of its expected cluster (0x%03"PRIx32")"
"processor %"PRIu32" starts to a new cluster",
i, midr_get_part(processors[i].midr), midr_get_part(cluster_midr), i);
goto new_cluster;
}
} else {
cluster_midr = midr_copy_part(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_PART;
}
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
if (cluster_flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
if ((cluster_midr & CPUINFO_ARM_MIDR_REVISION_MASK) != (processors[i].midr & CPUINFO_ARM_MIDR_REVISION_MASK)) {
cpuinfo_log_debug(
"CPU Revision of processor %"PRIu32" (0x%"PRIx32") is different than of its expected cluster (0x%"PRIx32")"
"processor %"PRIu32" starts to a new cluster",
i, midr_get_revision(cluster_midr), midr_get_revision(processors[i].midr), i);
goto new_cluster;
}
} else {
cluster_midr = midr_copy_revision(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_REVISION;
}
}
/* All checks passed, attach processor to the preceeding cluster */
cluster_processors++;
processors[i].package_leader_id = cluster_start;
processors[i].flags |= CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER;
cpuinfo_log_debug("assigned processor %"PRIu32" to preceeding cluster of processor %"PRIu32, i, cluster_start);
continue;
new_cluster:
/* Create a new cluster starting with processor i */
cluster_start = i;
processors[i].package_leader_id = i;
processors[i].flags |= CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER;
cluster_processors = 1;
/* Copy known information from processor to cluster, and set the flags accordingly */
cluster_flags = 0;
if (processors[i].flags & CPUINFO_LINUX_FLAG_MIN_FREQUENCY) {
cluster_min_frequency = processors[i].min_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MIN_FREQUENCY;
}
if (processors[i].flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
cluster_max_frequency = processors[i].max_frequency;
cluster_flags |= CPUINFO_LINUX_FLAG_MAX_FREQUENCY;
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
cluster_midr = midr_copy_implementer(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_IMPLEMENTER;
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
cluster_midr = midr_copy_variant(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_VARIANT;
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_PART) {
cluster_midr = midr_copy_part(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_PART;
}
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
cluster_midr = midr_copy_revision(cluster_midr, processors[i].midr);
cluster_flags |= CPUINFO_ARM_LINUX_VALID_REVISION;
}
}
}
}
/*
* Counts the number of logical processors in each core cluster.
* This function should be called after all processors are assigned to core clusters.
*
* @param max_processors - number of elements in the @p processors array.
* @param[in,out] processors - processor descriptors with pre-parsed POSSIBLE and PRESENT flags,
* and decoded core cluster (package_leader_id) information.
* The function expects the value of processors[i].package_processor_count to be zero.
* Upon return, processors[i].package_processor_count will contain the number of logical
* processors in the respective core cluster.
*/
void cpuinfo_arm_linux_count_cluster_processors(
uint32_t max_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors])
{
/* First pass: accumulate the number of processors at the group leader's package_processor_count */
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
const uint32_t package_leader_id = processors[i].package_leader_id;
processors[package_leader_id].package_processor_count += 1;
}
}
/* Second pass: copy the package_processor_count from the group leader processor */
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
const uint32_t package_leader_id = processors[i].package_leader_id;
processors[i].package_processor_count = processors[package_leader_id].package_processor_count;
}
}
}

44
3rdparty/cpuinfo/src/arm/linux/cp.h vendored Normal file
View File

@@ -0,0 +1,44 @@
#include <stdint.h>
#if CPUINFO_MOCK
extern uint32_t cpuinfo_arm_fpsid;
extern uint32_t cpuinfo_arm_mvfr0;
extern uint32_t cpuinfo_arm_wcid;
static inline uint32_t read_fpsid(void) {
return cpuinfo_arm_fpsid;
}
static inline uint32_t read_mvfr0(void) {
return cpuinfo_arm_mvfr0;
}
static inline uint32_t read_wcid(void) {
return cpuinfo_arm_wcid;
}
#else
#if !defined(__ARM_ARCH_7A__) && !defined(__ARM_ARCH_8A__) && !(defined(__ARM_ARCH) && (__ARM_ARCH >= 7))
/*
* CoProcessor 10 is inaccessible from user mode since ARMv7,
* and clang refuses to compile inline assembly when targeting ARMv7+
*/
static inline uint32_t read_fpsid(void) {
uint32_t fpsid;
__asm__ __volatile__("MRC p10, 0x7, %[fpsid], cr0, cr0, 0" : [fpsid] "=r" (fpsid));
return fpsid;
}
static inline uint32_t read_mvfr0(void) {
uint32_t mvfr0;
__asm__ __volatile__("MRC p10, 0x7, %[mvfr0], cr7, cr0, 0" : [mvfr0] "=r" (mvfr0));
return mvfr0;
}
#endif
static inline uint32_t read_wcid(void) {
uint32_t wcid;
__asm__ __volatile__("MRC p1, 0, %[wcid], c0, c0" : [wcid] "=r" (wcid));
return wcid;
}
#endif

908
3rdparty/cpuinfo/src/arm/linux/cpuinfo.c vendored Normal file
View File

@@ -0,0 +1,908 @@
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <linux/api.h>
#include <arm/linux/api.h>
#include <arm/midr.h>
#include <cpuinfo/log.h>
/*
* Size, in chars, of the on-stack buffer used for parsing lines of /proc/cpuinfo.
* This is also the limit on the length of a single line.
*/
#define BUFFER_SIZE 1024
static uint32_t parse_processor_number(
const char* processor_start,
const char* processor_end)
{
const size_t processor_length = (size_t) (processor_end - processor_start);
if (processor_length == 0) {
cpuinfo_log_warning("Processor number in /proc/cpuinfo is ignored: string is empty");
return 0;
}
uint32_t processor_number = 0;
for (const char* digit_ptr = processor_start; digit_ptr != processor_end; digit_ptr++) {
const uint32_t digit = (uint32_t) (*digit_ptr - '0');
if (digit > 10) {
cpuinfo_log_warning("non-decimal suffix %.*s in /proc/cpuinfo processor number is ignored",
(int) (processor_end - digit_ptr), digit_ptr);
break;
}
processor_number = processor_number * 10 + digit;
}
return processor_number;
}
/*
* Full list of ARM features reported in /proc/cpuinfo:
*
* * swp - support for SWP instruction (deprecated in ARMv7, can be removed in future)
* * half - support for half-word loads and stores. These instruction are part of ARMv4,
* so no need to check it on supported CPUs.
* * thumb - support for 16-bit Thumb instruction set. Note that BX instruction is detected
* by ARMv4T architecture, not by this flag.
* * 26bit - old CPUs merged 26-bit PC and program status register (flags) into 32-bit PC
* and had special instructions for working with packed PC. Now it is all deprecated.
* * fastmult - most old ARM CPUs could only compute 2 bits of multiplication result per clock
* cycle, but CPUs with M suffix (e.g. ARM7TDMI) could compute 4 bits per cycle.
* Of course, now it makes no sense.
* * fpa - floating point accelerator available. On original ARM ABI all floating-point operations
* generated FPA instructions. If FPA was not available, these instructions generated
* "illegal operation" interrupts, and the OS processed them by emulating the FPA instructions.
* Debian used this ABI before it switched to EABI. Now FPA is deprecated.
* * vfp - vector floating point instructions. Available on most modern CPUs (as part of VFPv3).
* Required by Android ARMv7A ABI and by Ubuntu on ARM.
* Note: there is no flag for VFPv2.
* * edsp - V5E instructions: saturating add/sub and 16-bit x 16-bit -> 32/64-bit multiplications.
* Required on Android, supported by all CPUs in production.
* * java - Jazelle extension. Supported on most CPUs.
* * iwmmxt - Intel/Marvell Wireless MMX instructions. 64-bit integer SIMD.
* Supported on XScale (Since PXA270) and Sheeva (PJ1, PJ4) architectures.
* Note that there is no flag for WMMX2 instructions.
* * crunch - Maverick Crunch instructions. Junk.
* * thumbee - ThumbEE instructions. Almost no documentation is available.
* * neon - NEON instructions (aka Advanced SIMD). MVFR1 register gives more
* fine-grained information on particular supported features, but
* the Linux kernel exports only a single flag for all of them.
* According to ARMv7A docs it also implies the availability of VFPv3
* (with 32 double-precision registers d0-d31).
* * vfpv3 - VFPv3 instructions. Available on most modern CPUs. Augment VFPv2 by
* conversion to/from integers and load constant instructions.
* Required by Android ARMv7A ABI and by Ubuntu on ARM.
* * vfpv3d16 - VFPv3 instructions with only 16 double-precision registers (d0-d15).
* * tls - software thread ID registers.
* Used by kernel (and likely libc) for efficient implementation of TLS.
* * vfpv4 - fused multiply-add instructions.
* * idiva - DIV instructions available in ARM mode.
* * idivt - DIV instructions available in Thumb mode.
* * vfpd32 - VFP (of any version) with 32 double-precision registers d0-d31.
* * lpae - Large Physical Address Extension (physical address up to 40 bits).
* * evtstrm - generation of Event Stream by timer.
* * aes - AES instructions.
* * pmull - Polinomial Multiplication instructions.
* * sha1 - SHA1 instructions.
* * sha2 - SHA2 instructions.
* * crc32 - CRC32 instructions.
*
* /proc/cpuinfo on ARM is populated in file arch/arm/kernel/setup.c in Linux kernel
* Note that some devices may use patched Linux kernels with different feature names.
* However, the names above were checked on a large number of /proc/cpuinfo listings.
*/
static void parse_features(
const char* features_start,
const char* features_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
const char* feature_start = features_start;
const char* feature_end;
/* Mark the features as valid */
processor->flags |= CPUINFO_ARM_LINUX_VALID_FEATURES | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
do {
feature_end = feature_start + 1;
for (; feature_end != features_end; feature_end++) {
if (*feature_end == ' ') {
break;
}
}
const size_t feature_length = (size_t) (feature_end - feature_start);
switch (feature_length) {
case 2:
if (memcmp(feature_start, "fp", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_FP;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "wp", feature_length) == 0) {
/*
* Some AArch64 kernels, including the one on Nexus 5X,
* erroneously report "swp" as "wp" to AArch32 programs
*/
processor->features |= CPUINFO_ARM_LINUX_FEATURE_SWP;
#endif
} else {
goto unexpected;
}
break;
case 3:
if (memcmp(feature_start, "aes", feature_length) == 0) {
#if CPUINFO_ARCH_ARM
processor->features2 |= CPUINFO_ARM_LINUX_FEATURE2_AES;
#elif CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_AES;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "swp", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_SWP;
} else if (memcmp(feature_start, "fpa", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_FPA;
} else if (memcmp(feature_start, "vfp", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_VFP;
} else if (memcmp(feature_start, "tls", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_TLS;
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unexpected;
}
break;
case 4:
if (memcmp(feature_start, "sha1", feature_length) == 0) {
#if CPUINFO_ARCH_ARM
processor->features2 |= CPUINFO_ARM_LINUX_FEATURE2_SHA1;
#elif CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_SHA1;
#endif
} else if (memcmp(feature_start, "sha2", feature_length) == 0) {
#if CPUINFO_ARCH_ARM
processor->features2 |= CPUINFO_ARM_LINUX_FEATURE2_SHA2;
#elif CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_SHA2;
#endif
} else if (memcmp(feature_start, "fphp", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_FPHP;
#endif
} else if (memcmp(feature_start, "fcma", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_FCMA;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "half", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_HALF;
} else if (memcmp(feature_start, "edsp", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_EDSP;
} else if (memcmp(feature_start, "java", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_JAVA;
} else if (memcmp(feature_start, "neon", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_NEON;
} else if (memcmp(feature_start, "lpae", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_LPAE;
} else if (memcmp(feature_start, "tlsi", feature_length) == 0) {
/*
* Some AArch64 kernels, including the one on Nexus 5X,
* erroneously report "tls" as "tlsi" to AArch32 programs
*/
processor->features |= CPUINFO_ARM_LINUX_FEATURE_TLS;
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unexpected;
}
break;
case 5:
if (memcmp(feature_start, "pmull", feature_length) == 0) {
#if CPUINFO_ARCH_ARM
processor->features2 |= CPUINFO_ARM_LINUX_FEATURE2_PMULL;
#elif CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_PMULL;
#endif
} else if (memcmp(feature_start, "crc32", feature_length) == 0) {
#if CPUINFO_ARCH_ARM
processor->features2 |= CPUINFO_ARM_LINUX_FEATURE2_CRC32;
#elif CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_CRC32;
#endif
} else if (memcmp(feature_start, "asimd", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_ASIMD;
#endif
} else if (memcmp(feature_start, "cpuid", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_CPUID;
#endif
} else if (memcmp(feature_start, "jscvt", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_JSCVT;
#endif
} else if (memcmp(feature_start, "lrcpc", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_LRCPC;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "thumb", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_THUMB;
} else if (memcmp(feature_start, "26bit", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_26BIT;
} else if (memcmp(feature_start, "vfpv3", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_VFPV3;
} else if (memcmp(feature_start, "vfpv4", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_VFPV4;
} else if (memcmp(feature_start, "idiva", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_IDIVA;
} else if (memcmp(feature_start, "idivt", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_IDIVT;
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unexpected;
}
break;
#if CPUINFO_ARCH_ARM
case 6:
if (memcmp(feature_start, "iwmmxt", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_IWMMXT;
} else if (memcmp(feature_start, "crunch", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_CRUNCH;
} else if (memcmp(feature_start, "vfpd32", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_VFPD32;
} else {
goto unexpected;
}
break;
#endif /* CPUINFO_ARCH_ARM */
case 7:
if (memcmp(feature_start, "evtstrm", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_EVTSTRM;
} else if (memcmp(feature_start, "atomics", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_ATOMICS;
#endif
} else if (memcmp(feature_start, "asimdhp", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_ASIMDHP;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "thumbee", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_THUMBEE;
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unexpected;
}
break;
case 8:
if (memcmp(feature_start, "asimdrdm", feature_length) == 0) {
#if CPUINFO_ARCH_ARM64
processor->features |= CPUINFO_ARM_LINUX_FEATURE_ASIMDRDM;
#endif
#if CPUINFO_ARCH_ARM
} else if (memcmp(feature_start, "fastmult", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_FASTMULT;
} else if (memcmp(feature_start, "vfpv3d16", feature_length) == 0) {
processor->features |= CPUINFO_ARM_LINUX_FEATURE_VFPV3D16;
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unexpected;
}
break;
default:
unexpected:
cpuinfo_log_warning("unexpected /proc/cpuinfo feature \"%.*s\" is ignored",
(int) feature_length, feature_start);
break;
}
feature_start = feature_end;
for (; feature_start != features_end; feature_start++) {
if (*feature_start != ' ') {
break;
}
}
} while (feature_start != feature_end);
}
static void parse_cpu_architecture(
const char* cpu_architecture_start,
const char* cpu_architecture_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
const size_t cpu_architecture_length = (size_t) (cpu_architecture_end - cpu_architecture_start);
/* Early AArch64 kernels report "CPU architecture: AArch64" instead of a numeric value 8 */
if (cpu_architecture_length == 7) {
if (memcmp(cpu_architecture_start, "AArch64", cpu_architecture_length) == 0) {
processor->midr = midr_set_architecture(processor->midr, UINT32_C(0xF));
processor->architecture_version = 8;
processor->flags |= CPUINFO_ARM_LINUX_VALID_ARCHITECTURE | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
return;
}
}
uint32_t architecture = 0;
const char* cpu_architecture_ptr = cpu_architecture_start;
for (; cpu_architecture_ptr != cpu_architecture_end; cpu_architecture_ptr++) {
const uint32_t digit = (*cpu_architecture_ptr) - '0';
/* Verify that CPU architecture is a decimal number */
if (digit >= 10) {
break;
}
architecture = architecture * 10 + digit;
}
if (cpu_architecture_ptr == cpu_architecture_start) {
cpuinfo_log_warning("CPU architecture %.*s in /proc/cpuinfo is ignored due to non-digit at the beginning of the string",
(int) cpu_architecture_length, cpu_architecture_start);
} else {
if (architecture != 0) {
processor->architecture_version = architecture;
processor->flags |= CPUINFO_ARM_LINUX_VALID_ARCHITECTURE | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
for (; cpu_architecture_ptr != cpu_architecture_end; cpu_architecture_ptr++) {
const char feature = *cpu_architecture_ptr;
switch (feature) {
#if CPUINFO_ARCH_ARM
case 'T':
processor->architecture_flags |= CPUINFO_ARM_LINUX_ARCH_T;
break;
case 'E':
processor->architecture_flags |= CPUINFO_ARM_LINUX_ARCH_E;
break;
case 'J':
processor->architecture_flags |= CPUINFO_ARM_LINUX_ARCH_J;
break;
#endif /* CPUINFO_ARCH_ARM */
case ' ':
case '\t':
/* Ignore whitespace at the end */
break;
default:
cpuinfo_log_warning("skipped unknown architectural feature '%c' for ARMv%"PRIu32,
feature, architecture);
break;
}
}
} else {
cpuinfo_log_warning("CPU architecture %.*s in /proc/cpuinfo is ignored due to invalid value (0)",
(int) cpu_architecture_length, cpu_architecture_start);
}
}
uint32_t midr_architecture = UINT32_C(0xF);
#if CPUINFO_ARCH_ARM
switch (processor->architecture_version) {
case 6:
midr_architecture = UINT32_C(0x7); /* ARMv6 */
break;
case 5:
if ((processor->architecture_flags & CPUINFO_ARM_LINUX_ARCH_TEJ) == CPUINFO_ARM_LINUX_ARCH_TEJ) {
midr_architecture = UINT32_C(0x6); /* ARMv5TEJ */
} else if ((processor->architecture_flags & CPUINFO_ARM_LINUX_ARCH_TE) == CPUINFO_ARM_LINUX_ARCH_TE) {
midr_architecture = UINT32_C(0x5); /* ARMv5TE */
} else {
midr_architecture = UINT32_C(0x4); /* ARMv5T */
}
break;
}
#endif
processor->midr = midr_set_architecture(processor->midr, midr_architecture);
}
static void parse_cpu_part(
const char* cpu_part_start,
const char* cpu_part_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
const size_t cpu_part_length = (size_t) (cpu_part_end - cpu_part_start);
/*
* CPU part should contain hex prefix (0x) and one to three hex digits.
* I have never seen less than three digits as a value of this field,
* but I don't think it is impossible to see such values in future.
* Value can not contain more than three hex digits since
* Main ID Register (MIDR) assigns only a 12-bit value for CPU part.
*/
if (cpu_part_length < 3 || cpu_part_length > 5) {
cpuinfo_log_warning("CPU part %.*s in /proc/cpuinfo is ignored due to unexpected length (%zu)",
(int) cpu_part_length, cpu_part_start, cpu_part_length);
return;
}
/* Verify the presence of hex prefix */
if (cpu_part_start[0] != '0' || cpu_part_start[1] != 'x') {
cpuinfo_log_warning("CPU part %.*s in /proc/cpuinfo is ignored due to lack of 0x prefix",
(int) cpu_part_length, cpu_part_start);
return;
}
/* Verify that characters after hex prefix are hexadecimal digits and decode them */
uint32_t cpu_part = 0;
for (const char* digit_ptr = cpu_part_start + 2; digit_ptr != cpu_part_end; digit_ptr++) {
const char digit_char = *digit_ptr;
uint32_t digit;
if (digit_char >= '0' && digit_char <= '9') {
digit = digit_char - '0';
} else if ((uint32_t) (digit_char - 'A') < 6) {
digit = 10 + (digit_char - 'A');
} else if ((uint32_t) (digit_char - 'a') < 6) {
digit = 10 + (digit_char - 'a');
} else {
cpuinfo_log_warning("CPU part %.*s in /proc/cpuinfo is ignored due to unexpected non-hex character %c at offset %zu",
(int) cpu_part_length, cpu_part_start, digit_char, (size_t) (digit_ptr - cpu_part_start));
return;
}
cpu_part = cpu_part * 16 + digit;
}
processor->midr = midr_set_part(processor->midr, cpu_part);
processor->flags |= CPUINFO_ARM_LINUX_VALID_PART | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
}
static void parse_cpu_implementer(
const char* cpu_implementer_start,
const char* cpu_implementer_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
const size_t cpu_implementer_length = cpu_implementer_end - cpu_implementer_start;
/*
* Value should contain hex prefix (0x) and one or two hex digits.
* I have never seen single hex digit as a value of this field,
* but I don't think it is impossible in future.
* Value can not contain more than two hex digits since
* Main ID Register (MIDR) assigns only an 8-bit value for CPU implementer.
*/
switch (cpu_implementer_length) {
case 3:
case 4:
break;
default:
cpuinfo_log_warning("CPU implementer %.*s in /proc/cpuinfo is ignored due to unexpected length (%zu)",
(int) cpu_implementer_length, cpu_implementer_start, cpu_implementer_length);
return;
}
/* Verify the presence of hex prefix */
if (cpu_implementer_start[0] != '0' || cpu_implementer_start[1] != 'x') {
cpuinfo_log_warning("CPU implementer %.*s in /proc/cpuinfo is ignored due to lack of 0x prefix",
(int) cpu_implementer_length, cpu_implementer_start);
return;
}
/* Verify that characters after hex prefix are hexadecimal digits and decode them */
uint32_t cpu_implementer = 0;
for (const char* digit_ptr = cpu_implementer_start + 2; digit_ptr != cpu_implementer_end; digit_ptr++) {
const char digit_char = *digit_ptr;
uint32_t digit;
if (digit_char >= '0' && digit_char <= '9') {
digit = digit_char - '0';
} else if ((uint32_t) (digit_char - 'A') < 6) {
digit = 10 + (digit_char - 'A');
} else if ((uint32_t) (digit_char - 'a') < 6) {
digit = 10 + (digit_char - 'a');
} else {
cpuinfo_log_warning("CPU implementer %.*s in /proc/cpuinfo is ignored due to unexpected non-hex character '%c' at offset %zu",
(int) cpu_implementer_length, cpu_implementer_start, digit_char, (size_t) (digit_ptr - cpu_implementer_start));
return;
}
cpu_implementer = cpu_implementer * 16 + digit;
}
processor->midr = midr_set_implementer(processor->midr, cpu_implementer);
processor->flags |= CPUINFO_ARM_LINUX_VALID_IMPLEMENTER | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
}
static void parse_cpu_variant(
const char* cpu_variant_start,
const char* cpu_variant_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
const size_t cpu_variant_length = cpu_variant_end - cpu_variant_start;
/*
* Value should contain hex prefix (0x) and one hex digit.
* Value can not contain more than one hex digits since
* Main ID Register (MIDR) assigns only a 4-bit value for CPU variant.
*/
if (cpu_variant_length != 3) {
cpuinfo_log_warning("CPU variant %.*s in /proc/cpuinfo is ignored due to unexpected length (%zu)",
(int) cpu_variant_length, cpu_variant_start, cpu_variant_length);
return;
}
/* Skip if there is no hex prefix (0x) */
if (cpu_variant_start[0] != '0' || cpu_variant_start[1] != 'x') {
cpuinfo_log_warning("CPU variant %.*s in /proc/cpuinfo is ignored due to lack of 0x prefix",
(int) cpu_variant_length, cpu_variant_start);
return;
}
/* Check if the value after hex prefix is indeed a hex digit and decode it. */
const char digit_char = cpu_variant_start[2];
uint32_t cpu_variant;
if ((uint32_t) (digit_char - '0') < 10) {
cpu_variant = (uint32_t) (digit_char - '0');
} else if ((uint32_t) (digit_char - 'A') < 6) {
cpu_variant = 10 + (uint32_t) (digit_char - 'A');
} else if ((uint32_t) (digit_char - 'a') < 6) {
cpu_variant = 10 + (uint32_t) (digit_char - 'a');
} else {
cpuinfo_log_warning("CPU variant %.*s in /proc/cpuinfo is ignored due to unexpected non-hex character '%c'",
(int) cpu_variant_length, cpu_variant_start, digit_char);
return;
}
processor->midr = midr_set_variant(processor->midr, cpu_variant);
processor->flags |= CPUINFO_ARM_LINUX_VALID_VARIANT | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
}
static void parse_cpu_revision(
const char* cpu_revision_start,
const char* cpu_revision_end,
struct cpuinfo_arm_linux_processor processor[restrict static 1])
{
uint32_t cpu_revision = 0;
for (const char* digit_ptr = cpu_revision_start; digit_ptr != cpu_revision_end; digit_ptr++) {
const uint32_t digit = (uint32_t) (*digit_ptr - '0');
/* Verify that the character in CPU revision is a decimal digit */
if (digit >= 10) {
cpuinfo_log_warning("CPU revision %.*s in /proc/cpuinfo is ignored due to unexpected non-digit character '%c' at offset %zu",
(int) (cpu_revision_end - cpu_revision_start), cpu_revision_start,
*digit_ptr, (size_t) (digit_ptr - cpu_revision_start));
return;
}
cpu_revision = cpu_revision * 10 + digit;
}
processor->midr = midr_set_revision(processor->midr, cpu_revision);
processor->flags |= CPUINFO_ARM_LINUX_VALID_REVISION | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
}
#if CPUINFO_ARCH_ARM
/*
* Decode one of the cache-related numbers reported by Linux kernel
* for pre-ARMv7 architecture.
* An example cache-related information in /proc/cpuinfo:
*
* I size : 32768
* I assoc : 4
* I line length : 32
* I sets : 256
* D size : 16384
* D assoc : 4
* D line length : 32
* D sets : 128
*
*/
static void parse_cache_number(
const char* number_start,
const char* number_end,
const char* number_name,
uint32_t number_ptr[restrict static 1],
uint32_t flags[restrict static 1],
uint32_t number_mask)
{
uint32_t number = 0;
for (const char* digit_ptr = number_start; digit_ptr != number_end; digit_ptr++) {
const uint32_t digit = *digit_ptr - '0';
if (digit >= 10) {
cpuinfo_log_warning("%s %.*s in /proc/cpuinfo is ignored due to unexpected non-digit character '%c' at offset %zu",
number_name, (int) (number_end - number_start), number_start,
*digit_ptr, (size_t) (digit_ptr - number_start));
return;
}
number = number * 10 + digit;
}
if (number == 0) {
cpuinfo_log_warning("%s %.*s in /proc/cpuinfo is ignored due to invalid value of zero reported by the kernel",
number_name, (int) (number_end - number_start), number_start);
}
/* If the number specifies a cache line size, verify that is a reasonable power of 2 */
if (number_mask & CPUINFO_ARM_LINUX_VALID_CACHE_LINE) {
switch (number) {
case 16:
case 32:
case 64:
case 128:
break;
default:
cpuinfo_log_warning("invalid %s %.*s is ignored: a value of 16, 32, 64, or 128 expected",
number_name, (int) (number_end - number_start), number_start);
}
}
*number_ptr = number;
*flags |= number_mask | CPUINFO_ARM_LINUX_VALID_PROCESSOR;
}
#endif /* CPUINFO_ARCH_ARM */
struct proc_cpuinfo_parser_state {
char* hardware;
char* revision;
uint32_t processor_index;
uint32_t max_processors_count;
struct cpuinfo_arm_linux_processor* processors;
struct cpuinfo_arm_linux_processor dummy_processor;
};
/*
* Decode a single line of /proc/cpuinfo information.
* Lines have format <words-with-spaces>[ ]*:[ ]<space-separated words>
* An example of /proc/cpuinfo (from Pandaboard-ES):
*
* Processor : ARMv7 Processor rev 10 (v7l)
* processor : 0
* BogoMIPS : 1392.74
*
* processor : 1
* BogoMIPS : 1363.33
*
* Features : swp half thumb fastmult vfp edsp thumbee neon vfpv3
* CPU implementer : 0x41
* CPU architecture: 7
* CPU variant : 0x2
* CPU part : 0xc09
* CPU revision : 10
*
* Hardware : OMAP4 Panda board
* Revision : 0020
* Serial : 0000000000000000
*/
static bool parse_line(
const char* line_start,
const char* line_end,
struct proc_cpuinfo_parser_state state[restrict static 1],
uint64_t line_number)
{
/* Empty line. Skip. */
if (line_start == line_end) {
return true;
}
/* Search for ':' on the line. */
const char* separator = line_start;
for (; separator != line_end; separator++) {
if (*separator == ':') {
break;
}
}
/* Skip line if no ':' separator was found. */
if (separator == line_end) {
cpuinfo_log_info("Line %.*s in /proc/cpuinfo is ignored: key/value separator ':' not found",
(int) (line_end - line_start), line_start);
return true;
}
/* Skip trailing spaces in key part. */
const char* key_end = separator;
for (; key_end != line_start; key_end--) {
if (key_end[-1] != ' ' && key_end[-1] != '\t') {
break;
}
}
/* Skip line if key contains nothing but spaces. */
if (key_end == line_start) {
cpuinfo_log_info("Line %.*s in /proc/cpuinfo is ignored: key contains only spaces",
(int) (line_end - line_start), line_start);
return true;
}
/* Skip leading spaces in value part. */
const char* value_start = separator + 1;
for (; value_start != line_end; value_start++) {
if (*value_start != ' ') {
break;
}
}
/* Value part contains nothing but spaces. Skip line. */
if (value_start == line_end) {
cpuinfo_log_info("Line %.*s in /proc/cpuinfo is ignored: value contains only spaces",
(int) (line_end - line_start), line_start);
return true;
}
/* Skip trailing spaces in value part (if any) */
const char* value_end = line_end;
for (; value_end != value_start; value_end--) {
if (value_end[-1] != ' ') {
break;
}
}
const uint32_t processor_index = state->processor_index;
const uint32_t max_processors_count = state->max_processors_count;
struct cpuinfo_arm_linux_processor* processors = state->processors;
struct cpuinfo_arm_linux_processor* processor = &state->dummy_processor;
if (processor_index < max_processors_count) {
processor = &processors[processor_index];
}
const size_t key_length = key_end - line_start;
switch (key_length) {
case 6:
if (memcmp(line_start, "Serial", key_length) == 0) {
/* Usually contains just zeros, useless */
#if CPUINFO_ARCH_ARM
} else if (memcmp(line_start, "I size", key_length) == 0) {
parse_cache_number(value_start, value_end,
"instruction cache size", &processor->proc_cpuinfo_cache.i_size,
&processor->flags, CPUINFO_ARM_LINUX_VALID_ICACHE_SIZE);
} else if (memcmp(line_start, "I sets", key_length) == 0) {
parse_cache_number(value_start, value_end,
"instruction cache sets", &processor->proc_cpuinfo_cache.i_sets,
&processor->flags, CPUINFO_ARM_LINUX_VALID_ICACHE_SETS);
} else if (memcmp(line_start, "D size", key_length) == 0) {
parse_cache_number(value_start, value_end,
"data cache size", &processor->proc_cpuinfo_cache.d_size,
&processor->flags, CPUINFO_ARM_LINUX_VALID_DCACHE_SIZE);
} else if (memcmp(line_start, "D sets", key_length) == 0) {
parse_cache_number(value_start, value_end,
"data cache sets", &processor->proc_cpuinfo_cache.d_sets,
&processor->flags, CPUINFO_ARM_LINUX_VALID_DCACHE_SETS);
#endif /* CPUINFO_ARCH_ARM */
} else {
goto unknown;
}
break;
#if CPUINFO_ARCH_ARM
case 7:
if (memcmp(line_start, "I assoc", key_length) == 0) {
parse_cache_number(value_start, value_end,
"instruction cache associativity", &processor->proc_cpuinfo_cache.i_assoc,
&processor->flags, CPUINFO_ARM_LINUX_VALID_ICACHE_WAYS);
} else if (memcmp(line_start, "D assoc", key_length) == 0) {
parse_cache_number(value_start, value_end,
"data cache associativity", &processor->proc_cpuinfo_cache.d_assoc,
&processor->flags, CPUINFO_ARM_LINUX_VALID_DCACHE_WAYS);
} else {
goto unknown;
}
break;
#endif /* CPUINFO_ARCH_ARM */
case 8:
if (memcmp(line_start, "CPU part", key_length) == 0) {
parse_cpu_part(value_start, value_end, processor);
} else if (memcmp(line_start, "Features", key_length) == 0) {
parse_features(value_start, value_end, processor);
} else if (memcmp(line_start, "BogoMIPS", key_length) == 0) {
/* BogoMIPS is useless, don't parse */
} else if (memcmp(line_start, "Hardware", key_length) == 0) {
size_t value_length = value_end - value_start;
if (value_length > CPUINFO_HARDWARE_VALUE_MAX) {
cpuinfo_log_info(
"length of Hardware value \"%.*s\" in /proc/cpuinfo exceeds limit (%d): truncating to the limit",
(int) value_length, value_start, CPUINFO_HARDWARE_VALUE_MAX);
value_length = CPUINFO_HARDWARE_VALUE_MAX;
} else {
state->hardware[value_length] = '\0';
}
memcpy(state->hardware, value_start, value_length);
cpuinfo_log_debug("parsed /proc/cpuinfo Hardware = \"%.*s\"", (int) value_length, value_start);
} else if (memcmp(line_start, "Revision", key_length) == 0) {
size_t value_length = value_end - value_start;
if (value_length > CPUINFO_REVISION_VALUE_MAX) {
cpuinfo_log_info(
"length of Revision value \"%.*s\" in /proc/cpuinfo exceeds limit (%d): truncating to the limit",
(int) value_length, value_start, CPUINFO_REVISION_VALUE_MAX);
value_length = CPUINFO_REVISION_VALUE_MAX;
} else {
state->revision[value_length] = '\0';
}
memcpy(state->revision, value_start, value_length);
cpuinfo_log_debug("parsed /proc/cpuinfo Revision = \"%.*s\"", (int) value_length, value_start);
} else {
goto unknown;
}
break;
case 9:
if (memcmp(line_start, "processor", key_length) == 0) {
const uint32_t new_processor_index = parse_processor_number(value_start, value_end);
if (new_processor_index < processor_index) {
/* Strange: decreasing processor number */
cpuinfo_log_warning(
"unexpectedly low processor number %"PRIu32" following processor %"PRIu32" in /proc/cpuinfo",
new_processor_index, processor_index);
} else if (new_processor_index > processor_index + 1) {
/* Strange, but common: skipped processor $(processor_index + 1) */
cpuinfo_log_info(
"unexpectedly high processor number %"PRIu32" following processor %"PRIu32" in /proc/cpuinfo",
new_processor_index, processor_index);
}
if (new_processor_index < max_processors_count) {
/* Record that the processor was mentioned in /proc/cpuinfo */
processors[new_processor_index].flags |= CPUINFO_ARM_LINUX_VALID_PROCESSOR;
} else {
/* Log and ignore processor */
cpuinfo_log_warning("processor %"PRIu32" in /proc/cpuinfo is ignored: index exceeds system limit %"PRIu32,
new_processor_index, max_processors_count - 1);
}
state->processor_index = new_processor_index;
return true;
} else if (memcmp(line_start, "Processor", key_length) == 0) {
/* TODO: parse to fix misreported architecture, similar to Android's cpufeatures */
} else {
goto unknown;
}
break;
case 11:
if (memcmp(line_start, "CPU variant", key_length) == 0) {
parse_cpu_variant(value_start, value_end, processor);
} else {
goto unknown;
}
break;
case 12:
if (memcmp(line_start, "CPU revision", key_length) == 0) {
parse_cpu_revision(value_start, value_end, processor);
} else {
goto unknown;
}
break;
#if CPUINFO_ARCH_ARM
case 13:
if (memcmp(line_start, "I line length", key_length) == 0) {
parse_cache_number(value_start, value_end,
"instruction cache line size", &processor->proc_cpuinfo_cache.i_line_length,
&processor->flags, CPUINFO_ARM_LINUX_VALID_ICACHE_LINE);
} else if (memcmp(line_start, "D line length", key_length) == 0) {
parse_cache_number(value_start, value_end,
"data cache line size", &processor->proc_cpuinfo_cache.d_line_length,
&processor->flags, CPUINFO_ARM_LINUX_VALID_DCACHE_LINE);
} else {
goto unknown;
}
break;
#endif /* CPUINFO_ARCH_ARM */
case 15:
if (memcmp(line_start, "CPU implementer", key_length) == 0) {
parse_cpu_implementer(value_start, value_end, processor);
} else if (memcmp(line_start, "CPU implementor", key_length) == 0) {
parse_cpu_implementer(value_start, value_end, processor);
} else {
goto unknown;
}
break;
case 16:
if (memcmp(line_start, "CPU architecture", key_length) == 0) {
parse_cpu_architecture(value_start, value_end, processor);
} else {
goto unknown;
}
break;
default:
unknown:
cpuinfo_log_debug("unknown /proc/cpuinfo key: %.*s", (int) key_length, line_start);
}
return true;
}
bool cpuinfo_arm_linux_parse_proc_cpuinfo(
char hardware[restrict static CPUINFO_HARDWARE_VALUE_MAX],
char revision[restrict static CPUINFO_REVISION_VALUE_MAX],
uint32_t max_processors_count,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors_count])
{
struct proc_cpuinfo_parser_state state = {
.hardware = hardware,
.revision = revision,
.processor_index = 0,
.max_processors_count = max_processors_count,
.processors = processors,
};
return cpuinfo_linux_parse_multiline_file("/proc/cpuinfo", BUFFER_SIZE,
(cpuinfo_line_callback) parse_line, &state);
}

159
3rdparty/cpuinfo/src/arm/linux/hwcap.c vendored Normal file
View File

@@ -0,0 +1,159 @@
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#include <dlfcn.h>
#include <elf.h>
#if CPUINFO_MOCK
#include <cpuinfo-mock.h>
#endif
#include <cpuinfo.h>
#include <arm/linux/api.h>
#include <cpuinfo/log.h>
#if CPUINFO_ARCH_ARM64 || CPUINFO_ARCH_ARM && !defined(__ANDROID__)
#include <sys/auxv.h>
#else
#define AT_HWCAP 16
#define AT_HWCAP2 26
#endif
#if CPUINFO_MOCK
static uint32_t mock_hwcap = 0;
void cpuinfo_set_hwcap(uint32_t hwcap) {
mock_hwcap = hwcap;
}
static uint32_t mock_hwcap2 = 0;
void cpuinfo_set_hwcap2(uint32_t hwcap2) {
mock_hwcap2 = hwcap2;
}
#endif
#if CPUINFO_ARCH_ARM
typedef unsigned long (*getauxval_function_t)(unsigned long);
bool cpuinfo_arm_linux_hwcap_from_getauxval(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1])
{
#if CPUINFO_MOCK
*hwcap = mock_hwcap;
*hwcap2 = mock_hwcap2;
return true;
#elif defined(__ANDROID__)
/* Android: dynamically check if getauxval is supported */
void* libc = NULL;
getauxval_function_t getauxval = NULL;
dlerror();
libc = dlopen("libc.so", RTLD_LAZY);
if (libc == NULL) {
cpuinfo_log_warning("failed to load libc.so: %s", dlerror());
goto cleanup;
}
getauxval = (getauxval_function_t) dlsym(libc, "getauxval");
if (getauxval == NULL) {
cpuinfo_log_info("failed to locate getauxval in libc.so: %s", dlerror());
goto cleanup;
}
*hwcap = getauxval(AT_HWCAP);
*hwcap2 = getauxval(AT_HWCAP2);
cleanup:
if (libc != NULL) {
dlclose(libc);
libc = NULL;
}
return getauxval != NULL;
#else
/* GNU/Linux: getauxval is always supported */
*hwcap = getauxval(AT_HWCAP);
*hwcap2 = getauxval(AT_HWCAP2);
return true;
#endif
}
#ifdef __ANDROID__
bool cpuinfo_arm_linux_hwcap_from_procfs(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1])
{
#if CPUINFO_MOCK
*hwcap = mock_hwcap;
*hwcap2 = mock_hwcap2;
return true;
#else
uint32_t hwcaps[2] = { 0, 0 };
bool result = false;
int file = -1;
file = open("/proc/self/auxv", O_RDONLY);
if (file == -1) {
cpuinfo_log_warning("failed to open /proc/self/auxv: %s", strerror(errno));
goto cleanup;
}
ssize_t bytes_read;
do {
Elf32_auxv_t elf_auxv;
bytes_read = read(file, &elf_auxv, sizeof(Elf32_auxv_t));
if (bytes_read < 0) {
cpuinfo_log_warning("failed to read /proc/self/auxv: %s", strerror(errno));
goto cleanup;
} else if (bytes_read > 0) {
if (bytes_read == sizeof(elf_auxv)) {
switch (elf_auxv.a_type) {
case AT_HWCAP:
hwcaps[0] = (uint32_t) elf_auxv.a_un.a_val;
break;
case AT_HWCAP2:
hwcaps[1] = (uint32_t) elf_auxv.a_un.a_val;
break;
}
} else {
cpuinfo_log_warning(
"failed to read %zu bytes from /proc/self/auxv: %zu bytes available",
sizeof(elf_auxv), (size_t) bytes_read);
goto cleanup;
}
}
} while (bytes_read == sizeof(Elf32_auxv_t));
/* Success, commit results */
*hwcap = hwcaps[0];
*hwcap2 = hwcaps[1];
result = true;
cleanup:
if (file != -1) {
close(file);
file = -1;
}
return result;
#endif
}
#endif /* __ANDROID__ */
#elif CPUINFO_ARCH_ARM64
void cpuinfo_arm_linux_hwcap_from_getauxval(
uint32_t hwcap[restrict static 1],
uint32_t hwcap2[restrict static 1])
{
#if CPUINFO_MOCK
*hwcap = mock_hwcap;
*hwcap2 = mock_hwcap2;
#else
*hwcap = (uint32_t) getauxval(AT_HWCAP);
*hwcap2 = (uint32_t) getauxval(AT_HWCAP2);
return ;
#endif
}
#endif

765
3rdparty/cpuinfo/src/arm/linux/init.c vendored Normal file
View File

@@ -0,0 +1,765 @@
#include <stdint.h>
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <cpuinfo.h>
#include <arm/linux/api.h>
#if defined(__ANDROID__)
#include <arm/android/api.h>
#endif
#include <arm/api.h>
#include <arm/midr.h>
#include <linux/api.h>
#include <cpuinfo/internal-api.h>
#include <cpuinfo/log.h>
struct cpuinfo_arm_isa cpuinfo_isa = { 0 };
static struct cpuinfo_package package = { { 0 } };
static inline bool bitmask_all(uint32_t bitfield, uint32_t mask) {
return (bitfield & mask) == mask;
}
static inline uint32_t min(uint32_t a, uint32_t b) {
return a < b ? a : b;
}
static inline int cmp(uint32_t a, uint32_t b) {
return (a > b) - (a < b);
}
static bool cluster_siblings_parser(
uint32_t processor, uint32_t siblings_start, uint32_t siblings_end,
struct cpuinfo_arm_linux_processor* processors)
{
processors[processor].flags |= CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER;
uint32_t package_leader_id = processors[processor].package_leader_id;
for (uint32_t sibling = siblings_start; sibling < siblings_end; sibling++) {
if (!bitmask_all(processors[sibling].flags, CPUINFO_LINUX_FLAG_VALID)) {
cpuinfo_log_info("invalid processor %"PRIu32" reported as a sibling for processor %"PRIu32,
sibling, processor);
continue;
}
const uint32_t sibling_package_leader_id = processors[sibling].package_leader_id;
if (sibling_package_leader_id < package_leader_id) {
package_leader_id = sibling_package_leader_id;
}
processors[sibling].package_leader_id = package_leader_id;
processors[sibling].flags |= CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER;
}
processors[processor].package_leader_id = package_leader_id;
return true;
}
static int cmp_arm_linux_processor(const void* ptr_a, const void* ptr_b) {
const struct cpuinfo_arm_linux_processor* processor_a = (const struct cpuinfo_arm_linux_processor*) ptr_a;
const struct cpuinfo_arm_linux_processor* processor_b = (const struct cpuinfo_arm_linux_processor*) ptr_b;
/* Move usable processors towards the start of the array */
const bool usable_a = bitmask_all(processor_a->flags, CPUINFO_LINUX_FLAG_VALID);
const bool usable_b = bitmask_all(processor_b->flags, CPUINFO_LINUX_FLAG_VALID);
if (usable_a != usable_b) {
return (int) usable_b - (int) usable_a;
}
/* Compare based on core type (e.g. Cortex-A57 < Cortex-A53) */
const uint32_t midr_a = processor_a->midr;
const uint32_t midr_b = processor_b->midr;
if (midr_a != midr_b) {
const uint32_t score_a = midr_score_core(midr_a);
const uint32_t score_b = midr_score_core(midr_b);
if (score_a != score_b) {
return score_a > score_b ? -1 : 1;
}
}
/* Compare based on core frequency (e.g. 2.0 GHz < 1.2 GHz) */
const uint32_t frequency_a = processor_a->max_frequency;
const uint32_t frequency_b = processor_b->max_frequency;
if (frequency_a != frequency_b) {
return frequency_a > frequency_b ? -1 : 1;
}
/* Compare based on cluster leader id (i.e. cluster 1 < cluster 0) */
const uint32_t cluster_a = processor_a->package_leader_id;
const uint32_t cluster_b = processor_b->package_leader_id;
if (cluster_a != cluster_b) {
return cluster_a > cluster_b ? -1 : 1;
}
/* Compare based on system processor id (i.e. processor 0 < processor 1) */
const uint32_t id_a = processor_a->system_processor_id;
const uint32_t id_b = processor_b->system_processor_id;
return cmp(id_a, id_b);
}
void cpuinfo_arm_linux_init(void) {
struct cpuinfo_arm_linux_processor* arm_linux_processors = NULL;
struct cpuinfo_processor* processors = NULL;
struct cpuinfo_core* cores = NULL;
struct cpuinfo_cluster* clusters = NULL;
struct cpuinfo_uarch_info* uarchs = NULL;
struct cpuinfo_cache* l1i = NULL;
struct cpuinfo_cache* l1d = NULL;
struct cpuinfo_cache* l2 = NULL;
struct cpuinfo_cache* l3 = NULL;
const struct cpuinfo_processor** linux_cpu_to_processor_map = NULL;
const struct cpuinfo_core** linux_cpu_to_core_map = NULL;
uint32_t* linux_cpu_to_uarch_index_map = NULL;
const uint32_t max_processors_count = cpuinfo_linux_get_max_processors_count();
cpuinfo_log_debug("system maximum processors count: %"PRIu32, max_processors_count);
const uint32_t max_possible_processors_count = 1 +
cpuinfo_linux_get_max_possible_processor(max_processors_count);
cpuinfo_log_debug("maximum possible processors count: %"PRIu32, max_possible_processors_count);
const uint32_t max_present_processors_count = 1 +
cpuinfo_linux_get_max_present_processor(max_processors_count);
cpuinfo_log_debug("maximum present processors count: %"PRIu32, max_present_processors_count);
uint32_t valid_processor_mask = 0;
uint32_t arm_linux_processors_count = max_processors_count;
if (max_present_processors_count != 0) {
arm_linux_processors_count = min(arm_linux_processors_count, max_present_processors_count);
valid_processor_mask = CPUINFO_LINUX_FLAG_PRESENT;
}
if (max_possible_processors_count != 0) {
arm_linux_processors_count = min(arm_linux_processors_count, max_possible_processors_count);
valid_processor_mask |= CPUINFO_LINUX_FLAG_POSSIBLE;
}
if ((max_present_processors_count | max_possible_processors_count) == 0) {
cpuinfo_log_error("failed to parse both lists of possible and present processors");
return;
}
arm_linux_processors = calloc(arm_linux_processors_count, sizeof(struct cpuinfo_arm_linux_processor));
if (arm_linux_processors == NULL) {
cpuinfo_log_error(
"failed to allocate %zu bytes for descriptions of %"PRIu32" ARM logical processors",
arm_linux_processors_count * sizeof(struct cpuinfo_arm_linux_processor),
arm_linux_processors_count);
return;
}
if (max_possible_processors_count) {
cpuinfo_linux_detect_possible_processors(
arm_linux_processors_count, &arm_linux_processors->flags,
sizeof(struct cpuinfo_arm_linux_processor),
CPUINFO_LINUX_FLAG_POSSIBLE);
}
if (max_present_processors_count) {
cpuinfo_linux_detect_present_processors(
arm_linux_processors_count, &arm_linux_processors->flags,
sizeof(struct cpuinfo_arm_linux_processor),
CPUINFO_LINUX_FLAG_PRESENT);
}
#if defined(__ANDROID__)
struct cpuinfo_android_properties android_properties;
cpuinfo_arm_android_parse_properties(&android_properties);
#else
char proc_cpuinfo_hardware[CPUINFO_HARDWARE_VALUE_MAX];
#endif
char proc_cpuinfo_revision[CPUINFO_REVISION_VALUE_MAX];
if (!cpuinfo_arm_linux_parse_proc_cpuinfo(
#if defined(__ANDROID__)
android_properties.proc_cpuinfo_hardware,
#else
proc_cpuinfo_hardware,
#endif
proc_cpuinfo_revision,
arm_linux_processors_count,
arm_linux_processors)) {
cpuinfo_log_error("failed to parse processor information from /proc/cpuinfo");
return;
}
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, valid_processor_mask)) {
arm_linux_processors[i].flags |= CPUINFO_LINUX_FLAG_VALID;
cpuinfo_log_debug("parsed processor %"PRIu32" MIDR 0x%08"PRIx32,
i, arm_linux_processors[i].midr);
}
}
uint32_t valid_processors = 0, last_midr = 0;
#if CPUINFO_ARCH_ARM
uint32_t last_architecture_version = 0, last_architecture_flags = 0;
#endif
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
arm_linux_processors[i].system_processor_id = i;
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
valid_processors += 1;
if (!(arm_linux_processors[i].flags & CPUINFO_ARM_LINUX_VALID_PROCESSOR)) {
/*
* Processor is in possible and present lists, but not reported in /proc/cpuinfo.
* This is fairly common: high-index processors can be not reported if they are offline.
*/
cpuinfo_log_info("processor %"PRIu32" is not listed in /proc/cpuinfo", i);
}
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_ARM_LINUX_VALID_MIDR)) {
last_midr = arm_linux_processors[i].midr;
}
#if CPUINFO_ARCH_ARM
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_ARM_LINUX_VALID_ARCHITECTURE)) {
last_architecture_version = arm_linux_processors[i].architecture_version;
last_architecture_flags = arm_linux_processors[i].architecture_flags;
}
#endif
} else {
/* Processor reported in /proc/cpuinfo, but not in possible and/or present lists: log and ignore */
if (!(arm_linux_processors[i].flags & CPUINFO_ARM_LINUX_VALID_PROCESSOR)) {
cpuinfo_log_warning("invalid processor %"PRIu32" reported in /proc/cpuinfo", i);
}
}
}
#if defined(__ANDROID__)
const struct cpuinfo_arm_chipset chipset =
cpuinfo_arm_android_decode_chipset(&android_properties, valid_processors, 0);
#else
const struct cpuinfo_arm_chipset chipset =
cpuinfo_arm_linux_decode_chipset(proc_cpuinfo_hardware, proc_cpuinfo_revision, valid_processors, 0);
#endif
#if CPUINFO_ARCH_ARM
uint32_t isa_features = 0, isa_features2 = 0;
#ifdef __ANDROID__
/*
* On Android before API 20, libc.so does not provide getauxval function.
* Thus, we try to dynamically find it, or use two fallback mechanisms:
* 1. dlopen libc.so, and try to find getauxval
* 2. Parse /proc/self/auxv procfs file
* 3. Use features reported in /proc/cpuinfo
*/
if (!cpuinfo_arm_linux_hwcap_from_getauxval(&isa_features, &isa_features2)) {
/* getauxval can't be used, fall back to parsing /proc/self/auxv */
if (!cpuinfo_arm_linux_hwcap_from_procfs(&isa_features, &isa_features2)) {
/*
* Reading /proc/self/auxv failed, probably due to file permissions.
* Use information from /proc/cpuinfo to detect ISA.
*
* If different processors report different ISA features, take the intersection.
*/
uint32_t processors_with_features = 0;
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID | CPUINFO_ARM_LINUX_VALID_FEATURES)) {
if (processors_with_features == 0) {
isa_features = arm_linux_processors[i].features;
isa_features2 = arm_linux_processors[i].features2;
} else {
isa_features &= arm_linux_processors[i].features;
isa_features2 &= arm_linux_processors[i].features2;
}
processors_with_features += 1;
}
}
}
}
#else
/* On GNU/Linux getauxval is always available */
cpuinfo_arm_linux_hwcap_from_getauxval(&isa_features, &isa_features2);
#endif
cpuinfo_arm_linux_decode_isa_from_proc_cpuinfo(
isa_features, isa_features2,
last_midr, last_architecture_version, last_architecture_flags,
&chipset, &cpuinfo_isa);
#elif CPUINFO_ARCH_ARM64
uint32_t isa_features = 0, isa_features2 = 0;
/* getauxval is always available on ARM64 Android */
cpuinfo_arm_linux_hwcap_from_getauxval(&isa_features, &isa_features2);
cpuinfo_arm64_linux_decode_isa_from_proc_cpuinfo(
isa_features, isa_features2, last_midr, &chipset, &cpuinfo_isa);
#endif
/* Detect min/max frequency and package ID */
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
const uint32_t max_frequency = cpuinfo_linux_get_processor_max_frequency(i);
if (max_frequency != 0) {
arm_linux_processors[i].max_frequency = max_frequency;
arm_linux_processors[i].flags |= CPUINFO_LINUX_FLAG_MAX_FREQUENCY;
}
const uint32_t min_frequency = cpuinfo_linux_get_processor_min_frequency(i);
if (min_frequency != 0) {
arm_linux_processors[i].min_frequency = min_frequency;
arm_linux_processors[i].flags |= CPUINFO_LINUX_FLAG_MIN_FREQUENCY;
}
if (cpuinfo_linux_get_processor_package_id(i, &arm_linux_processors[i].package_id)) {
arm_linux_processors[i].flags |= CPUINFO_LINUX_FLAG_PACKAGE_ID;
}
}
}
/* Initialize topology group IDs */
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
arm_linux_processors[i].package_leader_id = i;
}
/* Propagate topology group IDs among siblings */
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (!bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
continue;
}
if (arm_linux_processors[i].flags & CPUINFO_LINUX_FLAG_PACKAGE_ID) {
cpuinfo_linux_detect_core_siblings(
arm_linux_processors_count, i,
(cpuinfo_siblings_callback) cluster_siblings_parser,
arm_linux_processors);
}
}
/* Propagate all cluster IDs */
uint32_t clustered_processors = 0;
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID | CPUINFO_LINUX_FLAG_PACKAGE_CLUSTER)) {
clustered_processors += 1;
const uint32_t package_leader_id = arm_linux_processors[i].package_leader_id;
if (package_leader_id < i) {
arm_linux_processors[i].package_leader_id = arm_linux_processors[package_leader_id].package_leader_id;
}
cpuinfo_log_debug("processor %"PRIu32" clustered with processor %"PRIu32" as inferred from system siblings lists",
i, arm_linux_processors[i].package_leader_id);
}
}
if (clustered_processors != valid_processors) {
/*
* Topology information about some or all logical processors may be unavailable, for the following reasons:
* - Linux kernel is too old, or configured without support for topology information in sysfs.
* - Core is offline, and Linux kernel is configured to not report topology for offline cores.
*
* In this case, we assign processors to clusters using two methods:
* - Try heuristic cluster configurations (e.g. 6-core SoC usually has 4+2 big.LITTLE configuration).
* - If heuristic failed, assign processors to core clusters in a sequential scan.
*/
if (!cpuinfo_arm_linux_detect_core_clusters_by_heuristic(valid_processors, arm_linux_processors_count, arm_linux_processors)) {
cpuinfo_arm_linux_detect_core_clusters_by_sequential_scan(arm_linux_processors_count, arm_linux_processors);
}
}
cpuinfo_arm_linux_count_cluster_processors(arm_linux_processors_count, arm_linux_processors);
const uint32_t cluster_count = cpuinfo_arm_linux_detect_cluster_midr(
&chipset,
arm_linux_processors_count, valid_processors, arm_linux_processors);
/* Initialize core vendor, uarch, MIDR, and frequency for every logical processor */
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
const uint32_t cluster_leader = arm_linux_processors[i].package_leader_id;
if (cluster_leader == i) {
/* Cluster leader: decode core vendor and uarch */
cpuinfo_arm_decode_vendor_uarch(
arm_linux_processors[cluster_leader].midr,
#if CPUINFO_ARCH_ARM
!!(arm_linux_processors[cluster_leader].features & CPUINFO_ARM_LINUX_FEATURE_VFPV4),
#endif
&arm_linux_processors[cluster_leader].vendor,
&arm_linux_processors[cluster_leader].uarch);
} else {
/* Cluster non-leader: copy vendor, uarch, MIDR, and frequency from cluster leader */
arm_linux_processors[i].flags |= arm_linux_processors[cluster_leader].flags &
(CPUINFO_ARM_LINUX_VALID_MIDR | CPUINFO_LINUX_FLAG_MAX_FREQUENCY);
arm_linux_processors[i].midr = arm_linux_processors[cluster_leader].midr;
arm_linux_processors[i].vendor = arm_linux_processors[cluster_leader].vendor;
arm_linux_processors[i].uarch = arm_linux_processors[cluster_leader].uarch;
arm_linux_processors[i].max_frequency = arm_linux_processors[cluster_leader].max_frequency;
}
}
}
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
cpuinfo_log_debug("post-analysis processor %"PRIu32": MIDR %08"PRIx32" frequency %"PRIu32,
i, arm_linux_processors[i].midr, arm_linux_processors[i].max_frequency);
}
}
qsort(arm_linux_processors, arm_linux_processors_count,
sizeof(struct cpuinfo_arm_linux_processor), cmp_arm_linux_processor);
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
cpuinfo_log_debug("post-sort processor %"PRIu32": system id %"PRIu32" MIDR %08"PRIx32" frequency %"PRIu32,
i, arm_linux_processors[i].system_processor_id, arm_linux_processors[i].midr, arm_linux_processors[i].max_frequency);
}
}
uint32_t uarchs_count = 0;
enum cpuinfo_uarch last_uarch;
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (uarchs_count == 0 || arm_linux_processors[i].uarch != last_uarch) {
last_uarch = arm_linux_processors[i].uarch;
uarchs_count += 1;
}
arm_linux_processors[i].uarch_index = uarchs_count - 1;
}
}
/*
* Assumptions:
* - No SMP (i.e. each core supports only one hardware thread).
* - Level 1 instruction and data caches are private to the core clusters.
* - Level 2 and level 3 cache is shared between cores in the same cluster.
*/
cpuinfo_arm_chipset_to_string(&chipset, package.name);
package.processor_count = valid_processors;
package.core_count = valid_processors;
package.cluster_count = cluster_count;
processors = calloc(valid_processors, sizeof(struct cpuinfo_processor));
if (processors == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" logical processors",
valid_processors * sizeof(struct cpuinfo_processor), valid_processors);
goto cleanup;
}
cores = calloc(valid_processors, sizeof(struct cpuinfo_core));
if (cores == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" cores",
valid_processors * sizeof(struct cpuinfo_core), valid_processors);
goto cleanup;
}
clusters = calloc(cluster_count, sizeof(struct cpuinfo_cluster));
if (clusters == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" core clusters",
cluster_count * sizeof(struct cpuinfo_cluster), cluster_count);
goto cleanup;
}
uarchs = calloc(uarchs_count, sizeof(struct cpuinfo_uarch_info));
if (uarchs == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" microarchitectures",
uarchs_count * sizeof(struct cpuinfo_uarch_info), uarchs_count);
goto cleanup;
}
linux_cpu_to_processor_map = calloc(arm_linux_processors_count, sizeof(struct cpuinfo_processor*));
if (linux_cpu_to_processor_map == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for %"PRIu32" logical processor mapping entries",
arm_linux_processors_count * sizeof(struct cpuinfo_processor*), arm_linux_processors_count);
goto cleanup;
}
linux_cpu_to_core_map = calloc(arm_linux_processors_count, sizeof(struct cpuinfo_core*));
if (linux_cpu_to_core_map == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for %"PRIu32" core mapping entries",
arm_linux_processors_count * sizeof(struct cpuinfo_core*), arm_linux_processors_count);
goto cleanup;
}
if (uarchs_count > 1) {
linux_cpu_to_uarch_index_map = calloc(arm_linux_processors_count, sizeof(uint32_t));
if (linux_cpu_to_uarch_index_map == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for %"PRIu32" uarch index mapping entries",
arm_linux_processors_count * sizeof(uint32_t), arm_linux_processors_count);
goto cleanup;
}
}
l1i = calloc(valid_processors, sizeof(struct cpuinfo_cache));
if (l1i == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L1I caches",
valid_processors * sizeof(struct cpuinfo_cache), valid_processors);
goto cleanup;
}
l1d = calloc(valid_processors, sizeof(struct cpuinfo_cache));
if (l1d == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L1D caches",
valid_processors * sizeof(struct cpuinfo_cache), valid_processors);
goto cleanup;
}
uint32_t uarchs_index = 0;
for (uint32_t i = 0; i < arm_linux_processors_count; i++) {
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (uarchs_index == 0 || arm_linux_processors[i].uarch != last_uarch) {
last_uarch = arm_linux_processors[i].uarch;
uarchs[uarchs_index] = (struct cpuinfo_uarch_info) {
.uarch = arm_linux_processors[i].uarch,
.midr = arm_linux_processors[i].midr,
};
uarchs_index += 1;
}
uarchs[uarchs_index - 1].processor_count += 1;
uarchs[uarchs_index - 1].core_count += 1;
}
}
uint32_t l2_count = 0, l3_count = 0, big_l3_size = 0, cluster_id = UINT32_MAX;
/* Indication whether L3 (if it exists) is shared between all cores */
bool shared_l3 = true;
/* Populate cache infromation structures in l1i, l1d */
for (uint32_t i = 0; i < valid_processors; i++) {
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
cluster_id += 1;
clusters[cluster_id] = (struct cpuinfo_cluster) {
.processor_start = i,
.processor_count = arm_linux_processors[i].package_processor_count,
.core_start = i,
.core_count = arm_linux_processors[i].package_processor_count,
.cluster_id = cluster_id,
.package = &package,
.vendor = arm_linux_processors[i].vendor,
.uarch = arm_linux_processors[i].uarch,
.midr = arm_linux_processors[i].midr,
};
}
processors[i].smt_id = 0;
processors[i].core = cores + i;
processors[i].cluster = clusters + cluster_id;
processors[i].package = &package;
processors[i].linux_id = (int) arm_linux_processors[i].system_processor_id;
processors[i].cache.l1i = l1i + i;
processors[i].cache.l1d = l1d + i;
linux_cpu_to_processor_map[arm_linux_processors[i].system_processor_id] = &processors[i];
cores[i].processor_start = i;
cores[i].processor_count = 1;
cores[i].core_id = i;
cores[i].cluster = clusters + cluster_id;
cores[i].package = &package;
cores[i].vendor = arm_linux_processors[i].vendor;
cores[i].uarch = arm_linux_processors[i].uarch;
cores[i].midr = arm_linux_processors[i].midr;
linux_cpu_to_core_map[arm_linux_processors[i].system_processor_id] = &cores[i];
if (linux_cpu_to_uarch_index_map != NULL) {
linux_cpu_to_uarch_index_map[arm_linux_processors[i].system_processor_id] =
arm_linux_processors[i].uarch_index;
}
struct cpuinfo_cache temp_l2 = { 0 }, temp_l3 = { 0 };
cpuinfo_arm_decode_cache(
arm_linux_processors[i].uarch,
arm_linux_processors[i].package_processor_count,
arm_linux_processors[i].midr,
&chipset,
cluster_id,
arm_linux_processors[i].architecture_version,
&l1i[i], &l1d[i], &temp_l2, &temp_l3);
l1i[i].processor_start = l1d[i].processor_start = i;
l1i[i].processor_count = l1d[i].processor_count = 1;
#if CPUINFO_ARCH_ARM
/* L1I reported in /proc/cpuinfo overrides defaults */
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_ARM_LINUX_VALID_ICACHE)) {
l1i[i] = (struct cpuinfo_cache) {
.size = arm_linux_processors[i].proc_cpuinfo_cache.i_size,
.associativity = arm_linux_processors[i].proc_cpuinfo_cache.i_assoc,
.sets = arm_linux_processors[i].proc_cpuinfo_cache.i_sets,
.partitions = 1,
.line_size = arm_linux_processors[i].proc_cpuinfo_cache.i_line_length
};
}
/* L1D reported in /proc/cpuinfo overrides defaults */
if (bitmask_all(arm_linux_processors[i].flags, CPUINFO_ARM_LINUX_VALID_DCACHE)) {
l1d[i] = (struct cpuinfo_cache) {
.size = arm_linux_processors[i].proc_cpuinfo_cache.d_size,
.associativity = arm_linux_processors[i].proc_cpuinfo_cache.d_assoc,
.sets = arm_linux_processors[i].proc_cpuinfo_cache.d_sets,
.partitions = 1,
.line_size = arm_linux_processors[i].proc_cpuinfo_cache.d_line_length
};
}
#endif
if (temp_l3.size != 0) {
/*
* Assumptions:
* - L2 is private to each core
* - L3 is shared by cores in the same cluster
* - If cores in different clusters report the same L3, it is shared between all cores.
*/
l2_count += 1;
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
if (cluster_id == 0) {
big_l3_size = temp_l3.size;
l3_count = 1;
} else if (temp_l3.size != big_l3_size) {
/* If some cores have different L3 size, L3 is not shared between all cores */
shared_l3 = false;
l3_count += 1;
}
}
} else {
/* If some cores don't have L3 cache, L3 is not shared between all cores */
shared_l3 = false;
if (temp_l2.size != 0) {
/* Assume L2 is shared by cores in the same cluster */
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
l2_count += 1;
}
}
}
}
if (l2_count != 0) {
l2 = calloc(l2_count, sizeof(struct cpuinfo_cache));
if (l2 == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L2 caches",
l2_count * sizeof(struct cpuinfo_cache), l2_count);
goto cleanup;
}
if (l3_count != 0) {
l3 = calloc(l3_count, sizeof(struct cpuinfo_cache));
if (l3 == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L3 caches",
l3_count * sizeof(struct cpuinfo_cache), l3_count);
goto cleanup;
}
}
}
cluster_id = UINT32_MAX;
uint32_t l2_index = UINT32_MAX, l3_index = UINT32_MAX;
for (uint32_t i = 0; i < valid_processors; i++) {
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
cluster_id++;
}
struct cpuinfo_cache dummy_l1i, dummy_l1d, temp_l2 = { 0 }, temp_l3 = { 0 };
cpuinfo_arm_decode_cache(
arm_linux_processors[i].uarch,
arm_linux_processors[i].package_processor_count,
arm_linux_processors[i].midr,
&chipset,
cluster_id,
arm_linux_processors[i].architecture_version,
&dummy_l1i, &dummy_l1d, &temp_l2, &temp_l3);
if (temp_l3.size != 0) {
/*
* Assumptions:
* - L2 is private to each core
* - L3 is shared by cores in the same cluster
* - If cores in different clusters report the same L3, it is shared between all cores.
*/
l2_index += 1;
l2[l2_index] = (struct cpuinfo_cache) {
.size = temp_l2.size,
.associativity = temp_l2.associativity,
.sets = temp_l2.sets,
.partitions = 1,
.line_size = temp_l2.line_size,
.flags = temp_l2.flags,
.processor_start = i,
.processor_count = 1,
};
processors[i].cache.l2 = l2 + l2_index;
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
l3_index += 1;
if (l3_index < l3_count) {
l3[l3_index] = (struct cpuinfo_cache) {
.size = temp_l3.size,
.associativity = temp_l3.associativity,
.sets = temp_l3.sets,
.partitions = 1,
.line_size = temp_l3.line_size,
.flags = temp_l3.flags,
.processor_start = i,
.processor_count =
shared_l3 ? valid_processors : arm_linux_processors[i].package_processor_count,
};
}
}
if (shared_l3) {
processors[i].cache.l3 = l3;
} else if (l3_index < l3_count) {
processors[i].cache.l3 = l3 + l3_index;
}
} else if (temp_l2.size != 0) {
/* Assume L2 is shared by cores in the same cluster */
if (arm_linux_processors[i].package_leader_id == arm_linux_processors[i].system_processor_id) {
l2_index += 1;
l2[l2_index] = (struct cpuinfo_cache) {
.size = temp_l2.size,
.associativity = temp_l2.associativity,
.sets = temp_l2.sets,
.partitions = 1,
.line_size = temp_l2.line_size,
.flags = temp_l2.flags,
.processor_start = i,
.processor_count = arm_linux_processors[i].package_processor_count,
};
}
processors[i].cache.l2 = l2 + l2_index;
}
}
/* Commit */
cpuinfo_processors = processors;
cpuinfo_cores = cores;
cpuinfo_clusters = clusters;
cpuinfo_packages = &package;
cpuinfo_uarchs = uarchs;
cpuinfo_cache[cpuinfo_cache_level_1i] = l1i;
cpuinfo_cache[cpuinfo_cache_level_1d] = l1d;
cpuinfo_cache[cpuinfo_cache_level_2] = l2;
cpuinfo_cache[cpuinfo_cache_level_3] = l3;
cpuinfo_processors_count = valid_processors;
cpuinfo_cores_count = valid_processors;
cpuinfo_clusters_count = cluster_count;
cpuinfo_packages_count = 1;
cpuinfo_uarchs_count = uarchs_count;
cpuinfo_cache_count[cpuinfo_cache_level_1i] = valid_processors;
cpuinfo_cache_count[cpuinfo_cache_level_1d] = valid_processors;
cpuinfo_cache_count[cpuinfo_cache_level_2] = l2_count;
cpuinfo_cache_count[cpuinfo_cache_level_3] = l3_count;
cpuinfo_max_cache_size = cpuinfo_arm_compute_max_cache_size(&processors[0]);
cpuinfo_linux_cpu_max = arm_linux_processors_count;
cpuinfo_linux_cpu_to_processor_map = linux_cpu_to_processor_map;
cpuinfo_linux_cpu_to_core_map = linux_cpu_to_core_map;
cpuinfo_linux_cpu_to_uarch_index_map = linux_cpu_to_uarch_index_map;
__sync_synchronize();
cpuinfo_is_initialized = true;
processors = NULL;
cores = NULL;
clusters = NULL;
uarchs = NULL;
l1i = l1d = l2 = l3 = NULL;
linux_cpu_to_processor_map = NULL;
linux_cpu_to_core_map = NULL;
linux_cpu_to_uarch_index_map = NULL;
cleanup:
free(arm_linux_processors);
free(processors);
free(cores);
free(clusters);
free(uarchs);
free(l1i);
free(l1d);
free(l2);
free(l3);
free(linux_cpu_to_processor_map);
free(linux_cpu_to_core_map);
free(linux_cpu_to_uarch_index_map);
}

863
3rdparty/cpuinfo/src/arm/linux/midr.c vendored Normal file
View File

@@ -0,0 +1,863 @@
#include <stdint.h>
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include <cpuinfo.h>
#include <arm/linux/api.h>
#if defined(__ANDROID__)
#include <arm/android/api.h>
#endif
#include <arm/api.h>
#include <arm/midr.h>
#include <linux/api.h>
#include <cpuinfo/internal-api.h>
#include <cpuinfo/log.h>
#include <cpuinfo/common.h>
#define CLUSTERS_MAX 3
static inline bool bitmask_all(uint32_t bitfield, uint32_t mask) {
return (bitfield & mask) == mask;
}
/* Description of core clusters configuration in a chipset (identified by series and model number) */
struct cluster_config {
/* Number of cores (logical processors) */
uint8_t cores;
/* ARM chipset series (see cpuinfo_arm_chipset_series enum) */
uint8_t series;
/* Chipset model number (see cpuinfo_arm_chipset struct) */
uint16_t model;
/* Number of heterogenous clusters in the CPU package */
uint8_t clusters;
/*
* Number of cores in each cluster:
# - Symmetric configurations: [0] = # cores
* - big.LITTLE configurations: [0] = # LITTLE cores, [1] = # big cores
* - Max.Med.Min configurations: [0] = # Min cores, [1] = # Med cores, [2] = # Max cores
*/
uint8_t cluster_cores[CLUSTERS_MAX];
/*
* MIDR of cores in each cluster:
* - Symmetric configurations: [0] = core MIDR
* - big.LITTLE configurations: [0] = LITTLE core MIDR, [1] = big core MIDR
* - Max.Med.Min configurations: [0] = Min core MIDR, [1] = Med core MIDR, [2] = Max core MIDR
*/
uint32_t cluster_midr[CLUSTERS_MAX];
};
/*
* The list of chipsets where MIDR may not be unambigiously decoded at least on some devices.
* The typical reasons for impossibility to decoded MIDRs are buggy kernels, which either do not report all MIDR
* information (e.g. on ATM7029 kernel doesn't report CPU Part), or chipsets have more than one type of cores
* (i.e. 4x Cortex-A53 + 4x Cortex-A53 is out) and buggy kernels report MIDR information only about some cores
* in /proc/cpuinfo (either only online cores, or only the core that reads /proc/cpuinfo). On these kernels/chipsets,
* it is not possible to detect all core types by just parsing /proc/cpuinfo, so we use chipset name and this table to
* find their MIDR (and thus microarchitecture, cache, etc).
*
* Note: not all chipsets with heterogeneous multiprocessing need an entry in this table. The following HMP
* chipsets always list information about all cores in /proc/cpuinfo:
*
* - Snapdragon 660
* - Snapdragon 820 (MSM8996)
* - Snapdragon 821 (MSM8996PRO)
* - Snapdragon 835 (MSM8998)
* - Exynos 8895
* - Kirin 960
*
* As these are all new processors, there is hope that this table won't uncontrollably grow over time.
*/
static const struct cluster_config cluster_configs[] = {
#if CPUINFO_ARCH_ARM
{
/*
* MSM8916 (Snapdragon 410): 4x Cortex-A53
* Some AArch32 phones use non-standard /proc/cpuinfo format.
*/
.cores = 4,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8916),
.clusters = 1,
.cluster_cores = {
[0] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD030),
},
},
{
/*
* MSM8939 (Snapdragon 615): 4x Cortex-A53 + 4x Cortex-A53
* Some AArch32 phones use non-standard /proc/cpuinfo format.
*/
.cores = 8,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8939),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD034),
},
},
#endif
{
/* MSM8956 (Snapdragon 650): 2x Cortex-A72 + 4x Cortex-A53 */
.cores = 6,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8956),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD080),
},
},
{
/* MSM8976/MSM8976PRO (Snapdragon 652/653): 4x Cortex-A72 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8976),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD080),
},
},
{
/* MSM8992 (Snapdragon 808): 2x Cortex-A57 + 4x Cortex-A53 */
.cores = 6,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8992),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD033),
[1] = UINT32_C(0x411FD072),
},
},
{
/* MSM8994/MSM8994V (Snapdragon 810): 4x Cortex-A57 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_qualcomm_msm,
.model = UINT16_C(8994),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD032),
[1] = UINT32_C(0x411FD071),
},
},
#if CPUINFO_ARCH_ARM
{
/* Exynos 5422: 4x Cortex-A15 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_samsung_exynos,
.model = UINT16_C(5422),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC073),
[1] = UINT32_C(0x412FC0F3),
},
},
{
/* Exynos 5430: 4x Cortex-A15 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_samsung_exynos,
.model = UINT16_C(5430),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC074),
[1] = UINT32_C(0x413FC0F3),
},
},
#endif /* CPUINFO_ARCH_ARM */
{
/* Exynos 5433: 4x Cortex-A57 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_samsung_exynos,
.model = UINT16_C(5433),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD031),
[1] = UINT32_C(0x411FD070),
},
},
{
/* Exynos 7420: 4x Cortex-A57 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_samsung_exynos,
.model = UINT16_C(7420),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD032),
[1] = UINT32_C(0x411FD070),
},
},
{
/* Exynos 8890: 4x Exynos M1 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_samsung_exynos,
.model = UINT16_C(8890),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x531F0011),
},
},
#if CPUINFO_ARCH_ARM
{
/* Kirin 920: 4x Cortex-A15 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_hisilicon_kirin,
.model = UINT16_C(920),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC075),
[1] = UINT32_C(0x413FC0F3),
},
},
{
/* Kirin 925: 4x Cortex-A15 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_hisilicon_kirin,
.model = UINT16_C(925),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC075),
[1] = UINT32_C(0x413FC0F3),
},
},
{
/* Kirin 928: 4x Cortex-A15 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_hisilicon_kirin,
.model = UINT16_C(928),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC075),
[1] = UINT32_C(0x413FC0F3),
},
},
#endif /* CPUINFO_ARCH_ARM */
{
/* Kirin 950: 4x Cortex-A72 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_hisilicon_kirin,
.model = UINT16_C(950),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD080),
},
},
{
/* Kirin 955: 4x Cortex-A72 + 4x Cortex-A53 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_hisilicon_kirin,
.model = UINT16_C(955),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD080),
},
},
#if CPUINFO_ARCH_ARM
{
/* MediaTek MT8135: 2x Cortex-A7 + 2x Cortex-A15 */
.cores = 4,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(8135),
.clusters = 2,
.cluster_cores = {
[0] = 2,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC073),
[1] = UINT32_C(0x413FC0F2),
},
},
#endif
{
/* MediaTek MT8173: 2x Cortex-A72 + 2x Cortex-A53 */
.cores = 4,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(8173),
.clusters = 2,
.cluster_cores = {
[0] = 2,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD032),
[1] = UINT32_C(0x410FD080),
},
},
{
/* MediaTek MT8176: 2x Cortex-A72 + 4x Cortex-A53 */
.cores = 6,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(8176),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD032),
[1] = UINT32_C(0x410FD080),
},
},
#if CPUINFO_ARCH_ARM64
{
/*
* MediaTek MT8735: 4x Cortex-A53
* Some AArch64 phones use non-standard /proc/cpuinfo format.
*/
.cores = 4,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(8735),
.clusters = 1,
.cluster_cores = {
[0] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
},
},
#endif
#if CPUINFO_ARCH_ARM
{
/*
* MediaTek MT6592: 4x Cortex-A7 + 4x Cortex-A7
* Some phones use non-standard /proc/cpuinfo format.
*/
.cores = 4,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(6592),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC074),
[1] = UINT32_C(0x410FC074),
},
},
{
/* MediaTek MT6595: 4x Cortex-A17 + 4x Cortex-A7 */
.cores = 8,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(6595),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC075),
[1] = UINT32_C(0x410FC0E0),
},
},
#endif
{
/* MediaTek MT6797: 2x Cortex-A72 + 4x Cortex-A53 + 4x Cortex-A53 */
.cores = 10,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(6797),
.clusters = 3,
.cluster_cores = {
[0] = 4,
[1] = 4,
[2] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD034),
[2] = UINT32_C(0x410FD081),
},
},
{
/* MediaTek MT6799: 2x Cortex-A73 + 4x Cortex-A53 + 4x Cortex-A35 */
.cores = 10,
.series = cpuinfo_arm_chipset_series_mediatek_mt,
.model = UINT16_C(6799),
.clusters = 3,
.cluster_cores = {
[0] = 4,
[1] = 4,
[2] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD041),
[1] = UINT32_C(0x410FD034),
[2] = UINT32_C(0x410FD092),
},
},
{
/* Rockchip RK3399: 2x Cortex-A72 + 4x Cortex-A53 */
.cores = 6,
.series = cpuinfo_arm_chipset_series_rockchip_rk,
.model = UINT16_C(3399),
.clusters = 2,
.cluster_cores = {
[0] = 4,
[1] = 2,
},
.cluster_midr = {
[0] = UINT32_C(0x410FD034),
[1] = UINT32_C(0x410FD082),
},
},
#if CPUINFO_ARCH_ARM
{
/* Actions ATM8029: 4x Cortex-A5
* Most devices use non-standard /proc/cpuinfo format.
*/
.cores = 4,
.series = cpuinfo_arm_chipset_series_actions_atm,
.model = UINT16_C(7029),
.clusters = 1,
.cluster_cores = {
[0] = 4,
},
.cluster_midr = {
[0] = UINT32_C(0x410FC051),
},
},
#endif
};
/*
* Searches chipset name in mapping of chipset name to cores' MIDR values. If match is successful, initializes MIDR
* for all clusters' leaders with tabulated values.
*
* @param[in] chipset - chipset (SoC) name information.
* @param clusters_count - number of CPU core clusters detected in the SoC.
* @param cluster_leaders - indices of core clusters' leaders in the @p processors array.
* @param processors_count - number of usable logical processors in the system.
* @param[in,out] processors - array of logical processor descriptions with pre-parsed MIDR, maximum frequency,
* and decoded core cluster (package_leader_id) information.
* Upon successful return, processors[i].midr for all clusters' leaders contains the
* tabulated MIDR values.
* @param verify_midr - indicated whether the function should check that the MIDR values to be assigned to leaders of
* core clusters are consistent with known parts of their parsed values.
* Set if to false if the only MIDR value parsed from /proc/cpuinfo is for the last processor
* reported in /proc/cpuinfo and thus can't be unambiguously attributed to that processor.
*
* @retval true if the chipset was found in the mapping and core clusters' leaders initialized with MIDR values.
* @retval false if the chipset was not found in the mapping, or any consistency check failed.
*/
static bool cpuinfo_arm_linux_detect_cluster_midr_by_chipset(
const struct cpuinfo_arm_chipset chipset[restrict static 1],
uint32_t clusters_count,
const uint32_t cluster_leaders[restrict static CLUSTERS_MAX],
uint32_t processors_count,
struct cpuinfo_arm_linux_processor processors[restrict static processors_count],
bool verify_midr)
{
if (clusters_count <= CLUSTERS_MAX) {
for (uint32_t c = 0; c < CPUINFO_COUNT_OF(cluster_configs); c++) {
if (cluster_configs[c].model == chipset->model && cluster_configs[c].series == chipset->series) {
/* Verify that the total number of cores and clusters of cores matches expectation */
if (cluster_configs[c].cores != processors_count || cluster_configs[c].clusters != clusters_count) {
return false;
}
/* Verify that core cluster configuration matches expectation */
for (uint32_t cluster = 0; cluster < clusters_count; cluster++) {
const uint32_t cluster_leader = cluster_leaders[cluster];
if (cluster_configs[c].cluster_cores[cluster] != processors[cluster_leader].package_processor_count) {
return false;
}
}
if (verify_midr) {
/* Verify known parts of MIDR */
for (uint32_t cluster = 0; cluster < clusters_count; cluster++) {
const uint32_t cluster_leader = cluster_leaders[cluster];
/* Create a mask of known midr bits */
uint32_t midr_mask = 0;
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
midr_mask |= CPUINFO_ARM_MIDR_IMPLEMENTER_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
midr_mask |= CPUINFO_ARM_MIDR_VARIANT_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_PART) {
midr_mask |= CPUINFO_ARM_MIDR_PART_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
midr_mask |= CPUINFO_ARM_MIDR_REVISION_MASK;
}
/* Verify the bits under the mask */
if ((processors[cluster_leader].midr ^ cluster_configs[c].cluster_midr[cluster]) & midr_mask) {
cpuinfo_log_debug("parsed MIDR of cluster %08"PRIu32" does not match tabulated value %08"PRIu32,
processors[cluster_leader].midr, cluster_configs[c].cluster_midr[cluster]);
return false;
}
}
}
/* Assign MIDRs according to tabulated configurations */
for (uint32_t cluster = 0; cluster < clusters_count; cluster++) {
const uint32_t cluster_leader = cluster_leaders[cluster];
processors[cluster_leader].midr = cluster_configs[c].cluster_midr[cluster];
processors[cluster_leader].flags |= CPUINFO_ARM_LINUX_VALID_MIDR;
cpuinfo_log_debug("cluster %"PRIu32" MIDR = 0x%08"PRIx32, cluster, cluster_configs[c].cluster_midr[cluster]);
}
return true;
}
}
}
return false;
}
/*
* Initializes MIDR for leaders of core clusters using a heuristic for big.LITTLE systems:
* - If the only known MIDR is for the big core cluster, guess the matching MIDR for the LITTLE cluster.
* - Estimate which of the clusters is big using maximum frequency, if known, otherwise using system processor ID.
* - Initialize the MIDR for big and LITTLE core clusters using the guesstimates values.
*
* @param clusters_count - number of CPU core clusters detected in the SoC.
* @param cluster_with_midr_count - number of CPU core clusters in the SoC with known MIDR values.
* @param last_processor_with_midr - index of the last logical processor with known MIDR in the @p processors array.
* @param cluster_leaders - indices of core clusters' leaders in the @p processors array.
* @param[in,out] processors - array of logical processor descriptions with pre-parsed MIDR, maximum frequency,
* and decoded core cluster (package_leader_id) information.
* Upon successful return, processors[i].midr for all core clusters' leaders contains
* the heuristically detected MIDR value.
* @param verify_midr - indicated whether the function should check that the MIDR values to be assigned to leaders of
* core clusters are consistent with known parts of their parsed values.
* Set if to false if the only MIDR value parsed from /proc/cpuinfo is for the last processor
* reported in /proc/cpuinfo and thus can't be unambiguously attributed to that processor.
*
* @retval true if this is a big.LITTLE system with only one known MIDR and the CPU core clusters' leaders were
* initialized with MIDR values.
* @retval false if this is not a big.LITTLE system.
*/
static bool cpuinfo_arm_linux_detect_cluster_midr_by_big_little_heuristic(
uint32_t clusters_count,
uint32_t cluster_with_midr_count,
uint32_t last_processor_with_midr,
const uint32_t cluster_leaders[restrict static CLUSTERS_MAX],
struct cpuinfo_arm_linux_processor processors[restrict static last_processor_with_midr],
bool verify_midr)
{
if (clusters_count != 2 || cluster_with_midr_count != 1) {
/* Not a big.LITTLE system, or MIDR is known for both/neither clusters */
return false;
}
const uint32_t midr_flags =
(processors[processors[last_processor_with_midr].package_leader_id].flags & CPUINFO_ARM_LINUX_VALID_MIDR);
const uint32_t big_midr = processors[processors[last_processor_with_midr].package_leader_id].midr;
const uint32_t little_midr = midr_little_core_for_big(big_midr);
/* Default assumption: the first reported cluster is LITTLE cluster (this holds on most Linux kernels) */
uint32_t little_cluster_leader = cluster_leaders[0];
const uint32_t other_cluster_leader = cluster_leaders[1];
/* If maximum frequency is known for both clusters, assume LITTLE cluster is the one with lower frequency */
if (processors[little_cluster_leader].flags & processors[other_cluster_leader].flags & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
if (processors[little_cluster_leader].max_frequency > processors[other_cluster_leader].max_frequency) {
little_cluster_leader = other_cluster_leader;
}
}
if (verify_midr) {
/* Verify known parts of MIDR */
for (uint32_t cluster = 0; cluster < clusters_count; cluster++) {
const uint32_t cluster_leader = cluster_leaders[cluster];
/* Create a mask of known midr bits */
uint32_t midr_mask = 0;
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_IMPLEMENTER) {
midr_mask |= CPUINFO_ARM_MIDR_IMPLEMENTER_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_VARIANT) {
midr_mask |= CPUINFO_ARM_MIDR_VARIANT_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_PART) {
midr_mask |= CPUINFO_ARM_MIDR_PART_MASK;
}
if (processors[cluster_leader].flags & CPUINFO_ARM_LINUX_VALID_REVISION) {
midr_mask |= CPUINFO_ARM_MIDR_REVISION_MASK;
}
/* Verify the bits under the mask */
const uint32_t midr = (cluster_leader == little_cluster_leader) ? little_midr : big_midr;
if ((processors[cluster_leader].midr ^ midr) & midr_mask) {
cpuinfo_log_debug(
"parsed MIDR %08"PRIu32" of cluster leader %"PRIu32" is inconsistent with expected value %08"PRIu32,
processors[cluster_leader].midr, cluster_leader, midr);
return false;
}
}
}
for (uint32_t c = 0; c < clusters_count; c++) {
/* Skip cluster with already assigned MIDR */
const uint32_t cluster_leader = cluster_leaders[c];
if (bitmask_all(processors[cluster_leader].flags, CPUINFO_ARM_LINUX_VALID_MIDR)) {
continue;
}
const uint32_t midr = (cluster_leader == little_cluster_leader) ? little_midr : big_midr;
cpuinfo_log_info("assume processor %"PRIu32" to have MIDR %08"PRIx32, cluster_leader, midr);
/* To be consistent, we copy the MIDR entirely, rather than by parts */
processors[cluster_leader].midr = midr;
processors[cluster_leader].flags |= midr_flags;
}
return true;
}
/*
* Initializes MIDR for leaders of core clusters in a single sequential scan:
* - Clusters preceeding the first reported MIDR value are assumed to have default MIDR value.
* - Clusters following any reported MIDR value to have that MIDR value.
*
* @param default_midr - MIDR value that will be assigned to cluster leaders preceeding any reported MIDR value.
* @param processors_count - number of logical processor descriptions in the @p processors array.
* @param[in,out] processors - array of logical processor descriptions with pre-parsed MIDR, maximum frequency,
* and decoded core cluster (package_leader_id) information.
* Upon successful return, processors[i].midr for all core clusters' leaders contains
* the assigned MIDR value.
*/
static void cpuinfo_arm_linux_detect_cluster_midr_by_sequential_scan(
uint32_t default_midr,
uint32_t processors_count,
struct cpuinfo_arm_linux_processor processors[restrict static processors_count])
{
uint32_t midr = default_midr;
for (uint32_t i = 0; i < processors_count; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (processors[i].package_leader_id == i) {
if (bitmask_all(processors[i].flags, CPUINFO_ARM_LINUX_VALID_MIDR)) {
midr = processors[i].midr;
} else {
cpuinfo_log_info("assume processor %"PRIu32" to have MIDR %08"PRIx32, i, midr);
/* To be consistent, we copy the MIDR entirely, rather than by parts */
processors[i].midr = midr;
processors[i].flags |= CPUINFO_ARM_LINUX_VALID_MIDR;
}
}
}
}
}
/*
* Detects MIDR of each CPU core clusters' leader.
*
* @param[in] chipset - chipset (SoC) name information.
* @param max_processors - number of processor descriptions in the @p processors array.
* @param usable_processors - number of processor descriptions in the @p processors array with both POSSIBLE and
* PRESENT flags.
* @param[in,out] processors - array of logical processor descriptions with pre-parsed MIDR, maximum frequency,
* and decoded core cluster (package_leader_id) information.
* Upon return, processors[i].midr for all clusters' leaders contains the MIDR value.
*
* @returns The number of core clusters
*/
uint32_t cpuinfo_arm_linux_detect_cluster_midr(
const struct cpuinfo_arm_chipset chipset[restrict static 1],
uint32_t max_processors,
uint32_t usable_processors,
struct cpuinfo_arm_linux_processor processors[restrict static max_processors])
{
uint32_t clusters_count = 0;
uint32_t cluster_leaders[CLUSTERS_MAX];
uint32_t last_processor_in_cpuinfo = max_processors;
uint32_t last_processor_with_midr = max_processors;
uint32_t processors_with_midr_count = 0;
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID)) {
if (processors[i].flags & CPUINFO_ARM_LINUX_VALID_PROCESSOR) {
last_processor_in_cpuinfo = i;
}
if (bitmask_all(processors[i].flags, CPUINFO_ARM_LINUX_VALID_IMPLEMENTER | CPUINFO_ARM_LINUX_VALID_PART)) {
last_processor_with_midr = i;
processors_with_midr_count += 1;
}
const uint32_t group_leader = processors[i].package_leader_id;
if (group_leader == i) {
if (clusters_count < CLUSTERS_MAX) {
cluster_leaders[clusters_count] = i;
}
clusters_count += 1;
} else {
/* Copy known bits of information to cluster leader */
if ((processors[i].flags & ~processors[group_leader].flags) & CPUINFO_LINUX_FLAG_MAX_FREQUENCY) {
processors[group_leader].max_frequency = processors[i].max_frequency;
processors[group_leader].flags |= CPUINFO_LINUX_FLAG_MAX_FREQUENCY;
}
if (!bitmask_all(processors[group_leader].flags, CPUINFO_ARM_LINUX_VALID_MIDR) &&
bitmask_all(processors[i].flags, CPUINFO_ARM_LINUX_VALID_MIDR))
{
processors[group_leader].midr = processors[i].midr;
processors[group_leader].flags |= CPUINFO_ARM_LINUX_VALID_MIDR;
}
}
}
}
cpuinfo_log_debug("detected %"PRIu32" core clusters", clusters_count);
/*
* Two relations between reported /proc/cpuinfo information, and cores is possible:
* - /proc/cpuinfo reports information for all or some of the cores below the corresponding
* "processor : <number>" lines. Information on offline cores may be missing.
* - /proc/cpuinfo reports information only once, after all "processor : <number>" lines.
* The reported information may relate to processor #0 or to the processor which
* executed the system calls to read /proc/cpuinfo. It is also indistinguishable
* from /proc/cpuinfo reporting information only for the last core (e.g. if all other
* cores are offline).
*
* We detect the second case by checking if /proc/cpuinfo contains valid MIDR only for one,
* last reported, processor. Note, that the last reported core may be not the last
* present & possible processor, as /proc/cpuinfo may non-report high-index offline cores.
*/
if (processors_with_midr_count == 1 && last_processor_in_cpuinfo == last_processor_with_midr && clusters_count > 1) {
/*
* There are multiple core clusters, but /proc/cpuinfo reported MIDR only for one
* processor, and we don't even know which logical processor this information refers to.
*
* We make three attempts to detect MIDR for all clusters:
* 1. Search tabulated MIDR values for chipsets which have heterogeneous clusters and ship with Linux
* kernels which do not always report all cores in /proc/cpuinfo. If found, use the tabulated values.
* 2. For systems with 2 clusters and MIDR known for one cluster, assume big.LITTLE configuration,
* and estimate MIDR for the other cluster under assumption that MIDR for the big cluster is known.
* 3. Initialize MIDRs for all core clusters to the only parsed MIDR value.
*/
cpuinfo_log_debug("the only reported MIDR can not be attributed to a particular processor");
if (cpuinfo_arm_linux_detect_cluster_midr_by_chipset(
chipset, clusters_count, cluster_leaders, usable_processors, processors, false))
{
return clusters_count;
}
/* Try big.LITTLE heuristic */
if (cpuinfo_arm_linux_detect_cluster_midr_by_big_little_heuristic(
clusters_count, 1, last_processor_with_midr,
cluster_leaders, processors, false))
{
return clusters_count;
}
/* Fall back to sequential initialization of MIDR values for core clusters */
cpuinfo_arm_linux_detect_cluster_midr_by_sequential_scan(
processors[processors[last_processor_with_midr].package_leader_id].midr,
max_processors, processors);
} else if (processors_with_midr_count < usable_processors) {
/*
* /proc/cpuinfo reported MIDR only for some processors, and probably some core clusters do not have MIDR
* for any of the cores. Check if this is the case.
*/
uint32_t clusters_with_midr_count = 0;
for (uint32_t i = 0; i < max_processors; i++) {
if (bitmask_all(processors[i].flags, CPUINFO_LINUX_FLAG_VALID | CPUINFO_ARM_LINUX_VALID_MIDR)) {
if (processors[i].package_leader_id == i) {
clusters_with_midr_count += 1;
}
}
}
if (clusters_with_midr_count < clusters_count) {
/*
* /proc/cpuinfo reported MIDR only for some clusters, need to reconstruct others.
* We make three attempts to detect MIDR for clusters without it:
* 1. Search tabulated MIDR values for chipsets which have heterogeneous clusters and ship with Linux
* kernels which do not always report all cores in /proc/cpuinfo. If found, use the tabulated values.
* 2. For systems with 2 clusters and MIDR known for one cluster, assume big.LITTLE configuration,
* and estimate MIDR for the other cluster under assumption that MIDR for the big cluster is known.
* 3. Initialize MIDRs for core clusters in a single sequential scan:
* - Clusters preceeding the first reported MIDR value are assumed to have the last reported MIDR value.
* - Clusters following any reported MIDR value to have that MIDR value.
*/
if (cpuinfo_arm_linux_detect_cluster_midr_by_chipset(
chipset, clusters_count, cluster_leaders, usable_processors, processors, true))
{
return clusters_count;
}
if (last_processor_with_midr != max_processors) {
/* Try big.LITTLE heuristic */
if (cpuinfo_arm_linux_detect_cluster_midr_by_big_little_heuristic(
clusters_count, processors_with_midr_count, last_processor_with_midr,
cluster_leaders, processors, true))
{
return clusters_count;
}
/* Fall back to sequential initialization of MIDR values for core clusters */
cpuinfo_arm_linux_detect_cluster_midr_by_sequential_scan(
processors[processors[last_processor_with_midr].package_leader_id].midr,
max_processors, processors);
}
}
}
return clusters_count;
}

619
3rdparty/cpuinfo/src/arm/mach/init.c vendored Normal file
View File

@@ -0,0 +1,619 @@
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <alloca.h>
#include <errno.h>
#include <sys/types.h>
#include <sys/sysctl.h>
#include <mach/machine.h>
#include <cpuinfo.h>
#include <mach/api.h>
#include <cpuinfo/internal-api.h>
#include <cpuinfo/log.h>
/* Polyfill recent CPUFAMILY_ARM_* values for older SDKs */
#ifndef CPUFAMILY_ARM_MONSOON_MISTRAL
#define CPUFAMILY_ARM_MONSOON_MISTRAL 0xE81E7EF6
#endif
#ifndef CPUFAMILY_ARM_VORTEX_TEMPEST
#define CPUFAMILY_ARM_VORTEX_TEMPEST 0x07D34B9F
#endif
#ifndef CPUFAMILY_ARM_LIGHTNING_THUNDER
#define CPUFAMILY_ARM_LIGHTNING_THUNDER 0x462504D2
#endif
#ifndef CPUFAMILY_ARM_FIRESTORM_ICESTORM
#define CPUFAMILY_ARM_FIRESTORM_ICESTORM 0x1B588BB3
#endif
struct cpuinfo_arm_isa cpuinfo_isa = {
#if CPUINFO_ARCH_ARM
.thumb = true,
.thumb2 = true,
.thumbee = false,
.jazelle = false,
.armv5e = true,
.armv6 = true,
.armv6k = true,
.armv7 = true,
.vfpv2 = false,
.vfpv3 = true,
.d32 = true,
.wmmx = false,
.wmmx2 = false,
.neon = true,
#endif
#if CPUINFO_ARCH_ARM64
.aes = true,
.sha1 = true,
.sha2 = true,
.pmull = true,
.crc32 = true,
#endif
};
static uint32_t get_sys_info(int type_specifier, const char* name) {
size_t size = 0;
uint32_t result = 0;
int mib[2] = { CTL_HW, type_specifier };
if (sysctl(mib, 2, NULL, &size, NULL, 0) != 0) {
cpuinfo_log_info("sysctl(\"%s\") failed: %s", name, strerror(errno));
} else if (size == sizeof(uint32_t)) {
sysctl(mib, 2, &result, &size, NULL, 0);
cpuinfo_log_debug("%s: %"PRIu32 ", size = %lu", name, result, size);
} else {
cpuinfo_log_info("sysctl does not support non-integer lookup for (\"%s\")", name);
}
return result;
}
static uint32_t get_sys_info_by_name(const char* type_specifier) {
size_t size = 0;
uint32_t result = 0;
if (sysctlbyname(type_specifier, NULL, &size, NULL, 0) != 0) {
cpuinfo_log_info("sysctlbyname(\"%s\") failed: %s", type_specifier, strerror(errno));
} else if (size == sizeof(uint32_t)) {
sysctlbyname(type_specifier, &result, &size, NULL, 0);
cpuinfo_log_debug("%s: %"PRIu32 ", size = %lu", type_specifier, result, size);
} else {
cpuinfo_log_info("sysctl does not support non-integer lookup for (\"%s\")", type_specifier);
}
return result;
}
static enum cpuinfo_uarch decode_uarch(uint32_t cpu_family, uint32_t cpu_subtype, uint32_t core_index, uint32_t core_count) {
switch (cpu_family) {
case CPUFAMILY_ARM_SWIFT:
return cpuinfo_uarch_swift;
case CPUFAMILY_ARM_CYCLONE:
return cpuinfo_uarch_cyclone;
case CPUFAMILY_ARM_TYPHOON:
return cpuinfo_uarch_typhoon;
case CPUFAMILY_ARM_TWISTER:
return cpuinfo_uarch_twister;
case CPUFAMILY_ARM_HURRICANE:
return cpuinfo_uarch_hurricane;
case CPUFAMILY_ARM_MONSOON_MISTRAL:
/* 2x Monsoon + 4x Mistral cores */
return core_index < 2 ? cpuinfo_uarch_monsoon : cpuinfo_uarch_mistral;
case CPUFAMILY_ARM_VORTEX_TEMPEST:
/* Hexa-core: 2x Vortex + 4x Tempest; Octa-core: 4x Cortex + 4x Tempest */
return core_index + 4 < core_count ? cpuinfo_uarch_vortex : cpuinfo_uarch_tempest;
case CPUFAMILY_ARM_LIGHTNING_THUNDER:
/* Hexa-core: 2x Lightning + 4x Thunder; Octa-core (presumed): 4x Lightning + 4x Thunder */
return core_index + 4 < core_count ? cpuinfo_uarch_lightning : cpuinfo_uarch_thunder;
case CPUFAMILY_ARM_FIRESTORM_ICESTORM:
/* Hexa-core: 2x Firestorm + 4x Icestorm; Octa-core: 4x Firestorm + 4x Icestorm */
return core_index + 4 < core_count ? cpuinfo_uarch_firestorm : cpuinfo_uarch_icestorm;
default:
/* Use hw.cpusubtype for detection */
break;
}
#if CPUINFO_ARCH_ARM
switch (cpu_subtype) {
case CPU_SUBTYPE_ARM_V7:
return cpuinfo_uarch_cortex_a8;
case CPU_SUBTYPE_ARM_V7F:
return cpuinfo_uarch_cortex_a9;
case CPU_SUBTYPE_ARM_V7K:
return cpuinfo_uarch_cortex_a7;
default:
return cpuinfo_uarch_unknown;
}
#else
return cpuinfo_uarch_unknown;
#endif
}
static void decode_package_name(char* package_name) {
size_t size;
if (sysctlbyname("hw.machine", NULL, &size, NULL, 0) != 0) {
cpuinfo_log_warning("sysctlbyname(\"hw.machine\") failed: %s", strerror(errno));
return;
}
char *machine_name = alloca(size);
if (sysctlbyname("hw.machine", machine_name, &size, NULL, 0) != 0) {
cpuinfo_log_warning("sysctlbyname(\"hw.machine\") failed: %s", strerror(errno));
return;
}
cpuinfo_log_debug("hw.machine: %s", machine_name);
char name[10];
uint32_t major = 0, minor = 0;
if (sscanf(machine_name, "%9[^,0123456789]%"SCNu32",%"SCNu32, name, &major, &minor) != 3) {
cpuinfo_log_warning("parsing \"hw.machine\" failed: %s", strerror(errno));
return;
}
uint32_t chip_model = 0;
char suffix = '\0';
if (strcmp(name, "iPhone") == 0) {
/*
* iPhone 4 and up are supported:
* - iPhone 4 [A4]: iPhone3,1, iPhone3,2, iPhone3,3
* - iPhone 4S [A5]: iPhone4,1
* - iPhone 5 [A6]: iPhone5,1, iPhone5,2
* - iPhone 5c [A6]: iPhone5,3, iPhone5,4
* - iPhone 5s [A7]: iPhone6,1, iPhone6,2
* - iPhone 6 [A8]: iPhone7,2
* - iPhone 6 Plus [A8]: iPhone7,1
* - iPhone 6s [A9]: iPhone8,1
* - iPhone 6s Plus [A9]: iPhone8,2
* - iPhone SE [A9]: iPhone8,4
* - iPhone 7 [A10]: iPhone9,1, iPhone9,3
* - iPhone 7 Plus [A10]: iPhone9,2, iPhone9,4
* - iPhone 8 [A11]: iPhone10,1, iPhone10,4
* - iPhone 8 Plus [A11]: iPhone10,2, iPhone10,5
* - iPhone X [A11]: iPhone10,3, iPhone10,6
* - iPhone XS [A12]: iPhone11,2,
* - iPhone XS Max [A12]: iPhone11,4, iPhone11,6
* - iPhone XR [A12]: iPhone11,8
*/
chip_model = major + 1;
} else if (strcmp(name, "iPad") == 0) {
switch (major) {
/* iPad 2 and up are supported */
case 2:
/*
* iPad 2 [A5]: iPad2,1, iPad2,2, iPad2,3, iPad2,4
* iPad mini [A5]: iPad2,5, iPad2,6, iPad2,7
*/
chip_model = major + 3;
break;
case 3:
/*
* iPad 3rd Gen [A5X]: iPad3,1, iPad3,2, iPad3,3
* iPad 4th Gen [A6X]: iPad3,4, iPad3,5, iPad3,6
*/
chip_model = (minor <= 3) ? 5 : 6;
suffix = 'X';
break;
case 4:
/*
* iPad Air [A7]: iPad4,1, iPad4,2, iPad4,3
* iPad mini Retina [A7]: iPad4,4, iPad4,5, iPad4,6
* iPad mini 3 [A7]: iPad4,7, iPad4,8, iPad4,9
*/
chip_model = major + 3;
break;
case 5:
/*
* iPad mini 4 [A8]: iPad5,1, iPad5,2
* iPad Air 2 [A8X]: iPad5,3, iPad5,4
*/
chip_model = major + 3;
suffix = (minor <= 2) ? '\0' : 'X';
break;
case 6:
/*
* iPad Pro 9.7" [A9X]: iPad6,3, iPad6,4
* iPad Pro [A9X]: iPad6,7, iPad6,8
* iPad 5th Gen [A9]: iPad6,11, iPad6,12
*/
chip_model = major + 3;
suffix = minor <= 8 ? 'X' : '\0';
break;
case 7:
/*
* iPad Pro 12.9" [A10X]: iPad7,1, iPad7,2
* iPad Pro 10.5" [A10X]: iPad7,3, iPad7,4
* iPad 6th Gen [A10]: iPad7,5, iPad7,6
*/
chip_model = major + 3;
suffix = minor <= 4 ? 'X' : '\0';
break;
default:
cpuinfo_log_info("unknown iPad: %s", machine_name);
break;
}
} else if (strcmp(name, "iPod") == 0) {
switch (major) {
case 5:
chip_model = 5;
break;
/* iPod touch (5th Gen) [A5]: iPod5,1 */
case 7:
/* iPod touch (6th Gen, 2015) [A8]: iPod7,1 */
chip_model = 8;
break;
default:
cpuinfo_log_info("unknown iPod: %s", machine_name);
break;
}
} else {
cpuinfo_log_info("unknown device: %s", machine_name);
}
if (chip_model != 0) {
snprintf(package_name, CPUINFO_PACKAGE_NAME_MAX, "Apple A%"PRIu32"%c", chip_model, suffix);
}
}
void cpuinfo_arm_mach_init(void) {
struct cpuinfo_processor* processors = NULL;
struct cpuinfo_core* cores = NULL;
struct cpuinfo_cluster* clusters = NULL;
struct cpuinfo_package* packages = NULL;
struct cpuinfo_uarch_info* uarchs = NULL;
struct cpuinfo_cache* l1i = NULL;
struct cpuinfo_cache* l1d = NULL;
struct cpuinfo_cache* l2 = NULL;
struct cpuinfo_cache* l3 = NULL;
struct cpuinfo_mach_topology mach_topology = cpuinfo_mach_detect_topology();
processors = calloc(mach_topology.threads, sizeof(struct cpuinfo_processor));
if (processors == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" logical processors",
mach_topology.threads * sizeof(struct cpuinfo_processor), mach_topology.threads);
goto cleanup;
}
cores = calloc(mach_topology.cores, sizeof(struct cpuinfo_core));
if (cores == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" cores",
mach_topology.cores * sizeof(struct cpuinfo_core), mach_topology.cores);
goto cleanup;
}
packages = calloc(mach_topology.packages, sizeof(struct cpuinfo_package));
if (packages == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" packages",
mach_topology.packages * sizeof(struct cpuinfo_package), mach_topology.packages);
goto cleanup;
}
const uint32_t threads_per_core = mach_topology.threads / mach_topology.cores;
const uint32_t threads_per_package = mach_topology.threads / mach_topology.packages;
const uint32_t cores_per_package = mach_topology.cores / mach_topology.packages;
for (uint32_t i = 0; i < mach_topology.packages; i++) {
packages[i] = (struct cpuinfo_package) {
.processor_start = i * threads_per_package,
.processor_count = threads_per_package,
.core_start = i * cores_per_package,
.core_count = cores_per_package,
};
decode_package_name(packages[i].name);
}
const uint32_t cpu_family = get_sys_info_by_name("hw.cpufamily");
const uint32_t cpu_type = get_sys_info_by_name("hw.cputype");
const uint32_t cpu_subtype = get_sys_info_by_name("hw.cpusubtype");
switch (cpu_type) {
case CPU_TYPE_ARM64:
cpuinfo_isa.aes = true;
cpuinfo_isa.sha1 = true;
cpuinfo_isa.sha2 = true;
cpuinfo_isa.pmull = true;
cpuinfo_isa.crc32 = true;
break;
#if CPUINFO_ARCH_ARM
case CPU_TYPE_ARM:
switch (cpu_subtype) {
case CPU_SUBTYPE_ARM_V8:
cpuinfo_isa.armv8 = true;
cpuinfo_isa.aes = true;
cpuinfo_isa.sha1 = true;
cpuinfo_isa.sha2 = true;
cpuinfo_isa.pmull = true;
cpuinfo_isa.crc32 = true;
/* Fall-through to add ARMv7S features */
case CPU_SUBTYPE_ARM_V7S:
case CPU_SUBTYPE_ARM_V7K:
cpuinfo_isa.fma = true;
/* Fall-through to add ARMv7F features */
case CPU_SUBTYPE_ARM_V7F:
cpuinfo_isa.armv7mp = true;
cpuinfo_isa.fp16 = true;
/* Fall-through to add ARMv7 features */
case CPU_SUBTYPE_ARM_V7:
break;
default:
break;
}
break;
#endif
}
/*
* Support for ARMv8.1 Atomics & FP16 arithmetic instructions is supposed to be detected via
* sysctlbyname calls with "hw.optional.armv8_1_atomics" and "hw.optional.neon_fp16" arguments
* (see https://devstreaming-cdn.apple.com/videos/wwdc/2018/409t8zw7rumablsh/409/409_whats_new_in_llvm.pdf),
* but on new iOS versions these calls just fail with EPERM.
*
* Thus, we whitelist CPUs known to support these instructions.
*/
switch (cpu_family) {
case CPUFAMILY_ARM_MONSOON_MISTRAL:
case CPUFAMILY_ARM_VORTEX_TEMPEST:
case CPUFAMILY_ARM_LIGHTNING_THUNDER:
case CPUFAMILY_ARM_FIRESTORM_ICESTORM:
#if CPUINFO_ARCH_ARM64
cpuinfo_isa.atomics = true;
#endif
cpuinfo_isa.fp16arith = true;
}
/*
* There does not yet seem to exist an OS mechanism to detect support for
* ARMv8.2 optional dot-product instructions, so we currently whitelist CPUs
* known to support these instruction.
*/
switch (cpu_family) {
case CPUFAMILY_ARM_LIGHTNING_THUNDER:
case CPUFAMILY_ARM_FIRESTORM_ICESTORM:
cpuinfo_isa.dot = true;
}
uint32_t num_clusters = 1;
for (uint32_t i = 0; i < mach_topology.cores; i++) {
cores[i] = (struct cpuinfo_core) {
.processor_start = i * threads_per_core,
.processor_count = threads_per_core,
.core_id = i % cores_per_package,
.package = packages + i / cores_per_package,
.vendor = cpuinfo_vendor_apple,
.uarch = decode_uarch(cpu_family, cpu_subtype, i, mach_topology.cores),
};
if (i != 0 && cores[i].uarch != cores[i - 1].uarch) {
num_clusters++;
}
}
for (uint32_t i = 0; i < mach_topology.threads; i++) {
const uint32_t smt_id = i % threads_per_core;
const uint32_t core_id = i / threads_per_core;
const uint32_t package_id = i / threads_per_package;
processors[i].smt_id = smt_id;
processors[i].core = &cores[core_id];
processors[i].package = &packages[package_id];
}
clusters = calloc(num_clusters, sizeof(struct cpuinfo_cluster));
if (clusters == NULL) {
cpuinfo_log_error(
"failed to allocate %zu bytes for descriptions of %"PRIu32" clusters",
num_clusters * sizeof(struct cpuinfo_cluster), num_clusters);
goto cleanup;
}
uarchs = calloc(num_clusters, sizeof(struct cpuinfo_uarch_info));
if (uarchs == NULL) {
cpuinfo_log_error(
"failed to allocate %zu bytes for descriptions of %"PRIu32" uarchs",
num_clusters * sizeof(enum cpuinfo_uarch), num_clusters);
goto cleanup;
}
uint32_t cluster_idx = UINT32_MAX;
for (uint32_t i = 0; i < mach_topology.cores; i++) {
if (i == 0 || cores[i].uarch != cores[i - 1].uarch) {
cluster_idx++;
uarchs[cluster_idx] = (struct cpuinfo_uarch_info) {
.uarch = cores[i].uarch,
.processor_count = 1,
.core_count = 1,
};
clusters[cluster_idx] = (struct cpuinfo_cluster) {
.processor_start = i * threads_per_core,
.processor_count = 1,
.core_start = i,
.core_count = 1,
.cluster_id = cluster_idx,
.package = cores[i].package,
.vendor = cores[i].vendor,
.uarch = cores[i].uarch,
};
} else {
uarchs[cluster_idx].processor_count++;
uarchs[cluster_idx].core_count++;
clusters[cluster_idx].processor_count++;
clusters[cluster_idx].core_count++;
}
cores[i].cluster = &clusters[cluster_idx];
}
for (uint32_t i = 0; i < mach_topology.threads; i++) {
const uint32_t core_id = i / threads_per_core;
processors[i].cluster = cores[core_id].cluster;
}
for (uint32_t i = 0; i < mach_topology.packages; i++) {
packages[i].cluster_start = 0;
packages[i].cluster_count = num_clusters;
}
const uint32_t cacheline_size = get_sys_info(HW_CACHELINE, "HW_CACHELINE");
const uint32_t l1d_cache_size = get_sys_info(HW_L1DCACHESIZE, "HW_L1DCACHESIZE");
const uint32_t l1i_cache_size = get_sys_info(HW_L1ICACHESIZE, "HW_L1ICACHESIZE");
const uint32_t l2_cache_size = get_sys_info(HW_L2CACHESIZE, "HW_L2CACHESIZE");
const uint32_t l3_cache_size = get_sys_info(HW_L3CACHESIZE, "HW_L3CACHESIZE");
const uint32_t l1_cache_associativity = 4;
const uint32_t l2_cache_associativity = 8;
const uint32_t l3_cache_associativity = 16;
const uint32_t cache_partitions = 1;
const uint32_t cache_flags = 0;
uint32_t threads_per_l1 = 0, l1_count = 0;
if (l1i_cache_size != 0 || l1d_cache_size != 0) {
/* Assume L1 caches are private to each core */
threads_per_l1 = 1;
l1_count = mach_topology.threads / threads_per_l1;
cpuinfo_log_debug("detected %"PRIu32" L1 caches", l1_count);
}
uint32_t threads_per_l2 = 0, l2_count = 0;
if (l2_cache_size != 0) {
/* Assume L2 cache is shared between all cores */
threads_per_l2 = mach_topology.cores;
l2_count = 1;
cpuinfo_log_debug("detected %"PRIu32" L2 caches", l2_count);
}
uint32_t threads_per_l3 = 0, l3_count = 0;
if (l3_cache_size != 0) {
/* Assume L3 cache is shared between all cores */
threads_per_l3 = mach_topology.cores;
l3_count = 1;
cpuinfo_log_debug("detected %"PRIu32" L3 caches", l3_count);
}
if (l1i_cache_size != 0) {
l1i = calloc(l1_count, sizeof(struct cpuinfo_cache));
if (l1i == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L1I caches",
l1_count * sizeof(struct cpuinfo_cache), l1_count);
goto cleanup;
}
for (uint32_t c = 0; c < l1_count; c++) {
l1i[c] = (struct cpuinfo_cache) {
.size = l1i_cache_size,
.associativity = l1_cache_associativity,
.sets = l1i_cache_size / (l1_cache_associativity * cacheline_size),
.partitions = cache_partitions,
.line_size = cacheline_size,
.flags = cache_flags,
.processor_start = c * threads_per_l1,
.processor_count = threads_per_l1,
};
}
for (uint32_t t = 0; t < mach_topology.threads; t++) {
processors[t].cache.l1i = &l1i[t / threads_per_l1];
}
}
if (l1d_cache_size != 0) {
l1d = calloc(l1_count, sizeof(struct cpuinfo_cache));
if (l1d == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L1D caches",
l1_count * sizeof(struct cpuinfo_cache), l1_count);
goto cleanup;
}
for (uint32_t c = 0; c < l1_count; c++) {
l1d[c] = (struct cpuinfo_cache) {
.size = l1d_cache_size,
.associativity = l1_cache_associativity,
.sets = l1d_cache_size / (l1_cache_associativity * cacheline_size),
.partitions = cache_partitions,
.line_size = cacheline_size,
.flags = cache_flags,
.processor_start = c * threads_per_l1,
.processor_count = threads_per_l1,
};
}
for (uint32_t t = 0; t < mach_topology.threads; t++) {
processors[t].cache.l1d = &l1d[t / threads_per_l1];
}
}
if (l2_count != 0) {
l2 = calloc(l2_count, sizeof(struct cpuinfo_cache));
if (l2 == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L2 caches",
l2_count * sizeof(struct cpuinfo_cache), l2_count);
goto cleanup;
}
for (uint32_t c = 0; c < l2_count; c++) {
l2[c] = (struct cpuinfo_cache) {
.size = l2_cache_size,
.associativity = l2_cache_associativity,
.sets = l2_cache_size / (l2_cache_associativity * cacheline_size),
.partitions = cache_partitions,
.line_size = cacheline_size,
.flags = cache_flags,
.processor_start = c * threads_per_l2,
.processor_count = threads_per_l2,
};
}
for (uint32_t t = 0; t < mach_topology.threads; t++) {
processors[t].cache.l2 = &l2[0];
}
}
if (l3_count != 0) {
l3 = calloc(l3_count, sizeof(struct cpuinfo_cache));
if (l3 == NULL) {
cpuinfo_log_error("failed to allocate %zu bytes for descriptions of %"PRIu32" L3 caches",
l3_count * sizeof(struct cpuinfo_cache), l3_count);
goto cleanup;
}
for (uint32_t c = 0; c < l3_count; c++) {
l3[c] = (struct cpuinfo_cache) {
.size = l3_cache_size,
.associativity = l3_cache_associativity,
.sets = l3_cache_size / (l3_cache_associativity * cacheline_size),
.partitions = cache_partitions,
.line_size = cacheline_size,
.flags = cache_flags,
.processor_start = c * threads_per_l3,
.processor_count = threads_per_l3,
};
}
for (uint32_t t = 0; t < mach_topology.threads; t++) {
processors[t].cache.l3 = &l3[0];
}
}
/* Commit changes */
cpuinfo_processors = processors;
cpuinfo_cores = cores;
cpuinfo_clusters = clusters;
cpuinfo_packages = packages;
cpuinfo_uarchs = uarchs;
cpuinfo_cache[cpuinfo_cache_level_1i] = l1i;
cpuinfo_cache[cpuinfo_cache_level_1d] = l1d;
cpuinfo_cache[cpuinfo_cache_level_2] = l2;
cpuinfo_cache[cpuinfo_cache_level_3] = l3;
cpuinfo_processors_count = mach_topology.threads;
cpuinfo_cores_count = mach_topology.cores;
cpuinfo_clusters_count = num_clusters;
cpuinfo_packages_count = mach_topology.packages;
cpuinfo_uarchs_count = num_clusters;
cpuinfo_cache_count[cpuinfo_cache_level_1i] = l1_count;
cpuinfo_cache_count[cpuinfo_cache_level_1d] = l1_count;
cpuinfo_cache_count[cpuinfo_cache_level_2] = l2_count;
cpuinfo_cache_count[cpuinfo_cache_level_3] = l3_count;
cpuinfo_max_cache_size = cpuinfo_compute_max_cache_size(&processors[0]);
__sync_synchronize();
cpuinfo_is_initialized = true;
processors = NULL;
cores = NULL;
clusters = NULL;
packages = NULL;
uarchs = NULL;
l1i = l1d = l2 = l3 = NULL;
cleanup:
free(processors);
free(cores);
free(clusters);
free(packages);
free(uarchs);
free(l1i);
free(l1d);
free(l2);
free(l3);
}

257
3rdparty/cpuinfo/src/arm/midr.h vendored Normal file
View File

@@ -0,0 +1,257 @@
#pragma once
#include <stdint.h>
#define CPUINFO_ARM_MIDR_IMPLEMENTER_MASK UINT32_C(0xFF000000)
#define CPUINFO_ARM_MIDR_VARIANT_MASK UINT32_C(0x00F00000)
#define CPUINFO_ARM_MIDR_ARCHITECTURE_MASK UINT32_C(0x000F0000)
#define CPUINFO_ARM_MIDR_PART_MASK UINT32_C(0x0000FFF0)
#define CPUINFO_ARM_MIDR_REVISION_MASK UINT32_C(0x0000000F)
#define CPUINFO_ARM_MIDR_IMPLEMENTER_OFFSET 24
#define CPUINFO_ARM_MIDR_VARIANT_OFFSET 20
#define CPUINFO_ARM_MIDR_ARCHITECTURE_OFFSET 16
#define CPUINFO_ARM_MIDR_PART_OFFSET 4
#define CPUINFO_ARM_MIDR_REVISION_OFFSET 0
#define CPUINFO_ARM_MIDR_ARM1156 UINT32_C(0x410FB560)
#define CPUINFO_ARM_MIDR_CORTEX_A7 UINT32_C(0x410FC070)
#define CPUINFO_ARM_MIDR_CORTEX_A9 UINT32_C(0x410FC090)
#define CPUINFO_ARM_MIDR_CORTEX_A15 UINT32_C(0x410FC0F0)
#define CPUINFO_ARM_MIDR_CORTEX_A17 UINT32_C(0x410FC0E0)
#define CPUINFO_ARM_MIDR_CORTEX_A35 UINT32_C(0x410FD040)
#define CPUINFO_ARM_MIDR_CORTEX_A53 UINT32_C(0x410FD030)
#define CPUINFO_ARM_MIDR_CORTEX_A55 UINT32_C(0x410FD050)
#define CPUINFO_ARM_MIDR_CORTEX_A57 UINT32_C(0x410FD070)
#define CPUINFO_ARM_MIDR_CORTEX_A72 UINT32_C(0x410FD080)
#define CPUINFO_ARM_MIDR_CORTEX_A73 UINT32_C(0x410FD090)
#define CPUINFO_ARM_MIDR_CORTEX_A75 UINT32_C(0x410FD0A0)
#define CPUINFO_ARM_MIDR_KRYO280_GOLD UINT32_C(0x51AF8001)
#define CPUINFO_ARM_MIDR_KRYO280_SILVER UINT32_C(0x51AF8014)
#define CPUINFO_ARM_MIDR_KRYO385_GOLD UINT32_C(0x518F802D)
#define CPUINFO_ARM_MIDR_KRYO385_SILVER UINT32_C(0x518F803C)
#define CPUINFO_ARM_MIDR_KRYO_SILVER_821 UINT32_C(0x510F2010)
#define CPUINFO_ARM_MIDR_KRYO_GOLD UINT32_C(0x510F2050)
#define CPUINFO_ARM_MIDR_KRYO_SILVER_820 UINT32_C(0x510F2110)
#define CPUINFO_ARM_MIDR_EXYNOS_M1_M2 UINT32_C(0x530F0010)
#define CPUINFO_ARM_MIDR_DENVER2 UINT32_C(0x4E0F0030)
inline static uint32_t midr_set_implementer(uint32_t midr, uint32_t implementer) {
return (midr & ~CPUINFO_ARM_MIDR_IMPLEMENTER_MASK) |
((implementer << CPUINFO_ARM_MIDR_IMPLEMENTER_OFFSET) & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK);
}
inline static uint32_t midr_set_variant(uint32_t midr, uint32_t variant) {
return (midr & ~CPUINFO_ARM_MIDR_VARIANT_MASK) |
((variant << CPUINFO_ARM_MIDR_VARIANT_OFFSET) & CPUINFO_ARM_MIDR_VARIANT_MASK);
}
inline static uint32_t midr_set_architecture(uint32_t midr, uint32_t architecture) {
return (midr & ~CPUINFO_ARM_MIDR_ARCHITECTURE_MASK) |
((architecture << CPUINFO_ARM_MIDR_ARCHITECTURE_OFFSET) & CPUINFO_ARM_MIDR_ARCHITECTURE_MASK);
}
inline static uint32_t midr_set_part(uint32_t midr, uint32_t part) {
return (midr & ~CPUINFO_ARM_MIDR_PART_MASK) |
((part << CPUINFO_ARM_MIDR_PART_OFFSET) & CPUINFO_ARM_MIDR_PART_MASK);
}
inline static uint32_t midr_set_revision(uint32_t midr, uint32_t revision) {
return (midr & ~CPUINFO_ARM_MIDR_REVISION_MASK) |
((revision << CPUINFO_ARM_MIDR_REVISION_OFFSET) & CPUINFO_ARM_MIDR_REVISION_MASK);
}
inline static uint32_t midr_get_variant(uint32_t midr) {
return (midr & CPUINFO_ARM_MIDR_VARIANT_MASK) >> CPUINFO_ARM_MIDR_VARIANT_OFFSET;
}
inline static uint32_t midr_get_implementer(uint32_t midr) {
return (midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK) >> CPUINFO_ARM_MIDR_IMPLEMENTER_OFFSET;
}
inline static uint32_t midr_get_part(uint32_t midr) {
return (midr & CPUINFO_ARM_MIDR_PART_MASK) >> CPUINFO_ARM_MIDR_PART_OFFSET;
}
inline static uint32_t midr_get_revision(uint32_t midr) {
return (midr & CPUINFO_ARM_MIDR_REVISION_MASK) >> CPUINFO_ARM_MIDR_REVISION_OFFSET;
}
inline static uint32_t midr_copy_implementer(uint32_t midr, uint32_t other_midr) {
return (midr & ~CPUINFO_ARM_MIDR_IMPLEMENTER_MASK) | (other_midr & CPUINFO_ARM_MIDR_IMPLEMENTER_MASK);
}
inline static uint32_t midr_copy_variant(uint32_t midr, uint32_t other_midr) {
return (midr & ~CPUINFO_ARM_MIDR_VARIANT_MASK) | (other_midr & CPUINFO_ARM_MIDR_VARIANT_MASK);
}
inline static uint32_t midr_copy_architecture(uint32_t midr, uint32_t other_midr) {
return (midr & ~CPUINFO_ARM_MIDR_ARCHITECTURE_MASK) | (other_midr & CPUINFO_ARM_MIDR_ARCHITECTURE_MASK);
}
inline static uint32_t midr_copy_part(uint32_t midr, uint32_t other_midr) {
return (midr & ~CPUINFO_ARM_MIDR_PART_MASK) | (other_midr & CPUINFO_ARM_MIDR_PART_MASK);
}
inline static uint32_t midr_copy_revision(uint32_t midr, uint32_t other_midr) {
return (midr & ~CPUINFO_ARM_MIDR_REVISION_MASK) | (other_midr & CPUINFO_ARM_MIDR_REVISION_MASK);
}
inline static bool midr_is_arm1156(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_ARM1156 & uarch_mask);
}
inline static bool midr_is_arm11(uint32_t midr) {
return (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | 0x0000F000)) == UINT32_C(0x4100B000);
}
inline static bool midr_is_cortex_a9(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_CORTEX_A9 & uarch_mask);
}
inline static bool midr_is_scorpion(uint32_t midr) {
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x510000F0):
case UINT32_C(0x510002D0):
return true;
default:
return false;
}
}
inline static bool midr_is_krait(uint32_t midr) {
switch (midr & (CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case UINT32_C(0x510004D0):
case UINT32_C(0x510006F0):
return true;
default:
return false;
}
}
inline static bool midr_is_cortex_a53(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_CORTEX_A53 & uarch_mask);
}
inline static bool midr_is_qualcomm_cortex_a53_silver(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_KRYO280_SILVER & uarch_mask);
}
inline static bool midr_is_qualcomm_cortex_a55_silver(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_KRYO385_SILVER & uarch_mask);
}
inline static bool midr_is_kryo280_gold(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_KRYO280_GOLD & uarch_mask);
}
inline static bool midr_is_kryo_silver(uint32_t midr) {
const uint32_t uarch_mask =
CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_ARCHITECTURE_MASK | CPUINFO_ARM_MIDR_PART_MASK;
switch (midr & uarch_mask) {
case CPUINFO_ARM_MIDR_KRYO_SILVER_820:
case CPUINFO_ARM_MIDR_KRYO_SILVER_821:
return true;
default:
return false;
}
}
inline static bool midr_is_kryo_gold(uint32_t midr) {
const uint32_t uarch_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
return (midr & uarch_mask) == (CPUINFO_ARM_MIDR_KRYO_GOLD & uarch_mask);
}
inline static uint32_t midr_score_core(uint32_t midr) {
const uint32_t core_mask = CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_PART_MASK;
switch (midr & core_mask) {
case UINT32_C(0x53000030): /* Exynos M4 */
case UINT32_C(0x53000040): /* Exynos M5 */
case UINT32_C(0x4100D440): /* Cortex-X1 */
/* These cores are in big role w.r.t Cortex-A75/-A76/-A77/-A78 */
return 6;
case UINT32_C(0x4E000030): /* Denver 2 */
case UINT32_C(0x53000010): /* Exynos M1 and Exynos M2 */
case UINT32_C(0x53000020): /* Exynos M3 */
case UINT32_C(0x51008040): /* Kryo 485 Gold / Gold Prime */
case UINT32_C(0x51008020): /* Kryo 385 Gold */
case UINT32_C(0x51008000): /* Kryo 260 / 280 Gold */
case UINT32_C(0x51002050): /* Kryo Gold */
case UINT32_C(0x4800D400): /* Cortex-A76 (HiSilicon) */
case UINT32_C(0x4100D410): /* Cortex-A78 */
case UINT32_C(0x4100D0D0): /* Cortex-A77 */
case UINT32_C(0x4100D0E0): /* Cortex-A76AE */
case UINT32_C(0x4100D0B0): /* Cortex-A76 */
case UINT32_C(0x4100D0A0): /* Cortex-A75 */
case UINT32_C(0x4100D090): /* Cortex-A73 */
case UINT32_C(0x4100D080): /* Cortex-A72 */
#if CPUINFO_ARCH_ARM
case UINT32_C(0x4100C0F0): /* Cortex-A15 */
case UINT32_C(0x4100C0E0): /* Cortex-A17 */
case UINT32_C(0x4100C0D0): /* Rockchip RK3288 cores */
case UINT32_C(0x4100C0C0): /* Cortex-A12 */
#endif /* CPUINFO_ARCH_ARM */
/* These cores are always in big role */
return 5;
case UINT32_C(0x4100D070): /* Cortex-A57 */
/* Cortex-A57 can be in LITTLE role w.r.t. Denver 2, or in big role w.r.t. Cortex-A53 */
return 4;
#if CPUINFO_ARCH_ARM64
case UINT32_C(0x4100D060): /* Cortex-A65 */
#endif /* CPUINFO_ARCH_ARM64 */
case UINT32_C(0x4100D050): /* Cortex-A55 */
case UINT32_C(0x4100D030): /* Cortex-A53 */
/* Cortex-A53 is usually in LITTLE role, but can be in big role w.r.t. Cortex-A35 */
return 2;
case UINT32_C(0x4100D040): /* Cortex-A35 */
#if CPUINFO_ARCH_ARM
case UINT32_C(0x4100C070): /* Cortex-A7 */
#endif /* CPUINFO_ARCH_ARM */
case UINT32_C(0x51008050): /* Kryo 485 Silver */
case UINT32_C(0x51008030): /* Kryo 385 Silver */
case UINT32_C(0x51008010): /* Kryo 260 / 280 Silver */
case UINT32_C(0x51002110): /* Kryo Silver (Snapdragon 820) */
case UINT32_C(0x51002010): /* Kryo Silver (Snapdragon 821) */
/* These cores are always in LITTLE core */
return 1;
default:
/*
* Unknown cores, or cores which do not have big/LITTLE roles.
* To be future-proof w.r.t. cores not yet recognized in cpuinfo, assume position between
* Cortex-A57/A72/A73/A75 and Cortex-A53/A55. Then at least future cores paired with
* one of these known cores will be properly scored.
*/
return 3;
}
}
inline static uint32_t midr_little_core_for_big(uint32_t midr) {
const uint32_t core_mask =
CPUINFO_ARM_MIDR_IMPLEMENTER_MASK | CPUINFO_ARM_MIDR_ARCHITECTURE_MASK | CPUINFO_ARM_MIDR_PART_MASK;
switch (midr & core_mask) {
case CPUINFO_ARM_MIDR_CORTEX_A75:
return CPUINFO_ARM_MIDR_CORTEX_A55;
case CPUINFO_ARM_MIDR_CORTEX_A73:
case CPUINFO_ARM_MIDR_CORTEX_A72:
case CPUINFO_ARM_MIDR_CORTEX_A57:
case CPUINFO_ARM_MIDR_EXYNOS_M1_M2:
return CPUINFO_ARM_MIDR_CORTEX_A53;
case CPUINFO_ARM_MIDR_CORTEX_A17:
case CPUINFO_ARM_MIDR_CORTEX_A15:
return CPUINFO_ARM_MIDR_CORTEX_A7;
case CPUINFO_ARM_MIDR_KRYO280_GOLD:
return CPUINFO_ARM_MIDR_KRYO280_SILVER;
case CPUINFO_ARM_MIDR_KRYO_GOLD:
return CPUINFO_ARM_MIDR_KRYO_SILVER_820;
case CPUINFO_ARM_MIDR_DENVER2:
return CPUINFO_ARM_MIDR_CORTEX_A57;
default:
return midr;
}
}

133
3rdparty/cpuinfo/src/arm/tlb.c vendored Normal file
View File

@@ -0,0 +1,133 @@
switch (uarch) {
case cpuinfo_uarch_cortex_a5:
/*
* Cortex-A5 Technical Reference Manual:
* 6.3.1. Micro TLB
* The first level of caching for the page table information is a micro TLB of
* 10 entries that is implemented on each of the instruction and data sides.
* 6.3.2. Main TLB
* Misses from the instruction and data micro TLBs are handled by a unified main TLB.
* The main TLB is 128-entry two-way set-associative.
*/
break;
case cpuinfo_uarch_cortex_a7:
/*
* Cortex-A7 MPCore Technical Reference Manual:
* 5.3.1. Micro TLB
* The first level of caching for the page table information is a micro TLB of
* 10 entries that is implemented on each of the instruction and data sides.
* 5.3.2. Main TLB
* Misses from the micro TLBs are handled by a unified main TLB. This is a 256-entry 2-way
* set-associative structure. The main TLB supports all the VMSAv7 page sizes of
* 4KB, 64KB, 1MB and 16MB in addition to the LPAE page sizes of 2MB and 1G.
*/
break;
case cpuinfo_uarch_cortex_a8:
/*
* Cortex-A8 Technical Reference Manual:
* 6.1. About the MMU
* The MMU features include the following:
* - separate, fully-associative, 32-entry data and instruction TLBs
* - TLB entries that support 4KB, 64KB, 1MB, and 16MB pages
*/
break;
case cpuinfo_uarch_cortex_a9:
/*
* ARM CortexA9 Technical Reference Manual:
* 6.2.1 Micro TLB
* The first level of caching for the page table information is a micro TLB of 32 entries on the data side,
* and configurable 32 or 64 entries on the instruction side.
* 6.2.2 Main TLB
* The main TLB is implemented as a combination of:
* - A fully-associative, lockable array of four elements.
* - A 2-way associative structure of 2x32, 2x64, 2x128 or 2x256 entries.
*/
break;
case cpuinfo_uarch_cortex_a15:
/*
* ARM Cortex-A15 MPCore Processor Technical Reference Manual:
* 5.2.1. L1 instruction TLB
* The L1 instruction TLB is a 32-entry fully-associative structure. This TLB caches entries at the 4KB
* granularity of Virtual Address (VA) to Physical Address (PA) mapping only. If the page tables map the
* memory region to a larger granularity than 4K, it only allocates one mapping for the particular 4K region
* to which the current access corresponds.
* 5.2.2. L1 data TLB
* There are two separate 32-entry fully-associative TLBs that are used for data loads and stores,
* respectively. Similar to the L1 instruction TLB, both of these cache entries at the 4KB granularity of
* VA to PA mappings only. At implementation time, the Cortex-A15 MPCore processor can be configured with
* the -l1tlb_1m option, to have the L1 data TLB cache entries at both the 4KB and 1MB granularity.
* With this configuration, any translation that results in a 1MB or larger page is cached in the L1 data
* TLB as a 1MB entry. Any translation that results in a page smaller than 1MB is cached in the L1 data TLB
* as a 4KB entry. By default, all translations are cached in the L1 data TLB as a 4KB entry.
* 5.2.3. L2 TLB
* Misses from the L1 instruction and data TLBs are handled by a unified L2 TLB. This is a 512-entry 4-way
* set-associative structure. The L2 TLB supports all the VMSAv7 page sizes of 4K, 64K, 1MB and 16MB in
* addition to the LPAE page sizes of 2MB and 1GB.
*/
break;
case cpuinfo_uarch_cortex_a17:
/*
* ARM Cortex-A17 MPCore Processor Technical Reference Manual:
* 5.2.1. Instruction micro TLB
* The instruction micro TLB is implemented as a 32, 48 or 64 entry, fully-associative structure. This TLB
* caches entries at the 4KB and 1MB granularity of Virtual Address (VA) to Physical Address (PA) mapping
* only. If the translation tables map the memory region to a larger granularity than 4KB or 1MB, it only
* allocates one mapping for the particular 4KB region to which the current access corresponds.
* 5.2.2. Data micro TLB
* The data micro TLB is a 32 entry fully-associative TLB that is used for data loads and stores. The cache
* entries have a 4KB and 1MB granularity of VA to PA mappings only.
* 5.2.3. Unified main TLB
* Misses from the instruction and data micro TLBs are handled by a unified main TLB. This is a 1024 entry
* 4-way set-associative structure. The main TLB supports all the VMSAv7 page sizes of 4K, 64K, 1MB and 16MB
* in addition to the LPAE page sizes of 2MB and 1GB.
*/
break;
case cpuinfo_uarch_cortex_a35:
/*
* ARM CortexA35 Processor Technical Reference Manual:
* A6.2 TLB Organization
* Micro TLB
* The first level of caching for the translation table information is a micro TLB of ten entries that
* is implemented on each of the instruction and data sides.
* Main TLB
* A unified main TLB handles misses from the micro TLBs. It has a 512-entry, 2-way, set-associative
* structure and supports all VMSAv8 block sizes, except 1GB. If it fetches a 1GB block, the TLB splits
* it into 512MB blocks and stores the appropriate block for the lookup.
*/
break;
case cpuinfo_uarch_cortex_a53:
/*
* ARM Cortex-A53 MPCore Processor Technical Reference Manual:
* 5.2.1. Micro TLB
* The first level of caching for the translation table information is a micro TLB of ten entries that is
* implemented on each of the instruction and data sides.
* 5.2.2. Main TLB
* A unified main TLB handles misses from the micro TLBs. This is a 512-entry, 4-way, set-associative
* structure. The main TLB supports all VMSAv8 block sizes, except 1GB. If a 1GB block is fetched, it is
* split into 512MB blocks and the appropriate block for the lookup stored.
*/
break;
case cpuinfo_uarch_cortex_a57:
/*
* ARM® Cortex-A57 MPCore Processor Technical Reference Manual:
* 5.2.1 L1 instruction TLB
* The L1 instruction TLB is a 48-entry fully-associative structure. This TLB caches entries of three
* different page sizes, natively 4KB, 64KB, and 1MB, of VA to PA mappings. If the page tables map the memory
* region to a larger granularity than 1MB, it only allocates one mapping for the particular 1MB region to
* which the current access corresponds.
* 5.2.2 L1 data TLB
* The L1 data TLB is a 32-entry fully-associative TLB that is used for data loads and stores. This TLB
* caches entries of three different page sizes, natively 4KB, 64KB, and 1MB, of VA to PA mappings.
* 5.2.3 L2 TLB
* Misses from the L1 instruction and data TLBs are handled by a unified L2 TLB. This is a 1024-entry 4-way
* set-associative structure. The L2 TLB supports the page sizes of 4K, 64K, 1MB and 16MB. It also supports
* page sizes of 2MB and 1GB for the long descriptor format translation in AArch32 state and in AArch64 state
* when using the 4KB translation granule. In addition, the L2 TLB supports the 512MB page map size defined
* for the AArch64 translations that use a 64KB translation granule.
*/
break;
}

362
3rdparty/cpuinfo/src/arm/uarch.c vendored Normal file
View File

@@ -0,0 +1,362 @@
#include <stdint.h>
#include <arm/api.h>
#include <arm/midr.h>
#include <cpuinfo/log.h>
void cpuinfo_arm_decode_vendor_uarch(
uint32_t midr,
#if CPUINFO_ARCH_ARM
bool has_vfpv4,
#endif /* CPUINFO_ARCH_ARM */
enum cpuinfo_vendor vendor[restrict static 1],
enum cpuinfo_uarch uarch[restrict static 1])
{
switch (midr_get_implementer(midr)) {
case 'A':
*vendor = cpuinfo_vendor_arm;
switch (midr_get_part(midr)) {
#if CPUINFO_ARCH_ARM
case 0xC05:
*uarch = cpuinfo_uarch_cortex_a5;
break;
case 0xC07:
*uarch = cpuinfo_uarch_cortex_a7;
break;
case 0xC08:
*uarch = cpuinfo_uarch_cortex_a8;
break;
case 0xC09:
*uarch = cpuinfo_uarch_cortex_a9;
break;
case 0xC0C:
*uarch = cpuinfo_uarch_cortex_a12;
break;
case 0xC0E:
*uarch = cpuinfo_uarch_cortex_a17;
break;
case 0xC0D:
/*
* Rockchip RK3288 only.
* Core information is ambiguous: some sources specify Cortex-A12, others - Cortex-A17.
* Assume it is Cortex-A12.
*/
*uarch = cpuinfo_uarch_cortex_a12;
break;
case 0xC0F:
*uarch = cpuinfo_uarch_cortex_a15;
break;
#endif /* CPUINFO_ARCH_ARM */
case 0xD01:
*uarch = cpuinfo_uarch_cortex_a32;
break;
case 0xD03:
*uarch = cpuinfo_uarch_cortex_a53;
break;
case 0xD04:
*uarch = cpuinfo_uarch_cortex_a35;
break;
case 0xD05:
// Note: use Variant, not Revision, field
*uarch = (midr & CPUINFO_ARM_MIDR_VARIANT_MASK) == 0 ?
cpuinfo_uarch_cortex_a55r0 : cpuinfo_uarch_cortex_a55;
break;
case 0xD06:
*uarch = cpuinfo_uarch_cortex_a65;
break;
case 0xD07:
*uarch = cpuinfo_uarch_cortex_a57;
break;
case 0xD08:
*uarch = cpuinfo_uarch_cortex_a72;
break;
case 0xD09:
*uarch = cpuinfo_uarch_cortex_a73;
break;
case 0xD0A:
*uarch = cpuinfo_uarch_cortex_a75;
break;
case 0xD0B:
*uarch = cpuinfo_uarch_cortex_a76;
break;
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 0xD0C:
*uarch = cpuinfo_uarch_neoverse_n1;
break;
#endif /* CPUINFO_ARCH_ARM64 && !defined(__ANDROID__) */
case 0xD0D:
*uarch = cpuinfo_uarch_cortex_a77;
break;
case 0xD0E: /* Cortex-A76AE */
*uarch = cpuinfo_uarch_cortex_a76;
break;
case 0xD41: /* Cortex-A78 */
*uarch = cpuinfo_uarch_cortex_a78;
break;
case 0xD44: /* Cortex-X1 */
*uarch = cpuinfo_uarch_cortex_x1;
break;
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 0xD4A:
*uarch = cpuinfo_uarch_neoverse_e1;
break;
#endif /* CPUINFO_ARCH_ARM64 && !defined(__ANDROID__) */
default:
switch (midr_get_part(midr) >> 8) {
#if CPUINFO_ARCH_ARM
case 7:
*uarch = cpuinfo_uarch_arm7;
break;
case 9:
*uarch = cpuinfo_uarch_arm9;
break;
case 11:
*uarch = cpuinfo_uarch_arm11;
break;
#endif /* CPUINFO_ARCH_ARM */
default:
cpuinfo_log_warning("unknown ARM CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
}
break;
case 'B':
*vendor = cpuinfo_vendor_broadcom;
switch (midr_get_part(midr)) {
case 0x00F:
*uarch = cpuinfo_uarch_brahma_b15;
break;
case 0x100:
*uarch = cpuinfo_uarch_brahma_b53;
break;
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 0x516:
/* Broadcom Vulkan was sold to Cavium before it reached the market, so we identify it as Cavium ThunderX2 */
*vendor = cpuinfo_vendor_cavium;
*uarch = cpuinfo_uarch_thunderx2;
break;
#endif
default:
cpuinfo_log_warning("unknown Broadcom CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 'C':
*vendor = cpuinfo_vendor_cavium;
switch (midr_get_part(midr)) {
case 0x0A0: /* ThunderX */
case 0x0A1: /* ThunderX 88XX */
case 0x0A2: /* ThunderX 81XX */
case 0x0A3: /* ThunderX 83XX */
*uarch = cpuinfo_uarch_thunderx;
break;
case 0x0AF: /* ThunderX2 99XX */
*uarch = cpuinfo_uarch_thunderx2;
break;
default:
cpuinfo_log_warning("unknown Cavium CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#endif
case 'H':
*vendor = cpuinfo_vendor_huawei;
switch (midr_get_part(midr)) {
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 0xD01: /* Kunpeng 920 series */
*uarch = cpuinfo_uarch_taishan_v110;
break;
#endif
case 0xD40: /* Kirin 980 Big/Medium cores -> Cortex-A76 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a76;
break;
default:
cpuinfo_log_warning("unknown Huawei CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#if CPUINFO_ARCH_ARM
case 'i':
*vendor = cpuinfo_vendor_intel;
switch (midr_get_part(midr) >> 8) {
case 2: /* PXA 210/25X/26X */
case 4: /* PXA 27X */
case 6: /* PXA 3XX */
*uarch = cpuinfo_uarch_xscale;
break;
default:
cpuinfo_log_warning("unknown Intel CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#endif /* CPUINFO_ARCH_ARM */
case 'N':
*vendor = cpuinfo_vendor_nvidia;
switch (midr_get_part(midr)) {
case 0x000:
*uarch = cpuinfo_uarch_denver;
break;
case 0x003:
*uarch = cpuinfo_uarch_denver2;
break;
case 0x004:
*uarch = cpuinfo_uarch_carmel;
break;
default:
cpuinfo_log_warning("unknown Nvidia CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#if !defined(__ANDROID__)
case 'P':
*vendor = cpuinfo_vendor_apm;
switch (midr_get_part(midr)) {
case 0x000:
*uarch = cpuinfo_uarch_xgene;
break;
default:
cpuinfo_log_warning("unknown Applied Micro CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#endif
case 'Q':
*vendor = cpuinfo_vendor_qualcomm;
switch (midr_get_part(midr)) {
#if CPUINFO_ARCH_ARM
case 0x00F:
/* Mostly Scorpions, but some Cortex A5 may report this value as well */
if (has_vfpv4) {
/* Unlike Scorpion, Cortex-A5 comes with VFPv4 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a5;
} else {
*uarch = cpuinfo_uarch_scorpion;
}
break;
case 0x02D: /* Dual-core Scorpions */
*uarch = cpuinfo_uarch_scorpion;
break;
case 0x04D:
/*
* Dual-core Krait:
* - r1p0 -> Krait 200
* - r1p4 -> Krait 200
* - r2p0 -> Krait 300
*/
case 0x06F:
/*
* Quad-core Krait:
* - r0p1 -> Krait 200
* - r0p2 -> Krait 200
* - r1p0 -> Krait 300
* - r2p0 -> Krait 400 (Snapdragon 800 MSMxxxx)
* - r2p1 -> Krait 400 (Snapdragon 801 MSMxxxxPRO)
* - r3p1 -> Krait 450
*/
*uarch = cpuinfo_uarch_krait;
break;
#endif /* CPUINFO_ARCH_ARM */
case 0x201: /* Qualcomm Snapdragon 821: Low-power Kryo "Silver" */
case 0x205: /* Qualcomm Snapdragon 820 & 821: High-performance Kryo "Gold" */
case 0x211: /* Qualcomm Snapdragon 820: Low-power Kryo "Silver" */
*uarch = cpuinfo_uarch_kryo;
break;
case 0x800: /* High-performance Kryo 260 (r10p2) / Kryo 280 (r10p1) "Gold" -> Cortex-A73 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a73;
break;
case 0x801: /* Low-power Kryo 260 / 280 "Silver" -> Cortex-A53 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a53;
break;
case 0x802: /* High-performance Kryo 385 "Gold" -> Cortex-A75 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a75;
break;
case 0x803: /* Low-power Kryo 385 "Silver" -> Cortex-A55r0 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a55r0;
break;
case 0x804: /* High-performance Kryo 485 "Gold" / "Gold Prime" -> Cortex-A76 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a76;
break;
case 0x805: /* Low-performance Kryo 485 "Silver" -> Cortex-A55 */
*vendor = cpuinfo_vendor_arm;
*uarch = cpuinfo_uarch_cortex_a55;
break;
#if CPUINFO_ARCH_ARM64 && !defined(__ANDROID__)
case 0xC00:
*uarch = cpuinfo_uarch_falkor;
break;
case 0xC01:
*uarch = cpuinfo_uarch_saphira;
break;
#endif /* CPUINFO_ARCH_ARM64 && !defined(__ANDROID__) */
default:
cpuinfo_log_warning("unknown Qualcomm CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
case 'S':
*vendor = cpuinfo_vendor_samsung;
switch (midr & (CPUINFO_ARM_MIDR_VARIANT_MASK | CPUINFO_ARM_MIDR_PART_MASK)) {
case 0x00100010:
/*
* Exynos 8890 MIDR = 0x531F0011, assume Exynos M1 has:
* - CPU variant 0x1
* - CPU part 0x001
*/
*uarch = cpuinfo_uarch_exynos_m1;
break;
case 0x00400010:
/*
* Exynos 8895 MIDR = 0x534F0010, assume Exynos M2 has:
* - CPU variant 0x4
* - CPU part 0x001
*/
*uarch = cpuinfo_uarch_exynos_m2;
break;
case 0x00100020:
/*
* Exynos 9810 MIDR = 0x531F0020, assume Exynos M3 has:
* - CPU variant 0x1
* - CPU part 0x002
*/
*uarch = cpuinfo_uarch_exynos_m3;
break;
case 0x00100030:
/*
* Exynos 9820 MIDR = 0x531F0030, assume Exynos M4 has:
* - CPU variant 0x1
* - CPU part 0x003
*/
*uarch = cpuinfo_uarch_exynos_m4;
break;
case 0x00100040:
/*
* Exynos 9820 MIDR = 0x531F0040, assume Exynos M5 has:
* - CPU variant 0x1
* - CPU part 0x004
*/
*uarch = cpuinfo_uarch_exynos_m5;
break;
default:
cpuinfo_log_warning("unknown Samsung CPU variant 0x%01"PRIx32" part 0x%03"PRIx32" ignored",
midr_get_variant(midr), midr_get_part(midr));
}
break;
#if CPUINFO_ARCH_ARM
case 'V':
*vendor = cpuinfo_vendor_marvell;
switch (midr_get_part(midr)) {
case 0x581: /* PJ4 / PJ4B */
case 0x584: /* PJ4B-MP / PJ4C */
*uarch = cpuinfo_uarch_pj4;
break;
default:
cpuinfo_log_warning("unknown Marvell CPU part 0x%03"PRIx32" ignored", midr_get_part(midr));
}
break;
#endif /* CPUINFO_ARCH_ARM */
default:
cpuinfo_log_warning("unknown CPU implementer '%c' (0x%02"PRIx32") with CPU part 0x%03"PRIx32" ignored",
(char) midr_get_implementer(midr), midr_get_implementer(midr), midr_get_part(midr));
}
}

Some files were not shown because too many files have changed in this diff Show More