Chromium Code Reviews| Index: src/runtime.cc |
| diff --git a/src/runtime.cc b/src/runtime.cc |
| index c26783ad5a9550fc465e713d45e8dac0a6491fbe..789b7b64e8d91d7383d6edca28713c96ba7f6b54 100644 |
| --- a/src/runtime.cc |
| +++ b/src/runtime.cc |
| @@ -4556,6 +4556,7 @@ static Object* Runtime_LookupContext(Arguments args) { |
| } |
|
William Hesse
2009/09/07 14:34:18
Why three blank lines?
Lasse Reichstein
2009/09/08 11:51:35
Indeed. Fixed.
|
| + |
| // A mechanism to return pairs of Object*'s. This is somewhat |
|
William Hesse
2009/09/07 14:34:18
Object pointers. pointers to Objects.
Lasse Reichstein
2009/09/08 11:51:35
Done.
|
| // compiler-dependent as it assumes that a 64-bit value (a long long) |
| // is returned via two registers (edx:eax on ia32). Both the ia32 and |
| @@ -4565,10 +4566,13 @@ static Object* Runtime_LookupContext(Arguments args) { |
| // TODO(1236026): This is a non-portable hack that should be removed. |
| #ifdef V8_HOST_ARCH_64_BIT |
| // Tested with GCC, not with MSVC. |
| +// Doesn't work in MSVC without changing call sequence. |
| +// A structure used to return pairs of Object*'s. |
| struct ObjectPair { |
| Object* x; |
| Object* y; |
| }; |
| + |
| static inline ObjectPair MakePair(Object* x, Object* y) { |
| ObjectPair result = {x, y}; |
| return result; // Pointers x and y returned in rax and rdx, in AMD-x64-abi. |
| @@ -4582,8 +4586,6 @@ static inline ObjectPair MakePair(Object* x, Object* y) { |
| #endif |
| - |
| - |
| static inline Object* Unhole(Object* x, PropertyAttributes attributes) { |
| ASSERT(!x->IsTheHole() || (attributes & READ_ONLY) != 0); |
| USE(attributes); |
| @@ -7598,7 +7600,7 @@ static Object* Runtime_ListNatives(Arguments args) { |
| HandleScope scope; |
| Handle<JSArray> result = Factory::NewJSArray(0); |
| int index = 0; |
| -#define ADD_ENTRY(Name, argc) \ |
| +#define ADD_ENTRY(Name, argc, ressize) \ |
| { \ |
| HandleScope inner; \ |
| Handle<String> name = \ |
| @@ -7634,13 +7636,13 @@ static Object* Runtime_IS_VAR(Arguments args) { |
| // ---------------------------------------------------------------------------- |
| // Implementation of Runtime |
| -#define F(name, nargs) \ |
| +#define F(name, nargs, ressize) \ |
| { #name, "RuntimeStub_" #name, FUNCTION_ADDR(Runtime_##name), nargs, \ |
| - static_cast<int>(Runtime::k##name) }, |
| + static_cast<int>(Runtime::k##name), ressize }, |
| static Runtime::Function Runtime_functions[] = { |
| RUNTIME_FUNCTION_LIST(F) |
| - { NULL, NULL, NULL, 0, -1 } |
| + { NULL, NULL, NULL, 0, -1, 0 } |
| }; |
| #undef F |