| 1087 | } |
| 1088 | |
| 1089 | void Parse3BitState(benchmark::State& state, const char* regexp, |
| 1090 | const StringPiece& text) { |
| 1091 | for (auto _ : state) { |
| 1092 | Regexp* re = Regexp::Parse(regexp, Regexp::LikePerl, NULL); |
| 1093 | CHECK(re); |
| 1094 | Prog* prog = re->CompileToProg(0); |
| 1095 | CHECK(prog); |
| 1096 | CHECK(prog->CanBitState()); |
| 1097 | StringPiece sp[4]; // 4 because sp[0] is whole match. |
| 1098 | CHECK(prog->SearchBitState(text, text, Prog::kAnchored, Prog::kFullMatch, sp, 4)); |
| 1099 | delete prog; |
| 1100 | re->Decref(); |
| 1101 | } |
| 1102 | } |
| 1103 | |
| 1104 | void Parse3Backtrack(benchmark::State& state, const char* regexp, |
| 1105 | const StringPiece& text) { |
nothing calls this directly
no test coverage detected