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

Unified Diff: src/hydrogen.cc

Issue 527093002: Make concrete classes for individual call descriptors. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE. Created 6 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
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 169df22aa8293093add0c5275fb7343b00118c6e..e0fb789167cc959895e90e5ae77af1bd1d6ada96 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -7394,9 +7394,7 @@ HInstruction* HOptimizedGraphBuilder::NewPlainFunctionCall(
HInstruction* HOptimizedGraphBuilder::NewArgumentAdaptorCall(
HValue* fun, HValue* context,
int argument_count, HValue* expected_param_count) {
- CallInterfaceDescriptor* descriptor =
- isolate()->call_descriptor(CallDescriptorKey::ArgumentAdaptorCall);
-
+ ArgumentAdaptorDescriptor descriptor(isolate());
HValue* arity = Add<HConstant>(argument_count - 1);
HValue* op_vals[] = { context, fun, arity, expected_param_count };
@@ -7407,7 +7405,7 @@ HInstruction* HOptimizedGraphBuilder::NewArgumentAdaptorCall(
return New<HCallWithDescriptor>(
adaptor_value, argument_count, descriptor,
- Vector<HValue*>(op_vals, descriptor->GetEnvironmentLength()));
+ Vector<HValue*>(op_vals, descriptor.GetEnvironmentLength()));
}
@@ -8644,19 +8642,16 @@ bool HOptimizedGraphBuilder::TryInlineApiCall(Handle<JSFunction> function,
api_function_address
};
- CallInterfaceDescriptor* descriptor =
- isolate()->call_descriptor(CallDescriptorKey::ApiFunctionCall);
-
+ ApiFunctionDescriptor descriptor(isolate());
CallApiFunctionStub stub(isolate(), is_store, call_data_is_undefined, argc);
Handle<Code> code = stub.GetCode();
HConstant* code_value = Add<HConstant>(code);
- DCHECK((sizeof(op_vals) / kPointerSize) ==
- descriptor->GetEnvironmentLength());
+ DCHECK((sizeof(op_vals) / kPointerSize) == descriptor.GetEnvironmentLength());
HInstruction* call = New<HCallWithDescriptor>(
code_value, argc + 1, descriptor,
- Vector<HValue*>(op_vals, descriptor->GetEnvironmentLength()));
+ Vector<HValue*>(op_vals, descriptor.GetEnvironmentLength()));
if (drop_extra) Drop(1); // Drop function.
ast_context()->ReturnInstruction(call, ast_id);

Powered by Google App Engine
This is Rietveld 408576698