Re: [PATCH 1/5] ARC/dl-runtime helper macros

2020-05-29 Thread Vineet Gupta
On 5/29/20 7:00 PM, Vineet Gupta wrote: > This is purely for review purposes to attest the interface defined > in prior patch > --- > sysdeps/arc/dl-runtime.h | 42 > 1 file changed, 42 insertions(+) > create mode 100644 sysdeps/arc/dl-runtime.h Oops this

Re: [PATCH v6 07/13] ARC: Linux Syscall Interface

2020-05-29 Thread Vineet Gupta
On 5/29/20 9:49 AM, Adhemerval Zanella via Libc-alpha wrote: > > > On 22/04/2020 22:41, Vineet Gupta via Libc-alpha wrote: >> Signed-off-by: Vineet Gupta > > As prior patches we do not use DCO, but rather copyright assignment. > >> diff --git a/sysdeps/unix/sysv/linux/arc/arch-syscall.h >> b

[PATCH 1/5] ARC/dl-runtime helper macros

2020-05-29 Thread Vineet Gupta
This is purely for review purposes to attest the interface defined in prior patch --- sysdeps/arc/dl-runtime.h | 42 1 file changed, 42 insertions(+) create mode 100644 sysdeps/arc/dl-runtime.h diff --git a/sysdeps/arc/dl-runtime.h b/sysdeps/arc/dl-runtim

[PATCH 3/5] iee754: prvoide gcc builtins based generic fma functions

2020-05-29 Thread Vineet Gupta
--- sysdeps/generic/math-use-builtins.h | 4 sysdeps/ieee754/dbl-64/s_fma.c | 6 ++ sysdeps/ieee754/dbl-64/s_fmaf.c | 6 ++ sysdeps/ieee754/float128/float128_private.h | 2 ++ sysdeps/ieee754/ldbl-128/s_fmal.c | 5 + 5 files changed, 23 i

[PATCH 2/5] iee754: prvoide gcc builtins based generic sqrt functions

2020-05-29 Thread Vineet Gupta
--- sysdeps/generic/math-use-builtins.h | 3 +++ sysdeps/ieee754/dbl-64/e_sqrt.c | 6 ++ sysdeps/ieee754/flt-32/e_sqrtf.c| 6 ++ 3 files changed, 15 insertions(+) diff --git a/sysdeps/generic/math-use-builtins.h b/sysdeps/generic/math-use-builtins.h index 8a39ef58bc95..fc724c824a

[PATCH 4/5] aarch/fpu: use generic sqrt, fma functions

2020-05-29 Thread Vineet Gupta
Signed-off-by: Vineet Gupta --- sysdeps/aarch64/fpu/e_sqrt.c| 27 -- sysdeps/aarch64/fpu/e_sqrtf.c | 27 -- sysdeps/aarch64/fpu/math-use-builtins.h | 70 + sysdeps/aarch64/fpu/s_fma.c | 28 -- sysdeps/aarch64/fpu/s_

[PATCH 0/5] use gcc builtins for sqrt and fma functions

2020-05-29 Thread Vineet Gupta
Hi, This was suggested as part of ARC port review. Build tested for following targets: aarch64-linux-gnu arm-linux-gnueabi hppa-linux-gnu x86_64-linux-gnu arm-linux-gnueabihf riscv64-linux-gnu-rv64imac-lp64 riscv64-linux-gnu-rv64imafdc-lp64 powerpc-linux-gnu microblaze-linux-gnu nios2-linux-g

[PATCH 5/5] powerpc/fpu: use generic fma functions

2020-05-29 Thread Vineet Gupta
--- sysdeps/powerpc/fpu/math-use-builtins.h | 70 + sysdeps/powerpc/fpu/s_fma.c | 27 -- sysdeps/powerpc/fpu/s_fmaf.c| 27 -- 3 files changed, 70 insertions(+), 54 deletions(-) create mode 100644 sysdeps/powerpc/fpu/math-use-builtins

Re: [PATCH v6 06/13] ARC: hardware floating point support

2020-05-29 Thread Vineet Gupta
On 5/29/20 3:28 PM, Vineet Gupta via Libc-alpha wrote: >>> +/* Macros for accessing the hardware control word. */ >>> +# define _FPU_GETCW(cw) __asm__ volatile ("lr %0, [0x300]" : "=r" (cw)) >>> +# define _FPU_SETCW(cw) __asm__ volatile ("sr %0, [0x300]" : : "r" (cw)) >>> + >>> +/* Macros for a

Re: [PATCH v6 06/13] ARC: hardware floating point support

2020-05-29 Thread Vineet Gupta
On 5/29/20 7:12 AM, Adhemerval Zanella wrote: > > > On 22/04/2020 22:41, Vineet Gupta via Libc-alpha wrote: >> Signed-off-by: Vineet Gupta >> diff --git a/sysdeps/arc/fpu/e_sqrt.c b/sysdeps/arc/fpu/e_sqrt.c >> + >> +#include >> +#include >> + >> +double >> +__ieee754_sqrt (double d) >> +{ >>

[PATCH 2/2] ARC/dl-runtime helper macros

2020-05-29 Thread Vineet Gupta
This is purely for review purposes to attest the interface defined in prior patch --- sysdeps/arc/dl-runtime.h | 42 1 file changed, 42 insertions(+) create mode 100644 sysdeps/arc/dl-runtime.h diff --git a/sysdeps/arc/dl-runtime.h b/sysdeps/arc/dl-runtim

[PATCH 1/2] dl-runtime: reloc_{offset, index} now functions arch overide'able

2020-05-29 Thread Vineet Gupta
The existing macros are fragile and expect local variables with a certain name. Fix this by defining them as functions with default implementation in a new header dl-runtime.h which arches can override if need be. This came up during ARC port review, hence the need for argument pltgot in reloc_ind

Re: [PATCH 3/3] ARC: [plat-hsdk-4xd] initial port for HSDK-4xD board

2020-05-29 Thread Vineet Gupta
+CC Rob H (it seems the CC in patch didn't go thru) On 5/29/20 4:55 AM, Eugeniy Paltsev wrote: > This initial port adds support of ARC HS4x/HS4xD Development Kit board with > some > basic features such serial port, USB, SD/MMC, SPI flash, Ethernet and others. > > The HSDK-4xD board has much in c

Re: [PATCH] dl-runtime: reloc_{offset,index} now functions arch overide'able

2020-05-29 Thread Adhemerval Zanella
On 29/05/2020 14:39, Vineet Gupta wrote: > On 5/29/20 5:58 AM, Adhemerval Zanella via Libc-alpha wrote: >> >> >> On 28/05/2020 16:43, Vineet Gupta wrote: >>> The existing macros are fragile and expect local variables with a >>> certain name. Fix this by defining them as functions with defaul >>>

Re: [PATCH 2/3] ARC: ARCv2: support loop buffer (LPB) disabling

2020-05-29 Thread Vineet Gupta
On 5/29/20 4:55 AM, Eugeniy Paltsev wrote: > On HS cores, loop buffer (LPB) is programmable in runtime and can > be optionally disabled. > > Signed-off-by: Eugeniy Paltsev LGTM. -Vineet ___ linux-snps-arc mailing list linux-snps-arc@lists.infradead.or

Re: [PATCH 1/3] ARC: allow to overide default mcpu compiler flag

2020-05-29 Thread Vineet Gupta
On 5/29/20 4:55 AM, Eugeniy Paltsev wrote: > By default we set -mcpu=xxx compiler flag depending on the CPU ISA > version. It's good starting point, however that may be not enough > as for some platforms we may want to use some specific 'mcpu' > options for better optimization or to workaround HW i

Re: [PATCH] dl-runtime: reloc_{offset,index} now functions arch overide'able

2020-05-29 Thread Vineet Gupta
On 5/29/20 5:58 AM, Adhemerval Zanella via Libc-alpha wrote: > > > On 28/05/2020 16:43, Vineet Gupta wrote: >> The existing macros are fragile and expect local variables with a >> certain name. Fix this by defining them as functions with defaul >> timplementation in a new header dl-runtime.h whic

Re: [PATCH v6 07/13] ARC: Linux Syscall Interface

2020-05-29 Thread Adhemerval Zanella
On 22/04/2020 22:41, Vineet Gupta via Libc-alpha wrote: > Signed-off-by: Vineet Gupta As prior patches we do not use DCO, but rather copyright assignment. Some comments below. > --- > sysdeps/unix/sysv/linux/arc/arch-syscall.h| 303 ++ > sysdeps/unix/sysv/linux/arc/bits/

Re: [PATCH v6 06/13] ARC: hardware floating point support

2020-05-29 Thread Adhemerval Zanella
On 22/04/2020 22:41, Vineet Gupta via Libc-alpha wrote: > Signed-off-by: Vineet Gupta As prior patch we do not use DCO, but rather copyright assignment. Some comments below. > --- > sysdeps/arc/fpu/e_sqrt.c| 27 > sysdeps/arc/fpu/e_sqrtf.c | 27 > sysdeps/a

Re: [PATCH v6 01/13] ARC: ABI Implementation

2020-05-29 Thread Adhemerval Zanella
On 27/05/2020 19:15, Vineet Gupta wrote: > On 5/27/20 11:26 AM, Adhemerval Zanella via Libc-alpha wrote: >> >> >> On 22/04/2020 22:41, Vineet Gupta via Libc-alpha wrote: >>> This code deals with the ARC ABI. >>> >>> Signed-off-by: Vineet Gupta >> >> We do not use DCO, but rather copyright assig

Re: [PATCH] dl-runtime: reloc_{offset,index} now functions arch overide'able

2020-05-29 Thread Adhemerval Zanella
On 28/05/2020 16:43, Vineet Gupta wrote: > The existing macros are fragile and expect local variables with a > certain name. Fix this by defining them as functions with defaul > timplementation in a new header dl-runtime.h which arches can overrid > eif need be. > > This came up during ARC port

Re: [PATCH private 1/3] ARC: allow to overwrite default mcpu compiler flag

2020-05-29 Thread Eugeniy Paltsev
Oooops, this one is duplicate and should be dropped. --- Eugeniy Paltsev From: Eugeniy Paltsev Sent: Friday, May 29, 2020 14:55 To: linux-snps-arc@lists.infradead.org; Vineet Gupta Cc: linux-ker...@vger.kernel.org; Alexey Brodkin; Eugeniy Paltsev Subjec

[PATCH 1/3] ARC: allow to overide default mcpu compiler flag

2020-05-29 Thread Eugeniy Paltsev
By default we set -mcpu=xxx compiler flag depending on the CPU ISA version. It's good starting point, however that may be not enough as for some platforms we may want to use some specific 'mcpu' options for better optimization or to workaround HW issues. We are going to use this option for HSDK-4x

[PATCH private 1/3] ARC: allow to overwrite default mcpu compiler flag

2020-05-29 Thread Eugeniy Paltsev
By default we set -mcpu=xxx compiler flag depending on the CPU ISA version. It's good starting point, however that may be not enough as for some platforms we may want to use some specific 'mcpu' options for better optimization or to workaround HW issues. We are going to use this option for HSDK-4x

[PATCH 0/3] ARC: [plat-hsdk-4xd] initial port for HSDK-4xD board

2020-05-29 Thread Eugeniy Paltsev
Eugeniy Paltsev (3): ARC: allow to overide default mcpu compiler flag ARC: ARCv2: support loop buffer (LPB) disabling ARC: [plat-hsdk-4xd] initial port for HSDK-4xD board arch/arc/Kconfig| 13 ++ arch/arc/Makefile | 4 + arch/arc/boot/dts/hsdk-4xd.dt

[PATCH 2/3] ARC: ARCv2: support loop buffer (LPB) disabling

2020-05-29 Thread Eugeniy Paltsev
On HS cores, loop buffer (LPB) is programmable in runtime and can be optionally disabled. Signed-off-by: Eugeniy Paltsev --- arch/arc/Kconfig | 6 ++ arch/arc/kernel/head.S | 8 2 files changed, 14 insertions(+) diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig index 2d4f85dc9

[PATCH 3/3] ARC: [plat-hsdk-4xd] initial port for HSDK-4xD board

2020-05-29 Thread Eugeniy Paltsev
This initial port adds support of ARC HS4x/HS4xD Development Kit board with some basic features such serial port, USB, SD/MMC, SPI flash, Ethernet and others. The HSDK-4xD board has much in common with its predecessor - HSDK board. However HSDK-4xD has some differences in comparison with its prede