OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_X87 | 7 #if V8_TARGET_ARCH_X87 |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
325 NamedLoadHandlerCompiler::GenerateLoadFunctionPrototype(masm, receiver, eax, | 325 NamedLoadHandlerCompiler::GenerateLoadFunctionPrototype(masm, receiver, eax, |
326 ebx, &miss); | 326 ebx, &miss); |
327 __ bind(&miss); | 327 __ bind(&miss); |
328 PropertyAccessCompiler::TailCallBuiltin( | 328 PropertyAccessCompiler::TailCallBuiltin( |
329 masm, PropertyAccessCompiler::MissBuiltin(Code::LOAD_IC)); | 329 masm, PropertyAccessCompiler::MissBuiltin(Code::LOAD_IC)); |
330 } | 330 } |
331 | 331 |
332 | 332 |
333 void ArgumentsAccessStub::GenerateReadElement(MacroAssembler* masm) { | 333 void ArgumentsAccessStub::GenerateReadElement(MacroAssembler* masm) { |
334 // The key is in edx and the parameter count is in eax. | 334 // The key is in edx and the parameter count is in eax. |
| 335 DCHECK(edx.is(ArgumentsAccessReadDescriptor::index())); |
| 336 DCHECK(eax.is(ArgumentsAccessReadDescriptor::parameter_count())); |
335 | 337 |
336 // The displacement is used for skipping the frame pointer on the | 338 // The displacement is used for skipping the frame pointer on the |
337 // stack. It is the offset of the last parameter (if any) relative | 339 // stack. It is the offset of the last parameter (if any) relative |
338 // to the frame pointer. | 340 // to the frame pointer. |
339 static const int kDisplacement = 1 * kPointerSize; | 341 static const int kDisplacement = 1 * kPointerSize; |
340 | 342 |
341 // Check that the key is a smi. | 343 // Check that the key is a smi. |
342 Label slow; | 344 Label slow; |
343 __ JumpIfNotSmi(edx, &slow, Label::kNear); | 345 __ JumpIfNotSmi(edx, &slow, Label::kNear); |
344 | 346 |
(...skipping 3931 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4276 | 4278 |
4277 | 4279 |
4278 void CallApiGetterStub::Generate(MacroAssembler* masm) { | 4280 void CallApiGetterStub::Generate(MacroAssembler* masm) { |
4279 // ----------- S t a t e ------------- | 4281 // ----------- S t a t e ------------- |
4280 // -- esp[0] : return address | 4282 // -- esp[0] : return address |
4281 // -- esp[4] : name | 4283 // -- esp[4] : name |
4282 // -- esp[8 - kArgsLength*4] : PropertyCallbackArguments object | 4284 // -- esp[8 - kArgsLength*4] : PropertyCallbackArguments object |
4283 // -- ... | 4285 // -- ... |
4284 // -- edx : api_function_address | 4286 // -- edx : api_function_address |
4285 // ----------------------------------- | 4287 // ----------------------------------- |
| 4288 DCHECK(edx.is(ApiGetterDescriptor::function_address())); |
4286 | 4289 |
4287 // array for v8::Arguments::values_, handler for name and pointer | 4290 // array for v8::Arguments::values_, handler for name and pointer |
4288 // to the values (it considered as smi in GC). | 4291 // to the values (it considered as smi in GC). |
4289 const int kStackSpace = PropertyCallbackArguments::kArgsLength + 2; | 4292 const int kStackSpace = PropertyCallbackArguments::kArgsLength + 2; |
4290 // Allocate space for opional callback address parameter in case | 4293 // Allocate space for opional callback address parameter in case |
4291 // CPU profiler is active. | 4294 // CPU profiler is active. |
4292 const int kApiArgc = 2 + 1; | 4295 const int kApiArgc = 2 + 1; |
4293 | 4296 |
4294 Register api_function_address = edx; | 4297 Register api_function_address = edx; |
4295 Register scratch = ebx; | 4298 Register scratch = ebx; |
(...skipping 16 matching lines...) Expand all Loading... |
4312 Operand(ebp, 7 * kPointerSize), | 4315 Operand(ebp, 7 * kPointerSize), |
4313 NULL); | 4316 NULL); |
4314 } | 4317 } |
4315 | 4318 |
4316 | 4319 |
4317 #undef __ | 4320 #undef __ |
4318 | 4321 |
4319 } } // namespace v8::internal | 4322 } } // namespace v8::internal |
4320 | 4323 |
4321 #endif // V8_TARGET_ARCH_X87 | 4324 #endif // V8_TARGET_ARCH_X87 |
OLD | NEW |