dotnet / runtime

.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps.
https://docs.microsoft.com/dotnet/core/
MIT License
15.16k stars 4.72k forks source link

Improve handling of fixed register requirements #7966

Open CarolEidt opened 7 years ago

CarolEidt commented 7 years ago

When a node has a delayed-use register (either due to an RMW def or due to an internalRegDelayFree), if its result has a fixed-use, we can't propagate the register constraint to the def, because there's no associated fixed-reference on the RegRecord to ensure that it will not be used by the delay-free register. So, in those cases we leave the registerAssignment unchanged on the def, although the Interval will be preferenced to that if there is no conflict. See the code in LinearScan::associateRefPosWithInterval(). This means that we may often require a copy at the use of this node's result. This case could be moved to BuildRefPositionsForNode(), at the point where the def RefPosition is created, causing a RefTypeFixedRef to be added at that location. This, however, results in:

There may be an alternative approach to handle this issue, but in any case further investigation is required. This came to my attention while looking at dotnet/runtime#7931 category:cq theme:register-allocator skill-level:expert cost:medium

ghost commented 1 year ago

Due to lack of recent activity, this issue has been marked as a candidate for backlog cleanup. It will be closed if no further activity occurs within 14 more days. Any new comment (by anyone, not necessarily the author) will undo this process.

This process is part of our issue cleanup automation.

ghost commented 1 year ago

This issue will now be closed since it had been marked no-recent-activity but received no further activity in the past 14 days. It is still possible to reopen or comment on the issue, but please note that the issue will be locked if it remains inactive for another 30 days.