Skip to content

Fixed ambient probe convolution warning #6523

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

Merged
merged 40 commits into from
Dec 14, 2021

Conversation

JulienIgnace-Unity
Copy link
Contributor

@JulienIgnace-Unity JulienIgnace-Unity commented Dec 8, 2021

Purpose of this PR

Fixed ambient probe convolution warning
Unfortunately, this shader uses a lot of temp VGPR and we could not rewrite it to use less so we ended up using a temporary compute buffer in memory. This should not be a problem for performance as this shader is already super fast and not executed often generally.

Fixes: https://fogbugz.unity3d.com/f/cases/1388268/


Testing status

Ran graphics tests


Comments to reviewers

Need to merge #6035 first

JulienIgnace-Unity and others added 30 commits October 13, 2021 12:20
…d of a constant buffer generated through CPU readback
… into hd/gpu-ambient-probe

# Conflicts:
#	com.unity.render-pipelines.high-definition/Runtime/Sky/SkyManager.cs
…ologies/Graphics into hd/rg-skymanager

# Conflicts:
#	com.unity.render-pipelines.high-definition/Runtime/RenderPipeline/HDRenderPipeline.RenderGraph.cs
#	com.unity.render-pipelines.high-definition/Runtime/Sky/SkyManager.cs
… into hd/gpu-ambient-probe

# Conflicts:
#	com.unity.render-pipelines.high-definition/CHANGELOG.md
… into hd/rg-skymanager

# Conflicts:
#	com.unity.render-pipelines.high-definition/Runtime/Sky/AmbientProbeConvolution.compute
#	com.unity.render-pipelines.high-definition/Runtime/Sky/SkyManager.cs
@github-actions
Copy link

github-actions bot commented Dec 8, 2021

Hi! This comment will help you figure out which jobs to run before merging your PR. The suggestions are dynamic based on what files you have changed.
Link to Yamato: https://unity-ci.cds.internal.unity3d.com/project/902/
Search for your PR branch using the search bar at the top, then add the following segment(s) to the end of the URL (you may need multiple tabs depending on how many packages you change)

HDRP
/jobDefinition/.yamato%2Fall-hdrp.yml%23PR_HDRP_trunk
With changes to HDRP packages, you should also run
/jobDefinition/.yamato%2Fall-lightmapping.yml%23PR_Lightmapping_trunk

Depending on the scope of your PR, you may need to run more jobs than what has been suggested. Please speak to your lead or a Graphics SDET (#devs-graphics-automation) if you are unsure.

@github-actions github-actions bot added the HDRP label Dec 8, 2021
@github-actions
Copy link

github-actions bot commented Dec 8, 2021

It appears that you made a non-draft PR!
Please convert your PR to draft (button on the right side of the page).
See the PR template for more information.
Thank you!

… into hd/fix-convolution-warning

# Conflicts:
#	com.unity.render-pipelines.high-definition/Runtime/Sky/SkyManager.cs
{
int c = 0;
for (c = 0; c < 3; c++)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Extra white line

// If we use local VGPRs as a scratch buffer we end up using too many register
// To avoid that we go through memory.
// This is quite messy and bad for performance but this shader should never be critical so it should be fine.
// Uint is used as it's the only format supported everywhere as read/write from same thread.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

*on all platforms

Many platform do support typed loads on other formats

Copy link
Contributor

@FrancescoC-unity FrancescoC-unity left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yuck, but hey whatever is needed

@sebastienlagarde sebastienlagarde merged commit 9c4e6be into master Dec 14, 2021
@sebastienlagarde sebastienlagarde deleted the hd/fix-convolution-warning branch December 14, 2021 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants