blob: 5d12ab3200b4b8655bcde599e622af339937e0e5 [file] [log] [blame]
// Copyright 2023 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/src/cmd/gen
// using the template:
// src/tint/builtin/attribute_bench.cc.tmpl
//
// Do not modify this file directly
////////////////////////////////////////////////////////////////////////////////
#include "src/tint/builtin/attribute.h"
#include <array>
#include "benchmark/benchmark.h"
namespace tint::builtin {
namespace {
void AttributeParser(::benchmark::State& state) {
const char* kStrings[] = {
"alccn",
"3g",
"aVign",
"align",
"alig1",
"qqlJn",
"alill7n",
"ppqqndnHH",
"bicv",
"bndiGg",
"binding",
"bindiivg",
"8WWnding",
"bxxding",
"bXltigg",
"ultXn",
"buil3in",
"builtin",
"Euiltin",
"bPTTltin",
"builtdxx",
"c44mpute",
"coSSpuVVe",
"RomR22e",
"compute",
"cFpu9e",
"comute",
"VOORRHte",
"dyagnstic",
"d77agnnnsllrrc",
"dia400ostic",
"diagnostic",
"danstooc",
"dignszzic",
"d11ansppiic",
"XXragment",
"fIIa9955nnnt",
"aarHHgmenYSS",
"fragment",
"fkkaet",
"gjamRRn",
"fabmnt",
"gjoup",
"goup",
"goq",
"group",
"Nroup",
"govv",
"gruQQ",
"r",
"jd",
"NNw",
"id",
"i",
"rrd",
"iG",
"FFnterpolate",
"iEtrplat",
"inerporrate",
"interpolate",
"inteplate",
"XterJJoDate",
"inepol8t",
"nvark1n",
"invriant",
"Jnvarant",
"invariant",
"invaricnt",
"invariaOt",
"invttKK_ianvv",
"lxxcati8",
"Focqq__o",
"locaiqqn",
"location",
"loc33tio6",
"ltto6at9QQn",
"loc66tio",
"mOxt_u6zz",
"musyy_use",
"mHH_use",
"must_use",
"qWW4st_se",
"musOO_se",
"ust_uYe",
"i",
"Fie",
"siw",
"size",
"zff",
"sizqK",
"s3zmm",
"ertex",
"vereq",
"vbtbbx",
"vertex",
"irtex",
"vOOteq",
"vertTvvx",
"woFFkgroup_size",
"wfr00grPupsiQe",
"workgrouP_size",
"workgroup_size",
"workgroup77sise",
"RRobbkgroupCsize",
"wXXrkgroup_size",
};
for (auto _ : state) {
for (auto* str : kStrings) {
auto result = ParseAttribute(str);
benchmark::DoNotOptimize(result);
}
}
}
BENCHMARK(AttributeParser);
} // namespace
} // namespace tint::builtin