Skip to content
Snippets Groups Projects
  • Augie Fackler's avatar
    574e1d3bc667
    demandimport: instrument python 2 code with trace events · 574e1d3bc667
    Augie Fackler authored
    This causes the evaluation of an import in Python 3 to emit some trace
    data. There's some interesting wrinkles in here, like the fact that
    before we even hit dispatch we've demand-imported `sys` several times,
    despite the fact that `sys` was already fully loaded as one of the
    first few statements in the `hg` script. I don't think that's actually
    costing us a ton of performance, but it's probably something we should
    investigate fixing some day.
    
    Differential Revision: https://phab.mercurial-scm.org/D4347
    574e1d3bc667
    History
    demandimport: instrument python 2 code with trace events
    Augie Fackler authored
    This causes the evaluation of an import in Python 3 to emit some trace
    data. There's some interesting wrinkles in here, like the fact that
    before we even hit dispatch we've demand-imported `sys` several times,
    despite the fact that `sys` was already fully loaded as one of the
    first few statements in the `hg` script. I don't think that's actually
    costing us a ton of performance, but it's probably something we should
    investigate fixing some day.
    
    Differential Revision: https://phab.mercurial-scm.org/D4347