Open Bug 1901500 Opened 1 year ago Updated 1 year ago

Remote profiling silently fails to capture a profile when running out of memory

Categories

(DevTools :: Performance Tools (Profiler/Timeline), defect, P3)

defect

Tracking

(Not tracked)

People

(Reporter: florian, Unassigned)

References

(Blocks 1 open bug)

Details

Leave the Gecko Profiler running in Fenix for a long time. At some point decide to capture the profile using remote profiling. Click the capture button, at that point you'll wait for a long time with the interface in a disabled state (while the profile is gathered on the phone) then the "Start Recording" button comes back. If you are lucky, many seconds later a profiler tab will open. If you are not lucky, the only hint that something bad happened will be this message in the browser toolbox console:
Error: Protocol error (NS_ERROR_OUT_OF_MEMORY): Component returned failure code: 0x8007000e (NS_ERROR_OUT_OF_MEMORY) [nsIScriptableUnicodeConverter.ConvertFromUnicode] from: server0.conn0.perfActor5 (resource://devtools/shared/transport/packets.js:152:0)

The out of memory error might be linked to the way we exchange the data between the remote device and devtools client (see Bug 1581963 for switching to a better approach, migrating to the binary protocol).

https://searchfox.org/mozilla-central/rev/b11735b86bb4d416c918e2b2413456561beff50c/devtools/shared/transport/packets.js#152

In any case, the UI should respond correctly when an error occurs. We should be able to simulate another error to address the issue and at least provide a better UX here.

Severity: -- → S3
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.