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

Unified Diff: src/hydrogen.cc

Issue 6686003: Refactor fast API call. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Next round Created 9 years, 9 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 | « src/arm/stub-cache-arm.cc ('k') | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 513d4a8501b9210ab23ae2edd4b377cc1fcb8188..a4736e82b37e8921b04946068661e2a353454bb6 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -4241,13 +4241,6 @@ bool HGraphBuilder::TryCallApply(Call* expr) {
}
-static bool HasCustomCallGenerator(Handle<JSFunction> function) {
- SharedFunctionInfo* info = function->shared();
- return info->HasBuiltinFunctionId() &&
- CallStubCompiler::HasCustomCallGenerator(info->builtin_function_id());
-}
-
-
void HGraphBuilder::VisitCall(Call* expr) {
Expression* callee = expr->expression();
int argument_count = expr->arguments()->length() + 1; // Plus receiver.
@@ -4305,13 +4298,11 @@ void HGraphBuilder::VisitCall(Call* expr) {
return;
}
- if (HasCustomCallGenerator(expr->target()) ||
- CallOptimization(*expr->target()).is_simple_api_call() ||
+ if (CallStubCompiler::HasCustomCallGenerator(*expr->target()) ||
expr->check_type() != RECEIVER_MAP_CHECK) {
// When the target has a custom call IC generator, use the IC,
- // because it is likely to generate better code. Similarly, we
- // generate better call stubs for some API functions.
- // Also use the IC when a primitive receiver check is required.
+ // because it is likely to generate better code. Also use the IC
+ // when a primitive receiver check is required.
HContext* context = new HContext;
AddInstruction(context);
call = PreProcessCall(new HCallNamed(context, name, argument_count));
« no previous file with comments | « src/arm/stub-cache-arm.cc ('k') | src/ia32/stub-cache-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698