From 296f8acc114ca58d70b6cd2dc0cd9c3ad264cdd1 Mon Sep 17 00:00:00 2001 From: Jeffrey A Law Date: Mon, 15 Dec 1997 15:46:40 +0000 Subject: [PATCH] stmt.c (expand_asm_operands): If an ASM has no outputs, then treat it as volatile. * stmt.c (expand_asm_operands): If an ASM has no outputs, then treat it as volatile. From-SVN: r17100 --- gcc/ChangeLog | 5 +++++ gcc/stmt.c | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 76a30f9a014..c9ea3e81d7d 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Mon Dec 15 08:48:24 1997 Jeffrey A Law (law@cygnus.com) + + * stmt.c (expand_asm_operands): If an ASM has no outputs, then treat + it as volatile. + Mon Dec 15 00:04:48 1997 Jeffrey A Law (law@cygnus.com) * haifa-sched.c (remove_dependencies): Set RTX_INTEGRATED_P on diff --git a/gcc/stmt.c b/gcc/stmt.c index 18390347831..32867482f21 100644 --- a/gcc/stmt.c +++ b/gcc/stmt.c @@ -1421,6 +1421,10 @@ expand_asm_operands (string, outputs, inputs, clobbers, vol, filename, line) /* The insn we have emitted. */ rtx insn; + /* An ASM with no outputs needs to be treated as volatile. */ + if (noutputs == 0) + vol = 1; + if (output_bytecode) { error ("`asm' is invalid when generating bytecode"); -- 2.30.2