]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* i386.c (classify_argument): Fix computing of field's offsets.
authorJan Hubicka <jh@suse.cz>
Sun, 11 Aug 2002 12:44:21 +0000 (14:44 +0200)
committerJan Hubicka <hubicka@gcc.gnu.org>
Sun, 11 Aug 2002 12:44:21 +0000 (12:44 +0000)
From-SVN: r56204

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

index 296e960097d5b3579a6cdc700e64471e0e81b115..ff97998112ad4c0a743c109b26ea8befef1a7512 100644 (file)
@@ -1,3 +1,7 @@
+Sun Aug 11 14:43:17 CEST 2002  Jan Hubicka  <jh@suse.cz>
+
+       * i386.c (classify_argument): Fix computing of field's offsets.
+
 2002-08-11  Andreas Jaeger  <aj@suse.de>
 
        PR target/7531:
index 0c1ed9fa29ed2bd5c3c85861c20d6a661e4b68d9..1010bb81948185e6aaa9d0cb4731be162ccf74da 100644 (file)
@@ -1146,6 +1146,9 @@ override_options ()
               ix86_tls_dialect_string);
     }
 
+  if (profile_flag)
+    target_flags &= ~MASK_OMIT_LEAF_FRAME_POINTER;
+
   /* Keep nonleaf frame pointers.  */
   if (TARGET_OMIT_LEAF_FRAME_POINTER)
     flag_omit_frame_pointer = 1;
@@ -1257,6 +1260,8 @@ optimization_options (level, size)
       flag_pcc_struct_return = 0;
       flag_asynchronous_unwind_tables = 1;
     }
+  if (profile_flag)
+    flag_omit_frame_pointer = 0;
 }
 \f
 /* Table of valid machine attributes.  */
@@ -1634,7 +1639,7 @@ classify_argument (mode, type, classes, bit_offset)
                     return 0;
                   for (i = 0; i < num; i++)
                     {
-                      int pos = (offset + bit_offset) / 8 / 8;
+                      int pos = (offset + (bit_offset % 64)) / 8 / 8;
                       classes[i + pos] =
                         merge_classes (subclasses[i], classes[i + pos]);
                     }
@@ -1671,7 +1676,7 @@ classify_argument (mode, type, classes, bit_offset)
                      for (i = 0; i < num; i++)
                        {
                          int pos =
-                           (int_bit_position (field) + bit_offset) / 8 / 8;
+                           (int_bit_position (field) + (bit_offset % 64)) / 8 / 8;
                          classes[i + pos] =
                            merge_classes (subclasses[i], classes[i + pos]);
                        }
@@ -1717,7 +1722,7 @@ classify_argument (mode, type, classes, bit_offset)
 
                   num = classify_argument (TYPE_MODE (type),
                                            type, subclasses,
-                                           (offset + bit_offset) % 256);
+                                           (offset + (bit_offset % 64)) % 256);
                   if (!num)
                     return 0;
                   for (i = 0; i < num; i++)