From: "juzhe.zhong@rivai.ai" <juzhe.zhong@rivai.ai>
To: "Robin Dapp" <rdapp.gcc@gmail.com>,
gcc-patches <gcc-patches@gcc.gnu.org>
Cc: "Robin Dapp" <rdapp.gcc@gmail.com>,
kito.cheng <kito.cheng@gmail.com>,
Kito.cheng <kito.cheng@sifive.com>,
jeffreyalaw <jeffreyalaw@gmail.com>
Subject: Re: Re: [PATCH V2] RISC-V: Enable vec_int testsuite for RVV VLA vectorization
Date: Mon, 28 Aug 2023 18:17:22 +0800 [thread overview]
Message-ID: <7A327758FC85C2EC+2023082818172204830234@rivai.ai> (raw)
In-Reply-To: <47cd479f-be23-d9dc-69a3-42da888cf3c3@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 9998 bytes --]
Ok. Add -Wno-psabi which reduce 5 FAILS.
V3:
https://gcc.gnu.org/pipermail/gcc-patches/2023-August/628572.html
juzhe.zhong@rivai.ai
From: Robin Dapp
Date: 2023-08-28 16:22
To: Juzhe-Zhong; gcc-patches
CC: rdapp.gcc; kito.cheng; kito.cheng; jeffreyalaw
Subject: Re: [PATCH V2] RISC-V: Enable vec_int testsuite for RVV VLA vectorization
Thanks,
just giving my quick thoughts on some of the FAILs:
> Test report:
> FAIL: gcc.dg/vect/bb-slp-10.c -flto -ffat-lto-objects scan-tree-dump slp2 "unsupported unaligned access"
> FAIL: gcc.dg/vect/bb-slp-10.c scan-tree-dump slp2 "unsupported unaligned access"
For these we would need to add riscv to target_vect_element_align_preferred.
That might depend on uarch, though.
> FAIL: gcc.dg/vect/bb-slp-70.c (test for excess errors)
> FAIL: gcc.dg/vect/bb-slp-70.c -flto -ffat-lto-objects (test for excess errors)
> FAIL: gcc.dg/vect/bb-slp-layout-17.c (test for excess errors)
> FAIL: gcc.dg/vect/bb-slp-layout-17.c -flto -ffat-lto-objects (test for excess errors)
For these we need -Wno-psabi for now. Besides, I still wanted to provide a
popcount fallback sometime soon.
> FAIL: gcc.dg/vect/pr65310.c -flto -ffat-lto-objects scan-tree-dump vect "can't force alignment"
> FAIL: gcc.dg/vect/pr65310.c -flto -ffat-lto-objects scan-tree-dump-not vect "misalign = 0"
> FAIL: gcc.dg/vect/pr65310.c scan-tree-dump vect "can't force alignment"
> FAIL: gcc.dg/vect/pr65310.c scan-tree-dump-not vect "misalign = 0"
Same as above with vect_element_align_preferred.
> XPASS: gcc.dg/vect/vect-10.c -flto -ffat-lto-objects scan-tree-dump-times vect "vectorized 1 loops" 1
> XPASS: gcc.dg/vect/vect-10.c scan-tree-dump-times vect "vectorized 1 loops" 1
> FAIL: gcc.dg/vect/vect-104.c -flto -ffat-lto-objects scan-tree-dump-times vect "possible dependence between data-refs" 1
> FAIL: gcc.dg/vect/vect-104.c scan-tree-dump-times vect "possible dependence between data-refs" 1
> FAIL: gcc.dg/vect/vect-109.c -flto -ffat-lto-objects scan-tree-dump-times vect "unsupported unaligned access" 2
> FAIL: gcc.dg/vect/vect-109.c scan-tree-dump-times vect "unsupported unaligned access" 2
> XPASS: gcc.dg/vect/vect-24.c -flto -ffat-lto-objects scan-tree-dump-times vect "vectorized 3 loops" 1
> XPASS: gcc.dg/vect/vect-24.c scan-tree-dump-times vect "vectorized 3 loops" 1
> FAIL: gcc.dg/vect/vect-26.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-26.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-27.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-27.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-29.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-29.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-33.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using versioning" 1
> FAIL: gcc.dg/vect/vect-33.c scan-tree-dump-times vect "Alignment of access forced using versioning" 1
> FAIL: gcc.dg/vect/vect-72.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-72.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-75-big-array.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-75-big-array.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-75.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-75.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-77-alignchecks.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-77-alignchecks.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-77-global.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-77-global.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-78-alignchecks.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-78-alignchecks.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-78-global.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-78-global.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-89-big-array.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-89-big-array.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-89.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-89.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-96.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-96.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-96.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-96.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
As mentioned back when we added the movmisalign pattern, most of those are not real
problems but due to us not properly reporting whether we support misaligned vectors
in HW or not.
> FAIL: gcc.dg/vect/vect-align-1.c -flto -ffat-lto-objects execution test
> FAIL: gcc.dg/vect/vect-align-1.c execution test
> FAIL: gcc.dg/vect/vect-align-2.c -flto -ffat-lto-objects execution test
> FAIL: gcc.dg/vect/vect-align-2.c execution test
Those need vect_hw_misalign (if the uarch supports it).
> FAIL: gcc.dg/vect/vect-div-bitmask-4.c (test for excess errors)
> FAIL: gcc.dg/vect/vect-div-bitmask-4.c -flto -ffat-lto-objects (test for excess errors)
-Wno-psabi again. I would add this to the default vectorizer settings.
> FAIL: gcc.dg/vect/vect-multitypes-1.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 2
> FAIL: gcc.dg/vect/vect-multitypes-1.c scan-tree-dump-times vect "Alignment of access forced using peeling" 2
> FAIL: gcc.dg/vect/vect-multitypes-11.c -flto -ffat-lto-objects scan-tree-dump-times vect "vectorized 1 loops" 1
> FAIL: gcc.dg/vect/vect-multitypes-11.c scan-tree-dump-times vect "vectorized 1 loops" 1
> FAIL: gcc.dg/vect/vect-multitypes-3.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 3
> FAIL: gcc.dg/vect/vect-multitypes-3.c scan-tree-dump-times vect "Vectorizing an unaligned access" 3
> FAIL: gcc.dg/vect/vect-multitypes-4.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 2
> FAIL: gcc.dg/vect/vect-multitypes-4.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 8
> FAIL: gcc.dg/vect/vect-multitypes-4.c scan-tree-dump-times vect "Alignment of access forced using peeling" 2
> FAIL: gcc.dg/vect/vect-multitypes-4.c scan-tree-dump-times vect "Vectorizing an unaligned access" 8
> FAIL: gcc.dg/vect/vect-multitypes-6.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 6
> FAIL: gcc.dg/vect/vect-multitypes-6.c scan-tree-dump-times vect "Vectorizing an unaligned access" 6
vect_hw_misalign again.
> FAIL: gcc.dg/vect/vect-peel-1.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-peel-1.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-peel-3.c -flto -ffat-lto-objects scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-peel-3.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-peel-3.c scan-tree-dump-times vect "Alignment of access forced using peeling" 1
> FAIL: gcc.dg/vect/vect-peel-3.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-peel-4.c -flto -ffat-lto-objects scan-tree-dump-times vect "Vectorizing an unaligned access" 1
> FAIL: gcc.dg/vect/vect-peel-4.c scan-tree-dump-times vect "Vectorizing an unaligned access" 1
vect_element_align_preferred again.
> - } "-march=rv32gcv -mabi=ilp32d"] || [check_runtime riscv_vector_hw64 {
> + } ""] || [check_runtime riscv_vector_hw64 {
> int main (void)
> {
> asm ("vsetivli zero,8,e16,m1,ta,ma");
> asm ("vadd.vv v8,v8,v16" : : : "v8");
> return 0;
> }
> - } "-march=rv64gcv -mabi=lp64d"]
> + } ""]
> }
> @@ -11100,6 +11101,15 @@ proc check_vect_support_and_set_flags { } {
> }
> } elseif [istarget amdgcn-*-*] {
> set dg-do-what-default run
> + } elseif [istarget riscv64-*-*] {
> + if [check_effective_target_riscv_vector_hw] {
> + lappend DEFAULT_VECTCFLAGS "--param" "riscv-autovec-preference=scalable"
> + set dg-do-what-default run
> + } else {
> + lappend DEFAULT_VECTCFLAGS "-march=rv64gcv_zvfh" "-mabi=lp64d"
> + lappend DEFAULT_VECTCFLAGS "--param" "riscv-autovec-preference=scalable"
> + set dg-do-what-default compile
Please add -Wno-psabi the the DEFAULT_VECTCFLAGS for now. This already helps
with the test cases where we return a vector.
Regards
Robin
prev parent reply other threads:[~2023-08-28 10:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-28 7:14 Juzhe-Zhong
2023-08-28 8:22 ` Robin Dapp
2023-08-28 10:17 ` juzhe.zhong [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7A327758FC85C2EC+2023082818172204830234@rivai.ai \
--to=juzhe.zhong@rivai.ai \
--cc=gcc-patches@gcc.gnu.org \
--cc=jeffreyalaw@gmail.com \
--cc=kito.cheng@gmail.com \
--cc=kito.cheng@sifive.com \
--cc=rdapp.gcc@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).