- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for NewPipe (0.15 sec)
-
src/internal/poll/splice_linux_test.go
if err != nil { continue } poll.PutPipe(p) } }) b.Run("SplicePipeWithoutPool", func(b *testing.B) { for i := 0; i < b.N; i++ { p := poll.NewPipe() if p == nil { b.Skip("newPipe returned nil") } poll.DestroyPipe(p) } }) } func BenchmarkSplicePipePoolParallel(b *testing.B) { b.RunParallel(func(pb *testing.PB) { for pb.Next() {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 21:49:26 UTC 2024 - 2.8K bytes - Viewed (0) -
src/internal/poll/splice_linux.go
// redirecting the data transmission to the conventional way utilizing read() + write() as a fallback. p := newPipe() if p == nil { return nil } runtime.SetFinalizer(p, destroyPipe) return p } // getPipe tries to acquire a pipe buffer from the pool or create a new one with newPipe() if it gets nil from the cache. func getPipe() (*splicePipe, error) { v := splicePipePool.Get() if v == nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 21:49:26 UTC 2024 - 7.6K bytes - Viewed (0)