Commit graph

157 commits

Author SHA1 Message Date
kd-11 54ec363e88 rsx: Critical pipeline fixes
- Fix scissor and viewport binding behavior
- Fixes recovery if empty scissor is specified and then 'fixed' later
- Optimizes state binding a bit
2018-11-30 23:51:25 +03:00
kd-11 1ad76ad331 rsx: Restructure programs
- Also re-enable pipeline optimizations
2018-11-30 23:51:25 +03:00
kd-11 677b16f5c6 rsx: Fixups
- Also fix visual corruption when using disjoint indexed draws

- Refactor draw call emit again (vk)

- Improve execution barrier resolve
  - Allow vertex/index rebase inside begin/end pair
  - Add ALPHA_TEST to list of excluded methods [TODO: defer raster state]

- gl bringup

- Simplify
  - using the simple_array gets back a few more fps :)
2018-11-30 23:51:25 +03:00
kd-11 e01d2f08c9 rsx: Refactor FIFO
- Removes fifo structures from common RSXThread
- Sets up a dedicated FIFO controller
- Allows for configurable queue optimizations
2018-11-30 23:51:25 +03:00
Nekotekina 1b37e775be Migration to named_thread<>
Add atomic_t<>::try_dec instead of fetch_dec_sat
Add atomic_t<>::try_inc
GDBDebugServer is broken (needs rewrite)
Removed old_thread class (former named_thread)
Removed storing/rethrowing exceptions from thread
Emu.Stop doesn't inject an exception anymore
task_stack helper class removed
thread_base simplified (no shared_from_this)
thread_ctrl::spawn simplified (creates detached thread)
Implemented overrideable thread detaching logic
Disabled cellAdec, cellDmux, cellFsAio
SPUThread renamed to spu_thread
RawSPUThread removed, spu_thread used instead
Disabled deriving from ppu_thread
Partial support for thread renaming
lv2_timer... simplified, screw it
idm/fxm: butchered support for on_stop/on_init
vm: improved allocation structure (added size)
2018-10-19 22:22:35 +03:00
eladash 62f97f2e5f rsx: Fix default texture dimensions
haha
2018-10-03 20:57:46 +03:00
kd-11 a3d44b5e1f rsx: Cleanup changes for the flip patch 2018-09-24 16:44:02 +03:00
Jake 699eadc84f rsx: Move render flip from rsx queue command to flip command 2018-09-24 16:44:02 +03:00
eladash e8474145a5 rsx: Remove shader address verification
this came from a misunderstanding of the register's use
2018-09-24 13:25:05 +03:00
eladash 1a6c819176 cellgcm: Fix SET_REFERENCE initial value 2018-09-20 01:05:40 +03:00
eladash a8ea576b22 rsx/cellgcm: Implemet initialization registers reset 2018-09-20 01:05:40 +03:00
eladash efbd77deb4 rsx: dont silently ignore null shader address 2018-09-12 00:40:20 +03:00
kd-11 2e0ecb556c rsx: Possible fix for UB data type consistency 2018-09-03 18:24:20 +03:00
kd-11 6399833182 rsx: Fix endianness order when immediate mode register is updated, but used as register lookup
- Simplify the code by unifying all the register-backed memory
2018-09-03 18:24:20 +03:00
elad 685eaedbf9 rsx: Fix typos (#5054) 2018-08-30 00:47:48 +03:00
eladash 37ee0a2f55 Rsx/cellgcm: complete rsx_state::reset() 2018-08-29 13:37:50 +03:00
eladash fc50e6abcb Rsx: remove method registers reset
cellGcm manually resets registers each flip, tested with cellGcmSetFlip
2018-08-29 13:37:50 +03:00
eladash acf1286b49 Rsx: fix unknown cull faces 2018-08-28 10:47:24 +03:00
eladash 38a72cc6ee Rsx: fix flip method registers reset
driver flip does not reset registers
2018-08-28 10:47:24 +03:00
eladash e279bdb304 Rsx: add missing default vertex shader attributes registers states 2018-08-28 10:47:24 +03:00
kd-11 7915dcb23c rsx: Do not overflow the program buffer!
- Some games overflow the program buffer e.g Resistance games
  The observed overflow is one instruction longer, likely an engine bug
with counting instructions
2018-08-18 16:14:30 +03:00
kd-11 dd21e43ed5 rsx: Force disable draw reordering when capturing a frame 2018-08-18 16:14:30 +03:00
kd-11 0267221586 Minor optimizations and fixes
- FIFO: avoid multiline spam
- VK: Fix program setup counter
- FS: Precalculate fragment constants buffer size during analysis step
2018-08-18 16:14:30 +03:00
kd-11 8800c10476 zcull synchronization tweaks
- Implement forced reading when calling update method to sync partial lists
- Defer conditional render evaluation and use a read barrier to avoid extra work
- Fix HLE gcm library when binding tiles & zcull RAM
2018-08-18 16:14:30 +03:00
kd-11 3b47e43380 rsx: Synchronization rewritten
- Do not do a full sync on a texture read barrier
- Avoid calling zcull sync in FIFO spin wait
- Do not flush memory to cache from the renderer side; this method is now obsolete
2018-08-18 16:14:30 +03:00
eladash f349695a75 Rsx: rewrite address translation 2018-08-13 16:16:34 +03:00
Megamouse d057c79733 RSX: use localtime_s instead of localtime 2018-07-28 23:10:45 +02:00
Megamouse 67aff85e8e RSX/Qt: Move rrc captures to captures dir 2018-07-28 23:10:45 +02:00
Megamouse f8d396ac9e change rsx_capture filename 2018-07-28 23:10:45 +02:00
kd-11 19d808d378 rsx/gl: Minor cleanup and optimization
- Track register change status
- Remove unused gl classes
2018-07-22 17:19:59 +03:00
kd-11 fa55a8072c rsx: Improve vertex textures support
- Adds proper support for vertex textures, including dimensions other than 2D textures
- Minor analyser fixup, removes spurious 'analyser failed' errors
- Minor optimizations for program state tracking
2018-07-12 18:02:28 +03:00
kd-11 bd915bfebd rsx: vp decompiler fixes
- Fix program abort logic to never abort before resolving later label addresses
  Fixes jumping over broken code and jumping over END markers
- TEXTURE_CONTROL2 has indexing range of [0..15] without stride skipping!
  This register does not have interleaving with other texture registers
- Track shader address poke as it seems to invalidate programs as well
2018-07-07 16:20:33 +03:00
kd-11 66854b78fa rsx: Fix nv308a::color 2018-07-07 16:20:33 +03:00
Jake 00c9b323c2 rsx: fix image_in to use in_pitch when swizzling 2018-06-24 14:29:41 +04:00
eladash b456955688 rsx: fix hardcoded rsx allocation address 2018-06-24 10:57:30 +03:00
kd-11 6362942928 rsx: Avoid semaphore acquire deadlock 2018-05-30 13:30:23 +03:00
Nekotekina 72574b11ff SPU: use reservation spinlocks on writes (non-TSX)
This should decrease contention by avoiding global lock
2018-05-21 21:56:14 +03:00
Nekotekina 367f039523 Build transactions at runtime
Drop _xbegin family intrinsics due to bad codegen
Implemented `notifier` class, replacing vm::notify
Minor optimization: detach transactions from global mutex on TSX path
Minor optimization: don't acquire vm::passive_lock on PPU on TSX path
2018-05-16 17:31:58 +03:00
scribam 04ad49de4d typos 2018-05-14 21:14:39 +04:00
kd-11 b7979d3f57 rsx/vk: Improvements and minor optimizations
- Improve dirty state tracking affecting program state
- vk: Refactor out transform constants upload into a separate channel to avoid if possible
  transform data uploads are quite expensive
2018-05-13 14:44:14 +03:00
kd-11 440a31ef18 rsx: Optimizations for program management 2018-05-13 14:44:14 +03:00
Jake 75b40931fc rsx: initial capture/replay functionality (#4510)
* rsx: initial capture/replay functionality
2018-05-13 12:18:05 +03:00
kd-11 93b2776604 rsx: Fix vertex input detection
- Properly detect inline array registers vs constant value registers
- Silence needless spam, 306E is 2D surface engiine, the assumption that y is multiplied by 306E pitch is not crazy
2018-04-05 01:06:50 +03:00
kd-11 2dce55d036 rsx: ZCULL synchronization fixes
- Track asynchronous operations in RSX core
- Add read barriers to force pending writes to finish.
  Fixes zcull delay flicker in all UE3 titles without forcing hard stall
- Increase zcull latency as all writes should be synchronized now
2018-03-13 18:55:03 +03:00
kd-11 315798b1f4 rsx: ZCULL rewrite and other improvements
- ZCULL unit emulation rewritten
- ZCULL reports are now deferred avoiding pipeline stalls
- Minor optimizations; replaced std::mutex with shared_mutex where contention is rare
- Silence unnecessary error message
- Small improvement to out of memory handling for vulkan and slightly bump vertex buffer heap
2018-03-13 18:55:03 +03:00
kd-11 dece1e01f4 rsx: Improve transform constants management
- Removes the duplicate local_transform_constants
- Resets the transform constants on every context reset
- Simplifies the code abit which should make it faster
- NOTE: Transform constants are persistent across context re-init events (VF5)
2018-03-13 18:55:03 +03:00
kd-11 e230867492 rsx: Properly implement raster window offsets 2018-03-13 18:55:03 +03:00
kd-11 84b8a08d26 rsx: Basic performance counters 2018-03-13 18:55:03 +03:00
kd-11 a8ab408f64 rsx: Account for null blit ops (memcpy)
- Do not perform extra memory tasks if no actual image copy was performed
2018-02-16 16:14:54 +03:00
kd-11 bd297d079d rsx: Minor optimizations 2018-02-16 16:14:54 +03:00