mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-10-01 12:30:00 +02:00
afc44850be
* Avoid gpr overwritting on LD_C instruction * Address feedback * Ignore invalid registers
23 lines
No EOL
523 B
C#
23 lines
No EOL
523 B
C#
namespace Ryujinx.Graphics.Gal.Shader
|
|
{
|
|
class ShaderIrOperGpr : ShaderIrNode
|
|
{
|
|
public const int ZRIndex = 0xff;
|
|
|
|
public bool IsConst => Index == ZRIndex;
|
|
|
|
public bool IsValidRegister => (Index <= ZRIndex);
|
|
|
|
public int Index { get; set; }
|
|
|
|
public ShaderIrOperGpr(int Index)
|
|
{
|
|
this.Index = Index;
|
|
}
|
|
|
|
public static ShaderIrOperGpr MakeTemporary(int Index = 0)
|
|
{
|
|
return new ShaderIrOperGpr(0x100 + Index);
|
|
}
|
|
}
|
|
} |