1
0
Fork 0
mirror of https://github.com/Ryujinx/Ryujinx.git synced 2024-11-14 16:07:14 +00:00
Ryujinx/Ryujinx.Input
jhorv 5131b71437
Reducing memory allocations (#4537)
* add RecyclableMemoryStream dependency and MemoryStreamManager

* organize BinaryReader/BinaryWriter extensions

* add StreamExtensions to reduce need for BinaryWriter

* simple replacments of MemoryStream with RecyclableMemoryStream

* add write ReadOnlySequence<byte> support to IVirtualMemoryManager

* avoid 0-length array creation

* rework IpcMessage and related types to greatly reduce memory allocation by using RecylableMemoryStream, keeping streams around longer, avoiding their creation when possible, and avoiding creation of BinaryReader and BinaryWriter when possible

* reduce LINQ-induced memory allocations with custom methods to query KPriorityQueue

* use RecyclableMemoryStream in StreamUtils, and use StreamUtils in EmbeddedResources

* add constants for nanosecond/millisecond conversions

* code formatting

* XML doc adjustments

* fix: StreamExtension.WriteByte not writing non-zero values for lengths <= 16

* XML Doc improvements. Implement StreamExtensions.WriteByte() block writes for large-enough count values.

* add copyless path for StreamExtension.Write(ReadOnlySpan<int>)

* add default implementation of IVirtualMemoryManager.Write(ulong, ReadOnlySequence<byte>); remove previous explicit implementations

* code style fixes

* remove LINQ completely from KScheduler/KPriorityQueue by implementing a custom struct-based enumerator
2023-03-17 13:14:50 +01:00
..
Assigner Minor code formatting (#4498) 2023-03-04 14:43:08 +01:00
HLE [Headless] Add missing arguments & Fix typos (#4193) 2023-01-09 04:55:37 +01:00
Motion Reducing memory allocations (#4537) 2023-03-17 13:14:50 +01:00
GamepadButtonInputId.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
GamepadFeaturesFlag.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
GamepadStateSnapshot.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
IGamepad.cs Implement vibrations (#2468) 2021-08-05 00:39:40 +02:00
IGamepadDriver.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
IKeyboard.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
IMouse.cs Add Direct Mouse Support (#2374) 2021-06-24 02:09:08 +02:00
Key.cs Avalonia UI - Part 1 (#3270) 2022-05-15 13:30:15 +02:00
KeyboardStateSnapshot.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
MotionInputId.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00
MouseButton.cs Add TouchScreen Manager (#2333) 2021-06-14 08:42:55 +02:00
MouseStateSnapshot.cs Add Direct Mouse Support (#2374) 2021-06-24 02:09:08 +02:00
Ryujinx.Input.csproj misc: Some dependencies cleanup (#4507) 2023-03-12 03:24:11 +01:00
StickInputId.cs Miria: The Death of OpenTK 3 (#2194) 2021-04-14 12:28:43 +02:00