* [PATCH v2] LoongArch: testsuite:Fix fail in gen-vect-{2,25}.c file.
@ 2024-01-13 7:28 chenxiaolong
2024-01-18 7:30 ` [pushed][PATCH " chenglulu
0 siblings, 1 reply; 2+ messages in thread
From: chenxiaolong @ 2024-01-13 7:28 UTC (permalink / raw)
To: gcc-patches
Cc: xry111, i, xuchenghua, chenglulu, schwab, ci_notify, chenxiaolong
1.Added dg-do compile on LoongArch.
When binutils does not support vector instruction sets, an error occurs
because the assembler does not recognize vector instructions.
2.Added "-mlsx" option for vectorization on LoongArch.
gcc/testsuite/ChangeLog:
* gcc.dg/tree-ssa/gen-vect-2.c: Added detection of compilation
behavior and "-mlsx" option on LoongArch.
* gcc.dg/tree-ssa/gen-vect-25.c: Dito.
---
gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c | 2 ++
gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c | 2 ++
2 files changed, 4 insertions(+)
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
index b84f3184427..a35999a172a 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
@@ -1,6 +1,8 @@
/* { dg-do run { target vect_cmdline_needed } } */
+/* { dg-do compile { target { loongarch_sx && {! loongarch_sx_hw } } } } */
/* { dg-options "-O2 -fno-tree-loop-distribute-patterns -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic" } */
/* { dg-additional-options "-mno-sse" { target { i?86-*-* x86_64-*-* } } } */
+/* { dg-additional-options "-mlsx" { target { loongarch*-*-* } } } */
#include <stdlib.h>
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
index 18fe1aa1502..9f14a54c413 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
@@ -1,6 +1,8 @@
/* { dg-do run { target vect_cmdline_needed } } */
+/* { dg-do compile { target { loongarch_sx && {! loongarch_sx_hw } } } } */
/* { dg-options "-O2 -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic" } */
/* { dg-options "-O2 -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic -mno-sse" { target { i?86-*-* x86_64-*-* } } } */
+/* { dg-additional-options "-mlsx" { target { loongarch*-*-* } } } */
#include <stdlib.h>
--
2.20.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [pushed][PATCH v2] LoongArch: testsuite:Fix fail in gen-vect-{2,25}.c file.
2024-01-13 7:28 [PATCH v2] LoongArch: testsuite:Fix fail in gen-vect-{2,25}.c file chenxiaolong
@ 2024-01-18 7:30 ` chenglulu
0 siblings, 0 replies; 2+ messages in thread
From: chenglulu @ 2024-01-18 7:30 UTC (permalink / raw)
To: chenxiaolong, gcc-patches; +Cc: xry111, i, xuchenghua, schwab, ci_notify
Pushed to r14-8204.
在 2024/1/13 下午3:28, chenxiaolong 写道:
> 1.Added dg-do compile on LoongArch.
> When binutils does not support vector instruction sets, an error occurs
> because the assembler does not recognize vector instructions.
>
> 2.Added "-mlsx" option for vectorization on LoongArch.
>
> gcc/testsuite/ChangeLog:
>
> * gcc.dg/tree-ssa/gen-vect-2.c: Added detection of compilation
> behavior and "-mlsx" option on LoongArch.
> * gcc.dg/tree-ssa/gen-vect-25.c: Dito.
> ---
> gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c | 2 ++
> gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c | 2 ++
> 2 files changed, 4 insertions(+)
>
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
> index b84f3184427..a35999a172a 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-2.c
> @@ -1,6 +1,8 @@
> /* { dg-do run { target vect_cmdline_needed } } */
> +/* { dg-do compile { target { loongarch_sx && {! loongarch_sx_hw } } } } */
> /* { dg-options "-O2 -fno-tree-loop-distribute-patterns -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic" } */
> /* { dg-additional-options "-mno-sse" { target { i?86-*-* x86_64-*-* } } } */
> +/* { dg-additional-options "-mlsx" { target { loongarch*-*-* } } } */
>
> #include <stdlib.h>
>
> diff --git a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
> index 18fe1aa1502..9f14a54c413 100644
> --- a/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
> +++ b/gcc/testsuite/gcc.dg/tree-ssa/gen-vect-25.c
> @@ -1,6 +1,8 @@
> /* { dg-do run { target vect_cmdline_needed } } */
> +/* { dg-do compile { target { loongarch_sx && {! loongarch_sx_hw } } } } */
> /* { dg-options "-O2 -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic" } */
> /* { dg-options "-O2 -ftree-vectorize -fdump-tree-vect-details -fvect-cost-model=dynamic -mno-sse" { target { i?86-*-* x86_64-*-* } } } */
> +/* { dg-additional-options "-mlsx" { target { loongarch*-*-* } } } */
>
> #include <stdlib.h>
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-01-18 7:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-13 7:28 [PATCH v2] LoongArch: testsuite:Fix fail in gen-vect-{2,25}.c file chenxiaolong
2024-01-18 7:30 ` [pushed][PATCH " chenglulu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).