comparison m68k_to_x86.c @ 126:4e45d75501cf

Fix check in translate_m68k_src that deals with instructions for which both operands are registers that are not mapped to a native x86-64 register
author Mike Pavone <pavone@retrodev.com>
date Sat, 29 Dec 2012 22:22:53 -0800
parents dc5fc3adf705
children fe598ffd85ce
comparison
equal deleted inserted replaced
125:dc5fc3adf705 126:4e45d75501cf
108 case MODE_REG: 108 case MODE_REG:
109 case MODE_AREG: 109 case MODE_AREG:
110 //We only get one memory parameter, so if the dst operand is a register in memory, 110 //We only get one memory parameter, so if the dst operand is a register in memory,
111 //we need to copy this to a temp register first 111 //we need to copy this to a temp register first
112 reg = native_reg(&(inst->dst), opts); 112 reg = native_reg(&(inst->dst), opts);
113 if (reg >= 0 || inst->dst.addr_mode == MODE_UNUSED || (inst->dst.addr_mode != MODE_REG && inst->dst.addr_mode == MODE_AREG) 113 if (reg >= 0 || inst->dst.addr_mode == MODE_UNUSED || (inst->dst.addr_mode != MODE_REG && inst->dst.addr_mode != MODE_AREG)
114 || inst->op == M68K_EXG) { 114 || inst->op == M68K_EXG) {
115 115
116 ea->mode = MODE_REG_DISPLACE8; 116 ea->mode = MODE_REG_DISPLACE8;
117 ea->base = CONTEXT; 117 ea->base = CONTEXT;
118 ea->disp = reg_offset(&(inst->src)); 118 ea->disp = reg_offset(&(inst->src));