On Fri, 26 Jul 2013 22:17:47 +0200 Victor Stinner <victor.stinner at gmail.com> wrote: > 2013/7/26 Antoine Pitrou <solipsis at pitrou.net>: > >> The main drawback is the additionnal syscalls: on some platforms, 2 > >> additional syscalls are need to make a file descriptor non-inheritable > >> for each creation of file descriptor. According to my benchmark on the > >> implementation of the PEP 433: the overhead of making a file > >> descriptor non-inheritable is between 1% and 3% (7.8 µs => 7.9 or 8.0 > >> µs) on Linux 3.6. > > > > 1% and 3% of what? > > You're telling us there's a 0.1µs overhead. It's positively tiny. > > Copy-paste of the link: > > """ > On Linux, setting the close-on-flag has a low overhead on > performances. Results of bench_cloexec.py on Linux 3.6: > > - close-on-flag not set: 7.8 us > - O_CLOEXEC: 1% slower (7.9 us) > - ioctl(): 3% slower (8.0 us) > - fcntl(): 3% slower (8.0 us) > """ You aren't answering my question: slower than what? Benchmarking is useless if you aren't telling us what exactly you are benchmarking. > The overhead is between 0.1 and 0.2 µs (100 and 200 ns) according to > my micro-benchmark. That's what I figured out (see above). It's tiny. Antoine.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4