From 07166468c6fa706b7f35d3422e4966f62e7b86d2 Mon Sep 17 00:00:00 2001 From: Jay Kwak <82421531+jkwak-work@users.noreply.github.com> Date: Tue, 17 Sep 2024 13:51:08 -0700 Subject: Implement math intrinsics for WGSL (#5078) * Implement math intrinsics for WGSL This commit implements math related intrinsics and a few others for WGSL. The implementation is based on the following doc, https://www.w3.org/TR/WGSL slang-test was looking for the downstream compiler for WGSL even though it is not used. This commit adds a minimal change to avoid the crash. --- tools/slang-test/test-context.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tools/slang-test/test-context.h') diff --git a/tools/slang-test/test-context.h b/tools/slang-test/test-context.h index 28d39b064..314ec2803 100644 --- a/tools/slang-test/test-context.h +++ b/tools/slang-test/test-context.h @@ -37,7 +37,8 @@ struct PassThroughFlag Generic_C_CPP = 1 << int(SLANG_PASS_THROUGH_GENERIC_C_CPP), NVRTC = 1 << int(SLANG_PASS_THROUGH_NVRTC), LLVM = 1 << int(SLANG_PASS_THROUGH_LLVM), - Metal = 1 << int(SLANG_PASS_THROUGH_METAL) + Metal = 1 << int(SLANG_PASS_THROUGH_METAL), + WGSL = 1 << int(SLANG_PASS_THROUGH_WGSL) }; }; -- cgit v1.2.3