-
Notifications
You must be signed in to change notification settings - Fork 17.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
os: depend on Readlink only when necessary
Currently Readlink gets linked into the binary even when Executable is not needed. This reduces a simple "os.Stdout.Write([]byte("hello"))" by ~10KiB. Previously the executable path was read during init time, because deleting the executable would make "Readlink" return "(deleted)" suffix. There's probably a slight chance that the init time reading would return it anyways. Updates #6853 Change-Id: Ic76190c5b64d9320ceb489cd6a553108614653d1 Reviewed-on: https://go-review.googlesource.com/c/go/+/311790 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> Trust: Tobias Klauser <tobias.klauser@gmail.com>
- Loading branch information
Showing
2 changed files
with
78 additions
and
8 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