mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-10 14:08:04 +00:00
tint->dawn: Shuffle source tree in preperation of merging repos
docs/ -> docs/tint/ fuzzers/ -> src/tint/fuzzers/ samples/ -> src/tint/cmd/ src/ -> src/tint/ test/ -> test/tint/ BUG=tint:1418,tint:1433 Change-Id: Id2aa79f989aef3245b80ef4aa37a27ff16cd700b Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/80482 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
This commit is contained in:
committed by
Tint LUCI CQ
parent
38f1e9c75c
commit
dbc13af287
8
test/tint/shadowing/function/let.wgsl
Normal file
8
test/tint/shadowing/function/let.wgsl
Normal file
@@ -0,0 +1,8 @@
|
||||
fn a() {
|
||||
{
|
||||
var a = 1;
|
||||
var b = a;
|
||||
}
|
||||
let a = 1;
|
||||
let b = a;
|
||||
}
|
||||
14
test/tint/shadowing/function/let.wgsl.expected.glsl
Normal file
14
test/tint/shadowing/function/let.wgsl.expected.glsl
Normal file
@@ -0,0 +1,14 @@
|
||||
#version 310 es
|
||||
|
||||
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
void a() {
|
||||
{
|
||||
int a_1 = 1;
|
||||
int b = a_1;
|
||||
}
|
||||
int b = 1;
|
||||
}
|
||||
|
||||
12
test/tint/shadowing/function/let.wgsl.expected.hlsl
Normal file
12
test/tint/shadowing/function/let.wgsl.expected.hlsl
Normal file
@@ -0,0 +1,12 @@
|
||||
[numthreads(1, 1, 1)]
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
|
||||
void a() {
|
||||
{
|
||||
int a_1 = 1;
|
||||
int b = a_1;
|
||||
}
|
||||
const int b = 1;
|
||||
}
|
||||
12
test/tint/shadowing/function/let.wgsl.expected.msl
Normal file
12
test/tint/shadowing/function/let.wgsl.expected.msl
Normal file
@@ -0,0 +1,12 @@
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
void a() {
|
||||
{
|
||||
int a_1 = 1;
|
||||
int b = a_1;
|
||||
}
|
||||
int const a_2 = 1;
|
||||
int const b = a_2;
|
||||
}
|
||||
|
||||
32
test/tint/shadowing/function/let.wgsl.expected.spvasm
Normal file
32
test/tint/shadowing/function/let.wgsl.expected.spvasm
Normal file
@@ -0,0 +1,32 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 14
|
||||
; 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 %a "a"
|
||||
OpName %a_1 "a_1"
|
||||
OpName %b "b"
|
||||
%void = OpTypeVoid
|
||||
%1 = OpTypeFunction %void
|
||||
%int = OpTypeInt 32 1
|
||||
%int_1 = OpConstant %int 1
|
||||
%_ptr_Function_int = OpTypePointer Function %int
|
||||
%11 = OpConstantNull %int
|
||||
%unused_entry_point = OpFunction %void None %1
|
||||
%4 = OpLabel
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%a = OpFunction %void None %1
|
||||
%6 = OpLabel
|
||||
%a_1 = OpVariable %_ptr_Function_int Function %11
|
||||
%b = OpVariable %_ptr_Function_int Function %11
|
||||
OpStore %a_1 %int_1
|
||||
%12 = OpLoad %int %a_1
|
||||
OpStore %b %12
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
8
test/tint/shadowing/function/let.wgsl.expected.wgsl
Normal file
8
test/tint/shadowing/function/let.wgsl.expected.wgsl
Normal file
@@ -0,0 +1,8 @@
|
||||
fn a() {
|
||||
{
|
||||
var a = 1;
|
||||
var b = a;
|
||||
}
|
||||
let a = 1;
|
||||
let b = a;
|
||||
}
|
||||
3
test/tint/shadowing/function/param.wgsl
Normal file
3
test/tint/shadowing/function/param.wgsl
Normal file
@@ -0,0 +1,3 @@
|
||||
fn a(a : i32) {
|
||||
let b = a;
|
||||
}
|
||||
10
test/tint/shadowing/function/param.wgsl.expected.glsl
Normal file
10
test/tint/shadowing/function/param.wgsl.expected.glsl
Normal file
@@ -0,0 +1,10 @@
|
||||
#version 310 es
|
||||
|
||||
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
void a(int a_1) {
|
||||
int b = a_1;
|
||||
}
|
||||
|
||||
8
test/tint/shadowing/function/param.wgsl.expected.hlsl
Normal file
8
test/tint/shadowing/function/param.wgsl.expected.hlsl
Normal file
@@ -0,0 +1,8 @@
|
||||
[numthreads(1, 1, 1)]
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
|
||||
void a(int a_1) {
|
||||
const int b = a_1;
|
||||
}
|
||||
7
test/tint/shadowing/function/param.wgsl.expected.msl
Normal file
7
test/tint/shadowing/function/param.wgsl.expected.msl
Normal file
@@ -0,0 +1,7 @@
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
void a(int a_1) {
|
||||
int const b = a_1;
|
||||
}
|
||||
|
||||
25
test/tint/shadowing/function/param.wgsl.expected.spvasm
Normal file
25
test/tint/shadowing/function/param.wgsl.expected.spvasm
Normal file
@@ -0,0 +1,25 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 10
|
||||
; 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 %a "a"
|
||||
OpName %a_1 "a_1"
|
||||
%void = OpTypeVoid
|
||||
%1 = OpTypeFunction %void
|
||||
%int = OpTypeInt 32 1
|
||||
%5 = OpTypeFunction %void %int
|
||||
%unused_entry_point = OpFunction %void None %1
|
||||
%4 = OpLabel
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%a = OpFunction %void None %5
|
||||
%a_1 = OpFunctionParameter %int
|
||||
%9 = OpLabel
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
3
test/tint/shadowing/function/param.wgsl.expected.wgsl
Normal file
3
test/tint/shadowing/function/param.wgsl.expected.wgsl
Normal file
@@ -0,0 +1,3 @@
|
||||
fn a(a : i32) {
|
||||
let b = a;
|
||||
}
|
||||
10
test/tint/shadowing/function/var.wgsl
Normal file
10
test/tint/shadowing/function/var.wgsl
Normal file
@@ -0,0 +1,10 @@
|
||||
struct a { a : i32; };
|
||||
|
||||
fn f() {
|
||||
{
|
||||
var a : a = a();
|
||||
var b = a;
|
||||
}
|
||||
var a : a = a();
|
||||
var b = a;
|
||||
}
|
||||
19
test/tint/shadowing/function/var.wgsl.expected.glsl
Normal file
19
test/tint/shadowing/function/var.wgsl.expected.glsl
Normal file
@@ -0,0 +1,19 @@
|
||||
#version 310 es
|
||||
|
||||
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
struct a {
|
||||
int a;
|
||||
};
|
||||
|
||||
void f() {
|
||||
{
|
||||
a a_1 = a(0);
|
||||
a b = a_1;
|
||||
}
|
||||
a a_2 = a(0);
|
||||
a b = a_2;
|
||||
}
|
||||
|
||||
17
test/tint/shadowing/function/var.wgsl.expected.hlsl
Normal file
17
test/tint/shadowing/function/var.wgsl.expected.hlsl
Normal file
@@ -0,0 +1,17 @@
|
||||
[numthreads(1, 1, 1)]
|
||||
void unused_entry_point() {
|
||||
return;
|
||||
}
|
||||
|
||||
struct a {
|
||||
int a;
|
||||
};
|
||||
|
||||
void f() {
|
||||
{
|
||||
a a_1 = (a)0;
|
||||
a b = a_1;
|
||||
}
|
||||
a a_2 = (a)0;
|
||||
a b = a_2;
|
||||
}
|
||||
16
test/tint/shadowing/function/var.wgsl.expected.msl
Normal file
16
test/tint/shadowing/function/var.wgsl.expected.msl
Normal file
@@ -0,0 +1,16 @@
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
struct a {
|
||||
int a;
|
||||
};
|
||||
|
||||
void f() {
|
||||
{
|
||||
a a_1 = {};
|
||||
a b = a_1;
|
||||
}
|
||||
a a_2 = {};
|
||||
a b = a_2;
|
||||
}
|
||||
|
||||
42
test/tint/shadowing/function/var.wgsl.expected.spvasm
Normal file
42
test/tint/shadowing/function/var.wgsl.expected.spvasm
Normal file
@@ -0,0 +1,42 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 17
|
||||
; 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 %f "f"
|
||||
OpName %a "a"
|
||||
OpMemberName %a 0 "a"
|
||||
OpName %a_1 "a_1"
|
||||
OpName %b "b"
|
||||
OpName %a_2 "a_2"
|
||||
OpName %b_0 "b"
|
||||
OpMemberDecorate %a 0 Offset 0
|
||||
%void = OpTypeVoid
|
||||
%1 = OpTypeFunction %void
|
||||
%int = OpTypeInt 32 1
|
||||
%a = OpTypeStruct %int
|
||||
%9 = OpConstantNull %a
|
||||
%_ptr_Function_a = OpTypePointer Function %a
|
||||
%unused_entry_point = OpFunction %void None %1
|
||||
%4 = OpLabel
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%f = OpFunction %void None %1
|
||||
%6 = OpLabel
|
||||
%a_1 = OpVariable %_ptr_Function_a Function %9
|
||||
%b = OpVariable %_ptr_Function_a Function %9
|
||||
%a_2 = OpVariable %_ptr_Function_a Function %9
|
||||
%b_0 = OpVariable %_ptr_Function_a Function %9
|
||||
OpStore %a_1 %9
|
||||
%12 = OpLoad %a %a_1
|
||||
OpStore %b %12
|
||||
OpStore %a_2 %9
|
||||
%15 = OpLoad %a %a_2
|
||||
OpStore %b_0 %15
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
12
test/tint/shadowing/function/var.wgsl.expected.wgsl
Normal file
12
test/tint/shadowing/function/var.wgsl.expected.wgsl
Normal file
@@ -0,0 +1,12 @@
|
||||
struct a {
|
||||
a : i32;
|
||||
}
|
||||
|
||||
fn f() {
|
||||
{
|
||||
var a : a = a();
|
||||
var b = a;
|
||||
}
|
||||
var a : a = a();
|
||||
var b = a;
|
||||
}
|
||||
Reference in New Issue
Block a user