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

Side by Side Diff: vm/scopes.h

Issue 10539108: First step to SSA construction: Phi insertion. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: addressed comments, fixed bug in BitVector::Contains Created 8 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 | Annotate | Revision Log
« no previous file with comments | « vm/intermediate_language.cc ('k') | vm/scopes.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_SCOPES_H_ 5 #ifndef VM_SCOPES_H_
6 #define VM_SCOPES_H_ 6 #define VM_SCOPES_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/growable_array.h" 10 #include "vm/growable_array.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 } 67 }
68 68
69 void set_invisible(bool value) { 69 void set_invisible(bool value) {
70 is_invisible_ = value; 70 is_invisible_ = value;
71 } 71 }
72 72
73 bool Equals(const LocalVariable& other) const; 73 bool Equals(const LocalVariable& other) const;
74 74
75 // Map the frame index to a bit-vector index. Assumes the variable is 75 // Map the frame index to a bit-vector index. Assumes the variable is
76 // allocated to the frame. 76 // allocated to the frame.
77 int BitIndexIn(BitVector* vector) const; 77 // var_count is the total number of stack-allocated variables including
78 // all parameters.
79 int BitIndexIn(intptr_t var_count) const;
78 80
79 private: 81 private:
80 static const int kUnitializedIndex = INT_MIN; 82 static const int kUnitializedIndex = INT_MIN;
81 83
82 const intptr_t token_index_; 84 const intptr_t token_index_;
83 const String& name_; 85 const String& name_;
84 LocalScope* owner_; // Local scope declaring this variable. 86 LocalScope* owner_; // Local scope declaring this variable.
85 87
86 const AbstractType& type_; // Declaration type of local variable. 88 const AbstractType& type_; // Declaration type of local variable.
87 89
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 intptr_t end_token_index_; // Token index of end of scope. 331 intptr_t end_token_index_; // Token index of end of scope.
330 GrowableArray<LocalVariable*> variables_; 332 GrowableArray<LocalVariable*> variables_;
331 GrowableArray<SourceLabel*> labels_; 333 GrowableArray<SourceLabel*> labels_;
332 334
333 DISALLOW_COPY_AND_ASSIGN(LocalScope); 335 DISALLOW_COPY_AND_ASSIGN(LocalScope);
334 }; 336 };
335 337
336 } // namespace dart 338 } // namespace dart
337 339
338 #endif // VM_SCOPES_H_ 340 #endif // VM_SCOPES_H_
OLDNEW
« no previous file with comments | « vm/intermediate_language.cc ('k') | vm/scopes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698