Revision: 22023
Author: [email protected]
Date: Wed Jun 25 18:43:06 2014 UTC
Log: MIPS: Cleanup CallInterfaceDescriptor.
Port r22014 (234866c)
Original commit message:
Make CallInterfaceDescriptor work like CodeStubInterfaceDescriptor, owning
it's
register and representation arrays. This also eliminates a host of TSAN
warnings
for static arrays.
This CL depends on https://codereview.chromium.org/352583002 landing first
(a conceptual dependency at least).
BUG=
[email protected]
Review URL: https://codereview.chromium.org/356773003
http://code.google.com/p/v8/source/detail?r=22023
Modified:
/branches/bleeding_edge/src/mips/code-stubs-mips.cc
=======================================
--- /branches/bleeding_edge/src/mips/code-stubs-mips.cc Wed Jun 25 16:17:31
2014 UTC
+++ /branches/bleeding_edge/src/mips/code-stubs-mips.cc Wed Jun 25 18:43:06
2014 UTC
@@ -306,82 +306,72 @@
{
CallInterfaceDescriptor* descriptor =
isolate->call_descriptor(Isolate::ArgumentAdaptorCall);
- static Register registers[] = { a1, // JSFunction
- cp, // context
- a0, // actual number of arguments
- a2, // expected number of arguments
+ Register registers[] = { a1, // JSFunction
+ cp, // context
+ a0, // actual number of arguments
+ a2, // expected number of arguments
};
- static Representation representations[] = {
+ Representation representations[] = {
Representation::Tagged(), // JSFunction
Representation::Tagged(), // context
Representation::Integer32(), // actual number of arguments
Representation::Integer32(), // expected number of arguments
};
- descriptor->register_param_count_ = 4;
- descriptor->register_params_ = registers;
- descriptor->param_representations_ = representations;
+ descriptor->Initialize(ARRAY_SIZE(registers), registers,
representations);
}
{
CallInterfaceDescriptor* descriptor =
isolate->call_descriptor(Isolate::KeyedCall);
- static Register registers[] = { cp, // context
- a2, // key
+ Register registers[] = { cp, // context
+ a2, // key
};
- static Representation representations[] = {
+ Representation representations[] = {
Representation::Tagged(), // context
Representation::Tagged(), // key
};
- descriptor->register_param_count_ = 2;
- descriptor->register_params_ = registers;
- descriptor->param_representations_ = representations;
+ descriptor->Initialize(ARRAY_SIZE(registers), registers,
representations);
}
{
CallInterfaceDescriptor* descriptor =
isolate->call_descriptor(Isolate::NamedCall);
- static Register registers[] = { cp, // context
- a2, // name
+ Register registers[] = { cp, // context
+ a2, // name
};
- static Representation representations[] = {
+ Representation representations[] = {
Representation::Tagged(), // context
Representation::Tagged(), // name
};
- descriptor->register_param_count_ = 2;
- descriptor->register_params_ = registers;
- descriptor->param_representations_ = representations;
+ descriptor->Initialize(ARRAY_SIZE(registers), registers,
representations);
}
{
CallInterfaceDescriptor* descriptor =
isolate->call_descriptor(Isolate::CallHandler);
- static Register registers[] = { cp, // context
- a0, // receiver
+ Register registers[] = { cp, // context
+ a0, // receiver
};
- static Representation representations[] = {
+ Representation representations[] = {
Representation::Tagged(), // context
Representation::Tagged(), // receiver
};
- descriptor->register_param_count_ = 2;
- descriptor->register_params_ = registers;
- descriptor->param_representations_ = representations;
+ descriptor->Initialize(ARRAY_SIZE(registers), registers,
representations);
}
{
CallInterfaceDescriptor* descriptor =
isolate->call_descriptor(Isolate::ApiFunctionCall);
- static Register registers[] = { a0, // callee
- t0, // call_data
- a2, // holder
- a1, // api_function_address
- cp, // context
+ Register registers[] = { a0, // callee
+ t0, // call_data
+ a2, // holder
+ a1, // api_function_address
+ cp, // context
};
- static Representation representations[] = {
+ Representation representations[] = {
Representation::Tagged(), // callee
Representation::Tagged(), // call_data
Representation::Tagged(), // holder
Representation::External(), // api_function_address
Representation::Tagged(), // context
};
- descriptor->register_param_count_ = 5;
- descriptor->register_params_ = registers;
- descriptor->param_representations_ = representations;
+ descriptor->Initialize(ARRAY_SIZE(registers), registers,
representations);
}
}
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.