mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-06-28 08:56:24 +02:00
misc: Replace references to IntPtr/UIntPtr with nint/nuint + code cleanups.
This commit is contained in:
parent
a09d314817
commit
dfb4854d19
172 changed files with 902 additions and 914 deletions
|
@ -10,9 +10,9 @@ namespace Ryujinx.Cpu.AppleHv
|
|||
class HvExecutionContextVcpu : IHvExecutionContext
|
||||
{
|
||||
private static readonly MemoryBlock _setSimdFpRegFuncMem;
|
||||
private delegate HvResult SetSimdFpReg(ulong vcpu, HvSimdFPReg reg, in V128 value, IntPtr funcPtr);
|
||||
private delegate HvResult SetSimdFpReg(ulong vcpu, HvSimdFPReg reg, in V128 value, nint funcPtr);
|
||||
private static readonly SetSimdFpReg _setSimdFpReg;
|
||||
private static readonly IntPtr _setSimdFpRegNativePtr;
|
||||
private static readonly nint _setSimdFpRegNativePtr;
|
||||
|
||||
static HvExecutionContextVcpu()
|
||||
{
|
||||
|
@ -25,7 +25,7 @@ namespace Ryujinx.Cpu.AppleHv
|
|||
|
||||
_setSimdFpReg = Marshal.GetDelegateForFunctionPointer<SetSimdFpReg>(_setSimdFpRegFuncMem.Pointer);
|
||||
|
||||
if (NativeLibrary.TryLoad(HvApi.LibraryName, out IntPtr hvLibHandle))
|
||||
if (NativeLibrary.TryLoad(HvApi.LibraryName, out nint hvLibHandle))
|
||||
{
|
||||
_setSimdFpRegNativePtr = NativeLibrary.GetExport(hvLibHandle, nameof(HvApi.hv_vcpu_set_simd_fp_reg));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue