[Bug rtl-optimization/126426] riscv rvv: Incorrect result with -march=rva23u64 -O2 in libgav1
law at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Aug 4 22:43:41 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126426
--- Comment #5 from Jeffrey A. Law <law at gcc dot gnu.org> ---
So I think I know what's going on here. I don't think we're handling vector
modes correctly in ext-dce.
Consider something like (subreg:V2HI (reg:DI N)). What bits are live within N?
Right now ext-dce reports 0xffff and that in turn enables removal of an
extension. That seems horribly wrong. 0xfffffff seems much more correct ;-)
I need to go back to the initial review discussion which pushed us towards
using GET_MODE_INNER in various places.
Conceptually for destinations, GET_MODE_INNER is likely conservatively correct.
But for source operands, it seems quite wrong.
More information about the Gcc-bugs
mailing list