OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1044 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1055 | 1055 |
1056 LiveRange* live_range = LiveRangeFor(phi->id()); | 1056 LiveRange* live_range = LiveRangeFor(phi->id()); |
1057 LLabel* label = chunk_->GetLabel(phi->block()->block_id()); | 1057 LLabel* label = chunk_->GetLabel(phi->block()->block_id()); |
1058 label->GetOrCreateParallelMove(LGap::START, zone())-> | 1058 label->GetOrCreateParallelMove(LGap::START, zone())-> |
1059 AddMove(phi_operand, live_range->GetSpillOperand(), zone()); | 1059 AddMove(phi_operand, live_range->GetSpillOperand(), zone()); |
1060 live_range->SetSpillStartIndex(phi->block()->first_instruction_index()); | 1060 live_range->SetSpillStartIndex(phi->block()->first_instruction_index()); |
1061 } | 1061 } |
1062 } | 1062 } |
1063 | 1063 |
1064 | 1064 |
1065 bool LAllocator::Allocate(LChunk* chunk) { | 1065 bool LAllocator::Allocate(LChunkBase* chunk) { |
1066 ASSERT(chunk_ == NULL); | 1066 ASSERT(chunk_ == NULL); |
1067 chunk_ = chunk; | 1067 chunk_ = static_cast<LChunk*>(chunk); |
1068 MeetRegisterConstraints(); | 1068 MeetRegisterConstraints(); |
1069 if (!AllocationOk()) return false; | 1069 if (!AllocationOk()) return false; |
1070 ResolvePhis(); | 1070 ResolvePhis(); |
1071 BuildLiveRanges(); | 1071 BuildLiveRanges(); |
1072 AllocateGeneralRegisters(); | 1072 AllocateGeneralRegisters(); |
1073 if (!AllocationOk()) return false; | 1073 if (!AllocationOk()) return false; |
1074 AllocateDoubleRegisters(); | 1074 AllocateDoubleRegisters(); |
1075 if (!AllocationOk()) return false; | 1075 if (!AllocationOk()) return false; |
1076 PopulatePointerMaps(); | 1076 PopulatePointerMaps(); |
1077 if (has_osr_entry_) ProcessOsrEntry(); | 1077 if (has_osr_entry_) ProcessOsrEntry(); |
(...skipping 1032 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2110 LiveRange* current = live_ranges()->at(i); | 2110 LiveRange* current = live_ranges()->at(i); |
2111 if (current != NULL) current->Verify(); | 2111 if (current != NULL) current->Verify(); |
2112 } | 2112 } |
2113 } | 2113 } |
2114 | 2114 |
2115 | 2115 |
2116 #endif | 2116 #endif |
2117 | 2117 |
2118 | 2118 |
2119 } } // namespace v8::internal | 2119 } } // namespace v8::internal |
OLD | NEW |