2483 references to MemoryMarshal
Aspire.Dashboard.Tests (1)
TelemetryRepositoryTests\MetricsTests.cs (1)
1247Assert.True(Enumerable.SequenceEqual(MemoryMarshal.ToEnumerable(key), scope.Attributes), "Key and attributes don't match.");
GenerateDocumentationAndConfigFiles (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
ILAssembler (2)
GrammarVisitor.cs (2)
3102ReadOnlySpan<char> bytesAsChars = MemoryMarshal.Cast<byte, char>(bytes); 3132str = new string(MemoryMarshal.Cast<byte, char>(utf8Bytes));
ILCompiler.Compiler (5)
Compiler\ReachabilityInstrumentationFilter.cs (1)
47if (reader.Read(MemoryMarshal.Cast<bool, byte>(tokenStates.AsSpan())) != numTokens)
Compiler\TypePreinit.cs (2)
3449return new string(MemoryMarshal.Cast<byte, char>( 3478value.CopyTo(MemoryMarshal.Cast<byte, char>(((Span<byte>)bytes).Slice(firstCharField.Offset.AsInt)));
src\runtime\src\coreclr\tools\Common\Compiler\NativeAotNameMangler.cs (1)
624? SHA256.HashData(MemoryMarshal.AsBytes(literal.AsSpan()))
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
ILCompiler.ReadyToRun (2)
src\runtime\src\coreclr\tools\Common\Compiler\NativeAotNameMangler.cs (1)
624? SHA256.HashData(MemoryMarshal.AsBytes(literal.AsSpan()))
src\runtime\src\coreclr\tools\Common\JitInterface\CorInfoImpl.cs (1)
3499ReadOnlySpan<bool> bools = MemoryMarshal.CreateReadOnlySpan(ref objRefs, (int)objRefsSize);
ILCompiler.RyuJit (1)
src\runtime\src\coreclr\tools\Common\JitInterface\CorInfoImpl.cs (1)
3499ReadOnlySpan<bool> bools = MemoryMarshal.CreateReadOnlySpan(ref objRefs, (int)objRefsSize);
ILCompiler.TypeSystem (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
illink (1)
ILLink.RoslynAnalyzer (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
Microsoft.AspNetCore.Components.Endpoints (1)
Rendering\EndpointHtmlRenderer.Streaming.cs (1)
133? MemoryMarshal.Cast<byte, ComponentIdAndDepth>(stackalloc byte[bufSizeRequired])
Microsoft.AspNetCore.Components.Server (6)
Circuits\CircuitId.cs (2)
42MemoryMarshal.AsBytes(Secret.AsSpan()), 43MemoryMarshal.AsBytes(other.Secret.AsSpan()));
src\aspnetcore\src\submodules\MessagePack-CSharp\src\MessagePack.UnityClient\Assets\Scripts\MessagePack\BufferWriter.cs (2)
65MemoryMarshal.TryGetArray(memory, out _segment); 220MemoryMarshal.TryGetArray(memory, out _segment);
src\aspnetcore\src\submodules\MessagePack-CSharp\src\MessagePack.UnityClient\Assets\Scripts\MessagePack\SequenceReaderExtensions.cs (2)
40value = Unsafe.ReadUnaligned<T>(ref MemoryMarshal.GetReference(span)); 84value = Unsafe.ReadUnaligned<T>(ref MemoryMarshal.GetReference(tempSpan));
Microsoft.AspNetCore.Http (2)
src\aspnetcore\src\Shared\Dictionary\AdaptiveCapacityDictionary.cs (2)
548ref var r = ref MemoryMarshal.GetArrayDataReference(_arrayStorage); 549return MemoryMarshal.CreateSpan(ref r, _count);
Microsoft.AspNetCore.Http.Extensions (2)
src\aspnetcore\src\Shared\ValueStringBuilder\ValueStringBuilder.cs (2)
65return ref MemoryMarshal.GetReference(_chars); 79return ref MemoryMarshal.GetReference(_chars);
Microsoft.AspNetCore.HttpLogging (2)
src\aspnetcore\src\Shared\ValueStringBuilder\ValueStringBuilder.cs (2)
65return ref MemoryMarshal.GetReference(_chars); 79return ref MemoryMarshal.GetReference(_chars);
Microsoft.AspNetCore.OutputCaching (6)
FormatterBinaryReader.cs (3)
31_root = ref MemoryMarshal.GetReference(content.Span); 143var s = Encoding.UTF8.GetString(MemoryMarshal.CreateReadOnlySpan(ref Unsafe.Add(ref _root, _offset), bytes)); 170var result = MemoryMarshal.CreateReadOnlySpan(ref Unsafe.Add(ref _root, _offset), count);
FormatterBinaryWriter.cs (2)
39return MemoryMarshal.CreateSpan(ref Unsafe.Add(ref root, offset), length - offset); 117root = ref MemoryMarshal.GetReference(span);
RecyclableSequenceBuilder.cs (1)
85return MemoryMarshal.AsMemory(current).Span.Slice(_currentSegmentIndex);
Microsoft.AspNetCore.Razor.Utilities.Shared (11)
Utilities\Checksum.Builder.cs (2)
110_hash.Append(MemoryMarshal.AsBytes(value.AsSpan())); 111_hash.Append(MemoryMarshal.AsBytes("\0".AsSpan()));
Utilities\Checksum.cs (2)
48if (!MemoryMarshal.TryRead(bytes, out Checksum result)) 75Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), this);
Utilities\Hashing\XxHash128.cs (3)
134fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 227ref byte dest0 = ref MemoryMarshal.GetReference(destination); 395fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
Utilities\Hashing\XxHashShared.cs (4)
126ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 144ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 266fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 488fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
Microsoft.AspNetCore.Routing (4)
Matching\ILEmitTrieFactory.cs (4)
546ref var p = ref Unsafe.As<char, byte>(ref MemoryMarshal.GetReference(span)); 700GetReference = typeof(MemoryMarshal).GetMethod( 701nameof(MemoryMarshal.GetReference), 755/// <see cref="MemoryMarshal.GetReference{T}(ReadOnlySpan{T})"/> - GetReference[char]
Microsoft.AspNetCore.Server.Kestrel.Core (20)
Internal\Http\HttpHeaders.cs (7)
381var byteValue = MemoryMarshal.AsBytes(value); 501ulong result = MemoryMarshal.Read<ulong>(value); 515uint result = MemoryMarshal.Read<uint>(value); 526=> (ushort)(MemoryMarshal.Read<ushort>(value) | 0x0020); 568var byteValue = MemoryMarshal.AsBytes(values); 644if (MemoryMarshal.TryRead(byteValue, out ulong result)) 664if (MemoryMarshal.TryRead(byteValue, out uint result))
Internal\Http\HttpHeaders.Generated.cs (1)
7516ref byte nameStart = ref MemoryMarshal.GetReference(name);
Internal\Http\HttpParser.cs (2)
516var startLine = MemoryMarshal.CreateSpan(ref MemoryMarshal.GetReference(requestLine), queryEnd);
Internal\Infrastructure\HttpUtilities.cs (1)
328var c = MemoryMarshal.GetReference(str);
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
180return MemoryMarshal.TryGetArray(_memory, out segment);
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolBlock.cs (1)
20Memory = MemoryMarshal.CreateFromPinnedArray(pinnedArray, 0, pinnedArray.Length);
src\aspnetcore\src\Shared\Buffers.MemoryPool\UnmanagedBufferAllocator.cs (2)
59return (T*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(alloc)); 101return (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\aspnetcore\src\Shared\PathNormalizer\PathNormalizer.cs (3)
59else if (MemoryMarshal.CreateSpan(ref src[nextIndex], 2).StartsWith(dotSlash)) 63var lastIndex = MemoryMarshal.CreateSpan(ref src[0], writtenLength).LastIndexOf(ByteSlash); 93var lastSlashIndex = MemoryMarshal.CreateSpan(ref src[0], writtenLength).LastIndexOf(ByteSlash);
src\aspnetcore\src\Shared\ServerInfrastructure\BufferExtensions.cs (1)
59if (!MemoryMarshal.TryGetArray(memory, out var result))
src\aspnetcore\src\Shared\ServerInfrastructure\StringUtilities.cs (1)
172ref Unsafe.Add(ref MemoryMarshal.GetReference(buffer), i)),
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (5)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
180return MemoryMarshal.TryGetArray(_memory, out segment);
src\aspnetcore\src\Shared\Buffers.MemoryPool\MemoryPoolBlock.cs (1)
20Memory = MemoryMarshal.CreateFromPinnedArray(pinnedArray, 0, pinnedArray.Length);
src\aspnetcore\src\Shared\Buffers.MemoryPool\UnmanagedBufferAllocator.cs (2)
59return (T*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(alloc)); 101return (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\aspnetcore\src\Shared\ServerInfrastructure\StringUtilities.cs (1)
172ref Unsafe.Add(ref MemoryMarshal.GetReference(buffer), i)),
Microsoft.AspNetCore.WebSockets (2)
src\aspnetcore\src\Shared\ValueStringBuilder\ValueStringBuilder.cs (2)
65return ref MemoryMarshal.GetReference(_chars); 79return ref MemoryMarshal.GetReference(_chars);
Microsoft.AspNetCore.WebUtilities (2)
FormPipeReader.cs (2)
398var span = MemoryMarshal.CreateSpan(ref MemoryMarshal.GetReference(readOnlySpan), readOnlySpan.Length);
Microsoft.Build (3)
src\msbuild\artifacts\.packages\microsoft.codeanalysis.collections\5.0.0-1.25277.114\contentFiles\cs\net9.0\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
Microsoft.Build.Framework (4)
Utilities\ProcessExtensions.cs (1)
563int argc = MemoryMarshal.Read<int>(data);
Utilities\ValueStringBuilder.cs (3)
57_chars = MemoryMarshal.Cast<byte, char>((Span<byte>)_arrayToReturnToPool); 422_chars[.._length].CopyTo(MemoryMarshal.Cast<byte, char>((Span<byte>)poolArray)); 425_chars = MemoryMarshal.Cast<byte, char>((Span<byte>)poolArray);
Microsoft.CodeAnalysis (13)
Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
Text\SourceText.cs (2)
653var shortSpan = MemoryMarshal.Cast<char, short>(charSpan); 658hash.Append(MemoryMarshal.AsBytes(charSpan));
Text\SourceTextComparer.cs (1)
38return MemoryMarshal.Read<int>(contentHash.AsSpan());
Microsoft.CodeAnalysis.Analyzers (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Microsoft.CodeAnalysis.AnalyzerUtilities (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Microsoft.CodeAnalysis.CodeStyle (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Microsoft.CodeAnalysis.CSharp (3)
Symbols\Source\SourceNamedTypeSymbol_Extension.cs (3)
1156MemoryMarshal.Cast<char, short>(charSpan).CopyTo(shortSpan); 1159int bytesWritten = XxHash128.Hash(MemoryMarshal.AsBytes(shortSpan), hash); 1164int bytesWritten = XxHash128.Hash(MemoryMarshal.AsBytes(charSpan), hash);
Microsoft.CodeAnalysis.Extensions.Package (3)
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
Microsoft.CodeAnalysis.ResxSourceGenerator (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Microsoft.CodeAnalysis.Workspaces (22)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Workspace\Solution\Checksum.cs (2)
57Contract.ThrowIfFalse(MemoryMarshal.TryRead(checksum, out Checksum result)); 89Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(span), this);
Workspace\Solution\Checksum_Factory.cs (7)
37pooledHash.Object.Append(MemoryMarshal.AsBytes(value.AsSpan())); 38pooledHash.Object.Append(MemoryMarshal.AsBytes("\0".AsSpan())); 55pooledHash.Object.Append(MemoryMarshal.AsBytes(value.AsSpan())); 56pooledHash.Object.Append(MemoryMarshal.AsBytes("\0".AsSpan())); 67XxHash128.Hash(MemoryMarshal.AsBytes(value.AsSpan()), destination); 116XxHash128.Hash(MemoryMarshal.AsBytes(hashes), destination); 148pooledHash.Object.Append(MemoryMarshal.AsBytes(hashSpan));
Microsoft.Data.Analysis (8)
DataFrameBuffer.cs (2)
32get => (MemoryMarshal.Cast<byte, T>(Buffer.Span)).Slice(0, Length); 38get => MemoryMarshal.Cast<byte, T>(Buffer.Span);
DataFrameColumns\ArrowStringDataFrameColumn.cs (1)
261fixed (byte* data = &MemoryMarshal.GetReference(bytes))
PrimitiveColumnContainer.cs (2)
494mapIndicesLongSpan = MemoryMarshal.Cast<U, long>(mapIndicesSpan); 498mapIndicesIntSpan = MemoryMarshal.Cast<U, int>(mapIndicesSpan);
PrimitiveDataFrameColumn.cs (1)
150ReadOnlySpan<DateTime> valueSpan = MemoryMarshal.Cast<T, DateTime>(valueBuffer.ReadOnlySpan);
PrimitiveDataFrameColumn.Sort.cs (1)
66bool isArray = MemoryMarshal.TryGetArray(typedBuffer, out ArraySegment<T> arraySegment);
ReadOnlyDataFrameBuffer.cs (1)
44get => (MemoryMarshal.Cast<byte, T>(ReadOnlyBuffer.Span)).Slice(0, Length);
Microsoft.Diagnostics.DataContractReader.Contracts (4)
Contracts\Object_1.cs (1)
53return new string(MemoryMarshal.Cast<byte, char>(span));
Contracts\StackWalk\Context\ContextHolder.cs (3)
36Span<byte> byteSpan = MemoryMarshal.Cast<T, byte>(structSpan); 48Span<T> structSpan = MemoryMarshal.CreateSpan(ref Context, 1); 49Span<byte> byteSpan = MemoryMarshal.AsBytes(structSpan);
Microsoft.Diagnostics.DataContractReader.Legacy (46)
_generated\26\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSHandleEnum.cs (2)
76global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData>.GetManagedValuesDestination(handles).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData>.GetUnmanagedValuesSource(__handles_native, __handles_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSHandleData>.GetUnmanagedValuesSource(__handles_native, __handles_native__numElements).Length));
_generated\27\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSStackRefErrorEnum.cs (2)
76global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError>.GetManagedValuesDestination(refs).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError>.GetUnmanagedValuesSource(__refs_native, __refs_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefError>.GetUnmanagedValuesSource(__refs_native, __refs_native__numElements).Length));
_generated\28\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSStackRefEnum.cs (2)
78global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData>.GetManagedValuesDestination(refs).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData>.GetUnmanagedValuesSource(__refs_native, __refs_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSStackRefData>.GetUnmanagedValuesSource(__refs_native, __refs_native__numElements).Length));
_generated\29\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum.cs (2)
76global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion>.GetManagedValuesDestination(memRegions).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion>.GetUnmanagedValuesSource(__memRegions_native, __memRegions_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMemoryRegion>.GetUnmanagedValuesSource(__memRegions_native, __memRegions_native__numElements).Length));
_generated\30\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface.cs (16)
325global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __values_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __values_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __values_native__numElements); 378global::System.Span<ulong> __values_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__values_native, __values_native__numElements).GetPinnableReference()), __values_native__numElements); 565global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __values_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __values_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __values_native__numElements); 620global::System.Span<ulong> __values_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__values_native, __values_native__numElements).GetPinnableReference()), __values_native__numElements); 922global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __modules_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __modules_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __modules_native__numElements); 977global::System.Span<ulong> __modules_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__modules_native, __modules_native__numElements).GetPinnableReference()), __modules_native__numElements); 2317global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __heaps_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __heaps_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __heaps_native__numElements); 2370global::System.Span<ulong> __heaps_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__heaps_native, __heaps_native__numElements).GetPinnableReference()), __heaps_native__numElements); 3322global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo>.GetManagedValuesDestination(codeHeaps).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo>.GetUnmanagedValuesSource(__codeHeaps_native, __codeHeaps_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpJitCodeHeapInfo>.GetUnmanagedValuesSource(__codeHeaps_native, __codeHeaps_native__numElements).Length)); 3612global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetManagedValuesDestination(interfaces).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetUnmanagedValuesSource(__interfaces_native, __interfaces_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetUnmanagedValuesSource(__interfaces_native, __interfaces_native__numElements).Length)); 3707global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetManagedValuesDestination(interfaces).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetUnmanagedValuesSource(__interfaces_native, __interfaces_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpCOMInterfacePointerData>.GetUnmanagedValuesSource(__interfaces_native, __interfaces_native__numElements).Length)); 3984global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __values_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __values_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __values_native__numElements); 4039global::System.Span<ulong> __values_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__values_native, __values_native__numElements).GetPinnableReference()), __values_native__numElements);
_generated\33\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface4.cs (2)
77global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __arguments_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __arguments_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __arguments_native__numElements); 130global::System.Span<ulong> __arguments_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__arguments_native, __arguments_native__numElements).GetPinnableReference()), __arguments_native__numElements);
_generated\34\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface5.cs (2)
78global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData>.GetManagedValuesDestination(nativeCodeAddrs).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData>.GetUnmanagedValuesSource(__nativeCodeAddrs_native, __nativeCodeAddrs_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData, global::Microsoft.Diagnostics.DataContractReader.Legacy.DacpTieredVersionData>.GetUnmanagedValuesSource(__nativeCodeAddrs_native, __nativeCodeAddrs_native__numElements).Length));
_generated\39\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface10.cs (2)
87global::System.Span<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress> __mowList_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __mowList_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __mowList_native__numElements); 142global::System.Span<ulong> __mowList_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress, ulong>.GetUnmanagedValuesSource(__mowList_native, __mowList_native__numElements).GetPinnableReference()), __mowList_native__numElements);
_generated\44\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMethodEnum.cs (2)
76global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData>.GetManagedValuesDestination(values).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData>.GetUnmanagedValuesSource(__values_native, __values_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData, global::Microsoft.Diagnostics.DataContractReader.Legacy.SOSMethodData>.GetUnmanagedValuesSource(__values_native, __values_native__numElements).Length));
_generated\49\Microsoft.Diagnostics.DataContractReader.Legacy.IXCLRDataProcess.cs (4)
1857global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetManagedValuesDestination(flags).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetUnmanagedValuesSource(__flags_native, __flags_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetUnmanagedValuesSource(__flags_native, __flags_native__numElements).Length)); 1993global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetManagedValuesDestination(flags).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetUnmanagedValuesSource(__flags_native, __flags_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<uint, uint>.GetUnmanagedValuesSource(__flags_native, __flags_native__numElements).Length));
_generated\51\Microsoft.Diagnostics.DataContractReader.Legacy.IXCLRDataStackWalk.cs (2)
87global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(contextBuf).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__contextBuf_native, __contextBuf_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__contextBuf_native, __contextBuf_native__numElements).Length));
_generated\52\Microsoft.Diagnostics.DataContractReader.Legacy.IXCLRDataFrame.cs (2)
132global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(contextBuf).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__contextBuf_native, __contextBuf_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__contextBuf_native, __contextBuf_native__numElements).Length));
_generated\55\Microsoft.Diagnostics.DataContractReader.Legacy.IXCLRDataMethodInstance.cs (2)
629global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap>.GetManagedValuesDestination(maps).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap>.GetUnmanagedValuesSource(__maps_native, __maps_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataILAddressMap>.GetUnmanagedValuesSource(__maps_native, __maps_native__numElements).Length));
Dbi\DacDbiImpl.cs (4)
4719Span<byte> destBytes = MemoryMarshal.AsBytes(MemoryMarshal.CreateSpan(ref dest, 1)); 4728MemoryMarshal.AsBytes(MemoryMarshal.CreateSpan(ref value, 1)).Reverse();
Microsoft.DiaSymReader (115)
_generated\10\Microsoft.DiaSymReader.ISymUnmanagedAsyncMethod.cs (6)
323global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(breakpointMethod).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__breakpointMethod_native, __breakpointMethod_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__breakpointMethod_native, __breakpointMethod_native__numElements).Length)); 324global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(breakpointOffset).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__breakpointOffset_native, __breakpointOffset_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__breakpointOffset_native, __breakpointOffset_native__numElements).Length)); 325global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(yieldOffsets).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__yieldOffsets_native, __yieldOffsets_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__yieldOffsets_native, __yieldOffsets_native__numElements).Length));
_generated\15\Microsoft.DiaSymReader.ISymUnmanagedConstant.cs (4)
81global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length)); 193global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(signature).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__signature_native, __signature_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__signature_native, __signature_native__numElements).Length));
_generated\17\Microsoft.DiaSymReader.ISymUnmanagedDocument.cs (6)
95global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(url).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__url_native, __url_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__url_native, __url_native__numElements).Length)); 324global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(checksum).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__checksum_native, __checksum_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__checksum_native, __checksum_native__numElements).Length)); 510global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(source).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__source_native, __source_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__source_native, __source_native__numElements).Length));
_generated\18\Microsoft.DiaSymReader.ISymUnmanagedEncUpdate.cs (2)
193global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 259global::System.Span<global::System.IntPtr> __variables_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__variables_native, __variables_native__numElements).GetPinnableReference()), __variables_native__numElements);
_generated\19\Microsoft.DiaSymReader.ISymUnmanagedMethod.cs (22)
373global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(ranges).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__ranges_native, __ranges_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__ranges_native, __ranges_native__numElements).Length)); 430global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __parameters_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __parameters_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __parameters_native__numElements); 495global::System.Span<global::System.IntPtr> __parameters_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__parameters_native, __parameters_native__numElements).GetPinnableReference()), __parameters_native__numElements); 625global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 701global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(columns).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__columns_native, __columns_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__columns_native, __columns_native__numElements).Length)); 702global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(lines).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__lines_native, __lines_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__lines_native, __lines_native__numElements).Length)); 705global::System.Span<global::System.IntPtr> __documents_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedDocument, global::System.IntPtr>.GetUnmanagedValuesSource(__documents_native, __documents_native__numElements).GetPinnableReference()), __documents_native__numElements); 776global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 869global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(endColumns).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__endColumns_native, __endColumns_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__endColumns_native, __endColumns_native__numElements).Length)); 870global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(endLines).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__endLines_native, __endLines_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__endLines_native, __endLines_native__numElements).Length)); 871global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(startColumns).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__startColumns_native, __startColumns_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__startColumns_native, __startColumns_native__numElements).Length)); 872global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(startLines).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__startLines_native, __startLines_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__startLines_native, __startLines_native__numElements).Length)); 875global::System.Span<global::System.IntPtr> __documents_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedDocument, global::System.IntPtr>.GetUnmanagedValuesSource(__documents_native, __documents_native__numElements).GetPinnableReference()), __documents_native__numElements); 887global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetManagedValuesDestination(offsets).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__offsets_native, __offsets_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<int, int>.GetUnmanagedValuesSource(__offsets_native, __offsets_native__numElements).Length));
_generated\20\Microsoft.DiaSymReader.ISymUnmanagedMethod2.cs (3)
316global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __parameters_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __parameters_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __parameters_native__numElements); 435global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 520global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements);
_generated\21\Microsoft.DiaSymReader.ISymUnmanagedNamespace.cs (6)
81global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length)); 138global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 203global::System.Span<global::System.IntPtr> __namespaces_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace, global::System.IntPtr>.GetUnmanagedValuesSource(__namespaces_native, __namespaces_native__numElements).GetPinnableReference()), __namespaces_native__numElements); 271global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 336global::System.Span<global::System.IntPtr> __variables_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__variables_native, __variables_native__numElements).GetPinnableReference()), __variables_native__numElements);
_generated\22\Microsoft.DiaSymReader.ISymUnmanagedReader.cs (14)
176global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 241global::System.Span<global::System.IntPtr> __documents_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedDocument, global::System.IntPtr>.GetUnmanagedValuesSource(__documents_native, __documents_native__numElements).GetPinnableReference()), __documents_native__numElements); 471global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 536global::System.Span<global::System.IntPtr> __variables_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__variables_native, __variables_native__numElements).GetPinnableReference()), __variables_native__numElements); 604global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 669global::System.Span<global::System.IntPtr> __variables_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__variables_native, __variables_native__numElements).GetPinnableReference()), __variables_native__numElements); 803global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(customDebugInformation).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements).Length)); 860global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 925global::System.Span<global::System.IntPtr> __namespaces_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace, global::System.IntPtr>.GetUnmanagedValuesSource(__namespaces_native, __namespaces_native__numElements).GetPinnableReference()), __namespaces_native__numElements); 1162global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length)); 1221global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements); 1289global::System.Span<global::System.IntPtr> __methods_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedMethod, global::System.IntPtr>.GetUnmanagedValuesSource(__methods_native, __methods_native__numElements).GetPinnableReference()), __methods_native__numElements);
_generated\23\Microsoft.DiaSymReader.ISymUnmanagedReader2.cs (9)
160global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(customDebugInformation).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements).Length)); 219global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements); 287global::System.Span<global::System.IntPtr> __methods_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedMethod, global::System.IntPtr>.GetUnmanagedValuesSource(__methods_native, __methods_native__numElements).GetPinnableReference()), __methods_native__numElements); 393global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 566global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 646global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 791global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 995global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements);
_generated\24\Microsoft.DiaSymReader.ISymUnmanagedReader3.cs (10)
102global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(customDebugInformation).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements).Length)); 158global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(customDebugInformation).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__customDebugInformation_native, __customDebugInformation_native__numElements).Length)); 253global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 426global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 506global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 651global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 855global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements); 1067global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements);
_generated\25\Microsoft.DiaSymReader.ISymUnmanagedReader4.cs (6)
288global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 461global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 541global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 686global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 890global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements); 1102global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements);
_generated\26\Microsoft.DiaSymReader.ISymUnmanagedReader5.cs (6)
193global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 366global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 446global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __variables_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __variables_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __variables_native__numElements); 591global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 795global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements); 1007global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedMethod> __methods_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __methods_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __methods_native__numElements);
_generated\27\Microsoft.DiaSymReader.ISymUnmanagedCompilerInfoReader.cs (2)
93global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length));
_generated\28\Microsoft.DiaSymReader.ISymUnmanagedScope.cs (6)
213global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedScope> __children_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __children_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __children_native__numElements); 278global::System.Span<global::System.IntPtr> __children_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedScope, global::System.IntPtr>.GetUnmanagedValuesSource(__children_native, __children_native__numElements).GetPinnableReference()), __children_native__numElements); 478global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __locals_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __locals_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __locals_native__numElements); 543global::System.Span<global::System.IntPtr> __locals_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedVariable, global::System.IntPtr>.GetUnmanagedValuesSource(__locals_native, __locals_native__numElements).GetPinnableReference()), __locals_native__numElements); 611global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements); 676global::System.Span<global::System.IntPtr> __namespaces_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace, global::System.IntPtr>.GetUnmanagedValuesSource(__namespaces_native, __namespaces_native__numElements).GetPinnableReference()), __namespaces_native__numElements);
_generated\29\Microsoft.DiaSymReader.ISymUnmanagedScope2.cs (5)
135global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedConstant> __constants_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __constants_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __constants_native__numElements); 200global::System.Span<global::System.IntPtr> __constants_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedConstant, global::System.IntPtr>.GetUnmanagedValuesSource(__constants_native, __constants_native__numElements).GetPinnableReference()), __constants_native__numElements); 340global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedScope> __children_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __children_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __children_native__numElements); 483global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedVariable> __locals_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __locals_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __locals_native__numElements); 563global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedNamespace> __namespaces_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __namespaces_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __namespaces_native__numElements);
_generated\31\Microsoft.DiaSymReader.ISymUnmanagedVariable.cs (4)
93global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length)); 190global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetManagedValuesDestination(signature).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__signature_native, __signature_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<byte, byte>.GetUnmanagedValuesSource(__signature_native, __signature_native__numElements).Length));
_generated\9\Microsoft.DiaSymReader.ISymEncUnmanagedMethod.cs (4)
85global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetManagedValuesDestination(name).CopyTo(global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.InteropServices.MemoryMarshal.GetReference(global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements)), global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<char, char>.GetUnmanagedValuesSource(__name_native, __name_native__numElements).Length)); 250global::System.Span<global::Microsoft.DiaSymReader.ISymUnmanagedDocument> __documents_native__managedSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in __documents_native__marshaller.GetManagedValuesSource().GetPinnableReference()), __documents_native__numElements); 315global::System.Span<global::System.IntPtr> __documents_native__nativeSpan = global::System.Runtime.InteropServices.MemoryMarshal.CreateSpan(ref global::System.Runtime.CompilerServices.Unsafe.AsRef(in global::System.Runtime.InteropServices.Marshalling.ArrayMarshaller<global::Microsoft.DiaSymReader.ISymUnmanagedDocument, global::System.IntPtr>.GetUnmanagedValuesSource(__documents_native, __documents_native__numElements).GetPinnableReference()), __documents_native__numElements);
Microsoft.Extensions.AI.Abstractions (3)
SpeechToText\SpeechToTextClientExtensions.cs (2)
50var audioSpeechStream = MemoryMarshal.TryGetArray(audioSpeechContent.Data, out var array) ? 72var audioSpeechStream = MemoryMarshal.TryGetArray(audioSpeechContent.Data, out var array) ?
src\LegacySupport\FilePolyfills\FilePolyfills.cs (1)
61if (MemoryMarshal.TryGetArray(bytes, out ArraySegment<byte> segment) &&
Microsoft.Extensions.AI.Abstractions.Tests (1)
Embeddings\EmbeddingTests.cs (1)
35Assert.True(MemoryMarshal.TryGetArray(e.Vector, out ArraySegment<float> array));
Microsoft.Extensions.AI.OpenAI (1)
OpenAIImageGenerator.cs (1)
66imageStream = MemoryMarshal.TryGetArray(dataContent.Data, out var array) ?
Microsoft.Extensions.Caching.Hybrid (1)
Internal\InbuiltTypeSerializer.cs (1)
36if (source.IsSingleSegment && MemoryMarshal.TryGetArray(source.First, out ArraySegment<byte> segment))
Microsoft.Extensions.Caching.Hybrid.Tests (4)
DistributedCacheTests.cs (4)
324Assert.True(MemoryMarshal.TryGetArray(payload.First, out _)); 331Assert.False(MemoryMarshal.TryGetArray(payload.First, out _)); 335Assert.True(MemoryMarshal.TryGetArray(payload.First, out var segment)); 343Assert.True(MemoryMarshal.TryGetArray(payload.First, out segment));
Microsoft.Extensions.DataIngestion (3)
Chunkers\DocumentTokenChunker.cs (2)
71fixed (char* ptr = &MemoryMarshal.GetReference(contentToProcess.Span)) 113fixed (char* ptr = &MemoryMarshal.GetReference(overlapContent))
Chunkers\ValueStringBuilder.cs (1)
79return ref MemoryMarshal.GetReference(_chars);
Microsoft.Extensions.Diagnostics.ResourceMonitoring (1)
Linux\OSFileSystem.cs (1)
106if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> arraySegment) && arraySegment.Array != null)
Microsoft.Extensions.FileProviders.Physical (2)
PollingWildCardChangeToken.cs (2)
178sha256.AppendData(MemoryMarshal.AsBytes(path.AsSpan())); 179sha256.AppendData(MemoryMarshal.AsBytes([lastChangedUtc]));
Microsoft.Extensions.Identity.Core (1)
UserManager.cs (1)
2540RandomNumberGenerator.Fill(MemoryMarshal.AsBytes(resultBuffer));
Microsoft.Extensions.Logging.Abstractions (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
Microsoft.Extensions.ServiceDiscovery.Dns (1)
Resolver\DnsResolver.cs (1)
311var gotArray = MemoryMarshal.TryGetArray(record.Data, out ArraySegment<byte> segment);
Microsoft.ML.Core (2)
Data\ReadOnlyMemoryUtils.cs (1)
250fixed (char* valueChars = &MemoryMarshal.GetReference(span))
Utilities\Stream.cs (1)
717rentedArray.AsSpan(0, numElementsToReadThisChunk * sizeof(T)).CopyTo(MemoryMarshal.AsBytes(destination.Slice(0, numElementsToReadThisChunk)));
Microsoft.ML.CpuMath (84)
AvxIntrinsics.cs (42)
422fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 465fixed (float* pd = &MemoryMarshal.GetReference(dst)) 572fixed (float* psrc = &MemoryMarshal.GetReference(src)) 573fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 619fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 667fixed (float* psrc = &MemoryMarshal.GetReference(src)) 668fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 722fixed (float* psrc = &MemoryMarshal.GetReference(src)) 723fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 724fixed (float* pres = &MemoryMarshal.GetReference(result)) 779fixed (float* psrc = &MemoryMarshal.GetReference(src)) 780fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 781fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 829fixed (float* psrc = &MemoryMarshal.GetReference(src)) 830fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 879fixed (float* psrc = &MemoryMarshal.GetReference(src)) 880fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 881fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 927fixed (float* psrc1 = &MemoryMarshal.GetReference(src1)) 928fixed (float* psrc2 = &MemoryMarshal.GetReference(src2)) 929fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 976fixed (float* pSrc = &MemoryMarshal.GetReference(src)) 1064fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1108fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1156fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1200fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1249fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1293fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1344fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1345fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1399fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1400fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1401fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 1455fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1456fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1507fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1508fixed (float* pdst1 = &MemoryMarshal.GetReference(v)) 1509fixed (float* pdst2 = &MemoryMarshal.GetReference(w)) 1567fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1568fixed (int* pidx = &MemoryMarshal.GetReference(indices)) 1569fixed (float* pdst1 = &MemoryMarshal.GetReference(v)) 1570fixed (float* pdst2 = &MemoryMarshal.GetReference(w))
SseIntrinsics.cs (42)
357fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 389fixed (float* pd = &MemoryMarshal.GetReference(dst)) 491fixed (float* psrc = &MemoryMarshal.GetReference(src)) 492fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 526fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 561fixed (float* psrc = &MemoryMarshal.GetReference(src)) 562fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 603fixed (float* psrc = &MemoryMarshal.GetReference(src)) 604fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 605fixed (float* pres = &MemoryMarshal.GetReference(result)) 647fixed (float* psrc = &MemoryMarshal.GetReference(src)) 648fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 649fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 685fixed (float* psrc = &MemoryMarshal.GetReference(src)) 686fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 723fixed (float* psrc = &MemoryMarshal.GetReference(src)) 724fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 725fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 759fixed (float* psrc1 = &MemoryMarshal.GetReference(src1)) 760fixed (float* psrc2 = &MemoryMarshal.GetReference(src2)) 761fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 796fixed (float* pSrc = &MemoryMarshal.GetReference(src)) 881fixed (float* psrc = &MemoryMarshal.GetReference(src)) 912fixed (float* psrc = &MemoryMarshal.GetReference(src)) 946fixed (float* psrc = &MemoryMarshal.GetReference(src)) 977fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1011fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1042fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1078fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1079fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1120fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1121fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1122fixed (int* pidx = &MemoryMarshal.GetReference(idx)) 1163fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1164fixed (float* pdst = &MemoryMarshal.GetReference(dst)) 1201fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1202fixed (float* pdst1 = &MemoryMarshal.GetReference(v)) 1203fixed (float* pdst2 = &MemoryMarshal.GetReference(w)) 1246fixed (float* psrc = &MemoryMarshal.GetReference(src)) 1247fixed (int* pidx = &MemoryMarshal.GetReference(indices)) 1248fixed (float* pdst1 = &MemoryMarshal.GetReference(v)) 1249fixed (float* pdst2 = &MemoryMarshal.GetReference(w))
Microsoft.ML.Data (12)
DataLoadSave\Binary\UnsafeTypeOps.cs (12)
57fixed (sbyte* pArray = &MemoryMarshal.GetReference(array)) 69fixed (Byte* pArray = &MemoryMarshal.GetReference(array)) 81fixed (short* pArray = &MemoryMarshal.GetReference(array)) 93fixed (UInt16* pArray = &MemoryMarshal.GetReference(array)) 105fixed (int* pArray = &MemoryMarshal.GetReference(array)) 117fixed (UInt32* pArray = &MemoryMarshal.GetReference(array)) 129fixed (long* pArray = &MemoryMarshal.GetReference(array)) 141fixed (UInt64* pArray = &MemoryMarshal.GetReference(array)) 153fixed (Single* pArray = &MemoryMarshal.GetReference(array)) 165fixed (Double* pArray = &MemoryMarshal.GetReference(array)) 177fixed (TimeSpan* pArray = &MemoryMarshal.GetReference(array)) 194fixed (DataViewRowId* pArray = &MemoryMarshal.GetReference(array))
Microsoft.ML.FastTree (24)
Utils\ToByteArrayExtensions.cs (24)
55MemoryMarshal.Write(buffer.AsSpan(position), ref a); 77MemoryMarshal.Write(buffer.AsSpan(position), ref a); 99MemoryMarshal.Write(buffer.AsSpan(position), ref a); 121MemoryMarshal.Write(buffer.AsSpan(position), ref a); 143MemoryMarshal.Write(buffer.AsSpan(position), ref a); 165MemoryMarshal.Write(buffer.AsSpan(position), ref a); 187MemoryMarshal.Write(buffer.AsSpan(position), ref a); 209MemoryMarshal.Write(buffer.AsSpan(position), ref a); 293MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 304buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 326MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 337buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 359MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 375buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 397MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 408buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 430MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 441buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 463MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 474buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 496MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 507buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan())); 529MemoryMarshal.AsBytes(a.AsSpan()).CopyTo(buffer.AsSpan(position)); 540buffer.AsSpan(position, byteLength).CopyTo(MemoryMarshal.AsBytes(a.AsSpan()));
Microsoft.ML.ImageAnalytics (2)
ImagePixelExtractor.cs (2)
357Span<float> vf = typeof(TValue) == typeof(float) ? MemoryMarshal.Cast<TValue, float>(editor.Values) : default; 358Span<byte> vb = typeof(TValue) == typeof(byte) ? MemoryMarshal.Cast<TValue, byte>(editor.Values) : default;
Microsoft.ML.Tokenizers (3)
Model\SentencePieceUnigramModel.cs (1)
295Span<byte> byteSpan = MemoryMarshal.AsBytes(buffer.AsSpan());
Utils\ValueStringBuilder.cs (2)
66return ref MemoryMarshal.GetReference(_chars); 80return ref MemoryMarshal.GetReference(_chars);
Microsoft.ML.Vision (2)
ImageClassificationTrainer.cs (2)
878var labelsSpan = MemoryMarshal.Cast<long, byte>(labels); 890var featureSpan = MemoryMarshal.Cast<float, byte>(row.Item2);
Microsoft.NET.HostModel (3)
MachO\BinaryFormat\Blobs\CodeDirectoryBlob.cs (1)
32var cdHeader = MemoryMarshal.Read<CodeDirectoryHeader>(data);
MachO\FileUtils\StreamExtensions.cs (2)
53result = MemoryMarshal.Read<T>(buffer); 60MemoryMarshal.Write(buffer, ref value);
Microsoft.Private.Windows.Core (15)
_generated\12\Windows.Win32.byte.InlineArrays.g.cs (2)
43 internal unsafe Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<byte> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
_generated\37\Windows.Win32.char.InlineArrays.g.cs (4)
44 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 53 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 108 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 117 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
System\BufferScope.cs (1)
109public readonly ref T GetPinnableReference() => ref MemoryMarshal.GetReference(_span);
System\SpanReader.cs (3)
144value = Unsafe.ReadUnaligned<TValue>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(_unread))); 157/// This effectively does a <see cref="MemoryMarshal.Cast{TFrom, TTo}(ReadOnlySpan{TFrom})"/> and the same 180value = MemoryMarshal.Cast<T, TValue>(current);
System\Text\ValueStringBuilder.cs (2)
78public readonly ref char GetPinnableReference() => ref MemoryMarshal.GetReference(_chars); 92return ref MemoryMarshal.GetReference(_chars);
Windows\Win32\Foundation\GlobalBuffer.cs (1)
50public readonly Span<char> AsCharSpan() => MemoryMarshal.Cast<byte, char>(_buffer);
Windows\Win32\Graphics\Gdi\ARGB.cs (1)
57ToColorArray(MemoryMarshal.Cast<uint, ARGB>(argbColors));
Windows\Win32\System\Com\IID.cs (1)
18return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft.Win32.Registry (3)
Microsoft\Win32\RegistryKey.cs (3)
777ref MemoryMarshal.GetReference(nameSpan), 1019fixed (byte* lpData = &MemoryMarshal.GetReference(span)) 1125ReadOnlySpan<char> chars = MemoryMarshal.Cast<byte, char>(span.Slice(0, dataLength));
mscorlib (1)
mscorlib.cs (1)
102[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.MemoryMarshal))]
netstandard (1)
netstandard.cs (1)
1716[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.MemoryMarshal))]
NuGet.Packaging (1)
ContentModel\PatternTable.cs (1)
58Debug.Assert(MemoryMarshal.TryGetString(name, out _, out _, out _));
PresentationCore (5)
System\Windows\Media\Imaging\BitmapSource.cs (1)
670fixed (byte* pixelArray = &Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(pixels), (nint)offset * elementSize))
System\Windows\Media\Imaging\CachedBitmap.cs (1)
134fixed (byte* pixelArray = &MemoryMarshal.GetArrayDataReference(pixels))
System\Windows\Media\Imaging\PropVariant.cs (1)
141fixed (byte* sourcePtr = &MemoryMarshal.GetArrayDataReference(array))
System\Windows\Media\Imaging\WriteableBitmap.cs (2)
398fixed (byte* buffer = &MemoryMarshal.GetArrayDataReference(sourceBuffer)) 522fixed (byte* buffer = &MemoryMarshal.GetArrayDataReference(pixels))
PresentationFramework (1)
MS\Internal\WindowsRuntime\Generated\WinRT\Marshalers.cs (1)
321fixed (void* array_data = &MemoryMarshal.GetArrayDataReference(array))
Roslyn.Diagnostics.Analyzers (13)
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHash128.cs (3)
136fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 229ref byte dest0 = ref MemoryMarshal.GetReference(destination); 397fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Compilers\Core\Portable\Hashing\XxHashShared.cs (4)
127ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 145ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 267fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 489fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
src\roslyn\src\Dependencies\Collections\Segmented\SegmentedArray.cs (3)
69if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 164if (!MemoryMarshal.TryGetArray<T>(memory, out var segment)) 231if (!MemoryMarshal.TryGetArray<T>(memory, out var segment))
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\Base64Utilities.cs (3)
196ref char srcChars = ref MemoryMarshal.GetReference(utf16); 197ref byte destBytes = ref MemoryMarshal.GetReference(bytes); 208ref sbyte decodingMap = ref MemoryMarshal.GetReference(DecodingMap);
Shared (1)
ServerSentEvents\Helpers.cs (1)
88if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> segment))
System.Collections.Immutable (2)
System\Collections\Frozen\String\Hashing.cs (2)
27fixed (char* src = &MemoryMarshal.GetReference(s)) 90fixed (char* src = &MemoryMarshal.GetReference(s))
System.Console (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.Diagnostics.DiagnosticSource (8)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Diagnostics\Activity.cs (1)
2050_hexString = Convert.ToHexStringLower(MemoryMarshal.AsBytes(span));
System\Diagnostics\Metrics\ObjectSequence.netcore.cs (3)
18return MemoryMarshal.CreateSpan(ref Value1, 1); 26return MemoryMarshal.CreateSpan(ref Value1, 2); 36return MemoryMarshal.CreateSpan(ref Value1, 3);
System\Diagnostics\Metrics\StringSequence.netcore.cs (3)
19return MemoryMarshal.CreateSpan(ref Value1, 1); 27return MemoryMarshal.CreateSpan(ref Value1, 2); 37return MemoryMarshal.CreateSpan(ref Value1, 3);
System.Diagnostics.PerformanceCounter (17)
src\runtime\src\libraries\Common\src\Interop\Windows\Advapi32\Interop.PERF_INFO.cs (1)
111: MemoryMarshal.Cast<byte, char>(data.Slice(instance.NameOffset, instance.NameLength - sizeof(char))); // NameLength includes the null-terminator
src\runtime\src\libraries\Common\src\Interop\Windows\Kernel32\Interop.GetComputerName.cs (1)
23fixed (char* lpBuffer = &MemoryMarshal.GetReference(buffer))
System\Diagnostics\PerformanceCounterLib.cs (15)
135ref readonly PERF_DATA_BLOCK dataBlock = ref MemoryMarshal.AsRef<PERF_DATA_BLOCK>(data); 150ref readonly PERF_OBJECT_TYPE perfObject = ref MemoryMarshal.AsRef<PERF_OBJECT_TYPE>(dataSpan); 164ref readonly PERF_COUNTER_DEFINITION perfCounter = ref MemoryMarshal.AsRef<PERF_COUNTER_DEFINITION>(dataSpan); 1393ref readonly PERF_DATA_BLOCK dataBlock = ref MemoryMarshal.AsRef<PERF_DATA_BLOCK>(data); 1415ref readonly PERF_OBJECT_TYPE perfObjectType = ref MemoryMarshal.AsRef<PERF_OBJECT_TYPE>(dataSpan); 1431ref readonly PERF_OBJECT_TYPE perfObject = ref MemoryMarshal.AsRef<PERF_OBJECT_TYPE>(dataSpan); 1452ref readonly PERF_COUNTER_DEFINITION perfCounter = ref MemoryMarshal.AsRef<PERF_COUNTER_DEFINITION>(dataSpan); 1492ref readonly PERF_INSTANCE_DEFINITION perfInstance = ref MemoryMarshal.AsRef<PERF_INSTANCE_DEFINITION>(dataSpan); 1526ref readonly PERF_COUNTER_BLOCK perfCounterBlock = ref MemoryMarshal.AsRef<PERF_COUNTER_BLOCK>(dataSpan); 1540ref readonly PERF_DATA_BLOCK dataBlock = ref MemoryMarshal.AsRef<PERF_DATA_BLOCK>(data); 1551ref readonly PERF_OBJECT_TYPE type = ref MemoryMarshal.AsRef<PERF_OBJECT_TYPE>(dataSpan); 1567ref readonly PERF_OBJECT_TYPE perfObject = ref MemoryMarshal.AsRef<PERF_OBJECT_TYPE>(dataSpan); 1581ref readonly PERF_COUNTER_DEFINITION perfCounterDefinition = ref MemoryMarshal.AsRef<PERF_COUNTER_DEFINITION>(dataSpan); 1591ref readonly PERF_INSTANCE_DEFINITION perfInstance = ref MemoryMarshal.AsRef<PERF_INSTANCE_DEFINITION>(dataSpan); 1598ref readonly PERF_COUNTER_BLOCK perfCounterBlock = ref MemoryMarshal.AsRef<PERF_COUNTER_BLOCK>(dataSpan);
System.Diagnostics.Process (3)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.ReadLink.cs (1)
43int resultLength = ReadLink(path, ref MemoryMarshal.GetReference(spanBuffer), spanBuffer.Length);
src\runtime\src\libraries\Common\src\System\Runtime\InteropServices\SpanOfCharAsUtf8StringMarshaller.cs (1)
53_unmanagedValue = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.DirectoryServices.Protocols (1)
System\DirectoryServices\Protocols\Interop\LdapPal.Linux.cs (1)
131bv_len = new CLong(MemoryMarshal.CreateReadOnlySpanFromNullTerminated((byte*)passwordPtr).Length),
System.Drawing.Common (3)
_generated\3\Windows.Win32.byte.InlineArrays.g.cs (2)
43 internal unsafe Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<byte> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
System\Drawing\Interop\LOGFONT.cs (1)
38public Span<char> lfFaceName => MemoryMarshal.CreateSpan(ref _lfFaceName[0], (int)PInvokeCore.LF_FACESIZE);
System.Formats.Cbor (1)
System\Formats\Cbor\Writer\CborWriter.cs (1)
156fixed (byte* ptr = &MemoryMarshal.GetReference(encodedValue))
System.Formats.Nrbf (5)
System\Formats\Nrbf\ArraySinglePrimitiveRecord.cs (5)
136Span<byte> resultAsBytes = MemoryMarshal.AsBytes<T>(valuesToRead.Slice(0, sliceSize)); 164Span<short> span = MemoryMarshal.Cast<T, short>(result.AsSpan()); 176Span<int> span = MemoryMarshal.Cast<T, int>(result.AsSpan()); 188Span<long> span = MemoryMarshal.Cast<T, long>(result.AsSpan()); 204Span<byte> resultAsBytes = MemoryMarshal.AsBytes<T>(result.AsSpan());
System.Formats.Tar (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.IO.Compression (22)
System\IO\Compression\Crc32Helper.ZLib.cs (1)
23fixed (byte* bufferPtr = &MemoryMarshal.GetReference(buffer))
System\IO\Compression\DeflateDecoder.cs (2)
76fixed (byte* inputPtr = &MemoryMarshal.GetReference(source)) 77fixed (byte* outputPtr = &MemoryMarshal.GetReference(destination))
System\IO\Compression\DeflateEncoder.cs (3)
216fixed (byte* inputPtr = &MemoryMarshal.GetReference(source)) 217fixed (byte* outputPtr = &MemoryMarshal.GetReference(destination)) 273fixed (byte* outputPtr = &MemoryMarshal.GetReference(destination))
System\IO\Compression\DeflateZLib\DeflateStream.cs (1)
584fixed (byte* bufferPtr = &MemoryMarshal.GetReference(buffer))
System\IO\Compression\DeflateZLib\Inflater.cs (1)
75fixed (byte* bufPtr = &MemoryMarshal.GetReference(destination))
System\IO\Compression\Zstandard\ZstandardDecoder.cs (7)
148fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 149fixed (byte* destPtr = &MemoryMarshal.GetReference(destination)) 217fixed (byte* dataPtr = &MemoryMarshal.GetReference(data)) 252fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 253fixed (byte* destPtr = &MemoryMarshal.GetReference(destination)) 297fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 298fixed (byte* destPtr = &MemoryMarshal.GetReference(destination))
System\IO\Compression\Zstandard\ZstandardDictionary.cs (3)
108Span<nuint> lengthsAsNuint = MemoryMarshal.Cast<byte, nuint>(lengthsArray.AsSpan(0, sampleLengths.Length * Unsafe.SizeOf<nuint>())); 136fixed (byte* samplesPtr = &MemoryMarshal.GetReference(samples)) 138fixed (nuint* lengthsAsNuintPtr = &MemoryMarshal.GetReference(lengthsAsNuint))
System\IO\Compression\Zstandard\ZstandardEncoder.cs (4)
240fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 241fixed (byte* outBytes = &MemoryMarshal.GetReference(destination)) 373fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 374fixed (byte* outBytes = &MemoryMarshal.GetReference(destination))
System.IO.Compression.Brotli (8)
System\IO\Compression\dec\BrotliDecoder.cs (4)
73fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 74fixed (byte* outBytes = &MemoryMarshal.GetReference(destination)) 116fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 117fixed (byte* outBytes = &MemoryMarshal.GetReference(destination))
System\IO\Compression\enc\BrotliEncoder.cs (4)
158fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 159fixed (byte* outBytes = &MemoryMarshal.GetReference(destination)) 214fixed (byte* inBytes = &MemoryMarshal.GetReference(source)) 215fixed (byte* outBytes = &MemoryMarshal.GetReference(destination))
System.IO.FileSystem.AccessControl (2)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\PathHelper.Windows.cs (1)
78while ((result = Interop.Kernel32.GetFullPathNameW(ref MemoryMarshal.GetReference(path), (uint)builder.Capacity, ref builder.GetPinnableReference(), IntPtr.Zero)) > builder.Capacity)
System.IO.FileSystem.Watcher (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.IO.Hashing (17)
System\IO\Hashing\Adler32.cs (5)
251ref byte sourceRef = ref MemoryMarshal.GetReference(source); 354ref byte sourceRef = ref MemoryMarshal.GetReference(source); 413ref byte sourceRef = ref MemoryMarshal.GetReference(source); 459return UpdateVector256((s2 << 16) | s1, MemoryMarshal.CreateReadOnlySpan(ref sourceRef, length)); 474foreach (byte b in MemoryMarshal.CreateReadOnlySpan(ref sourceRef, length))
System\IO\Hashing\Crc32ParameterSet.WellKnown.cs (2)
199ReadOnlySpan<ulong> ulongData = MemoryMarshal.Cast<byte, ulong>(source); 211ReadOnlySpan<uint> uintData = MemoryMarshal.Cast<byte, uint>(source);
System\IO\Hashing\XxHash128.cs (3)
132fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 225ref byte dest0 = ref MemoryMarshal.GetReference(destination); 393fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
System\IO\Hashing\XxHash3.cs (3)
112Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), hash); 130fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 360fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
System\IO\Hashing\XxHashShared.cs (4)
122ReadOnlySpan<ulong> defaultSecretUInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret); 140ReadOnlySpan<ulong> defaultSecret3UInt64 = MemoryMarshal.Cast<byte, ulong>(DefaultSecret.Slice(3)); 258fixed (byte* sourcePtr = &MemoryMarshal.GetReference(source)) 480fixed (byte* defaultSecret = &MemoryMarshal.GetReference(DefaultSecret))
System.Memory (8)
src\runtime\artifacts\obj\System.Memory\Release\net11.0\System.Memory.Forwards.cs (1)
17[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.MemoryMarshal))]
System\Buffers\ReadOnlySequence.cs (3)
146if (MemoryMarshal.TryGetMemoryManager(memory, out MemoryManager<T>? manager, out int index, out int length)) 153else if (MemoryMarshal.TryGetArray(memory, out ArraySegment<T> segment)) 164if (!MemoryMarshal.TryGetString((ReadOnlyMemory<char>)(object)memory, out string? text, out int start, out length))
System\Buffers\ReadOnlySequence.Helpers.cs (2)
688return MemoryMarshal.CreateReadOnlySpan(ref Unsafe.As<char, T>(ref MemoryMarshal.GetReference(spanOfChar)), spanOfChar.Length);
System\Buffers\SequenceReaderExtensions.Binary.cs (2)
32value = MemoryMarshal.Read<T>(span); 51value = MemoryMarshal.Read<T>(tempSpan);
System.Net.Http (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.Net.Mail (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.Net.NameResolution (6)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.IPAddress.cs (2)
38h.AddBytes(MemoryMarshal.CreateReadOnlySpan(ref Address[0], IsIPv6 ? IPv6AddressBytes : IPv4AddressBytes)); 71return MemoryMarshal.CreateReadOnlySpan(ref Address[0], addressByteCount).SequenceEqual(
src\runtime\src\libraries\Common\src\System\Net\SocketAddressPal.Unix.cs (4)
116fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 129fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 130fixed (byte* ipAddress = &MemoryMarshal.GetReference(address)) 159fixed (byte* rawInput = &MemoryMarshal.GetReference(address))
System.Net.Ping (11)
src\runtime\src\libraries\Common\src\System\Net\SocketAddressPal.Unix.cs (4)
116fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 129fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 130fixed (byte* ipAddress = &MemoryMarshal.GetReference(address)) 159fixed (byte* rawInput = &MemoryMarshal.GetReference(address))
src\runtime\src\libraries\Common\src\System\Runtime\InteropServices\SpanOfCharAsUtf8StringMarshaller.cs (1)
53_unmanagedValue = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
System\Net\NetworkInformation\Ping.RawSocket.cs (6)
113socket.SetRawSocketOption(0, 11, MemoryMarshal.AsBytes(new ReadOnlySpan<int>(in opt))); 118socket.SetRawSocketOption(41, 25, MemoryMarshal.AsBytes(new ReadOnlySpan<int>(in opt))); 148IcmpHeader receivedHeader = MemoryMarshal.Read<IcmpHeader>(receiveBuffer.AsSpan(icmpHeaderOffset)); 183IcmpHeader originalRequestHeader = MemoryMarshal.Read<IcmpHeader>(receiveBuffer.AsSpan(dataOffset + payloadIpHeaderLength)); 216IcmpHeader originalRequestHeader = MemoryMarshal.Read<IcmpHeader>(receiveBuffer.AsSpan(dataOffset + IpV6HeaderLengthInBytes)); 308fixed (byte* sockAddr = &MemoryMarshal.GetReference(socketAddress))
System.Net.Primitives (22)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.IPAddress.cs (2)
38h.AddBytes(MemoryMarshal.CreateReadOnlySpan(ref Address[0], IsIPv6 ? IPv6AddressBytes : IPv4AddressBytes)); 71return MemoryMarshal.CreateReadOnlySpan(ref Address[0], addressByteCount).SequenceEqual(
src\runtime\src\libraries\Common\src\System\Net\NetworkInformation\InterfaceInfoPal.Unix.cs (3)
37ReadOnlySpan<char> castInterfaceName = MemoryMarshal.Cast<TChar, char>(interfaceName); 52ReadOnlySpan<byte> castInterfaceName = MemoryMarshal.Cast<TChar, byte>(interfaceName); 58ReadOnlySpan<char> castInterfaceName = MemoryMarshal.Cast<TChar, char>(interfaceName);
src\runtime\src\libraries\Common\src\System\Net\SocketAddressPal.Unix.cs (4)
116fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 129fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 130fixed (byte* ipAddress = &MemoryMarshal.GetReference(address)) 159fixed (byte* rawInput = &MemoryMarshal.GetReference(address))
System\Net\IPAddress.cs (3)
374MemoryMarshal.AsBytes<ushort>(numbers).CopyTo(destination); 382MemoryMarshal.Write(destination, in address); 722ReadOnlySpan<byte> numbers = MemoryMarshal.AsBytes<ushort>(_numbers).Slice(0, 16);
System\Net\IPAddressParser.cs (4)
102ReadOnlySpan<byte> castScopeIdSpan = MemoryMarshal.Cast<TChar, byte>(scopeIdSpan); 108ReadOnlySpan<char> castScopeIdSpan = MemoryMarshal.Cast<TChar, char>(scopeIdSpan); 213scopeId.TryFormat(MemoryMarshal.Cast<TChar, byte>(destination).Slice(pos), out bytesWritten) : 214scopeId.TryFormat(MemoryMarshal.Cast<TChar, char>(destination).Slice(pos), out bytesWritten);
System\Net\IPEndPoint.cs (2)
137isConvertedToInt = uint.TryParse(MemoryMarshal.Cast<TChar, byte>(portSpan), NumberStyles.None, CultureInfo.InvariantCulture, out port); 141isConvertedToInt = uint.TryParse(MemoryMarshal.Cast<TChar, char>(portSpan), NumberStyles.None, CultureInfo.InvariantCulture, out port);
System\Net\IPNetwork.cs (4)
96BaseAddress.TryWriteBytes(MemoryMarshal.AsBytes(new Span<UInt128>(ref baseAddressValue)), out int bytesWritten); 98address.TryWriteBytes(MemoryMarshal.AsBytes(new Span<UInt128>(ref otherAddressValue)), out bytesWritten); 263baseAddress.TryWriteBytes(MemoryMarshal.AsBytes(new Span<UInt128>(ref value)), out int bytesWritten); 275: new IPAddress(MemoryMarshal.AsBytes(new Span<UInt128>(ref newAddress)));
System.Net.Quic (86)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.BIO.cs (1)
44BioWrite(b, ref MemoryMarshal.GetReference(data), data.Length);
src\runtime\src\libraries\Common\src\System\Net\SocketAddressPal.Unix.cs (4)
116fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 129fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 130fixed (byte* ipAddress = &MemoryMarshal.GetReference(address)) 159fixed (byte* rawInput = &MemoryMarshal.GetReference(address))
System\Net\Quic\Internal\MsQuicHelpers.cs (2)
52Span<byte> rawAddress = MemoryMarshal.AsBytes(MemoryMarshal.CreateSpan(ref result, 1));
System\Net\Quic\Interop\msquic_generated.cs (79)
14using MemoryMarshal = System.Runtime.InteropServices.MemoryMarshal; 315return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificateHash; 323return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificateHashStore; 331return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificateContext; 339return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificateFile; 347return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificateFileProtected; 355return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref this, 1)).Anonymous.CertificatePkcs12; 975return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.IsSetFlags, 1)); 983return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.IsSet, 1)); 1263return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous1.IsSetFlags, 1)); 1271return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous1.IsSet, 1)); 1279return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous2.Flags, 1)); 2231return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.NEW_CONNECTION, 1)); 2239return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.STOP_COMPLETE, 1)); 2331return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.CONNECTED, 1)); 2339return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SHUTDOWN_INITIATED_BY_TRANSPORT, 1)); 2347return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SHUTDOWN_INITIATED_BY_PEER, 1)); 2355return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SHUTDOWN_COMPLETE, 1)); 2363return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.LOCAL_ADDRESS_CHANGED, 1)); 2371return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_ADDRESS_CHANGED, 1)); 2379return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_STREAM_STARTED, 1)); 2387return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.STREAMS_AVAILABLE, 1)); 2395return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_NEEDS_STREAMS, 1)); 2403return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.IDEAL_PROCESSOR_CHANGED, 1)); 2411return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.DATAGRAM_STATE_CHANGED, 1)); 2419return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.DATAGRAM_RECEIVED, 1)); 2427return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.DATAGRAM_SEND_STATE_CHANGED, 1)); 2435return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.RESUMED, 1)); 2443return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.RESUMPTION_TICKET_RECEIVED, 1)); 2451return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_CERTIFICATE_RECEIVED, 1)); 2459return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.RELIABLE_RESET_NEGOTIATED, 1)); 2467return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.ONE_WAY_DELAY_NEGOTIATED, 1)); 2763return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.START_COMPLETE, 1)); 2771return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.RECEIVE, 1)); 2779return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SEND_COMPLETE, 1)); 2787return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_SEND_ABORTED, 1)); 2795return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.PEER_RECEIVE_ABORTED, 1)); 2803return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SEND_SHUTDOWN_COMPLETE, 1)); 2811return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.SHUTDOWN_COMPLETE, 1)); 2819return ref MemoryMarshal.GetReference(MemoryMarshal.CreateSpan(ref Anonymous.IDEAL_SEND_BUFFER_SIZE, 1));
System.Net.Security (17)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Net.Security.Native\Interop.NetSecurityNative.cs (3)
124ref MemoryMarshal.GetReference(inputBytes), 154ref MemoryMarshal.GetReference(inputBytes), 185ref MemoryMarshal.GetReference(inputBytes),
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.BIO.cs (1)
44BioWrite(b, ref MemoryMarshal.GetReference(data), data.Length);
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OCSP.cs (1)
87ref MemoryMarshal.GetReference(buf),
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSsl.cs (3)
1174fixed (byte* p = &MemoryMarshal.GetReference(clientProto)) *outp = p; 1277ReadOnlySpan<byte> data = MemoryMarshal.CreateReadOnlySpanFromNullTerminated((byte*)line); 1296int bytes = Ssl.BioWrite(bio, ref MemoryMarshal.GetReference(buffer), buffer.Length);
src\runtime\src\libraries\Common\src\Interop\Unix\System.Security.Cryptography.Native\Interop.Ssl.cs (2)
336fixed (byte* pBuffer = &MemoryMarshal.GetReference(serializedProtocols)) 352fixed (IntPtr* pHandles = &MemoryMarshal.GetReference(x509handles))
System\Net\NegotiateAuthenticationPal.ManagedNtlm.cs (5)
367ref NegotiateMessage message = ref MemoryMarshal.AsRef<NegotiateMessage>(asBytes); 459ref NtChallengeResponse temp = ref MemoryMarshal.AsRef<NtChallengeResponse>(blob.Slice(0, sizeof(NtChallengeResponse))); 466serverInfo.CopyTo(MemoryMarshal.CreateSpan(ref temp.ServerInfo[0], serverInfo.Length)); 638ref readonly ChallengeMessage challengeMessage = ref MemoryMarshal.AsRef<ChallengeMessage>(blob.Slice(0, sizeof(ChallengeMessage))); 697ref AuthenticateMessage response = ref MemoryMarshal.AsRef<AuthenticateMessage>(responseAsSpan.Slice(0, sizeof(AuthenticateMessage)));
System\Net\Security\SslStream.cs (2)
788fixed (byte* ptr = &MemoryMarshal.GetReference(buffer)) 823fixed (byte* ptr = &MemoryMarshal.GetReference(buffer))
System.Net.Sockets (24)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.IPAddress.cs (2)
38h.AddBytes(MemoryMarshal.CreateReadOnlySpan(ref Address[0], IsIPv6 ? IPv6AddressBytes : IPv4AddressBytes)); 71return MemoryMarshal.CreateReadOnlySpan(ref Address[0], addressByteCount).SequenceEqual(
src\runtime\src\libraries\Common\src\System\Net\SocketAddressPal.Unix.cs (4)
116fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 129fixed (byte* rawAddress = &MemoryMarshal.GetReference(buffer)) 130fixed (byte* ipAddress = &MemoryMarshal.GetReference(address)) 159fixed (byte* rawInput = &MemoryMarshal.GetReference(address))
System\Net\Sockets\Socket.cs (1)
315fixed (byte* ptr = &MemoryMarshal.GetReference(buffer))
System\Net\Sockets\Socket.Tasks.cs (4)
548saea.SetBuffer(MemoryMarshal.AsMemory(buffer)); 566saea.SetBuffer(MemoryMarshal.AsMemory(buffer)); 656saea.SetBuffer(MemoryMarshal.AsMemory(buffer)); 686saea.SetBuffer(MemoryMarshal.AsMemory(buffer));
System\Net\Sockets\SocketAsyncContext.Unix.cs (3)
1684fixed (byte* bufferPtr = &MemoryMarshal.GetReference(buffer)) 1904fixed (byte* bufferPtr = &MemoryMarshal.GetReference(buffer)) 2028fixed (byte* bufferPtr = &MemoryMarshal.GetReference(buffer))
System\Net\Sockets\SocketAsyncEventArgs.cs (1)
123bool success = MemoryMarshal.TryGetArray(_buffer, out ArraySegment<byte> arraySegment);
System\Net\Sockets\SocketPal.Unix.cs (9)
111fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 126fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 150fixed (byte* sockAddr = &MemoryMarshal.GetReference(socketAddress)) 151fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 191fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 212Unsafe.IsNullRef(ref MemoryMarshal.GetReference(buffer)) ? Array.Empty<byte>() : buffer; 221fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 249fixed (byte* b = &MemoryMarshal.GetReference(buffer)) 494fixed (byte* b = &MemoryMarshal.GetReference(buffer))
System.Net.WebSockets (3)
System\Net\WebSockets\ManagedWebSocket.cs (1)
1684fixed (byte* toMaskBeg = &MemoryMarshal.GetReference(toMask))
System\Net\WebSockets\WebSocket.cs (2)
37if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> arraySegment)) 57MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> arraySegment) ?
System.Numerics.Tensors (135)
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IAggregationOperator.cs (27)
68ref T xRef = ref MemoryMarshal.GetReference(x); 1186ref T xRef = ref MemoryMarshal.GetReference(x); 1187ref T yRef = ref MemoryMarshal.GetReference(y); 2396ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(AlignmentByteMask_64x65)), 2403ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(AlignmentUInt16Mask_32x33)), 2410ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(AlignmentUInt32Mask_16x17)), 2417ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(AlignmentUInt64Mask_8x9)), 2432ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(AlignmentByteMask_64x65)), 2439ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(AlignmentUInt16Mask_32x33)), 2446ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(AlignmentUInt32Mask_16x17)), 2453ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(AlignmentUInt64Mask_8x9)), 2468ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(AlignmentByteMask_64x65)), 2475ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(AlignmentUInt16Mask_32x33)), 2482ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(AlignmentUInt32Mask_16x17)), 2489ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(AlignmentUInt64Mask_8x9)), 2504ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(RemainderByteMask_64x65)), 2511ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(RemainderUInt16Mask_32x33)), 2518ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(RemainderUInt32Mask_16x17)), 2525ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(RemainderUInt64Mask_8x9)), 2540ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(RemainderByteMask_64x65)), 2547ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(RemainderUInt16Mask_32x33)), 2554ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(RemainderUInt32Mask_16x17)), 2561ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(RemainderUInt64Mask_8x9)), 2576ref Unsafe.As<byte, T>(ref MemoryMarshal.GetReference(RemainderByteMask_64x65)), 2583ref Unsafe.As<ushort, T>(ref MemoryMarshal.GetReference(RemainderUInt16Mask_32x33)), 2590ref Unsafe.As<uint, T>(ref MemoryMarshal.GetReference(RemainderUInt32Mask_16x17)), 2597ref Unsafe.As<ulong, T>(ref MemoryMarshal.GetReference(RemainderUInt64Mask_8x9)),
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IBinaryOperator.cs (5)
79ref T xRef = ref MemoryMarshal.GetReference(x); 80ref T yRef = ref MemoryMarshal.GetReference(y); 81ref T dRef = ref MemoryMarshal.GetReference(destination); 1412ref T xRef = ref MemoryMarshal.GetReference(x); 1413ref T dRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IBooleanUnaryOperator.cs (9)
80ref T xRef = ref MemoryMarshal.GetReference(x); 213ref T xRef = ref MemoryMarshal.GetReference(x); 214ref bool destinationRef = ref MemoryMarshal.GetReference(destination); 321ref T xRef = ref MemoryMarshal.GetReference(x); 322ref bool destinationRef = ref MemoryMarshal.GetReference(destination); 438ref T xRef = ref MemoryMarshal.GetReference(x); 439ref bool destinationRef = ref MemoryMarshal.GetReference(destination); 565ref T xRef = ref MemoryMarshal.GetReference(x); 566ref bool destinationRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IStatefulUnaryOperator.cs (2)
46ref T xRef = ref MemoryMarshal.GetReference(x); 47ref T dRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.ITernaryOperator.cs (9)
65ref T xRef = ref MemoryMarshal.GetReference(x); 66ref T yRef = ref MemoryMarshal.GetReference(y); 67ref T zRef = ref MemoryMarshal.GetReference(z); 68ref T dRef = ref MemoryMarshal.GetReference(destination); 1541ref T xRef = ref MemoryMarshal.GetReference(x); 1542ref T yRef = ref MemoryMarshal.GetReference(y); 1543ref T dRef = ref MemoryMarshal.GetReference(destination); 3028ref T xRef = ref MemoryMarshal.GetReference(x); 3029ref T dRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IUnaryInputBinaryOutput.cs (10)
65ref T sourceRef = ref MemoryMarshal.GetReference(x); 66ref T destination1Ref = ref MemoryMarshal.GetReference(destination1); 67ref T destination2Ref = ref MemoryMarshal.GetReference(destination2); 199ref T xRef = ref MemoryMarshal.GetReference(x); 200ref T yRef = ref MemoryMarshal.GetReference(y); 201ref T destination1Ref = ref MemoryMarshal.GetReference(destination1); 202ref T destination2Ref = ref MemoryMarshal.GetReference(destination2); 381ref T xRef = ref MemoryMarshal.GetReference(x); 382ref T destination1Ref = ref MemoryMarshal.GetReference(destination1); 383ref T destination2Ref = ref MemoryMarshal.GetReference(destination2);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IUnaryOneToFourOperator.cs (2)
40ref TInput sourceRef = ref MemoryMarshal.GetReference(x); 41ref TOutput destinationRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IUnaryOneToTwoOperator.cs (2)
40ref TInput sourceRef = ref MemoryMarshal.GetReference(x); 41ref TOutput destinationRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IUnaryOperator.cs (2)
86ref TInput xRef = ref MemoryMarshal.GetReference(x); 87ref TOutput dRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\Common\TensorPrimitives.IUnaryTwoToOneOperator.cs (2)
40ref TInput xRef = ref MemoryMarshal.GetReference(x); 41ref TOutput destinationRef = ref MemoryMarshal.GetReference(destination);
System\Numerics\Tensors\netcore\ReadOnlyTensorSpan_1.cs (9)
42? ref MemoryMarshal.GetArrayDataReference(array) 77? ref MemoryMarshal.GetArrayDataReference(array) 101? ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (uint)start) 110ref T reference = ref MemoryMarshal.GetReference(span); 140ref T reference = ref MemoryMarshal.GetReference(span); 155? ref Unsafe.As<byte, T>(ref MemoryMarshal.GetArrayDataReference(array)) 182? ref Unsafe.Add(ref Unsafe.As<byte, T>(ref MemoryMarshal.GetArrayDataReference(array)), linearOffset) 481span = MemoryMarshal.CreateReadOnlySpan(in Unsafe.Add(ref _reference, linearOffset), length); 497span = MemoryMarshal.CreateReadOnlySpan(in Unsafe.Add(ref _reference, linearOffset), length);
System\Numerics\Tensors\netcore\Tensor.cs (14)
272Span<T> dstSpan = MemoryMarshal.CreateSpan(ref destination._reference, (int)destination.FlattenedLength); 392Span<T> span = MemoryMarshal.CreateSpan(ref destination._reference, (int)destination.FlattenedLength); 430Span<T> span = MemoryMarshal.CreateSpan(ref destination._reference, (int)destination.FlattenedLength); 1623ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref Unsafe.Add(ref tensor.AsTensorSpan()._reference, tensor._start), tensor._values.Length - tensor._start); 1624Span<T> ospan = MemoryMarshal.CreateSpan(ref output.AsTensorSpan()._reference, (int)output.FlattenedLength); 1638Span<T> ospan = MemoryMarshal.CreateSpan(ref output.AsTensorSpan()._reference, (int)output.FlattenedLength); 1683ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref tensor._reference, (int)tensor.FlattenedLength); 1684Span<T> ospan = MemoryMarshal.CreateSpan(ref destination._reference, (int)destination.FlattenedLength); 1814return MemoryMarshal.CreateReadOnlySpan(in tensor.GetPinnableReference(), (int)tensor.FlattenedLength).SequenceEqual(MemoryMarshal.CreateReadOnlySpan(in other.GetPinnableReference(), (int)other.FlattenedLength)); 3662ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref x._reference, (int)x.FlattenedLength); 3694ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref x._reference, (int)x.FlattenedLength); 3725ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref x._reference, (int)x.FlattenedLength); 3758ReadOnlySpan<T> span = MemoryMarshal.CreateSpan(ref x._reference, (int)x.FlattenedLength);
System\Numerics\Tensors\netcore\Tensor_1.cs (6)
83get => ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start + _shape.GetLinearOffset<TensorShape.GetOffsetAndLengthForNInt, nint>(indexes)); 89get => ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start + _shape.GetLinearOffset<TensorShape.GetOffsetAndLengthForNIndex, NIndex>(indexes)); 137public ReadOnlyTensorSpan<T> AsReadOnlyTensorSpan() => new ReadOnlyTensorSpan<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start), in _shape); 149public TensorSpan<T> AsTensorSpan() => new TensorSpan<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_values), _start), in _shape); 196if (_shape.FlattenedLength != 0) ret = ref MemoryMarshal.GetArrayDataReference(_values); 393public readonly ref T Current => ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(_tensor._values), _linearOffset);
System\Numerics\Tensors\netcore\TensorPrimitives.CosineSimilarity.cs (12)
63ref T xRef = ref MemoryMarshal.GetReference(x); 64ref T yRef = ref MemoryMarshal.GetReference(y); 100ref T xRef = ref MemoryMarshal.GetReference(x); 101ref T yRef = ref MemoryMarshal.GetReference(y); 137ref T xRef = ref MemoryMarshal.GetReference(x); 138ref T yRef = ref MemoryMarshal.GetReference(y); 203ref short xRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(x)); 204ref short yRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(y)); 245ref short xRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(x)); 246ref short yRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(y)); 287ref short xRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(x)); 288ref short yRef = ref Unsafe.As<Half, short>(ref MemoryMarshal.GetReference(y));
System\Numerics\Tensors\netcore\TensorPrimitives.HammingDistance.cs (10)
55MemoryMarshal.CreateReadOnlySpan(ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(x)), x.Length), 56MemoryMarshal.CreateReadOnlySpan(ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(y)), y.Length)); 81ref T xRef = ref MemoryMarshal.GetReference(x); 82ref T yRef = ref MemoryMarshal.GetReference(y); 112ref T xRef = ref MemoryMarshal.GetReference(x); 113ref T yRef = ref MemoryMarshal.GetReference(y); 145ref T xRef = ref MemoryMarshal.GetReference(x); 146ref T yRef = ref MemoryMarshal.GetReference(y);
System\Numerics\Tensors\netcore\TensorPrimitives.Max.cs (3)
247ref T xRef = ref MemoryMarshal.GetReference(x); 312ref T xRef = ref MemoryMarshal.GetReference(x); 378ref T xRef = ref MemoryMarshal.GetReference(x);
System\Numerics\Tensors\netcore\TensorSpan_1.cs (9)
40? ref MemoryMarshal.GetArrayDataReference(array) 57? ref MemoryMarshal.GetArrayDataReference(array) 69? ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (uint)start) 76ref T reference = ref MemoryMarshal.GetReference(span); 88ref T reference = ref MemoryMarshal.GetReference(span); 101? ref Unsafe.As<byte, T>(ref MemoryMarshal.GetArrayDataReference(array)) 113? ref Unsafe.Add(ref Unsafe.As<byte, T>(ref MemoryMarshal.GetArrayDataReference(array)), linearOffset) 352span = MemoryMarshal.CreateSpan(ref Unsafe.Add(ref _reference, linearOffset), length); 368span = MemoryMarshal.CreateSpan(ref Unsafe.Add(ref _reference, linearOffset), length);
System\Numerics\Tensors\TensorPrimitives.Helpers.cs (2)
17if (!Unsafe.AreSame(ref MemoryMarshal.GetReference(input), ref MemoryMarshal.GetReference(destination)) &&
System.Private.CoreLib (1096)
Internal\Runtime\Augments\RuntimeAugments.cs (2)
157ref byte element = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(array), (nuint)flattenedIndex * array.ElementSize); 164ref object element = ref Unsafe.Add(ref Unsafe.As<byte, object>(ref MemoryMarshal.GetArrayDataReference(array)), flattenedIndex);
src\runtime\src\coreclr\nativeaot\Runtime.Base\src\System\Runtime\TypeCast.cs (2)
764ref object? element = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index); 795ref object? element = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index);
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.ReadDir.cs (1)
38? MemoryMarshal.CreateReadOnlySpanFromNullTerminated(Name)
src\runtime\src\libraries\Common\src\Interop\Unix\System.Native\Interop.ReadLink.cs (1)
43int resultLength = ReadLink(path, ref MemoryMarshal.GetReference(spanBuffer), spanBuffer.Length);
src\runtime\src\libraries\Common\src\System\HexConverter.cs (4)
122ref byte srcRef = ref MemoryMarshal.GetReference(source); 123ref TChar destRef = ref MemoryMarshal.GetReference(destination); 324ref TChar srcRef = ref MemoryMarshal.GetReference(source); 325ref byte destRef = ref MemoryMarshal.GetReference(destination);
src\runtime\src\libraries\Common\src\System\Number.Formatting.Common.cs (5)
328fixed (char* pFormat = &MemoryMarshal.GetReference(format)) 527fixed (char* pFormat = &MemoryMarshal.GetReference(format)) 793fixed (TChar* spanPtr = &MemoryMarshal.GetReference(vlb.AppendSpan(bufferSize))) 880r.EncodeToUtf8(MemoryMarshal.AsBytes(vlb.AppendSpan(r.Utf8SequenceLength))); 1135fixed (char* pFormat = &MemoryMarshal.GetReference(format))
src\runtime\src\libraries\Common\src\System\Number.NumberBuffer.cs (1)
33public readonly byte* DigitsPtr => (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(Digits)); // safe since constructor expects Digits to refer to unmovable memory
src\runtime\src\libraries\Common\src\System\Number.Parsing.Common.cs (2)
285fixed (TChar* stringPointer = &MemoryMarshal.GetReference(value)) 344fixed (TChar* stringPointer = &MemoryMarshal.GetReference(value))
src\runtime\src\libraries\Common\src\System\Runtime\InteropServices\SpanOfCharAsUtf8StringMarshaller.cs (1)
53_unmanagedValue = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
src\runtime\src\libraries\System.Private.CoreLib\src\Microsoft\Win32\SafeHandles\SafeFileHandle.ThreadPoolValueTaskSource.cs (1)
98Memory<byte> writableSingleSegment = MemoryMarshal.AsMemory(_singleSegment);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Array.cs (30)
64ref MemoryMarshal.GetArrayDataReference(newArray), 65ref MemoryMarshal.GetArrayDataReference(larray), 468ref byte src = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(sourceArray), (uint)sourceIndex * elementSize); 469ref byte dst = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(destinationArray), (uint)destinationIndex * elementSize); 543ref object? srcData = ref Unsafe.Add(ref Unsafe.As<byte, object?>(ref MemoryMarshal.GetArrayDataReference(sourceArray)), sourceIndex); 544ref byte destData = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(destinationArray), (nuint)destinationIndex * destSize); 588ref byte srcData = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(sourceArray), (nuint)sourceIndex * srcSize); 589ref object? destData = ref Unsafe.Add(ref Unsafe.As<byte, object?>(ref MemoryMarshal.GetArrayDataReference(destinationArray)), destinationIndex); 611ref object? srcData = ref Unsafe.Add(ref Unsafe.As<byte, object?>(ref MemoryMarshal.GetArrayDataReference(sourceArray)), sourceIndex); 612ref object? destData = ref Unsafe.Add(ref Unsafe.As<byte, object?>(ref MemoryMarshal.GetArrayDataReference(destinationArray)), destinationIndex); 648ref byte srcData = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(sourceArray), (nuint)sourceIndex * srcElSize); 649ref byte destData = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(destinationArray), (nuint)destinationIndex * destElSize); 671ref byte pStart = ref MemoryMarshal.GetArrayDataReference(array); 1517ref T first = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)startIndex); 1919ref Unsafe.Add(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetArrayDataReference(array)), startIndex), 1927ref Unsafe.Add(ref Unsafe.As<T, short>(ref MemoryMarshal.GetArrayDataReference(array)), startIndex), 1935ref Unsafe.Add(ref Unsafe.As<T, int>(ref MemoryMarshal.GetArrayDataReference(array)), startIndex), 1943ref Unsafe.Add(ref Unsafe.As<T, long>(ref MemoryMarshal.GetArrayDataReference(array)), startIndex), 2164ref Unsafe.Add(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetArrayDataReference(array)), endIndex), 2174ref Unsafe.Add(ref Unsafe.As<T, short>(ref MemoryMarshal.GetArrayDataReference(array)), endIndex), 2184ref Unsafe.Add(ref Unsafe.As<T, int>(ref MemoryMarshal.GetArrayDataReference(array)), endIndex), 2194ref Unsafe.Add(ref Unsafe.As<T, long>(ref MemoryMarshal.GetArrayDataReference(array)), endIndex), 2297SpanHelpers.Reverse(ref MemoryMarshal.GetArrayDataReference(array), (nuint)array.Length); 2314SpanHelpers.Reverse(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index), (nuint)length); 2515var span = new Span<T>(ref MemoryMarshal.GetArrayDataReference(array), array.Length); 2564var span = new Span<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index), length); 2588var spanKeys = new Span<TKey>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(keys), index), length); 2589var spanItems = new Span<TValue>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(items), index), length); 2606var span = new Span<T>(ref MemoryMarshal.GetArrayDataReference(array), array.Length); 3073new Span<T>(ref Unsafe.As<byte, T>(ref MemoryMarshal.GetArrayDataReference(array)), array.Length).Slice(adjustedIndex, length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\BitConverter.cs (28)
47Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value ? (byte)1 : (byte)0); 75Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 103Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 131Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 159Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 187Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 217Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 247Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 277Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 307Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 335Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 363Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 391Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 419Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), value); 445return Unsafe.ReadUnaligned<char>(ref MemoryMarshal.GetReference(value)); 480return Unsafe.ReadUnaligned<short>(ref MemoryMarshal.GetReference(value)); 518return Unsafe.ReadUnaligned<int>(ref MemoryMarshal.GetReference(value)); 556return Unsafe.ReadUnaligned<long>(ref MemoryMarshal.GetReference(value)); 594return Unsafe.ReadUnaligned<Int128>(ref MemoryMarshal.GetReference(value)); 621return Unsafe.ReadUnaligned<ushort>(ref MemoryMarshal.GetReference(value)); 651return Unsafe.ReadUnaligned<uint>(ref MemoryMarshal.GetReference(value)); 681return Unsafe.ReadUnaligned<ulong>(ref MemoryMarshal.GetReference(value)); 721return Unsafe.ReadUnaligned<UInt128>(ref MemoryMarshal.GetReference(value)); 746return Unsafe.ReadUnaligned<BFloat16>(ref MemoryMarshal.GetReference(value)); 771return Unsafe.ReadUnaligned<Half>(ref MemoryMarshal.GetReference(value)); 799return Unsafe.ReadUnaligned<float>(ref MemoryMarshal.GetReference(value)); 827return Unsafe.ReadUnaligned<double>(ref MemoryMarshal.GetReference(value)); 953return Unsafe.ReadUnaligned<byte>(ref MemoryMarshal.GetReference(value)) != 0;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffer.cs (4)
54Memmove(ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(dst), uDstOffset), ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(src), uSrcOffset), uCount); 86return Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index); 97Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), index) = value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Binary\BinaryPrimitives.ReadBigEndian.cs (56)
25BitConverter.Int64BitsToDouble(ReverseEndianness(MemoryMarshal.Read<long>(source))) : 26MemoryMarshal.Read<double>(source); 42BitConverter.Int16BitsToHalf(ReverseEndianness(MemoryMarshal.Read<short>(source))) : 43MemoryMarshal.Read<Half>(source); 59BitConverter.Int16BitsToBFloat16(ReverseEndianness(MemoryMarshal.Read<short>(source))) : 60MemoryMarshal.Read<BFloat16>(source); 76ReverseEndianness(MemoryMarshal.Read<short>(source)) : 77MemoryMarshal.Read<short>(source); 93ReverseEndianness(MemoryMarshal.Read<int>(source)) : 94MemoryMarshal.Read<int>(source); 110ReverseEndianness(MemoryMarshal.Read<long>(source)) : 111MemoryMarshal.Read<long>(source); 127ReverseEndianness(MemoryMarshal.Read<Int128>(source)) : 128MemoryMarshal.Read<Int128>(source); 144ReverseEndianness(MemoryMarshal.Read<nint>(source)) : 145MemoryMarshal.Read<nint>(source); 161BitConverter.Int32BitsToSingle(ReverseEndianness(MemoryMarshal.Read<int>(source))) : 162MemoryMarshal.Read<float>(source); 179ReverseEndianness(MemoryMarshal.Read<ushort>(source)) : 180MemoryMarshal.Read<ushort>(source); 197ReverseEndianness(MemoryMarshal.Read<uint>(source)) : 198MemoryMarshal.Read<uint>(source); 215ReverseEndianness(MemoryMarshal.Read<ulong>(source)) : 216MemoryMarshal.Read<ulong>(source); 233ReverseEndianness(MemoryMarshal.Read<UInt128>(source)) : 234MemoryMarshal.Read<UInt128>(source); 251ReverseEndianness(MemoryMarshal.Read<nuint>(source)) : 252MemoryMarshal.Read<nuint>(source); 269bool success = MemoryMarshal.TryRead(source, out long tmp); 274return MemoryMarshal.TryRead(source, out value); 291bool success = MemoryMarshal.TryRead(source, out short tmp); 296return MemoryMarshal.TryRead(source, out value); 313bool success = MemoryMarshal.TryRead(source, out short tmp); 318return MemoryMarshal.TryRead(source, out value); 335bool success = MemoryMarshal.TryRead(source, out short tmp); 340return MemoryMarshal.TryRead(source, out value); 357bool success = MemoryMarshal.TryRead(source, out int tmp); 362return MemoryMarshal.TryRead(source, out value); 379bool success = MemoryMarshal.TryRead(source, out long tmp); 384return MemoryMarshal.TryRead(source, out value); 401bool success = MemoryMarshal.TryRead(source, out Int128 tmp); 406return MemoryMarshal.TryRead(source, out value); 423bool success = MemoryMarshal.TryRead(source, out nint tmp); 428return MemoryMarshal.TryRead(source, out value); 444bool success = MemoryMarshal.TryRead(source, out int tmp); 449return MemoryMarshal.TryRead(source, out value); 467bool success = MemoryMarshal.TryRead(source, out ushort tmp); 472return MemoryMarshal.TryRead(source, out value); 490bool success = MemoryMarshal.TryRead(source, out uint tmp); 495return MemoryMarshal.TryRead(source, out value); 513bool success = MemoryMarshal.TryRead(source, out ulong tmp); 518return MemoryMarshal.TryRead(source, out value); 536bool success = MemoryMarshal.TryRead(source, out UInt128 tmp); 541return MemoryMarshal.TryRead(source, out value); 560bool success = MemoryMarshal.TryRead(source, out nuint tmp); 565return MemoryMarshal.TryRead(source, out value);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Binary\BinaryPrimitives.ReadLittleEndian.cs (56)
25BitConverter.Int64BitsToDouble(ReverseEndianness(MemoryMarshal.Read<long>(source))) : 26MemoryMarshal.Read<double>(source); 42BitConverter.Int16BitsToHalf(ReverseEndianness(MemoryMarshal.Read<short>(source))) : 43MemoryMarshal.Read<Half>(source); 59BitConverter.Int16BitsToBFloat16(ReverseEndianness(MemoryMarshal.Read<short>(source))) : 60MemoryMarshal.Read<BFloat16>(source); 76ReverseEndianness(MemoryMarshal.Read<short>(source)) : 77MemoryMarshal.Read<short>(source); 93ReverseEndianness(MemoryMarshal.Read<int>(source)) : 94MemoryMarshal.Read<int>(source); 110ReverseEndianness(MemoryMarshal.Read<long>(source)) : 111MemoryMarshal.Read<long>(source); 127ReverseEndianness(MemoryMarshal.Read<Int128>(source)) : 128MemoryMarshal.Read<Int128>(source); 144ReverseEndianness(MemoryMarshal.Read<nint>(source)) : 145MemoryMarshal.Read<nint>(source); 161BitConverter.Int32BitsToSingle(ReverseEndianness(MemoryMarshal.Read<int>(source))) : 162MemoryMarshal.Read<float>(source); 179ReverseEndianness(MemoryMarshal.Read<ushort>(source)) : 180MemoryMarshal.Read<ushort>(source); 197ReverseEndianness(MemoryMarshal.Read<uint>(source)) : 198MemoryMarshal.Read<uint>(source); 215ReverseEndianness(MemoryMarshal.Read<ulong>(source)) : 216MemoryMarshal.Read<ulong>(source); 233ReverseEndianness(MemoryMarshal.Read<UInt128>(source)) : 234MemoryMarshal.Read<UInt128>(source); 251ReverseEndianness(MemoryMarshal.Read<nuint>(source)) : 252MemoryMarshal.Read<nuint>(source); 269bool success = MemoryMarshal.TryRead(source, out long tmp); 274return MemoryMarshal.TryRead(source, out value); 291bool success = MemoryMarshal.TryRead(source, out short tmp); 296return MemoryMarshal.TryRead(source, out value); 313bool success = MemoryMarshal.TryRead(source, out short tmp); 318return MemoryMarshal.TryRead(source, out value); 335return MemoryMarshal.TryRead(source, out value); 338bool success = MemoryMarshal.TryRead(source, out short tmp); 357return MemoryMarshal.TryRead(source, out value); 360bool success = MemoryMarshal.TryRead(source, out int tmp); 379return MemoryMarshal.TryRead(source, out value); 382bool success = MemoryMarshal.TryRead(source, out long tmp); 401return MemoryMarshal.TryRead(source, out value); 404bool success = MemoryMarshal.TryRead(source, out Int128 tmp); 423return MemoryMarshal.TryRead(source, out value); 426bool success = MemoryMarshal.TryRead(source, out nint tmp); 444bool success = MemoryMarshal.TryRead(source, out int tmp); 449return MemoryMarshal.TryRead(source, out value); 467return MemoryMarshal.TryRead(source, out value); 470bool success = MemoryMarshal.TryRead(source, out ushort tmp); 490return MemoryMarshal.TryRead(source, out value); 493bool success = MemoryMarshal.TryRead(source, out uint tmp); 513return MemoryMarshal.TryRead(source, out value); 516bool success = MemoryMarshal.TryRead(source, out ulong tmp); 536return MemoryMarshal.TryRead(source, out value); 539bool success = MemoryMarshal.TryRead(source, out UInt128 tmp); 559return MemoryMarshal.TryRead(source, out value); 562bool success = MemoryMarshal.TryRead(source, out nuint tmp);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Binary\BinaryPrimitives.ReverseEndianness.cs (16)
202ReverseEndianness<short, Int16EndiannessReverser>(MemoryMarshal.Cast<ushort, short>(source), MemoryMarshal.Cast<ushort, short>(destination)); 211ReverseEndianness<int, Int32EndiannessReverser>(MemoryMarshal.Cast<uint, int>(source), MemoryMarshal.Cast<uint, int>(destination)); 220ReverseEndianness<long, Int64EndiannessReverser>(MemoryMarshal.Cast<ulong, long>(source), MemoryMarshal.Cast<ulong, long>(destination)); 230ReverseEndianness<long, Int64EndiannessReverser>(MemoryMarshal.Cast<nuint, long>(source), MemoryMarshal.Cast<nuint, long>(destination)); 238ReverseEndianness<long, Int64EndiannessReverser>(MemoryMarshal.Cast<nint, long>(source), MemoryMarshal.Cast<nint, long>(destination)); 294ref T sourceRef = ref MemoryMarshal.GetReference(source); 295ref T destRef = ref MemoryMarshal.GetReference(destination); 376ReverseEndianness(MemoryMarshal.Cast<UInt128, Int128>(source), MemoryMarshal.Cast<UInt128, Int128>(destination)); 386if (Unsafe.AreSame(ref MemoryMarshal.GetReference(source), ref MemoryMarshal.GetReference(destination)) ||
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Binary\BinaryPrimitives.WriteBigEndian.cs (56)
27MemoryMarshal.Write(destination, in tmp); 31MemoryMarshal.Write(destination, in value); 50MemoryMarshal.Write(destination, in tmp); 54MemoryMarshal.Write(destination, in value); 73MemoryMarshal.Write(destination, in tmp); 77MemoryMarshal.Write(destination, in value); 96MemoryMarshal.Write(destination, in tmp); 100MemoryMarshal.Write(destination, in value); 119MemoryMarshal.Write(destination, in tmp); 123MemoryMarshal.Write(destination, in value); 142MemoryMarshal.Write(destination, in tmp); 146MemoryMarshal.Write(destination, in value); 165MemoryMarshal.Write(destination, in tmp); 169MemoryMarshal.Write(destination, in value); 188MemoryMarshal.Write(destination, in tmp); 192MemoryMarshal.Write(destination, in value); 211MemoryMarshal.Write(destination, in tmp); 215MemoryMarshal.Write(destination, in value); 235MemoryMarshal.Write(destination, in tmp); 239MemoryMarshal.Write(destination, in value); 259MemoryMarshal.Write(destination, in tmp); 263MemoryMarshal.Write(destination, in value); 283MemoryMarshal.Write(destination, in tmp); 287MemoryMarshal.Write(destination, in value); 307MemoryMarshal.Write(destination, in tmp); 311MemoryMarshal.Write(destination, in value); 331MemoryMarshal.Write(destination, in tmp); 335MemoryMarshal.Write(destination, in value); 354return MemoryMarshal.TryWrite(destination, in tmp); 357return MemoryMarshal.TryWrite(destination, in value); 375return MemoryMarshal.TryWrite(destination, in tmp); 378return MemoryMarshal.TryWrite(destination, in value); 396return MemoryMarshal.TryWrite(destination, in tmp); 399return MemoryMarshal.TryWrite(destination, in value); 417return MemoryMarshal.TryWrite(destination, in tmp); 420return MemoryMarshal.TryWrite(destination, in value); 438return MemoryMarshal.TryWrite(destination, in tmp); 441return MemoryMarshal.TryWrite(destination, in value); 459return MemoryMarshal.TryWrite(destination, in tmp); 462return MemoryMarshal.TryWrite(destination, in value); 480return MemoryMarshal.TryWrite(destination, in tmp); 483return MemoryMarshal.TryWrite(destination, in value); 501return MemoryMarshal.TryWrite(destination, in tmp); 504return MemoryMarshal.TryWrite(destination, in value); 522return MemoryMarshal.TryWrite(destination, in tmp); 525return MemoryMarshal.TryWrite(destination, in value); 544return MemoryMarshal.TryWrite(destination, in tmp); 547return MemoryMarshal.TryWrite(destination, in value); 566return MemoryMarshal.TryWrite(destination, in tmp); 569return MemoryMarshal.TryWrite(destination, in value); 588return MemoryMarshal.TryWrite(destination, in tmp); 591return MemoryMarshal.TryWrite(destination, in value); 610return MemoryMarshal.TryWrite(destination, in tmp); 613return MemoryMarshal.TryWrite(destination, in value); 632return MemoryMarshal.TryWrite(destination, in tmp); 635return MemoryMarshal.TryWrite(destination, in value);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Binary\BinaryPrimitives.WriteLittleEndian.cs (56)
27MemoryMarshal.Write(destination, in tmp); 31MemoryMarshal.Write(destination, in value); 50MemoryMarshal.Write(destination, in tmp); 54MemoryMarshal.Write(destination, in value); 73MemoryMarshal.Write(destination, in tmp); 77MemoryMarshal.Write(destination, in value); 96MemoryMarshal.Write(destination, in tmp); 100MemoryMarshal.Write(destination, in value); 119MemoryMarshal.Write(destination, in tmp); 123MemoryMarshal.Write(destination, in value); 142MemoryMarshal.Write(destination, in tmp); 146MemoryMarshal.Write(destination, in value); 165MemoryMarshal.Write(destination, in tmp); 169MemoryMarshal.Write(destination, in value); 188MemoryMarshal.Write(destination, in tmp); 192MemoryMarshal.Write(destination, in value); 211MemoryMarshal.Write(destination, in tmp); 215MemoryMarshal.Write(destination, in value); 235MemoryMarshal.Write(destination, in tmp); 239MemoryMarshal.Write(destination, in value); 259MemoryMarshal.Write(destination, in tmp); 263MemoryMarshal.Write(destination, in value); 283MemoryMarshal.Write(destination, in tmp); 287MemoryMarshal.Write(destination, in value); 307MemoryMarshal.Write(destination, in tmp); 311MemoryMarshal.Write(destination, in value); 331MemoryMarshal.Write(destination, in tmp); 335MemoryMarshal.Write(destination, in value); 354return MemoryMarshal.TryWrite(destination, in tmp); 357return MemoryMarshal.TryWrite(destination, in value); 375return MemoryMarshal.TryWrite(destination, in tmp); 378return MemoryMarshal.TryWrite(destination, in value); 396return MemoryMarshal.TryWrite(destination, in tmp); 399return MemoryMarshal.TryWrite(destination, in value); 417return MemoryMarshal.TryWrite(destination, in tmp); 420return MemoryMarshal.TryWrite(destination, in value); 438return MemoryMarshal.TryWrite(destination, in tmp); 441return MemoryMarshal.TryWrite(destination, in value); 459return MemoryMarshal.TryWrite(destination, in tmp); 462return MemoryMarshal.TryWrite(destination, in value); 480return MemoryMarshal.TryWrite(destination, in tmp); 483return MemoryMarshal.TryWrite(destination, in value); 501return MemoryMarshal.TryWrite(destination, in tmp); 504return MemoryMarshal.TryWrite(destination, in value); 522return MemoryMarshal.TryWrite(destination, in tmp); 525return MemoryMarshal.TryWrite(destination, in value); 544return MemoryMarshal.TryWrite(destination, in tmp); 547return MemoryMarshal.TryWrite(destination, in value); 566return MemoryMarshal.TryWrite(destination, in tmp); 569return MemoryMarshal.TryWrite(destination, in value); 588return MemoryMarshal.TryWrite(destination, in tmp); 591return MemoryMarshal.TryWrite(destination, in value); 610return MemoryMarshal.TryWrite(destination, in tmp); 613return MemoryMarshal.TryWrite(destination, in value); 632return MemoryMarshal.TryWrite(destination, in tmp); 635return MemoryMarshal.TryWrite(destination, in value);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\SharedArrayPool.cs (1)
414Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(arrays), count) = array; // arrays[count] = array, but avoiding stelemref
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Decoder.cs (1)
175DecodeFrom(default(Base64DecoderChar), MemoryMarshal.Cast<char, ushort>(source), destination,
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Encoder.cs (1)
162EncodeTo(default(Base64EncoderChar), source, MemoryMarshal.Cast<char, ushort>(destination), out bytesConsumed, out charsWritten, isFinalBlock);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Helper\Base64DecoderHelper.cs (5)
34fixed (T* srcBytes = &MemoryMarshal.GetReference(source)) 35fixed (byte* destBytes = &MemoryMarshal.GetReference(bytes)) 129ref sbyte decodingMap = ref MemoryMarshal.GetReference(decoder.DecodingMap); 345fixed (byte* bufferBytes = &MemoryMarshal.GetReference(buffer)) 356ref sbyte decodingMap = ref MemoryMarshal.GetReference(decoder.DecodingMap);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Helper\Base64EncoderHelper.cs (5)
31fixed (byte* srcBytes = &MemoryMarshal.GetReference(source)) 32fixed (T* destBytes = &MemoryMarshal.GetReference(destination)) 83ref byte encodingMap = ref MemoryMarshal.GetReference(encoder.EncodingMap); 588fixed (byte* bufferBytes = &MemoryMarshal.GetReference(buffer)) 601ref byte encodingMap = ref MemoryMarshal.GetReference(encoder.EncodingMap);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Url\Base64UrlDecoder.cs (1)
202DecodeFrom(default(Base64UrlDecoderChar), MemoryMarshal.Cast<char, ushort>(source), destination,
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\Base64Url\Base64UrlEncoder.cs (1)
109EncodeTo(default(Base64UrlEncoderChar), source, MemoryMarshal.Cast<char, ushort>(destination), out bytesConsumed, out charsWritten, isFinalBlock);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\FormattingHelpers.CountDigits.cs (1)
55ulong powerOf10 = Unsafe.Add(ref MemoryMarshal.GetReference(powersOf10), elementOffset);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Collections\BitArray.cs (16)
95MemoryMarshal.AsBytes(array).CopyTo(_array); 99BinaryPrimitives.ReverseEndianness(array, MemoryMarshal.Cast<byte, int>((Span<byte>)_array)); 123MemoryMarshal.Cast<byte, int>((Span<byte>)_array)[(int)index] &= ReverseIfBE((1 << (int)extraBits) - 1); 172ref byte arrayRef = ref MemoryMarshal.GetArrayDataReference(_array); 173ReadOnlySpan<byte> valuesAsBytes = MemoryMarshal.AsBytes(values.AsSpan()); 257MemoryMarshal.AsBytes(values).CopyTo(_array); 261BinaryPrimitives.ReverseEndianness(values, MemoryMarshal.Cast<byte, int>((Span<byte>)_array)); 449Span<int> thisRemaining = MemoryMarshal.Cast<byte, int>(((Span<byte>)thisArray).Slice(i, roundedBytesRemaining)); 450Span<int> valueRemaining = MemoryMarshal.Cast<byte, int>(((Span<byte>)valueArray).Slice(i, roundedBytesRemaining)); 464ref byte left = ref MemoryMarshal.GetArrayDataReference(thisArray); 465ref byte right = ref MemoryMarshal.GetArrayDataReference(valueArray); 525Span<int> intSpan = MemoryMarshal.Cast<byte, int>((Span<byte>)_array); 588Span<int> intSpan = MemoryMarshal.Cast<byte, int>((Span<byte>)_array); 691Span<int> source = MemoryMarshal.Cast<byte, int>((Span<byte>)_array).Slice(0, intLength); 743Span<int> in32Span = MemoryMarshal.Cast<byte, int>((Span<byte>)_array); 898foreach (int i in MemoryMarshal.Cast<byte, int>(_array))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Collections\Generic\ArraySortHelper.cs (6)
463ref T zeroRef = ref MemoryMarshal.GetReference(keys); 549T t = Unsafe.Add(ref MemoryMarshal.GetReference(keys), i + 1); 552while (j >= 0 && (t == null || LessThan(ref t, ref Unsafe.Add(ref MemoryMarshal.GetReference(keys), j)))) 554Unsafe.Add(ref MemoryMarshal.GetReference(keys), j + 1) = Unsafe.Add(ref MemoryMarshal.GetReference(keys), j); 558Unsafe.Add(ref MemoryMarshal.GetReference(keys), j + 1) = t!;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Collections\Generic\RandomizedStringEqualityComparer.cs (2)
90ref Unsafe.As<char, byte>(ref MemoryMarshal.GetReference(alternate)), 135ref MemoryMarshal.GetReference(alternate),
src\runtime\src\libraries\System.Private.CoreLib\src\System\Diagnostics\Tracing\EventPipePayloadDecoder.cs (3)
121charPayload = MemoryMarshal.Cast<byte, char>(payload); 126charPayload = MemoryMarshal.Cast<byte, char>(payload.Slice(0, byteCount - 2)); 129decodedFields[i] = BitConverter.IsLittleEndian ? new string(charPayload) : Encoding.Unicode.GetString(MemoryMarshal.Cast<char, byte>(charPayload));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Enum.cs (2)
2254ReadOnlySpan<byte> rawData = MemoryMarshal.AsBytes(new ReadOnlySpan<long>(ref value)); 2265return RuntimeHelpers.Box(ref MemoryMarshal.GetReference(rawData), type)!;
src\runtime\src\libraries\System.Private.CoreLib\src\System\GCMemoryInfo.cs (2)
80internal ReadOnlySpan<GCGenerationInfo> GenerationInfoAsSpan => MemoryMarshal.CreateReadOnlySpan(ref _generationInfo0, 5); 85internal ReadOnlySpan<TimeSpan> PauseDurationsAsSpan => MemoryMarshal.CreateReadOnlySpan(ref _pauseDuration0, 2);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CalendarData.Icu.cs (1)
445ReadOnlySpan<char> calendarStringSpan = MemoryMarshal.CreateReadOnlySpanFromNullTerminated(calendarStringPtr);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CharUnicodeInfo.cs (17)
88StrongBidiCategory bidiCategory = (StrongBidiCategory)(Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoriesValues), offset) & 0b_0110_0000); 151uint rawValue = Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(DigitValues), offset); 185int rawValue = Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(DigitValues), offset); 199return (GraphemeClusterBreakType)Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(GraphemeSegmentationValues), offset); 217return (sbyte)Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoriesValues), offset) < 0; 263ref byte refToValue = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(NumericValues), offset * 8 /* sizeof(double) */); 287ref short rsStart = ref Unsafe.As<byte, short>(ref MemoryMarshal.GetReference(UppercaseValues)); 306ref ushort rsStart = ref Unsafe.As<byte, ushort>(ref MemoryMarshal.GetReference(UppercaseValues)); 322ref short rsStart = ref Unsafe.As<byte, short>(ref MemoryMarshal.GetReference(LowercaseValues)); 341ref ushort rsStart = ref Unsafe.As<byte, ushort>(ref MemoryMarshal.GetReference(LowercaseValues)); 421return (UnicodeCategory)(Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoriesValues), offset) & 0x1F); 482uint index = Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoryCasingLevel1Index), codePoint >> 9); 488ref byte level2Ref = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoryCasingLevel2Index), (index << 6) + ((codePoint >> 3) & 0b_0011_1110)); 502return Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(CategoryCasingLevel3Index), (index << 4) + (codePoint & 0x0F)); 519uint index = Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(NumericGraphemeLevel1Index), codePoint >> 9); 525ref byte level2Ref = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(NumericGraphemeLevel2Index), (index << 6) + ((codePoint >> 3) & 0b_0011_1110)); 539return Unsafe.AddByteOffset(ref MemoryMarshal.GetReference(NumericGraphemeLevel3Index), (index << 4) + (codePoint & 0x0F));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CompareInfo.cs (8)
291InvariantModeCasing.CompareStringIgnoreCase(ref MemoryMarshal.GetReference(string1), string1.Length, ref MemoryMarshal.GetReference(string2), string2.Length) : 367Debug.Assert(!Unsafe.IsNullRef(ref MemoryMarshal.GetReference(span1))); 368Debug.Assert(!Unsafe.IsNullRef(ref MemoryMarshal.GetReference(span2))); 438return Ordinal.CompareStringIgnoreCase(ref MemoryMarshal.GetReference(string1), string1.Length, ref MemoryMarshal.GetReference(string2), string2.Length); 452return Ordinal.CompareStringIgnoreCase(ref MemoryMarshal.GetReference(string1), string1.Length, ref MemoryMarshal.GetReference(string2), string2.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CompareInfo.Icu.cs (26)
60fixed (char* pString1 = &MemoryMarshal.GetReference(string1)) 61fixed (char* pString2 = &MemoryMarshal.GetReference(string2)) 88fixed (char* pSource = &MemoryMarshal.GetReference(source)) 89fixed (char* pTarget = &MemoryMarshal.GetReference(target)) 111fixed (char* ap = &MemoryMarshal.GetReference(source)) 112fixed (char* bp = &MemoryMarshal.GetReference(target)) 226fixed (char* ap = &MemoryMarshal.GetReference(source)) 227fixed (char* bp = &MemoryMarshal.GetReference(target)) 335fixed (char* pSource = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 336fixed (char* pPrefix = &MemoryMarshal.GetReference(prefix)) 352fixed (char* ap = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 353fixed (char* bp = &MemoryMarshal.GetReference(prefix)) 434fixed (char* ap = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 435fixed (char* bp = &MemoryMarshal.GetReference(prefix)) 519fixed (char* pSource = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 520fixed (char* pSuffix = &MemoryMarshal.GetReference(suffix)) 536fixed (char* ap = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 537fixed (char* bp = &MemoryMarshal.GetReference(suffix)) 619fixed (char* ap = &MemoryMarshal.GetReference(source)) // could be null (or otherwise unable to be dereferenced) 620fixed (char* bp = &MemoryMarshal.GetReference(suffix)) 758fixed (char* pSource = &MemoryMarshal.GetReference(source)) 759fixed (byte* pDest = &MemoryMarshal.GetReference(destination)) 805fixed (char* pSource = &MemoryMarshal.GetReference(source)) 870fixed (char* pSource = &MemoryMarshal.GetNonNullPinnableReference(source)) 872fixed (byte* pSortKey = &MemoryMarshal.GetReference(sortKey)) 895fixed (byte* pSortKey = &MemoryMarshal.GetReference(sortKey))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\CompareInfo.Nls.cs (12)
55fixed (char* pSource = &MemoryMarshal.GetReference(source)) 56fixed (char* pValue = &MemoryMarshal.GetReference(value)) 126fixed (char* pSource = &MemoryMarshal.GetReference(source)) 148fixed (byte* pSortKey = &MemoryMarshal.GetReference(span)) 219fixed (char* pString1 = &MemoryMarshal.GetReference(string1)) 220fixed (char* pString2 = &MemoryMarshal.GetReference(string2)) 271fixed (char* pSource = &MemoryMarshal.GetReference(lpStringSource)) 272fixed (char* pValue = &MemoryMarshal.GetReference(lpStringValue)) 439fixed (char* pSource = &MemoryMarshal.GetReference(source)) 440fixed (byte* pSortKey = &MemoryMarshal.GetReference(destination)) 494fixed (char* pSource = &MemoryMarshal.GetReference(source)) 523fixed (char* pText = &MemoryMarshal.GetReference(text))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\DateTimeFormat.cs (17)
176fixed (TChar* ptr = &MemoryMarshal.GetReference(outputBuffer.AppendSpan(2))) 183fixed (TChar* ptr = &MemoryMarshal.GetReference(outputBuffer.AppendSpan(4))) 757r.EncodeToUtf8(MemoryMarshal.AsBytes(result.AppendSpan(r.Utf8SequenceLength))); 834fixed (TChar* p = &MemoryMarshal.GetReference(result.AppendSpan(2))) 842fixed (TChar* p = &MemoryMarshal.GetReference(result.AppendSpan(5))) 888fixed (TChar* hoursMinutes = &MemoryMarshal.GetReference(result.AppendSpan(5))) 1115bool success = Unsafe.AreSame(ref MemoryMarshal.GetReference(destination), ref MemoryMarshal.GetReference(vlb.AsSpan())); 1327fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1355fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1382fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1415fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1474fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1534fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1574fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1622fixed (TChar* dest = &MemoryMarshal.GetReference(destination)) 1681fixed (TChar* dest = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\HebrewNumber.cs (1)
214Rune.DecodeLastFromUtf8(MemoryMarshal.AsBytes(outputBuffer.AsSpan()), out Rune value, out int bytesConsumed);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\IdnMapping.cs (2)
219Ordinal.EqualsIgnoreCase(ref MemoryMarshal.GetReference(input), ref MemoryMarshal.GetReference(output), input.Length))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\InvariantModeCasing.cs (4)
230fixed (char* pSource = &MemoryMarshal.GetReference(source)) 231fixed (char* pValue = &MemoryMarshal.GetReference(value)) 292fixed (char* pSource = &MemoryMarshal.GetReference(source)) 293fixed (char* pValue = &MemoryMarshal.GetReference(value))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\Normalization.Icu.cs (1)
68fixed (char* pDest = &MemoryMarshal.GetReference(buffer))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\Normalization.Nls.cs (1)
63fixed (char* pDest = &MemoryMarshal.GetReference(buffer))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\Ordinal.cs (2)
355ref char valueRef = ref MemoryMarshal.GetReference(value); 365ref char searchSpace = ref MemoryMarshal.GetReference(source);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\Ordinal.Utf8.cs (4)
61ReadOnlySpan<byte> spanA = MemoryMarshal.CreateReadOnlySpan(ref strA, lengthA); 62ReadOnlySpan<byte> spanB = MemoryMarshal.CreateReadOnlySpan(ref strB, lengthB); 371ReadOnlySpan<byte> spanA = MemoryMarshal.CreateReadOnlySpan(ref source, sourceLength); 372ReadOnlySpan<byte> spanB = MemoryMarshal.CreateReadOnlySpan(ref prefix, prefixLength);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\OrdinalCasing.Icu.cs (4)
285fixed (char* pSource = &MemoryMarshal.GetReference(source)) 286fixed (char* pValue = &MemoryMarshal.GetReference(value)) 349fixed (char* pSource = &MemoryMarshal.GetReference(source)) 350fixed (char* pValue = &MemoryMarshal.GetReference(value))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\TextInfo.cs (2)
264fixed (char* pSource = &MemoryMarshal.GetReference(source)) 265fixed (char* pDestination = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Globalization\TimeSpanFormat.cs (1)
232fixed (TChar* dest = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Guid.cs (17)
72this = MemoryMarshal.Read<Guid>(b); 89this = MemoryMarshal.Read<Guid>(b); 529Span<byte> bytes = MemoryMarshal.AsBytes(new Span<GuidResult>(ref result)); 617Span<byte> bytes = MemoryMarshal.AsBytes(new Span<GuidResult>(ref result)); 1003MemoryMarshal.Write(g, in this); 1008Guid guid = new Guid(MemoryMarshal.AsBytes(new ReadOnlySpan<Guid>(in this)), false); 1009MemoryMarshal.Write(g, in guid); 1021MemoryMarshal.Write(g, in this); 1026Guid guid = new Guid(MemoryMarshal.AsBytes(new ReadOnlySpan<Guid>(in this)), bigEndian); 1027MemoryMarshal.Write(g, in guid); 1040MemoryMarshal.Write(destination, in this); 1045Guid guid = new Guid(MemoryMarshal.AsBytes(new ReadOnlySpan<Guid>(in this)), false); 1046MemoryMarshal.Write(destination, in guid); 1062MemoryMarshal.Write(destination, in this); 1067Guid guid = new Guid(MemoryMarshal.AsBytes(new ReadOnlySpan<Guid>(in this)), bigEndian); 1068MemoryMarshal.Write(destination, in guid); 1337fixed (TChar* guidChars = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\Enumeration\FileSystemEntry.Unix.cs (1)
104Span<char> buffer = MemoryMarshal.CreateSpan(ref _fileNameBuffer._char0, DecodedNameBufferLength);
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\MemoryStream.cs (2)
410MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> destinationArray) ? 693if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> sourceArray))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\PinnedBufferMemoryStream.cs (1)
26fixed (byte* ptr = &MemoryMarshal.GetReference((Span<byte>)array))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\RandomAccess.Unix.cs (4)
27fixed (byte* bufPtr = &MemoryMarshal.GetReference(buffer)) 75fixed (Interop.Sys.IOVector* pinnedVectors = &MemoryMarshal.GetReference(vectors)) 114fixed (byte* bufPtr = &MemoryMarshal.GetReference(buffer)) 199fixed (Interop.Sys.IOVector* pinnedVectors = &MemoryMarshal.GetReference(left))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\Stream.cs (2)
311if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> array)) 734if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> array))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\StreamWriter.cs (1)
427fixed (char* bufferPtr = &MemoryMarshal.GetReference(buffer))
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\TextReader.cs (2)
275new ValueTask<int>(MemoryMarshal.TryGetArray(buffer, out ArraySegment<char> array) ? 305new ValueTask<int>(MemoryMarshal.TryGetArray(buffer, out ArraySegment<char> array) ?
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\TextWriter.cs (2)
674MemoryMarshal.TryGetArray(buffer, out ArraySegment<char> array) ? 769MemoryMarshal.TryGetArray(buffer, out ArraySegment<char> array) ?
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\UnmanagedMemoryStream.cs (6)
394SpanHelpers.Memmove(ref MemoryMarshal.GetReference(buffer), ref *(pointer + pos + _offset), (nuint)nInt); 406SpanHelpers.Memmove(ref MemoryMarshal.GetReference(buffer), ref *(_mem + pos), (nuint)nInt); 468MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> destinationArray) ? 673SpanHelpers.Memmove(ref *(pointer + pos + _offset), ref MemoryMarshal.GetReference(buffer), (nuint)buffer.Length); 685SpanHelpers.Memmove(ref *(_mem + pos), ref MemoryMarshal.GetReference(buffer), (nuint)buffer.Length); 734if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> sourceArray))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Marvin.cs (1)
23public static int ComputeHash32(ReadOnlySpan<byte> data, ulong seed) => ComputeHash32(ref MemoryMarshal.GetReference(data), (uint)data.Length, (uint)seed, (uint)(seed >> 32));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Marvin.OrdinalIgnoreCase.cs (1)
94int hash = ComputeHash32(ref Unsafe.As<char, byte>(ref MemoryMarshal.GetReference(scratch)), (uint)charsWritten * 2, p0, p1);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Memory.cs (4)
304refToReturn = ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject)); 317refToReturn = ref MemoryMarshal.GetReference(memoryManagerSpan); 414void* pointer = Unsafe.Add<T>(Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject))), _index & ReadOnlyMemory<T>.RemoveFlagsBitMask); 421void* pointer = Unsafe.Add<T>(Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject))), _index);
src\runtime\src\libraries\System.Private.CoreLib\src\System\MemoryExtensions.cs (203)
39return new Span<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)start /* force zero-extension */), array.Length - start); 63return new Span<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)actualIndex /* force zero-extension */), array.Length - actualIndex); 87return new Span<T>(ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)start /* force zero-extension */), length); 335ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 342ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 349ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 356ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 362return SpanHelpers.Contains(ref MemoryMarshal.GetReference(span), value, span.Length); 818ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 825ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 832ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 839ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 845return SpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value, span.Length); 867ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 874ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 881ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 888ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 945ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 953ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 960return SpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, span.Length); 983ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 991ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1052ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1061ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1069return SpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, value2, span.Length); 1093ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1102ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1155ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1165ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1174return SpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, value2, value3, span.Length); 1212ref byte valuesRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values)); 1215ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1225ref short valuesRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(values)); 1228ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1241ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 1243ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(values)), 1396ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1403ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1410ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 1417ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 1423return SpanHelpers.LastIndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value, span.Length); 1445ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1452ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1459ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 1466ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 1523ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1531ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1538return SpanHelpers.LastIndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, span.Length); 1561ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1569ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1630ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1639ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1647return SpanHelpers.LastIndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, value2, span.Length); 1671ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1680ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1734ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1744ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1753return SpanHelpers.LastIndexOfAnyExcept(ref MemoryMarshal.GetReference(span), value0, value1, value2, value3, span.Length); 1792ref byte valuesRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values)); 1795ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1805ref short valuesRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(values)); 1808ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 1821ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 1823ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(values)), 1930ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 1939ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)), 1948ref Unsafe.As<T, uint>(ref MemoryMarshal.GetReference(span)), 1957ref Unsafe.As<T, ulong>(ref MemoryMarshal.GetReference(span)), 1964return SpanHelpers.IndexOfAnyInRange(ref MemoryMarshal.GetReference(span), lowInclusive, highInclusive, span.Length); 2001ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2010ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)), 2019ref Unsafe.As<T, uint>(ref MemoryMarshal.GetReference(span)), 2028ref Unsafe.As<T, ulong>(ref MemoryMarshal.GetReference(span)), 2035return SpanHelpers.IndexOfAnyExceptInRange(ref MemoryMarshal.GetReference(span), lowInclusive, highInclusive, span.Length); 2072ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2081ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)), 2090ref Unsafe.As<T, uint>(ref MemoryMarshal.GetReference(span)), 2099ref Unsafe.As<T, ulong>(ref MemoryMarshal.GetReference(span)), 2106return SpanHelpers.LastIndexOfAnyInRange(ref MemoryMarshal.GetReference(span), lowInclusive, highInclusive, span.Length); 2143ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2152ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)), 2161ref Unsafe.As<T, uint>(ref MemoryMarshal.GetReference(span)), 2170ref Unsafe.As<T, ulong>(ref MemoryMarshal.GetReference(span)), 2177return SpanHelpers.LastIndexOfAnyExceptInRange(ref MemoryMarshal.GetReference(span), lowInclusive, highInclusive, span.Length); 2216ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2222ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2228ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 2234ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 2239return SpanHelpers.IndexOf(ref MemoryMarshal.GetReference(span), value, span.Length); 2257ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2263ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2269ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 2275ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 2325ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2327ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 2332ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 2334ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(value)), 2338return SpanHelpers.IndexOf(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(value), value.Length); 2354ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2356ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 2361ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 2363ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(value)), 2412ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2419ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2426ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 2433ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 2439return SpanHelpers.LastIndexOf(ref MemoryMarshal.GetReference(span), value, span.Length); 2458ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2465ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2472ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 2479ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 2532ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2534ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 2540ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 2542ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(value)), 2547return SpanHelpers.LastIndexOf(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(value), value.Length); 2564ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2566ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 2572ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 2574ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(value)), 2675ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2683ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2690return SpanHelpers.IndexOfAny(ref MemoryMarshal.GetReference(span), value0, value1, span.Length); 2710ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2718ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2775ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2784ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2792return SpanHelpers.IndexOfAny(ref MemoryMarshal.GetReference(span), value0, value1, value2, span.Length); 2813ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 2822ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 2879ref byte spanRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)); 2880ref byte valueRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values)); 2927ref short spanRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)); 2928ref short valueRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(values)); 2964return SpanHelpers.IndexOfAny(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(values), values.Length); 3095ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3103ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 3110return SpanHelpers.LastIndexOfAny(ref MemoryMarshal.GetReference(span), value0, value1, span.Length); 3130ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3138ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 3196ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3205ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 3213return SpanHelpers.LastIndexOfAny(ref MemoryMarshal.GetReference(span), value0, value1, value2, span.Length); 3234ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3243ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 3301ref byte spanRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)); 3302ref byte valueRef = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values)); 3349ref short spanRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)); 3350ref short valueRef = ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(values)); 3386return SpanHelpers.LastIndexOfAny(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(values), values.Length); 3456ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3457ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(other)), 3461return length == otherLength && SpanHelpers.SequenceEqual(ref MemoryMarshal.GetReference(span), ref MemoryMarshal.GetReference(other), length); 3498ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3499ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(other)), 3540ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3542ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(other)), 3547ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(span)), 3549ref Unsafe.As<T, char>(ref MemoryMarshal.GetReference(other)), 3552return SpanHelpers.SequenceCompareTo(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(other), other.Length); 3596ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 3597ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 3601return valueLength <= span.Length && SpanHelpers.SequenceEqual(ref MemoryMarshal.GetReference(span), ref MemoryMarshal.GetReference(value), valueLength); 3639ref Unsafe.As<T, byte>(ref Unsafe.Add(ref MemoryMarshal.GetReference(span), (nint)(uint)(spanLength - valueLength) /* force zero-extension */)), 3640ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(value)), 3646ref Unsafe.Add(ref MemoryMarshal.GetReference(span), (nint)(uint)(spanLength - valueLength) /* force zero-extension */), 3647ref MemoryMarshal.GetReference(value), 3719SpanHelpers.Reverse(ref MemoryMarshal.GetReference(span), (nuint)span.Length); 4130ref MemoryMarshal.GetReference(span), 4131ref MemoryMarshal.GetReference(other)); 4149ref MemoryMarshal.GetReference(span), 4150ref MemoryMarshal.GetReference(other)); 4479ref byte src = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)); 4491ref ushort src = ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)); 4502ref int src = ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)); 4513ref long src = ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)); 4524ref T src2 = ref MemoryMarshal.GetReference(span); 4545ref byte src = ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)); 4557ref ushort src = ref Unsafe.As<T, ushort>(ref MemoryMarshal.GetReference(span)); 4568ref int src = ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)); 4579ref long src = ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)); 4643ref T src = ref MemoryMarshal.GetReference(source); 4644ref T dst = ref MemoryMarshal.GetReference(destination); 4727ref T src = ref MemoryMarshal.GetReference(source); 4728ref T dst = ref MemoryMarshal.GetReference(destination); 4942ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 4943ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(other)), 5433ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 5440ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 5447ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 5454ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)), 5461ref MemoryMarshal.GetReference(span), 5482ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(span)), 5489ref Unsafe.As<T, short>(ref MemoryMarshal.GetReference(span)), 5496ref Unsafe.As<T, int>(ref MemoryMarshal.GetReference(span)), 5503ref Unsafe.As<T, long>(ref MemoryMarshal.GetReference(span)),
src\runtime\src\libraries\System.Private.CoreLib\src\System\MemoryExtensions.Globalization.cs (12)
96return Ordinal.EqualsIgnoreCase(ref MemoryMarshal.GetReference(span), ref MemoryMarshal.GetReference(value), span.Length); 127return Ordinal.CompareStringIgnoreCase(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(other), other.Length); 143return SpanHelpers.IndexOf(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(value), value.Length); 191ref MemoryMarshal.GetReference(span), 193ref MemoryMarshal.GetReference(value), 367ref Unsafe.Add(ref MemoryMarshal.GetReference(span), span.Length - value.Length), 368ref MemoryMarshal.GetReference(value), 404&& Ordinal.EqualsIgnoreCase(ref MemoryMarshal.GetReference(span), ref MemoryMarshal.GetReference(value), value.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\MemoryExtensions.Globalization.Utf8.cs (4)
24return Ordinal.EqualsIgnoreCaseUtf8(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(value), value.Length); 75return Ordinal.StartsWithIgnoreCaseUtf8(ref MemoryMarshal.GetReference(span), span.Length, ref MemoryMarshal.GetReference(value), value.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Net\WebUtility.cs (1)
349Span<byte> utf8Bytes = MemoryMarshal.AsBytes(dest).Slice(dest.Length * 2 - state.byteCount);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Number.Formatting.cs (16)
306MemoryMarshal.AsBytes<char>("00010203040506070809" + 330ref MemoryMarshal.GetReference(useChars ? TwoDigitsCharsAsBytes : TwoDigitsBytes); 1679fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 1727fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 1783fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 1993fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2014fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2112fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2160fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2232fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2421fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2441fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2542fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2594fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2657fixed (TChar* buffer = &MemoryMarshal.GetReference(destination)) 2782fixed (TChar* buffer = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\BitOperations.cs (4)
574ref MemoryMarshal.GetReference(TrailingZeroCountDeBruijn), 871ref uint lookupTable = ref MemoryMarshal.GetArrayDataReference(s_crcTable); 879ref uint lookupTable = ref MemoryMarshal.GetArrayDataReference(s_crcTable); 890ref uint lookupTable = ref MemoryMarshal.GetArrayDataReference(s_crcTable);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Vector.cs (1)
821return Unsafe.ReadUnaligned<Vector<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values)));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Vector_1.cs (6)
97this = Unsafe.ReadUnaligned<Vector<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values))); 115this = Unsafe.ReadUnaligned<Vector<T>>(ref MemoryMarshal.GetReference(values)); 665Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), this); 679Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), this); 786Unsafe.WriteUnaligned(ref MemoryMarshal.GetReference(destination), this); 801Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), this);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Vector2.cs (3)
411return Unsafe.ReadUnaligned<Vector2>(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(values))); 1016Unsafe.WriteUnaligned(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(destination)), this); 1030Unsafe.WriteUnaligned(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(destination)), this);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Vector3.cs (3)
446return Unsafe.ReadUnaligned<Vector3>(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(values))); 1026Unsafe.WriteUnaligned(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(destination)), this); 1040Unsafe.WriteUnaligned(ref Unsafe.As<float, byte>(ref MemoryMarshal.GetReference(destination)), this);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Random.cs (1)
646Shuffle(new Span<T>(ref MemoryMarshal.GetArrayDataReference(values), values.Length));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Random.Xoshiro256StarStarImpl.cs (1)
142MemoryMarshal.Write(buffer, BitOperations.RotateLeft(s1 * 5, 7) * 9);
src\runtime\src\libraries\System.Private.CoreLib\src\System\ReadOnlyMemory.cs (4)
226refToReturn = ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject)); 239refToReturn = ref MemoryMarshal.GetReference(memoryManagerSpan); 329void* pointer = Unsafe.Add<T>(Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject))), _index & RemoveFlagsBitMask); 336void* pointer = Unsafe.Add<T>(Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(Unsafe.As<T[]>(tmpObject))), _index);
src\runtime\src\libraries\System.Private.CoreLib\src\System\ReadOnlySpan.cs (2)
50_reference = ref MemoryMarshal.GetArrayDataReference(array); 84_reference = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)start /* force zero-extension */);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\AsyncProfiler.cs (2)
296ref byte dst = ref MemoryMarshal.GetReference(buffer); 323ref byte dst = ref MemoryMarshal.GetReference(buffer);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\RuntimeHelpers.cs (2)
64ref MemoryMarshal.GetArrayDataReference(dest), 65ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), offset),
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\CollectionsMarshal.cs (1)
39span = new Span<T>(ref MemoryMarshal.GetArrayDataReference(items), size);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\GCHandle.cs (1)
142return (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(Unsafe.As<Array>(target)));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\GCHandleExtensions.cs (1)
38return (T*)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(array));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshal.cs (2)
169void* pRawData = Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(arr)); 178void* pRawData = Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(arr));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\AnsiStringMarshaller.cs (1)
92_unmanagedValue = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\ArrayMarshaller.cs (2)
181public ref TUnmanagedElement GetPinnableReference() => ref MemoryMarshal.GetReference(_span); 212return ref MemoryMarshal.GetArrayDataReference(array);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\BStrStringMarshaller.cs (1)
91byte* pBuffer = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\PointerArrayMarshaller.cs (2)
182public ref TUnmanagedElement GetPinnableReference() => ref MemoryMarshal.GetReference(_span); 213return ref MemoryMarshal.GetArrayDataReference(array);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\ReadOnlySpanMarshaller.cs (5)
19/// A <see cref="ReadOnlySpan{T}"/> marshalled with this marshaller will match the semantics of <see cref="MemoryMarshal.GetReference{T}(ReadOnlySpan{T})"/>. 45if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(managed))) 110if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(managed))) 147public ref TUnmanagedElement GetPinnableReference() => ref MemoryMarshal.GetReference(_span); 173return ref MemoryMarshal.GetReference(managed);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\SpanMarshaller.cs (5)
19/// A <see cref="Span{T}"/> marshalled with this marshaller will match the semantics of <see cref="MemoryMarshal.GetReference{T}(Span{T})"/>. 39if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(managed))) 143if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(managed))) 179public ref TUnmanagedElement GetPinnableReference() => ref MemoryMarshal.GetReference(_span); 205return ref MemoryMarshal.GetReference(managed);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshalling\Utf8StringMarshaller.cs (1)
96_unmanagedValue = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(buffer));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\SafeBuffer.cs (2)
246ref T structure = ref MemoryMarshal.GetReference(buffer); 335ref T structure = ref MemoryMarshal.GetReference(data);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\ISimdVector_2.cs (3)
207TSelf.StoreUnsafe(vector, ref MemoryMarshal.GetReference(destination)); 257return TSelf.LoadUnsafe(ref MemoryMarshal.GetReference(values)); 792TSelf.StoreUnsafe(vector, ref MemoryMarshal.GetReference(destination));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector128.cs (3)
790Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector); 1059return Unsafe.ReadUnaligned<Vector128<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values))); 3777Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector256.cs (3)
797Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector); 1060return Unsafe.ReadUnaligned<Vector256<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values))); 3714Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector512.cs (3)
708Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector); 955return Unsafe.ReadUnaligned<Vector512<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values))); 3685Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Vector64.cs (3)
749Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector); 1035return Unsafe.ReadUnaligned<Vector64<T>>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(values))); 3774Unsafe.WriteUnaligned(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(destination)), vector);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any1CharPackedIgnoreCaseSearchValues.cs (2)
37PackedSpanHelpers.IndexOfAnyIgnoreCase(ref MemoryMarshal.GetReference(span), _lowerCase, span.Length); 42PackedSpanHelpers.IndexOfAnyExceptIgnoreCase(ref MemoryMarshal.GetReference(span), _lowerCase, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any1CharPackedSearchValues.cs (2)
27PackedSpanHelpers.IndexOf(ref MemoryMarshal.GetReference(span), _e0, span.Length); 32PackedSpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), _e0, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any1SearchValues.cs (4)
36SpanHelpers.NonPackedIndexOfValueType<TImpl, SpanHelpers.DontNegate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, span.Length); 40SpanHelpers.NonPackedIndexOfValueType<TImpl, SpanHelpers.Negate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, span.Length); 44SpanHelpers.LastIndexOfValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, span.Length); 48SpanHelpers.LastIndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any2CharPackedIgnoreCaseSearchValues.cs (4)
44PackedSpanHelpers.IndexOfAnyIgnoreCase(ref MemoryMarshal.GetReference(span), _e0, _e1, span.Length); 49PackedSpanHelpers.IndexOfAnyExceptIgnoreCase(ref MemoryMarshal.GetReference(span), _e0, _e1, span.Length); 57ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 65ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any2CharPackedSearchValues.cs (2)
27PackedSpanHelpers.IndexOfAny(ref MemoryMarshal.GetReference(span), _e0, _e1, span.Length); 32PackedSpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), _e0, _e1, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any2SearchValues.cs (4)
36SpanHelpers.NonPackedIndexOfAnyValueType<TImpl, SpanHelpers.DontNegate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, span.Length); 40SpanHelpers.NonPackedIndexOfAnyValueType<TImpl, SpanHelpers.Negate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, span.Length); 44SpanHelpers.LastIndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, span.Length); 48SpanHelpers.LastIndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any3CharPackedSearchValues.cs (2)
27PackedSpanHelpers.IndexOfAny(ref MemoryMarshal.GetReference(span), _e0, _e1, _e2, span.Length); 32PackedSpanHelpers.IndexOfAnyExcept(ref MemoryMarshal.GetReference(span), _e0, _e1, _e2, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any3SearchValues.cs (4)
36SpanHelpers.NonPackedIndexOfAnyValueType<TImpl, SpanHelpers.DontNegate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, span.Length); 40SpanHelpers.NonPackedIndexOfAnyValueType<TImpl, SpanHelpers.Negate<TImpl>>(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, span.Length); 44SpanHelpers.LastIndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, span.Length); 48SpanHelpers.LastIndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any4SearchValues.cs (4)
39SpanHelpers.IndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, span.Length); 43SpanHelpers.IndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, span.Length); 47SpanHelpers.LastIndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, span.Length); 51SpanHelpers.LastIndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Any5SearchValues.cs (4)
40SpanHelpers.IndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, _e4, span.Length); 44SpanHelpers.IndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, _e4, span.Length); 48SpanHelpers.LastIndexOfAnyValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, _e4, span.Length); 52SpanHelpers.LastIndexOfAnyExceptValueType(ref Unsafe.As<T, TImpl>(ref MemoryMarshal.GetReference(span)), _e0, _e1, _e2, _e3, _e4, span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\AnyByteSearchValues.cs (6)
32ref MemoryMarshal.GetReference(span), span.Length, ref _state); 40ref MemoryMarshal.GetReference(span), span.Length, ref _state); 48ref MemoryMarshal.GetReference(span), span.Length, ref _state); 56ref MemoryMarshal.GetReference(span), span.Length, ref _state); 64ref MemoryMarshal.GetReference(span), span.Length, ref _state); 72ref MemoryMarshal.GetReference(span), span.Length, ref _state);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\AsciiByteSearchValues.cs (6)
48ref MemoryMarshal.GetReference(span), span.Length, ref _state); 56ref MemoryMarshal.GetReference(span), span.Length, ref _state); 64ref MemoryMarshal.GetReference(span), span.Length, ref _state); 72ref MemoryMarshal.GetReference(span), span.Length, ref _state); 80ref MemoryMarshal.GetReference(span), span.Length, ref _state); 88ref MemoryMarshal.GetReference(span), span.Length, ref _state);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\AsciiCharSearchValues.cs (6)
50ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 58ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 66ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 74ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 82ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state); 90ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), span.Length, ref _state);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\BitmapCharSearchValues.cs (4)
56IndexOfAny<IndexOfAnyAsciiSearcher.DontNegate>(ref MemoryMarshal.GetReference(span), span.Length); 60IndexOfAny<IndexOfAnyAsciiSearcher.Negate>(ref MemoryMarshal.GetReference(span), span.Length); 64LastIndexOfAny<IndexOfAnyAsciiSearcher.DontNegate>(ref MemoryMarshal.GetReference(span), span.Length); 68LastIndexOfAny<IndexOfAnyAsciiSearcher.Negate>(ref MemoryMarshal.GetReference(span), span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticCharSearchValues.cs (4)
26ProbabilisticMap.IndexOfAny<SearchValues.TrueConst>(ref MemoryMarshal.GetReference(span), span.Length, ref _map); 29ProbabilisticMapState.IndexOfAnySimpleLoop<SearchValues.TrueConst, IndexOfAnyAsciiSearcher.Negate>(ref MemoryMarshal.GetReference(span), span.Length, ref _map); 32ProbabilisticMap.LastIndexOfAny<SearchValues.TrueConst>(ref MemoryMarshal.GetReference(span), span.Length, ref _map); 35ProbabilisticMapState.LastIndexOfAnySimpleLoop<SearchValues.TrueConst, IndexOfAnyAsciiSearcher.Negate>(ref MemoryMarshal.GetReference(span), span.Length, ref _map);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticMap.cs (1)
108ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(values)),
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticMapState.cs (1)
88return Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(hashEntries), (nuint)offset) == value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\ProbabilisticWithAsciiCharSearchValues.cs (10)
60ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 70ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 86ref MemoryMarshal.GetReference(span), 109ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 124ref MemoryMarshal.GetReference(span), 159ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 169ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 185ref MemoryMarshal.GetReference(span), 198ref Unsafe.As<char, short>(ref MemoryMarshal.GetReference(span)), 213ref MemoryMarshal.GetReference(span),
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\RangeCharSearchValues.cs (4)
43? PackedSpanHelpers.IndexOfAnyInRange(ref MemoryMarshal.GetReference(span), _lowInclusive, _rangeInclusive, span.Length) 45ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(span)), 53? PackedSpanHelpers.IndexOfAnyExceptInRange(ref MemoryMarshal.GetReference(span), _lowInclusive, _rangeInclusive, span.Length) 55ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(span)),
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\SearchValues.cs (1)
86ReadOnlySpan<short> shortValues = MemoryMarshal.Cast<char, short>(values);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\AsciiStringSearchValuesTeddyBase.cs (9)
202ref char searchSpace = ref MemoryMarshal.GetReference(span); 254ref char searchSpace = ref MemoryMarshal.GetReference(span); 306ref char searchSpace = ref MemoryMarshal.GetReference(span); 361ref char searchSpace = ref MemoryMarshal.GetReference(span); 431ref char searchSpace = ref MemoryMarshal.GetReference(span); 486ref char searchSpace = ref MemoryMarshal.GetReference(span); 547offsetFromStart = (int)((nuint)Unsafe.ByteOffset(ref MemoryMarshal.GetReference(span), ref matchRef) / 2); 594offsetFromStart = (int)((nuint)Unsafe.ByteOffset(ref MemoryMarshal.GetReference(span), ref matchRef) / 2); 639offsetFromStart = (int)((nuint)Unsafe.ByteOffset(ref MemoryMarshal.GetReference(span), ref matchRef) / 2);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\Helpers\AhoCorasick.cs (7)
81ref AhoCorasickNode nodes = ref MemoryMarshal.GetArrayDataReference(_nodes); 100ref Unsafe.As<char, short>(ref Unsafe.Add(ref MemoryMarshal.GetReference(span), i)), 123char c = TCaseSensitivity.TransformInput(Unsafe.Add(ref MemoryMarshal.GetReference(span), i)); 186ref AhoCorasickNode nodes = ref MemoryMarshal.GetArrayDataReference(_nodes); 209ref Unsafe.As<char, short>(ref Unsafe.Add(ref MemoryMarshal.GetReference(span), i)), 242c = Unsafe.Add(ref MemoryMarshal.GetReference(span), i); 247char.IsLowSurrogate(lowSurrogate = Unsafe.Add(ref MemoryMarshal.GetReference(span), i + 1)))
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\Helpers\RabinKarp.cs (4)
114ref char current = ref MemoryMarshal.GetReference(span); 120ref char end = ref Unsafe.Add(ref MemoryMarshal.GetReference(span), (uint)(span.Length - hashLength)); 129ref string[]? bucketsRef = ref MemoryMarshal.GetArrayDataReference(_buckets); 137int startOffset = (int)((nuint)Unsafe.ByteOffset(ref MemoryMarshal.GetReference(span), ref current) / sizeof(char));
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\Helpers\StringSearchValuesHelper.cs (2)
23ValidateReadPosition(MemoryMarshal.CreateReadOnlySpan(ref searchSpaceStart, searchSpaceLength), ref searchSpace, offset); 31nint currentByteOffset = Unsafe.ByteOffset(ref MemoryMarshal.GetReference(span), ref searchSpace);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\SingleStringSearchValuesPackedThreeChars.cs (1)
79IndexOf(ref MemoryMarshal.GetReference(span), span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SearchValues\Strings\SingleStringSearchValuesThreeChars.cs (1)
74IndexOf(ref MemoryMarshal.GetReference(span), span.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Span.cs (2)
52_reference = ref MemoryMarshal.GetArrayDataReference(array); 89_reference = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(array), (nint)(uint)start /* force zero-extension */);
src\runtime\src\libraries\System.Private.CoreLib\src\System\SpanHelpers.BinarySearch.cs (1)
20return BinarySearch(ref MemoryMarshal.GetReference(span), span.Length, comparable);
src\runtime\src\libraries\System.Private.CoreLib\src\System\String.Comparison.cs (6)
349=> SpanHelpers.SequenceCompareTo(ref MemoryMarshal.GetReference(strA), strA.Length, ref MemoryMarshal.GetReference(strB), strB.Length); 717return Marvin.ComputeHash32(ref Unsafe.As<char, byte>(ref MemoryMarshal.GetReference(value)), (uint)value.Length * 2 /* in bytes, not chars */, (uint)seed, (uint)(seed >> 32)); 750return Marvin.ComputeHash32OrdinalIgnoreCase(ref MemoryMarshal.GetReference(value), value.Length /* in chars, not bytes */, (uint)seed, (uint)(seed >> 32)); 804fixed (char* src = &MemoryMarshal.GetReference(span)) 915fixed (char* src = &MemoryMarshal.GetReference(span))
src\runtime\src\libraries\System.Private.CoreLib\src\System\String.cs (6)
86source: ref MemoryMarshal.GetArrayDataReference(value)); 112source: ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(value), startIndex)); 317Buffer.Memmove(ref result._firstChar, ref MemoryMarshal.GetReference(value), (uint)value.Length); 427destination: ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(destination), destinationIndex), 472destination: ref MemoryMarshal.GetArrayDataReference(chars), 496destination: ref MemoryMarshal.GetArrayDataReference(chars),
src\runtime\src\libraries\System.Private.CoreLib\src\System\String.Manipulation.cs (3)
2104ref char source = ref MemoryMarshal.GetReference(sourceSpan); 2473fixed (char* pTrimChars = &MemoryMarshal.GetReference(trimChars)) 2540fixed (char* pTrimChars = &MemoryMarshal.GetReference(trimChars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Ascii.CaseConversion.cs (15)
42=> ChangeCase<ushort, ushort, ToUpperConversion>(MemoryMarshal.Cast<char, ushort>(source), MemoryMarshal.Cast<char, ushort>(destination), out charsWritten); 54=> ChangeCase<byte, ushort, ToUpperConversion>(source, MemoryMarshal.Cast<char, ushort>(destination), out charsWritten); 66=> ChangeCase<ushort, byte, ToUpperConversion>(MemoryMarshal.Cast<char, ushort>(source), destination, out bytesWritten); 92=> ChangeCase<ushort, ushort, ToLowerConversion>(MemoryMarshal.Cast<char, ushort>(source), MemoryMarshal.Cast<char, ushort>(destination), out charsWritten); 104=> ChangeCase<byte, ushort, ToLowerConversion>(source, MemoryMarshal.Cast<char, ushort>(destination), out charsWritten); 116=> ChangeCase<ushort, byte, ToLowerConversion>(MemoryMarshal.Cast<char, ushort>(source), destination, out bytesWritten); 136=> ChangeCase<ushort, ToLowerConversion>(MemoryMarshal.Cast<char, ushort>(value), out charsWritten); 156=> ChangeCase<ushort, ToUpperConversion>(MemoryMarshal.Cast<char, ushort>(value), out charsWritten); 163if (MemoryMarshal.AsBytes(source).Overlaps(MemoryMarshal.AsBytes(destination))) 182fixed (TFrom* pSource = &MemoryMarshal.GetReference(source)) 183fixed (TTo* pDestination = &MemoryMarshal.GetReference(destination)) 197fixed (T* pBuffer = &MemoryMarshal.GetReference(buffer))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Ascii.cs (2)
22IsValidCore(ref MemoryMarshal.GetReference(value), value.Length); 32IsValidCore(ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(value)), value.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Ascii.Equality.cs (12)
26&& Equals<byte, byte, PlainLoader<byte>>(ref MemoryMarshal.GetReference(left), ref MemoryMarshal.GetReference(right), (uint)right.Length); 31&& Equals<byte, ushort, WideningLoader>(ref MemoryMarshal.GetReference(left), ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(right)), (uint)right.Length); 40&& Equals<ushort, ushort, PlainLoader<ushort>>(ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(left)), ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(right)), (uint)right.Length); 177&& EqualsIgnoreCase<byte, byte, PlainLoader<byte>>(ref MemoryMarshal.GetReference(left), ref MemoryMarshal.GetReference(right), (uint)right.Length); 182&& EqualsIgnoreCase<byte, ushort, WideningLoader>(ref MemoryMarshal.GetReference(left), ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(right)), (uint)right.Length); 191&& EqualsIgnoreCase<ushort, ushort, PlainLoader<ushort>>(ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(left)), ref Unsafe.As<char, ushort>(ref MemoryMarshal.GetReference(right)), (uint)right.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Ascii.Transcoding.cs (4)
36fixed (byte* pSource = &MemoryMarshal.GetReference(source)) 37fixed (char* pDestination = &MemoryMarshal.GetReference(destination)) 71fixed (char* pSource = &MemoryMarshal.GetReference(source)) 72fixed (byte* pDestination = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\ASCIIEncoding.cs (10)
145fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 319fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 320fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 329fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 330fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 487fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 610fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 611fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 620fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 621fixed (char* charsPtr = &MemoryMarshal.GetReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Decoder.cs (5)
113fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 199fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 200fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 305fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 306fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\DecoderNLS.cs (7)
62fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 107fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 108fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars)) 158fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 159fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars)) 207MemoryMarshal.AsBytes(new ReadOnlySpan<int>(in _leftoverBytes)).Slice(0, _leftoverByteCount); 211bytes.CopyTo(MemoryMarshal.AsBytes(new Span<int>(ref _leftoverBytes)));
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Encoder.cs (5)
111fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 196fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 197fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 304fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 305fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\EncoderNLS.cs (5)
58fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars)) 97fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars)) 98fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 144fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars)) 145fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Encoding.cs (7)
583fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 729fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 730fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 785fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 878fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes)) 879fixed (char* charsPtr = &MemoryMarshal.GetNonNullPinnableReference(chars)) 915fixed (byte* bytesPtr = &MemoryMarshal.GetNonNullPinnableReference(bytes))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Encoding.Internal.cs (18)
273pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)), 318fixed (char* _pChars_Unused = &MemoryMarshal.GetReference(chars)) 366pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)), 550pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)), 552pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 595fixed (char* _pChars_Unused = &MemoryMarshal.GetReference(chars)) 596fixed (byte* _pBytes_Unused = &MemoryMarshal.GetReference(bytes)) 653pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)), 655pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 873pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 918fixed (byte* _pBytes_Unused = &MemoryMarshal.GetReference(bytes)) 962pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 1153pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 1155pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)), 1196fixed (byte* _pBytes_Unused = &MemoryMarshal.GetReference(bytes)) 1197fixed (char* _pChars_Unused = &MemoryMarshal.GetReference(chars)) 1253pBytes: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(bytes)), 1255pChars: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(chars)),
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Latin1Encoding.cs (9)
84fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 231fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 232fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 241fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 242fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 526fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 527fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 538fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 539fixed (char* charsPtr = &MemoryMarshal.GetReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\StringBuilder.cs (8)
343ref MemoryMarshal.GetArrayDataReference(sourceArray), 1011ReplaceInPlaceAtChunk(ref chunk!, ref indexInChunk, ref MemoryMarshal.GetReference(value), value.Length); 1150Append(ref MemoryMarshal.GetArrayDataReference(value), value.Length); 1158Append(ref MemoryMarshal.GetReference(value), value.Length); 1416Insert(index, ref MemoryMarshal.GetArrayDataReference(value), value.Length); 1483Insert(index, ref MemoryMarshal.GetReference(value), value.Length); 2384ref char destination = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(chunkChars), chunkLength); 2490ReplaceInPlaceAtChunk(ref targetChunk!, ref targetIndexInChunk, ref MemoryMarshal.GetReference<char>(value), value.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Unicode\Utf16Utility.cs (1)
304fixed (char* pValue = &MemoryMarshal.GetReference(utf16Data))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Unicode\Utf8.cs (25)
47fixed (char* pOriginalSource = &MemoryMarshal.GetReference(source)) 48fixed (byte* pOriginalDestination = &MemoryMarshal.GetReference(destination)) 63pInputBuffer: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)), 65pOutputBuffer: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)), 93destination = destination.Slice((int)(pOutputBufferRemaining - (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)))); 108source = source.Slice((int)(pInputBufferRemaining - (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source))) + 1); 111pInputBufferRemaining = (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)); 112pOutputBufferRemaining = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)); 138fixed (byte* pOriginalSource = &MemoryMarshal.GetReference(source)) 139fixed (char* pOriginalDestination = &MemoryMarshal.GetReference(destination)) 154pInputBuffer: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)), 156pOutputBuffer: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)), 184destination = destination.Slice((int)(pOutputBufferRemaining - (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)))); 198source = source.Slice((int)(pInputBufferRemaining - (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)))); 205pInputBufferRemaining = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)); 206pOutputBufferRemaining = (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)); 233fixed (byte* pOriginalSource = &MemoryMarshal.GetReference(source)) 234fixed (char* pOriginalDestination = &MemoryMarshal.GetReference(destination)) 249pInputBuffer: (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)), 251pOutputBuffer: (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)), 283source = source.Slice((int)(pInputBufferRemaining - (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)))); 284destination = destination.Slice((int)(pOutputBufferRemaining - (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)))); 305pInputBufferRemaining = (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(source)); 306pOutputBufferRemaining = (char*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(destination)); 408ref MemoryMarshal.GetReference(dest), dest.Length);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\Unicode\Utf8Utility.cs (1)
30fixed (byte* pUtf8Data = &MemoryMarshal.GetReference(utf8Data))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\UnicodeEncoding.cs (3)
158fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 201fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 293fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\UTF32Encoding.cs (3)
166fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 209fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 301fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\UTF7Encoding.cs (3)
202fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 245fixed (byte* pBytes = &MemoryMarshal.GetArrayDataReference(bytes)) 337fixed (char* pChars = &MemoryMarshal.GetArrayDataReference(chars))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Text\UTF8Encoding.cs (10)
194fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 365fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 366fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 375fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 376fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 487fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 560fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 561fixed (char* charsPtr = &MemoryMarshal.GetReference(chars)) 570fixed (byte* bytesPtr = &MemoryMarshal.GetReference(bytes)) 571fixed (char* charsPtr = &MemoryMarshal.GetReference(chars))
System\Array.NativeAot.cs (3)
268ref byte arrayRef = ref MemoryMarshal.GetArrayDataReference(this); 386ref byte element = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(this), (nuint)flattenedIndex * ElementSize); 404ref byte element = ref Unsafe.AddByteOffset(ref MemoryMarshal.GetArrayDataReference(this), (nuint)flattenedIndex * ElementSize);
System\Reflection\EnumInfo.cs (1)
48return MemoryMarshal.Cast<TStorage, TResult>(Values).ToArray();
System\Runtime\InteropServices\PInvokeMarshal.cs (1)
550ReadOnlySpan<byte> span = MemoryMarshal.CreateReadOnlySpanFromNullTerminated(pchBuffer);
System.Private.DataContractSerialization (16)
System\Xml\XmlBinaryWriter.cs (11)
110ref byte bytePtr = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(buffer), offset); 125ref byte bytePtr = ref Unsafe.Add(ref MemoryMarshal.GetArrayDataReference(buffer), offset); 609fixed (char* pch = &MemoryMarshal.GetReference(chars)) 862WriteArray(XmlBinaryNodeType.BoolTextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 869WriteArray(XmlBinaryNodeType.Int16TextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 885WriteArray(XmlBinaryNodeType.Int32TextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 901WriteArray(XmlBinaryNodeType.Int64TextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 917WriteArray(XmlBinaryNodeType.FloatTextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 935WriteArray(XmlBinaryNodeType.DoubleTextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 953WriteArray(XmlBinaryNodeType.DecimalTextWithEndElement, items.Length, MemoryMarshal.AsBytes(items)); 987WriteArray(XmlBinaryNodeType.GuidTextWithEndElement, items.Length, MemoryMarshal.AsBytes(items));
System\Xml\XmlBufferReader.cs (3)
488ReadRawArrayBytes(MemoryMarshal.AsBytes(dst)); 942T value = MemoryMarshal.Read<T>(buffer); 949=> MemoryMarshal.Read<T>(_buffer.AsSpan(offset, sizeof(T)));
System\Xml\XmlStreamNodeWriter.cs (2)
341.CopyTo(MemoryMarshal.Cast<byte, char>(buffer.AsSpan(offset))); 346MemoryMarshal.Cast<byte, short>(buffer.AsSpan(offset)));
System.Private.StackTraceMetadata (1)
Internal\StackTraceMetadata\StackTraceMetadata.cs (1)
178string documentName = System.Text.Encoding.UTF8.GetString(MemoryMarshal.CreateReadOnlySpanFromNullTerminated(documentAddress));
System.Private.Uri (4)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\PercentEncodingHelper.cs (1)
87if (Rune.DecodeFromUtf8(MemoryMarshal.AsBytes(new ReadOnlySpan<uint>(ref temp))[..bytesLeftInBuffer], out Rune rune, out bytesConsumed) == OperationStatus.Done)
System\UriExt.cs (2)
563!Unsafe.AreSame(ref MemoryMarshal.GetReference(charsToUnescape), ref MemoryMarshal.GetReference(destination));
System.Private.Windows.Core (64)
_generated\12\Windows.Win32.byte.InlineArrays.g.cs (2)
43 internal unsafe Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<byte> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
_generated\123\Windows.Win32.IAdviseSink.g.cs (1)
264 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\124\Windows.Win32.IBindCtx.g.cs (1)
479 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\127\Windows.Win32.IDataObject.g.cs (1)
531 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\128\Windows.Win32.IDataObjectAsyncCapability.g.cs (1)
317 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\129\Windows.Win32.IDispatch.g.cs (1)
219 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\130\Windows.Win32.IDispatchEx.g.cs (1)
429 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\133\Windows.Win32.IDragSourceHelper.g.cs (1)
202 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\134\Windows.Win32.IDragSourceHelper2.g.cs (1)
211 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\135\Windows.Win32.IDropSource.g.cs (1)
173 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\136\Windows.Win32.IDropSourceNotify.g.cs (1)
165 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\137\Windows.Win32.IDropTarget.g.cs (1)
291 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\138\Windows.Win32.IDropTargetHelper.g.cs (1)
333 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\139\Windows.Win32.IEnumFORMATETC.g.cs (1)
249 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\140\Windows.Win32.IEnumMoniker.g.cs (1)
239 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\141\Windows.Win32.IEnumSTATDATA.g.cs (1)
249 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\142\Windows.Win32.IEnumSTATSTG.g.cs (1)
259 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\143\Windows.Win32.IEnumString.g.cs (1)
246 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\144\Windows.Win32.IEnumUnknown.g.cs (1)
236 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\145\Windows.Win32.IGlobalInterfaceTable.g.cs (1)
239 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\148\Windows.Win32.IMoniker.g.cs (1)
940 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\152\Windows.Win32.IPersist.g.cs (1)
144 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\153\Windows.Win32.IPersistStream.g.cs (1)
294 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\154\Windows.Win32.IPicture.g.cs (1)
733 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\155\Windows.Win32.IPictureDisp.g.cs (1)
166 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\156\Windows.Win32.IRecordInfo.g.cs (1)
792 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\157\Windows.Win32.IRunningObjectTable.g.cs (1)
397 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\158\Windows.Win32.ISequentialStream.g.cs (1)
179 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\159\Windows.Win32.IServiceProvider.g.cs (1)
147 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\160\Windows.Win32.IStorage.g.cs (1)
860 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\161\Windows.Win32.IStream.g.cs (1)
518 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\162\Windows.Win32.ITypeComp.g.cs (1)
196 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\163\Windows.Win32.ITypeInfo.g.cs (1)
992 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\164\Windows.Win32.ITypeLib.g.cs (1)
546 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\165\Windows.Win32.IUnknown.g.cs (1)
119 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\268\Windows.Win32.VariableLengthInlineArray.g.cs (1)
40 return MemoryMarshal.CreateSpan(ref this.e0, length);
_generated\37\Windows.Win32.char.InlineArrays.g.cs (4)
44 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 53 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 108 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 117 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
System\BufferScope.cs (1)
109public readonly ref T GetPinnableReference() => ref MemoryMarshal.GetReference(_span);
System\IO\BinaryReaderExtensions.cs (5)
134Span<ushort> ushorts = MemoryMarshal.Cast<byte, ushort>(arrayData); 139Span<int> ints = MemoryMarshal.Cast<byte, int>(arrayData); 144Span<long> longs = MemoryMarshal.Cast<byte, long>(arrayData); 262writer.Write(MemoryMarshal.Cast<T, char>(span)); 268writer.Write(MemoryMarshal.Cast<T, byte>(span));
System\SpanReader.cs (8)
144value = Unsafe.ReadUnaligned<TValue>(ref Unsafe.As<T, byte>(ref MemoryMarshal.GetReference(_unread))); 157/// This effectively does a <see cref="MemoryMarshal.Cast{TFrom, TTo}(ReadOnlySpan{TFrom})"/> and the same 182value = MemoryMarshal.CreateReadOnlySpan(ref Unsafe.As<T, TValue>(ref MemoryMarshal.GetReference(_unread)), count); 271span = MemoryMarshal.CreateReadOnlySpan(ref MemoryMarshal.GetReference(span), length); 282span = MemoryMarshal.CreateReadOnlySpan(ref Unsafe.Add(ref MemoryMarshal.GetReference(span), (nint)(uint)start), length);
System\SpanWriter.cs (2)
103span = MemoryMarshal.CreateSpan(ref Unsafe.Add(ref MemoryMarshal.GetReference(span), (nint)(uint)start), length);
System\Text\ValueStringBuilder.cs (2)
78public readonly ref char GetPinnableReference() => ref MemoryMarshal.GetReference(_chars); 92return ref MemoryMarshal.GetReference(_chars);
Windows\Win32\Foundation\GlobalBuffer.cs (1)
50public readonly Span<char> AsCharSpan() => MemoryMarshal.Cast<byte, char>(_buffer);
Windows\Win32\Graphics\Gdi\ARGB.cs (1)
57ToColorArray(MemoryMarshal.Cast<uint, ARGB>(argbColors));
Windows\Win32\System\Com\IComCallableWrapper.cs (1)
25return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Windows\Win32\System\Com\IID.cs (1)
18return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Windows\Win32\System\Variant\VARIANT.cs (1)
876=> MemoryMarshal.CreateSpan(ref Unsafe.AsRef<T>(Marshal.UnsafeAddrOfPinnedArrayElement(array, 0).ToPointer()), array.Length);
System.Private.Windows.GdiPlus (2)
_generated\25\Windows.Win32.float.InlineArrays.g.cs (2)
43 internal unsafe Span<float> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<float> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
System.Private.Xml (3)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Xml\BinaryXml\XmlBinaryReader.cs (1)
2335Span<byte> dstBytes = MemoryMarshal.AsBytes(dstChars);
System\Xml\XmlCharType.cs (1)
186private static uint GetCharProperties(char ch) => Unsafe.Add(ref MemoryMarshal.GetReference(CharProperties), ch);
System.Reflection.Metadata (4)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Reflection\Metadata\BlobBuilder.cs (1)
1009WriteBytesUnchecked(MemoryMarshal.AsBytes(value));
System\Reflection\Metadata\BlobWriter.cs (1)
401WriteBytes(MemoryMarshal.AsBytes(value));
System\Reflection\Metadata\Ecma335\MetadataBuilder.Heaps.cs (1)
280return GetOrAddBlob(MemoryMarshal.AsBytes(value.AsSpan()));
System.Resources.Extensions (1)
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\PinnedBufferMemoryStream.cs (1)
26fixed (byte* ptr = &MemoryMarshal.GetReference((Span<byte>)array))
System.Runtime (1)
src\runtime\artifacts\obj\System.Runtime\Release\net11.0\System.Runtime.Forwards.cs (1)
693[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.MemoryMarshal))]
System.Runtime.InteropServices.JavaScript (8)
System\Runtime\InteropServices\JavaScript\Marshaling\JSMarshalerArgument.Byte.cs (2)
126var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(array)); 146var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(value.Array));
System\Runtime\InteropServices\JavaScript\Marshaling\JSMarshalerArgument.Double.cs (2)
132var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(array)); 152var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(value.Array));
System\Runtime\InteropServices\JavaScript\Marshaling\JSMarshalerArgument.Int32.cs (2)
126var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(array)); 146var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(value.Array));
System\Runtime\InteropServices\JavaScript\Marshaling\JSMarshalerArgument.Single.cs (2)
132var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(array)); 152var refPtr = (IntPtr)Unsafe.AsPointer(ref MemoryMarshal.GetArrayDataReference(value.Array));
System.Runtime.Numerics (40)
src\runtime\src\libraries\Common\src\System\Number.Formatting.Common.cs (5)
328fixed (char* pFormat = &MemoryMarshal.GetReference(format)) 527fixed (char* pFormat = &MemoryMarshal.GetReference(format)) 793fixed (TChar* spanPtr = &MemoryMarshal.GetReference(vlb.AppendSpan(bufferSize))) 880r.EncodeToUtf8(MemoryMarshal.AsBytes(vlb.AppendSpan(r.Utf8SequenceLength))); 1135fixed (char* pFormat = &MemoryMarshal.GetReference(format))
src\runtime\src\libraries\Common\src\System\Number.NumberBuffer.cs (1)
33public readonly byte* DigitsPtr => (byte*)Unsafe.AsPointer(ref MemoryMarshal.GetReference(Digits)); // safe since constructor expects Digits to refer to unmovable memory
src\runtime\src\libraries\Common\src\System\Number.Parsing.Common.cs (2)
285fixed (TChar* stringPointer = &MemoryMarshal.GetReference(value)) 344fixed (TChar* stringPointer = &MemoryMarshal.GetReference(value))
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder_1.cs (2)
70return ref MemoryMarshal.GetReference(_chars); 84return ref MemoryMarshal.GetReference(_chars);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\Text\FormattingHelpers.CountDigits.cs (1)
55ulong powerOf10 = Unsafe.Add(ref MemoryMarshal.GetReference(powersOf10), elementOffset);
System\Number.BigInteger.cs (9)
29? MemoryMarshal.Cast<ulong, nuint>(UInt64PowersOfTen) 30: MemoryMarshal.Cast<uint, nuint>(UInt32PowersOfTenCore); 862fixed (TChar* ptr = &MemoryMarshal.GetReference(destination)) 892fixed (char* ptr = &MemoryMarshal.GetReference(span)) 1231? MemoryMarshal.Cast<ulong, nuint>(LeadingPowers1E9_64) 1232: MemoryMarshal.Cast<uint, nuint>(LeadingPowers1E9_32); 1582? (Convert.FromHexString(Unsafe.BitCast<ReadOnlySpan<TChar>, ReadOnlySpan<byte>>(input), MemoryMarshal.AsBytes(destination), out _, out _) != OperationStatus.Done) 1583: (Convert.FromHexString(Unsafe.BitCast<ReadOnlySpan<TChar>, ReadOnlySpan<char>>(input), MemoryMarshal.AsBytes(destination), out _, out _) != OperationStatus.Done)) 1590MemoryMarshal.AsBytes(destination).Reverse();
System\Numerics\BigInteger.cs (12)
417Span<byte> limbBytes = MemoryMarshal.AsBytes(val.AsSpan(0, wholeLimbCount)); 428value.Slice(0, wholeLimbCount * nint.Size).CopyTo(MemoryMarshal.AsBytes(val.AsSpan())); 831return Number.ParseBigInteger(MemoryMarshal.Cast<char, Utf16Char>(value), style, NumberFormatInfo.GetInstance(provider)); 836return Number.ParseBigInteger(MemoryMarshal.Cast<byte, Utf8Char>(utf8Text), style, NumberFormatInfo.GetInstance(provider)); 846return Number.TryParseBigInteger(MemoryMarshal.Cast<char, Utf16Char>(value), style, NumberFormatInfo.GetInstance(provider), out result) == Number.ParsingStatus.OK; 856return Number.TryParseBigInteger(MemoryMarshal.Cast<byte, Utf8Char>(utf8Text), style, NumberFormatInfo.GetInstance(provider), out result) == Number.ParsingStatus.OK; 1223hash.AddBytes(MemoryMarshal.AsBytes(_bits.AsSpan())); 1646ReadOnlySpan<byte> srcBytes = MemoryMarshal.AsBytes(bits.AsSpan(..^1)); 1863return Number.TryFormatBigInteger(this, format, NumberFormatInfo.GetInstance(provider), MemoryMarshal.Cast<char, Utf16Char>(destination), out charsWritten); 1868return Number.TryFormatBigInteger(this, format, NumberFormatInfo.GetInstance(provider), MemoryMarshal.Cast<byte, Utf8Char>(utf8Destination), out bytesWritten); 3432Span<uint> words = MemoryMarshal.Cast<nuint, uint>(zd).Slice(0, zWordCount); 3457Span<uint> words = MemoryMarshal.Cast<nuint, uint>(zd).Slice(0, zWordCount);
System\Numerics\BigIntegerCalculator.GcdInv.cs (2)
420Span<uint> x32 = MemoryMarshal.Cast<nuint, uint>(x); 421Span<uint> y32 = MemoryMarshal.Cast<nuint, uint>(y);
System\Numerics\BigIntegerCalculator.ShiftRot.cs (2)
122Span<uint> tmp = MemoryMarshal.Cast<nuint, uint>(tmpNuint).Slice(0, tmpLength); 156ref nuint start = ref MemoryMarshal.GetReference(bits);
System\Numerics\Complex.cs (4)
2133=> TryParse(MemoryMarshal.Cast<char, Utf16Char>(s), style, provider, out result); 2137=> TryParse(MemoryMarshal.Cast<byte, Utf8Char>(utf8Text), style, provider, out result); 2262TryFormat(MemoryMarshal.Cast<char, Utf16Char>(destination), out charsWritten, format, provider); 2266TryFormat(MemoryMarshal.Cast<byte, Utf8Char>(utf8Destination), out bytesWritten, format, provider);
System.Security.Cryptography (54)
Microsoft\Win32\SafeHandles\SafePasswordHandle.cs (1)
40if (!Unsafe.IsNullRef(ref MemoryMarshal.GetReference(password)))
src\runtime\src\libraries\Common\src\Interop\Windows\Advapi32\Interop.CryptGetProvParam.cs (1)
68fixed (byte* bytePtr = &MemoryMarshal.GetReference(pbData))
src\runtime\src\libraries\Common\src\Interop\Windows\BCrypt\Interop.BCryptEncryptDecrypt.RSA.cs (4)
70fixed (byte* pSource = &MemoryMarshal.GetReference(effectiveSource)) 71fixed (byte* pDest = &MemoryMarshal.GetReference(destination)) 105fixed (byte* pSource = &MemoryMarshal.GetReference(source)) 106fixed (byte* pDest = &MemoryMarshal.GetReference(destination))
src\runtime\src\libraries\Common\src\Interop\Windows\BCrypt\Interop.BCryptSignHash.cs (7)
34fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 60fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 88fixed (byte* pData = &MemoryMarshal.GetReference(data)) 90fixed (byte* pContext = &MemoryMarshal.GetReference(context)) 125fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 126fixed (byte* pDest = &MemoryMarshal.GetReference(destination)) 127fixed (byte* pContext = &MemoryMarshal.GetReference(context))
src\runtime\src\libraries\Common\src\Interop\Windows\BCrypt\Interop.BCryptVerifySignature.cs (9)
41fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 42fixed (byte* pSignature = &MemoryMarshal.GetReference(signature)) 70fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 71fixed (byte* pSignature = &MemoryMarshal.GetReference(signature)) 99fixed (byte* pSignature = &MemoryMarshal.GetReference(signature)) 100fixed (byte* pContext = &MemoryMarshal.GetReference(context)) 128fixed (byte* pHash = &MemoryMarshal.GetReference(hash)) 129fixed (byte* pSignature = &MemoryMarshal.GetReference(signature)) 130fixed (byte* pContext = &MemoryMarshal.GetReference(context))
src\runtime\src\libraries\Common\src\Interop\Windows\NCrypt\Interop.NCryptDeriveKeyMaterial.cs (1)
136fixed (NCryptBuffer* pParameters = &MemoryMarshal.GetReference(parameters))
src\runtime\src\libraries\Common\src\Microsoft\Win32\SafeHandles\SafeUnicodeStringHandle.cs (1)
32if (!Unsafe.IsNullRef(ref MemoryMarshal.GetReference(s)))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\CngHelpers.cs (5)
192ref MemoryMarshal.GetReference(empty), 213ref MemoryMarshal.GetReference(destination), 239fixed (byte* oidPtr = &MemoryMarshal.GetReference(pkcs12TripleDesOidBytes)) 289ref MemoryMarshal.GetReference(empty), 317ref MemoryMarshal.GetReference(destination),
src\runtime\src\libraries\Common\src\System\Security\Cryptography\ECCng.ImportExport.NamedCurve.cs (2)
94KeyBlobMagicNumber magic = (KeyBlobMagicNumber)MemoryMarshal.Cast<byte, int>(ecBlob)[0]; 175ref MemoryMarshal.GetReference(keyBlob),
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Helpers.cs (1)
83return Unsafe.IsNullRef(ref MemoryMarshal.GetReference(span));
src\runtime\src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (2)
224fixed (byte* maybeRentedPtr = &MemoryMarshal.GetReference(buf)) 509fixed (byte* maybeRentedPtr = &MemoryMarshal.GetReference(buf))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs12Kdf.cs (1)
127if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(password)))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\PqcBlobHelpers.cs (4)
131ref BCRYPT_PQDSA_KEY_BLOB blobHeader = ref MemoryMarshal.Cast<byte, BCRYPT_PQDSA_KEY_BLOB>(blobBytes)[0]; 138Span<char> blobBodyChars = MemoryMarshal.Cast<byte, char>(blobBytes.Slice(index)); 166ref readonly BCRYPT_PQDSA_KEY_BLOB blob = ref MemoryMarshal.Cast<byte, BCRYPT_PQDSA_KEY_BLOB>(blobBytes)[0]; 172parameterSet = MemoryMarshal.Cast<byte, char>(blobBytes.Slice(index, parameterSetLength));
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Security\Cryptography\BasicSymmetricCipherLiteNCrypt.cs (1)
121fixed (byte* pIv = &MemoryMarshal.GetReference(iv))
System\Security\Cryptography\CngKey.Import.cs (2)
86ref MemoryMarshal.GetReference(keyBlob), 137ref MemoryMarshal.GetReference(keyBlob),
System\Security\Cryptography\CryptoStream.cs (2)
378if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> bufferArray)) 651if (MemoryMarshal.TryGetArray(inputBuffer, out ArraySegment<byte> segment))
System\Security\Cryptography\HashProviderDispenser.Windows.cs (2)
275fixed (byte* pKey = &MemoryMarshal.GetReference(key)) 276fixed (byte* pSrc = &MemoryMarshal.GetReference(source))
System\Security\Cryptography\Helpers.cs (2)
370return ref buffer.Length != 0 ? ref MemoryMarshal.GetReference(buffer) : ref Unsafe.AsRef<byte>((void*)1); 377return ref buffer.Length != 0 ? ref MemoryMarshal.GetReference(buffer) : ref Unsafe.AsRef<byte>((void*)1);
System\Security\Cryptography\RandomNumberGenerator.cs (1)
129Span<byte> oneUintBytes = MemoryMarshal.AsBytes(new Span<uint>(ref oneUint));
System\Security\Cryptography\X509Certificates\CertificatePal.Windows.cs (1)
302fixed (char* ptr = &MemoryMarshal.GetReference(buffer))
System\Security\Cryptography\X509Certificates\FindPal.Windows.cs (1)
136ReadOnlySpan<char> actual = MemoryMarshal.CreateReadOnlySpanFromNullTerminated((char*)pNameValue->Value.pbData);
System\Security\Cryptography\X509Certificates\WindowsInterop.crypt32.cs (1)
33fixed (char* ptr = &MemoryMarshal.GetReference(buffer))
System\Security\Cryptography\X509Certificates\X509CertificateLoader.Windows.cs (1)
266CryptographicOperations.ZeroMemory(MemoryMarshal.AsBytes(szPassword));
System.Security.Cryptography.Cose (2)
System\Security\Cryptography\Cose\CoseMessage.cs (2)
110fixed (byte* ptr = &MemoryMarshal.GetReference(cborPayload)) 195fixed (byte* ptr = &MemoryMarshal.GetReference(cborPayload))
System.Security.Cryptography.Pkcs (8)
Internal\Cryptography\Pal\Windows\DecryptorPalWindows.Decode.cs (1)
37ref MemoryMarshal.GetReference(encodedMessage),
Internal\Cryptography\Pal\Windows\HelpersWindows.cs (1)
466fixed (byte* asciiPtr = &MemoryMarshal.GetReference(buf))
Internal\Cryptography\Pal\Windows\PkcsPalWindows.cs (1)
36if (!Interop.Crypt32.CryptMsgUpdate(hCryptMsg, ref MemoryMarshal.GetReference(encodedMessage), encodedMessage.Length, fFinal: true))
src\runtime\src\libraries\Common\src\Interop\Windows\Advapi32\Interop.CryptGetProvParam.cs (1)
68fixed (byte* bytePtr = &MemoryMarshal.GetReference(pbData))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Helpers.cs (1)
83return Unsafe.IsNullRef(ref MemoryMarshal.GetReference(span));
src\runtime\src\libraries\Common\src\System\Security\Cryptography\PasswordBasedEncryption.cs (2)
224fixed (byte* maybeRentedPtr = &MemoryMarshal.GetReference(buf)) 509fixed (byte* maybeRentedPtr = &MemoryMarshal.GetReference(buf))
src\runtime\src\libraries\Common\src\System\Security\Cryptography\Pkcs12Kdf.cs (1)
127if (Unsafe.IsNullRef(ref MemoryMarshal.GetReference(password)))
System.ServiceModel.NetFramingBase (1)
System\ServiceModel\Channels\SingletonConnectionReader.cs (1)
533if (MemoryMarshal.TryGetArray(buffer, out ArraySegment<byte> array))
System.ServiceModel.NetTcp (1)
System\ServiceModel\Channels\SocketAwaitableEventArgs.cs (1)
50SetBuffer(MemoryMarshal.AsMemory(memory));
System.ServiceModel.UnixDomainSocket (1)
System\ServiceModel\Channels\SocketAwaitableEventArgs.cs (1)
50SetBuffer(MemoryMarshal.AsMemory(memory));
System.ServiceProcess.ServiceController (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.Text.Encoding.CodePages (1)
System\Text\CodePagesEncodingProvider.cs (1)
201MemoryMarshal.GetArrayDataReference(array);
System.Text.Encodings.Web (3)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Text\Encodings\Web\TextEncoder.cs (2)
44fixed (char* pBuffer = &MemoryMarshal.GetReference(buffer)) 543fixed (char* pText = &MemoryMarshal.GetReference(text))
System.Text.Json (16)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Marvin.cs (1)
23public static int ComputeHash32(ReadOnlySpan<byte> data, ulong seed) => ComputeHash32(ref MemoryMarshal.GetReference(data), (uint)data.Length, (uint)seed, (uint)(seed >> 32));
System\Text\Json\Document\JsonDocument.MetadataDb.cs (10)
229MemoryMarshal.Write(_data.AsSpan(Length), ref row); 272MemoryMarshal.Write(destination, ref length); 281int current = MemoryMarshal.Read<int>(dataPos); 285MemoryMarshal.Write(dataPos, ref value); 294int current = MemoryMarshal.Read<int>(dataPos); 297MemoryMarshal.Write(dataPos, ref value); 312DbRow row = MemoryMarshal.Read<DbRow>(data.Slice(i)); 328return MemoryMarshal.Read<DbRow>(_data.AsSpan(index)); 334uint union = MemoryMarshal.Read<uint>(_data.AsSpan(index + NumberOfRowsOffset)); 377Span<int> newDbInts = MemoryMarshal.Cast<byte, int>(newDatabase.AsSpan());
System\Text\Json\Document\JsonDocument.StackRowStack.cs (2)
50MemoryMarshal.Write(_rentedBuffer.AsSpan(_topOfStack), ref row); 58StackRow row = MemoryMarshal.Read<StackRow>(_rentedBuffer.AsSpan(_topOfStack));
System\Text\Json\Writer\Utf8JsonWriter.cs (2)
162return MemoryMarshal.Cast<byte, char>(partialStringDataBytes.Slice(0, length)); 170value.CopyTo(MemoryMarshal.Cast<byte, char>(partialStringDataBytes));
System.Text.RegularExpressions (3)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System\Text\RegularExpressions\RegexCompiler.cs (1)
106private static MethodInfo MemoryMarshalGetArrayDataReferenceSearchValuesMethod => field ??= typeof(MemoryMarshal).GetMethod("GetArrayDataReference", [Type.MakeGenericMethodParameter(0).MakeArrayType()])!.MakeGenericMethod(typeof(SearchValues<char>))!;
System\Text\RegularExpressions\Symbolic\BitVector.cs (1)
178hc.AddBytes(MemoryMarshal.AsBytes<ulong>(_blocks));
System.Text.RegularExpressions.Generator (3)
src\runtime\src\libraries\Common\src\Polyfills\EncodingPolyfills.cs (1)
79return ref buffer.Length != 0 ? ref MemoryMarshal.GetReference(buffer) : ref Unsafe.AsRef<T>((void*)1);
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
Stubs.cs (1)
20fixed (char* ptr = &MemoryMarshal.GetReference(span))
System.Web.HttpUtility (1)
src\runtime\src\libraries\Common\src\System\Text\ValueStringBuilder.cs (1)
75return ref MemoryMarshal.GetReference(_chars);
System.Windows.Forms (2)
System\Windows\Forms\Dialogs\CommonDialogs\ColorDialog.cs (2)
77MemoryMarshal.Cast<COLORREF, int>(_customColors).CopyTo(result); 87MemoryMarshal.Cast<int, COLORREF>(value)[..Math.Min(customColors.Length, value.Length)].CopyTo(customColors);
System.Windows.Forms.Primitives (185)
_generated\106\Windows.Win32.IAccessible.g.cs (1)
1248 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\107\Windows.Win32.IAccessibleEx.g.cs (1)
271 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\108\Windows.Win32.IAdviseSinkEx.g.cs (1)
270 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\109\Windows.Win32.IAutoComplete.g.cs (1)
198 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\110\Windows.Win32.IAutoComplete2.g.cs (1)
251 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\111\Windows.Win32.IBindHost.g.cs (1)
205 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\112\Windows.Win32.IBinding.g.cs (1)
292 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\113\Windows.Win32.IBindStatusCallback.g.cs (1)
381 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\114\Windows.Win32.IClassFactory.g.cs (1)
186 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\115\Windows.Win32.IClassFactory2.g.cs (1)
309 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\117\Windows.Win32.IConnectionPoint.g.cs (1)
303 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\118\Windows.Win32.IConnectionPointContainer.g.cs (1)
185 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\119\Windows.Win32.IEnumConnectionPoints.g.cs (1)
246 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\12\Windows.Win32.byte.InlineArrays.g.cs (4)
43 internal unsafe Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<byte> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 89 internal unsafe Span<byte> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 98 internal unsafe readonly ReadOnlySpan<byte> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
_generated\120\Windows.Win32.IEnumConnections.g.cs (1)
250 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\121\Windows.Win32.IEnumIDList.g.cs (1)
259 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\122\Windows.Win32.IEnumOleUndoUnits.g.cs (1)
251 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\123\Windows.Win32.IEnumOLEVERB.g.cs (1)
249 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\124\Windows.Win32.IEnumShellItems.g.cs (1)
259 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\125\Windows.Win32.IEnumVARIANT.g.cs (1)
256 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\126\Windows.Win32.IErrorInfo.g.cs (1)
279 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\127\Windows.Win32.IErrorLog.g.cs (1)
142 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\128\Windows.Win32.IExpandCollapseProvider.g.cs (1)
206 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\129\Windows.Win32.IFileDialog.g.cs (1)
1124 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\130\Windows.Win32.IFileDialogCustomize.g.cs (1)
1373 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\131\Windows.Win32.IFileDialogEvents.g.cs (1)
406 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\132\Windows.Win32.IFileOpenDialog.g.cs (1)
947 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\133\Windows.Win32.IFileOperationProgressSink.g.cs (1)
913 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\134\Windows.Win32.IFileSaveDialog.g.cs (1)
1082 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\135\Windows.Win32.IFont.g.cs (1)
979 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\136\Windows.Win32.IFontDisp.g.cs (1)
163 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\137\Windows.Win32.IGetOleObject.g.cs (1)
150 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\138\Windows.Win32.IGetVBAObject.g.cs (1)
150 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\139\Windows.Win32.IGridItemProvider.g.cs (1)
298 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\140\Windows.Win32.IGridProvider.g.cs (1)
232 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\141\Windows.Win32.IHTMLCurrentStyle.g.cs (1)
3252 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\142\Windows.Win32.IHTMLDataTransfer.g.cs (1)
386 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\143\Windows.Win32.IHTMLDocument.g.cs (1)
190 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\144\Windows.Win32.IHTMLDocument2.g.cs (1)
3532 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\145\Windows.Win32.IHTMLDocument3.g.cs (1)
1428 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\146\Windows.Win32.IHTMLDocument4.g.cs (1)
623 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\147\Windows.Win32.IHTMLDOMNode.g.cs (1)
786 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\148\Windows.Win32.IHTMLElement.g.cs (1)
2840 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\149\Windows.Win32.IHTMLElement2.g.cs (1)
3246 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\150\Windows.Win32.IHTMLElement3.g.cs (1)
1526 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\151\Windows.Win32.IHTMLElementCollection.g.cs (1)
354 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\152\Windows.Win32.IHTMLEventObj.g.cs (1)
994 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\153\Windows.Win32.IHTMLFiltersCollection.g.cs (1)
270 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\154\Windows.Win32.IHTMLFormElement.g.cs (1)
904 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\155\Windows.Win32.IHTMLFrameBase.g.cs (1)
720 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\156\Windows.Win32.IHTMLFramesCollection2.g.cs (1)
241 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\157\Windows.Win32.IHTMLImageElementFactory.g.cs (1)
192 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\158\Windows.Win32.IHTMLImgElement.g.cs (1)
1680 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\159\Windows.Win32.IHTMLLocation.g.cs (1)
770 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\160\Windows.Win32.IHTMLMimeTypesCollection.g.cs (1)
196 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\161\Windows.Win32.IHTMLOpsProfile.g.cs (1)
426 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\162\Windows.Win32.IHTMLOptionElement.g.cs (1)
506 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\163\Windows.Win32.IHTMLOptionElementFactory.g.cs (1)
192 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\164\Windows.Win32.IHTMLPluginsCollection.g.cs (1)
224 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\165\Windows.Win32.IHTMLRect.g.cs (1)
410 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\166\Windows.Win32.IHTMLRectCollection.g.cs (1)
270 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\167\Windows.Win32.IHTMLRenderStyle.g.cs (1)
720 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\168\Windows.Win32.IHTMLRuleStyle.g.cs (1)
5182 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\169\Windows.Win32.IHTMLScreen.g.cs (1)
490 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\170\Windows.Win32.IHTMLSelectionObject.g.cs (1)
282 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\171\Windows.Win32.IHTMLStyle.g.cs (1)
5702 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\172\Windows.Win32.IHTMLStyleSheet.g.cs (1)
826 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\173\Windows.Win32.IHTMLStyleSheetRule.g.cs (1)
292 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\174\Windows.Win32.IHTMLStyleSheetRulesCollection.g.cs (1)
226 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\175\Windows.Win32.IHTMLStyleSheetsCollection.g.cs (1)
270 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\176\Windows.Win32.IHTMLWindow2.g.cs (1)
2363 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\177\Windows.Win32.IHTMLWindow3.g.cs (1)
619 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\178\Windows.Win32.IHTMLWindow4.g.cs (1)
230 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\179\Windows.Win32.IInvokeProvider.g.cs (1)
138 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\180\Windows.Win32.ILegacyIAccessibleProvider.g.cs (1)
612 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\181\Windows.Win32.ILockBytes.g.cs (1)
388 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\186\Windows.Win32.IMessageFilter.g.cs (1)
222 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\19\Windows.Win32.char.InlineArrays.g.cs (10)
44 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 53 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 108 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 117 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 172 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 181 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 236 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 245 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength); 300 internal unsafe Span<char> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 309 internal unsafe readonly ReadOnlySpan<char> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
_generated\190\Windows.Win32.IModalWindow.g.cs (1)
138 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\191\Windows.Win32.IMultipleViewProvider.g.cs (1)
263 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\196\Windows.Win32.int.InlineArrays.g.cs (2)
43 internal unsafe Span<int> AsSpan() => MemoryMarshal.CreateSpan(ref Value[0], SpanLength); 52 internal unsafe readonly ReadOnlySpan<int> AsReadOnlySpan() => MemoryMarshal.CreateReadOnlySpan(ref Unsafe.AsRef(in Value[0]), SpanLength);
_generated\198\Windows.Win32.IOleAdviseHolder.g.cs (1)
320 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\199\Windows.Win32.IOleClientSite.g.cs (1)
316 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\200\Windows.Win32.IOleCommandTarget.g.cs (1)
207 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\201\Windows.Win32.IOleContainer.g.cs (1)
206 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\202\Windows.Win32.IOleControl.g.cs (1)
264 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\203\Windows.Win32.IOleControlSite.g.cs (1)
367 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\204\Windows.Win32.IOleInPlaceActiveObject.g.cs (1)
362 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\205\Windows.Win32.IOleInPlaceFrame.g.cs (1)
576 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\206\Windows.Win32.IOleInPlaceObject.g.cs (1)
325 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\207\Windows.Win32.IOleInPlaceObjectWindowless.g.cs (1)
377 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\208\Windows.Win32.IOleInPlaceSite.g.cs (1)
569 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\209\Windows.Win32.IOleInPlaceUIWindow.g.cs (1)
360 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\210\Windows.Win32.IOleObject.g.cs (1)
986 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\211\Windows.Win32.IOleParentUndoUnit.g.cs (1)
404 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\212\Windows.Win32.IOleUndoManager.g.cs (1)
551 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\213\Windows.Win32.IOleUndoUnit.g.cs (1)
250 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\214\Windows.Win32.IOleWindow.g.cs (1)
186 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\215\Windows.Win32.IOmHistory.g.cs (1)
308 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\216\Windows.Win32.IOmNavigator.g.cs (1)
830 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\217\Windows.Win32.IParseDisplayName.g.cs (1)
148 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\218\Windows.Win32.IPerPropertyBrowsing.g.cs (1)
287 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\219\Windows.Win32.IPersistPropertyBag.g.cs (1)
238 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\220\Windows.Win32.IPersistStorage.g.cs (1)
362 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\221\Windows.Win32.IPersistStreamInit.g.cs (1)
324 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\222\Windows.Win32.IPropertyBag.g.cs (1)
195 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\223\Windows.Win32.IPropertyDescriptionList.g.cs (1)
203 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\224\Windows.Win32.IPropertyNotifySink.g.cs (1)
169 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\225\Windows.Win32.IPropertyStore.g.cs (1)
318 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\226\Windows.Win32.IProvideClassInfo.g.cs (1)
136 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\227\Windows.Win32.IProvideClassInfo2.g.cs (1)
170 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\228\Windows.Win32.IProvideMultipleClassInfo.g.cs (1)
266 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\229\Windows.Win32.IQuickActivate.g.cs (1)
238 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\230\Windows.Win32.IRangeValueProvider.g.cs (1)
389 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\231\Windows.Win32.IRawElementProviderFragment.g.cs (1)
350 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\232\Windows.Win32.IRawElementProviderFragmentRoot.g.cs (1)
185 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\233\Windows.Win32.IRawElementProviderHwndOverride.g.cs (1)
142 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\234\Windows.Win32.IRawElementProviderSimple.g.cs (1)
273 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\235\Windows.Win32.IRichEditOle.g.cs (1)
818 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\236\Windows.Win32.IRichEditOleCallback.g.cs (1)
612 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\237\Windows.Win32.IScrollItemProvider.g.cs (1)
134 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\238\Windows.Win32.IScrollProvider.g.cs (1)
403 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\239\Windows.Win32.ISelectionItemProvider.g.cs (1)
277 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\240\Windows.Win32.ISelectionProvider.g.cs (1)
221 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\241\Windows.Win32.IShellFolder.g.cs (1)
745 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\242\Windows.Win32.IShellItem.g.cs (1)
361 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\243\Windows.Win32.IShellItemArray.g.cs (1)
469 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\244\Windows.Win32.IShellItemFilter.g.cs (1)
187 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\245\Windows.Win32.ISimpleFrameSite.g.cs (1)
201 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\246\Windows.Win32.ISpecifyPropertyPages.g.cs (1)
146 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\247\Windows.Win32.ISupportErrorInfo.g.cs (1)
148 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\248\Windows.Win32.ITableItemProvider.g.cs (1)
172 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\249\Windows.Win32.ITableProvider.g.cs (1)
214 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\251\Windows.Win32.ITextDocument.g.cs (1)
1023 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\252\Windows.Win32.ITextFont.g.cs (1)
2575 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\253\Windows.Win32.ITextPara.g.cs (1)
2285 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\254\Windows.Win32.ITextProvider.g.cs (1)
333 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\255\Windows.Win32.ITextProvider2.g.cs (1)
379 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\256\Windows.Win32.ITextRange.g.cs (1)
2706 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\257\Windows.Win32.ITextRangeProvider.g.cs (1)
812 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\258\Windows.Win32.ITextSelection.g.cs (1)
2446 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\259\Windows.Win32.ITextStoryRanges.g.cs (1)
298 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\260\Windows.Win32.IToggleProvider.g.cs (1)
177 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\261\Windows.Win32.IUIAutomation.g.cs (1)
2455 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\262\Windows.Win32.IUIAutomationCacheRequest.g.cs (1)
408 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\263\Windows.Win32.IUIAutomationCondition.g.cs (1)
98 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\264\Windows.Win32.IUIAutomationElement.g.cs (1)
3265 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\265\Windows.Win32.IUIAutomationElementArray.g.cs (1)
177 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\266\Windows.Win32.IUIAutomationEventHandler.g.cs (1)
143 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\267\Windows.Win32.IUIAutomationFocusChangedEventHandler.g.cs (1)
139 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\268\Windows.Win32.IUIAutomationPropertyChangedEventHandler.g.cs (1)
147 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\269\Windows.Win32.IUIAutomationProxyFactory.g.cs (1)
183 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\270\Windows.Win32.IUIAutomationProxyFactoryEntry.g.cs (1)
568 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\271\Windows.Win32.IUIAutomationProxyFactoryMapping.g.cs (1)
448 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\272\Windows.Win32.IUIAutomationStructureChangedEventHandler.g.cs (1)
143 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\273\Windows.Win32.IUIAutomationTreeWalker.g.cs (1)
659 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\274\Windows.Win32.IValueProvider.g.cs (1)
226 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\275\Windows.Win32.IVBFormat.g.cs (1)
161 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\276\Windows.Win32.IVBGetControl.g.cs (1)
140 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\277\Windows.Win32.IViewObject.g.cs (1)
376 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\278\Windows.Win32.IViewObject2.g.cs (1)
343 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\279\Windows.Win32.IWebBrowser.g.cs (1)
943 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\280\Windows.Win32.IWebBrowser2.g.cs (1)
2237 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\281\Windows.Win32.IWebBrowserApp.g.cs (1)
1584 return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
_generated\616\Windows.Win32.VariableLengthInlineArray.g.cs (1)
44 return MemoryMarshal.CreateSpan(ref this.e0, length);
Microsoft\Office\IMsoComponent.cs (1)
118return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft\Office\IMsoComponentManager.cs (1)
30return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft\VisualStudio\Shell\ICategorizeProperties.cs (1)
28return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft\VisualStudio\Shell\IProvidePropertyBuilder.cs (1)
28return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft\VisualStudio\Shell\IVSMDPerPropertyBrowsing.cs (1)
29return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
Microsoft\VisualStudio\Shell\IVsPerPropertyBrowsing.cs (1)
28return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
System\Windows\Forms\IExtender.cs (1)
99return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));