gecko-dev/js
Jim Blandy 97f7fd3ca4 Bug 1445973: Part 4: Clear the hasCachedSavedFrame bit on a frame when we miss for a pc mismatch. r=jorendorff
We'd really like the LiveSavedFrameCache to be able to assert that, if a frame
has its hasCachedSavedFrame bit set, there is indeed a cache entry for it (if
the cache hasn't been cleared completely for a compartment mismatch). See the
explanation of LiveSavedFrameCache in Stack.h, and the comments in
LiveSavedFrameCache::find.

Sometimes we do find a cache entry for the frame, but execution in that frame
has progressed to a different source position since we cached it, so the
SavedFrame in that cache entry isn't useful. When this occurs, we used to simply
pop the cache entry, and report a miss: although this did create a situation
where a frame with its bit set had no cache entry, that was only temporary: we
would push a new entry for the frame as we build the new SavedFrame chain.

Unless, of course, SavedFrame construction encounters an OOM and the whole
process aborts early.

This patch clears a frame's hasCachedSavedFrame bit when we report a cache miss
due to a pc mismatch. Under normal circumstances, the frame will soon be cached
again and its bit re-set. If an OOM does occur, the absence of the cache entry
is accurately reported.

--HG--
extra : rebase_source : 5e980e5732b7fd5ff1dd6a68c1a49a1c538010c6
extra : source : 2ed6d9d910b0f3dd24e163f17e3a70d327286582
2018-03-29 19:51:18 -07:00
..
ductwork/debugger Bug 1433175 - scripted patch to replace Components.classes[, Components.interfaces.nsI, Components.utils. and Components.results. with Cc, Ci, Cu and Cr, r=Mossop. 2018-02-28 18:51:33 +01:00
examples Bug 1339461 - script-generated patch to convert foo.indexOf(...) == -1 to foo.includes(), r=Mossop. 2018-02-01 20:45:22 +01:00
ipc Bug 1445551: Part 3 - Remove AllowCPOWsInAddon machinery. r=mccr8 2018-03-13 19:20:17 -07:00
public Bug 1428468 - JS::GetValueZone(const Value& value) declared but never defined. r=sfink 2018-04-02 19:47:42 +02:00
rust Bug 1451825 - Update to env_logger 0.5. r=ted 2018-04-05 10:08:05 -07:00
src Bug 1445973: Part 4: Clear the hasCachedSavedFrame bit on a frame when we miss for a pc mismatch. r=jorendorff 2018-03-29 19:51:18 -07:00
xpconnect Merge mozilla-central to inbound. a=merge CLOSED TREE 2018-04-07 13:00:30 +03:00
app.mozbuild Bug 1431090 - Add FuzzingInterface support to JS engine. r=jandem 2018-01-17 17:05:04 +01:00
ffi.configure
moz.build Bug 1403322: Switch jsreftests, jittests, test-verify to SCHEDULES; r=ahal 2017-12-20 00:39:21 +00:00
moz.configure Bug 1440417: Determine JS_64BIT at configure time. r=froydnj 2018-02-22 10:40:00 +02:00