mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-08 13:14:56 +00:00
test: Generate expected output for all tests
The expected output is far from perfect, and the generated HLSL and MSL isn't even validated yet, so may be incorrect. However, by committing the generated output, we get clear examples of the currently generated output of each backend. As we land fixes and improvements to each backend, the presubmits will require us to update the expected test output, and so code reviews will include diffs of each backend's generated output. Change-Id: I5c2a9e5b796d0ab75b3ec4c7f8ad00a0a2ab166f Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/51224 Commit-Queue: Ben Clayton <bclayton@chromium.org> Reviewed-by: David Neto <dneto@google.com>
This commit is contained in:
committed by
Commit Bot service account
parent
5858dcc313
commit
d1232670ae
1494
test/bug/tint/749.spvasm.expected.wgsl
Normal file
1494
test/bug/tint/749.spvasm.expected.wgsl
Normal file
File diff suppressed because it is too large
Load Diff
12
test/bug/tint/782.wgsl.expected.hlsl
Normal file
12
test/bug/tint/782.wgsl.expected.hlsl
Normal file
@@ -0,0 +1,12 @@
|
||||
|
||||
void foo() {
|
||||
int tint_symbol[2] = {0, 0};
|
||||
int implict[2] = {0, 0};
|
||||
implict = tint_symbol;
|
||||
}
|
||||
|
||||
[numthreads(1, 1, 1)]
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
|
||||
10
test/bug/tint/782.wgsl.expected.msl
Normal file
10
test/bug/tint/782.wgsl.expected.msl
Normal file
@@ -0,0 +1,10 @@
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
|
||||
void foo() {
|
||||
int tint_symbol[2] = {0};
|
||||
int implict[2] = {0};
|
||||
implict = tint_symbol;
|
||||
}
|
||||
|
||||
34
test/bug/tint/782.wgsl.expected.spvasm
Normal file
34
test/bug/tint/782.wgsl.expected.spvasm
Normal file
@@ -0,0 +1,34 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 16
|
||||
; Schema: 0
|
||||
OpCapability Shader
|
||||
OpMemoryModel Logical GLSL450
|
||||
OpEntryPoint GLCompute %unused_entry_point "unused_entry_point"
|
||||
OpExecutionMode %unused_entry_point LocalSize 1 1 1
|
||||
OpName %unused_entry_point "unused_entry_point"
|
||||
OpName %foo "foo"
|
||||
OpName %explicit "explicit"
|
||||
OpName %implict "implict"
|
||||
OpDecorate %_arr_int_uint_2 ArrayStride 4
|
||||
%void = OpTypeVoid
|
||||
%1 = OpTypeFunction %void
|
||||
%int = OpTypeInt 32 1
|
||||
%uint = OpTypeInt 32 0
|
||||
%uint_2 = OpConstant %uint 2
|
||||
%_arr_int_uint_2 = OpTypeArray %int %uint_2
|
||||
%_ptr_Function__arr_int_uint_2 = OpTypePointer Function %_arr_int_uint_2
|
||||
%13 = OpConstantNull %_arr_int_uint_2
|
||||
%unused_entry_point = OpFunction %void None %1
|
||||
%4 = OpLabel
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%foo = OpFunction %void None %1
|
||||
%6 = OpLabel
|
||||
%explicit = OpVariable %_ptr_Function__arr_int_uint_2 Function %13
|
||||
%implict = OpVariable %_ptr_Function__arr_int_uint_2 Function %13
|
||||
%15 = OpLoad %_arr_int_uint_2 %explicit
|
||||
OpStore %implict %15
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
9
test/bug/tint/782.wgsl.expected.wgsl
Normal file
9
test/bug/tint/782.wgsl.expected.wgsl
Normal file
@@ -0,0 +1,9 @@
|
||||
type ArrayExplicitStride = [[stride(4)]] array<i32, 2>;
|
||||
|
||||
type ArrayImplicitStride = array<i32, 2>;
|
||||
|
||||
fn foo() {
|
||||
var explicit : ArrayExplicitStride;
|
||||
var implict : ArrayImplicitStride;
|
||||
implict = explicit;
|
||||
}
|
||||
Reference in New Issue
Block a user