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

bufio: add (*Reader).WriteTo, (*Writer).ReadFrom to optimize io.Copy #4028

Closed
dvyukov opened this issue Sep 1, 2012 · 5 comments
Closed

Comments

@dvyukov
Copy link
Member

dvyukov commented Sep 1, 2012

For some programs io.Copy() to bufio.Writer causes generation of a lot of garbage.
It seems that bufio.Writer could efficiently support io.ReaderFrom interface to reduce
garbage generation.
@remyoudompheng
Copy link
Contributor

Comment 1:

Similarly I have missed a WriteTo method on bytes.Reader

@rsc
Copy link
Contributor

rsc commented Sep 1, 2012

Comment 2:

I will create a separate issue for package bytes.

Labels changed: added priority-later, go1.1, removed priority-triage.

Status changed to Accepted.

@gopherbot
Copy link

Comment 3 by jgraettinger@google.com:

I'd be happy to work up a patch for review.

@nigeltao
Copy link
Contributor

Comment 4:

This issue was updated by revision e289a2b.

R=dave, nigeltao, rsc, bradfitz, rogpeppe
CC=golang-dev
http://golang.org/cl/6548047
Committer: Nigel Tao 

@nigeltao
Copy link
Contributor

Comment 5:

This issue was closed by revision 2a4818d.

Status changed to Fixed.

@rsc rsc added this to the Go1.1 milestone Apr 14, 2015
@rsc rsc removed the go1.1 label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 24, 2016
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants