MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / Parse3CachedOnePass

Function Parse3CachedOnePass

extern/re2/re2/testing/regexp_benchmark.cc:1148–1156  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1146}
1147
1148void Parse3CachedOnePass(benchmark::State& state, const char* regexp,
1149 const StringPiece& text) {
1150 Prog* prog = GetCachedProg(regexp);
1151 CHECK(prog->IsOnePass());
1152 StringPiece sp[4]; // 4 because sp[0] is whole match.
1153 for (auto _ : state) {
1154 CHECK(prog->SearchOnePass(text, text, Prog::kAnchored, Prog::kFullMatch, sp, 4));
1155 }
1156}
1157
1158void Parse3CachedBitState(benchmark::State& state, const char* regexp,
1159 const StringPiece& text) {

Callers

nothing calls this directly

Calls 3

GetCachedProgFunction · 0.85
IsOnePassMethod · 0.80
SearchOnePassMethod · 0.80

Tested by

no test coverage detected