Closed Bug 1162679 Opened 9 years ago Closed 2 years ago

Decorate profile samples that go over add-on shims with add-on identifier

Categories

(Core :: Gecko Profiler, task, P3)

task

Tracking

()

RESOLVED INVALID
Tracking Status
e10s + ---
firefox40 --- affected

People

(Reporter: mconley, Unassigned)

References

(Blocks 2 open bugs)

Details

In single-process Firefox, I believe that code running within an add-on compartment will get "decorated" in the profiler output, so it'll show the icon for the add-on alongside the samples. I could be wrong about the mechanics there, but the end result is that you can tell if some samples are the result of an add-on doing some work.

I think we're losing this information when an add-on makes use of the shims. I'm seeing profiles where there's work going on in RemoteAddonsParent and RemoteAddonsChild, and it'd be really useful if we knew which add-on was causing that activity in profiles.
I think cleopatra does the annotation by looking at the file information for JS stack frames. I think the problem here is that sometimes the profiler doesn't see some of the JS stack frames for extension calls to RemoteAddonsParent/RemoteAddonsChild. It would be good to have a small testcase that we (or :djvj) can test with.
I wonder if we could take advantage of the fact that the addon ID is known to the shims at the point of interposition?:

https://dxr.mozilla.org/mozilla-central/source/js/xpconnect/idl/nsIAddonInterposition.idl?from=nsIAddonInterposition.idl#29
Priority: -- → P3
Blocks: 1329161

I'm not sure if this is still an issue? (With the new add-on system, Fission, etc.)
AddonInterposition doesn't seem to even exist anymore! -- These two name declarations could probably be removed.

Severity: normal → N/A
Type: defect → task
Flags: needinfo?(mconley)

I've seen the addon decoration regularly, so I'd say this is not happening in current browsers. But not sure!

Yeah, this bug is wayyyy invalid at this point. The add-on shims got pulled out after we switched to WebExtensions-only in 57. Nothing to do here!

Status: NEW → RESOLVED
Closed: 2 years ago
Flags: needinfo?(mconley)
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.