public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Eric Botcazou <ebotcazou@adacore.com>
To: Bernd Schmidt <bernds@codesourcery.com>
Cc: gcc-patches@gcc.gnu.org, Paolo Bonzini <bonzini@gnu.org>,
	Andrew Pinski <pinskia@gmail.com>
Subject: Re: Patch: PR40900, extending call patterns
Date: Wed, 05 May 2010 13:01:00 -0000	[thread overview]
Message-ID: <201005051458.39945.ebotcazou@adacore.com> (raw)
In-Reply-To: <4BDE99BF.2030303@codesourcery.com>

> Seems to be because it's a signed operation, and arm has
>
> #define PROMOTE_MODE(MODE, UNSIGNEDP, TYPE)     \
>   if (GET_MODE_CLASS (MODE) == MODE_INT         \
>       && GET_MODE_SIZE (MODE) < 4)              \
>     {                                           \
>       if (MODE == QImode)                       \
>         UNSIGNEDP = 1;                          \
>       else if (MODE == HImode)                  \
>         UNSIGNEDP = 1;                          \
>       (MODE) = SImode;                          \
>     }
>
> while ppc doesn't modify UNSIGNEDP.

Can't we be clever during RTL expansion and avoid blindly zero-extending the 
value when we known that

  D.2014_1 = shortv2 ();

and promote_function_mode sign-extends?  The kind of extension for a specific 
variable can be changed since the SUBREG_PROMOTED_* machinery records it.  In 
other words, can't we just override promote_decl_mode in the SSA_NAME case of 
expand_expr_real_1?

-- 
Eric Botcazou

  reply	other threads:[~2010-05-05 13:01 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-30  1:05 Bernd Schmidt
2010-04-30  3:33 ` Andrew Pinski
2010-04-30  9:23   ` Paolo Bonzini
2010-04-30 15:09     ` Bernd Schmidt
     [not found]       ` <201005010054.17350.ebotcazou@adacore.com>
2010-05-01 10:45         ` Paolo Bonzini
2010-05-03  9:39         ` Bernd Schmidt
2010-05-05 13:01           ` Eric Botcazou [this message]
2010-05-06  7:14             ` Paolo Bonzini
2010-05-06  7:36               ` Eric Botcazou
2010-06-08 21:56             ` Bernd Schmidt
2010-06-09 22:14               ` Eric Botcazou
2010-06-11 13:58                 ` Bernd Schmidt
2010-06-16 21:23                   ` Eric Botcazou
2010-06-18  7:31                     ` Bernd Schmidt
2010-06-18 17:09                       ` Eric Botcazou

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=201005051458.39945.ebotcazou@adacore.com \
    --to=ebotcazou@adacore.com \
    --cc=bernds@codesourcery.com \
    --cc=bonzini@gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=pinskia@gmail.com \
    /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).