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

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

Issue 23530066: Lazily save double registers for HCallRuntime instructions within Hydrogen code stubs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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
« no previous file with comments | « src/ia32/lithium-codegen-ia32.h ('k') | src/ia32/lithium-ia32.h » ('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 // 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 965 matching lines...) Expand 10 before | Expand all | Expand 10 after
976 976
977 void LCodeGen::CallCode(Handle<Code> code, 977 void LCodeGen::CallCode(Handle<Code> code,
978 RelocInfo::Mode mode, 978 RelocInfo::Mode mode,
979 LInstruction* instr) { 979 LInstruction* instr) {
980 CallCodeGeneric(code, mode, instr, RECORD_SIMPLE_SAFEPOINT); 980 CallCodeGeneric(code, mode, instr, RECORD_SIMPLE_SAFEPOINT);
981 } 981 }
982 982
983 983
984 void LCodeGen::CallRuntime(const Runtime::Function* fun, 984 void LCodeGen::CallRuntime(const Runtime::Function* fun,
985 int argc, 985 int argc,
986 LInstruction* instr) { 986 LInstruction* instr,
987 SaveFPRegsMode save_doubles) {
987 ASSERT(instr != NULL); 988 ASSERT(instr != NULL);
988 ASSERT(instr->HasPointerMap()); 989 ASSERT(instr->HasPointerMap());
989 LPointerMap* pointers = instr->pointer_map(); 990 LPointerMap* pointers = instr->pointer_map();
990 RecordPosition(pointers->position()); 991 RecordPosition(pointers->position());
991 992
992 __ CallRuntime(fun, argc); 993 __ CallRuntime(fun, argc, save_doubles);
993 994
994 RecordSafepointWithLazyDeopt(instr, RECORD_SIMPLE_SAFEPOINT); 995 RecordSafepointWithLazyDeopt(instr, RECORD_SIMPLE_SAFEPOINT);
995 996
996 ASSERT(info()->is_calling()); 997 ASSERT(info()->is_calling());
997 } 998 }
998 999
999 1000
1000 void LCodeGen::LoadContextFromDeferred(LOperand* context) { 1001 void LCodeGen::LoadContextFromDeferred(LOperand* context) {
1001 if (context->IsRegister()) { 1002 if (context->IsRegister()) {
1002 if (!ToRegister(context).is(esi)) { 1003 if (!ToRegister(context).is(esi)) {
(...skipping 3421 matching lines...) Expand 10 before | Expand all | Expand 10 after
4424 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); 4425 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
4425 __ bind(&done); 4426 __ bind(&done);
4426 } else { 4427 } else {
4427 ArrayNArgumentsConstructorStub stub(kind, context_mode, override_mode); 4428 ArrayNArgumentsConstructorStub stub(kind, context_mode, override_mode);
4428 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); 4429 CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr);
4429 } 4430 }
4430 } 4431 }
4431 4432
4432 4433
4433 void LCodeGen::DoCallRuntime(LCallRuntime* instr) { 4434 void LCodeGen::DoCallRuntime(LCallRuntime* instr) {
4434 CallRuntime(instr->function(), instr->arity(), instr); 4435 CallRuntime(instr->function(), instr->arity(), instr, instr->save_doubles());
4435 } 4436 }
4436 4437
4437 4438
4438 void LCodeGen::DoStoreCodeEntry(LStoreCodeEntry* instr) { 4439 void LCodeGen::DoStoreCodeEntry(LStoreCodeEntry* instr) {
4439 Register function = ToRegister(instr->function()); 4440 Register function = ToRegister(instr->function());
4440 Register code_object = ToRegister(instr->code_object()); 4441 Register code_object = ToRegister(instr->code_object());
4441 __ lea(code_object, FieldOperand(code_object, Code::kHeaderSize)); 4442 __ lea(code_object, FieldOperand(code_object, Code::kHeaderSize));
4442 __ mov(FieldOperand(function, JSFunction::kCodeEntryOffset), code_object); 4443 __ mov(FieldOperand(function, JSFunction::kCodeEntryOffset), code_object);
4443 } 4444 }
4444 4445
(...skipping 1939 matching lines...) Expand 10 before | Expand all | Expand 10 after
6384 FixedArray::kHeaderSize - kPointerSize)); 6385 FixedArray::kHeaderSize - kPointerSize));
6385 __ bind(&done); 6386 __ bind(&done);
6386 } 6387 }
6387 6388
6388 6389
6389 #undef __ 6390 #undef __
6390 6391
6391 } } // namespace v8::internal 6392 } } // namespace v8::internal
6392 6393
6393 #endif // V8_TARGET_ARCH_IA32 6394 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/lithium-codegen-ia32.h ('k') | src/ia32/lithium-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698