Commit d084929d authored by jgruber's avatar jgruber Committed by Commit Bot

[regexp] Typify RegExpPrototypeExecBodyWithoutResult

And related call sites.

Drive-by: add IntPtrZero() and SmiZero() helpers.

Bug: v8:8015
Change-Id: I83195cf2da858f8d35f25c9a1aa5c40c81df78b9
Reviewed-on: https://chromium-review.googlesource.com/1162169
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: 's avatarPeter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54918}
parent cdb4d913
This diff is collapsed.
......@@ -34,6 +34,9 @@ class RegExpBuiltinsAssembler : public CodeStubAssembler {
char const* method_name);
protected:
TNode<Smi> SmiZero();
TNode<IntPtrT> IntPtrZero();
// Allocate a RegExpResult with the given length (the number of captures,
// including the match itself), index (the index where the match starts),
// and input string. |length| and |index| are expected to be tagged, and
......@@ -41,9 +44,10 @@ class RegExpBuiltinsAssembler : public CodeStubAssembler {
Node* AllocateRegExpResult(Node* context, Node* length, Node* index,
Node* input);
TNode<Object> FastLoadLastIndex(Node* regexp);
Node* SlowLoadLastIndex(Node* context, Node* regexp);
Node* LoadLastIndex(Node* context, Node* regexp, bool is_fastpath);
TNode<Object> FastLoadLastIndex(TNode<JSRegExp> regexp);
TNode<Object> SlowLoadLastIndex(TNode<Context> context, TNode<Object> regexp);
TNode<Object> LoadLastIndex(TNode<Context> context, TNode<Object> regexp,
bool is_fastpath);
void FastStoreLastIndex(Node* regexp, Node* value);
void SlowStoreLastIndex(Node* context, Node* regexp, Node* value);
......@@ -58,20 +62,19 @@ class RegExpBuiltinsAssembler : public CodeStubAssembler {
Variable* var_string_end);
// Low level logic around the actual call into pattern matching code.
TNode<Object> RegExpExecInternal(TNode<Context> context,
TNode<JSRegExp> regexp, TNode<String> string,
TNode<Number> last_index,
TNode<FixedArray> match_info);
TNode<HeapObject> RegExpExecInternal(TNode<Context> context,
TNode<JSRegExp> regexp,
TNode<String> string,
TNode<Number> last_index,
TNode<RegExpMatchInfo> match_info);
Node* ConstructNewResultFromMatchInfo(Node* const context, Node* const regexp,
Node* const match_info,
TNode<String> const string);
Node* RegExpPrototypeExecBodyWithoutResult(Node* const context,
Node* const regexp,
Node* const string,
Label* if_didnotmatch,
const bool is_fastpath);
TNode<HeapObject> RegExpPrototypeExecBodyWithoutResult(
TNode<Context> context, TNode<JSReceiver> maybe_regexp,
TNode<String> string, Label* if_didnotmatch, const bool is_fastpath);
Node* RegExpPrototypeExecBody(Node* const context, Node* const regexp,
TNode<String> string, const bool is_fastpath);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment