Closed Bug 991217 Opened 10 years ago Closed 10 years ago

Assertion failure: IsCompatibleLIRCoercion(def->type(), as->type()), at jit/shared/Lowering-shared-inl.h:195 or Crash on Heap with invalid read/write

Categories

(Core :: JavaScript Engine: JIT, defect)

x86_64
Linux
defect
Not set
critical

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox30 --- disabled
firefox31 --- disabled
firefox32 --- disabled
firefox33 --- disabled
firefox34 --- affected
firefox-esr24 --- unaffected

People

(Reporter: decoder, Assigned: nmatsakis)

Details

(4 keywords, Whiteboard: [jsbugmon:ignore])

Attachments

(1 file, 1 obsolete file)

The following testcase asserts on mozilla-central revision 4941a2ac0786 (threadsafe build, run with --fuzzing-safe --thread-count=2):


gczeal(4);
setJitCompilerOption("ion.usecount.trigger", 30);
var N2 = 150;
var T = TypedObject;
var Array2 = T.uint32.array(N2);
function foo() {
  var array2 = new Array2();
  for (var i = 0; i < 0x0451 << 0x7fffffff; array2++)
    array1[i] = i + 1;
  for (var i = 0; i < N2; i++)
    array2[i] = i + 2;
}
foo();
Crashes release builds with crashes on the heap, e.g.:

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7e51fa5 in ?? ()
(gdb) x /i $pc
=> 0x7ffff7e51fa5:      mov    0x30(%rcx),%r11
(gdb) info reg rcx
rcx            0xfffbfffff4a65040       -1125900097269696


Crashes look dangerous, marking s-s.
Keywords: crash
Whiteboard: [jsbugmon:update,bisect]
Assignee: nobody → nmatsakis
Whiteboard: [jsbugmon:update,bisect] → [jsbugmon:update]
JSBugMon: Bisection requested, result:
autoBisect shows this is probably related to the following changeset:

The first bad revision is:
changeset:   http://hg.mozilla.org/mozilla-central/rev/b2ed6214694f
user:        Nicholas D. Matsakis
date:        Mon Feb 10 14:48:51 2014 -0500
summary:     Bug 898356 Part 4 -- Check for neutered typed object unless the check is covered by a length check r=jandem

This iteration took 2.614 seconds to run.
Niko, can you look at this? Thanks!
Flags: needinfo?(nmatsakis)
Group: javascript-core-security
Niko, any update here? Does this only affect typed objects?
Whiteboard: [jsbugmon:update] → [jsbugmon:update,ignore]
JSBugMon: The testcase found in this bug no longer reproduces (tried revision 48eee276b1ee).
Whiteboard: [jsbugmon:update,ignore] → [jsbugmon:bisectfix]
Test seems to be intermittent, this still reproduces sometimes, even in JSBugMon.
Whiteboard: [jsbugmon:bisectfix] → [jsbugmon:ignore]
Attached patch Bug991217.diff (obsolete) — Splinter Review
Attachment #8469563 - Flags: review?(jdemooij)
Flags: needinfo?(nmatsakis)
Comment on attachment 8469563 [details] [diff] [review]
Bug991217.diff

Attached patch to wrong bug.
Attachment #8469563 - Attachment is obsolete: true
Attachment #8469563 - Flags: review?(jdemooij)
Flags: needinfo?(nmatsakis)
I did some investigation of this problem but was not yet able to reproduce. It is almost certainly similar to bug 1029130 -- that is, it could be fixed by an object policy on an appropriate node. (Maybe even a dup.)
Flags: needinfo?(nmatsakis)
Christian, can you still reproduce this?
Flags: needinfo?(choller)
Doesn't seem to reproduce anymore, marking WFM :)
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → WORKSFORME
Flags: needinfo?(choller)
Group: javascript-core-security
Group: core-security → core-security-release
Group: core-security-release
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: