Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/compile: combine slice header and backing array for static slices into a single symbol #7637

Open
josharian opened this issue Mar 26, 2014 · 2 comments
Milestone

Comments

@josharian
Copy link
Contributor

Static slices generate two symbols, one for the slice header and one for the backing
array. These could be combined into a single symbol, laid out with the slice header
followed by the backing array. This would reduce binary size, particularly for the
unicode tables.

This does not make sense to do unless issue #7599 is also done, otherwise the backing
array will be needlessly loaded during init.

See https://golang.org/cl/78870047/ for more discussion.

Something similar could probably profitably be done for strings and string headers,
although there is a different approach under discussion at issue #7384.
@ianlancetaylor
Copy link
Contributor

Comment 1:

Labels changed: added repo-main, release-go1.4.

@josharian
Copy link
Contributor Author

Comment 2:

Labels changed: added release-go1.5, removed release-go1.4.

@bradfitz bradfitz modified the milestone: Go1.5 Dec 16, 2014
@rsc rsc removed the repo-main label Apr 14, 2015
@josharian josharian modified the milestones: Go1.6, Go1.5 May 21, 2015
@rsc rsc changed the title cmd/gc: combine slice header and backing array for static slices into a single symbol cmd/compile: combine slice header and backing array for static slices into a single symbol Jun 8, 2015
@josharian josharian modified the milestones: Go1.6, Go1.6Early Jun 29, 2015
@rsc rsc modified the milestones: Unplanned, Go1.6Early Nov 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants