[clang] [Clang] Support using boolean vectors in ternary operators (PR #154145)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 18 09:31:39 PDT 2025


erichkeane wrote:

> > Nope, that was me mis-reading the Github interface. LGTM.
> 
> Nice, thanks for the quick review. I'm going to try making the generic bit functions (e.g. `__builtin_ctzg`) work with these vestors as well. A future patch I'll like to add a new queryable feature for boolean vectors so people can start depending on this expanded support. Right now we can only check `__has_feature(ext_vector_type)` which will return an error on booleans until clang 15 and isn't really useful until this patch. Likely we'll wand a builtin for masked loads / stores as well.

Another thing to look at is handling these operations in ExprConstant.cpp so that we handle them in constexpr too!

https://github.com/llvm/llvm-project/pull/154145


More information about the cfe-commits mailing list