mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-19 04:56:32 +00:00
RD DXIL Disassembly: ignore first getelemenptr index if it is zero
Before GroupShared float* _30 = shared_pos[0] + _29; After GroupShared float* _30 = shared_pos[_29];
This commit is contained in:
@@ -2786,18 +2786,33 @@ void Program::MakeRDDisassemblyString(const DXBC::Reflection *reflection)
|
||||
|
||||
lineStr += ptrStr;
|
||||
// arg[1] : index 0
|
||||
bool first = true;
|
||||
if(inst.args.size() > 1)
|
||||
{
|
||||
lineStr += "[";
|
||||
lineStr += ArgToString(inst.args[1], false);
|
||||
lineStr += "]";
|
||||
if(getival<uint32_t>(inst.args[1]) > 0)
|
||||
{
|
||||
lineStr += "[";
|
||||
lineStr += ArgToString(inst.args[1], false);
|
||||
lineStr += "]";
|
||||
first = false;
|
||||
}
|
||||
}
|
||||
|
||||
// arg[2..] : index 1...N
|
||||
for(size_t a = 2; a < inst.args.size(); ++a)
|
||||
{
|
||||
lineStr += " + ";
|
||||
if(first)
|
||||
lineStr += "[";
|
||||
else
|
||||
lineStr += " + ";
|
||||
|
||||
lineStr += ArgToString(inst.args[a], false);
|
||||
|
||||
if(first)
|
||||
{
|
||||
lineStr += "]";
|
||||
first = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user