Xamarin Public Jenkins (auto-signing) ef583813eb Imported Upstream version 6.4.0.137
Former-commit-id: 943baa9f16a098c33e129777827f3a9d20da00d6
2019-07-26 19:53:28 +00:00

29 lines
740 B
C#

using System.Runtime.CompilerServices;
#if BIT64
using nuint = System.UInt64;
#else
using nuint = System.UInt32;
#endif
namespace System.Runtime
{
static class RuntimeImports
{
internal static unsafe void RhZeroMemory (ref byte b, nuint byteLength)
{
fixed (byte* bytePointer = &b) {
ZeroMemory (bytePointer, byteLength);
}
}
internal static unsafe void RhZeroMemory (IntPtr p, UIntPtr byteLength) => ZeroMemory ((void*) p, (nuint) byteLength);
[MethodImpl (MethodImplOptions.InternalCall)]
static extern unsafe void ZeroMemory (void* p, nuint byteLength);
[MethodImpl (MethodImplOptions.InternalCall)]
internal extern static void RhBulkMoveWithWriteBarrier (ref byte dmem, ref byte smem, nuint size);
}
}