[clang] [HLSL] Make memory representation of boolean vectors in HLSL, vectors of i32. Add support for boolean swizzling. (PR #123977)

Chris B via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 14 12:56:38 PST 2025


================
@@ -2064,6 +2064,9 @@ llvm::Value *CodeGenFunction::EmitToMemory(llvm::Value *Value, QualType Ty) {
 
   if (Ty->isExtVectorBoolType()) {
     llvm::Type *StoreTy = convertTypeForLoadStore(Ty, Value->getType());
+    if (getLangOpts().HLSL)
----------------
llvm-beanz wrote:

Do we need to check HLSL here? We should be able to instead check that StoreTy refers to a smaller integer type than Value->getType() right?

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


More information about the cfe-commits mailing list