Message154080
> but maybe it's due to something specific about the configuration of the buildbot
> machine?
Maybe you didn't try with a large enough file. Here's a trial on my box:
"""
$ df -h /tmp/
Filesystem Size Used Avail Use% Mounted on
tmpfs 253M 68K 253M 1% /tmp
$ cat /tmp/test.py
import mmap
import zlib
f = open('/tmp/foo', 'wb+')
f.seek(512 * 1024 * 1024)
f.write(b'x')
f.flush()
m = mmap.mmap(f.fileno(), 0, access=mmap.ACCESS_READ)
zlib.crc32(m)
m.close()
$ python /tmp/test.py
Bus error (core dumped)
"""
> I've temporarily changed the test to use a regular chunk of memory
>instead of the mmap hack). If possible, I'd like to change back to the
>old technique in the long run (since it allows the test to run on
>machines with less RAM)
Yes, but this kind of test is only supposed to be run on machines
which have enough memory.
Also, if the filesystem doesn't support sparse files, this writes a
lot to the disk (and if it crashes, you end up with a huge file).
I'd say it's fine this way... |
|
Date |
User |
Action |
Args |
2012-02-23 19:17:08 | neologix | set | recipients:
+ neologix, loewis, pitrou, vstinner, nadeem.vawda, torsten, python-dev |
2012-02-23 19:17:08 | neologix | link | issue13873 messages |
2012-02-23 19:17:08 | neologix | create | |
|