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

Unified Diff: runtime/vm/ast.h

Issue 12212050: Fix allocation of array tables (use store barrier if needed, store values directly instead of via s… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/ast.h
===================================================================
--- runtime/vm/ast.h (revision 18461)
+++ runtime/vm/ast.h (working copy)
@@ -265,17 +265,22 @@
class ArrayNode : public AstNode {
public:
- ArrayNode(intptr_t token_pos, const AbstractType& type)
+ ArrayNode(intptr_t token_pos,
+ const AbstractType& type,
+ const LocalVariable& temp)
: AstNode(token_pos),
type_(type),
+ temp_local_(temp),
elements_() {
CheckFields();
}
ArrayNode(intptr_t token_pos,
const AbstractType& type,
+ const LocalVariable& temp,
const GrowableArray<AstNode*>& elements)
: AstNode(token_pos),
type_(type),
+ temp_local_(temp),
elements_(elements.length()) {
CheckFields();
for (intptr_t i = 0; i < elements.length(); i++) {
@@ -295,10 +300,13 @@
const AbstractType& type() const { return type_; }
+ const LocalVariable& temp_local() const { return temp_local_; }
+
DECLARE_COMMON_NODE_FUNCTIONS(ArrayNode);
private:
const AbstractType& type_;
+ const LocalVariable& temp_local_; // Store allocated array while filling it.
GrowableArray<AstNode*> elements_;
void CheckFields() {
« no previous file with comments | « no previous file | runtime/vm/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698