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

Side by Side Diff: src/mips64/builtins-mips64.cc

Issue 1963583004: [turbofan] Initial version of allocation folding and write barrier elimination. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Jaros comments; Created 4 years, 7 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
« no previous file with comments | « src/mips/builtins-mips.cc ('k') | src/ppc/builtins-ppc.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #if V8_TARGET_ARCH_MIPS64 5 #if V8_TARGET_ARCH_MIPS64
6 6
7 #include "src/codegen.h" 7 #include "src/codegen.h"
8 #include "src/debug/debug.h" 8 #include "src/debug/debug.h"
9 #include "src/deoptimizer.h" 9 #include "src/deoptimizer.h"
10 #include "src/full-codegen/full-codegen.h" 10 #include "src/full-codegen/full-codegen.h"
(...skipping 2712 matching lines...) Expand 10 before | Expand all | Expand 10 after
2723 __ Jump(masm->isolate()->builtins()->ConstructedNonConstructable(), 2723 __ Jump(masm->isolate()->builtins()->ConstructedNonConstructable(),
2724 RelocInfo::CODE_TARGET); 2724 RelocInfo::CODE_TARGET);
2725 } 2725 }
2726 2726
2727 // static 2727 // static
2728 void Builtins::Generate_AllocateInNewSpace(MacroAssembler* masm) { 2728 void Builtins::Generate_AllocateInNewSpace(MacroAssembler* masm) {
2729 // ----------- S t a t e ------------- 2729 // ----------- S t a t e -------------
2730 // -- a0 : requested object size (untagged) 2730 // -- a0 : requested object size (untagged)
2731 // -- ra : return address 2731 // -- ra : return address
2732 // ----------------------------------- 2732 // -----------------------------------
2733 Label runtime;
2734 __ Allocate(a0, v0, a1, a2, &runtime, NO_ALLOCATION_FLAGS);
2735 __ Ret();
2736
2737 __ bind(&runtime);
2738 __ SmiTag(a0); 2733 __ SmiTag(a0);
2739 __ Push(a0); 2734 __ Push(a0);
2740 __ Move(cp, Smi::FromInt(0)); 2735 __ Move(cp, Smi::FromInt(0));
2741 __ TailCallRuntime(Runtime::kAllocateInNewSpace); 2736 __ TailCallRuntime(Runtime::kAllocateInNewSpace);
2742 } 2737 }
2743 2738
2744 // static 2739 // static
2745 void Builtins::Generate_AllocateInOldSpace(MacroAssembler* masm) { 2740 void Builtins::Generate_AllocateInOldSpace(MacroAssembler* masm) {
2746 // ----------- S t a t e ------------- 2741 // ----------- S t a t e -------------
2747 // -- a0 : requested object size (untagged) 2742 // -- a0 : requested object size (untagged)
2748 // -- ra : return address 2743 // -- ra : return address
2749 // ----------------------------------- 2744 // -----------------------------------
2750 Label runtime;
2751 __ Allocate(a0, v0, a1, a2, &runtime, PRETENURE);
2752 __ Ret();
2753
2754 __ bind(&runtime);
2755 __ SmiTag(a0); 2745 __ SmiTag(a0);
2756 __ Move(a1, Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE))); 2746 __ Move(a1, Smi::FromInt(AllocateTargetSpace::encode(OLD_SPACE)));
2757 __ Push(a0, a1); 2747 __ Push(a0, a1);
2758 __ Move(cp, Smi::FromInt(0)); 2748 __ Move(cp, Smi::FromInt(0));
2759 __ TailCallRuntime(Runtime::kAllocateInTargetSpace); 2749 __ TailCallRuntime(Runtime::kAllocateInTargetSpace);
2760 } 2750 }
2761 2751
2762 void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) { 2752 void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) {
2763 // State setup as expected by MacroAssembler::InvokePrologue. 2753 // State setup as expected by MacroAssembler::InvokePrologue.
2764 // ----------- S t a t e ------------- 2754 // ----------- S t a t e -------------
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
2892 } 2882 }
2893 } 2883 }
2894 2884
2895 2885
2896 #undef __ 2886 #undef __
2897 2887
2898 } // namespace internal 2888 } // namespace internal
2899 } // namespace v8 2889 } // namespace v8
2900 2890
2901 #endif // V8_TARGET_ARCH_MIPS64 2891 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/mips/builtins-mips.cc ('k') | src/ppc/builtins-ppc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698