Thanks for replying!
I've used that C example as my guide, which means I create every object per invocation. As for the bytecode, DXC compiles the HLSL in each invocation, so the DXIL bytecode fed to IRObjectCreateFromDXIL isn't shared either. The DXC implementation of this also looks nearly identical to the example C code in the manual.
The crashes I encounter tend to originate from irmetalirconverter.dll in some of the allocation functions like RtlFreeHeap() or RtlAllocateHeap(), so maybe there's an unsafe allocator or something.
Interestingly, I am able to catch the issue with gflags page heap. This double free happens deep within the irmetalirconverter.dll call stack during the call to IRCompilerAllocCompileAndLink:
VERIFIER STOP 0000000000000007: pid 0x8EC0: block already freed
0000024E535A1000 : Heap handle
0000024E6016CFE0 : Heap block
0000000000000000 : Block size
0000000000000000 :
I will make a note to submit this to the feedback assistant, as per your guidance.
Topic:
Graphics & Games
SubTopic:
Metal
Tags: