Closed Bug 1680241 Opened 5 years ago Closed 5 years ago

script-source-extent.js test is sensitive to GC timing

Categories

(Core :: JavaScript Engine, defect)

defect

Tracking

()

RESOLVED FIXED
85 Branch
Tracking Status
firefox85 --- fixed

People

(Reporter: jonco, Assigned: jonco)

Details

Attachments

(1 file)

While working on bug 1677765 I found that if a GC occurs in the wrong place then this test can fail.

For example, if I add a gc() call after g.evaluate in getScriptSourceExtent, it fails like this:

/Users/jon/work/bug/js/src/jit-test/tests/parser/script-source-extent.js:78:13 Error: Assertion failed: got 1, expected 2
Stack:
  testSourceExtent@/Users/jon/work/bug/js/src/jit-test/tests/parser/script-source-extent.js:78:13
  @/Users/jon/work/bug/js/src/jit-test/tests/parser/script-source-extent.js:240:17

My guess is that some static class field initializer lambdas are no longer reachable after the class has been initialised and are thrown away by GC.

Assignee: nobody → jcoppeard
Status: NEW → ASSIGNED
Pushed by jcoppeard@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e3d78b6d7755 Disable GC zeal in script-source-extent.js test r=tcampbell
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → 85 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: