mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2025-06-28 19:50:47 -07:00
IPC code gen improvements (#6352)
* HipcGenerator: skip do-nothing call to MemoryMarshal.Cast<byte, byte>() in generated code * HipcGenerator: fix method name typos * HipcGenerator: make generated methods use stackalloc for `isBufferMapAlias` bool array * HipcGenerator: make generated GetCommandHandlers() method return a FrozenDictionary<int, CommandHandler> * HipcGenerator: return `FrozenDictionary<,>.Empty` when there are no command implementations, otherwise create `FrozenDictionary` from a `IEnumerable<KeyValuePair<,>>`` instead of a `Dictionary<,>``
This commit is contained in:
@ -127,7 +127,7 @@ namespace Ryujinx.Horizon.Sdk.Sf
|
||||
return _bufferRanges[argIndex];
|
||||
}
|
||||
|
||||
public Result ProcessBuffers(ref ServiceDispatchContext context, bool[] isBufferMapAlias, ServerMessageRuntimeMetadata runtimeMetadata)
|
||||
public Result ProcessBuffers(ref ServiceDispatchContext context, scoped Span<bool> isBufferMapAlias, ServerMessageRuntimeMetadata runtimeMetadata)
|
||||
{
|
||||
bool mapAliasBuffersValid = true;
|
||||
|
||||
@ -246,7 +246,7 @@ namespace Ryujinx.Horizon.Sdk.Sf
|
||||
return mode == HipcBufferMode.Normal;
|
||||
}
|
||||
|
||||
public void SetOutBuffers(HipcMessageData response, bool[] isBufferMapAlias)
|
||||
public void SetOutBuffers(HipcMessageData response, ReadOnlySpan<bool> isBufferMapAlias)
|
||||
{
|
||||
int recvPointerIndex = 0;
|
||||
|
||||
|
Reference in New Issue
Block a user