From: Richard Henderson <richard.henderson@linaro.org>
To: Michael Tokarev <mjt@tls.msk.ru>, WANG Rui <wangrui@loongson.cn>
Cc: qemu-devel@nongnu.org, qemu@hev.cc, qemu-stable <qemu-stable@nongnu.org>
Subject: Re: [PATCH] tcg/optimize: Fix folding of vector bitsel
Date: Wed, 24 Sep 2025 12:33:29 -0700 [thread overview]
Message-ID: <e6911694-a412-4092-9c72-98d33aec9f70@linaro.org> (raw)
In-Reply-To: <1c834cbf-95be-4ee6-8048-7a6ca34ab0f8@tls.msk.ru>
On 9/24/25 12:31, Michael Tokarev wrote:
> On 19.09.2025 15:49, WANG Rui wrote:
>> It looks like a typo. When the false value (C) is the constant -1, the
>> correct fold should be: R = B | ~A
>>
>> Reproducer (LoongArch64 assembly):
>>
>> .text
>> .globl _start
>> _start:
>> vldi $vr1, 3073
>> vldi $vr2, 1023
>> vbitsel.v $vr0, $vr2, $vr1, $vr2
>> vpickve2gr.d $a1, $vr0, 1
>> xori $a0, $a1, 1
>> li.w $a7, 93
>> syscall 0
>>
>> Fixes: e58b977238e3 ("tcg/optimize: Optimize bitsel_vec")
>> Link: https://github.com/llvm/llvm-project/issues/159610
>> Signed-off-by: WANG Rui <wangrui@loongson.cn>
>
> It also looks like qemu-stable@ material.
>
> Please let me know if it isn't.
It is, yes.
r~
prev parent reply other threads:[~2025-09-24 19:34 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-19 12:49 [PATCH] tcg/optimize: Fix folding of vector bitsel WANG Rui
2025-09-23 23:17 ` Richard Henderson
2025-09-24 4:03 ` Philippe Mathieu-Daudé
2025-09-24 4:29 ` WANG Rui
2025-09-25 0:23 ` Philippe Mathieu-Daudé
2025-09-24 19:31 ` Michael Tokarev
2025-09-24 19:33 ` Richard Henderson [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=e6911694-a412-4092-9c72-98d33aec9f70@linaro.org \
--to=richard.henderson@linaro.org \
--cc=mjt@tls.msk.ru \
--cc=qemu-devel@nongnu.org \
--cc=qemu-stable@nongnu.org \
--cc=qemu@hev.cc \
--cc=wangrui@loongson.cn \
/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 NNTP newsgroup(s).