Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve JIT loop optimizations (.NET 9) #93144

Closed
15 of 21 tasks
BruceForstall opened this issue Oct 6, 2023 · 4 comments
Closed
15 of 21 tasks

Improve JIT loop optimizations (.NET 9) #93144

BruceForstall opened this issue Oct 6, 2023 · 4 comments
Assignees
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI User Story A single user-facing feature. Can be grouped under an epic.
Milestone

Comments

@BruceForstall
Copy link
Member

BruceForstall commented Oct 6, 2023

We plan to continue improving JIT optimization capabilities for loop code. An overview of many JIT optimization possibilities is here; this issue will focus on issues we choose to address in .NET 9.

Planned for .NET 9

Loop recognition and canonicalization

Loop cloning

Induction variables

Pushed out of .NET 9

Loop cloning

Multi-dimensional array improvements

Loop peeling

@BruceForstall BruceForstall added area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI User Story A single user-facing feature. Can be grouped under an epic. labels Oct 6, 2023
@BruceForstall BruceForstall added this to the 9.0.0 milestone Oct 6, 2023
@ghost
Copy link

ghost commented Oct 6, 2023

Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.

Issue Details

We plan to continue improving JIT optimization capabilities for loop code. An overview of many JIT optimization possibilities is here; this issue will focus on issues we choose to address in .NET 9.

Planned for .NET 9

Loop recognition and canonicalization

Loop cloning

Multi-dimensional array improvements

Loop peeling

Induction variables

Author: BruceForstall
Assignees: -
Labels:

area-CodeGen-coreclr, User Story

Milestone: 9.0.0

@jakobbotsch
Copy link
Member

jakobbotsch commented Dec 13, 2023

With recent work we are close to having moved from the old lexical representation of loops to a more general graph-based one. Since I'll be out until New Year's, here's a more detailed list of work done and expected future work.

Some stats from the loop representation switch over some of our win-x64 collections:

  • 25.1% more hoisting in benchmarks.run_pgo, 5.7% more hoisting in realworld, 35.8% more hoisting in libraries_tests.run
  • 7.3% more cloned loops in benchmarks.run_pgo, 6.8% more cloned loops in realworld, 6.7% more cloned loops in libraries_tests.run
  • 5.0% (~700) more aligned loops aggregated over the collections

@JulieLeeMSFT
Copy link
Member

.NET9 work is complete. Closing.

@JulieLeeMSFT
Copy link
Member

Will move the pushed-out items to .NET 10 user story during .NET 10 planning.

@github-project-automation github-project-automation bot moved this from Team User Stories to Done in .NET Core CodeGen Jul 30, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Aug 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI User Story A single user-facing feature. Can be grouped under an epic.
Projects
Status: Done
Development

No branches or pull requests

3 participants