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
encoding/gob: test failed with out of memory on raspberrypi #3742
Labels
Comments
This isn't an Arm problem, it affects pretty much any 32bit system. Running this on my pandaboard the amount of RSS used for the Fuzz test varies wildly, most likely due to GC conservatism. pando(~/go/src/pkg/encoding/gob) % /usr/bin/time -v ./gob.test -test.run=Fuzz 2>&1 | grep Maximum\ resident\ set Maximum resident set size (kbytes): 17200 pando(~/go/src/pkg/encoding/gob) % /usr/bin/time -v ./gob.test -test.run=Fuzz 2>&1 | grep Maximum\ resident\ set Maximum resident set size (kbytes): 13520 pando(~/go/src/pkg/encoding/gob) % /usr/bin/time -v ./gob.test -test.run=Fuzz 2>&1 | grep Maximum\ resident\ set Maximum resident set size (kbytes): 1058880 pando(~/go/src/pkg/encoding/gob) % /usr/bin/time -v ./gob.test -test.run=Fuzz 2>&1 | grep Maximum\ resident\ set Maximum resident set size (kbytes): 10848 pando(~/go/src/pkg/encoding/gob) % /usr/bin/time -v ./gob.test -test.run=Fuzz 2>&1 | grep Maximum\ resident\ set Maximum resident set size (kbytes): 1058848 It turns out this is another manifestation of issue #3225. Oddly the final comment by rsc says that TestFuzz is disabled in -short mode, and this is still true. So there must be another test that is triggering the same behaviour, possibly TestFuzzRegressions. Labels changed: added arch-arm, os-linux. Owner changed to @davecheney. Status changed to Accepted. |
Digging in further (and adding a bit of swap), this fuzz regression test reliably needs 279mb of rss to run. @dsymonds, is this expected, or does this sound like a problem ? === RUN TestFuzzRegressions --- PASS: TestFuzzRegressions (0.11 seconds) codec_test.go:1469: seed=1328492090837718000 n=100 e=*float32 PASS ok encoding/gob 0.239s Command being timed: "go test -v -test.run=FuzzReg" User time (seconds): 20.28 System time (seconds): 1.93 Percent of CPU this job got: 87% Elapsed (wall clock) time (h:mm:ss or m:ss): 0:25.37 Average shared text size (kbytes): 0 Average unshared data size (kbytes): 0 Average stack size (kbytes): 0 Average total size (kbytes): 0 Maximum resident set size (kbytes): 279072 Average resident set size (kbytes): 0 Major (requiring I/O) page faults: 0 Minor (reclaiming a frame) page faults: 57929 Voluntary context switches: 1181 Involuntary context switches: 919 Swaps: 0 File system inputs: 0 File system outputs: 0 Socket messages sent: 0 Socket messages received: 0 Signals delivered: 0 Page size (bytes): 4096 Exit status: 0 |
I wouldn't be surprised by that. This is throwing random data at gob, and some forms are going to trigger large allocations. The trick is to make the gob package not allocate stupid amounts and cleanly reject extreme inputs, which could form a DoS vector. So, yes, it sounds like the test is doing an adequate job. |
This issue was closed by revision bbe6017. Status changed to Fixed. |
mikioh
changed the title
raspberrypi: encoding/gob test failed with out of memory
encoding/gob: test failed with out of memory on raspberrypi
Feb 26, 2015
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The text was updated successfully, but these errors were encountered: