v8
3.14.5(node0.10.28)
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 recursion_depth, 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 recursion_depth, int budget, BoyerMooreLookahead *bm, bool not_at_start) |
virtual RegExpNode * | FilterASCII (int depth) |
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 | kFillInBMBudget = 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 568 of file jsregexp.h.
|
protected |
Enumerator | |
---|---|
DONE | |
CONTINUE |
Definition at line 668 of file jsregexp.h.
|
inlineexplicit |
Definition at line 570 of file jsregexp.h.
References v8::internal::NULL.
|
virtual |
Definition at line 2313 of file jsregexp.cc.
|
pure virtual |
Implemented in LoopChoiceNode, ChoiceNode, EndNode, BackReferenceNode, AssertionNode, TextNode, and ActionNode.
Referenced by Analysis::EnsureAnalyzed().
|
inline |
Definition at line 661 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 2536 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, String::kMaxAsciiCharCode, 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 620 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 631 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 609 of file jsregexp.h.
References v8::internal::NULL.
Referenced by ChoiceNode::Emit().
|
inlinevirtual |
Reimplemented in TextNode, and ActionNode.
Definition at line 606 of file jsregexp.h.
References RegExpNode::kNodeIsTooComplexForGreedyLoops.
Referenced by ChoiceNode::GreedyLoopTextLengthForAlternative().
|
inline |
Definition at line 659 of file jsregexp.h.
Referenced by Analysis::EnsureAnalyzed(), RegExpNode::replacement(), RegExpNode::set_replacement(), and Analysis::VisitLoopChoice().
|
inline |
Definition at line 651 of file jsregexp.h.
|
protected |
Definition at line 2317 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 633 of file jsregexp.h.
References ASSERT, RegExpNode::info(), and RegExpNode::replacement_.
Referenced by RegExpNode::set_replacement().
|
inline |
Definition at line 647 of file jsregexp.h.
References RegExpNode::set_bm_info().
Referenced by BackReferenceNode::FillInBMInfo(), and ChoiceNode::FillInBMInfo().
|
inlineprotected |
Definition at line 673 of file jsregexp.h.
Referenced by SeqRegExpNode::FillInBMInfo(), TextNode::FillInBMInfo(), NegativeLookaheadChoiceNode::FillInBMInfo(), and RegExpNode::SaveBMInfo().
|
inline |
Definition at line 637 of file jsregexp.h.
References RegExpNode::info(), RegExpNode::replacement(), RegExpNode::replacement_, and NodeInfo::replacement_calculated.
|
inline |
Definition at line 665 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(), TextNode::FillInBMInfo(), ActionNode::IncrementRegister(), ActionNode::PositiveSubmatchSuccess(), ActionNode::SetRegister(), ActionNode::StorePosition(), and TextNode::TextNode().
|
static |
Definition at line 619 of file jsregexp.h.
Referenced by ChoiceNode::Emit().
|
static |
Definition at line 657 of file jsregexp.h.
|
static |
Definition at line 605 of file jsregexp.h.
Referenced by ChoiceNode::Emit(), RegExpNode::GreedyLoopTextLength(), and ActionNode::GreedyLoopTextLength().
|
protected |
Definition at line 669 of file jsregexp.h.
Referenced by RegExpNode::replacement(), and RegExpNode::set_replacement().