Home
last modified time | relevance | path

Searched refs:prog_ (Results 1 – 13 of 13) sorted by relevance

/external/regex-re2/re2/testing/
Dbacktrack.cc63 Prog* prog_; // program being run member in re2::Backtracker
79 : prog_(prog), in Backtracker()
101 if (prog_->anchor_start() && text.begin() > context_.begin()) in Search()
103 if (prog_->anchor_end() && text.end() < context_.end()) in Search()
105 anchored_ = anchored | prog_->anchor_start(); in Search()
106 longest_ = longest | prog_->anchor_end(); in Search()
107 endmatch_ = prog_->anchor_end(); in Search()
125 nvisited_ = (prog_->size()*(text.size()+1) + 31)/32; in Search()
132 return Visit(prog_->start(), text.begin()); in Search()
140 if (Visit(prog_->start(), p)) // Match must be leftmost; done. in Search()
[all …]
Dtester.cc169 prog_(NULL), in TestInstance()
187 prog_ = regexp_->CompileToProg(0); in TestInstance()
188 if (prog_ == NULL) { in TestInstance()
200 << prog_->Dump(); in TestInstance()
270 delete prog_; in ~TestInstance()
301 if (prog_ == NULL) { in RunSearch()
306 prog_->UnsafeSearchBacktrack(text, context, anchor, kind_, in RunSearch()
312 if (prog_ == NULL) { in RunSearch()
317 prog_->SearchNFA(text, context, anchor, kind_, in RunSearch()
323 if (prog_ == NULL) { in RunSearch()
[all …]
Ddfa_test.cc26 BuildThread(Prog* prog) : prog_(prog) {} in BuildThread()
28 CHECK(prog_->BuildEntireDFA(Prog::kFirstMatch)); in Run()
32 Prog* prog_; member in re2::BuildThread
239 : prog_(prog), match_(match), no_match_(no_match) {} in SearchThread()
244 matched = prog_->SearchDFA(match_, NULL, in Run()
249 matched = prog_->SearchDFA(no_match_, NULL, in Run()
258 Prog* prog_; member in re2::SearchThread
Dtester.h82 Prog* prog_; // compiled program variable
/external/regex-re2/re2/
Dbitstate.cc49 Prog* prog_; // program being run member in re2::BitState
72 : prog_(prog), in BitState()
125 int op = prog_->inst(id)->opcode(); in Push()
170 Prog::Inst* ip = prog_->inst(id); in TrySearch()
202 if (ip->greedy(prog_)) { in TrySearch()
301 if (prog_->anchor_start() && context_.begin() != text.begin()) in Search()
303 if (prog_->anchor_end() && context_.end() != text.end()) in Search()
305 anchored_ = anchored || prog_->anchor_start(); in Search()
306 longest_ = longest || prog_->anchor_end(); in Search()
307 endmatch_ = prog_->anchor_end(); in Search()
[all …]
Dcompile.cc218 Prog* prog_; // Program being built. member in re2::Compiler
240 prog_ = new Prog(); in Compiler()
255 delete prog_; in ~Compiler()
397 prog_->byte_inst_count_++; in ByteRange()
398 prog_->MarkByteRange(lo, hi); in ByteRange()
405 prog_->MarkByteRange(lo + 'A' - 'a', hi + 'A' - 'a'); in ByteRange()
435 prog_->MarkByteRange('\n', '\n'); in EmptyWidth()
441 prog_->MarkByteRange(i, j-1); in EmptyWidth()
953 prog_->set_flags(flags); in Setup()
1019 c.prog_->set_start(all.begin); in Compile()
[all …]
Dnfa.cc109 Prog* prog_; // underlying program member in re2::NFA
129 prog_ = prog; in NFA()
136 q0_.resize(prog_->size()); in NFA()
137 q1_.resize(prog_->size()); in NFA()
138 nastack_ = 2*prog_->size(); in NFA()
223 Prog::Inst* ip = prog_->inst(id); in AddToThreadq()
309 Prog::Inst* ip = prog_->inst(id); in Step()
326 if (ip->greedy(prog_) || longest_) { in Step()
333 if (ip->greedy(prog_)) in Step()
419 if (prog_->anchor_start() && context.begin() != text.begin()) in Search()
[all …]
Dset.cc18 prog_ = NULL; in Set()
25 delete prog_; in ~Set()
90 prog_ = Prog::CompileSet(options_, anchor_, re); in Compile()
91 return prog_ != NULL; in Compile()
101 bool ret = prog_->SearchDFA(text, text, Prog::kAnchored, in Match()
Ddfa.cc336 return prog_->bytemap_range(); in ByteMap()
337 return prog_->bytemap()[c]; in ByteMap()
341 Prog* prog_; // The regular expression program to run. member in re2::DFA
435 : prog_(prog), in DFA()
444 fprintf(stderr, "\nkind %d\n%s\n", (int)kind_, prog_->DumpUnanchored().c_str()); in DFA()
455 mem_budget_ -= (prog_->size() + nmark) * in DFA()
460 prog_->size(), max_mem); in DFA()
471 int64 one_state = sizeof(State) + (prog_->size()+nmark)*sizeof(int) + in DFA()
472 (prog_->bytemap_range()+1)*sizeof(State*); in DFA()
475 prog_->size(), max_mem); in DFA()
[all …]
Dre2.cc181 prog_ = NULL; in Init()
215 prog_ = suffix_regexp_->CompileToProg(options_.max_mem()*2/3); in Init()
216 if (prog_ == NULL) { in Init()
229 is_one_pass_ = prog_->IsOnePass(); in Init()
254 delete prog_; in ~RE2()
265 if (prog_ == NULL) in ProgramSize()
267 return prog_->size(); in ProgramSize()
464 if (prog_ == NULL) in PossibleMatchRange()
486 if (maxlen > 0 && prog_->PossibleMatchRange(&dmin, &dmax, maxlen)) { in PossibleMatchRange()
561 if (prog_->anchor_start() && startpos != 0) in Match()
[all …]
Dset.h46 re2::Prog* prog_; variable
Dre2.h711 re2::Prog* prog_; // compiled program for regexp variable
/external/regex-re2/
Ducs2.diff25 if (TrySearch(prog_->start(), p)) // Match must be leftmost; done.
27 - if (prog_->flags() & Regexp::UCS2)
173 c.prog_->set_start_unanchored(c.prog_->start());
184 c.prog_->set_start_unanchored(unanchored.begin);
190 - bool ucs2 = prog_->flags() & Regexp::UCS2;
350 if (Visit(prog_->start(), p)) // Match must be leftmost; done.
352 - if (prog_->flags() & Regexp::UCS2)
384 prog_ = regexp_->CompileToProg(0);