[clang] [llvm] [HLSL] Add WaveActiveBitOr HLSL function (PR #178056)
Tex Riddell via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 29 11:51:54 PST 2026
================
@@ -3597,6 +3597,31 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall) {
TheCall->setType(ArgTyExpr);
break;
}
+ case Builtin::BI__builtin_hlsl_wave_active_bit_or: {
+ if (SemaRef.checkArgCount(TheCall, 1))
+ return true;
+
+ // Ensure input expr type is a scalar/vector and then
+ // set the return type to the arg type
+ QualType ArgType = TheCall->getArg(0)->getType();
+
+ if (!(ArgType->isScalarType())) {
----------------
tex3d wrote:
In this case, the comment above is correct - we should support scalar or vector, but this code requires scalar.
https://github.com/llvm/llvm-project/pull/178056
More information about the cfe-commits
mailing list