This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/80136] [7 Regression] ICE in gimplify_modify_expr, at gimplify.c:5627


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80136

--- Comment #15 from Bill Schmidt <wschmidt at gcc dot gnu.org> ---
Jakub, thanks for the confirmation that force_gimple_operand is unnecessary. 
Christophe, thanks for testing.  Thus I am now regstrapping:

Index: gcc/testsuite/gcc.dg/torture/pr79908.c                                   
===================================================================
--- gcc/testsuite/gcc.dg/torture/pr79908.c      (revision 246334)               
+++ gcc/testsuite/gcc.dg/torture/pr79908.c      (working copy)                  
@@ -0,0 +1,12 @@
+/* { dg-do compile } */                                                        
+                                                                               
+/* Used to fail in the stdarg pass before fix for PR79908.  */                 
+                                                                               
+typedef __builtin_va_list __gnuc_va_list;                                      
+typedef __gnuc_va_list va_list;                                                
+                                                                               
+void testva (int n, ...)                                                       
+{                                                                              
+  va_list ap;                                                                  
+  _Complex int i = __builtin_va_arg (ap, _Complex int);                        
+}                                                                              
Index: gcc/tree-stdarg.c                                                        
===================================================================
--- gcc/tree-stdarg.c   (revision 246334)                                       
+++ gcc/tree-stdarg.c   (working copy)                                          
@@ -1058,7 +1058,7 @@ expand_ifn_va_arg_1 (function *fun)
            gimplify_assign (lhs, expr, &pre);                                  
          }                                                                     
        else                                                                    
-         gimplify_expr (&expr, &pre, &post, is_gimple_lvalue, fb_lvalue);      
+         gimplify_and_add (expr, &pre);                                        

        input_location = saved_location;                                        
        pop_gimplify_context (NULL);                                            

Would appreciate any additional testing from James and Andrew -- thanks!

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]