diff options
| author | jsmall-nvidia <jsmall@nvidia.com> | 2020-01-15 14:58:45 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-01-15 14:58:45 -0500 |
| commit | 662721ba4ab0e38924701df4c876a86eb8390968 (patch) | |
| tree | deef68220d0aebbdfff370918a3d42fcf12fd72c /tools/render-test/cpu-compute-util.h | |
| parent | ef41dfc605f7868c0ccc7dde05982232b7d49589 (diff) | |
Bind Location (#1166)
* First pass at BindLocation.
* Added BindSet::init - for initializing with two input constant buffers. Needs better name, and perhaps should be another class.
* Fix handling of constant buffer stripping.
Improved initialization.
* Trying to generalize BindLocation a little more.
Split out CPULikeBindRoot.
* More work to make BindLocation et al work with non uniform bindings.
* Added parsing to a location.
* WIP: Trying to get CPU working with BindLocation.
* Describe problem of knowing the type of the reference point in the binding table.
* More ideas on getBindings fix.
* Remove BindSet as member of BindLocation.
* Added BindLocation::Invalid
* Made BindLocation able to be key in hash
* Use BindLocation for bindings on BindingSet.
* Added cuda and nvrtc categories to test infrastructure.
Disabled CUDA synthetic tests by default.
Fixed such that all tests now produce something in BindLocation style.
* Use m_userIndex instead of m_userData on Resource.
Move the binding setup out of cpu-compute-util (as no longer CPU specific)
* Removed CPUBinding - used BindLocation/BindSet instead.
Fixed some bugs around indexOf around uniform indirection.
* Renamed BindSet::Resource -> BindSet::Value.
* Document BindLocation.
* Fixes for Clang/GCC
Improve invariant requirement handling when constructing from BindPoints.
Diffstat (limited to 'tools/render-test/cpu-compute-util.h')
| -rw-r--r-- | tools/render-test/cpu-compute-util.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tools/render-test/cpu-compute-util.h b/tools/render-test/cpu-compute-util.h index 179985f6f..21c40ba43 100644 --- a/tools/render-test/cpu-compute-util.h +++ b/tools/render-test/cpu-compute-util.h @@ -1,10 +1,11 @@ #ifndef CPU_COMPUTE_UTIL_H #define CPU_COMPUTE_UTIL_H -#include "cpu-memory-binding.h" #include "slang-support.h" #include "options.h" +#include "bind-location.h" + #include "../../source/core/slang-smart-pointer.h" namespace renderer_test { @@ -28,11 +29,11 @@ struct CPUComputeUtil struct Context { /// Holds the binding information - CPUMemoryBinding binding; + BindSet m_bindSet; + CPULikeBindRoot m_bindRoot; + /// Buffers are held in same order as entries in layout (useful for dumping out bindings) - List<CPUMemoryBinding::Buffer> buffers; - /// Holds the resources created (in calcBindings) - List<RefPtr<Resource> > m_resources; + List<BindSet::Value*> m_buffers; }; struct ExecuteInfo @@ -53,12 +54,12 @@ struct CPUComputeUtil static SlangResult checkStyleConsistency(ISlangSharedLibrary* sharedLib, const uint32_t dispatchSize[3], const ShaderCompilerUtil::OutputAndLayout& compilationAndLayout); static SlangResult calcBindings(const ShaderCompilerUtil::OutputAndLayout& compilationAndLayout, Context& outContext); - + static SlangResult calcExecuteInfo(ExecuteStyle style, ISlangSharedLibrary* sharedLib, const uint32_t dispatchSize[3], const ShaderCompilerUtil::OutputAndLayout& compilationAndLayout, Context& context, ExecuteInfo& out); static SlangResult execute(const ExecuteInfo& info); - static SlangResult writeBindings(const ShaderInputLayout& layout, const List<CPUMemoryBinding::Buffer>& buffers, const Slang::String& fileName); + static SlangResult writeBindings(const ShaderInputLayout& layout, const List<BindSet::Value*>& buffers, const Slang::String& fileName); }; |
