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

Side by Side Diff: runtime/vm/constant_propagator.cc

Issue 1756403002: VM: Add smi fast path operations for precompiled code (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: addressed comments Created 4 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
« no previous file with comments | « runtime/vm/aot_optimizer.cc ('k') | runtime/vm/flow_graph_compiler.h » ('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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 #include "vm/constant_propagator.h" 5 #include "vm/constant_propagator.h"
6 6
7 #include "vm/bit_vector.h" 7 #include "vm/bit_vector.h"
8 #include "vm/flow_graph_builder.h" 8 #include "vm/flow_graph_builder.h"
9 #include "vm/flow_graph_compiler.h" 9 #include "vm/flow_graph_compiler.h"
10 #include "vm/flow_graph_range_analysis.h" 10 #include "vm/flow_graph_range_analysis.h"
(...skipping 919 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 SetValue(binary_op, Integer::ZoneHandle(Z, result.raw())); 930 SetValue(binary_op, Integer::ZoneHandle(Z, result.raw()));
931 return; 931 return;
932 } 932 }
933 } 933 }
934 } 934 }
935 935
936 SetValue(binary_op, non_constant_); 936 SetValue(binary_op, non_constant_);
937 } 937 }
938 938
939 939
940 void ConstantPropagator::VisitCheckedSmiOp(CheckedSmiOpInstr* instr) {
941 SetValue(instr, non_constant_);
942 }
943
944
940 void ConstantPropagator::VisitBinarySmiOp(BinarySmiOpInstr* instr) { 945 void ConstantPropagator::VisitBinarySmiOp(BinarySmiOpInstr* instr) {
941 VisitBinaryIntegerOp(instr); 946 VisitBinaryIntegerOp(instr);
942 } 947 }
943 948
944 949
945 void ConstantPropagator::VisitBinaryInt32Op(BinaryInt32OpInstr* instr) { 950 void ConstantPropagator::VisitBinaryInt32Op(BinaryInt32OpInstr* instr) {
946 VisitBinaryIntegerOp(instr); 951 VisitBinaryIntegerOp(instr);
947 } 952 }
948 953
949 954
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after
1680 graph_->MergeBlocks(); 1685 graph_->MergeBlocks();
1681 GrowableArray<BitVector*> dominance_frontier; 1686 GrowableArray<BitVector*> dominance_frontier;
1682 graph_->ComputeDominators(&dominance_frontier); 1687 graph_->ComputeDominators(&dominance_frontier);
1683 1688
1684 if (FLAG_trace_constant_propagation) { 1689 if (FLAG_trace_constant_propagation) {
1685 FlowGraphPrinter::PrintGraph("After CP", graph_); 1690 FlowGraphPrinter::PrintGraph("After CP", graph_);
1686 } 1691 }
1687 } 1692 }
1688 1693
1689 } // namespace dart 1694 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/aot_optimizer.cc ('k') | runtime/vm/flow_graph_compiler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698