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

Side by Side Diff: runtime/vm/flow_graph_builder.h

Issue 179443004: VM: Replace StoreVMField with StoreInstanceField. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_FLOW_GRAPH_BUILDER_H_ 5 #ifndef VM_FLOW_GRAPH_BUILDER_H_
6 #define VM_FLOW_GRAPH_BUILDER_H_ 6 #define VM_FLOW_GRAPH_BUILDER_H_
7 7
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "platform/globals.h" 9 #include "platform/globals.h"
10 #include "vm/allocation.h" 10 #include "vm/allocation.h"
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 // This implementation shares state among visitors by using the builder. 311 // This implementation shares state among visitors by using the builder.
312 // The implementation is incorrect if a visitor that hits a return is not 312 // The implementation is incorrect if a visitor that hits a return is not
313 // actually added to the graph. 313 // actually added to the graph.
314 void AddReturnExit(intptr_t token_pos, Value* value); 314 void AddReturnExit(intptr_t token_pos, Value* value);
315 315
316 protected: 316 protected:
317 Definition* BuildStoreTemp(const LocalVariable& local, Value* value); 317 Definition* BuildStoreTemp(const LocalVariable& local, Value* value);
318 Definition* BuildStoreExprTemp(Value* value); 318 Definition* BuildStoreExprTemp(Value* value);
319 Definition* BuildLoadExprTemp(); 319 Definition* BuildLoadExprTemp();
320 320
321 Definition* BuildStoreLocal(const LocalVariable& local, 321 Definition* BuildStoreLocal(const LocalVariable& local, Value* value);
322 Value* value,
323 bool result_is_needed);
324 Definition* BuildLoadLocal(const LocalVariable& local); 322 Definition* BuildLoadLocal(const LocalVariable& local);
325 323
326 void HandleStoreLocal(StoreLocalNode* node, bool result_is_needed);
327
328 // Helpers for translating parts of the AST. 324 // Helpers for translating parts of the AST.
329 void BuildPushArguments(const ArgumentListNode& node, 325 void BuildPushArguments(const ArgumentListNode& node,
330 ZoneGrowableArray<PushArgumentInstr*>* values); 326 ZoneGrowableArray<PushArgumentInstr*>* values);
331 327
332 // Creates an instantiated type argument vector used in preparation of an 328 // Creates an instantiated type argument vector used in preparation of an
333 // allocation call. 329 // allocation call.
334 // May be called only if allocating an object of a parameterized class. 330 // May be called only if allocating an object of a parameterized class.
335 Value* BuildInstantiatedTypeArguments( 331 Value* BuildInstantiatedTypeArguments(
336 intptr_t token_pos, 332 intptr_t token_pos,
337 const TypeArguments& type_arguments); 333 const TypeArguments& type_arguments);
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 explicit ValueGraphVisitor(FlowGraphBuilder* owner) 459 explicit ValueGraphVisitor(FlowGraphBuilder* owner)
464 : EffectGraphVisitor(owner), value_(NULL) { } 460 : EffectGraphVisitor(owner), value_(NULL) { }
465 461
466 // Visit functions overridden by this class. 462 // Visit functions overridden by this class.
467 virtual void VisitLiteralNode(LiteralNode* node); 463 virtual void VisitLiteralNode(LiteralNode* node);
468 virtual void VisitAssignableNode(AssignableNode* node); 464 virtual void VisitAssignableNode(AssignableNode* node);
469 virtual void VisitConstructorCallNode(ConstructorCallNode* node); 465 virtual void VisitConstructorCallNode(ConstructorCallNode* node);
470 virtual void VisitBinaryOpNode(BinaryOpNode* node); 466 virtual void VisitBinaryOpNode(BinaryOpNode* node);
471 virtual void VisitConditionalExprNode(ConditionalExprNode* node); 467 virtual void VisitConditionalExprNode(ConditionalExprNode* node);
472 virtual void VisitLoadLocalNode(LoadLocalNode* node); 468 virtual void VisitLoadLocalNode(LoadLocalNode* node);
473 virtual void VisitStoreLocalNode(StoreLocalNode* node);
474 virtual void VisitStoreIndexedNode(StoreIndexedNode* node); 469 virtual void VisitStoreIndexedNode(StoreIndexedNode* node);
475 virtual void VisitInstanceSetterNode(InstanceSetterNode* node); 470 virtual void VisitInstanceSetterNode(InstanceSetterNode* node);
476 virtual void VisitThrowNode(ThrowNode* node); 471 virtual void VisitThrowNode(ThrowNode* node);
477 virtual void VisitClosureCallNode(ClosureCallNode* node); 472 virtual void VisitClosureCallNode(ClosureCallNode* node);
478 virtual void VisitStaticSetterNode(StaticSetterNode* node); 473 virtual void VisitStaticSetterNode(StaticSetterNode* node);
479 virtual void VisitStoreStaticFieldNode(StoreStaticFieldNode* node); 474 virtual void VisitStoreStaticFieldNode(StoreStaticFieldNode* node);
480 virtual void VisitTypeNode(TypeNode* node); 475 virtual void VisitTypeNode(TypeNode* node);
481 virtual void VisitLetNode(LetNode* node); 476 virtual void VisitLetNode(LetNode* node);
482 477
483 Value* value() const { return value_; } 478 Value* value() const { return value_; }
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
560 // Output parameters. 555 // Output parameters.
561 GrowableArray<TargetEntryInstr**> true_successor_addresses_; 556 GrowableArray<TargetEntryInstr**> true_successor_addresses_;
562 GrowableArray<TargetEntryInstr**> false_successor_addresses_; 557 GrowableArray<TargetEntryInstr**> false_successor_addresses_;
563 558
564 intptr_t condition_token_pos_; 559 intptr_t condition_token_pos_;
565 }; 560 };
566 561
567 } // namespace dart 562 } // namespace dart
568 563
569 #endif // VM_FLOW_GRAPH_BUILDER_H_ 564 #endif // VM_FLOW_GRAPH_BUILDER_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698