public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/61837] missed loop invariant expression optimization
Date: Thu, 29 Jul 2021 00:43:24 +0000	[thread overview]
Message-ID: <bug-61837-4-2VJFsNnP0i@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-61837-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61837

--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jiu Fu Guo <guojiufu@gcc.gnu.org>:

https://gcc.gnu.org/g:aafa38b5bfed5e3eff258aa5354ed928f4986709

commit r12-2585-gaafa38b5bfed5e3eff258aa5354ed928f4986709
Author: Jiufu Guo <guojiufu@linux.ibm.com>
Date:   Thu Jul 15 17:21:00 2021 +0800

    Use preferred mode for doloop IV [PR61837]

    Currently, doloop.xx variable is using the type as niter which may be
    shorter than word size.  For some targets, it would be better to use
    word size type.  For example, on 64bit system, to access 32bit value,
    subreg maybe used.  Then using 64bit type maybe better for niter if
    it can be present in both 32bit and 64bit.

    This patch add target hook to query preferred mode for doloop IV,
    and update mode accordingly.

    gcc/ChangeLog:

    2021-07-29  Jiufu Guo  <guojiufu@linux.ibm.com>

            PR target/61837
            * config/rs6000/rs6000.c (TARGET_PREFERRED_DOLOOP_MODE): New hook.
            (rs6000_preferred_doloop_mode): New hook.
            * doc/tm.texi: Regenerate.
            * doc/tm.texi.in: Add hook preferred_doloop_mode.
            * target.def (preferred_doloop_mode): New hook.
            * targhooks.c (default_preferred_doloop_mode): New hook.
            * targhooks.h (default_preferred_doloop_mode): New hook.
            * tree-ssa-loop-ivopts.c (compute_doloop_base_on_mode): New
function.
            (add_iv_candidate_for_doloop): Call targetm.preferred_doloop_mode
            and compute_doloop_base_on_mode.

    gcc/testsuite/ChangeLog:

    2021-07-29  Jiufu Guo  <guojiufu@linux.ibm.com>

            PR target/61837
            * gcc.target/powerpc/pr61837.c: New test.

  parent reply	other threads:[~2021-07-29  0:43 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-61837-4@http.gcc.gnu.org/bugzilla/>
2020-04-07  7:30 ` luoxhu at gcc dot gnu.org
2020-04-07 16:37 ` segher at gcc dot gnu.org
2020-04-13 10:31 ` luoxhu at gcc dot gnu.org
2020-04-14  6:42 ` segher at gcc dot gnu.org
2020-04-14  7:01 ` luoxhu at gcc dot gnu.org
2020-04-14  7:26 ` segher at gcc dot gnu.org
2020-04-14  7:52 ` luoxhu at gcc dot gnu.org
2020-04-14 10:37 ` rguenth at gcc dot gnu.org
2020-05-15  3:27 ` cvs-commit at gcc dot gnu.org
2021-07-29  0:43 ` cvs-commit at gcc dot gnu.org [this message]
2021-08-12  2:17 ` guojiufu 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-61837-4-2VJFsNnP0i@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: 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).