mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-10 05:57:51 +00:00
[intrinsics] rm f32 overloads of reflect, faceForward
These were removed from the spec in: https://github.com/gpuweb/gpuweb/pull/1914 Bug: tint:921 Change-Id: I4e584fdee9cf540a192f12d1208595056e081410 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/57300 Auto-Submit: Ben Clayton <bclayton@google.com> Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: James Price <jrprice@google.com> Reviewed-by: James Price <jrprice@google.com>
This commit is contained in:
committed by
Tint LUCI CQ
parent
99a78ad72f
commit
70a3fa1ee9
@@ -1,45 +0,0 @@
|
||||
// Copyright 2021 The Tint Authors.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// File generated by tools/intrinsic-gen
|
||||
// using the template:
|
||||
// test/intrinsics/intrinsics.wgsl.tmpl
|
||||
// and the intrinsic defintion file:
|
||||
// src/intrinsics.def
|
||||
//
|
||||
// Do not modify this file directly
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
// fn faceForward(f32, f32, f32) -> f32
|
||||
fn faceForward_fc994b() {
|
||||
var res: f32 = faceForward(1.0, 1.0, 1.0);
|
||||
}
|
||||
|
||||
[[stage(vertex)]]
|
||||
fn vertex_main() -> [[builtin(position)]] vec4<f32> {
|
||||
faceForward_fc994b();
|
||||
return vec4<f32>();
|
||||
}
|
||||
|
||||
[[stage(fragment)]]
|
||||
fn fragment_main() {
|
||||
faceForward_fc994b();
|
||||
}
|
||||
|
||||
[[stage(compute), workgroup_size(1)]]
|
||||
fn compute_main() {
|
||||
faceForward_fc994b();
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
void faceForward_fc994b() {
|
||||
float res = faceforward(1.0f, 1.0f, 1.0f);
|
||||
}
|
||||
|
||||
struct tint_symbol {
|
||||
float4 value : SV_Position;
|
||||
};
|
||||
|
||||
tint_symbol vertex_main() {
|
||||
faceForward_fc994b();
|
||||
const tint_symbol tint_symbol_1 = {float4(0.0f, 0.0f, 0.0f, 0.0f)};
|
||||
return tint_symbol_1;
|
||||
}
|
||||
|
||||
void fragment_main() {
|
||||
faceForward_fc994b();
|
||||
return;
|
||||
}
|
||||
|
||||
[numthreads(1, 1, 1)]
|
||||
void compute_main() {
|
||||
faceForward_fc994b();
|
||||
return;
|
||||
}
|
||||
@@ -1,50 +0,0 @@
|
||||
SKIP: FAILED
|
||||
|
||||
|
||||
|
||||
Validation Failure:
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
void faceForward_fc994b() {
|
||||
float res = faceforward(1.0f, 1.0f, 1.0f);
|
||||
}
|
||||
|
||||
vertex void vertex_main() {
|
||||
faceForward_fc994b();
|
||||
return;
|
||||
}
|
||||
|
||||
fragment void fragment_main() {
|
||||
faceForward_fc994b();
|
||||
return;
|
||||
}
|
||||
|
||||
kernel void compute_main() {
|
||||
faceForward_fc994b();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
tint_2Q1ua3.metal:5:17: error: call to 'faceforward' is ambiguous
|
||||
float res = faceforward(1.0f, 1.0f, 1.0f);
|
||||
^~~~~~~~~~~
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:311:18: note: candidate function
|
||||
METAL_FUNC half2 faceforward(half2 n, half2 i, half2 nref)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:342:18: note: candidate function
|
||||
METAL_FUNC half3 faceforward(half3 n, half3 i, half3 nref)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:373:18: note: candidate function
|
||||
METAL_FUNC half4 faceforward(half4 n, half4 i, half4 nref)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:416:19: note: candidate function
|
||||
METAL_FUNC float2 faceforward(float2 n, float2 i, float2 nref)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:459:19: note: candidate function
|
||||
METAL_FUNC float3 faceforward(float3 n, float3 i, float3 nref)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:502:19: note: candidate function
|
||||
METAL_FUNC float4 faceforward(float4 n, float4 i, float4 nref)
|
||||
^
|
||||
1 error generated.
|
||||
@@ -1,67 +0,0 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 32
|
||||
; Schema: 0
|
||||
OpCapability Shader
|
||||
%14 = OpExtInstImport "GLSL.std.450"
|
||||
OpMemoryModel Logical GLSL450
|
||||
OpEntryPoint Vertex %vertex_main "vertex_main" %tint_pointsize %tint_symbol_1
|
||||
OpEntryPoint Fragment %fragment_main "fragment_main"
|
||||
OpEntryPoint GLCompute %compute_main "compute_main"
|
||||
OpExecutionMode %fragment_main OriginUpperLeft
|
||||
OpExecutionMode %compute_main LocalSize 1 1 1
|
||||
OpName %tint_pointsize "tint_pointsize"
|
||||
OpName %tint_symbol_1 "tint_symbol_1"
|
||||
OpName %faceForward_fc994b "faceForward_fc994b"
|
||||
OpName %res "res"
|
||||
OpName %tint_symbol_2 "tint_symbol_2"
|
||||
OpName %tint_symbol "tint_symbol"
|
||||
OpName %vertex_main "vertex_main"
|
||||
OpName %fragment_main "fragment_main"
|
||||
OpName %compute_main "compute_main"
|
||||
OpDecorate %tint_pointsize BuiltIn PointSize
|
||||
OpDecorate %tint_symbol_1 BuiltIn Position
|
||||
%float = OpTypeFloat 32
|
||||
%_ptr_Output_float = OpTypePointer Output %float
|
||||
%4 = OpConstantNull %float
|
||||
%tint_pointsize = OpVariable %_ptr_Output_float Output %4
|
||||
%v4float = OpTypeVector %float 4
|
||||
%_ptr_Output_v4float = OpTypePointer Output %v4float
|
||||
%8 = OpConstantNull %v4float
|
||||
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %8
|
||||
%void = OpTypeVoid
|
||||
%9 = OpTypeFunction %void
|
||||
%float_1 = OpConstant %float 1
|
||||
%_ptr_Function_float = OpTypePointer Function %float
|
||||
%18 = OpTypeFunction %void %v4float
|
||||
%faceForward_fc994b = OpFunction %void None %9
|
||||
%12 = OpLabel
|
||||
%res = OpVariable %_ptr_Function_float Function %4
|
||||
%13 = OpExtInst %float %14 FaceForward %float_1 %float_1 %float_1
|
||||
OpStore %res %13
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%tint_symbol_2 = OpFunction %void None %18
|
||||
%tint_symbol = OpFunctionParameter %v4float
|
||||
%21 = OpLabel
|
||||
OpStore %tint_symbol_1 %tint_symbol
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%vertex_main = OpFunction %void None %9
|
||||
%23 = OpLabel
|
||||
OpStore %tint_pointsize %float_1
|
||||
%24 = OpFunctionCall %void %faceForward_fc994b
|
||||
%25 = OpFunctionCall %void %tint_symbol_2 %8
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%fragment_main = OpFunction %void None %9
|
||||
%27 = OpLabel
|
||||
%28 = OpFunctionCall %void %faceForward_fc994b
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%compute_main = OpFunction %void None %9
|
||||
%30 = OpLabel
|
||||
%31 = OpFunctionCall %void %faceForward_fc994b
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -1,19 +0,0 @@
|
||||
fn faceForward_fc994b() {
|
||||
var res : f32 = faceForward(1.0, 1.0, 1.0);
|
||||
}
|
||||
|
||||
[[stage(vertex)]]
|
||||
fn vertex_main() -> [[builtin(position)]] vec4<f32> {
|
||||
faceForward_fc994b();
|
||||
return vec4<f32>();
|
||||
}
|
||||
|
||||
[[stage(fragment)]]
|
||||
fn fragment_main() {
|
||||
faceForward_fc994b();
|
||||
}
|
||||
|
||||
[[stage(compute), workgroup_size(1)]]
|
||||
fn compute_main() {
|
||||
faceForward_fc994b();
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
// Copyright 2021 The Tint Authors.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// File generated by tools/intrinsic-gen
|
||||
// using the template:
|
||||
// test/intrinsics/intrinsics.wgsl.tmpl
|
||||
// and the intrinsic defintion file:
|
||||
// src/intrinsics.def
|
||||
//
|
||||
// Do not modify this file directly
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
// fn reflect(f32, f32) -> f32
|
||||
fn reflect_feae90() {
|
||||
var res: f32 = reflect(1.0, 1.0);
|
||||
}
|
||||
|
||||
[[stage(vertex)]]
|
||||
fn vertex_main() -> [[builtin(position)]] vec4<f32> {
|
||||
reflect_feae90();
|
||||
return vec4<f32>();
|
||||
}
|
||||
|
||||
[[stage(fragment)]]
|
||||
fn fragment_main() {
|
||||
reflect_feae90();
|
||||
}
|
||||
|
||||
[[stage(compute), workgroup_size(1)]]
|
||||
fn compute_main() {
|
||||
reflect_feae90();
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
void reflect_feae90() {
|
||||
float res = reflect(1.0f, 1.0f);
|
||||
}
|
||||
|
||||
struct tint_symbol {
|
||||
float4 value : SV_Position;
|
||||
};
|
||||
|
||||
tint_symbol vertex_main() {
|
||||
reflect_feae90();
|
||||
const tint_symbol tint_symbol_1 = {float4(0.0f, 0.0f, 0.0f, 0.0f)};
|
||||
return tint_symbol_1;
|
||||
}
|
||||
|
||||
void fragment_main() {
|
||||
reflect_feae90();
|
||||
return;
|
||||
}
|
||||
|
||||
[numthreads(1, 1, 1)]
|
||||
void compute_main() {
|
||||
reflect_feae90();
|
||||
return;
|
||||
}
|
||||
@@ -1,50 +0,0 @@
|
||||
SKIP: FAILED
|
||||
|
||||
|
||||
|
||||
Validation Failure:
|
||||
#include <metal_stdlib>
|
||||
|
||||
using namespace metal;
|
||||
void reflect_feae90() {
|
||||
float res = reflect(1.0f, 1.0f);
|
||||
}
|
||||
|
||||
vertex void vertex_main() {
|
||||
reflect_feae90();
|
||||
return;
|
||||
}
|
||||
|
||||
fragment void fragment_main() {
|
||||
reflect_feae90();
|
||||
return;
|
||||
}
|
||||
|
||||
kernel void compute_main() {
|
||||
reflect_feae90();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
tint_ib1Pi6.metal:5:17: error: call to 'reflect' is ambiguous
|
||||
float res = reflect(1.0f, 1.0f);
|
||||
^~~~~~~
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:315:18: note: candidate function
|
||||
METAL_FUNC half2 reflect(half2 i, half2 n)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:346:18: note: candidate function
|
||||
METAL_FUNC half3 reflect(half3 i, half3 n)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:377:18: note: candidate function
|
||||
METAL_FUNC half4 reflect(half4 i, half4 n)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:420:19: note: candidate function
|
||||
METAL_FUNC float2 reflect(float2 i, float2 n)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:463:19: note: candidate function
|
||||
METAL_FUNC float3 reflect(float3 i, float3 n)
|
||||
^
|
||||
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/lib/clang/902.14/include/metal/metal_geometric:506:19: note: candidate function
|
||||
METAL_FUNC float4 reflect(float4 i, float4 n)
|
||||
^
|
||||
1 error generated.
|
||||
@@ -1,67 +0,0 @@
|
||||
; SPIR-V
|
||||
; Version: 1.3
|
||||
; Generator: Google Tint Compiler; 0
|
||||
; Bound: 32
|
||||
; Schema: 0
|
||||
OpCapability Shader
|
||||
%14 = OpExtInstImport "GLSL.std.450"
|
||||
OpMemoryModel Logical GLSL450
|
||||
OpEntryPoint Vertex %vertex_main "vertex_main" %tint_pointsize %tint_symbol_1
|
||||
OpEntryPoint Fragment %fragment_main "fragment_main"
|
||||
OpEntryPoint GLCompute %compute_main "compute_main"
|
||||
OpExecutionMode %fragment_main OriginUpperLeft
|
||||
OpExecutionMode %compute_main LocalSize 1 1 1
|
||||
OpName %tint_pointsize "tint_pointsize"
|
||||
OpName %tint_symbol_1 "tint_symbol_1"
|
||||
OpName %reflect_feae90 "reflect_feae90"
|
||||
OpName %res "res"
|
||||
OpName %tint_symbol_2 "tint_symbol_2"
|
||||
OpName %tint_symbol "tint_symbol"
|
||||
OpName %vertex_main "vertex_main"
|
||||
OpName %fragment_main "fragment_main"
|
||||
OpName %compute_main "compute_main"
|
||||
OpDecorate %tint_pointsize BuiltIn PointSize
|
||||
OpDecorate %tint_symbol_1 BuiltIn Position
|
||||
%float = OpTypeFloat 32
|
||||
%_ptr_Output_float = OpTypePointer Output %float
|
||||
%4 = OpConstantNull %float
|
||||
%tint_pointsize = OpVariable %_ptr_Output_float Output %4
|
||||
%v4float = OpTypeVector %float 4
|
||||
%_ptr_Output_v4float = OpTypePointer Output %v4float
|
||||
%8 = OpConstantNull %v4float
|
||||
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %8
|
||||
%void = OpTypeVoid
|
||||
%9 = OpTypeFunction %void
|
||||
%float_1 = OpConstant %float 1
|
||||
%_ptr_Function_float = OpTypePointer Function %float
|
||||
%18 = OpTypeFunction %void %v4float
|
||||
%reflect_feae90 = OpFunction %void None %9
|
||||
%12 = OpLabel
|
||||
%res = OpVariable %_ptr_Function_float Function %4
|
||||
%13 = OpExtInst %float %14 Reflect %float_1 %float_1
|
||||
OpStore %res %13
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%tint_symbol_2 = OpFunction %void None %18
|
||||
%tint_symbol = OpFunctionParameter %v4float
|
||||
%21 = OpLabel
|
||||
OpStore %tint_symbol_1 %tint_symbol
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%vertex_main = OpFunction %void None %9
|
||||
%23 = OpLabel
|
||||
OpStore %tint_pointsize %float_1
|
||||
%24 = OpFunctionCall %void %reflect_feae90
|
||||
%25 = OpFunctionCall %void %tint_symbol_2 %8
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%fragment_main = OpFunction %void None %9
|
||||
%27 = OpLabel
|
||||
%28 = OpFunctionCall %void %reflect_feae90
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
%compute_main = OpFunction %void None %9
|
||||
%30 = OpLabel
|
||||
%31 = OpFunctionCall %void %reflect_feae90
|
||||
OpReturn
|
||||
OpFunctionEnd
|
||||
@@ -1,19 +0,0 @@
|
||||
fn reflect_feae90() {
|
||||
var res : f32 = reflect(1.0, 1.0);
|
||||
}
|
||||
|
||||
[[stage(vertex)]]
|
||||
fn vertex_main() -> [[builtin(position)]] vec4<f32> {
|
||||
reflect_feae90();
|
||||
return vec4<f32>();
|
||||
}
|
||||
|
||||
[[stage(fragment)]]
|
||||
fn fragment_main() {
|
||||
reflect_feae90();
|
||||
}
|
||||
|
||||
[[stage(compute), workgroup_size(1)]]
|
||||
fn compute_main() {
|
||||
reflect_feae90();
|
||||
}
|
||||
Reference in New Issue
Block a user