public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Tamar Christina <Tamar.Christina@arm.com>
To: Richard Sandiford <richard.sandiford@linaro.org>
Cc: GCC Patches <gcc-patches@gcc.gnu.org>, nd <nd@arm.com>,
	James Greenhalgh	<James.Greenhalgh@arm.com>,
	Marcus Shawcroft <Marcus.Shawcroft@arm.com>,
	Richard Earnshaw <Richard.Earnshaw@arm.com>
Subject: RE: [PATCH][GCC][AArch64] optimize float immediate moves (2 /4) - HF/DF/SF mode.
Date: Thu, 15 Jun 2017 13:25:00 -0000	[thread overview]
Message-ID: <VI1PR0801MB2031B9D822E987A87E7EB218FFC00@VI1PR0801MB2031.eurprd08.prod.outlook.com> (raw)
In-Reply-To: <87mv9adgtb.fsf@linaro.org>

Hi Richard,

> > +    rtx tmp = gen_reg_rtx (SImode);
> > +    aarch64_expand_mov_immediate (tmp, gen_int_mode (ival, SImode));
> > +    tmp = simplify_gen_subreg (HImode, tmp, SImode, 0);
> 
> This looks wrong for big-endian, and...
> 
> > +    emit_move_insn (operands[0], gen_lowpart (HFmode, tmp));
> 
> ...either it should be OK to go directly from tmp to the HFmode lowpart, or
> we should move the HImode temporary into a fresh REG.  Current
> validate_subreg seems to suggest that we need the latter.
> 
> Isn't it possible to use a HImode move immediate instead of an SImode one?

We don't really have a movehi pattern, currently a movhi would end up in the general
mov<mode>_aarch64 pattern which would then use end up using a w register as well.

I'll take a look at big-endian. 

> 
> Thanks,
> Richard

  reply	other threads:[~2017-06-15 13:25 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-07 11:38 Tamar Christina
2017-06-12  7:31 ` Tamar Christina
2017-06-14 10:06   ` Richard Sandiford
2017-06-15 13:25     ` Tamar Christina [this message]
2017-06-15 14:28       ` Tamar Christina
2017-06-16  7:53         ` Richard Sandiford
2017-06-16  8:42           ` Tamar Christina
2017-06-14  8:43 ` James Greenhalgh
2017-06-21 10:48   ` Tamar Christina
2017-06-26 10:50     ` Tamar Christina
2017-07-03  6:12       ` Tamar Christina
2017-07-10  7:35         ` Tamar Christina
2017-07-27 16:09       ` James Greenhalgh
2017-08-01 11:47       ` Bin.Cheng
2017-08-01 11:51         ` Tamar Christina
2017-08-01 12:04           ` Bin.Cheng

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=VI1PR0801MB2031B9D822E987A87E7EB218FFC00@VI1PR0801MB2031.eurprd08.prod.outlook.com \
    --to=tamar.christina@arm.com \
    --cc=James.Greenhalgh@arm.com \
    --cc=Marcus.Shawcroft@arm.com \
    --cc=Richard.Earnshaw@arm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=nd@arm.com \
    --cc=richard.sandiford@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).