From: Matt Mackall Date: Sat, 30 Apr 2005 16:06:40 GMT Subject: Re: Mercurial 0.4b vs git patchbomb benchmark Message-ID: <20050430160640.GK21897@waste.org> In-Reply-To: <200504301444.j3UEiHN05686@adam.yggdrasil.com> On Sat, Apr 30, 2005 at 07:44:17AM -0700, Adam J. Richter wrote: > > I'd like to mention a couple of possible optimizations > for both the with and without compression approaches. > > If you remove the gzip compression, then I imagine you could > do much of the IO of checking out files via sendfile, without > ever copying data to program space or even changing the program's > memory map. There apparently exists a python sendfile module. > > If this mercurial were written in C, much of the rest of > the IO could be optimized with mmap (to reduce copies) and writev > in the absense of a compression pass. I don't know enough about > python to know if these optimizations are available. Python can do mmap, not sure about writev. But I'm currently still in the "keep it as simple as possible" stage. There's a bunch of room for optimization still, but if I do it all now, it'll make things hard when I run into the next design change. And there's still some important core work that needs doing - checkout and commit need to be a subcase of the core merge code. -- Mathematics is the supreme nostalgia of our time.