Skip to content

LSRA: Don't change register assignments for def/use conflicts #10196

Open
@CarolEidt

Description

@CarolEidt

Currently, LinearScan::resolveConflictingDefAndUse() may change the register assignment on the def or use of a tree temp (SDSU) when there is a conflict. This may increase the likelihood that at least one of the references will get a desired register, but it can cause problems when a necessary fixed register is not actually assigned. This is because, although there is a RefTypeFixedRef associated with it, that will only discourage other Intervals from taking that register, and will not actually cause it to be spilled if it is occupied. A solution (see #10182 and dotnet/coreclr#17673) is to also mark the register as killed, but that is overly conservative, since if it is allocated to an Interval that remains live (e.g. a lclVar), it will be unnecessarily killed.

category:correctness
theme:register-allocator
skill-level:expert
cost:small

Metadata

Metadata

Assignees

No one assigned

    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