

def _translate_neg(self, tb, instruction):
    oprnd0 = tb.read(instruction.operands[0])
    imm0 = tb.immediate(((2 ** oprnd0.size) - 1), oprnd0.size)
    imm1 = tb.immediate(1, oprnd0.size)
    imm2 = tb.immediate(1, 1)
    tmp0 = tb.temporal(oprnd0.size)
    tmp1 = tb.temporal(oprnd0.size)
    tmp2 = tb.temporal(1)
    tb.add(self._builder.gen_xor(oprnd0, imm0, tmp0))
    tb.add(self._builder.gen_add(tb, imm1, tmp1))
    tb.add(self._builder.gen_bisz(oprnd0, tmp2))
    tb.add(self._builder.gen_xor(tmp2, imm2, self._flags['cf']))
    if (self._translation_mode == FULL_TRANSLATION):
        self._update_of_sub(tb, oprnd0, oprnd0, tmp1)
        self._update_sf(tb, oprnd0, oprnd0, tmp1)
        self._update_zf(tb, oprnd0, oprnd0, tmp1)
        self._update_af(tb, oprnd0, oprnd0, tmp1)
        self._update_pf(tb, oprnd0, oprnd0, tmp1)
    tb.write(instruction.operands[0], tmp1)

dataset/ETHPy150Open programa-stic/barf-project/barf/barf/arch/x86/x86translator.py X86Translator._translate_neg/VarMisuse@134/170 `tmp0`->`tb`