misc: chore: Fix object creation in Cpu project
This commit is contained in:
@@ -49,7 +49,7 @@ namespace ARMeilleure.Common
|
||||
|
||||
public TableSparseBlock(ulong size, Action<IntPtr> ensureMapped, PageInitDelegate pageInit)
|
||||
{
|
||||
SparseMemoryBlock block = new SparseMemoryBlock(size, pageInit, null);
|
||||
SparseMemoryBlock block = new(size, pageInit, null);
|
||||
|
||||
_trackingEvent = (ulong address, ulong size, bool write) =>
|
||||
{
|
||||
@@ -363,7 +363,7 @@ namespace ARMeilleure.Common
|
||||
/// <returns>The new sparse block that was added</returns>
|
||||
private TableSparseBlock ReserveNewSparseBlock()
|
||||
{
|
||||
TableSparseBlock block = new TableSparseBlock(_sparseBlockSize, EnsureMapped, InitLeafPage);
|
||||
TableSparseBlock block = new(_sparseBlockSize, EnsureMapped, InitLeafPage);
|
||||
|
||||
_sparseReserved.Add(block);
|
||||
_sparseReservedOffset = 0;
|
||||
@@ -416,7 +416,7 @@ namespace ARMeilleure.Common
|
||||
IntPtr address = (IntPtr)NativeAllocator.Instance.Allocate((uint)size);
|
||||
page = new AddressTablePage(false, address);
|
||||
|
||||
Span<T> span = new Span<T>((void*)page.Address, length);
|
||||
Span<T> span = new((void*)page.Address, length);
|
||||
span.Fill(fill);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user