Bug 129762 - Don't generate bytecode expression range info unless it's needed.
Summary: Don't generate bytecode expression range info unless it's needed.
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Andreas Kling
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-05 15:35 PST by Andreas Kling
Modified: 2014-03-05 15:58 PST (History)
3 users (show)

See Also:


Attachments
Patch (19.87 KB, patch)
2014-03-05 15:42 PST, Andreas Kling
ggaren: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Kling 2014-03-05 15:35:02 PST
Patch a-comin'.
Comment 1 Andreas Kling 2014-03-05 15:42:24 PST
Created attachment 225922 [details]
Patch
Comment 2 Geoffrey Garen 2014-03-05 15:58:38 PST
Comment on attachment 225922 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=225922&action=review

I'd love to see m_metadataForReparse turned into a ParserContext class, which we also pass as input to the parser. That way, the thing we save is the thing we passed to the parser, an it's more obvious that this is right, and harder to change wrong in future.

I'd also love to shared some code with generateFunctionCodeBlock and/or getGlobalCodeBlock for doing this creation dance. My gut says there's some code that could meaningfully be shared -- but I haven't analyzed it fully.

> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.cpp:322
> +void UnlinkedCodeBlock::materializeExpressionInfo()

materializeExpressionInfoIfNecessary?