Ryujinx/Ryujinx.Cpu
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
..
AppleHv Clear CPU side data on GPU buffer clears (#4125) 2023-02-16 18:28:49 -03:00
Jit Clear CPU side data on GPU buffer clears (#4125) 2023-02-16 18:28:49 -03:00
Tracking Update range for remapped sparse textures instead of recreating them (#4442) 2023-03-14 17:08:44 -03:00
AddressSpace.cs Fix NRE when disposing AddressSpace with 4KB pages support (#4307) 2023-01-17 14:50:39 +00:00
ExceptionCallbacks.cs Make structs readonly when applicable (#4002) 2022-12-05 14:47:39 +01:00
ICpuContext.cs Make PPTC state non-static (#4157) 2023-01-05 00:01:44 +01:00
ICpuEngine.cs Refactor CPU interface to allow the implementation of other CPU emulators (#3362) 2022-05-31 16:29:35 -03:00
IDiskCacheState.cs Make PPTC state non-static (#4157) 2023-01-05 00:01:44 +01:00
IExecutionContext.cs Capitalization to be consistent (#3860) 2022-11-17 18:13:37 +01:00
ITickSource.cs Refactor CPU interface to allow the implementation of other CPU emulators (#3362) 2022-05-31 16:29:35 -03:00
IVirtualMemoryManagerTracked.cs Clear CPU side data on GPU buffer clears (#4125) 2023-02-16 18:28:49 -03:00
LoadState.cs Make PPTC state non-static (#4157) 2023-01-05 00:01:44 +01:00
MemoryEhMeilleure.cs Clear CPU side data on GPU buffer clears (#4125) 2023-02-16 18:28:49 -03:00
MemoryHelper.cs Reducing memory allocations (#4537) 2023-03-17 13:14:50 +01:00
MemoryManagerBase.cs
PrivateMemoryAllocation.cs Implement support for page sizes > 4KB (#4252) 2023-01-17 05:13:24 +01:00
PrivateMemoryAllocator.cs Implement support for page sizes > 4KB (#4252) 2023-01-17 05:13:24 +01:00
Ryujinx.Cpu.csproj infra: Migrate to .NET 7 (#3795) 2022-11-09 20:22:43 +01:00
TickSource.cs Refactor CPU interface to allow the implementation of other CPU emulators (#3362) 2022-05-31 16:29:35 -03:00