Patchwork [PR50572] Tune loop alignment for Atom

login
register
mail settings
Submitter Sergey Ostanevich
Date Oct. 19, 2011, 12:05 p.m.
Message ID <CAGYS_TLO6B_pQ88bLXgB7V3T2VFw-pfqANyUUASGduWQWbQCNQ@mail.gmail.com>
Download mbox | patch
Permalink /patch/120604/
State New
Headers show

Comments

Sergey Ostanevich - Oct. 19, 2011, 12:05 p.m.
Hi!

Here is a patch to address PR50572.
Successfully bootstrapped and passed make check on x86_64-linux.

regards,
Sergos



2011-10-19  Sergey Ostanevich  <sergos.gnu@gmail.com>

	* gcc/config/i386/i386.c (ix86_option_override_internal): use loop
align by 16 bytes for Atom platform

     {

Patch

diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index 2c53423..7a93144 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -3497,6 +3497,8 @@  ix86_option_override_internal (bool main_args_p)
     {
       align_loops = processor_target_table[ix86_tune].align_loop;
       align_loops_max_skip =
processor_target_table[ix86_tune].align_loop_max_skip;
+      if (ix86_tune == PROCESSOR_ATOM && optimize > 1)
+        align_loops_max_skip = 15;
     }
   if (align_jumps == 0)