True. Nice catch. This will simplify this section even more. I will send an updated patch with this change included.
Petar ________________________________________ From: Peter Maydell [[email protected]] Sent: Thursday, May 09, 2013 7:54 PM To: Petar Jovanovic Cc: [email protected]; Petar Jovanovic; [email protected] Subject: Re: [Qemu-devel] [PATCH] target-mips: clean-up in BIT_INSV On 9 May 2013 18:28, Petar Jovanovic <[email protected]> wrote: > @@ -2921,7 +2922,7 @@ target_ulong helper_##name(CPUMIPSState *env, > target_ulong rs, \ > return rt; \ > } \ > \ > - filter = ((int64_t)0x01 << size) - 1; \ > + filter = (1LL << size) - 1; \ > filter = filter << pos; \ > temprs = (rs << pos) & filter; \ > temprt = rt & ~filter; \ This section of code is pretty much hand-coding temp = deposit64(rt, pos, size, rs); isn't it? -- PMM
