Implement a Macro JIT (#1445)

* Implement a Macro JIT

* Nit: space
This commit is contained in:
gdkchan 2020-08-02 22:36:57 -03:00 committed by GitHub
parent c11855565e
commit 60db4c3530
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 774 additions and 159 deletions

View file

@ -32,6 +32,11 @@ namespace Ryujinx.Graphics.Gpu.State
private readonly Register[] _registers;
/// <summary>
/// Gets or sets the shadow ram control used for this sub-channel.
/// </summary>
public ShadowRamControl ShadowRamControl { get; set; }
/// <summary>
/// Creates a new instance of the GPU state.
/// </summary>
@ -72,14 +77,15 @@ namespace Ryujinx.Graphics.Gpu.State
/// Calls a GPU method, using this state.
/// </summary>
/// <param name="meth">The GPU method to be called</param>
/// <param name="shadowCtrl">Shadow RAM control register value</param>
public void CallMethod(MethodParams meth, ShadowRamControl shadowCtrl)
public void CallMethod(MethodParams meth)
{
int value = meth.Argument;
// Methods < 0x80 shouldn't be affected by shadow RAM at all.
if (meth.Method >= 0x80)
{
ShadowRamControl shadowCtrl = ShadowRamControl;
// TODO: Figure out what TrackWithFilter does, compared to Track.
if (shadowCtrl == ShadowRamControl.Track ||
shadowCtrl == ShadowRamControl.TrackWithFilter)