[clang] [HLSL] Implementation of the elementwise fmod builtin (PR #108849)
Farzon Lotfi via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 26 10:04:45 PDT 2024
================
@@ -0,0 +1,37 @@
+
+// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify -verify-ignore-unexpected
+
+float test_too_few_arg() {
+ return __builtin_elementwise_fmod();
+ // expected-error at -1 {{too few arguments to function call, expected 2, have 0}}
+}
+
+float2 test_too_many_arg(float2 p0, float2 p1, float2 p3) {
----------------
farzonl wrote:
most of these test cases seem to be covered by `clang/test/Sema/builtins-elementwise-math.c`. You should be able to reduce this test down to just the two double test cases
https://github.com/llvm/llvm-project/pull/108849
More information about the cfe-commits
mailing list