mirror of
https://github.com/ryujinx-mirror/ryujinx.git
synced 2025-08-30 23:26:26 -05:00
aloha
This commit is contained in:
33
Ryujinx/Cpu/Instruction/AInstEmitException.cs
Normal file
33
Ryujinx/Cpu/Instruction/AInstEmitException.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using ChocolArm64.Decoder;
|
||||
using ChocolArm64.State;
|
||||
using ChocolArm64.Translation;
|
||||
using System;
|
||||
|
||||
namespace ChocolArm64.Instruction
|
||||
{
|
||||
static partial class AInstEmit
|
||||
{
|
||||
public static void Svc(AILEmitterCtx Context)
|
||||
{
|
||||
AOpCodeException Op = (AOpCodeException)Context.CurrOp;
|
||||
|
||||
Context.EmitStoreState();
|
||||
|
||||
Context.EmitLdarg(ATranslatedSub.RegistersArgIdx);
|
||||
|
||||
Context.EmitLdc_I4(Op.Id);
|
||||
|
||||
Context.EmitCall(typeof(ARegisters), nameof(ARegisters.OnSvcCall));
|
||||
|
||||
if (Context.CurrBlock.Next != null)
|
||||
{
|
||||
Context.EmitLoadState(Context.CurrBlock.Next);
|
||||
}
|
||||
}
|
||||
|
||||
public static void Und(AILEmitterCtx Context)
|
||||
{
|
||||
throw new Exception("und inst! " + Context.CurrOp.Position.ToString("x8"));
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user