Describe the enhancement requested
Similar to #41349, .NET 5 introduced new overloads for decimalGetBits for which allow the use of a stackalloc'ed span, and avoiding the allocation of a fresh byte array for each value serialized. This should (slightly) reduce the allocations associated with serializing C# decimal values.
|
int[] decimalBits = decimal.GetBits(value); |
Component(s)
C#
Describe the enhancement requested
Similar to #41349, .NET 5 introduced new overloads for
decimalGetBitsfor which allow the use of astackalloc'ed span, and avoiding the allocation of a fresh byte array for each value serialized. This should (slightly) reduce the allocations associated with serializing C# decimal values.arrow/csharp/src/Apache.Arrow/DecimalUtility.cs
Line 226 in 80622fa
Component(s)
C#