Assertion failure in InlineCache.cpp
See original GitHub issueI discovered this while trying to produce a repro for #6160. The following code when run in ch
hits an assertion in InlineCache.cpp
:
WScript.Attach(() => {
let iter = g();
iter.next();
iter.next();
});
(async () => {
await 777;
await 1206;
WScript.Detach(() => {});
})();
function* g() { yield 0; }
The assertion that was hit is: https://github.com/microsoft/ChakraCore/blob/master/lib/Runtime/Language/InlineCache.cpp#L570
Assert(!needsProtoInvalidation || isProtoRegistered);
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Assertion failure in InlineCache.cpp · Issue #6323 · chakra-core ...
I believe we have a bad interaction between generator functions (which keep an interpreter stack frame on the heap) and the debugger.
Read more >1375435 - Assertion failure: resumePointsEmpty(), at js/src/jit ...
The assertion is in JIT code and I don't know what the implications are if something is wrong there with the inline cache....
Read more >Assertion Error - visual c++ - Stack Overflow
In vc++6.0 MFC Application Project , I will not get the compile Error , but when i run the project ...
Read more >Bug ID: JDK-6956958 assert(is_clean() || is_call_to_compiled ...
The assertion failure was only seen in one test in one configuration. I have no idea (yet) how reproducible this failure is. Here...
Read more >Adventures in gdb « Tim Chevalier's blog
File js/src/jit/BaselineCodeGen.cpp: 2590: bool ... return “record”), and got an assertion failure in the emitGuardNonDoubleType() method in ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@fatcerberus Yep, I already tried to repro this on my branch 🤞 but it’s there as well. It’s more about generators than anything else.
It sounds like #6160 might be the same thing (or at least closely related). I haven’t tried to dig into solutions yet but I hope to take a look sometime this week.
Assuming debugging is enabled for a given session,
JsDiagStartDebugging
is called almost immediately after context creation, and runs continuously until the runtime is freed. This lets me run a debug server over loopback to allow attaching anssj
instance on-demand at any time.I already made this commit in my own repo as a workaround - https://github.com/fatcerberus/minisphere/commit/71ccfc825017c7efb07262fa741fb9015d53b6fb
The only thing that concerned me with that workaround is that in my case, without it, CC hits a failfast (https://github.com/microsoft/ChakraCore/blob/master/lib/Runtime/Debug/DebugContext.cpp#L359) which struck me as a potential security issue I might just be sweeping under the carpet.