Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/libraries/System.Private.CoreLib/src/System/Buffer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public static unsafe void MemoryCopy(void* source, void* destination, ulong dest
// Non-inlinable wrapper around the QCall that avoids polluting the fast path
// with P/Invoke prolog/epilog.
[MethodImpl(MethodImplOptions.NoInlining)]
internal static unsafe void Memmove(ref byte dest, ref byte src, nuint len)
internal static unsafe void MemmoveInternal(ref byte dest, ref byte src, nuint len)
{
fixed (byte* pDest = &dest)
fixed (byte* pSrc = &src)
Expand All @@ -137,7 +137,7 @@ internal static unsafe void Memmove(ref byte dest, ref byte src, nuint len)
// Non-inlinable wrapper around the QCall that avoids polluting the fast path
// with P/Invoke prolog/epilog.
[MethodImpl(MethodImplOptions.NoInlining)]
internal static unsafe void ZeroMemory(ref byte b, nuint byteLength)
internal static unsafe void ZeroMemoryInternal(ref byte b, nuint byteLength)
{
fixed (byte* bytePointer = &b)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ internal static void Memmove(ref byte dest, ref byte src, nuint len)
Debug.Assert(len > 0);
_ = Unsafe.ReadUnaligned<byte>(ref dest);
_ = Unsafe.ReadUnaligned<byte>(ref src);
Buffer.Memmove(ref dest, ref src, len);
Buffer.MemmoveInternal(ref dest, ref src, len);
}

[Intrinsic] // Unrolled for small sizes
Expand Down Expand Up @@ -425,7 +425,7 @@ public static void ClearWithoutReferences(ref byte dest, nuint len)
PInvoke:
// Implicit nullchecks
_ = Unsafe.ReadUnaligned<byte>(ref dest);
Buffer.ZeroMemory(ref dest, len);
Buffer.ZeroMemoryInternal(ref dest, len);
}

internal static void Fill(ref byte dest, byte value, nuint len)
Expand Down