JIT: Fix an invalid use of remainder liveness in physical promotion #99897
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Physical promotion computes liveness for all locals it promotes, including the liveness of the remainder of the local (i.e. all the non-promoted segments of the struct). This liveness information is used to skip unnecessary stores during decomposition. However, in some cases physical promotion may need to use the base struct local as scratch space to handle various edge cases (for example, partially overlapping copies). In those cases the remainder liveness cannot be used to skip optimizations. This was already handled in one place; this change handles it in another place as well.
Fix #99882