Closed Bug 791398 Opened 7 years ago Closed 7 years ago

Work around profiler OOM'ing on low-memory devices


(Core :: Gecko Profiler, defect)

Gonk (Firefox OS)
Not set





(Reporter: cjones, Assigned: cjones)




(1 file)

+++ This bug was initially created as a clone of Bug #789667 +++

Bug 789667 is the "real" fix, but in the meantime we have developers and partners who need access to *some* profiler on b2g.  Upcoming patch will stop the bleeding.
Assignee: nobody → jones.chris.g
Attachment #661392 - Flags: review?(bgirard)
Lowering the number of entries to 100,000 will give you ~500-2k samples with js enabled and no stackwalking giving a 0.5s-2s buffer at 1ms interval. I'm fine with this to make it usable but it's not really a solution since the buffer will be unusably small.

Is the crash only when saving the profile? If so we should just save to a file stream properly instead of building the whole string.
Comment on attachment 661392 [details] [diff] [review]
Lower the default sample size to prevent OOMs

I don't object to landing this patch very temporarily if you're alright with the caveat I mentioned. I am a bit concerned that a profile with too little samples is just misleading and not statistically significant.
Attachment #661392 - Flags: review?(bgirard) → review+
Another patch in this series bumps the sample interval to 10ms.  Without this patch, we crash 100% while trying to dump the profile.  I agree that the "real fix" is to stream the data, which is what bug 789667 covers.  But without this bandaid, the profiler is 100% unusable on b2g.
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
You need to log in before you can comment on or make changes to this bug.