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

Side by Side Diff: src/compiler/control-builders.h

Issue 1160983004: [turbofan] First step towards sanitizing for-in and making it optimizable. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add some comments. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | src/compiler/control-builders.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_COMPILER_CONTROL_BUILDERS_H_ 5 #ifndef V8_COMPILER_CONTROL_BUILDERS_H_
6 #define V8_COMPILER_CONTROL_BUILDERS_H_ 6 #define V8_COMPILER_CONTROL_BUILDERS_H_
7 7
8 #include "src/compiler/ast-graph-builder.h" 8 #include "src/compiler/ast-graph-builder.h"
9 #include "src/compiler/node.h" 9 #include "src/compiler/node.h"
10 10
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 explicit BlockBuilder(AstGraphBuilder* builder) 124 explicit BlockBuilder(AstGraphBuilder* builder)
125 : ControlBuilder(builder), break_environment_(NULL) {} 125 : ControlBuilder(builder), break_environment_(NULL) {}
126 126
127 // Primitive control commands. 127 // Primitive control commands.
128 void BeginBlock(); 128 void BeginBlock();
129 void EndBlock(); 129 void EndBlock();
130 130
131 // Primitive support for break. 131 // Primitive support for break.
132 void Break() final; 132 void Break() final;
133 133
134 // Compound control commands for conditional break.
135 void BreakWhen(Node* condition, BranchHint = BranchHint::kNone);
136
134 private: 137 private:
135 Environment* break_environment_; // Environment after the block exits. 138 Environment* break_environment_; // Environment after the block exits.
136 }; 139 };
137 140
138 141
139 // Tracks control flow for a try-catch statement. 142 // Tracks control flow for a try-catch statement.
140 class TryCatchBuilder final : public ControlBuilder { 143 class TryCatchBuilder final : public ControlBuilder {
141 public: 144 public:
142 explicit TryCatchBuilder(AstGraphBuilder* builder) 145 explicit TryCatchBuilder(AstGraphBuilder* builder)
143 : ControlBuilder(builder), 146 : ControlBuilder(builder),
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 Environment* finally_environment_; // Environment for the 'finally' body. 189 Environment* finally_environment_; // Environment for the 'finally' body.
187 Node* token_node_; // Node for token in 'finally' body. 190 Node* token_node_; // Node for token in 'finally' body.
188 Node* value_node_; // Node for value in 'finally' body. 191 Node* value_node_; // Node for value in 'finally' body.
189 }; 192 };
190 193
191 } // namespace compiler 194 } // namespace compiler
192 } // namespace internal 195 } // namespace internal
193 } // namespace v8 196 } // namespace v8
194 197
195 #endif // V8_COMPILER_CONTROL_BUILDERS_H_ 198 #endif // V8_COMPILER_CONTROL_BUILDERS_H_
OLDNEW
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | src/compiler/control-builders.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698