================
@@ -3607,6 +3607,30 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned 
BuiltinID, CallExpr *TheCall) {
       return true;
     break;
   }
+  case Builtin::BI__builtin_hlsl_wave_prefix_count_bits: {
+    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
----------------
tex3d wrote:

This comment doesn't sound right, nor is it what the code does.
- doesn't accept vector input (WavePrefixCountBits is scalar only in DXC too, 
so it's a comment problem)
- Does not set the return type (which is fine if it's already uint in 
definition)
- The return type should not be the same as the arg type - should be uint

https://github.com/llvm/llvm-project/pull/178059
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to