mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-07-09 06:35:54 +00:00
Add google benchmark to the DEPs. Implement a basic set of benchmarks for each of the writers and the WGSL parser. Add build rules for CMake. GN build rules TODO. Add a simple go tool (ported from Marl) to diff two benchmarks. Less noisy than the one provided by google benchmark. Bug: tint:1378 Change-Id: I73cf92c5d9fd2d3bfac8f264864fd774afbd5d01 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/76840 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: Ben Clayton <bclayton@chromium.org>
26 lines
580 B
HLSL
26 lines
580 B
HLSL
struct Input {
|
|
float4 color;
|
|
};
|
|
struct Output {
|
|
float4 color;
|
|
};
|
|
struct tint_symbol_2 {
|
|
float4 color : TEXCOORD0;
|
|
};
|
|
struct tint_symbol_3 {
|
|
float4 color : SV_Target0;
|
|
};
|
|
|
|
Output main_inner(Input tint_symbol) {
|
|
const Output tint_symbol_4 = {tint_symbol.color};
|
|
return tint_symbol_4;
|
|
}
|
|
|
|
tint_symbol_3 main(tint_symbol_2 tint_symbol_1) {
|
|
const Input tint_symbol_5 = {tint_symbol_1.color};
|
|
const Output inner_result = main_inner(tint_symbol_5);
|
|
tint_symbol_3 wrapper_result = (tint_symbol_3)0;
|
|
wrapper_result.color = inner_result.color;
|
|
return wrapper_result;
|
|
}
|