引擎版本5.3.2。我们内部测试开启dx12校验层后,会随机会报一些buffer状态不正确的问题,譬如: “Resource state (0x2: D3D12_RESOURCE_STATE_INDEX_BUFFER) of resource (0x000001E8C090FA90:‘Unnamed ID3D12Resource Object’) (subresource: 0) is invalid for use as a root constant buffer. Expected State Bits (all): 0x1: D3D12_RESOURCE_STATE_VERTEX_AND_CONSTANT_BUFFER, Actual State: 0x2: D3D12_RESOURCE_STATE_INDEX_BUFFER, Missing State: 0x1: D3D12_RESOURCE_STATE_VERTEX_AND_CONSTANT_BUFFER”。因为不好复现、不好截帧,很难定位是哪一次ResourceBarrier调用导致后续对象状态不正确。这个问题是不是5.3.2版本的RDG已知的问题?是的话后续版本有没有修复?
Hi,
我搜了一下内部,看到一个类似的问题,
LogD3D12RHI: Error: ID3D12CommandList::DrawIndexedInstanced: Using IASetIndexBuffer on Command List (0x000001EBE5494190:'Unnamed ID3D12GraphicsCommandList Object'): Resource state (0x1: D3D12_RESOURCE_STATE_VERTEX_AND_CONSTANT_BUFFER) of resource (0x000001EBE48EEA80:'Resource Allocator Underlying Buffer') (subresource: 0) is invalid for use as a index buffer. Expected State Bits (all): 0x2: D3D12_RESOURCE_STATE_INDEX_BUFFER, Actual State: 0x1: D3D12_RESOURCE_STATE_VERTEX_AND_CONSTANT_BUFFER, Missing State: 0x2: D3D12_RESOURCE_STATE_INDEX_BUFFER.
但是应该是微软的validation layer里的bug,我们应该已经在UE5.3里修复了这个问题(CL#26575304)。
Microsoft has confirmed that this is a bug in the validation layer and the error is bogus. The bug will be fixed in the next Agility SDK release.
有没有其它已知的校验层BUG
CL#xxxx 在github上找不到的吧,能不能麻烦你们提供下git commit hash
https://github.com/EpicGames/UnrealEngine/commit/4eb93f6824c65f4a2f7ffeafb2ff55c0b9123bbf
不过因为这个改动实际是更新二进制的改动,所以不在git上显示。主要修改都在Engine\Source\ThirdParty\Windows\DirectX\x64和\Arm64目录下。
这个改动在我们用的5.3.2中已经包含了,这么说是这个bug微软还没修明白吗?
emmm,我不太确定,我们自己内部的测试应该是没有这个问题了。可以试试5.5是否还有类似的问题。。。