OSDN Git Service

* config/i386/i386.c (override_options): Define c3-2 as a 686 with SSE.
[pf3gnuchains/gcc-fork.git] / gcc / c-semantics.c
index 0b8f587..e19e73e 100644 (file)
@@ -1,7 +1,7 @@
 /* This file contains the definitions and documentation for the common
    tree codes used in the GNU C and C++ compilers (see c-common.def
    for the standard codes).  
-   Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
    Written by Benjamin Chelf (chelf@codesourcery.com).
 
 This file is part of GCC.
@@ -146,6 +146,8 @@ add_scope_stmt (begin_p, partial_p)
     }
   else
     {
+      if (partial_p != SCOPE_PARTIAL_P (TREE_PURPOSE (top)))
+       abort ();
       TREE_VALUE (top) = ss;
       *stack_ptr = TREE_CHAIN (top);
     }
@@ -422,16 +424,20 @@ void
 genrtl_while_stmt (t)
      tree t;
 {
-  tree cond;
+  tree cond = WHILE_COND (t);
+
   emit_nop ();
   emit_line_note (input_filename, lineno);
   expand_start_loop (1); 
   genrtl_do_pushlevel ();
 
-  cond = expand_cond (WHILE_COND (t));
-  emit_line_note (input_filename, lineno);
-  expand_exit_loop_top_cond (0, cond);
-  genrtl_do_pushlevel ();
+  if (cond && !integer_nonzerop (cond))
+    {
+      cond = expand_cond (cond);
+      emit_line_note (input_filename, lineno);
+      expand_exit_loop_top_cond (0, cond);
+      genrtl_do_pushlevel ();
+    }
   
   expand_stmt (WHILE_BODY (t));
 
@@ -520,7 +526,7 @@ void
 genrtl_for_stmt (t)
      tree t;
 {
-  tree cond;
+  tree cond = FOR_COND (t);
   const char *saved_filename;
   int saved_lineno;
 
@@ -537,7 +543,6 @@ genrtl_for_stmt (t)
   else
     expand_start_loop (1);
   genrtl_do_pushlevel ();
-  cond = expand_cond (FOR_COND (t));
 
   /* Save the filename and line number so that we expand the FOR_EXPR
      we can reset them back to the saved values.  */
@@ -545,12 +550,15 @@ genrtl_for_stmt (t)
   saved_lineno = lineno;
 
   /* Expand the condition.  */
-  emit_line_note (input_filename, lineno);
-  if (cond)
-    expand_exit_loop_top_cond (0, cond);
+  if (cond && !integer_nonzerop (cond))
+    {
+      cond = expand_cond (cond);
+      emit_line_note (input_filename, lineno);
+      expand_exit_loop_top_cond (0, cond);
+      genrtl_do_pushlevel ();
+    }
 
   /* Expand the body.  */
-  genrtl_do_pushlevel ();
   expand_stmt (FOR_BODY (t));
 
   /* Expand the increment expression.  */
@@ -747,7 +755,7 @@ genrtl_asm_stmt (cv_qualifier, string, output_operands,
 
   emit_line_note (input_filename, lineno);
   if (asm_input_p)
-    expand_asm (string);
+    expand_asm (string, cv_qualifier != NULL_TREE);
   else
     c_expand_asm_operands (string, output_operands, input_operands, 
                           clobbers, cv_qualifier != NULL_TREE,