Closed Bug 988097 Opened 10 years ago Closed 10 years ago

Allow OOM testing code to be used in non-debug builds

Categories

(Core :: JavaScript Engine, defect)

x86_64
Linux
defect
Not set
critical

Tracking

()

RESOLVED FIXED
mozilla31
Tracking Status
firefox31 --- fixed

People

(Reporter: decoder, Assigned: decoder)

References

(Blocks 1 open bug)

Details

(Keywords: sec-want, Whiteboard: [qa-][adv-main31-])

Attachments

(1 file)

Attached patch js-oom-opt.patchSplinter Review
In bug 964803, we added the --enable-oom-breakpoint flag, which we can now use to also enable the oomAfterAllocations functionality in --disable-debug builds. Patch attached.
Attachment #8396839 - Flags: review?(jdemooij)
Comment on attachment 8396839 [details] [diff] [review]
js-oom-opt.patch

Review of attachment 8396839 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good.

::: js/public/Utility.h
@@ +61,5 @@
>   */
>  #if defined JS_USE_CUSTOM_ALLOCATOR
>  # include "jscustomallocator.h"
>  #else
> +# if defined(JS_DEBUG) || defined(JS_OOM_BREAKPOINT)

Nit: please use DEBUG instead of JS_DEBUG, here and in the other files. We use JS_DEBUG in a few places, but DEBUG has many more hits so it's good to be consistent :)
Attachment #8396839 - Flags: review?(jdemooij) → review+
https://hg.mozilla.org/mozilla-central/rev/8d521eaf9b65
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla31
Whiteboard: [qa-]
Whiteboard: [qa-] → [qa-][adv-main31-]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: