This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: RX: 4.5 branch: Fix alignment and addressing issues.
- From: Andrew Pinski <pinskia at gmail dot com>
- To: Nick Clifton <nickc at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 16 Mar 2011 12:05:41 -0700
- Subject: Re: RX: 4.5 branch: Fix alignment and addressing issues.
- References: <m3k4fzs2v1.fsf@redhat.com>
On Wed, Mar 16, 2011 at 4:48 AM, Nick Clifton <nickc@redhat.com> wrote:
> Hi Guys,
>
> ÂI am checking in the attached patch to fix some regressions in the RX
> Âport with regard to alignment and addressing modes. ÂWith this patch
> Âapplied I have 18 fewer failures in the GCC testsuite.
> + (set_attr "length" "5")] ;; Worst case sceanario. FIXME: If we defined separate patterns
> +) ;; rather than using iterators we could specify exact sizes.
You can set up the correct length even without using separate patterns.
An example can be found in mips/mips.md:
(define_insn "*div<mode>3"
[(set (match_operand:ANYF 0 "register_operand" "=f")
(div:ANYF (match_operand:ANYF 1 "register_operand" "f")
(match_operand:ANYF 2 "register_operand" "f")))]
"<divide_condition>"
{
if (TARGET_FIX_SB1)
return "div.<fmt>\t%0,%1,%2\;mov.<fmt>\t%0,%0";
else
return "div.<fmt>\t%0,%1,%2";
}
[(set_attr "type" "fdiv")
(set_attr "mode" "<UNITMODE>")
(set (attr "length")
(if_then_else (ne (symbol_ref "TARGET_FIX_SB1") (const_int 0))
(const_int 8)
(const_int 4)))])
Thanks,
Andrew Pinski