Closed
Bug 1207642
Opened 10 years ago
Closed 10 years ago
Crash at hex address on Android x86 from JNI stack misalignment
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox40 unaffected, firefox41- wontfix, firefox42+ fixed, firefox43+ fixed, firefox44+ fixed, fennec41+)
RESOLVED
FIXED
Firefox 44
People
(Reporter: kbrosnan, Assigned: jchen)
References
Details
(Keywords: crash, topcrash-android-x86)
Crash Data
Attachments
(5 files, 1 obsolete file)
|
152.32 KB,
text/plain
|
Details | |
|
5.17 MB,
video/quicktime
|
Details | |
|
48.83 KB,
patch
|
jchen
:
review+
Sylvestre
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
|
47.63 KB,
patch
|
jchen
:
review+
Sylvestre
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
|
65.54 KB,
patch
|
jchen
:
review+
|
Details | Diff | Splinter Review |
We have a crash that is taking up 27 of the top 50 spots after a day of reporting. All the crashes are at a hex address.
| Reporter | ||
Updated•10 years ago
|
Crash Signature: [ @0x82c27a8c]
[ @0x69127a8c]
[ @0x6ad27a8c]
[ @0x69227a8c]
[ @0x6a727a8c]
[ @0x6ac27a8c]
[ @0x4007ec79]
[ @0x69627a8c]
[ @0x83227a8c]
[ @0x828a3935]
[ @0x82d27a8c]
[ @0x5da27a8c]
[ @0x6a827a8c]
[ @0x83127a8c]
[ @0x6b227a8c]
[ @0x69327a8c]
… → [@ @0x82c27a8c]
[@ @0x69127a8c]
[@ @0x6ad27a8c]
[@ @0x69227a8c]
[@ @0x6a727a8c]
[@ @0x6ac27a8c]
[@ @0x4007ec79]
[@ @0x69627a8c]
[@ @0x83227a8c]
[@ @0x828a3935]
[@ @0x82d27a8c]
[@ @0x5da27a8c]
[@ @0x6a827a8c]
[@ @0x83127a8c]
[@ @0x6b227a8c]
…
Comment 1•10 years ago
|
||
We had this reported recently in #mobile. See also Bug 1201310 and particularly Bug 1031657, which includes crashreport links for x86.
tracking-fennec: --- → ?
Comment 2•10 years ago
|
||
this seems to happen mainly (95%) on devices with a Imagination Technologies gpu - the most frequent crashing device (27% of all crashers) is the ASUS MeMO Pad FHD 10 (ME302C)...
https://crash-stats.mozilla.com/search/?product=FennecAndroid&version=41.0&signature=%24%40&_facets=signature&_facets=android_device&_facets=android_version&_facets=android_manufacturer&_facets=adapter_vendor_id&_facets=adapter_device_id&_columns=date&_columns=signature&_columns=product&_columns=version&_columns=build_id&_columns=platform#facet-adapter_vendor_id
Updated•10 years ago
|
Assignee: nobody → snorp
Status: NEW → ASSIGNED
tracking-fennec: ? → 41+
| Reporter | ||
Comment 3•10 years ago
|
||
Snorp, you were going to order a MeMoPad. Do you have an order in?
Comment 4•10 years ago
|
||
Yeah, I couldn't reproduce on the x86 phone I have here. I ordered a MeMoPad: http://www.amazon.com/gp/product/B00DXFDHV8?psc=1&redirect=true&ref_=od_aui_detailpages00
| Reporter | ||
Comment 5•10 years ago
|
||
Ioana would you work with the SV team to test this on x86 devices. I'll send you URLs from the crash reports, though we don't know if URLs are key to reproduce this.
Flags: needinfo?(ioana.chiorean)
Was able to reproduce this crash just browsing on facebook.com, or http://www.ayzdorov.ru/lechenie_ykys_blohi.php, or just about:crashes. No specific steps, just panning and zooming.
Device: ZTE Grand X In (Android 4.0.4)
Crash: https://crash-stats.mozilla.com/report/index/fc1f91ad-fa96-4309-bf86-55c522150929
Attaching logcat
Flags: needinfo?(ioana.chiorean)
Updated•10 years ago
|
Comment 7•10 years ago
|
||
Using a ME302C, Firefox crashes very often (mostly on first or second visited page) and is not usable. It seems to me that the crashes occur when scrolling or loading a page. If I stay idle on a loaded page it does not seem to crash. Previous version was not crashing, Fx Beta is crashing the same way.
Snorp, do we better understand this issue now? This was mentioned in channel meeting as a top crash on Mobile. It would be nice if we had a potential fix in the works soon.
Flags: needinfo?(snorp)
Comment 10•10 years ago
|
||
KaiRo, I was looking at the crash-state page and this report https://crash-stats.mozilla.com/report/list?product=FennecAndroid&range_value=7&range_unit=days&date=2015-10-07&signature=%400x82c27a8c&version=FennecAndroid%3A41.0.
Based on product info, does it mean this is not happening on 41.0.1 or is product version 41.0 the same as 41.0.1 now?
Flags: needinfo?(kairo)
| Reporter | ||
Comment 11•10 years ago
|
||
Firefox for Android did not build a 41.0.1.
Comment 13•10 years ago
|
||
Margaret, Snorp seems busy, do you know who else could help? thanks
Flags: needinfo?(margaret.leibovic)
Comment 14•10 years ago
|
||
This is a causing a huge spike in term of crashes.
Keywords: topcrash-android-x86
Comment 15•10 years ago
|
||
(In reply to Sylvestre Ledru [:sylvestre] from comment #13)
> Margaret, Snorp seems busy, do you know who else could help? thanks
Snorp is PTO, but I think he should be back Monday. But maybe jchen can help take a look or redirect in the meantime...
Flags: needinfo?(margaret.leibovic) → needinfo?(nchen)
| Assignee | ||
Comment 16•10 years ago
|
||
We suspect the random hex address is a problem with breakpad not generating valid crash reports. Bug 1069556 may fix that; it wouldn't fix the underlying cause of the crashes but would let us identify the crashes better.
Depends on: 1069556
Flags: needinfo?(nchen)
Comment 17•10 years ago
|
||
A very similar crash affects Samsung GT-i9195/European LTE devices (I know because v41.0 was delivered by autoupdate this evening). Firefox starts up, but crashes after idling on the home screen for perhaps a second or so. Failure is too quick to permit accessing any menus. Crashes, sends crash report, crashes.
FF is installed on the SD card, claims to have 57MB of "data" somewhere in device storage but I'm unwilling to wipe this for fear of destroying bookmarks etc. The GT-i9195 is not an x86 device and doesn't have an Imagination Technologies CPU either so this is probably a red herring. (Qualcomm Snapdragon 400/Adreno 305, ARM arch.)
Comment 18•10 years ago
|
||
Sorry, GPU. The point stands; the GPU is a Qualcomm Adreno 305.
Comment 19•10 years ago
|
||
Margaret, Jim, there is a small chance that I will do another dot release for 41 in a day or two. Based on comment 16 and the fact that this is a top-crash on Fennec, do you think we will have a fix ready for uplift soon (today at best)?
Flags: needinfo?(nchen)
Flags: needinfo?(margaret.leibovic)
Comment 20•10 years ago
|
||
I have the ASUS device in question and can't get it to crash. I'm going to try applying the system update and see if that changes things.
Flags: needinfo?(snorp)
Comment 21•10 years ago
|
||
(In reply to Ritu Kothari (:ritu) from comment #19)
> Margaret, Jim, there is a small chance that I will do another dot release
> for 41 in a day or two. Based on comment 16 and the fact that this is a
> top-crash on Fennec, do you think we will have a fix ready for uplift soon
> (today at best)?
It doesn't look like there's been significant progress here, so I'm skeptical we'll have a patch soon. I defer to snorp.
Flags: needinfo?(margaret.leibovic)
Comment 22•10 years ago
|
||
New signature after latest update: https://crash-stats.mozilla.com/report/list?signature=%400x83326bac
Comment 23•10 years ago
|
||
Attached a small video, in case it can help. The crash can be triggered quite easily by hiding/displaying the address bar (when scrolling) once or twice
| Assignee | ||
Comment 24•10 years ago
|
||
I looked at a Nightly crash dump and the crash was due to a SSE2 instruction accessing misaligned data, due to a misaligned stack pointer. The stack stays in libxul then goes to libdvm, so it's likely that the stack misalignment happened when libdvm calls the JNI entry point in libxul. In particular, this commit in Dalvik [1] from Honeycomb was about fixing a stack misalignment bug, so I think some x86 devices don't have this fix in their Dalvik builds (sigh). I think we can work around the Dalvik bug by telling GCC to fix the stack manually.
[1] https://github.com/android/platform_dalvik/commit/4570ad0a7706d3338d58bd0204e102719e4d68fb
Flags: needinfo?(nchen)
| Assignee | ||
Comment 25•10 years ago
|
||
Assuming comment 24 is the real cause of the crashes, this patch should work.
It uses the force_align_arg_pointer attribute to force realigning stack at JNI
entry points. Because of recent JNI changes, We will need separate patches for
aurora and beta.
Attachment #8675838 -
Flags: review?(snorp)
Updated•10 years ago
|
Attachment #8675838 -
Flags: review?(snorp) → review+
Comment 26•10 years ago
|
||
Jim, I guess we want that to land asap.
Could you fill the uplift request to aurora and beta? Thanks
Flags: needinfo?(nchen)
Keywords: checkin-needed
| Assignee | ||
Comment 27•10 years ago
|
||
Try for checkin: https://treeherder.mozilla.org/#/jobs?repo=try&revision=905b167794c6
Flags: needinfo?(nchen)
| Assignee | ||
Comment 28•10 years ago
|
||
Approval Request Comment
[Feature/regressing bug #]: N/A
[User impact if declined]: Random crashes on x86 devices
[Describe test coverage new/current, TreeHerder]: Tested locally
[Risks and why]: Very small; patch makes trivial changes to compiled code
[String/UUID change made/needed]: None
Attachment #8676417 -
Flags: review+
Attachment #8676417 -
Flags: approval-mozilla-aurora?
| Assignee | ||
Comment 29•10 years ago
|
||
Approval Request Comment
[Feature/regressing bug #]: N/A
[User impact if declined]: Random crashes on x86 devices
[Describe test coverage new/current, TreeHerder]: Tested locally
[Risks and why]: Very small; patch makes trivial changes to compiled code
[String/UUID change made/needed]: None
Attachment #8676418 -
Flags: review+
Attachment #8676418 -
Flags: approval-mozilla-beta?
Comment 30•10 years ago
|
||
this failed to apply:
renamed 1207642 -> Bug-1207642---Work-around-Dalvik-bug-by-realigning.patch
applying Bug-1207642---Work-around-Dalvik-bug-by-realigning.patch
patching file mozglue/android/nsGeckoUtils.cpp
Hunk #2 FAILED at 68
1 out of 2 hunks FAILED -- saving rejects to file mozglue/android/nsGeckoUtils.cpp.rej
patch failed, unable to continue (try -v)
patch failed, rejects left in working directory
errors during apply, please fix and refresh Bug-1207642---Work-around-Dalvik-bug-by-realigning.patch
Flags: needinfo?(snorp)
Keywords: checkin-needed
Comment 31•10 years ago
|
||
Jim can you fix this up for uplift
Flags: needinfo?(snorp) → needinfo?(nchen)
| Assignee | ||
Comment 32•10 years ago
|
||
Use the force_align_arg_pointer attribute to force realigning stack at
JNI entry points.
Attachment #8676891 -
Flags: review+
| Assignee | ||
Updated•10 years ago
|
Attachment #8675838 -
Attachment is obsolete: true
| Assignee | ||
Updated•10 years ago
|
Flags: needinfo?(nchen)
Keywords: checkin-needed
Updated•10 years ago
|
Summary: Crash at hex address in Android 41 → x86 only - Crash at hex address in Android
Comment 33•10 years ago
|
||
Keywords: checkin-needed
Comment 34•10 years ago
|
||
Too far in the 41 cycle to do a new dot release, tracking for 42 and we will be doing a 48 beta 9 for this.
| Assignee | ||
Updated•10 years ago
|
Assignee: snorp → nchen
Summary: x86 only - Crash at hex address in Android → Crash at hex address on Android x86 from JNI stack misalignment
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 44
Comment 36•10 years ago
|
||
Comment on attachment 8676417 [details] [diff] [review]
Patch for Aurora
trying to land that again!
Attachment #8676417 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Comment 37•10 years ago
|
||
Comment on attachment 8676418 [details] [diff] [review]
Patch for Beta
Should be in 42 beta 9.
Attachment #8676418 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 38•10 years ago
|
||
Comment 39•10 years ago
|
||
I've verified this on Firefox 42 Beta 9 on ZTE Grand X In (Android 4.0.4):
I wasn't able to reproduce this issue following the steps from comment 6, it seems to be fixed, however we might want to check this in crash-stats to be sure. Marking this verified after checking crash-stats.
Comment 40•10 years ago
|
||
Sigh, this seems to still happen in 42.0b9: See e.g. https://crash-stats.mozilla.com/report/list?signature=%400x4007ed69 or https://crash-stats.mozilla.com/report/list?signature=%400x4007ec79
Comment 41•10 years ago
|
||
Jim, James, any idea ? :/
Status: RESOLVED → REOPENED
Flags: needinfo?(snorp)
Flags: needinfo?(nchen)
Resolution: FIXED → ---
Comment 42•10 years ago
|
||
Unfortunately our device it is a ZTE Grand X In with Android 4.0.4 ( API 15). As I can see the crashes reproduce on API 19 only ( no ZTE listed there either.) So it might be fine for our device. Is there anyone with a API 19 x86 device?
| Assignee | ||
Comment 43•10 years ago
|
||
(In reply to Robert Kaiser (:kairo@mozilla.com) from comment #40)
> Sigh, this seems to still happen in 42.0b9: See e.g.
> https://crash-stats.mozilla.com/report/list?signature=%400x4007ed69 or
> https://crash-stats.mozilla.com/report/list?signature=%400x4007ec79
These two signatures are abort() calls (crash address is 0xdeadbaad). These shouldn't be as frequent as the other ones, and are not covered by the fix.
Flags: needinfo?(nchen)
Comment 44•10 years ago
|
||
Jim, could you open a new bug to follow up with this one? Thanks
Status: REOPENED → RESOLVED
Closed: 10 years ago → 10 years ago
Flags: needinfo?(nchen)
Resolution: --- → FIXED
| Assignee | ||
Updated•9 years ago
|
Flags: needinfo?(nchen)
Flags: needinfo?(snorp)
Updated•4 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•