All of lore.kernel.org
 help / color / mirror / Atom feed
From: ChenQi <Qi.Chen@windriver.com>
To: Khem Raj <raj.khem@gmail.com>
Cc: OE Core mailing list <openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH 1/3] glibc: Upgrade to 2.23
Date: Thu, 31 Mar 2016 15:01:10 +0800	[thread overview]
Message-ID: <56FCCB36.4040203@windriver.com> (raw)
In-Reply-To: <39E0EE4C-3FCD-4FAC-94F2-0B4F3BED8F2F@gmail.com>

On 03/29/2016 10:16 AM, Khem Raj wrote:
>> On Mar 28, 2016, at 6:38 PM, ChenQi <Qi.Chen@windriver.com> wrote:
>>
>> On 02/23/2016 06:31 AM, Andre McCurdy wrote:
>>> On Sat, Feb 20, 2016 at 12:07 AM, Khem Raj <raj.khem@gmail.com> wrote:
>>>> Drop kconfig and options-group support
>>>> Forward port cross-localedef support
>>>> Assume ssp support in libc when building gcc-initial
>>> Breaks for me when building for x86 with -Os (building with
>>> -O1/-O2/-O3 are all OK):
>>>
>>> i686-rdk-linux-gcc  -m32 -march=core2 -mtune=core2 -msse3 -mfpmath=sse
>>> --sysroot=/home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/vbox32-tcbootstrap
>>> ../sysdeps/unix/sysv/linux/posix_fallocate.c -c -std=gnu11
>>> -fgnu89-inline  -Os -Wall -Werror -Wno-error -Wundef -Wwrite-strings
>>> -fdebug-prefix-map=/home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/vbox32=
>>> -fdebug-prefix-map=/home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/x86_64-linux=
>>> -fdebug-prefix-map=/home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux=/usr/src/glibc
>>> -fdebug-prefix-map=/home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/git=/usr/src/glibc
>>> -feliminate-unused-debug-types -fmerge-all-constants -frounding-math
>>> -g -pipe -Wstrict-prototypes -Wold-style-definition   -Wa,-mtune=i686
>>> -fexceptions  -ftls-model=initial-exec      -I../include
>>> -I/home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux/io
>>>   -I/home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux
>>>   -I../sysdeps/unix/sysv/linux/i386/i686  -I../sysdeps/i386/i686/nptl
>>> -I../sysdeps/unix/sysv/linux/i386  -I../sysdeps/unix/sysv/linux/x86
>>> -I../sysdeps/i386/nptl  -I../sysdeps/unix/sysv/linux/include
>>> -I../sysdeps/unix/sysv/linux  -I../sysdeps/nptl  -I../sysdeps/pthread
>>> -I../sysdeps/gnu  -I../sysdeps/unix/inet  -I../sysdeps/unix/sysv
>>> -I../sysdeps/unix/i386  -I../sysdeps/unix  -I../sysdeps/posix
>>> -I../sysdeps/i386/i686/fpu/multiarch  -I../sysdeps/i386/i686/fpu
>>> -I../sysdeps/i386/i686/multiarch  -I../sysdeps/i386/i686
>>> -I../sysdeps/i386/fpu  -I../sysdeps/x86/fpu/include
>>> -I../sysdeps/x86/fpu  -I../sysdeps/i386  -I../sysdeps/x86
>>> -I../sysdeps/wordsize-32  -I../sysdeps/ieee754/ldbl-96
>>> -I../sysdeps/ieee754/dbl-64  -I../sysdeps/ieee754/flt-32
>>> -I../sysdeps/ieee754  -I../sysdeps/generic  -I.. -I../libio -I.
>>> -nostdinc -isystem
>>> /home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/x86_64-linux/usr/bin/i686-rdk-linux.gcc-cross-initial-i686/../../lib/i686-rdk-linux.gcc-cross-initial-i686/gcc/i686-rdk-linux/5.3.0/include
>>> -isystem /home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/x86_64-linux/usr/bin/i686-rdk-linux.gcc-cross-initial-i686/../../lib/i686-rdk-linux.gcc-cross-initial-i686/gcc/i686-rdk-linux/5.3.0/include-fixed
>>> -isystem /home/andre/rdk/rdk-master/build-vbox32/tmp/sysroots/vbox32/usr/include
>>>   -D_LIBC_REENTRANT -include
>>> /home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux/libc-modules.h
>>> -DMODULE_NAME=libc -include ../include/libc-symbols.h       -o
>>> /home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux/io/posix_fallocate.o
>>> -MD -MP -MF /home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux/io/posix_fallocate.o.dt
>>> -MT /home/andre/rdk/rdk-master/build-vbox32/tmp/work/core2-32-rdk-linux/glibc/2.23-r0/build-i686-rdk-linux/io/posix_fallocate.o
>>> ../sysdeps/unix/sysv/linux/posix_fallocate.c: In function 'posix_fallocate':
>>> ../sysdeps/unix/sysv/linux/posix_fallocate.c:39:1: error: bp cannot be
>>> used in asm here
>>>   }
>>>   ^
>>> ../sysdeps/unix/sysv/linux/posix_fallocate.c:39:1: error: bp cannot be
>>> used in asm here
>>
>> Hi All,
>>
>> For the latest master, if 'DEBUG_BUILD' is enabled, the above error appers.
>>
>> | ../sysdeps/unix/sysv/linux/posix_fallocate.c: In function 'posix_fallocate':
>> | ../sysdeps/unix/sysv/linux/posix_fallocate.c:39:1: error: bp cannot be used in asm here
>> |  }
>> |  ^
>>
>> The problem could be reproduced if we add in local.conf the following line.
>> DEBUG_BUILD = "1"
>>
>> Do you have any idea what's going on there?
> posix_fallocate is calling a syscall helper with 6 argument, and there has been i386 specific optimization added to glibc
> which checks for gcc version and if its >= 5.0 then relies upon gcc to do right thing when spilling ebp, and switched to using
> inline syscall handler. But this spill is working/tested with -O2 and everything else is just a bonus if it works. Can you try this
> patch to glibc  ?
>
>
> --- a/sysdeps/unix/sysv/linux/i386/sysdep.h
> +++ b/sysdeps/unix/sysv/linux/i386/sysdep.h
> @@ -46,7 +46,7 @@
>      to compile glibc.  Disable GCC 5 optimization when compiling for
>      profiling since asm ("ebp") can't be used to put the 6th argument
>      in %ebp for syscall.  */
> -#if __GNUC_PREREQ (5,0) && !defined PROF
> +#if __GNUC_PREREQ (5,0) && !defined PROF && !defined __OPTIMIZE_SIZE__
>   # define OPTIMIZE_FOR_GCC_5
>   #endif
>
>
>
>

Hi Khem,

Thanks for your reply.
I've tried the above patch, but the problem is still there :(

Best Regards,
Chen Qi



  reply	other threads:[~2016-03-31  7:00 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-20  8:06 [PATCH 0/3] Upgrade glibc 2.23 Khem Raj
2016-02-20  8:07 ` [PATCH 1/3] glibc: Upgrade to 2.23 Khem Raj
2016-02-22 15:49   ` Martin Jansa
2016-02-22 16:19     ` Khem Raj
2016-02-22 16:38       ` Martin Jansa
2016-02-22 22:31   ` Andre McCurdy
2016-03-29  1:38     ` ChenQi
2016-03-29  2:16       ` Khem Raj
2016-03-31  7:01         ` ChenQi [this message]
2016-04-01  8:44           ` ChenQi
2016-04-01 14:11             ` Khem Raj
2016-02-20  8:07 ` [PATCH 2/3] pseudo: Fix build when security flags are enabled Khem Raj
2016-02-20  8:07 ` [PATCH 3/3] libnewt: Fix build with PIE flags Khem Raj

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56FCCB36.4040203@windriver.com \
    --to=qi.chen@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=raj.khem@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.