v8
3.25.30(node0.11.13)
V8 is Google's open source JavaScript engine
|
#include <jsregexp.h>
Public Member Functions | |
RegExpNode (Zone *zone) | |
virtual | ~RegExpNode () |
virtual void | Accept (NodeVisitor *visitor)=0 |
virtual void | Emit (RegExpCompiler *compiler, Trace *trace)=0 |
virtual int | EatsAtLeast (int still_to_find, int budget, bool not_at_start)=0 |
bool | EmitQuickCheck (RegExpCompiler *compiler, Trace *trace, bool preload_has_checked_bounds, Label *on_possible_success, QuickCheckDetails *details_return, bool fall_through_on_failure) |
virtual void | GetQuickCheckDetails (QuickCheckDetails *details, RegExpCompiler *compiler, int characters_filled_in, bool not_at_start)=0 |
virtual int | GreedyLoopTextLength () |
virtual RegExpNode * | GetSuccessorOfOmnivorousTextNode (RegExpCompiler *compiler) |
virtual void | FillInBMInfo (int offset, int budget, BoyerMooreLookahead *bm, bool not_at_start) |
virtual RegExpNode * | FilterASCII (int depth, bool ignore_case) |
RegExpNode * | replacement () |
RegExpNode * | set_replacement (RegExpNode *replacement) |
void | SaveBMInfo (BoyerMooreLookahead *bm, bool not_at_start, int offset) |
Label * | label () |
NodeInfo * | info () |
BoyerMooreLookahead * | bm_info (bool not_at_start) |
Zone * | zone () const |
Public Member Functions inherited from ZoneObject | |
INLINE (void *operator new(size_t size, Zone *zone)) | |
void | operator delete (void *, size_t) |
void | operator delete (void *pointer, Zone *zone) |
Static Public Attributes | |
static const int | kNodeIsTooComplexForGreedyLoops = -1 |
static const int | kRecursionBudget = 200 |
static const int | kMaxCopiesCodeGenerated = 10 |
Protected Types | |
enum | LimitResult { DONE, CONTINUE } |
Protected Member Functions | |
LimitResult | LimitVersions (RegExpCompiler *compiler, Trace *trace) |
void | set_bm_info (bool not_at_start, BoyerMooreLookahead *bm) |
Protected Attributes | |
RegExpNode * | replacement_ |
Definition at line 588 of file jsregexp.h.
|
protected |
Enumerator | |
---|---|
DONE | |
CONTINUE |
Definition at line 685 of file jsregexp.h.
|
inlineexplicit |
Definition at line 590 of file jsregexp.h.
References v8::internal::NULL.
|
virtual |
Definition at line 2257 of file jsregexp.cc.
|
pure virtual |
Implemented in LoopChoiceNode, ChoiceNode, EndNode, BackReferenceNode, AssertionNode, TextNode, and ActionNode.
Referenced by Analysis::EnsureAnalyzed().
|
inline |
Definition at line 678 of file jsregexp.h.
Referenced by ChoiceNode::Emit().
|
pure virtual |
Implemented in LoopChoiceNode, NegativeLookaheadChoiceNode, ChoiceNode, EndNode, BackReferenceNode, AssertionNode, TextNode, and ActionNode.
Referenced by NegativeLookaheadChoiceNode::EatsAtLeast(), and ChoiceNode::EatsAtLeastHelper().
|
pure virtual |
Implemented in LoopChoiceNode, ChoiceNode, NegativeSubmatchSuccess, EndNode, BackReferenceNode, AssertionNode, TextNode, and ActionNode.
Referenced by RegExpCompiler::Assemble(), ActionNode::Emit(), BackReferenceNode::Emit(), ChoiceNode::Emit(), and Trace::Flush().
bool EmitQuickCheck | ( | RegExpCompiler * | compiler, |
Trace * | trace, | ||
bool | preload_has_checked_bounds, | ||
Label * | on_possible_success, | ||
QuickCheckDetails * | details_return, | ||
bool | fall_through_on_failure | ||
) |
Definition at line 2477 of file jsregexp.cc.
References RegExpCompiler::ascii(), ASSERT, Trace::at_start(), Trace::backtrack(), QuickCheckDetails::cannot_match(), RegExpMacroAssembler::CanReadUnaligned(), QuickCheckDetails::characters(), Trace::characters_preloaded(), RegExpMacroAssembler::CheckCharacter(), RegExpMacroAssembler::CheckCharacterAfterAnd(), RegExpMacroAssembler::CheckNotCharacter(), RegExpMacroAssembler::CheckNotCharacterAfterAnd(), Trace::cp_offset(), Trace::FALSE_VALUE, String::kMaxOneByteCharCode, String::kMaxUtf16CodeUnit, RegExpMacroAssembler::LoadCurrentCharacter(), RegExpCompiler::macro_assembler(), QuickCheckDetails::mask(), QuickCheckDetails::Rationalize(), and QuickCheckDetails::value().
Referenced by ChoiceNode::Emit().
|
inlinevirtual |
Reimplemented in LoopChoiceNode, NegativeLookaheadChoiceNode, ChoiceNode, EndNode, BackReferenceNode, AssertionNode, TextNode, ActionNode, and SeqRegExpNode.
Definition at line 638 of file jsregexp.h.
References UNREACHABLE.
Referenced by ChoiceNode::Emit(), SeqRegExpNode::FillInBMInfo(), TextNode::FillInBMInfo(), and ChoiceNode::FillInBMInfo().
|
inlinevirtual |
Reimplemented in LoopChoiceNode, NegativeLookaheadChoiceNode, ChoiceNode, TextNode, and SeqRegExpNode.
Definition at line 648 of file jsregexp.h.
Referenced by RegExpEngine::Compile(), ChoiceNode::FilterASCII(), NegativeLookaheadChoiceNode::FilterASCII(), LoopChoiceNode::FilterASCII(), and SeqRegExpNode::FilterSuccessor().
|
pure virtual |
Implemented in LoopChoiceNode, NegativeLookaheadChoiceNode, ChoiceNode, EndNode, BackReferenceNode, AssertionNode, TextNode, and ActionNode.
Referenced by ActionNode::GetQuickCheckDetails(), ChoiceNode::GetQuickCheckDetails(), and NegativeLookaheadChoiceNode::GetQuickCheckDetails().
|
inlinevirtual |
Reimplemented in TextNode.
Definition at line 627 of file jsregexp.h.
References v8::internal::NULL.
Referenced by ChoiceNode::Emit().
|
inlinevirtual |
Reimplemented in TextNode, and ActionNode.
Definition at line 624 of file jsregexp.h.
References RegExpNode::kNodeIsTooComplexForGreedyLoops.
Referenced by ChoiceNode::GreedyLoopTextLengthForAlternative().
|
inline |
Definition at line 676 of file jsregexp.h.
Referenced by Analysis::EnsureAnalyzed(), RegExpNode::replacement(), RegExpNode::set_replacement(), and Analysis::VisitLoopChoice().
|
inline |
Definition at line 668 of file jsregexp.h.
|
protected |
Definition at line 2261 of file jsregexp.cc.
References RegExpCompiler::AddWork(), RegExpMacroAssembler::Bind(), DONE, Trace::Flush(), RegExpMacroAssembler::GoTo(), Trace::is_trivial(), RegExpCompiler::kMaxRecursion, RegExpCompiler::macro_assembler(), v8::internal::NULL, RegExpCompiler::recursion_depth(), and Trace::stop_node().
Referenced by ActionNode::Emit(), BackReferenceNode::Emit(), and ChoiceNode::Emit().
|
inline |
Definition at line 650 of file jsregexp.h.
References ASSERT, RegExpNode::info(), and RegExpNode::replacement_.
Referenced by RegExpNode::set_replacement().
|
inline |
Definition at line 664 of file jsregexp.h.
References RegExpNode::set_bm_info().
Referenced by BackReferenceNode::FillInBMInfo(), and ChoiceNode::FillInBMInfo().
|
inlineprotected |
Definition at line 690 of file jsregexp.h.
Referenced by SeqRegExpNode::FillInBMInfo(), TextNode::FillInBMInfo(), NegativeLookaheadChoiceNode::FillInBMInfo(), and RegExpNode::SaveBMInfo().
|
inline |
Definition at line 654 of file jsregexp.h.
References RegExpNode::info(), RegExpNode::replacement(), RegExpNode::replacement_, and NodeInfo::replacement_calculated.
|
inline |
Definition at line 682 of file jsregexp.h.
Referenced by ChoiceNode::AddAlternative(), AssertionNode::AfterNewline(), AssertionNode::AtBoundary(), AssertionNode::AtEnd(), AssertionNode::AtNonBoundary(), AssertionNode::AtStart(), ActionNode::BeginSubmatch(), ActionNode::ClearCaptures(), ChoiceNode::Emit(), ActionNode::EmptyMatchCheck(), Analysis::EnsureAnalyzed(), TextNode::FillInBMInfo(), ActionNode::IncrementRegister(), ActionNode::PositiveSubmatchSuccess(), ActionNode::SetRegister(), ActionNode::StorePosition(), and TextNode::TextNode().
|
static |
Definition at line 674 of file jsregexp.h.
|
static |
Definition at line 623 of file jsregexp.h.
Referenced by ChoiceNode::Emit(), RegExpNode::GreedyLoopTextLength(), and ActionNode::GreedyLoopTextLength().
|
static |
Definition at line 637 of file jsregexp.h.
Referenced by ChoiceNode::Emit().
|
protected |
Definition at line 686 of file jsregexp.h.
Referenced by RegExpNode::replacement(), and RegExpNode::set_replacement().