]> sourceware.org Git - glibc.git/commitdiff
i386: Disable check_consistency for GCC 5 and above [BZ #25788]
authorH.J. Lu <hjl.tools@gmail.com>
Mon, 6 Apr 2020 13:02:11 +0000 (06:02 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Mon, 6 Apr 2020 13:44:33 +0000 (06:44 -0700)
check_consistency should be disabled for GCC 5 and above since there is
no fixed PIC register in GCC 5 and above.  Check __GNUC_PREREQ (5,0)
instead OPTIMIZE_FOR_GCC_5 since OPTIMIZE_FOR_GCC_5 is false with
-fno-omit-frame-pointer.

sysdeps/unix/sysv/linux/i386/sysdep.h

index 5e3888060b3cb16277971d524f6cf5f0fc4165e7..6671afe65ef192baab8dca5d9fc4d4017ec10d47 100644 (file)
@@ -580,8 +580,9 @@ struct libc_do_syscall_args
 # define EXTRAVAR_5
 #endif
 
-/* Consistency check for position-independent code.  */
-#if defined __PIC__ && !defined OPTIMIZE_FOR_GCC_5
+/* Consistency check for position-independent code.  Disabled for GCC 5
+   and above since there is no fixed PIC register in GCC 5 and above.  */
+#if defined __PIC__ && !__GNUC_PREREQ (5,0)
 # define check_consistency()                                                 \
   ({ int __res;                                                                      \
      __asm__ __volatile__                                                    \
This page took 0.050214 seconds and 5 git commands to generate.