Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1485)

Unified Diff: runtime/lib/regexp.cc

Issue 1305993005: VM: Simplify irregexp entry stub. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: simplify ExecuteMatch Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/flow_graph_type_propagator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/regexp.cc
diff --git a/runtime/lib/regexp.cc b/runtime/lib/regexp.cc
index 6fd9d6f1ccd0d2af02f123dfe5c6dce1de908b93..14bf14f4ebaa1ddda78dabb0731b5a31197f5365 100644
--- a/runtime/lib/regexp.cc
+++ b/runtime/lib/regexp.cc
@@ -83,6 +83,7 @@ DEFINE_NATIVE_ENTRY(JSSyntaxRegExp_getGroupCount, 1) {
DEFINE_NATIVE_ENTRY(JSSyntaxRegExp_ExecuteMatch, 3) {
+ // This function is intrinsified. See Intrinsifier::JSRegExp_ExecuteMatch.
const JSRegExp& regexp = JSRegExp::CheckedHandle(arguments->NativeArgAt(0));
ASSERT(!regexp.IsNull());
GET_NON_NULL_NATIVE_ARGUMENT(String, subject, arguments->NativeArgAt(1));
@@ -93,15 +94,7 @@ DEFINE_NATIVE_ENTRY(JSSyntaxRegExp_ExecuteMatch, 3) {
zone);
}
- // This function is intrinsified. See Intrinsifier::JSRegExp_ExecuteMatch.
- const intptr_t cid = subject.GetClassId();
-
- // Retrieve the cached function.
- const Function& fn = Function::Handle(regexp.function(cid));
- ASSERT(!fn.IsNull());
-
- // And finally call the generated code.
- return IRRegExpMacroAssembler::Execute(fn, subject, start_index, zone);
+ return IRRegExpMacroAssembler::Execute(regexp, subject, start_index, zone);
}
} // namespace dart
« no previous file with comments | « no previous file | runtime/vm/flow_graph_type_propagator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698