Faster startup by moving code out of commands.py?
peter.arrenbrecht at gmail.com
Mon May 9 00:25:36 CDT 2011
On Sun, May 1, 2011 at 5:36 PM, Matt Mackall <mpm at selenic.com> wrote:
> On Sun, 2011-05-01 at 10:26 -0500, Steve Borho wrote:
> > On Sun, May 1, 2011 at 9:49 AM, Peter Arrenbrecht
> > <peter.arrenbrecht at gmail.com> wrote:
> > > Just a wild idea we had at the sprint: Maybe we could speed up hg by
> > > moving most of the code out of commands.py into separate files. Then
> > > each command would only have to parse code that it actually needs. And
> > > the command table could be filled with things that point to which file
> > > to load and which function to call in it.
> > >
> > > Would also help with structuring the stuff in commands.py a bit.
> > +1
> > I've had similar thoughts in the past, breaking commands.py into commands/
> Let's see some timings.
As a quick experiment I replaced all of the bodies in commands.py with
pass. Doesn't pay off.
More information about the Mercurial-devel