Comments (6)
It may be a bug in the validator with the placed resources and placed resources that you supply virtual addresses directly in the root signature constant. i will confirm this and will reopen if there is something.
from d3d12memoryallocator.
I don't know where can this issue come from, as resource states are tracked per resource, not per memory heap where they are placed. The message says the resource state has been automatically promoted from COMMON to NON_PIXEL_SHADER_RESOURCE and then used as UAV. Please try to explicitly transition it to UNORDERED_ACCESS state before using it for the compute dispatch and see if it helps.
It is also possible that the validation layer has bugs. You can capture a frame using PIX and see what barriers, draw calls, and dispatches are executed that use this texture to figure out whether there is really something wrong with its state or it is a false alarm.
from d3d12memoryallocator.
there was one shader that was reading from uav, i have made it srv and the warning went away,
however now i have the same issue with the another uav,
It is in CollideHairVerticesWithSdf_forward from the tressfx sample. HairVertices buffer which is expected to be RW
Also something else.
If make allocations with ALLOCATION_FLAG_COMMITTED i still get the warning however if
I force CalcDefaultPoolIndex to return UINT32_MAX they stop.
I am on AMD 5700 XT
On the cpu side everything is correct no warnings from validation, may be there is a memory aliasing
any clue will be helpful.
I have not seen such a warning before from DX12.
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: BoneSkinningUpdate [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: BoneSkinningUpdate [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: UpdateSDF [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: UpdateSDF::ConstructSignedDistanceField [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: UpdateSDF [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::IntegrationAndGlobalShapeContraints [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::IntegrationAndGlobalShapeContraints [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::CalculateStrandLevelData [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::CalculateStrandLevelData [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::VelocityShockPropagation [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::VelocityShockPropagation [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::LocalShapeConstraints [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::LocalShapeConstraints [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::LengthConstriantsWindAndCollision [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::LengthConstriantsWindAndCollision [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunSimulation::UpdateFollowHairVertices [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation::UpdateFollowHairVertices [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE END: RunSimulation [ EXECUTION MESSAGE #1015: END_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunCollision [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 MESSAGE: GPU-BASED VALIDATION: TRACE BEGIN: RunCollision::CollideWithHair [ EXECUTION MESSAGE #1014: BEGIN_EVENT]
D3D12 ERROR: GPU-BASED VALIDATION: Dispatch, Incompatible resource state: Resource: 0x000002455B6852B0:'Unnamed ID3D12Resource Object', Subresource Index: [0], Root descriptor type: UAV, Resource State: D3D12_RESOURCE_STATE_NON_PIXEL_SHADER_RESOURCE(0x40) (Promoted from COMMON state), Shader Stage: COMPUTE, Root Parameter Index: [2], Dispatch Index: [21], Shader Code: <couldn't find file location in debug info>, Asm Instruction Range: [0xa-0xffffffff], Asm Operand Index: [0], Command List: 0x000002455B26C190:'CommandList 2, Allocator 0', SRV/UAV/CBV Descriptor Heap: 0x000002455AF8DBA0:'StaticHeapDX12', Sampler Descriptor Heap: 0x000002455AF8F110:'StaticHeapDX12', Pipeline State: 0x000002455B83A6C0:'TressFXSDFCollision.hlslCollideHairVerticesWithSdf_forward', [ EXECUTION ERROR #942: GPU_BASED_VALIDATION_INCOMPATIBLE_RESOURCE_STATE]
from d3d12memoryallocator.
Does your application work correctly despite these errors reported by the validation?
Returning UINT32_MAX from CalcDefaultPoolIndex causes allocation of all the resources as committed.
If you suspect memory aliasing, please use Allocator::BuildStatsString to get JSON dump with the list of all allocations, their offsets and sizes. You can then validate whether they overlap. But I think this is very unlikely.
from d3d12memoryallocator.
from d3d12memoryallocator.
I'm also getting a similar issue, but with no adverse side-effects that I've seen in my application.
Always returning UINT32_MAX to force committed resources in AllocatorPimpl::CalcDefaultPoolIndex(...) suppresses these issues (or non-issues, it would seem).
from d3d12memoryallocator.
Related Issues (20)
- D3D12MA_DEBUG_GLOBAL_MUTEX causes double lock on Release HOT 1
- FindAtOffset compile error with GDK HOT 1
- DivideRoudingUp spelling mistake HOT 1
- Crash on systems older than Windows 10 Build 20348 HOT 3
- Stats inside ASSERT conditional HOT 1
- Offset is not correctly written when exporting to json HOT 2
- Index Buffer Creation fail HOT 2
- XBOX support HOT 1
- UWP: ARM build issues HOT 2
- Questions about Defragmentation Thread Safety HOT 7
- AlignUp SizeInBytes for buffer memory
- Regarding D3D12_HEAP_FLAG_CREATE_NOT_ZEROED HOT 2
- 32-bit compile error: ambiguous call to JsonWriter::WriteNumber with SIZE_T input. HOT 3
- C bindings for Direct3D 12 Memory Allocator HOT 3
- Question about ALLOCATION_FLAG_WITHIN_BUDGET flag HOT 4
- Question about support for deferring block frees HOT 4
- Update vcpkg port HOT 1
- C interface like VMA HOT 1
- GetResourceAllocation errors while using castable formats and CreateResource3
- Is D3D12MA::Allocator::BeginDefragmentation() Work Correctly ? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from d3d12memoryallocator.