In almost most cases working with Register Allocator we must first
load source and then evaluate the destination. In this particular case
for byte-code shl-int/2addr v10, v10 we first find a destination (memory)
then load source (v10 -> physical register) and generate a shift operation
on memory. This is ok for this bytecode but RA thinks that v10 is in register
(we loaded source) and this is incorrect because updated value in memory
and physycal register is not up to date.
Change-Id: Ib4c71f70dcbf78b76ca89897e3bd605a89d77d08
Signed-off-by: Serguei Katkov <serguei.i.katkov@intel.com>
LoadValueDirectFixed(rl_rhs, t_reg);
if (is_two_addr) {
// Can we do this directly into memory?
- rl_result = UpdateLocTyped(rl_dest, kCoreReg);
rl_rhs = LoadValue(rl_rhs, kCoreReg);
+ rl_result = UpdateLocTyped(rl_dest, kCoreReg);
if (rl_result.location != kLocPhysReg) {
// Okay, we can do this into memory
OpMemReg(op, rl_result, t_reg.GetReg());