working on L4's tlsf
This commit is contained in:
@@ -117,24 +117,5 @@ namespace StgSharp.HighPerformance.Memory
|
||||
return false;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
private unsafe bool TryGetEmptyLine(
|
||||
nuint size,
|
||||
out int index
|
||||
|
||||
)
|
||||
{
|
||||
if (!_bufferAllocator.TryAlloc(size, out Tlsf.Handle handle))
|
||||
{
|
||||
index = 0;
|
||||
return false;
|
||||
}
|
||||
|
||||
// origin :CacheLineHead* entry = (CacheLineHead*)handle.EntryHandle;
|
||||
CacheLineHead* entry = (CacheLineHead*)handle.Address;
|
||||
index = entry->Id;
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user