Closed
Bug 605452
Opened 14 years ago
Closed 14 years ago
Crash at [@ js::mjit::ic::GetProp ] when switching tabs
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
mozilla2.0b7
Tracking | Status | |
---|---|---|
blocking2.0 | --- | beta7+ |
People
(Reporter: ehsan.akhgari, Assigned: dvander)
References
Details
(Keywords: crash, reproducible, Whiteboard: fixed-in-tracemonkey)
Crash Data
Attachments
(1 file, 1 obsolete file)
2.80 KB,
patch
|
dvander
:
review+
|
Details | Diff | Splinter Review |
I got this crash after updating to today's nightly build twice when switching tabs:
bp-eb07cb8e-084d-4e7f-a873-7eaf12101019
bp-4b6d5987-b979-4a48-93b0-7a0862101019
I have BarTab installed, and the crash happened as soon as I clicked a tab to load it for the first time after a restart.
Reporter | ||
Comment 1•14 years ago
|
||
I could reproduce this very easily by just restarting, and trying to load 2 or 3 tabs.
Comment 3•14 years ago
|
||
Hardware: x86 → x86_64
Comment 4•14 years ago
|
||
(In reply to comment #2)
> I get this crash when I try to load Gmail.
I'm experiencing the same problem.
http://crash-stats.mozilla.com/report/index/bp-b74d280e-9082-4e26-a8ca-982772101019
http://crash-stats.mozilla.com/report/index/bp-cc8d405b-245f-4f99-96c5-608052101019
Gmail was really slow to load, causing the "This is taking longer than usual..." page to display. When I clicked the "Try reloading the page" link, it crashed. This was reproducable.
Comment 5•14 years ago
|
||
also confirming on the 10/19 build 64-bit. For me, i was trying to do session restore
Build identifier: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b8pre) Gecko/20101019 Firefox/4.0b8pre
http://crash-stats.mozilla.com/report/index/bp-23d7ebe5-935b-4919-ab4f-9020c2101019
Crashing Thread
Frame Module Signature [Expand] Source
0 XUL js::mjit::ic::GetProp js/src/jsobj.h:1046
1 @0x1302cb67e
Updated•14 years ago
|
blocking2.0: --- → ?
Comment 6•14 years ago
|
||
Seems to crash firefox when trying to open firefox...
See http://crash-stats.mozilla.com/report/index/bp-c795fd86-b0b5-4df7-b6ac-778832101019
Comment 7•14 years ago
|
||
I meant when opening gmail ;)
Updated•14 years ago
|
Assignee: general → dvander
blocking2.0: ? → beta7+
Comment 9•14 years ago
|
||
Can reproduce with a tinderbox build of
http://hg.mozilla.org/tracemonkey/rev/759533cf3c38
![]() |
Assignee | |
Comment 10•14 years ago
|
||
This looks like some kind of register allocation bug. I'm not yet sure of the details - I can only reproduce this in optimized builds. But I think I can see where we go wrong.
; JSOP_GETGNAME, Load global slot into (t=R12, d=R10)
b42b: mov 0x750(%r12), %r12 ; Load global variable
b433: mov %r14, %r10 ; R10 = payload mask
b436: and %r12, %r10 ; Convert R10 to R12's payload
b439: xor %r10, %r12 ; Convert R12 to R12's type
; Store value (t=R12, d=R10) into slot 0xA8.
b43c: mov %r12, %r15 ; ValueReg = type tag in R12
b43f: or %r10, %r15 ; Give ValueReg R10's payload
b442: mov %r15, 0x18(%rbx) ; Store value into slot
; JSOP_GETARGPROP
; Load value from formal argument vector.
b449: mov -0x8(%rbx), %r12 ; Load formal argument
b44d: and %r14, %r12 ; Convert R12 to a payload
! b450: mov %r10, %r15 ; Set ValueReg = type tag in R10
b453: or %r12, %r15 ; Tag R12 payload with R10
b456: mov %r15, 0xb0(%rbx) ; Store value into stack slot
Something bogus happened on the ! line. R10 is a payload from the previous instruction, but it's expecting a type tag. The new value becomes something invalid, which I can remat with ($rbx - 8) | $r10. However, the stack slot at 0xb0 has a payload, which is confusing. Maybe it got added somewhere else.
Still investigating.
Comment 11•14 years ago
|
||
Happens on Linux as well (I was using 64bit), when loading gmail, on latest nightly.
Updated•14 years ago
|
Keywords: reproducible
![]() |
Assignee | |
Comment 12•14 years ago
|
||
Revised analysis.
; JSOP_GETGNAME, Load global slot into (t=R12, d=R10)
b42b: mov 0x750(%r12), %r12 ; Load global variable
b433: mov %r14, %r10 ; R10 = payload mask
b436: and %r12, %r10 ; Convert R10 to R12's payload
b439: xor %r10, %r12 ; Convert R12 to R12's type
; JSOP_GETARGPROP calls FrameState::push(Address)
; 1. allocReg(DATA) evicts R12.
b43c: mov %r12, %r15 ; ValueReg = type tag in R12
b43f: or %r10, %r15 ; Give ValueReg R10's payload
b442: mov %r15, 0x18(%rbx) ; Store value into slot
; 2. Load arg payload into R12.
b449: mov -0x8(%rbx), %r12 ; Load formal argument
b44d: and %r14, %r12 ; Convert R12 to a payload
; 3. allocReg(TYPE) evicts R10.
! b450: mov %r10, %r15 ; Set ValueReg = type tag in R10
b453: or %r12, %r15 ; Tag R12 payload with R10
b456: mov %r15, 0xb0(%rbx) ; Store value into stack slot
This is push(Address) being wonky and mostly wrong. I'll try a fix, and a test case.
Comment 13•14 years ago
|
||
(In reply to comment #11)
If this issue is the same as what occurs on Linux, here is the regression range:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=1d7cd2d8b830&tochange=0a8ccb9ecdce
![]() |
Assignee | |
Comment 14•14 years ago
|
||
This bug has existed since the beginning of JM. The problem is that FrameState::push(Address) creates an uninitialized FrameEntry, and fills it in incrementally by allocating registers one at a time. When allocating the second register, it can evict the first.
On x64, this is really bad, since FEs are always synced in whole, and half of the FE is uninitialized. On x86, there *may* be some bug here, but I suspect it's okay (if not sketchy) because FEs are synced in halves.
Anyway, this patch fixes the logic for both platforms. I've verified that gmail no longer crashes on my machine.
Attachment #484581 -
Flags: review?(sstangl)
![]() |
Assignee | |
Updated•14 years ago
|
Attachment #484581 -
Flags: review?(dmandelin)
Comment 15•14 years ago
|
||
Comment on attachment 484581 [details] [diff] [review]
fix
breakValueIntoComponents() does not have to exist, and x64 does not need to pin address.base:
the code within FrameState::push(Address) in the #ifdef JSPUNBOX_64 section can merely be:
> RegisterID typeReg = allocReg();
> RegisterID dataReg = allocReg();
> // Note that address.base is still valid, since eviction does not clobber.
> masm.loadValueAsComponents(address, typeReg, dataReg);
r+ with changes.
Attachment #484581 -
Flags: review?(sstangl) → review+
Updated•14 years ago
|
Attachment #484581 -
Flags: review?(dmandelin) → review+
![]() |
Assignee | |
Comment 16•14 years ago
|
||
patch to checkin
Attachment #484581 -
Attachment is obsolete: true
Attachment #484593 -
Flags: review+
![]() |
Assignee | |
Comment 17•14 years ago
|
||
Whiteboard: fixed-in-tracemonkey
Comment 18•14 years ago
|
||
Is it possible that this could also be showing up as a crash sans symbols, like: http://crash-stats.mozilla.com/report/index/1aeae141-c5d0-4a74-b4be-c17a72101020
Comment 19•14 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Comment 20•14 years ago
|
||
How are we tracking these bugs which have been FIXED on mozilla-central but haven't yet landed on the relbranch?
![]() |
Assignee | |
Comment 21•14 years ago
|
||
(In reply to comment #18)
Yes, this is most likely the same crash. It could also show up under the "EnterMethodJIT" signature, or just about anything else, but keep in mind it was x64 only.
Updated•14 years ago
|
Target Milestone: --- → mozilla2.0b7
Updated•14 years ago
|
Crash Signature: [@ js::mjit::ic::GetProp ]
You need to log in
before you can comment on or make changes to this bug.
Description
•