Patchwork ARM: Emit conditions in push_multi

login
register
mail settings
Submitter Jakub Jelinek
Date Sept. 12, 2011, 9:36 a.m.
Message ID <20110912093659.GB2687@tyan-ft48-01.lab.bos.redhat.com>
Download mbox | patch
Permalink /patch/114303/
State New
Headers show

Comments

Jakub Jelinek - Sept. 12, 2011, 9:36 a.m.
Hi!

This last hunk is wrong, for sprintf you need to use %% instead of %.

On Wed, Sep 07, 2011 at 09:23:36PM +0200, Bernd Schmidt wrote:
> @@ -10631,7 +10633,7 @@ (define_insn "*push_fp_multi"
>    {
>      char pattern[100];
>  
> -    sprintf (pattern, \"sfmfd\\t%%1, %d, [%%m0]!\", XVECLEN (operands[2], 0));
> +    sprintf (pattern, \"sfm%(fd%)\\t%%1, %d, [%%m0]!\", XVECLEN (operands[2], 0));
>      output_asm_insn (pattern, operands);
>      return \"\";
>    }"

Committed as obvious:

2011-09-12  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/50352
	* config/arm/arm.md (*push_fp_multi): Add % before %( and %) in the
	sprintf format string.


	Jakub

Patch

--- gcc/config/arm/arm.md	(revision 178777)
+++ gcc/config/arm/arm.md	(revision 178778)
@@ -10633,7 +10633,7 @@  (define_insn "*push_fp_multi"
   {
     char pattern[100];
 
-    sprintf (pattern, \"sfm%(fd%)\\t%%1, %d, [%%m0]!\", XVECLEN (operands[2], 0));
+    sprintf (pattern, \"sfm%%(fd%%)\\t%%1, %d, [%%m0]!\", XVECLEN (operands[2], 0));
     output_asm_insn (pattern, operands);
     return \"\";
   }"