Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1472)

Issue 9221011: Collect AstNode type information (Closed)

Created:
8 years, 11 months ago by Jakob Kummerow
Modified:
8 years, 10 months ago
CC:
v8-dev
Visibility:
Public.

Description

Collect AstNode type information Committed: https://code.google.com/p/v8/source/detail?r=10631

Patch Set 1 #

Total comments: 1

Patch Set 2 : refactor to AstVisitor approach #

Total comments: 16

Patch Set 3 : review feedback #

Patch Set 4 : removed VariableProxy::ast_properties_ #

Total comments: 27

Patch Set 5 : review feedback (embedded AstProperties and AstConstructionVisitor) #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+1371 lines, -981 lines) Patch
M src/ast.h View 1 2 3 4 77 chunks +817 lines, -363 lines 4 comments Download
M src/ast.cc View 1 2 3 4 5 chunks +166 lines, -231 lines 0 comments Download
M src/compiler.cc View 1 2 3 4 3 chunks +6 lines, -1 line 0 comments Download
M src/heap.cc View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M src/hydrogen.cc View 1 2 3 4 5 chunks +22 lines, -14 lines 0 comments Download
M src/isolate.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M src/objects.h View 1 2 7 chunks +23 lines, -8 lines 0 comments Download
M src/objects-inl.h View 1 2 4 chunks +8 lines, -10 lines 0 comments Download
M src/parser.h View 1 2 3 4 6 chunks +70 lines, -25 lines 0 comments Download
M src/parser.cc View 1 2 3 4 77 chunks +178 lines, -265 lines 0 comments Download
M src/rewriter.cc View 1 2 3 4 5 chunks +18 lines, -15 lines 0 comments Download
M src/scopes.h View 1 2 3 4 6 chunks +33 lines, -9 lines 0 comments Download
M src/scopes.cc View 1 2 3 4 13 chunks +24 lines, -36 lines 0 comments Download
M test/cctest/test-ast.cc View 1 2 3 4 2 chunks +3 lines, -2 lines 0 comments Download

Messages

Total messages: 16 (0 generated)
Jakob Kummerow
Kevin: PTAL. Is this what you had in mind? The new methods aren't used anywhere ...
8 years, 11 months ago (2012-01-17 13:10:45 UTC) #1
Sven Panne
https://chromiumcodereview.appspot.com/9221011/diff/1/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/1/src/ast.h#newcode153 src/ast.h:153: typedef int Flag; Drive-by comment: One could use EnumSet<FlagIndex> ...
8 years, 11 months ago (2012-01-17 13:46:58 UTC) #2
Kevin Millikin (Chromium)
I agree with Sven---I'd do something to avoid the duplication required by the masks. You ...
8 years, 11 months ago (2012-01-17 15:30:20 UTC) #3
Jakob Kummerow
New approach, please take another look. Please disregard the delta from the first patch set, ...
8 years, 10 months ago (2012-01-30 11:02:50 UTC) #4
Vyacheslav Egorov (Chromium)
How about some C++ template magic? class Parser { inline void OnNewNode(AstNode* t) { /* ...
8 years, 10 months ago (2012-01-30 11:48:46 UTC) #5
fschneider
drive-by comments: https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h#newcode2349 src/ast.h:2349: class AstNodeFactory { maybe make it BASE_EMBEDDED. ...
8 years, 10 months ago (2012-01-30 12:10:35 UTC) #6
fschneider
more dbc: https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h#newcode1254 src/ast.h:1254: AstProperties* ast_properties_; It seems quite expensive to ...
8 years, 10 months ago (2012-01-30 13:54:26 UTC) #7
Jakob Kummerow
Thanks for all the feedback; I've uploaded a new revision. https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h#newcode1254 ...
8 years, 10 months ago (2012-02-01 14:46:09 UTC) #8
fschneider
https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h#newcode1254 src/ast.h:1254: AstProperties* ast_properties_; It seems that we only visit the ...
8 years, 10 months ago (2012-02-02 15:54:07 UTC) #9
Jakob Kummerow
Florian: I'm inclined to agree with that analysis :-) New patch set uploaded. https://chromiumcodereview.appspot.com/9221011/diff/4001/src/ast.h File ...
8 years, 10 months ago (2012-02-03 10:06:22 UTC) #10
fschneider
https://chromiumcodereview.appspot.com/9221011/diff/13003/src/ast.cc File src/ast.cc (right): https://chromiumcodereview.appspot.com/9221011/diff/13003/src/ast.cc#newcode1020 src/ast.cc:1020: // proxy()->var()->IsStackAllocated() && fun() == NULL; Forgotten commented code? ...
8 years, 10 months ago (2012-02-06 14:14:29 UTC) #11
Kevin Millikin (Chromium)
https://chromiumcodereview.appspot.com/9221011/diff/13003/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/13003/src/ast.h#newcode2322 src/ast.h:2322: AstProperties* DetachAstProperties(); I don't understand why the AstProperties ownership ...
8 years, 10 months ago (2012-02-06 15:14:22 UTC) #12
Jakob Kummerow
"a minimal change"? Yeah, right ;-) But I agree that the CL looks better now. ...
8 years, 10 months ago (2012-02-07 12:38:36 UTC) #13
fschneider
LGTM.
8 years, 10 months ago (2012-02-07 14:31:49 UTC) #14
Kevin Millikin (Chromium)
LGTM. https://chromiumcodereview.appspot.com/9221011/diff/19001/src/ast.h File src/ast.h (right): https://chromiumcodereview.appspot.com/9221011/diff/19001/src/ast.h#newcode148 src/ast.h:148: kDontCrankshaft, To be pedantic (everybody loves that), "Crankshaft" ...
8 years, 10 months ago (2012-02-08 09:13:18 UTC) #15
Jakob Kummerow
8 years, 10 months ago (2012-02-08 09:51:02 UTC) #16
Thanks for the reviews. 
Nits are fixed, landing.

https://chromiumcodereview.appspot.com/9221011/diff/19001/src/ast.h
File src/ast.h (right):

https://chromiumcodereview.appspot.com/9221011/diff/19001/src/ast.h#newcode148
src/ast.h:148: kDontCrankshaft,
On 2012/02/08 09:13:18, Kevin Millikin wrote:
> To be pedantic (everybody loves that), "Crankshaft" is the name of the entire
> backend, not just the optimizing compiler.  And it's not a verb anyway.  I
> suggest "kDontOptimize".

Done.

https://chromiumcodereview.appspot.com/9221011/diff/19001/src/ast.h#newcode161
src/ast.h:161: explicit AstProperties(const AstProperties& other)
On 2012/02/08 09:13:18, Kevin Millikin wrote:
> Default copy constructor and assignment operator should do the right thing.

Done.

Powered by Google App Engine
This is Rietveld 408576698