Thu, 09 Mar 2017 11:56:47 -0800 osutil: use Python memory allocator in _listdir
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 09 Mar 2017 11:56:47 -0800] rev 31477
osutil: use Python memory allocator in _listdir The Python memory allocator has performance advantages for small allocations.
Thu, 09 Mar 2017 11:54:25 -0800 bdiff: use Python memory allocator in fixws
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 09 Mar 2017 11:54:25 -0800] rev 31476
bdiff: use Python memory allocator in fixws Python has its own memory allocation APIs. For allocations <= 512 bytes, it allocates memory from arenas. This means that average small allocations don't call the system allocator, which makes them faster. Also, arena allocations cut down on memory fragmentation, which can matter for performance in long-running processes. Another advantage of using the Python memory allocator is that allocations are tracked by Python. This is a bigger deal in Python 3, as modern versions of Python have some decent built-in tools for examining memory usage, leaks, etc. This patch converts a trivial malloc() + free() in the bdiff code to use the Python allocator APIs. Since the object being operated on is a line, chances are it will use an arena. So, this could have a net positive impact on performance (although I didn't measure it).
Thu, 16 Mar 2017 11:17:55 -0700 localrepo: fix deprecation warning version of wfile
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Thu, 16 Mar 2017 11:17:55 -0700] rev 31475
localrepo: fix deprecation warning version of wfile The patch lingered a bit too long in my local clone and I messed up when I updated the version number. Since nobody caught it, I'm fixing the version after the fact.
Wed, 15 Mar 2017 15:07:14 -0700 util: explicitly tests for None
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 15 Mar 2017 15:07:14 -0700] rev 31474
util: explicitly tests for None Changeset 8b6927eb7efd removed the mutable default value, but did not explicitly tested for None. Such implicit checking can introduce semantic and performance issue. We move to an explicit check for None as recommended by PEP8: https://www.python.org/dev/peps/pep-0008/#programming-recommendations
(0) -30000 -10000 -3000 -1000 -300 -100 -30 -10 -4 +4 +10 +30 +100 +300 +1000 +3000 +10000 tip