summaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2003-04-04 22:44:02 +0000
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2003-04-04 22:44:02 +0000
commitd5c801655343fc68422499d5af7e7e35b4e32b4d (patch)
tree9d8eeb3110a4fafa855c76608180345189b7b597 /gcc/emit-rtl.c
parent52ce909cee693585ed37e129098265b9dcf38804 (diff)
downloadgcc-d5c801655343fc68422499d5af7e7e35b4e32b4d.tar.gz
* emit-rtl.c (get_mem_attrs): Adjust alignment tests determining
use of default attributes to agree MEM_ALIGN macro. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@65254 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index 4aab67494d4..96903a3148c 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -312,13 +312,14 @@ get_mem_attrs (alias, expr, offset, size, align, mode)
mem_attrs attrs;
void **slot;
- /* If everything is the default, we can just return zero. */
+ /* If everything is the default, we can just return zero.
+ This must match what the corresponding MEM_* macros return when the
+ field is not present. */
if (alias == 0 && expr == 0 && offset == 0
&& (size == 0
|| (mode != BLKmode && GET_MODE_SIZE (mode) == INTVAL (size)))
- && (align == BITS_PER_UNIT
- || (STRICT_ALIGNMENT
- && mode != BLKmode && align == GET_MODE_ALIGNMENT (mode))))
+ && (STRICT_ALIGNMENT && mode != BLKmode
+ ? align == GET_MODE_ALIGNMENT (mode) : align == BITS_PER_UNIT))
return 0;
attrs.alias = alias;