Bug 1234410 - Fix JIT spew assertion when we've hit OOM r=lth

This commit is contained in:
Jon Coppeard 2016-01-19 10:05:07 +00:00
parent 314276ea80
commit 595fb493d7
2 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,10 @@
if (!('oomTest' in this))
quit();
enableSPSProfiling();
oomTest(() => {
try {
for (var quit of oomTest.gcparam("//").ArrayBuffer(1)) {}
} catch (e) {}
});

View File

@ -1276,6 +1276,9 @@ struct JitcodeMapBufferWriteSpewer
{}
void spewAndAdvance(const char* name) {
if (writer->oom())
return;
uint32_t curPos = writer->length();
const uint8_t* start = writer->buffer() + startPos;
const uint8_t* end = writer->buffer() + curPos;