Closed Bug 475146 Opened 15 years ago Closed 15 years ago

Wrong gczeal check in RefillDoubleFreeList

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: igor, Assigned: igor)

References

Details

(Keywords: fixed1.9.1, Whiteboard: fixed-in-tracemonkey)

Attachments

(1 file)

RefillDoubleFreeList from js/src/jsgc.cpp contains:

    if (rt->gcMallocBytes >= rt->gcMaxMallocBytes && rt->gcPoke
#ifdef JS_GC_ZEAL
        && (rt->gcZeal >= 2 || (rt->gcZeal >= 1 && rt->gcPoke))
#endif
        ) {
        goto do_gc;
    }

This is wrong as the the gc zeal check should use ||, not &&, condition. With this bug the gc zeal checks during double allocation becomes effectively disabled.

The patch for bug 474801 fixes this regression from bug 456826 due to yet unclear oranges that it triggers I file this bug separately.
Attached patch v1Splinter Review
The fix uses ||, not &&, in the gczeal check.
Attachment #358582 - Flags: review?(mrbkap)
Comment on attachment 358582 [details] [diff] [review]
v1

Sorry, I should have caught this in review.
Attachment #358582 - Flags: review?(mrbkap) → review+
(In reply to comment #2)
> (From update of attachment 358582 [details] [diff] [review])
> Sorry, I should have caught this in review.

It was I who did a review for the regressed patch. So blame me, no yourself! 

Nominating for 1.9.1 as this is a regression.
Flags: blocking1.9.1?
Flags: blocking1.9.1? → blocking1.9.1+
Keywords: verified1.9.1
landed to TM - http://hg.mozilla.org/tracemonkey/rev/92ddc88a2f16
Whiteboard: fixed-in-tracemonkey
http://hg.mozilla.org/mozilla-central/rev/92ddc88a2f16
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Flags: in-testsuite-
Flags: in-litmus-
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: