Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rsx: Bug fixes #2861

Merged
merged 26 commits into from
Jun 22, 2017
Merged

rsx: Bug fixes #2861

merged 26 commits into from
Jun 22, 2017

Conversation

kd-11
Copy link
Contributor

@kd-11 kd-11 commented Jun 11, 2017

  • Fix stencil clear values - Regression: FEAR 2 Demo #2810
  • Fix some buffer misalignment crashes when using debuggers or faulty drivers
  • Fix an old regression with God of War I and II from the collection - God of War 1&2 HD old regression #2626
  • Fix openGL clip space conversion (Z symmetry)
  • Add a workaround to fix shadow map generation
  • Add hardware PCF shadow support
  • Fix stencil buffer reset (Still a workaround atm)
  • Remove several hundred compilation warnings from rsx code
  • Improve SPIRV compilation speed by avoiding unnecessary SH context (re)creattion
  • Add a needed rsx method for wipeout HD
  • Fix index buffer generation when using a non-zero base offset
  • Drop vs user files from the repo
  • Added a toggle to ensure strict rendering mode. Currently only affects framebuffer feedback loops. When disabled, we ignore the feedback loop in vulkan and issue a texture barrier in ogl. When enabled, a duplicate texture is created to ensure this is not an issue but there is a tangible performance penalty. Defaults to OFF
  • Re-organized the graphics options tab a bit to separate main options from debugging options.

Current bugs

  • Crash compiling textureProj due to PCF samplers support
  • Crash when debug overlay is enabled (vulkan only)

@mention-bot
Copy link

@kd-11, thanks for your PR! By analyzing the history of the files in this pull request, we identified @vlj, @Nekotekina and @jarveson to be potential reviewers.

@kd-11 kd-11 mentioned this pull request Jun 11, 2017
@MarioSonic2987
Copy link
Contributor

MarioSonic2987 commented Jun 11, 2017

@kd-11
This PR:
image 1
Master:
image

@Xcedf
Copy link

Xcedf commented Jun 11, 2017

Confirm GoW issue is fixed, also fixed same depth issue in Ni No Kuni Demo
thx for the awesome work

@kd-11 kd-11 changed the title rsx: Bug fixes [WIP] rsx: Bug fixes Jun 12, 2017
@kd-11
Copy link
Contributor Author

kd-11 commented Jun 12, 2017

Marking as WIP since touching this has uncovered alot of other issues.

@woj1993
Copy link

woj1993 commented Jun 13, 2017

@kd-11 What issues?
PS. Are you sure this is best option? I worry you fix might stay marked as WIP too long and will need another rewrite if it isn't merged now.

@AniLeo
Copy link
Member

AniLeo commented Jun 13, 2017

@woj1993 no need to worry, it will get merged relatively soon. We're running internal tests.

@takhlaq
Copy link
Contributor

takhlaq commented Jun 20, 2017

The Legend of Heroes: Trails of Cold Steel [BLUS31572]
looks good
Trails of Cold Steel

@Xcedf
Copy link

Xcedf commented Jun 20, 2017

Magnificent changes, now have perfect shadows in Tekken6 and Soul Calibur IV
but i also have a slowdown in some games if compare to master
here's the example,
master
31
this pr
32
will try to find more specific commit later

@kd-11
Copy link
Contributor Author

kd-11 commented Jun 20, 2017

Disable the invalidate cache option. Should fix performance. Report if it does not.

@Xcedf
Copy link

Xcedf commented Jun 20, 2017

Unfortunately not, doesn't affect performance at all tried both on and off
another example of fps drop Heavy Rain Demo menu
master 18fps
this pr 14fps

@kd-11
Copy link
Contributor Author

kd-11 commented Jun 20, 2017

Odd. I'll look into it.

@VadimSaveljev
Copy link

Demon's souls reborn with this PR
before
after

@Xcedf
Copy link

Xcedf commented Jun 20, 2017

Another issue
several games are fail to compile shaders
Army of Two
Lolipop Chainsaw
OGL:
F {rsx::thread} : class gl::glsl::link_exception thrown: linkage failed: 'Fragment info

0(115) : error C1031: swizzle mask element not present in operand "xyz"
0(128) : error C1031: swizzle mask element not present in operand "xyz"
0(130) : error C1031: swizzle mask element not present in operand "xyz"
0(133) : error C1031: swizzle mask element not present in operand "xyz"
(0) : error C2003: incompatible options for link
Vulkan:
E {rsx::thread} RSX: ERROR: 0:125: 'xyz' : vector swizzle selection out of range
ERROR: 0:125: 'assign' : cannot convert from ' global highp float' to ' temp highp 3-component vector of float'
ERROR: 0:125: '' : compilation terminated
ERROR: 3 compilation errors. No code generated.
E {rsx::thread} RSX:
F {rsx::thread} : class std::runtime_error thrown: Failed to compile fragment shader
(in file C:\rpcs3\rpcs3\Emu\RSX\VK\VKFragmentProgram.cpp:492)

@kd-11
Copy link
Contributor Author

kd-11 commented Jun 20, 2017

Thats new with this build? If so, attach fragmentprogram.spirv here

@Xcedf
Copy link

Xcedf commented Jun 20, 2017

Yes it's on this build, master is fine, here's the new files
https://mega.nz/#!rcZWmYrL!d01JENkZUAx514DmAB7hi7Xa1qL6HOBMZxpqngjJ9MQ

@Sora3100
Copy link

Sora3100 commented Jun 20, 2017

OpenGL (the blue and normal textures seen below flicker along with the eyes):
y81wz 1

Vulkan:
g4uax 1

Also, the command menu in the bottom left seems to have a weird display bug
I can also confirm that Xillia 1/2 now displays shadows

@MarioSonic2987
Copy link
Contributor

Many games are improved with this PR:
gtav
nsunsr
ssbs
tekkenrevolution

@Xcedf
Copy link

Xcedf commented Jun 21, 2017

Some info about my issues:
performance regression caused by cd3d7ef or previous 86465e9(but it has compilation issues, so can't tell for sure now)

@kd-11
Copy link
Contributor Author

kd-11 commented Jun 21, 2017

Thanks alot. Its probably the former since it copies a texture in GPU memory and spams the log. Not sure it should be disabled though as using a current render target as input is a spec violation. I need to check for a way around that.

@Xcedf
Copy link

Xcedf commented Jun 21, 2017

You're welcome
As for shader compilation issue: commit b31d937 is the cause
edited my pervious commit, gave wrong revision sorry
and slowdowns issue it's cd3d7ef for sure
tested only for vulkan, file VKTextureCache.h commenting out lines 492-497 fixes slowdowns, other code cause no slowdowns

@kd-11
Copy link
Contributor Author

kd-11 commented Jun 22, 2017

Disabling those lines allows for a pretty serious spec violation that causes heavy flickering and broken graphics in some cases. It needs some more work to prevent the slowdown.

@Grima04
Copy link

Grima04 commented Jun 22, 2017

Grand Theft Auto V BLES01807

F 0:04:29.285507 {rsx::thread} class gl::glsl::link_exception thrown: linkage failed: 'Vertex info
0(77) : error C0000: syntax error, unexpected '.', expecting ')' at token "."
(0) : error C2003: incompatible options for link

LOG:
RPCS3_GTAV_22-06-2017.zip

Video:
https://www.youtube.com/watch?v=YUn41FgN6eE

kd-11 added 21 commits June 22, 2017 23:13
…sues

- Also set some default values for samplers in a cleaner way using their 'natural' float values
Need to find the proper command issued to discard all surfaces
- Create temporary copies for use with the draw call instead
Another fix for signed normalized formats; single component vectors are swizzled
- Fixes stencil volume shadows in a few games. This is part of the surface invalidation workarounds
- Vertex buffer contents treat the base vertex as vertex 0 so we do the same for indices

rsx: Fix vertex base indexing

rsx: Properly fix non-zero offset indexed rendering
- Wrap unused parameters as comments to prevent C1400
- Fix sized variable conversions with explicit casts
rsx: Give more info when ring buffer allocations fail
@uvraj
Copy link

uvraj commented Jul 19, 2017

unbenannt
having loadscreen issues

@uvraj
Copy link

uvraj commented Jul 19, 2017

unbenannt
PR looks good so far

@uvraj
Copy link

uvraj commented Jul 19, 2017

F {rsx::thread} class std::runtime_error thrown: Unknown texture dimension 0
(in file C:\rpcs3\rpcs3\Emu\RSX\gcm_enums.cpp:137) getting this error

@uvraj
Copy link

uvraj commented Jul 19, 2017

unbenannt
games like minecraft are running pretty well :)

@kd-11
Copy link
Contributor Author

kd-11 commented Jul 19, 2017

This was merged and closed 2 weeks ago. Latest rsx PR is #3026

@kd-11 kd-11 deleted the vulkan branch October 13, 2017 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet