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

Side by Side Diff: src/x64/code-stubs-x64.cc

Issue 11151005: Improve FastCloneShallowArray/ObjectStubs with VFP copying on ARM (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 // Return and remove the on-stack parameter. 293 // Return and remove the on-stack parameter.
294 __ movq(rsi, rax); 294 __ movq(rsi, rax);
295 __ ret(2 * kPointerSize); 295 __ ret(2 * kPointerSize);
296 296
297 // Need to collect. Call into runtime system. 297 // Need to collect. Call into runtime system.
298 __ bind(&gc); 298 __ bind(&gc);
299 __ TailCallRuntime(Runtime::kPushBlockContext, 2, 1); 299 __ TailCallRuntime(Runtime::kPushBlockContext, 2, 1);
300 } 300 }
301 301
302 302
303 int FastCloneShallowArrayStub::MaximumClonedLength() {
304 return 8;
305 }
306
307
303 static void GenerateFastCloneShallowArrayCommon( 308 static void GenerateFastCloneShallowArrayCommon(
304 MacroAssembler* masm, 309 MacroAssembler* masm,
305 int length, 310 int length,
306 FastCloneShallowArrayStub::Mode mode, 311 FastCloneShallowArrayStub::Mode mode,
307 Label* fail) { 312 Label* fail) {
308 // Registers on entry: 313 // Registers on entry:
309 // 314 //
310 // rcx: boilerplate literal array. 315 // rcx: boilerplate literal array.
311 ASSERT(mode != FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS); 316 ASSERT(mode != FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS);
312 317
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 } 433 }
429 434
430 GenerateFastCloneShallowArrayCommon(masm, length_, mode, &slow_case); 435 GenerateFastCloneShallowArrayCommon(masm, length_, mode, &slow_case);
431 __ ret(3 * kPointerSize); 436 __ ret(3 * kPointerSize);
432 437
433 __ bind(&slow_case); 438 __ bind(&slow_case);
434 __ TailCallRuntime(Runtime::kCreateArrayLiteralShallow, 3, 1); 439 __ TailCallRuntime(Runtime::kCreateArrayLiteralShallow, 3, 1);
435 } 440 }
436 441
437 442
443 int FastCloneShallowObjectStub::MaximumClonedProperties() {
444 return 6;
445 }
446
447
438 void FastCloneShallowObjectStub::Generate(MacroAssembler* masm) { 448 void FastCloneShallowObjectStub::Generate(MacroAssembler* masm) {
439 // Stack layout on entry: 449 // Stack layout on entry:
440 // 450 //
441 // [rsp + kPointerSize]: object literal flags. 451 // [rsp + kPointerSize]: object literal flags.
442 // [rsp + (2 * kPointerSize)]: constant properties. 452 // [rsp + (2 * kPointerSize)]: constant properties.
443 // [rsp + (3 * kPointerSize)]: literal index. 453 // [rsp + (3 * kPointerSize)]: literal index.
444 // [rsp + (4 * kPointerSize)]: literals array. 454 // [rsp + (4 * kPointerSize)]: literals array.
445 455
446 // Load boilerplate object into ecx and check if we need to create a 456 // Load boilerplate object into ecx and check if we need to create a
447 // boilerplate. 457 // boilerplate.
(...skipping 6034 matching lines...) Expand 10 before | Expand all | Expand 10 after
6482 #endif 6492 #endif
6483 6493
6484 __ Ret(); 6494 __ Ret();
6485 } 6495 }
6486 6496
6487 #undef __ 6497 #undef __
6488 6498
6489 } } // namespace v8::internal 6499 } } // namespace v8::internal
6490 6500
6491 #endif // V8_TARGET_ARCH_X64 6501 #endif // V8_TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698