Merge pull request #1921 from ogniK5377/no-unit
Fixed uninitialized memory due to missing returns in canary
This commit is contained in:
commit
e75e8b9580
14 changed files with 34 additions and 3 deletions
|
@ -67,6 +67,7 @@ public:
|
|||
6, "ShaderTrianglesAdjacency");
|
||||
default:
|
||||
UNREACHABLE_MSG("Unknown primitive mode.");
|
||||
return LazyGeometryProgram(geometry_programs.points, "points", 1, "ShaderPoints");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -364,6 +364,7 @@ public:
|
|||
return value;
|
||||
default:
|
||||
UNREACHABLE_MSG("Unimplemented conversion size: {}", static_cast<u32>(size));
|
||||
return value;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -626,6 +627,7 @@ public:
|
|||
return "floatBitsToInt(" + value + ')';
|
||||
} else {
|
||||
UNREACHABLE();
|
||||
return value;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2062,6 +2064,8 @@ private:
|
|||
std::to_string(instr.alu.GetSignedImm20_20())};
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return {regs.GetRegisterAsInteger(instr.gpr39, 0, false),
|
||||
std::to_string(instr.alu.GetSignedImm20_20())};
|
||||
}
|
||||
}();
|
||||
const std::string offset = '(' + packed_shift + " & 0xff)";
|
||||
|
@ -3312,6 +3316,7 @@ private:
|
|||
return std::to_string(instr.r2p.immediate_mask);
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return std::to_string(instr.r2p.immediate_mask);
|
||||
}
|
||||
}();
|
||||
const std::string mask = '(' + regs.GetRegisterAsInteger(instr.gpr8, 0, false) +
|
||||
|
@ -3775,7 +3780,10 @@ private:
|
|||
}
|
||||
break;
|
||||
}
|
||||
default: { UNIMPLEMENTED_MSG("Unhandled instruction: {}", opcode->get().GetName()); }
|
||||
default: {
|
||||
UNIMPLEMENTED_MSG("Unhandled instruction: {}", opcode->get().GetName());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
|
@ -3930,4 +3938,4 @@ std::optional<ProgramResult> DecompileProgram(const ProgramCode& program_code, u
|
|||
return {};
|
||||
}
|
||||
|
||||
} // namespace OpenGL::GLShader::Decompiler
|
||||
} // namespace OpenGL::GLShader::Decompiler
|
||||
|
|
|
@ -427,6 +427,7 @@ static const char* GetSource(GLenum source) {
|
|||
RET(OTHER);
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return "Unknown source";
|
||||
}
|
||||
#undef RET
|
||||
}
|
||||
|
@ -445,6 +446,7 @@ static const char* GetType(GLenum type) {
|
|||
RET(MARKER);
|
||||
default:
|
||||
UNREACHABLE();
|
||||
return "Unknown type";
|
||||
}
|
||||
#undef RET
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue