Bug 148152
| Summary: | OSR exit should have a direct reference to its target CodeBlock | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Geoffrey Garen <ggaren> |
| Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Normal | ||
| Priority: | P2 | ||
| Version: | Other | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Geoffrey Garen
From InlineCallFrame.h:
// FIXME: It's dangerous that OSR exit asks the Executable for a CodeBlock
// instead of having a pointer to a CodeBlock. If the GC discards a
// CodeBlock that we inline, then we will see a different CodeBlock
// at OSR time than we saw at compilation time. This works if compilation
// is mostly pure and the two CodeBlocks are equivalent, but that is a
// fragile thing to rely on.
inline CodeBlock* baselineCodeBlockForInlineCallFrame(InlineCallFrame* inlineCallFrame)
{
RELEASE_ASSERT(inlineCallFrame);
ScriptExecutable* executable = inlineCallFrame->executable.get();
RELEASE_ASSERT(executable->structure()->classInfo() == FunctionExecutable::info());
return static_cast<FunctionExecutable*>(executable)->baselineCodeBlockFor(inlineCallFrame->specializationKind());
}
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |