Lines Matching refs:code
6 // * Redistributions of source code must retain the above copyright
69 // Call the construct code with 2 arguments.
240 #else // ! V8_NATIVE_REGEXP (RegExp interpreter code)
298 data->set(JSRegExp::code_index(is_ascii), result.code);
334 Code* RegExpImpl::IrregexpNativeCode(FixedArray* re, bool is_ascii) {
335 return Code::cast(re->get(JSRegExp::code_index(is_ascii)));
343 // Initialize compiled code entries to null.
393 Handle<Code> code(RegExpImpl::IrregexpNativeCode(*regexp, is_ascii));
394 res = NativeRegExpMacroAssembler::Match(code,
474 // bytecodes or native code.
482 // 3) From the nodes we generate either byte codes or native code
484 // the search). The code generation step is described in more
487 // Code generation.
508 // The code generated (whether as byte codes or native code) maintains
520 // which will be presented first. The actual code generated is a more
526 // push backtrack code location
527 // <generate code to test for choice>
528 // backtrack code location:
531 // <generate code to test for last choice>
535 // <generate code to perform action>
536 // push backtrack code location
537 // <generate code to test for following nodes>
538 // backtrack code location:
545 // <generate code to test for following nodes>
555 // the node has already been code generated then the Emit() call will
556 // generate a jump to the previously generated code instead. In order to
559 // destination of the jump is resolved later when the code is generated.
561 // Actual regular expression code generation.
563 // Code generation is actually more complicated than the above. In order
564 // to improve the efficiency of the generated code some optimizations are
585 // are needed and to generate code for a node more than once, allowing
586 // specialized an efficient versions of the code to be created. This is
591 // Instead of emitting code, nodes that manipulate the state can record their
593 // current position offset, an optional backtrack code location on the top of
596 // will emit code to bring the actual state into line with the virtual state.
601 // known backtrack code location than it is to pop an unknown backtrack
604 // The virtual state found in the Trace affects code generation. For example
606 // position and the virtual current position, and matching code needs to use
608 // string. Therefore code generated for a non-trivial trace is specialized
609 // to that trace. The code generator therefore has the ability to generate
610 // code for each node several times. In order to limit the size of the
611 // generated code there is an arbitrary limit on how many specialized sets of
612 // code may be generated for a given node. If the limit is reached, the
613 // trace is flushed and a generic version of the code for a node is emitted.
614 // This is subsequently used for that node. The code emitted for non-generic
616 // the event that code generation is requested for an identical trace.
740 // Attempts to compile the regexp using an Irregexp code generator. Returns
778 Handle<Object> code = macro_assembler_->GetCode(pattern);
786 return RegExpEngine::CompilationResult(*code, next_register_);
995 // nodes. It normalizes the state of the code generator to ensure we can
996 // generate generic code.
1013 // Generate deferred actions here along with code to undo them again.
1063 // so this code can be used as the generic version.
1200 // Emit code.
1329 // involved in order to simplify code generation.
1529 // If we are generating a greedy loop then don't stop and don't reuse code.
1563 // If we get here code has been generated for this node too many times or
1564 // recursion is too deep. Time to switch to a generic version. The code for
2042 // Emit the code to check for a ^ in multiline mode (1-character lookbehind
2078 // Emit the code to handle \b and \B (word-boundary or non-word-boundary)
2118 // Emit the code to handle \b and \B (word-boundary or non-word-boundary).
2255 // We call this repeatedly to generate code for each pass over the text node.
2279 // order to get to the code we are now generating. The quick check can involve
2375 // This generates the code to match a text node. A text node can contain
2379 // emitting code for some character positions every time. See the comment on
2495 // Later we will generate code for all these text nodes using recursion
2570 // records the way the alternative is being code generated.
2615 /* Code generation for choice nodes.
2627 * next GoTo if we decide to reuse some already generated code. Some
2666 * than fail. Therefore we want the loop code to look like this (U is the
2667 * unwind code that steps back in the greedy loop). The following alternatives
2811 // No quick check was generated. Put the full code here.
2894 // code through a quick check which already did the checked load.
3612 // combined if it turns out they hinder good code generation.
4650 // because the following code only handles ranges that start on