Commit graph

492 commits

Author SHA1 Message Date
Nekotekina
e1042bc631 Get rid of "module" keyword
Workaround some intellisense problems.
2020-05-06 18:20:11 +03:00
Eladash
1bd6cb2105 SPU/PPU debugger: use ':' instead of '=' 2020-05-05 13:46:26 +03:00
Eladash
72bef8dd7f PPU: Clear reservation on context switch
Ensure that only 2 PPU reservations exist at maximum at a time.
2020-05-02 14:57:38 +03:00
Eladash
f4f0fb88b1 kernel explorer: Add more information about SPU/PPU threads 2020-04-29 15:32:16 +03:00
Eladash
dd6825a7bd Fix sys_ppu_thread_start error checking, fix rare bug in sys_ppu_thread_create
* Correct error code to EBUSY.
* lv2_obj::awake was called even when EBSUY should be returned.
* Fix sys_ppu_thread_create for a newly created thread with the same id as ppu_thread::id_base. (can happen if main thread exited before its creation)
2020-04-29 08:58:09 +03:00
Eladash
954e3f6e6c Fixup for cpu_flag::pause state check after #8114 2020-04-29 05:56:47 +03:00
Nekotekina
689419b0ca Remove test_stopped() check from ppu_load_acquire_reservation
Fixes warning.
2020-04-29 00:09:40 +03:00
Eladash
a505d87565 Partial revert of 3be687cd18 2020-04-28 20:20:19 +03:00
Eladash
3be687cd18 PPU: Fix LWARX/LDARX on TSX path 2020-04-28 14:27:40 +03:00
Eladash
0bf73ba0bc PPU debugger: report functions on registers display 2020-04-19 10:56:42 +01:00
Eladash
368bd7cf02 PPU debugger: read 32-bit pointer instead of 64-bit
PPU ABI supports only 32-bit pointers in userland, also fix it to use super ptr.
2020-04-19 10:56:42 +01:00
Eladash
83c7f6f149 debugger: Rephrase "Current function" to "In function"
Takes less space which makes actual function name display a bit nicer.
Also the meaning is clearer.
2020-04-19 10:56:42 +01:00
Nekotekina
c7fe8567b8 Experimental squashing of reservation memory area.
Enables trivial synchronization between shared mem.
Reduces memory usage, but potentially degrades performance.
Rename an overload of vm::passive_lock to vm::range_lock.
2020-04-16 02:25:43 +03:00
Eladash
63be05d5d3 minor ppu fixup
does not affect anything except consistency.
2020-04-14 17:09:58 +03:00
Eladash
c8b8cafeec PPU: Merge reservations store functions into one 2020-04-13 14:34:37 +03:00
Eladash
158b24ec25 SPU LLVM: Add accurate double-precision FMA support 2020-04-09 17:27:14 +03:00
Eladash
c948c9305c sys_ppu_thread_create: read function descriptor immediately and save it 2020-04-08 19:23:13 +03:00
Eladash
cc8f024c6c Fixup ppu/spu_thread::dump_all() 2020-04-08 14:35:44 +03:00
Nekotekina
91d80aa7b9 Implement jit_compiler::check
Instead of checking file existence (because file may be damaged).
2020-04-07 16:09:47 +03:00
Megamouse
b1fdbc7fcc Move some format functions 2020-04-06 20:59:58 +02:00
Eladash
dc5cdb3bb4 sys_ppu_thread: reduce global memory stats after thread creation 2020-04-05 15:23:09 +03:00
Eladash
63080c22a3 Fix ppu_thread::dump_callstack() 2020-04-04 00:06:51 +03:00
Eladash
0beea91d5e Minor debugger fixups 2020-04-03 18:37:21 +03:00
Nick Renieris
6cbb12e5cd PPUThread: String & hex previews for register pointers in register dump 2020-04-03 01:36:35 +01:00
Nick Renieris
1231274e0f CPUThread: Split dump() info to separate methods 2020-04-03 01:36:35 +01:00
Eladash
92f821aeb1
PPU LLVM: Add FMA accuracy setting (#7874)
* PPU LLVM : Match PS3 for the instructions fmadd, fmadds, fmsub, fmsubs, fnmadd, fnmadds, fnmsub, fnmsubs

Co-authored-by: doesthisusername <yfirestorm@gmail.com>
2020-03-31 20:01:10 +03:00
Nekotekina
471db3219d Finalize constexpr ppu_decoder<> thing
Move SSSE3 checks to runtime in PPUInterpreter.cpp
2020-03-25 11:18:48 +03:00
Nekotekina
1ceb779a38 Make ppu_decoder<> objects constexpr (partial) 2020-03-24 13:46:46 +03:00
Nekotekina
e606130262 Memoize and print r3-r6 under Current function in the ppu_thread::dump() 2020-03-22 14:13:52 +03:00
Eladash
dc839e1784 lv2: Do not lose r3 data on syscalls
Allows to get the ID of the lv2 sync objects in the debugger by looking at r3's content.
2020-03-22 12:41:02 +03:00
Eladash
1dbb5422a2 Avoid a segfault when reading ppu stack contents in debuggers
TODO: lock vm mutex.
2020-03-19 14:18:05 +03:00
Nekotekina
45389dca51 PPU: minor fix for ppu_join_status::max
Don't treat it as special "invalid" value.
2020-03-14 20:36:56 +03:00
Eladash
efe6e1eb0a sys_ppu_thread: Make PPU id removal after exit atomic with descheduling
* Make PPU id removal after exit atomic with descheduling
* Make joining thread scheduling atomic with thread exit sleep.
* Update sys_ppu_thread_stop/restart.
* Add idm::remove_verify.
2020-03-14 18:30:14 +02:00
Nekotekina
04dedb17eb Disable exception handling.
Use -fno-exceptions in cmake.
On MSVC, enable _HAS_EXCEPTION=0.
Cleanup throw/catch from the source.
Create yaml.cpp enclave because it needs exception to work.
Disable thread_local optimizations in logs.cpp (TODO).
Implement cpu_counter for cpu_threads (moved globals).
2020-03-12 16:03:08 +03:00
Nekotekina Aux1
250736ece5 Fix warnings in emucore 2020-03-04 21:23:34 +03:00
Nekotekina
bdbc7b5f1d PPU: use named_thread_group to compile modules
Improves internal logic by not using too many threads.
2020-03-04 14:10:38 +03:00
Nekotekina
3105b21909 Print PPU Syscall Usage Stats
* Every 10 seconds
* On normal exit
2020-03-02 20:48:20 +03:00
Nekotekina
490f58ff3c Try to purge thread_state::detached
It's rarely necessary, but can cause unexpected problems.
2020-02-28 21:11:13 +03:00
Nekotekina
65eeee0f4c Remove cancerous lf_value<>
Replace thread names (generic, PPU, SPU) with new shared pointers.
Devirtualize cpu_thread::get_name (used in single case).
2020-02-28 18:54:46 +03:00
JohnHolmesII
479a64c4e8 Remove some inline compiler pragmas 2020-02-23 09:38:04 +03:00
Nekotekina
972e0ab31d Remove -Wno-reorder and make it an error 2020-02-21 15:20:34 +03:00
Nekotekina
92e3eaf3ff Fix signed-unsigned comparisons and mark warning as error (part 2). 2020-02-19 22:54:58 +03:00
Nekotekina
f08c778d2c Use more starts_with/ends_with.
Remove ends_with global func.
2020-02-18 14:53:23 +03:00
Nekotekina
244e74ebe2 Try to ignore some annoying warning (seems CIB) 2020-02-17 20:56:03 +03:00
Megamouse
fe75311be2 move config structs to own files and clean up some headers 2020-02-17 15:08:17 +03:00
Nekotekina
c0f80cfe7a Use attributes for LIKELY/UNLIKELY
Remove LIKELY/UNLIKELY macro.
2020-02-05 10:42:34 +03:00
Nekotekina
327bb2d8f0 Modernize PPU logging (ppu_log variable) 2020-02-01 11:52:24 +03:00
Nekotekina
1d0f359406 logs: add more log channels instead of GENERAL 2020-01-31 16:44:48 +03:00
Ivan
7f07b79c04 Partial revert of #7180
PC is PS
2020-01-27 07:05:18 +03:00
Eladash
a7aef22754 ppu: Log SELF header information and CIA of caller HLE functions 2020-01-27 01:21:40 +00:00