Skip to content

Implement loop peeling #93142

@BruceForstall

Description

@BruceForstall

"Loop peeling" is a compiler optimization that unrolls a loop into two copies. In the variant of interest here, the first copy executes the first iteration of the loop, and the second copy executes the remaining iterations of the loop. Given the structure and semantics of .NET code, it is believed that peeling the first iteration will allow better optimization of the remaining iterations by constructing CSEs in the first copy in exception order, and using them in the second copy where exception checking such as null checking of arrays can be removed.

Metadata

Metadata

Assignees

Labels

area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions