This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Properly diagnose mixing RVV scalable vectors with GNU vectors.
ClosedPublic

Authored by craig.topper on Feb 22 2023, 6:52 PM.

Details

Summary

This case was being picked up by SVE code and printing an SVE
specific message.

This patch distinquishes RVV from SVE and provides a correct error
message for RVV.

The use of the generic isSizelessBuiltinType was also picking up
WebAssembly reference types which was probably an accident so I've
removed that.

I've named the test similar to SVE's test that contains this check.
Their test also tests the arm_sve_vector_bits attribute. I plan to
add something similar for RISC-V soon so I've adopted this naming.

Diff Detail

Event Timeline

craig.topper created this revision.Feb 22 2023, 6:52 PM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 22 2023, 6:52 PM
craig.topper requested review of this revision.Feb 22 2023, 6:52 PM
c-rhodes accepted this revision.Feb 23 2023, 5:15 AM

One minor nit but otherwise LGTM

clang/lib/Sema/SemaExpr.cpp
10769–10770

nit: update comment?

This revision is now accepted and ready to land.Feb 23 2023, 5:15 AM