* loop.c (invariant_p, case MEM): Put MEM_VOLATILE_P check back.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@30496
138bc75d-0d04-0410-961f-
82ee72b054a4
Thu Nov 11 19:45:24 1999 Jim Wilson <wilson@cygnus.com>
+ * loop.c (invariant_p, case MEM): Put MEM_VOLATILE_P check back.
+
* dbxout.c (dbxout_type, case INTEGER_TYPE): Handle too large
unsigned types.
return VARRAY_INT (set_in_loop, REGNO (x)) == 0;
case MEM:
+ /* Volatile memory references must be rejected. Do this before
+ checking for read-only items, so that volatile read-only items
+ will be rejected also. */
+ if (MEM_VOLATILE_P (x))
+ return 0;
+
/* If we had a subroutine call, any location in memory could
have been clobbered. We used to test here for volatile and
readonly, but true_dependence knows how to do that better