Make the shader translator more error resilient (part 2)
This commit is contained in:
parent
04102e5c9d
commit
8eb773d81f
5 changed files with 67 additions and 31 deletions
|
@ -28,6 +28,13 @@ namespace Ryujinx.Graphics.Shader.Translation
|
|||
|
||||
Block[] cfg = Decoder.Decode(code, (ulong)headerSize);
|
||||
|
||||
if (cfg == null)
|
||||
{
|
||||
// TODO: Error.
|
||||
|
||||
return code;
|
||||
}
|
||||
|
||||
ulong endAddress = 0;
|
||||
|
||||
foreach (Block block in cfg)
|
||||
|
@ -163,6 +170,8 @@ namespace Ryujinx.Graphics.Shader.Translation
|
|||
|
||||
if (cfg == null)
|
||||
{
|
||||
// TODO: Error.
|
||||
|
||||
size = 0;
|
||||
|
||||
return new Operation[0];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue