Closed Bug 734718 Opened 10 years ago Closed 3 years ago

java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method) at org.mozilla.gecko.BrowserToolbarBackground.draw(BrowserToolbarBackground.java)

Categories

(Firefox for Android Graveyard :: General, defect)

15 Branch
ARM
Android
defect
Not set
critical

Tracking

(firefox19 affected, firefox20 affected, firefox21 affected, blocking-fennec1.0 -)

RESOLVED WONTFIX
Firefox 19
Tracking Status
firefox19 --- affected
firefox20 --- affected
firefox21 --- affected
blocking-fennec1.0 --- -

People

(Reporter: scoobidiver, Unassigned)

Details

(Keywords: crash, regression, reproducible, Whiteboard: [native-crash][ARMv6])

Crash Data

Attachments

(1 file)

It's similar to bug 733101 and occurs after the fix of bug 707675.

There's one crash in 13.0a1/20120309: bp-653b4434-49d8-4924-bd47-20cfc2120310.

java.lang.OutOfMemoryError: bitmap size exceeds VM budget
	at android.graphics.Bitmap.nativeCreate(Native Method)
	at android.graphics.Bitmap.createBitmap(Bitmap.java:507)
	at org.mozilla.gecko.GeckoAppShell$4.run(GeckoAppShell.java:500)
	at android.os.Handler.handleCallback(Handler.java:587)
	at android.os.Handler.dispatchMessage(Handler.java:92)
	at android.os.Looper.loop(Looper.java:123)
	at org.mozilla.gecko.GeckoBackgroundThread.run(GeckoBackgroundThread.java:31)

More reports at:
https://crash-stats.mozilla.com/report/list?signature=java.lang.OutOfMemoryError%3A%20bitmap%20size%20exceeds%20VM%20budget%20at%20android.graphics.Bitmap.nativeCreate%28Native%20Method%29
blocking-fennec1.0: --- → -
Crash Signature: [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method) ] → [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method)]
It disappeared after 13.0a2/20120424 and reappeared from 15.0a1/20120427. The regression range might be:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=cc5254f9825f&tochange=450d8cd16316
blocking-fennec1.0: - → ?
Version: Trunk → Firefox 15
blocking-fennec1.0: ? → +
Sriram - Can you try to reproduce this?
Assignee: nobody → sriram
minusing 2 crashes in beta. If this is fixed this we would still consider uplifting if a patch appears.
blocking-fennec1.0: + → -
Crash Signature: [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method)] → [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method)] [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget(Heap Size=32711KB, Allocated=30105KB Bitmap Size=295KB) at android.graphics.…
It's #48 top crasher in 14.0.
It's possible, but far from certain, we by calling this code often we just keep a lot of bitmaps around and the GCs doesn't reclaim them fast enough and boom we crash.

There's no harm in trying this as this should make things strictly better.
Attachment #677078 - Flags: review?(bugmail.mozilla)
Comment on attachment 677078 [details] [diff] [review]
patch - shot in the dark

Review of attachment 677078 [details] [diff] [review]:
-----------------------------------------------------------------

Patch looks good to me. Also cc'ing sriram since this is his code.
Attachment #677078 - Flags: review?(bugmail.mozilla) → review+
Scoobidiver should we close the bug and reopen if we get more crashes or leave it open and close if we don't?
(In reply to Benoit Girard (:BenWa) from comment #9)
> Scoobidiver should we close the bug and reopen if we get more crashes or
> leave it open and close if we don't?
The first one. Let's assume it's going to be fixed. That will be easy to check as Nightly is affected, by a single user nevertheless.

Why do you say it's a shot in the dark while there are STR in comment 1?
I missed over that. I'll check the steps tomorrow.
https://hg.mozilla.org/mozilla-central/rev/3f75a8ea00a6
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 19
It's not fixed.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
It's #3 top crasher in 18.0.2 for ARMv6 devices.
(In reply to Scoobidiver from comment #14)
> It's #3 top crasher in 18.0.2 for ARMv6 devices.

Well, the numbers of this one are not much over the long list of the other signatures following, see https://crash-analysis.mozilla.com/rkaiser/2013-02-13/2013-02-13.fennecandroid.18.0.2.armv6.topcrash.html - so this being #3 might not really be significant.
It's #82 top crasher in 19.0.2, #51 in 20.0b5, and #22 in 21.0a2.

The stack trace now looks like:
java.lang.OutOfMemoryError: bitmap size exceeds VM budget
	at android.graphics.Bitmap.nativeCreate(Native Method)
	at android.graphics.Bitmap.createBitmap(Bitmap.java:468)
	at org.mozilla.gecko.CanvasDelegate.draw(CanvasDelegate.java:58)
	at org.mozilla.gecko.BrowserToolbarBackground.draw(BrowserToolbarBackground.java:88)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1643)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1641)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1641)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.View.draw(View.java:6759)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1643)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1641)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.ViewGroup.drawChild(ViewGroup.java:1641)
	at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1370)
	at android.view.View.draw(View.java:6759)
	at android.widget.FrameLayout.draw(FrameLayout.java:352)
	at com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:1853)
	at android.view.ViewRoot.draw(ViewRoot.java:1407)
	at android.view.ViewRoot.performTraversals(ViewRoot.java:1163)
	at android.view.ViewRoot.handleMessage(ViewRoot.java:1727)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:123)
	at android.app.ActivityThread.main(ActivityThread.java:4644)
	at java.lang.reflect.Method.invokeNative(Native Method)
	at java.lang.reflect.Method.invoke(Method.java:521)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:878)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)
	at dalvik.system.NativeStart.main(Native Method)

More reports at:
https://crash-stats.mozilla.com/report/list?signature=java.lang.OutOfMemoryError%3A+bitmap+size+exceeds+VM+budget+at+android.graphics.Bitmap.nativeCreate%28Native+Method%29
Summary: java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method) → java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate(Native Method) at org.mozilla.gecko.BrowserToolbarBackground.draw(BrowserToolbarBackground.java)
Whiteboard: [native-crash] → [native-crash][ARMv6]
Assignee: sriram → nobody
Crash Signature: , Bitmap Size=295KB) at android.graphics.Bitmap.nativeCreate(Native Method) ] → , Bitmap Size=295KB) at android.graphics.Bitmap.nativeCreate(Native Method) ] [@ java.lang.OutOfMemoryError: bitmap size exceeds VM budget at android.graphics.Bitmap.nativeCreate]
Closing because no crash reported since 12 weeks.
Status: REOPENED → RESOLVED
Closed: 9 years ago3 years ago
Resolution: --- → WONTFIX
Closing because no crash reported since 12 weeks.
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.