public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/50527] inconsistent vla align Date: Tue, 27 Sep 2011 11:11:00 -0000 [thread overview] Message-ID: <bug-50527-4-FRgTWp5w6k@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-50527-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50527 --- Comment #6 from vries at gcc dot gnu.org 2011-09-27 10:49:23 UTC --- > I think we can check if the size is constant in evaluate_stmt and > compute alignment according to that. We can only do that in the last ccp phase that does folding of vla-alllocas. If the argument is not constant, it will not be folded in this phase, but it might be folded during the next ccp phase, when the argument does turn constant. If the argument is constant, it might not be folded in this phase, but it still might be folded during the next ccp phase. Therefore, in evaluate_stmt, we cannot predict whether the alloca will be folded, unless we're in the last ccp phase. And the propagation of alignment of alloca starts in the first ccp phase. > It should only change from > non-constant to constant, thus properly go down the lattice during > propagation. Currently, the result of an alloca is always constant, to be precise, constant 0 with only lower bits valid. This is independent of whether the argument is constant.
next prev parent reply other threads:[~2011-09-27 10:50 UTC|newest] Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top 2011-09-26 14:48 [Bug middle-end/50527] New: " vries at gcc dot gnu.org 2011-09-26 15:13 ` [Bug middle-end/50527] " rguenth at gcc dot gnu.org 2011-09-26 15:30 ` rguenth at gcc dot gnu.org 2011-09-27 9:29 ` vries at gcc dot gnu.org 2011-09-27 10:06 ` vries at gcc dot gnu.org 2011-09-27 10:08 ` rguenther at suse dot de 2011-09-27 11:11 ` vries at gcc dot gnu.org [this message] 2011-09-27 11:25 ` rguenther at suse dot de 2011-09-27 13:47 ` vries at gcc dot gnu.org 2011-10-07 12:50 ` vries at gcc dot gnu.org 2011-10-07 12:51 ` vries at gcc dot gnu.org 2011-10-07 13:38 ` vries at gcc dot gnu.org 2011-10-13 11:10 ` vries at gcc dot gnu.org 2011-10-13 11:18 ` vries at gcc dot gnu.org
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=bug-50527-4-FRgTWp5w6k@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.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: linkBe 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).