From: Marek Polacek <polacek@redhat.com>
To: Joseph Myers <joseph@codesourcery.com>
Cc: Richard Biener <rguenther@suse.de>,
GCC Patches <gcc-patches@gcc.gnu.org>,
Jakub Jelinek <jakub@redhat.com>
Subject: Re: [PATCH] Add save_expr langhook (PR c/68513)
Date: Mon, 30 Nov 2015 15:41:00 -0000 [thread overview]
Message-ID: <20151130153744.GE28072@redhat.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1511281600370.8818@digraph.polyomino.org.uk>
On Sat, Nov 28, 2015 at 04:05:30PM +0000, Joseph Myers wrote:
> On Sat, 28 Nov 2015, Richard Biener wrote:
>
> > Different approach: after the FE folds (unexpectedly?), scan the result
> > for SAVE_EXPRs and if found, drop the folding.
>
> Or, if conversions are going to fold from language-independent code (which
> is the underlying problem here - a conversion without folding would be
> preferred once the fallout from that can be resolved), make the front end
> fold with c_fully_fold before doing the conversion, and wrap the result of
> the conversion in a C_MAYBE_CONST_EXPR with c_wrap_maybe_const in the same
> way as done in other places that fold early (if either c_fully_fold
> indicates it can't occur in a constant expression, or the result of
> folding / conversion is not an INTEGER_CST).
Unfortunately, even this doesn't seem to work :(; I'm getting leaked
C_MAYBE_CONST_EXPRs e.g. when converting to (_Complex float), and a bunch of
missing warnings resulting in big testsuite fallout.
Marek
next prev parent reply other threads:[~2015-11-30 15:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-27 19:02 Marek Polacek
2015-11-27 19:36 ` Marek Polacek
2015-11-27 23:56 ` Joseph Myers
2015-11-30 12:58 ` Marek Polacek
2015-11-28 8:38 ` Richard Biener
2015-11-28 16:19 ` Joseph Myers
2015-11-30 15:41 ` Marek Polacek [this message]
2015-11-30 15:51 ` Marek Polacek
2015-11-30 16:00 ` Richard Biener
2015-11-30 16:06 ` Richard Biener
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=20151130153744.GE28072@redhat.com \
--to=polacek@redhat.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=joseph@codesourcery.com \
--cc=rguenther@suse.de \
/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).