-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
inlining: use already-resolved source for finalizer inlining
The source for `Core.finalizer` call is already resolved when arrived at `sroa_mutables!`, so we can just try to inline `InliningCase` appended to the intrinsic call there. This commit also improves the robustness of the implementation, by handling few edge cases e.g. when `finalizer` returns a constant value and when the `finalizer` inliner bail out from inlining `finalizer` with conditional block, and tests such cases explicitly.
- Loading branch information
Showing
4 changed files
with
78 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters