| OLD | NEW |
| 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/flow_graph_allocator.h" | 5 #include "vm/flow_graph_allocator.h" |
| 6 | 6 |
| 7 #include "vm/bit_vector.h" | 7 #include "vm/bit_vector.h" |
| 8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
| 9 #include "vm/il_printer.h" | 9 #include "vm/il_printer.h" |
| 10 #include "vm/flow_graph.h" | 10 #include "vm/flow_graph.h" |
| (...skipping 2727 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2738 range->assigned_location()); | 2738 range->assigned_location()); |
| 2739 } | 2739 } |
| 2740 } | 2740 } |
| 2741 } | 2741 } |
| 2742 | 2742 |
| 2743 | 2743 |
| 2744 static Representation RepresentationForRange(Representation definition_rep) { | 2744 static Representation RepresentationForRange(Representation definition_rep) { |
| 2745 if (definition_rep == kUnboxedMint) { | 2745 if (definition_rep == kUnboxedMint) { |
| 2746 // kUnboxedMint is split into two ranges, each of which are kUntagged. | 2746 // kUnboxedMint is split into two ranges, each of which are kUntagged. |
| 2747 return kUntagged; | 2747 return kUntagged; |
| 2748 } else if (definition_rep == kUnboxedUint32) { |
| 2749 // kUnboxedUint32 is untagged. |
| 2750 return kUntagged; |
| 2748 } | 2751 } |
| 2749 return definition_rep; | 2752 return definition_rep; |
| 2750 } | 2753 } |
| 2751 | 2754 |
| 2752 | 2755 |
| 2753 void FlowGraphAllocator::CollectRepresentations() { | 2756 void FlowGraphAllocator::CollectRepresentations() { |
| 2754 // Parameters. | 2757 // Parameters. |
| 2755 GraphEntryInstr* graph_entry = flow_graph_.graph_entry(); | 2758 GraphEntryInstr* graph_entry = flow_graph_.graph_entry(); |
| 2756 for (intptr_t i = 0; i < graph_entry->initial_definitions()->length(); ++i) { | 2759 for (intptr_t i = 0; i < graph_entry->initial_definitions()->length(); ++i) { |
| 2757 Definition* def = (*graph_entry->initial_definitions())[i]; | 2760 Definition* def = (*graph_entry->initial_definitions())[i]; |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2876 OS::Print("-- [after ssa allocator] ir [%s] -------------\n", | 2879 OS::Print("-- [after ssa allocator] ir [%s] -------------\n", |
| 2877 function.ToFullyQualifiedCString()); | 2880 function.ToFullyQualifiedCString()); |
| 2878 FlowGraphPrinter printer(flow_graph_, true); | 2881 FlowGraphPrinter printer(flow_graph_, true); |
| 2879 printer.PrintBlocks(); | 2882 printer.PrintBlocks(); |
| 2880 OS::Print("----------------------------------------------\n"); | 2883 OS::Print("----------------------------------------------\n"); |
| 2881 } | 2884 } |
| 2882 } | 2885 } |
| 2883 | 2886 |
| 2884 | 2887 |
| 2885 } // namespace dart | 2888 } // namespace dart |
| OLD | NEW |