Bug 117209 - CallFrame::trueCallFrame() should populate the bytecodeOffset when reifying Inlined frames
Summary: CallFrame::trueCallFrame() should populate the bytecodeOffset when reifying I...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Mark Lam
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-04 14:15 PDT by Mark Lam
Modified: 2013-06-06 13:30 PDT (History)
5 users (show)

See Also:


Attachments
the patch. (31.88 KB, patch)
2013-06-06 06:47 PDT, Mark Lam
ggaren: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Lam 2013-06-04 14:15:53 PDT
We should be populating the frame bytecodeOffset when reifying an InlinedFrame.  This removes one caller of CodeBlock::codeOriginForReturn().  Still one more caller remaining before we can remove codeOriginForReturn() completely.
Comment 1 Mark Lam 2013-06-06 06:47:20 PDT
Created attachment 203930 [details]
the patch.

This patch has passed run-javascriptcore-tests and "fast/js fast/regex ietestcenter/JavaScript sputnik" layout tests with a debug build.
Comment 2 Geoffrey Garen 2013-06-06 12:52:24 PDT
Comment on attachment 203930 [details]
the patch.

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

r=me

> Source/JavaScriptCore/dfg/DFGJITCompiler.h:317
> +        unsigned locationBits = CallFrame::Location::encode(index, CallFrame::Location::CodeOriginIndex);

Minor nit: Usually, when we supply a tag to a function call, the tag is first and the data is second.

> Source/JavaScriptCore/interpreter/CallFrame.h:1
> + /*

Please fix.

> Source/JavaScriptCore/interpreter/CallFrame.h:119
> +            enum Decoration {

Maybe a word like "Type" or "LocationType" would be a little more specific.

> Source/JavaScriptCore/interpreter/CallFrame.h:122
> +                InlinedFrame = (1 << 1),

To make this a comment about the location, how about calling this "IsInlinedCode"?
Comment 3 Mark Lam 2013-06-06 13:30:34 PDT
Thanks for there review.  Feedback applied and the patch is landed in r151285: <http://trac.webkit.org/changeset/151285>.