The attached patch contains __builtin_arm_rbit which generates RBIT
instruction for ARM targets.
Please let me know if you any questions or comments, or commit this
patch for me as I do not have write access to SVN.
Thanks
Ayan
commit a692b5b4965840babbdaf5e2b9b1feb1995d351d
Author: Ayan
the existing ARM backend configurations. Please
let me know if you have any questions or need further modifications.
Thanks,
Ayan
[1] ARM ACLE Document:
https://arm-software.github.io/acle/main/acle.html#fused-multiply-accumulate-fma
Signed-off-by: Ayan Shafqat
diff --git a/gcc/config/aarch64
for
AArch64, confirming that the generated code uses the expected fused
multiply-accumulate instructions (fmadd).
[1]
https://arm-software.github.io/acle/main/acle.html#fused-multiply-accumulate-fma
Signed-off-by: Ayan Shafqat
---
gcc/config/aarch64/arm_acle.h | 14
arm-cortexa9_neon-linux-gnueabihf, confirming that the generated code
uses the expected fused multiply-accumulate instructions:
vfma.f32 for single precision
vmfa.f64 for double precision
Signed-off-by: Ayan Shafqat
[1]
https://arm-software.github.io/acle/main/acle.html#fused-multiply
Hello Kyrylo,
On Tue, Mar 11, 2025 at 08:55:46AM +, Kyrylo Tkachov wrote:
> This looks ok to me.
> GCC is currently in a regression fixing stage so normally such a change would
> wait until stage 1 reopens.
> But this looks like a pretty safe change so I’m not against taking it now.
> Do you
that `BUILTIN_VHSDF_HSDF` handles those cases.
Signed-off-by: Ayan Shafqat
Signed-off-by: Andrew Pinski
---
gcc/config/aarch64/aarch64-simd-builtins.def | 5 +
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/gcc/config/aarch64/aarch64-simd-builtins.def
b/gcc/config/aarch64
library or optimization levels.
Signed-off-by: Ayan Shafqat
---
gcc/config/aarch64/arm_acle.h | 14 ++
1 file changed, 14 insertions(+)
diff --git a/gcc/config/aarch64/arm_acle.h b/gcc/config/aarch64/arm_acle.h
index 7976c117daf..d972a4e7e7e 100644
--- a/gcc/config/aarch64/arm_acle.h
not fall back to
library calls, regardless of optimization levels.
Signed-off-by: Ayan Shafqat
---
.../gcc.target/aarch64/acle/acle_sqrt.c | 17 +
1 file changed, 17 insertions(+)
create mode 100644 gcc/testsuite/gcc.target/aarch64/acle/acle_sqrt.c
diff --git a/gcc
mode is selected for each precision variant.
Signed-off-by: Ayan Shafqat
Signed-off-by: Andrew Pinski
---
gcc/config/arm/arm-builtins.cc | 3 +++
gcc/config/arm/arm_vfp_builtins.def | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/config/arm/arm-builtins.cc b/gcc
This patch introduces inline definitions for the __fma and __fmaf
functions in arm_acle.h for Aarch64 targets. These definitions rely on
__builtin_fma and __builtin_fmaf to ensure proper inlining and to meet
the ACLE requirements [1].
The patch has been tested locally using a crosstool-NG sysroot
This patch introduces inline definitions for the __fma and __fmaf
functions in arm_acle.h for arm targets. These definitions rely on
__builtin_fma and __builtin_fmaf to ensure proper inlining and to meet
the ACLE requirements [1].
The patch has been tested locally using a crosstool-NG sysroot for
that `BUILTIN_VHSDF_HSDF` handles those cases.
gcc/ChangeLog:
* config/aarch64/aarch64-simd-builtins.def: Change
BUILTIN_VHSDF_DF to BUILTIN_VHSDF_HSDF
Signed-off-by: Ayan Shafqat
Signed-off-by: Andrew Pinski
---
gcc/config/aarch64/aarch64-simd-builtins.def | 5 +
1 file
library or optimization levels.
gcc/ChangeLog:
* config/aarch64/arm_acle.h (__sqrt, __sqrtf): New function.
Signed-off-by: Ayan Shafqat
---
gcc/config/aarch64/arm_acle.h | 14 ++
1 file changed, 14 insertions(+)
diff --git a/gcc/config/aarch64/arm_acle.h b/gcc/config/aarch64
not fall back to
library calls, regardless of optimization levels.
gcc/testsuite/ChangeLog:
* gcc.target/aarch64/acle/acle_sqrt.c: New test.
Signed-off-by: Ayan Shafqat
---
.../gcc.target/aarch64/acle/acle_sqrt.c | 17 +
1 file changed, 17 insertions(+)
create
library or optimization levels.
gcc/ChangeLog:
* config/aarch64/arm_acle.h (__sqrt, __sqrtf): New function.
Signed-off-by: Ayan Shafqat
---
gcc/config/aarch64/arm_acle.h | 14 ++
1 file changed, 14 insertions(+)
diff --git a/gcc/config/aarch64/arm_acle.h b/gcc/config/aarch64
definitions for __sqrt() and __sqrtf().
new file: gcc/testsuite/gcc.target/arm/acle/acle_sqrt.c
* Create tests to compile and check for vsqrt.f64 and vsqrt.f32 instructions.
[1] https://developer.arm.com/documentation/101028/0012/3--C-language-extensions
Signed-off-by: Ayan Shafqat
---
gcc
--C-language-extensions
gcc/ChangeLog:
* config/arm/arm_acle.h (__sqrt, __sqrtf): New functions
gcc/testsuite/ChangeLog:
* gcc.target/arm/acle/acle_sqrt.c: New test.
Signed-off-by: Ayan Shafqat
---
gcc/config/arm/arm_acle.h | 18 ++
gcc
mode is selected for each precision variant.
Signed-off-by: Ayan Shafqat
Signed-off-by: Andrew Pinski
gcc/ChangeLog:
* config/arm/arm-builtins.cc (df_UP): New macro.
* config/arm/arm_vfp_builtins.def (VAR1, VAR3): Change VAR1 to
VAR3, for HF, SF, and DF modes.
---
gcc
025 at 05:23:00PM -0400, Ayan Shafqat wrote:
> > This patch introduces two new inline functions, __sqrt and __sqrtf, in
> > +__sqrt(double __x)
> Just formatting nits, there should be space in between the function name
> and ( and only one space between double and __x.
Tha
Hello Jakub:
Thank you very much for your feedback. See additional replies below.
On Thu, Mar 13, 2025 at 10:31:44PM +0100, Jakub Jelinek wrote:
> On Thu, Mar 13, 2025 at 05:25:26PM -0400, Ayan Shafqat wrote:
> > gcc/testsuite/ChangeLog:
> >
> > * gcc.target/aarch64/
expanded to hardware instructions and do not fall back to
library calls, regardless of optimization levels.
gcc/ChangeLog:
* config/aarch64/arm_acle.h (__sqrt, __sqrtf): New function.
gcc/testsuite/ChangeLog:
* gcc.target/aarch64/acle/acle_sqrt.c: New test.
Signed-off-by: Ayan Shafqat
that `BUILTIN_VHSDF_HSDF` handles those cases.
gcc/ChangeLog:
* config/aarch64/aarch64-simd-builtins.def: Change
BUILTIN_VHSDF_DF to BUILTIN_VHSDF_HSDF
Signed-off-by: Ayan Shafqat
Signed-off-by: Andrew Pinski
---
gcc/config/aarch64/aarch64-simd-builtins.def | 5 +
1 file
This patch introduces inline definitions for the __fma and __fmaf
functions in arm_acle.h for arm targets. These definitions rely on
__builtin_fma and __builtin_fmaf to ensure proper inlining and to meet
the ACLE requirements [1].
The patch has been tested locally using a crosstool-NG sysroot for
On Thu, Mar 13, 2025 at 08:31:24AM +, Kyrylo Tkachov wrote:
>
> I forgot during the review, but a patch needs a ChangeLog entry.
> Could you provide one please to add to the commit log?
>
I have submitted the patch again in the mailing list:
https://gcc.gnu.org/pipermail/gcc-patches/2025-Marc
This patch introduces inline definitions for the __fma and __fmaf
functions in arm_acle.h for Aarch64 targets. These definitions rely on
__builtin_fma and __builtin_fmaf to ensure proper inlining and to meet
the ACLE requirements [1].
The patch has been tested locally using a crosstool-NG sysroot
25 matches
Mail list logo