class TraceGlobalMoveResolver extends Object
Modifier and Type | Field and Description |
---|---|
private int |
firstVirtualStackIndex |
private FrameMapBuilder |
frameMapBuilder |
private int |
insertIdx |
private LIRInsertionBuffer |
insertionBuffer |
private List<Value> |
mappingFrom |
private List<AllocatableValue> |
mappingTo |
private int[] |
registerBlocked |
private LIRGeneratorTool.SpillMoveFactory |
spillMoveFactory |
private static int |
STACK_SLOT_IN_CALLER_FRAME_IDX |
private int[] |
stackBlocked |
Constructor and Description |
---|
TraceGlobalMoveResolver(LIRGenerationResult res,
LIRGeneratorTool.SpillMoveFactory spillMoveFactory,
Architecture arch) |
Modifier and Type | Method and Description |
---|---|
void |
addMapping(Value from,
AllocatableValue to) |
private void |
appendInsertionBuffer() |
private static boolean |
areMultipleReadsAllowed() |
private void |
block(Value location) |
private void |
breakCycle(int spillCandidate) |
private boolean |
checkEmpty() |
private void |
createInsertionBuffer(List<LIRInstruction> list) |
private LIRInstruction |
createMove(Value fromOpr,
AllocatableValue toOpr) |
private Register[] |
getRegisters() |
private LIRGeneratorTool.SpillMoveFactory |
getSpillMoveFactory() |
private int |
getStackArrayIndex(StackSlot stackSlot) |
private int |
getStackArrayIndex(StackSlotValue stackSlotValue) |
private int |
getStackArrayIndex(VirtualStackSlot virtualStackSlot) |
private boolean |
hasMappings() |
private void |
insertMove(Value fromOperand,
AllocatableValue toOperand) |
static boolean |
isMoveToSelf(Value from,
Value to) |
private static boolean |
mightBeBlocked(Value location) |
private void |
printMapping() |
void |
resolveAndAppendMoves() |
private void |
resolveMappings() |
private boolean |
safeToProcessMove(Value fromLocation,
Value toLocation)
|
void |
setInsertPosition(List<LIRInstruction> insertList,
int insertIdx) |
private void |
setValueBlocked(Value location,
int direction) |
private void |
unblock(Value location) |
private int |
valueBlocked(Value location) |
private boolean |
verifyBeforeResolve() |
private int insertIdx
private LIRInsertionBuffer insertionBuffer
private final List<Value> mappingFrom
private final List<AllocatableValue> mappingTo
private final int[] registerBlocked
private static final int STACK_SLOT_IN_CALLER_FRAME_IDX
private int[] stackBlocked
private final int firstVirtualStackIndex
private final LIRGeneratorTool.SpillMoveFactory spillMoveFactory
private final FrameMapBuilder frameMapBuilder
public TraceGlobalMoveResolver(LIRGenerationResult res, LIRGeneratorTool.SpillMoveFactory spillMoveFactory, Architecture arch)
private void setValueBlocked(Value location, int direction)
private int valueBlocked(Value location)
private static boolean areMultipleReadsAllowed()
private boolean hasMappings()
private LIRGeneratorTool.SpillMoveFactory getSpillMoveFactory()
private Register[] getRegisters()
private boolean checkEmpty()
private boolean verifyBeforeResolve()
private boolean safeToProcessMove(Value fromLocation, Value toLocation)
public static boolean isMoveToSelf(Value from, Value to)
private static boolean mightBeBlocked(Value location)
private void createInsertionBuffer(List<LIRInstruction> list)
private void appendInsertionBuffer()
private void insertMove(Value fromOperand, AllocatableValue toOperand)
private LIRInstruction createMove(Value fromOpr, AllocatableValue toOpr)
private void resolveMappings()
private void breakCycle(int spillCandidate)
private void printMapping()
public void setInsertPosition(List<LIRInstruction> insertList, int insertIdx)
public void addMapping(Value from, AllocatableValue to)
public void resolveAndAppendMoves()
private int getStackArrayIndex(StackSlotValue stackSlotValue)
private int getStackArrayIndex(StackSlot stackSlot)
private int getStackArrayIndex(VirtualStackSlot virtualStackSlot)