

def _translate_lods_suffix(self, tb, instruction, suffix):
    if (self._arch_mode == ARCH_X86_MODE_32):
        src = ReilRegisterOperand('esi', 32)
    elif (self._arch_mode == ARCH_X86_MODE_64):
        src = ReilRegisterOperand('rsi', 64)
    else:
        raise Exception('Invalid architecture mode: %d', self._arch_mode)
    if (suffix == 'b'):
        dst = ReilRegisterOperand('al', 8)
    elif (suffix == 'w'):
        dst = ReilRegisterOperand('ax', 16)
    elif (suffix == 'd'):
        dst = ReilRegisterOperand('eax', 32)
    elif (suffix == 'q'):
        dst = ReilRegisterOperand('rax', 64)
    else:
        raise Exception(('Invalid instruction suffix: %s' % suffix))
    if instruction.prefix:
        (counter, loop_start_lbl) = self._rep_prefix_begin(tb, instruction)
    tb.add(self._builder.gen_ldm(dst, dst))
    self._update_strings_src(tb, src, dst.size, instruction)
    if instruction.prefix:
        self._rep_prefix_end(tb, instruction, counter, loop_start_lbl)

dataset/ETHPy150Open programa-stic/barf-project/barf/barf/arch/x86/x86translator.py X86Translator._translate_lods_suffix/VarMisuse@197/299 `src`->`dst`