Closed Bug 627475 Opened 14 years ago Closed 14 years ago

JM: Clean up OOM handling

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: billm, Assigned: billm)

Details

(Whiteboard: fixed-in-tracemonkey)

Attachments

(1 file)

There are still a few places in the methodjit where OOM handling is a little off.
Attached patch patchSplinter Review
This fixes two problems. One is that the execPool->alloc(totalSize) allocation wasn't being checked for OOM. The other is that sometimes we weren't calling js_ReportOutOfMemory for OOMs. For the second fix, I changed the interface for reporting OOMs a little bit. Most OOM errors set one of the following flags: (oomInVector || masm.oom() || stubcc.masm.oom()). In these cases, the compiler returns as quickly as possible to performCompilation, which is responsible for doing ReportOutOfMemory. In all other cases, ReportOutOfMemory should be done as soon as the problem is discovered.
Assignee: general → wmccloskey
Status: NEW → ASSIGNED
Attachment #505492 - Flags: review?(dmandelin)
Attachment #505492 - Flags: review?(dmandelin) → review+
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: