From f8294202ce8d5658f6308eeaed634058db9bbb4b Mon Sep 17 00:00:00 2001 From: Anders Leino Date: Wed, 6 Nov 2024 13:14:35 +0200 Subject: Make various parameters and return types require specialization when targeting WGSL (#5483) Structured buffer types translate to array types in the WGSL emitter. WGSL doesn't allow passing runtime-sized arrays to functions. Similarly for pointers to texture handles. Also, structured buffers (runtime-sized arrays) cannot be returned in WGSL. This closes issue #5228, issue #5278 and issue #5288 by enabling specialized functions to be generated in these cases, in order to work around these constraints. --- .../optimization/func-resource-result/func-resource-result-simple.slang | 1 - 1 file changed, 1 deletion(-) (limited to 'tests/optimization') diff --git a/tests/optimization/func-resource-result/func-resource-result-simple.slang b/tests/optimization/func-resource-result/func-resource-result-simple.slang index 7366bc179..80342e569 100644 --- a/tests/optimization/func-resource-result/func-resource-result-simple.slang +++ b/tests/optimization/func-resource-result/func-resource-result-simple.slang @@ -4,7 +4,6 @@ //TEST(compute, vulkan):COMPARE_COMPUTE_EX:-vk -compute -shaderobj //TEST(compute):COMPARE_COMPUTE_EX:-cpu -compute -shaderobj //TEST(compute):COMPARE_COMPUTE:-slang -shaderobj -mtl -//DISABLE_TEST(compute):COMPARE_COMPUTE_EX:-wgpu // Test that a function that returns a resource type can be // compiled for targets that don't natively support resource -- cgit v1.2.3