mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-06 12:15:43 +00:00
This CL adds const-eval for the `sign` builtin. Bug: tint:1581 Change-Id: I5d9bfd3f3f742bcba69fbb0d7f47dc57ce18e134 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/107460 Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Dan Sinclair <dsinclair@chromium.org> Reviewed-by: Antonio Maiorano <amaiorano@google.com>
12 lines
228 B
HLSL
12 lines
228 B
HLSL
cbuffer cbuffer_i : register(b0, space0) {
|
|
uint4 i[1];
|
|
};
|
|
RWByteAddressBuffer j : register(u1, space0);
|
|
|
|
[numthreads(1, 1, 1)]
|
|
void main() {
|
|
const uint l = dot(i[0].xyz, i[0].xyz);
|
|
j.Store(0u, asuint(i[0].x));
|
|
return;
|
|
}
|