@@ -3444,6 +3444,12 @@ output_asm_insn (const char *templ, rtx *operands)
output_operand_lossage ("invalid %%-code");
break;
+ /* Escaped braces. Print them as is. */
+ case '\\':
+ if (*p == '{' || *p == '}')
+ c = *p++;
+ /* FALLTHROUGH */
+
default:
putc (c, asm_out_file);
}
@@ -3955,6 +3961,12 @@ asm_fprintf (FILE *file, const char *p, ...)
}
break;
+ /* Escaped braces. Print them as is. */
+ case '\\':
+ if (*p == '{' || *p == '}')
+ c = *p++;
+ /* FALLTHROUGH */
+
default:
putc (c, file);
}
new file mode 100644
@@ -0,0 +1,9 @@
+/* { dg-do compile } */
+/* { dg-options "" } */
+
+void f()
+{
+ asm ( ".pushsection \".foo\"; .asciz \"div \\{ width : 50%% | height = 10px \\} \"; .long %c0; .popsection" : : "i"(42) );
+}
+
+/* { dg-final { scan-assembler "div { width : 50%% | height = 10px }" } } */
--
1.7.7.6