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

Faster tar xzf linux-3.0.tar.gz #16

Closed
rfjakob opened this issue Jan 4, 2016 · 5 comments
Closed

Faster tar xzf linux-3.0.tar.gz #16

rfjakob opened this issue Jan 4, 2016 · 5 comments

Comments

@rfjakob
Copy link
Owner

rfjakob commented Jan 4, 2016

tar xzf linux-3.0.tar.gz is my canonical small-file benchmark. Gocryptfs takes 2x the time compared to EncFS.
Looking at the cpu profile, this is caused by heavy GC activity that originates in go-fuse. For each created file, an inode object is allocated. Recycling inode objects could reduce GC pressure considerably.

@kofalt
Copy link

kofalt commented Jan 5, 2016

The new(ish) sync.Pool may be of significant help here.

@rfjakob
Copy link
Owner Author

rfjakob commented Jan 5, 2016 via email

@kofalt
Copy link

kofalt commented Jan 6, 2016

I had a look, and in go 1.3.3 this ran without error:

package main

import (
    "sync"
)

func main() {
    p := sync.Pool{
        New: func() interface{} {
            return nil
        },
    }
    p.Get()
}

It looks like it was added in 1.3.

@rfjakob
Copy link
Owner Author

rfjakob commented Jan 10, 2016

Fixed by hanwen/go-fuse#91

@rfjakob
Copy link
Owner Author

rfjakob commented Jan 19, 2016

Merged as hanwen/go-fuse@c4b6b79 .

@rfjakob rfjakob closed this as completed Jan 19, 2016
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

2 participants