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

Side by Side Diff: src/x64/lithium-codegen-x64.cc

Issue 16206007: Turn off allocation site info for crankshafted array constructor calls. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 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
« src/code-stubs.h ('K') | « src/x64/code-stubs-x64.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 3918 matching lines...) Expand 10 before | Expand all | Expand 10 after
3929 3929
3930 3930
3931 void LCodeGen::DoCallNewArray(LCallNewArray* instr) { 3931 void LCodeGen::DoCallNewArray(LCallNewArray* instr) {
3932 ASSERT(ToRegister(instr->constructor()).is(rdi)); 3932 ASSERT(ToRegister(instr->constructor()).is(rdi));
3933 ASSERT(ToRegister(instr->result()).is(rax)); 3933 ASSERT(ToRegister(instr->result()).is(rax));
3934 ASSERT(FLAG_optimize_constructed_arrays); 3934 ASSERT(FLAG_optimize_constructed_arrays);
3935 3935
3936 __ Set(rax, instr->arity()); 3936 __ Set(rax, instr->arity());
3937 __ Move(rbx, instr->hydrogen()->property_cell()); 3937 __ Move(rbx, instr->hydrogen()->property_cell());
3938 ElementsKind kind = instr->hydrogen()->elements_kind(); 3938 ElementsKind kind = instr->hydrogen()->elements_kind();
3939 bool disable_allocation_sites =
3940 (AllocationSiteInfo::GetMode(kind) == TRACK_ALLOCATION_SITE);
3941
3939 if (instr->arity() == 0) { 3942 if (instr->arity() == 0) {
3940 ArrayNoArgumentConstructorStub stub(kind); 3943 ArrayNoArgumentConstructorStub stub(kind, disable_allocation_sites);
3941 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); 3944 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
3942 } else if (instr->arity() == 1) { 3945 } else if (instr->arity() == 1) {
3943 ArraySingleArgumentConstructorStub stub(kind); 3946 ArraySingleArgumentConstructorStub stub(kind, disable_allocation_sites);
3944 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); 3947 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
3945 } else { 3948 } else {
3946 ArrayNArgumentsConstructorStub stub(kind); 3949 ArrayNArgumentsConstructorStub stub(kind, disable_allocation_sites);
3947 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); 3950 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
3948 } 3951 }
3949 } 3952 }
3950 3953
3951 3954
3952 void LCodeGen::DoCallRuntime(LCallRuntime* instr) { 3955 void LCodeGen::DoCallRuntime(LCallRuntime* instr) {
3953 CallRuntime(instr->function(), instr->arity(), instr); 3956 CallRuntime(instr->function(), instr->arity(), instr);
3954 } 3957 }
3955 3958
3956 3959
(...skipping 1741 matching lines...) Expand 10 before | Expand all | Expand 10 after
5698 FixedArray::kHeaderSize - kPointerSize)); 5701 FixedArray::kHeaderSize - kPointerSize));
5699 __ bind(&done); 5702 __ bind(&done);
5700 } 5703 }
5701 5704
5702 5705
5703 #undef __ 5706 #undef __
5704 5707
5705 } } // namespace v8::internal 5708 } } // namespace v8::internal
5706 5709
5707 #endif // V8_TARGET_ARCH_X64 5710 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/code-stubs.h ('K') | « src/x64/code-stubs-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698