f005802733
- stores/loads that access different fields can't alias each other; - if result of the AllocateObject does not escape then stores/loads to it does not alias stores/loads to other objects. Other: - rename LoadFieldInstr's value to instance to better convey meaning and match StoreInstanceFieldInstr; - slightly bump inlining_size_threshold; - canonicalize UnboxDouble(BoxDouble(v)) and BoxDouble(UnboxDouble(v)) patterns; R=srdjan@google.com BUG= Review URL: https://codereview.chromium.org//14872002 git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22340 260f80e4-7a28-3924-810f-c04153c831b5
37 lines
954 B
C++
37 lines
954 B
C++
// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
#ifndef VM_FLOW_GRAPH_INLINER_H_
|
|
#define VM_FLOW_GRAPH_INLINER_H_
|
|
|
|
#include "vm/allocation.h"
|
|
|
|
namespace dart {
|
|
|
|
class Field;
|
|
class FlowGraph;
|
|
template <typename T> class GrowableArray;
|
|
|
|
class FlowGraphInliner : ValueObject {
|
|
public:
|
|
FlowGraphInliner(FlowGraph* flow_graph,
|
|
GrowableArray<const Field*>* guarded_fields)
|
|
: flow_graph_(flow_graph), guarded_fields_(guarded_fields) {}
|
|
|
|
// The flow graph is destructively updated upon inlining.
|
|
void Inline();
|
|
|
|
static void CollectGraphInfo(FlowGraph* flow_graph);
|
|
|
|
private:
|
|
FlowGraph* flow_graph_;
|
|
GrowableArray<const Field*>* guarded_fields_;
|
|
|
|
DISALLOW_COPY_AND_ASSIGN(FlowGraphInliner);
|
|
};
|
|
|
|
} // namespace dart
|
|
|
|
#endif // VM_FLOW_GRAPH_INLINER_H_
|