rs6000.h (CONSTANT_ALIGNMENT): Don't overalign strings when optimizing for size...
authorNathan Froyd <froydnj@codesourcery.com>
Sat, 23 Feb 2008 00:35:20 +0000 (00:35 +0000)
committerNathan Froyd <froydnj@gcc.gnu.org>
Sat, 23 Feb 2008 00:35:20 +0000 (00:35 +0000)
* config/rs6000/rs6000.h (CONSTANT_ALIGNMENT): Don't overalign
strings when optimizing for size, unless the target cares about
alignment.

From-SVN: r132566

gcc/ChangeLog
gcc/config/rs6000/rs6000.h

index d9f0fa46d1c6cb1fe9641b20bd75497d57eac176..9f35e8c652aca082c509ee7a9891e206eae87524 100644 (file)
@@ -1,3 +1,9 @@
+2008-02-22  Nathan Froyd  <froydnj@codesourcery.com>
+
+       * config/rs6000/rs6000.h (CONSTANT_ALIGNMENT): Don't overalign
+       strings when optimizing for size, unless the target cares about
+       alignment.
+
 2008-02-22  Tom Tromey  <tromey@redhat.com>
 
        * regclass.c (current_pass): Remove declaration.
index 6a64eae3dd90502c056ecc1b4eca1ca45f180dd1..f5bf7daac1e3e115ae8b92087942a7eee4cae7ae 100644 (file)
@@ -596,6 +596,7 @@ extern enum rs6000_nop_insertion rs6000_sched_insert_nops;
    Make vector constants quadword aligned.  */
 #define CONSTANT_ALIGNMENT(EXP, ALIGN)                           \
   (TREE_CODE (EXP) == STRING_CST                                \
+   && (TARGET_STRICT_ALIGN || !optimize_size)                    \
    && (ALIGN) < BITS_PER_WORD                                    \
    ? BITS_PER_WORD                                               \
    : (ALIGN))