On 10/20/2017 10:56 AM, Peter Maydell wrote: > + if (s->be_data) { > + tcg_gen_extr_i64_i32(tmp2, tmp, t64); > + } else { > + tcg_gen_extr_i64_i32(tmp, tmp2, t64); > + }
The test against be_data must be of the form s->be_data == MO_BE/LE. The actual bits have MO_BSWAP non-zero, and then set MO_BE/LE to either 0 or MO_BSWAP depending on the host endianness. > - gen_aa32_frob64(s, o64); > + if (s->be_data) { > + tcg_gen_rotri_i64(o64, o64, 32); > + } > tcg_gen_setcond_i64(TCG_COND_NE, o64, o64, cpu_exclusive_val); We're not splitting o64 to parts. Are you sure it shouldn't stay as frob? r~