forked from openhwgroup/corev-gcc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added __builtin_riscv_cv_simd_neg_[h,b]
Issue [openhwgroup#54](openhwgroup#54) CORE-V: SIMD __builtin_riscv_cv_simd_neg_h and __builtin_riscv_cv_simd_neg_b needs implementing Files Changed: * config/riscv/corev.def: Added new builtins. * config/riscv/corev.md: Likewise. * testsuite/gcc.target/riscv/cv-simd-neg-b-compile-1.c: Created. * testsuite/gcc.target/riscv/cv-simd-neg-h-compile-1.c: Likewise. Signed-off-by: Mary Bennett <[email protected]>
- Loading branch information
Mary Bennett
committed
Aug 29, 2023
1 parent
5ebc68d
commit f04196c
Showing
4 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
/* { dg-do compile } */ | ||
/* { dg-options "-march=rv32i_xcvsimd -mabi=ilp32" } */ | ||
|
||
int foo1 (int a) | ||
{ | ||
return __builtin_riscv_cv_simd_neg_b(a); | ||
} | ||
|
||
/* { dg-final { scan-assembler-times "cv\\.sub\\.b" 1 } } */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
/* { dg-do compile } */ | ||
/* { dg-options "-march=rv32i_xcvsimd -mabi=ilp32" } */ | ||
|
||
int foo1 (int a) | ||
{ | ||
return __builtin_riscv_cv_simd_neg_h(a); | ||
} | ||
|
||
/* { dg-final { scan-assembler-times "cv\\.sub\\.h" 1 } } */ |