OSDN Git Service

* toplev.c (init_asm_output): Add explicit 'b' to mode when
[pf3gnuchains/gcc-fork.git] / gcc / toplev.c
index c15ab99..2741be5 100644 (file)
@@ -43,6 +43,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 #include "line-map.h"
 #include "input.h"
 #include "tree.h"
+#include "version.h"
 #include "rtl.h"
 #include "tm_p.h"
 #include "flags.h"
@@ -264,7 +265,7 @@ int flag_branch_probabilities = 0;
 int flag_reorder_blocks = 0;
 
 /* Nonzero if blocks should be partitioned into hot and cold sections in
-   addition to being reordered. */
+   addition to being reordered.  */
 
 int flag_reorder_blocks_and_partition = 0;
 
@@ -707,6 +708,9 @@ int flag_schedule_speculative_load_dangerous = 0;
 int flag_sched_stalled_insns = 0;
 int flag_sched_stalled_insns_dep = 1;
 
+/* The following flag controls the module scheduling activation.  */
+int flag_modulo_sched = 0;
+
 int flag_single_precision_constant;
 
 /* flag_branch_on_count_reg means try to replace add-1,compare,branch tupple
@@ -822,7 +826,7 @@ int flag_tree_gvn = 0;
 /* Enable the SSA-PRE tree optimization.  */
 int flag_tree_pre = 0;
 
-/* Enable points-to analysis on trees. */
+/* Enable points-to analysis on trees.  */
 enum pta_type flag_tree_points_to = PTA_NONE;
 
 /* Enable SSA-CCP on trees.  */
@@ -1007,6 +1011,7 @@ static const lang_independent_options f_options[] =
   {"sched-stalled-insns-dep", &flag_sched_stalled_insns_dep, 1 },
   {"sched2-use-superblocks", &flag_sched2_use_superblocks, 1 },
   {"sched2-use-traces", &flag_sched2_use_traces, 1 },
+  {"modulo-sched", &flag_modulo_sched, 1 },
   {"branch-count-reg",&flag_branch_on_count_reg, 1 },
   {"pic", &flag_pic, 1 },
   {"PIC", &flag_pic, 2 },
@@ -1511,12 +1516,12 @@ check_global_declarations (tree *vec, int len)
         because many programs have static variables
         that exist only to get some text into the object file.  */
       if (TREE_CODE (decl) == FUNCTION_DECL
-         && (warn_unused_function
-             || TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)))
          && DECL_INITIAL (decl) == 0
          && DECL_EXTERNAL (decl)
          && ! DECL_ARTIFICIAL (decl)
-         && ! TREE_PUBLIC (decl))
+         && ! TREE_PUBLIC (decl)
+         && (warn_unused_function
+             || TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl))))
        {
          if (TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)))
            pedwarn ("%J'%F' used but never defined", decl, decl);
@@ -2034,7 +2039,7 @@ init_asm_output (const char *name)
       if (!strcmp (asm_file_name, "-"))
        asm_out_file = stdout;
       else
-       asm_out_file = fopen (asm_file_name, "w+");
+       asm_out_file = fopen (asm_file_name, "w+b");
       if (asm_out_file == 0)
        fatal_error ("can't open %s for writing: %m", asm_file_name);
     }