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

Unified Diff: runtime/vm/flow_graph_allocator.h

Issue 10831070: Allow deoptimization from states with spilled values. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: address Srdjan's comments Created 8 years, 5 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/flow_graph_allocator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph_allocator.h
diff --git a/runtime/vm/flow_graph_allocator.h b/runtime/vm/flow_graph_allocator.h
index d92801e17cda76a48d2efe3aeb2bb5216697e11d..2bfcd2077f2ac950b1c147373e6b81675d92525e 100644
--- a/runtime/vm/flow_graph_allocator.h
+++ b/runtime/vm/flow_graph_allocator.h
@@ -52,13 +52,19 @@ class FlowGraphAllocator : public ValueObject {
// linearly assign consequent lifetime positions to every instruction.
// We assign position as follows:
//
- // 2 * n - even position corresponding to an implicit parallel move
- // preceding the instruction;
+ // 2 * n - even position corresponding to instruction's start;
//
- // 2 * n + 1 - odd position corresponding to instruction itself;
+ // 2 * n + 1 - odd position corresponding to instruction's end;
//
- // Having positions corresponding to parallel moves between every two
- // instructions allows us to capture non-trivial shapes of use intervals.
+ // Having two positions per instruction allows us to capture non-trivial
+ // shapes of use intervals: e.g. by placing a use at the start or the
+ // end position we can distinguish between instructions that need value
+ // at the register only at their start and those instructions that
+ // need value in the register until the end of instruction's body.
+ // Register allocator can perform splitting of live ranges at any position.
+ // An implicit ParallelMove will be inserted by ConnectSplitSiblings where
+ // required to resolve data flow between split siblings when allocation
+ // is finished.
// For specific examples see comments inside ProcessOneInstruction.
// Additionally creates parallel moves at the joins' predecessors
// that will be used for phi resolution.
@@ -74,7 +80,7 @@ class FlowGraphAllocator : public ValueObject {
Instruction* ConnectOutgoingPhiMoves(BlockEntryInstr* block);
void ProcessOneInstruction(BlockEntryInstr* block, Instruction* instr);
void ConnectIncomingPhiMoves(BlockEntryInstr* block);
- void BlockLocation(Location loc, intptr_t from, intptr_t to);
+ void BlockLocation(Location loc, intptr_t pos);
// Process live ranges sorted by their start and assign registers
// to them
« no previous file with comments | « no previous file | runtime/vm/flow_graph_allocator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698