From: Georg-Johann Lay <avr@gjlay.de>
To: gcc-patches@gcc.gnu.org
Cc: Denis Chertykov <chertykov@gmail.com>,
Eric Weddington <eric.weddington@atmel.com>
Subject: Re: Ping #1: [Patch,AVR]: Clean-up some SP insns
Date: Wed, 05 Oct 2011 10:09:00 -0000 [thread overview]
Message-ID: <4E8C2875.1070303@gjlay.de> (raw)
In-Reply-To: <4E8181C2.5000706@gjlay.de>
Ping #1: http://gcc.gnu.org/ml/gcc-patches/2011-09/msg01690.html
Georg-Johann Lay wrote:
> This is just a code clean-up.
>
> The bulky code from *addhi3_sp_R_pc2 and *addhi3_sp_R_pc3 is done by a small C
> function that does the same (except that it prints some comment depending on
> -dp or -fverbose-asm).
>
> *movhi_sp is an insn that should not be there and go away because it is a move
> insn and there should be at most one move insn per mode (HImode in this case).
>
> stack_register_operand, i.e. (REG:HI 32), is in register class STACK_REG, thus
> not in NO_REGS, thus element of register_operand, general_regs and
> nonimmediate_operand which are the predicates/condition of *movhi. *movhi
> already knows to handle "q,r" and "r,q" moves, same applies to the output
> function output_movhi.
>
> The patch passes the test suite, of course.
>
> Ok?
>
> Moreover, I'd like to remove constraint "R" which is just used in one insn now
> and replace it by 3-letter constraint C.. so that prefix R is free.
>
> R is of absolutely no use in inline assembly and the constraint can be
> renamed/removed from documentation, IMO.
>
> Johann
>
> * config/avr/avr-protos.h (avr_out_addto_sp): New prototype.
> * config/avr/avr.c (avr_out_addto_sp): New function.
> (adjust_insn_length): Handle ADJUST_LEN_ADDTO_SP.
> * config/avr/avr.md (adjust_len): Add "addto_sp".
> (*movhi_sp): Remove insn.
> (*addhi3_sp_R_pc2, *addhi3_sp_R_pc3): Merge to *addhi3_sp_R.
next prev parent reply other threads:[~2011-10-05 9:51 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-27 9:26 Georg-Johann Lay
2011-09-27 16:55 ` Richard Henderson
2011-09-27 21:30 ` Georg-Johann Lay
2011-10-05 10:09 ` Georg-Johann Lay [this message]
2011-10-05 10:43 ` Ping #1: " Denis Chertykov
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=4E8C2875.1070303@gjlay.de \
--to=avr@gjlay.de \
--cc=chertykov@gmail.com \
--cc=eric.weddington@atmel.com \
--cc=gcc-patches@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).