Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Classes | Namespaces | Macros | Typedefs | Functions | Variables
regexp.cc File Reference
#include "vm/regexp.h"
#include <memory>
#include "platform/splay-tree-inl.h"
#include "platform/unicode.h"
#include "unicode/uniset.h"
#include "vm/dart_entry.h"
#include "vm/regexp_assembler.h"
#include "vm/regexp_assembler_bytecode.h"
#include "vm/regexp_ast.h"
#include "vm/symbols.h"
#include "vm/thread.h"
#include "vm/unibrow-inl.h"
#include "vm/regexp_assembler_ir.h"

Go to the source code of this file.

Classes

class  dart::FrequencyCollator
 
class  dart::RegExpCompiler
 
class  dart::RecursionCheck
 
class  dart::VisitMarker
 
struct  dart::AlternativeGeneration
 
class  dart::AlternativeGenerationList
 
class  dart::RegExpExpansionLimiter
 

Namespaces

namespace  dart
 

Macros

#define Z   (zone())
 
#define DEFINE_ACCEPT(Type)
 
#define OZ   (on_success->zone())
 

Typedefs

typedef bool dart::EmitCharacterFunction(Zone *zone, RegExpCompiler *compiler, uint16_t c, BlockLabel *on_failure, intptr_t cp_offset, bool check, bool preloaded)
 

Functions

ContainedInLattice dart::AddRange (ContainedInLattice containment, const int32_t *ranges, intptr_t ranges_length, Interval new_range)
 
static RegExpEngine::CompilationResult dart::IrregexpRegExpTooBig ()
 
static intptr_t dart::GetCaseIndependentLetters (uint16_t character, bool one_byte_subject, int32_t *letters)
 
static bool dart::EmitSimpleCharacter (Zone *zone, RegExpCompiler *compiler, uint16_t c, BlockLabel *on_failure, intptr_t cp_offset, bool check, bool preloaded)
 
static bool dart::EmitAtomNonLetter (Zone *zone, RegExpCompiler *compiler, uint16_t c, BlockLabel *on_failure, intptr_t cp_offset, bool check, bool preloaded)
 
static bool dart::ShortCutEmitCharacterPair (RegExpMacroAssembler *macro_assembler, bool one_byte, uint16_t c1, uint16_t c2, BlockLabel *on_failure)
 
static bool dart::EmitAtomLetter (Zone *zone, RegExpCompiler *compiler, uint16_t c, BlockLabel *on_failure, intptr_t cp_offset, bool check, bool preloaded)
 
static void dart::EmitBoundaryTest (RegExpMacroAssembler *masm, uint16_t border, BlockLabel *fall_through, BlockLabel *above_or_equal, BlockLabel *below)
 
static void dart::EmitDoubleBoundaryTest (RegExpMacroAssembler *masm, uint16_t first, uint16_t last, BlockLabel *fall_through, BlockLabel *in_range, BlockLabel *out_of_range)
 
static void dart::EmitUseLookupTable (RegExpMacroAssembler *masm, ZoneGrowableArray< uint16_t > *ranges, intptr_t start_index, intptr_t end_index, uint16_t min_char, BlockLabel *fall_through, BlockLabel *even_label, BlockLabel *odd_label)
 
static void dart::CutOutRange (RegExpMacroAssembler *masm, ZoneGrowableArray< uint16_t > *ranges, intptr_t start_index, intptr_t end_index, intptr_t cut_index, BlockLabel *even_label, BlockLabel *odd_label)
 
static void dart::SplitSearchSpace (ZoneGrowableArray< uint16_t > *ranges, intptr_t start_index, intptr_t end_index, intptr_t *new_start_index, intptr_t *new_end_index, uint16_t *border)
 
static void dart::GenerateBranches (RegExpMacroAssembler *masm, ZoneGrowableArray< uint16_t > *ranges, intptr_t start_index, intptr_t end_index, uint16_t min_char, uint16_t max_char, BlockLabel *fall_through, BlockLabel *even_label, BlockLabel *odd_label)
 
static void dart::EmitCharClass (RegExpMacroAssembler *macro_assembler, RegExpCharacterClass *cc, bool one_byte, BlockLabel *on_failure, intptr_t cp_offset, bool check_offset, bool preloaded, Zone *zone)
 
static uint32_t dart::SmearBitsRight (uint32_t v)
 
static bool dart::RangeContainsLatin1Equivalents (CharacterRange range)
 
static bool dart::RangesContainLatin1Equivalents (ZoneGrowableArray< CharacterRange > *ranges)
 
static uint16_t dart::ConvertNonLatin1ToLatin1 (uint16_t c)
 
static void dart::EmitWordCheck (RegExpMacroAssembler *assembler, BlockLabel *word, BlockLabel *non_word, bool fall_through_on_word)
 
static void dart::EmitHat (RegExpCompiler *compiler, RegExpNode *on_success, Trace *trace)
 
static bool dart::DeterminedAlready (QuickCheckDetails *quick_check, intptr_t offset)
 
static void dart::UpdateBoundsCheck (intptr_t index, intptr_t *checked_up_to)
 
static bool dart::CompareInverseRanges (ZoneGrowableArray< CharacterRange > *ranges, const int32_t *special_class, intptr_t length)
 
static bool dart::CompareRanges (ZoneGrowableArray< CharacterRange > *ranges, const int32_t *special_class, intptr_t length)
 
void dart::AddBmpCharacters (RegExpCompiler *compiler, ChoiceNode *result, RegExpNode *on_success, UnicodeRangeSplitter *splitter)
 
void dart::AddNonBmpSurrogatePairs (RegExpCompiler *compiler, ChoiceNode *result, RegExpNode *on_success, UnicodeRangeSplitter *splitter)
 
RegExpNodedart::NegativeLookaroundAgainstReadDirectionAndMatch (RegExpCompiler *compiler, ZoneGrowableArray< CharacterRange > *lookbehind, ZoneGrowableArray< CharacterRange > *match, RegExpNode *on_success, bool read_backward, RegExpFlags flags)
 
RegExpNodedart::MatchAndNegativeLookaroundInReadDirection (RegExpCompiler *compiler, ZoneGrowableArray< CharacterRange > *match, ZoneGrowableArray< CharacterRange > *lookahead, RegExpNode *on_success, bool read_backward, RegExpFlags flags)
 
void dart::AddLoneLeadSurrogates (RegExpCompiler *compiler, ChoiceNode *result, RegExpNode *on_success, UnicodeRangeSplitter *splitter)
 
void dart::AddLoneTrailSurrogates (RegExpCompiler *compiler, ChoiceNode *result, RegExpNode *on_success, UnicodeRangeSplitter *splitter)
 
RegExpNodedart::UnanchoredAdvance (RegExpCompiler *compiler, RegExpNode *on_success)
 
void dart::AddUnicodeCaseEquivalents (ZoneGrowableArray< CharacterRange > *ranges)
 
static void dart::AddClass (const int32_t *elmv, intptr_t elmc, ZoneGrowableArray< CharacterRange > *ranges)
 
static void dart::AddClassNegated (const int32_t *elmv, intptr_t elmc, ZoneGrowableArray< CharacterRange > *ranges)
 
static void dart::MoveRanges (ZoneGrowableArray< CharacterRange > *list, intptr_t from, intptr_t to, intptr_t count)
 
static intptr_t dart::InsertRangeInCanonicalList (ZoneGrowableArray< CharacterRange > *list, intptr_t count, CharacterRange insert)
 
static bool dart::ArrayContains (ZoneGrowableArray< unsigned > *array, unsigned value)
 
 dart::COMPILE_ASSERT (BoyerMoorePositionInfo::kMapSize==RegExpMacroAssembler::kTableSize)
 
RegExpNodedart::OptionallyStepBackToLeadSurrogate (RegExpCompiler *compiler, RegExpNode *on_success, RegExpFlags flags)
 
void dart::CreateSpecializedFunction (Thread *thread, Zone *zone, const RegExp &regexp, intptr_t specialization_cid, bool sticky, const Object &owner)
 

Variables

static constexpr bool dart::kRegexpOptimization = true
 
static constexpr intptr_t dart::kMaxLookaheadForBoyerMoore = 8
 
static constexpr int32_t dart::kRangeEndMarker = Utf::kMaxCodePoint + 1
 
static constexpr int32_t dart::kSpaceRanges []
 
static constexpr intptr_t dart::kSpaceRangeCount = ARRAY_SIZE(kSpaceRanges)
 
static constexpr int32_t dart::kWordRanges []
 
static constexpr intptr_t dart::kWordRangeCount = ARRAY_SIZE(kWordRanges)
 
static constexpr int32_t dart::kDigitRanges [] = {'0', '9' + 1, kRangeEndMarker}
 
static constexpr intptr_t dart::kDigitRangeCount = ARRAY_SIZE(kDigitRanges)
 
static constexpr int32_t dart::kSurrogateRanges [] = {0xd800, 0xe000, kRangeEndMarker}
 
static constexpr intptr_t dart::kSurrogateRangeCount = ARRAY_SIZE(kSurrogateRanges)
 
static constexpr int32_t dart::kLineTerminatorRanges []
 
static constexpr intptr_t dart::kLineTerminatorRangeCount
 

Macro Definition Documentation

◆ DEFINE_ACCEPT

#define DEFINE_ACCEPT (   Type)
Value:
void Type##Node::Accept(NodeVisitor* visitor) { \
visitor->Visit##Type(this); \
}

Definition at line 828 of file regexp.cc.

829 { \
830 visitor->Visit##Type(this); \
831 }

◆ OZ

#define OZ   (on_success->zone())

Definition at line 3793 of file regexp.cc.

◆ Z

#define Z   (zone())

Definition at line 26 of file regexp.cc.