On Fri, 2012-05-25 at 12:18 +0300, Stefan Kristiansson wrote:
<snip>
> Note!
> I'm not at all confident about this...
> Feedback or better suggestions are appreciated.
>
> ---
> gcc/config/or1k/or1k.c | 11 ++++++-----
> 1 file changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/gcc/config/or1k/or1k.c b/gcc/config/or1k/or1k.c
> index 16238fe..2a6bb96 100644
> --- a/gcc/config/or1k/or1k.c
> +++ b/gcc/config/or1k/or1k.c
> @@ -381,18 +381,19 @@ or1k_emit_int_cmove (rtx dest,
> rtx false_cond)
> {
> rtx condition_rtx, cr;
> + rtx op0 = XEXP (op, 0);
> + rtx op1 = XEXP (op, 1);
>
> - if ((GET_MODE (or1k_compare_op0) != SImode) &&
> - (GET_MODE (or1k_compare_op0) != HImode) &&
> - (GET_MODE (or1k_compare_op0) != QImode))
> + if ((GET_MODE (op0) != SImode) &&
> + (GET_MODE (op0) != HImode) &&
> + (GET_MODE (op0) != QImode))
> {
> return 0;
> }
>
> /* We still have to do the compare, because cmov doesn't do a compare, it
> just looks at the FLAG bit set by a previous compare instruction. */
> - condition_rtx = or1k_expand_compare (GET_CODE (op),
> - or1k_compare_op0, or1k_compare_op1);
> + condition_rtx = or1k_expand_compare (GET_CODE (op), op0, op1);
>
> cr = XEXP (condition_rtx, 0);
Hi Stefan,
I discussed with Joern Rennecke, who notes that we didn't test the
-mcmov option when we did the 4.5 port. He advises this patch looks
good, so please apply it (including back-porting to the 4.5.1 code base
in SVN).
When you've done this, I'll rerun regression for the 4.5.1 tool chains
with this option enabled to see if anything else crawls out of the
woodwork.
Thanks,
Jeremy
--
Tel: +44 (1590) 610184
Cell: +44 (7970) 676050
SkypeID: jeremybennett
Email: [email protected]
Web: www.embecosm.com
_______________________________________________
OpenRISC mailing list
[email protected]
http://lists.openrisc.net/listinfo/openrisc