Skip to content

Commit c0c45cc

Browse files
Add AVX10.2 experimental note, and feedback
1 parent dbf79fc commit c0c45cc

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

release-notes/10.0/preview/preview1/runtime.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,17 +44,16 @@ static int Sum(int[] array)
4444

4545
The type of the underlying collection is clear, and the JIT should be able to transform this snippet into the first one. However, array interfaces are implemented differently from "normal" interfaces, such that the JIT does not know how to devirtualize them. This means the enumerator calls in the for-each loop remain virtual, blocking multiple optimizations: inlining, stack allocation, and others.
4646

47-
In Preview 1, the JIT can now devirtualize and inline array interface methods, thanks to work in [#108153](https://github.com/dotnet/runtime/pull/108153) and [#109209](https://github.com/dotnet/runtime/pull/109209). This is the first of many steps we will be taking to achieve performance parity between the above implementations, as detailed in our [de-abstraction plans](https://github.com/dotnet/runtime/issues/108913) for .NET 10.
47+
The JIT can now devirtualize and inline array interface methods, thanks to work in [dotnet/runtime #108153](https://github.com/dotnet/runtime/pull/108153) and [dotnet/runtime #109209](https://github.com/dotnet/runtime/pull/109209). This is the first of many steps we will be taking to achieve performance parity between the above implementations, as detailed in our [de-abstraction plans](https://github.com/dotnet/runtime/issues/108913) for .NET 10.
4848

4949
## Stack Allocation of Arrays of Value Types
5050

5151
In .NET 9, the JIT gained the ability to allocate objects on the stack, when the object is guaranteed to not outlive its parent method. Not only does stack allocation reduce the number of objects the GC has to track, but it also unlocks other optimizations: For example, after an object has been stack-allocated, the JIT can consider replacing it entirely with its scalar values. Because of this, stack allocation is key to reducing the abstraction penalty of reference types.
5252

53-
In Preview 1, thanks to [contributions](https://github.com/dotnet/runtime/pull/104906) from @hez2010, the JIT will now stack-allocate small fixed-sized arrays of value types that don't contain GC pointers when it can make the same lifetime guarantees described above. Among other [stack allocation enhancements](https://github.com/dotnet/runtime/issues/104936), we plan to expand this ability to arrays of reference types in the coming previews.
54-
55-
56-
53+
Thanks to [contributions](https://github.com/dotnet/runtime/pull/104906) from @hez2010, the JIT will now stack-allocate small, fixed-sized arrays of value types that don't contain GC pointers when it can make the same lifetime guarantees described above. Among other [stack allocation enhancements](https://github.com/dotnet/runtime/issues/104936), we plan to expand this ability to arrays of reference types in the coming previews.
5754

5855
## AVX10.2 Support
5956

6057
Preview 1 enables support for the Advanced Vector Extensions (AVX) 10.2 for x64-based processors, thanks to [contributions](https://github.com/dotnet/runtime/pull/111209) from @khushal1996. .NET developers can try out the new intrinsics available in the `System.Runtime.Intrinsics.X86.Avx10v2` class once capable hardware is available. In the next several previews, we plan to further incorporate AVX10.2 support into the JIT's emitter to take full advantage of the instruction set's features.
58+
59+
Because AVX10.2-enabled hardware is not yet available, the JIT's support for AVX10.2 is disabled by default for now. We plan to enable it once we have thoroughly tested it.

0 commit comments

Comments
 (0)