OSDN Git Service

* config/i386/i386.c (ix86_target_string): Use ARRAY_SIZE.
authoruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 7 Jan 2009 18:26:39 +0000 (18:26 +0000)
committeruros <uros@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 7 Jan 2009 18:26:39 +0000 (18:26 +0000)
(ix86_target_string): Ditto.
(ix86_valid_target_attribute_inner_p): Ditto.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@143164 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/i386/i386.c

index b379b1b..03338fc 100644 (file)
@@ -1,3 +1,9 @@
+2009-01-07  Uros Bizjak  <ubizjak@gmail.com>
+
+       * config/i386/i386.c (ix86_target_string): Use ARRAY_SIZE.
+       (ix86_target_string): Ditto.
+       (ix86_valid_target_attribute_inner_p): Ditto.
+
 2009-01-07  Jan Sjodin  <jan.sjodin@amd.com>
 
        PR tree-optimization/38492
 2009-01-06  Jan Hubicka  <jh@suse.cz>
 
        PR target/38744
-       * i386.c (ix86_expand_call): Use ARRAY_SIZE
+       * i386.c (ix86_expand_call): Use ARRAY_SIZE.
 
 2009-01-06  Gerald Pfeifer  <gerald@pfeifer.com>
 
        (ix86_nsaved_sseregs): New.
        (ix86_compute_frame_layout): Update nsseregs; set preferred alignment
        to 16 for w64; compute padding and size of sse reg save area.
-       (ix86_emit_save_regs, ix86_emit_save_regs_using_mov): Save only general
-       purpose regs.
+       (ix86_emit_save_regs, ix86_emit_save_regs_using_mov): Save only
+       general purpose regs.
        (ix86_emit_save_sse_regs_using_mov): New.
        (ix86_expand_prologue): Save SSE regs if needed.
        (ix86_emit_restore_regs_using_mov): Use only general purpose regs.
            Kai Tietz <kai.tietz@onevision.com>
 
        * i386.h (ACCUMULATE_OUTGOING_ARGS): Enable for MSABI
-       * i386.c (init_cumulative_args): Disallow calls of MSABI functions when
-       accumulate outgoing args is off.
+       * i386.c (init_cumulative_args): Disallow calls of MSABI functions
+       when accumulate outgoing args is off.
 
 2009-01-06  H.J. Lu  <hongjiu.lu@intel.com>
 
        (ira_build_conflicts): Use ira_conflicts_p.  Check result of
        building conflict table.
 
-       * ira-color.c (fast_allocation): Use num instead of
-       ira_allocnos_num.
+       * ira-color.c (fast_allocation): Use num instead of ira_allocnos_num.
        (ira_color): Use ira_conflicts_p.
        
        * global.c: Include ira.h.
 
        * reload1.c (compute_use_by_pseudos, reload, count_pseudo,
        count_spilled_pseudo, find_reg, alter_reg, finish_spills,
-       emit_input_reload_insns, delete_output_reload): Use
-       ira_conflicts_p.
+       emit_input_reload_insns, delete_output_reload): Use ira_conflicts_p.
        
 2009-01-06  Ben Elliston  <bje@au.ibm.com>
 
 
        PR tree-optimization/38492
        * graphite.c (rename_map_elt, debug_rename_elt,
-        debug_rename_map_1, debug_rename_map, new_rename_map_elt,
-        rename_map_elt_info, eq_rename_map_elts,
-        get_new_name_from_old_name, bb_in_sese_p): Moved around.
+       debug_rename_map_1, debug_rename_map, new_rename_map_elt,
+       rename_map_elt_info, eq_rename_map_elts,
+       get_new_name_from_old_name, bb_in_sese_p): Moved around.
        (sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
        (sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
        (sese_build_livein_liveouts): New.
        (gloog): Call scop_adjust_phis_for_liveouts.
 
        * graphite.h (struct sese): Documented.  Added fields liveout,
-        num_ver and livein.
+       num_ver and livein.
        (SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
        (new_sese, free_sese, sese_build_livein_liveouts): Declared.
        (struct scop): Added field liveout_renames.
        * config/mips/sync.md (memory_barrier): Redefine as expander pattern.
        Remove mem:BLK from insn operands.  Use Pmode scratch register.
        Set volatile flag on operand 0.
-       (*memory_barrier): New insn pattern.
+       (*mb_internal): New insn pattern.
 
        * config/alpha/sync.md (*memory_barrier): Rename from *mb_internal.
 
index df2be1c..6a31bbf 100644 (file)
@@ -2306,9 +2306,7 @@ ix86_target_string (int isa, int flags, const char *arch, const char *tune,
     { "-mtls-direct-seg-refs",         MASK_TLS_DIRECT_SEG_REFS },
   };
 
-  const char *opts[ (sizeof (isa_opts) / sizeof (isa_opts[0])
-                    + sizeof (flag_opts) / sizeof (flag_opts[0])
-                    + 6)][2];
+  const char *opts[ARRAY_SIZE (isa_opts) + ARRAY_SIZE (flag_opts) + 6][2];
 
   char isa_other[40];
   char target_other[40];
@@ -2337,7 +2335,7 @@ ix86_target_string (int isa, int flags, const char *arch, const char *tune,
     }
 
   /* Pick out the options in isa options.  */
-  for (i = 0; i < sizeof (isa_opts) / sizeof (isa_opts[0]); i++)
+  for (i = 0; i < ARRAY_SIZE (isa_opts); i++)
     {
       if ((isa & isa_opts[i].mask) != 0)
        {
@@ -2353,7 +2351,7 @@ ix86_target_string (int isa, int flags, const char *arch, const char *tune,
     }
 
   /* Add flag options.  */
-  for (i = 0; i < sizeof (flag_opts) / sizeof (flag_opts[0]); i++)
+  for (i = 0; i < ARRAY_SIZE (flag_opts); i++)
     {
       if ((flags & flag_opts[i].mask) != 0)
        {
@@ -2379,7 +2377,7 @@ ix86_target_string (int isa, int flags, const char *arch, const char *tune,
   if (num == 0)
     return NULL;
 
-  gcc_assert (num < sizeof (opts) / sizeof (opts[0]));
+  gcc_assert (num < ARRAY_SIZE (opts));
 
   /* Size the string.  */
   len = 0;
@@ -3526,7 +3524,7 @@ ix86_valid_target_attribute_inner_p (tree args, char *p_strings[])
       /* Find the option.  */
       ch = *p;
       opt = N_OPTS;
-      for (i = 0; i < sizeof (attrs) / sizeof (attrs[0]); i++)
+      for (i = 0; i < ARRAY_SIZE (attrs); i++)
        {
          type = attrs[i].type;
          opt_len = attrs[i].len;