-
Notifications
You must be signed in to change notification settings - Fork 69
Speed up HLSL preprocessing and prepared SPIR-V hot paths #1029
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
Open
AnastaZIuk
wants to merge
37
commits into
master
Choose a base branch
from
unroll
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
624184f
Reduce Wave preprocess overhead and update DXC pointer
AnastaZIuk 555684d
Advance DXC to latest unroll-devshFixes
AnastaZIuk 03ad12b
Restore default include search path for builtin HLSL
AnastaZIuk ac0289d
Advance DXC to latest unroll-devshFixes
AnastaZIuk 8e3c301
Promote NSC channel ac0289dda98b1046000873b0b3ffedb06356be53 (#1028)
github-actions[bot] fe4a528
Update examples_tests to local unroll
AnastaZIuk 441dcb2
Merge remote-tracking branch 'origin/master' into unroll-local-sync
AnastaZIuk f195565
Update EX31 examples pointer
AnastaZIuk 697cfcf
Wire path tracer pipeline cache
AnastaZIuk fad9d56
Update path tracer examples pointer
AnastaZIuk a0b65da
Add SPIR-V trimmer fast path
AnastaZIuk 9515bdd
Update path tracer examples pointer
AnastaZIuk 939de4f
Update path tracer examples pointer
AnastaZIuk dd5180b
Update path tracer examples pointer
AnastaZIuk 8d3e66d
Trim manifest whitespace and update examples pointer
AnastaZIuk cba6113
Clean up shader review leftovers
AnastaZIuk 476a5bf
Update path tracer examples pointer
AnastaZIuk d986945
Cache validated SPIR-V hashes
AnastaZIuk 5ecde9a
Update path tracer examples pointer
AnastaZIuk 1ede3de
Tighten final shader cleanup
AnastaZIuk 758f7c8
Update path tracer examples pointer
AnastaZIuk 8745660
Update path tracer examples pointer
AnastaZIuk 94a501f
Mark generated NSC headers correctly
AnastaZIuk b1f28c0
Update path tracer examples pointer
AnastaZIuk 4b444b6
Revert "Mark generated NSC headers correctly"
AnastaZIuk f4b0aed
Update path tracer examples pointer
AnastaZIuk 01794c5
Update path tracer examples pointer
AnastaZIuk 4a0c2e2
Update path tracer examples pointer
AnastaZIuk 02f04db
Update path tracer examples pointer
AnastaZIuk 3ae2b26
Update path tracer examples pointer
AnastaZIuk fcae991
Update path tracer examples pointer
AnastaZIuk c8af81b
Update path tracer examples pointer
AnastaZIuk 3541a9d
Update path tracer examples pointer
AnastaZIuk 8723771
Validate SPIR-V once per blob
AnastaZIuk 52ae40b
Update EX31 examples pointer
AnastaZIuk 6476500
Update EX31 examples pointer
AnastaZIuk f5f036e
Update EX31 examples pointer
AnastaZIuk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Submodule examples_tests
updated
35 files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there's numerous problems I see with this approach:
CFileSystemIncludeLoaderis a long lived object. The include file contents will change, and because the IFIle will be closed in the meantime there's nothing to stop (on the OS level) that change occuring, you will get stale cache hits and hot-reload (for whatever example implements it) won't kick in.IIncludeLoader::found_t::contentscan be SEVERAL kilobytes per file, this cache will basically live forever as nabla runs so its basically a multi-MB memory leakfurthermore because of concurrency you needed to add a mutex
It would make more sense if you wrapped this up into a
SSessionCachestruct in theCIncludeFinderand specified it as a mutable member inSProcessorOptionsthis way:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think some of the functionality of this was already in
Nabla/include/nbl/asset/utils/IShaderCompiler.h
Line 197 in f5f036e
but it obviously served a different purpose (whole IShader from includes)
but the design there is sound esp with the
readCacheandwriteCacheon the Options struct