On Sat, Jul 20, 2013 at 1:43 AM, <
hv1...@gmail.com> wrote:
> On Friday, July 19, 2013 1:27:30 AM UTC-7, David Bruant wrote:
> > Any chance this could be made into an addon (or just Firefox devtools)?
> > Something like : reload the page to get the graphs.
> > How is the information exposed? (so I understand how an addon could grab
> it
> > to display it)
> >
> > I imagine everyone caring about perf of their website would love to be
> able
> > to use such a tool.
>
> I can image that.
>
> But I think in that case you might just use SPS. It logs more or less the
> same information. There is only the need to add logging of which engine is
> used. So that shouldn't be that hard and it would/should be possible to
> create the same graphs... The person that created SPS may always contact me
> about this.
>
I think we should have a devtool for general code-quality analysis.
Something that tells users if their code contains stuff that's hard to
optimize (e.g. by making calls polymorphic or forcing objects into dict
mode), unnecessarily entrains lots of stuff into closures, creates lots of
garbage, or has bad compiletime / runtime ratios. Bhackett's JIT Inspector
could find a home there. I mentioned that in
https://bugzilla.mozilla.org/show_bug.cgi?id=896088, too, and it's
certainly something the devtools people should lead. (CC-ing ejpbruel for
that.)
>
> Why I don't use SPS myself:
> 1) Because I can use python quite easily to get the information out of it
> that I want, instead of only the information the addon provides.
> 2) I don't want to build a browser to test/fix performance in the
> js-engine.
>
I think that the information the Tracelogger gives is, in large parts at
least, orthogonal to what SPS provides. From the SPS output, you can see
where time is spent in the engine and the browser, but you quite often
can't tell *why* it is spent there. Having a list of JS functions with
their compile/invocation count, and compile/run durations gives very
specific information about which of the JS functions to look into.
>
> On Friday, July 19, 2013 12:51:55 AM UTC-7, Till Schneidereit wrote:
> > These graphs look amazing! I'm very much looking forward to doing them
> for
> > Shumway: I'm sure we can glean some info from them about how to optimize
> > that codebase, itself.
>
> Cool :D
>
Indeed! :)
For that to *fully* work, we'd need a way to run it in the browser, though.
We do have quite large parts of the project that we can run in the shell,
but everything that's related to rendering can obviously only run in the
browser. But that's just a nit, really.
>
> > - it'd be great to be able to sort the scripts list by the various
> columns
>
> Possible now ;)
>
> > - I don't know if this easily done, but having invocation counts in
> > addition to total time would be great for the scripts list
>
> Visible now. They will appear as soon as I rebuild the graphs. For GGC I
> just did, because I added a logger for Minor GC
Very, very cool!
I now have additional requests, but please feel free to just ignore them,
they're not important:
- in Octane-Richards-GGC, the 4th-most-costly function (at 6.55%) spends
99.13% of the time in the ion compiler, but only 0.17% executing the JITted
code. How about making cases like that more visible by adding a "compile
time / run time"-ratio column?
- Maybe drop the "script" from all values in "Time spent", to save space?
- The "Time spent" values could actually be their own columns, to enable
sorting by them.
- Exposing places in the entire program where a lot of time is spent in the
interpreter or baseline would be interesting. See the 5th-most-costly
function in Octane-Richards-GGC, spending ~6.4% of the overall program's
time in the interpreter. Maybe enabling the comparison of columns would
work? Like "Total time / Interp time * Ion time".
- Please implement the parts of Excel I forgot to mention. ;)
Seriously, though, such a cool tool!