Closed Bug 951418 Opened 12 years ago Closed 4 years ago

Port trace_viewer to gecko

Categories

(Core :: Gecko Profiler, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: BenWa, Unassigned)

Details

Attachments

(1 file)

We'd like to get a 'flamegraph' view for the profiler. Chrome uses trace_viewer which I believe we could reuse. The problem is that they use several webkit specific features and it's very difficult to port. If we complete the port we can reuse the same trace_viewer tool that people are already familiar with using. The repo can be found here: http://code.google.com/p/trace-viewer/ Note that the head revision using createShadowRoot which isn't well supported in Gecko. However revision 200 has all the features we need for now and doesn't use createShadowRoot. The first set of problems is that they use webkitRequestAnimationFrame and the chrome js object. This is easy to fix. The hard problem is that they use flex-box and input features we don't support (like window.event). I tried doing this port myself but I quickly hit a wall. The goal is to get <repo>/src/interactive_tests.html running as well in Firefox as in Chrome then we can integrate the view in the profiler UI.
(In reply to Benoit Girard (:BenWa) from comment #0) > Note that the head revision using createShadowRoot which isn't well > supported in Gecko. However revision 200 has all the features we need for > now and doesn't use createShadowRoot. If this remains an issue, try http://www.polymer-project.org/ > The first set of problems is that they use webkitRequestAnimationFrame and > the chrome js object. Is that window.chrome? What do they access off of that? > This is easy to fix. The hard problem is that they use > flex-box and input features we don't support (like window.event). I tried > doing this port myself but I quickly hit a wall. Hmm, window.event _should_ be replaceable with the event object that we pass to the event handler.
(In reply to :Ehsan Akhgari (needinfo? me!) from comment #1) > (In reply to Benoit Girard (:BenWa) from comment #0) > > Note that the head revision using createShadowRoot which isn't well > > supported in Gecko. However revision 200 has all the features we need for > > now and doesn't use createShadowRoot. > > If this remains an issue, try http://www.polymer-project.org/ > > > The first set of problems is that they use webkitRequestAnimationFrame and > > the chrome js object. > > Is that window.chrome? What do they access off of that? nothing that we need, I added window.chrome = {} and that fixed that issue. > > > This is easy to fix. The hard problem is that they use > > flex-box and input features we don't support (like window.event). I tried > > doing this port myself but I quickly hit a wall. > > Hmm, window.event _should_ be replaceable with the event object that we pass > to the event handler. Yes that also works. The real problem is when I replace everything with all the webkit stuff with either -moz- or the non prefix version (as applicable) it doesn't size the elements properly.
(In reply to comment #2) > (In reply to :Ehsan Akhgari (needinfo? me!) from comment #1) > > (In reply to Benoit Girard (:BenWa) from comment #0) > > > Note that the head revision using createShadowRoot which isn't well > > > supported in Gecko. However revision 200 has all the features we need for > > > now and doesn't use createShadowRoot. > > > > If this remains an issue, try http://www.polymer-project.org/ > > > > > The first set of problems is that they use webkitRequestAnimationFrame and > > > the chrome js object. > > > > Is that window.chrome? What do they access off of that? > > nothing that we need, I added window.chrome = {} and that fixed that issue. > > > > > This is easy to fix. The hard problem is that they use > > > flex-box and input features we don't support (like window.event). I tried > > > doing this port myself but I quickly hit a wall. > > > > Hmm, window.event _should_ be replaceable with the event object that we pass > > to the event handler. > > Yes that also works. > > The real problem is when I replace everything with all the webkit stuff with > either -moz- or the non prefix version (as applicable) it doesn't size the > elements properly. I'd ask dholbert about any possible flexbox issues.
I asked dholbert for some help and made some progress tonight. There's only one remain 'big' issue and it's 2 pixel spacing only in firefox that I can't find where it's coming and how to remove it.
Attached image systrace_firefox.png
current result for systrace on firefox
Are we porting from the trace-viewer repo https://code.google.com/p/trace-viewer/? This way we can keep up with the latest improvements of trace-viewer.
No, I just use the latest systrace tool in android sdk(trace viewer reversion 775). I will try the new one.
Stumbled across this bug. CC'ing Greg Tatum, who is working on something like this.
Oh cool. Work is progressing on github here: https://github.com/devtools-html/perf.html/issues/85 The terminology I'm using is that the tab is the Timeline view, but will have various reports including a time-based flame chart. There will be additional reports like marker information, and whatever else we cook up.

We've had a flame graph on profiler.firefox.com for a while now, so I'll mark this old bug fixed.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: