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

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

Issue 8932004: Implement target cache for constructor calls. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments by Vyacheslav Egorov. Created 8 years, 10 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/type-info.cc ('K') | « src/x64/full-codegen-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 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 3085 matching lines...) Expand 10 before | Expand all | Expand 10 after
3096 ASSERT(ToRegister(instr->result()).is(rax)); 3096 ASSERT(ToRegister(instr->result()).is(rax));
3097 __ LoadHeapObject(rdi, instr->target()); 3097 __ LoadHeapObject(rdi, instr->target());
3098 CallKnownFunction(instr->target(), instr->arity(), instr, CALL_AS_FUNCTION); 3098 CallKnownFunction(instr->target(), instr->arity(), instr, CALL_AS_FUNCTION);
3099 } 3099 }
3100 3100
3101 3101
3102 void LCodeGen::DoCallNew(LCallNew* instr) { 3102 void LCodeGen::DoCallNew(LCallNew* instr) {
3103 ASSERT(ToRegister(instr->InputAt(0)).is(rdi)); 3103 ASSERT(ToRegister(instr->InputAt(0)).is(rdi));
3104 ASSERT(ToRegister(instr->result()).is(rax)); 3104 ASSERT(ToRegister(instr->result()).is(rax));
3105 3105
3106 Handle<Code> builtin = isolate()->builtins()->JSConstructCall(); 3106 CallConstructStub stub(NO_CALL_FUNCTION_FLAGS);
3107 __ Set(rax, instr->arity()); 3107 __ Set(rax, instr->arity());
3108 CallCode(builtin, RelocInfo::CONSTRUCT_CALL, instr); 3108 CallCode(stub.GetCode(), RelocInfo::CONSTRUCT_CALL, instr);
3109 } 3109 }
3110 3110
3111 3111
3112 void LCodeGen::DoCallRuntime(LCallRuntime* instr) { 3112 void LCodeGen::DoCallRuntime(LCallRuntime* instr) {
3113 CallRuntime(instr->function(), instr->arity(), instr); 3113 CallRuntime(instr->function(), instr->arity(), instr);
3114 } 3114 }
3115 3115
3116 3116
3117 void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) { 3117 void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
3118 Register object = ToRegister(instr->object()); 3118 Register object = ToRegister(instr->object());
(...skipping 1266 matching lines...) Expand 10 before | Expand all | Expand 10 after
4385 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt); 4385 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt);
4386 ASSERT(osr_pc_offset_ == -1); 4386 ASSERT(osr_pc_offset_ == -1);
4387 osr_pc_offset_ = masm()->pc_offset(); 4387 osr_pc_offset_ = masm()->pc_offset();
4388 } 4388 }
4389 4389
4390 #undef __ 4390 #undef __
4391 4391
4392 } } // namespace v8::internal 4392 } } // namespace v8::internal
4393 4393
4394 #endif // V8_TARGET_ARCH_X64 4394 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/type-info.cc ('K') | « src/x64/full-codegen-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698