summaryrefslogtreecommitdiff
path: root/gcc/stmt.c
diff options
context:
space:
mode:
authorrms <rms@138bc75d-0d04-0410-961f-82ee72b054a4>1992-06-18 17:38:13 +0000
committerrms <rms@138bc75d-0d04-0410-961f-82ee72b054a4>1992-06-18 17:38:13 +0000
commit426b38c952d3ddcbe5aac0cf36f8651add04a9e4 (patch)
treec44cc579dc50f803d5e4bdad12f47f315543dce0 /gcc/stmt.c
parenta3bc5c8a88bfc4589cfb861127c0f2d7c9b6b87e (diff)
downloadgcc-426b38c952d3ddcbe5aac0cf36f8651add04a9e4.tar.gz
*** empty log message ***
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@1207 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/stmt.c')
-rw-r--r--gcc/stmt.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/gcc/stmt.c b/gcc/stmt.c
index 2c2759686e0..11c122b2b34 100644
--- a/gcc/stmt.c
+++ b/gcc/stmt.c
@@ -1012,7 +1012,8 @@ expand_asm_operands (string, outputs, inputs, clobbers, vol, filename, line)
for (tail = clobbers; tail; tail = TREE_CHAIN (tail))
{
char *regname = TREE_STRING_POINTER (TREE_VALUE (tail));
- if (decode_reg_name (regname) >= 0)
+ i = decode_reg_name (regname);
+ if (i >= 0 || i == -4)
++nclobbers;
}
@@ -1183,9 +1184,15 @@ expand_asm_operands (string, outputs, inputs, clobbers, vol, filename, line)
if (j < 0)
{
- if (j == -3)
+ if (j == -3) /* `cc', which is not a register */
continue;
+ if (j == -4) /* `memory', don't cache memory across asm */
+ {
+ XVECEXP (body, 0, i++) = gen_rtx (CLOBBER, VOIDmode, const0_rtx);
+ continue;
+ }
+
error ("unknown register name `%s' in `asm'", regname);
return;
}