diff --git a/renderdoc/driver/d3d12/d3d12_shader_feedback.cpp b/renderdoc/driver/d3d12/d3d12_shader_feedback.cpp index f6a27551d..6ece37fe9 100644 --- a/renderdoc/driver/d3d12/d3d12_shader_feedback.cpp +++ b/renderdoc/driver/d3d12/d3d12_shader_feedback.cpp @@ -191,11 +191,7 @@ static bool AnnotateDXILShader(const DXBC::DXBCContainer *dxbc, uint32_t space, const std::map &slots, bytebuf &editedBlob) { - DXIL::ProgramEditor editor(dxbc, slots.size(), editedBlob); - - const DXIL::Type *i32 = editor.GetInt32Type(); - const DXIL::Type *i8 = editor.GetInt8Type(); - const DXIL::Type *i1 = editor.GetBoolType(); + DXIL::ProgramEditor editor(dxbc, slots.size() + 64, editedBlob); const DXIL::Type *handleType = editor.GetTypeByName("dx.types.Handle"); const DXIL::Function *createHandle = editor.GetFunctionByName("dx.op.createHandle"); @@ -205,6 +201,10 @@ static bool AnnotateDXILShader(const DXBC::DXBCContainer *dxbc, uint32_t space, if(!handleType || !createHandle) return false; + const DXIL::Type *i32 = editor.GetInt32Type(); + const DXIL::Type *i8 = editor.GetInt8Type(); + const DXIL::Type *i1 = editor.GetBoolType(); + // get the atomic function we'll need const DXIL::Function *atomicBinOp = editor.GetFunctionByName("dx.op.atomicBinOp.i32"); if(!atomicBinOp) diff --git a/renderdoc/driver/shaders/dxil/dxil_bytecode.cpp b/renderdoc/driver/shaders/dxil/dxil_bytecode.cpp index 6789c7b1f..c3e7c629e 100644 --- a/renderdoc/driver/shaders/dxil/dxil_bytecode.cpp +++ b/renderdoc/driver/shaders/dxil/dxil_bytecode.cpp @@ -2387,7 +2387,7 @@ const DXIL::Type *Program::GetBoolType() } if(!m_BoolType) - RDCERR("Couldn't find void type"); + RDCERR("Couldn't find bool type"); return m_BoolType; } @@ -2408,7 +2408,7 @@ const Type *Program::GetInt32Type() } if(!m_Int32Type) - RDCERR("Couldn't find void type"); + RDCERR("Couldn't find int32 type"); return m_Int32Type; } @@ -2429,7 +2429,7 @@ const Type *Program::GetInt8Type() } if(!m_Int8Type) - RDCERR("Couldn't find void type"); + RDCERR("Couldn't find int8 type"); return m_Int8Type; }