public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "rguenther at suse dot de" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/42131] Weird translation of DO loops Date: Tue, 01 Dec 2009 09:42:00 -0000 [thread overview] Message-ID: <20091201094227.22778.qmail@sourceware.org> (raw) In-Reply-To: <bug-42131-10053@http.gcc.gnu.org/bugzilla/> ------- Comment #26 from rguenther at suse dot de 2009-12-01 09:42 ------- Subject: Re: Weird translation of DO loops On Mon, 30 Nov 2009, tkoenig at gcc dot gnu dot org wrote: > > > ------- Comment #22 from tkoenig at gcc dot gnu dot org 2009-11-30 19:15 ------- > (In reply to comment #21) > > > the "sign" for unsigned steps is always 1, you don't seem to account > > for unsignedness? > > (Un)fortunately, there are no unsigned varaibles in Fortran. > > > Note that I believe generating > > > > step_sign = fold_build3 (fold_build2 (LT_EXPR, boolean_type_node, > > step, build_int_cst (TREE_TYPE (step), > > 0)), > > build_int_cst (type, -1), build_int_cst (type, 1)); > > > > is better as that allows more freedom for fold and efficient expansion > > for the target. Just double-check that it also works for the > > unrolling ;) > > That doesn't work (something about fold_build3 needing five arguments > instead of three), so think I'll submit my patch "as is". Ah, of course ... more like step_sign = fold_build3 (COND_EXPR, type, fold_build2 (LT_EXPR, boolean_type_node, step, build_int_cst (TREE_TYPE (step), 0)), build_int_cst (type, -1), build_int_cst (type, 1)); Which still would be prefered IMHO. Richard. > Thanks for your comments! > > Thanks, > > Richard. > > > > > -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42131
next prev parent reply other threads:[~2009-12-01 9:42 UTC|newest] Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-11-21 13:58 [Bug fortran/42131] New: " rguenth at gcc dot gnu dot org 2009-11-21 16:26 ` [Bug fortran/42131] " kargl at gcc dot gnu dot org 2009-11-21 17:33 ` toon at moene dot org 2009-11-21 18:31 ` tkoenig at gcc dot gnu dot org 2009-11-21 19:24 ` rguenth at gcc dot gnu dot org 2009-11-21 21:41 ` toon at moene dot org 2009-11-21 23:07 ` tkoenig at gcc dot gnu dot org 2009-11-21 23:24 ` rguenther at suse dot de 2009-11-21 23:42 ` tkoenig at gcc dot gnu dot org 2009-11-22 10:21 ` toon at moene dot org 2009-11-22 19:04 ` burnus at gcc dot gnu dot org 2009-11-23 21:48 ` tkoenig at gcc dot gnu dot org 2009-11-24 18:04 ` toon at moene dot org 2009-11-26 21:56 ` tkoenig at gcc dot gnu dot org 2009-11-26 22:07 ` kargl at gcc dot gnu dot org 2009-11-26 23:43 ` tkoenig at gcc dot gnu dot org 2009-11-27 8:29 ` burnus at gcc dot gnu dot org 2009-11-27 9:47 ` rguenther at suse dot de 2009-11-27 9:48 ` rguenther at suse dot de 2009-11-28 15:16 ` tkoenig at gcc dot gnu dot org 2009-11-30 7:31 ` tkoenig at gcc dot gnu dot org 2009-11-30 10:10 ` rguenther at suse dot de 2009-11-30 19:16 ` tkoenig at gcc dot gnu dot org 2009-11-30 20:19 ` jvdelisle at gcc dot gnu dot org 2009-11-30 20:36 ` tkoenig at gcc dot gnu dot org 2009-11-30 21:01 ` tkoenig at gcc dot gnu dot org 2009-12-01 9:42 ` rguenther at suse dot de [this message] 2009-12-01 18:33 ` jb at gcc dot gnu dot org 2009-12-02 9:23 ` jb at gcc dot gnu dot org 2009-12-04 14:24 ` dominiq at lps dot ens dot fr
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=20091201094227.22778.qmail@sourceware.org \ --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).