Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-29 Thread Nathan Chancellor
On Tue, Oct 22, 2019 at 03:57:09AM -0500, Segher Boessenkool wrote: > On Mon, Oct 21, 2019 at 10:15:29PM -0700, Nathan Chancellor wrote: > > On Fri, Oct 18, 2019 at 03:02:10PM -0500, Segher Boessenkool wrote: > > > I think the proper solution is for the kernel to *do* use -ffreestanding, > > > and

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-22 Thread Segher Boessenkool
On Mon, Oct 21, 2019 at 10:15:29PM -0700, Nathan Chancellor wrote: > On Fri, Oct 18, 2019 at 03:02:10PM -0500, Segher Boessenkool wrote: > > I think the proper solution is for the kernel to *do* use -ffreestanding, > > and then somehow tell the kernel that memcpy etc. are the standard > > functions

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-21 Thread Nathan Chancellor
On Fri, Oct 18, 2019 at 03:02:10PM -0500, Segher Boessenkool wrote: > On Fri, Oct 18, 2019 at 12:00:22PM -0700, Nathan Chancellor wrote: > > Just as an FYI, there was some more discussion around the availablity > > and use of bcmp in this LLVM bug which spawned > > commit 5f074f3e192f ("lib/string.

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-18 Thread Segher Boessenkool
On Fri, Oct 18, 2019 at 12:00:22PM -0700, Nathan Chancellor wrote: > Just as an FYI, there was some more discussion around the availablity > and use of bcmp in this LLVM bug which spawned > commit 5f074f3e192f ("lib/string.c: implement a basic bcmp"). > > https://bugs.llvm.org/show_bug.cgi?id=4103

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-18 Thread Nathan Chancellor
On Mon, Oct 14, 2019 at 02:11:41PM -0500, Segher Boessenkool wrote: > On Mon, Oct 14, 2019 at 08:56:12AM -0700, Nick Desaulniers wrote: > > On Mon, Oct 14, 2019 at 2:35 AM Segher Boessenkool > > wrote: > > > > > > On Sun, Oct 13, 2019 at 07:51:01PM -0700, Nathan Chancellor wrote: > > > > r374662 g

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-14 Thread Segher Boessenkool
On Mon, Oct 14, 2019 at 08:56:12AM -0700, Nick Desaulniers wrote: > On Mon, Oct 14, 2019 at 2:35 AM Segher Boessenkool > wrote: > > > > On Sun, Oct 13, 2019 at 07:51:01PM -0700, Nathan Chancellor wrote: > > > r374662 gives LLVM the ability to convert certain loops into a reference > > > to bcmp as

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-14 Thread Nick Desaulniers
On Mon, Oct 14, 2019 at 2:35 AM Segher Boessenkool wrote: > > On Sun, Oct 13, 2019 at 07:51:01PM -0700, Nathan Chancellor wrote: > > r374662 gives LLVM the ability to convert certain loops into a reference > > to bcmp as an optimization; this breaks prom_init_check.sh: > > When/why does LLVM think

Re: [PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-14 Thread Segher Boessenkool
On Sun, Oct 13, 2019 at 07:51:01PM -0700, Nathan Chancellor wrote: > r374662 gives LLVM the ability to convert certain loops into a reference > to bcmp as an optimization; this breaks prom_init_check.sh: When/why does LLVM think this is okay? This function has been removed from POSIX over a decad

[PATCH v4 3/3] powerpc/prom_init: Use -ffreestanding to avoid a reference to bcmp

2019-10-13 Thread Nathan Chancellor
r374662 gives LLVM the ability to convert certain loops into a reference to bcmp as an optimization; this breaks prom_init_check.sh: CALLarch/powerpc/kernel/prom_init_check.sh Error: External symbol 'bcmp' referenced from prom_init.c make[2]: *** [arch/powerpc/kernel/Makefile:196: prom_init_