diff options
author | mmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-05-04 16:02:07 +0000 |
---|---|---|
committer | mmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-05-04 16:02:07 +0000 |
commit | 64511c32eb0c3d7cb2346f34c6f1c20346b48751 (patch) | |
tree | 1861645136096dd536aa0bee0c2ebc01e0d0a214 | |
parent | 79048c7d6c68ab62e5732bef0606792d2dde66e1 (diff) | |
download | gcc-64511c32eb0c3d7cb2346f34c6f1c20346b48751.tar.gz |
* resource.c (mark_set_resources): Handle UNSPEC_VOLATILE,
ASM_INPUT, TRAP_IF, and ASM_OPERANDS just like in
mark_referenced_resources.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@26769 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/resource.c | 22 |
2 files changed, 28 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 68dd128a47d..fab7d58835d 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +Tue May 4 13:17:55 1999 Mark Mitchell <mark@codesourcery.com> + + * resource.c (mark_set_resources): Handle UNSPEC_VOLATILE, + ASM_INPUT, TRAP_IF, and ASM_OPERANDS just like in + mark_referenced_resources. + Mon May 3 22:38:41 1999 David Edelsohn <edelsohn@gnu.org> * rs6000/aix43.h (SUBTARGET_OVERRIDE_OPTIONS): Change non-PowerPC diff --git a/gcc/resource.c b/gcc/resource.c index eceac56df90..bc214a3dc23 100644 --- a/gcc/resource.c +++ b/gcc/resource.c @@ -739,6 +739,28 @@ mark_set_resources (x, res, in_dest, include_delayed_effects) SET_HARD_REG_BIT (res->regs, REGNO (x) + i); return; + case UNSPEC_VOLATILE: + case ASM_INPUT: + /* Traditional asm's are always volatile. */ + res->volatil = 1; + return; + + case TRAP_IF: + res->volatil = 1; + break; + + case ASM_OPERANDS: + res->volatil = MEM_VOLATILE_P (x); + + /* For all ASM_OPERANDS, we must traverse the vector of input operands. + We can not just fall through here since then we would be confused + by the ASM_INPUT rtx inside ASM_OPERANDS, which do not indicate + traditional asms unlike their normal usage. */ + + for (i = 0; i < ASM_OPERANDS_INPUT_LENGTH (x); i++) + mark_set_resources (ASM_OPERANDS_INPUT (x, i), res, in_dest, 0); + return; + default: break; } |