This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: PATCH: PR 834: IA64: Change br to brl for "far" brancheswhen possible
- From: "Jan Beulich" <JBeulich at novell dot com>
- To: <hjl at lucon dot org>,<rth at redhat dot com>
- Cc: <binutils at sources dot redhat dot com>
- Date: Fri, 13 May 2005 09:40:46 +0200
- Subject: Re: PATCH: PR 834: IA64: Change br to brl for "far" brancheswhen possible
>+ /* Check if slot 2 is NOP. Possible templates are MBB and BBB.
>+ For BBB, slot 0 also has to be nop.b. */
>+ if (!((template == 0x12 /* MBB */
>+ && (s2 & 0x1e1f8000000LL) == 0x4000000000LL)
>+ || (template == 0x16 /* BBB */
>+ && (s0 & 0x1e1f8000000LL) == 0x4000000000LL
>+ && (s2 & 0x1e1f8000000LL) == 0x4000000000LL)))
>+ return FALSE;
>...
I would think the code would become much better readable if the template values were symbolic (macros or enumeration values) and the nop checks would be hidden in macros.
>+ /* For BBB, we need to put nop.m in slot 0 and keep the original
>+ predicate. */
>+ t0 &= 0x7e0LL;
Why do you try to keep the predicate on a nop?
Jan