forked from golang/go
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/compile/internal/ir: drop Inl.Body
We don't actually depend on Inl.Body anywhere, except it implicitly serves to indicate whether Inl.Dcl has been populated. So replace it with a boolean so we don't need to keep a useless copy of every inlinable function body in memory. While here, also add some Fatalfs to make sure there are no unused local variables. The unified frontend now omits unreachable code during export data writing, so there shouldn't be unused local variables. Also, since unified IR uses the same code/data to construct the original function as inlined and/or imported functions, the Dcl list should always be the same, which addresses the real root issue (i.e., that export/import could skew the Dcl lists). Change-Id: I6e3435f3a0352f6efbae787344006efac1891e84 Reviewed-on: https://go-review.googlesource.com/c/go/+/523315 Auto-Submit: Matthew Dempsky <[email protected]> Reviewed-by: Cherry Mui <[email protected]> Reviewed-by: Cuong Manh Le <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]>
- Loading branch information
Showing
4 changed files
with
22 additions
and
55 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