]> Cypherpunks repositories - gostls13.git/commit
[dev.fuzz] internal/fuzz: don't store corpus in memory
authorRoland Shoemaker <roland@golang.org>
Wed, 25 Aug 2021 20:31:19 +0000 (13:31 -0700)
committerRoland Shoemaker <roland@golang.org>
Thu, 2 Sep 2021 21:43:52 +0000 (21:43 +0000)
commite5247f7886aad90d6fa402b5308d4c30afdfebdf
treebddbd7770486fdbe77eecfdd2ba544c7edd6c40c
parent5bc273aca54391177ad3f43a54d22021deb99114
[dev.fuzz] internal/fuzz: don't store corpus in memory

Instead of holding all corpus data/values in memory, only store seed
inputs added via F.Add in memory, and only load corpus entries which
are written to disk when we need them. This should significantly reduce
the memory required by the coordinator process.

Additionally only load the corpus in the coordinator process, since the
worker has no need for it.

Fixes #46669.

Change-Id: Ic3b0c5e929fdb3e2877b963e6b0fa14e140c1e1d
Reviewed-on: https://go-review.googlesource.com/c/go/+/345096
Trust: Roland Shoemaker <roland@golang.org>
Run-TryBot: Roland Shoemaker <roland@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
src/internal/fuzz/fuzz.go
src/internal/fuzz/worker.go
src/testing/fuzz.go