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

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

Issue 9187005: Enable optimization of top-level code. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: fixed problem with eval code, addressed comments 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
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 2587 matching lines...) Expand 10 before | Expand all | Expand 10 after
2598 2598
2599 2599
2600 void LCodeGen::DoOuterContext(LOuterContext* instr) { 2600 void LCodeGen::DoOuterContext(LOuterContext* instr) {
2601 Register context = ToRegister(instr->context()); 2601 Register context = ToRegister(instr->context());
2602 Register result = ToRegister(instr->result()); 2602 Register result = ToRegister(instr->result());
2603 __ movq(result, 2603 __ movq(result,
2604 Operand(context, Context::SlotOffset(Context::PREVIOUS_INDEX))); 2604 Operand(context, Context::SlotOffset(Context::PREVIOUS_INDEX)));
2605 } 2605 }
2606 2606
2607 2607
2608 void LCodeGen::DoDeclareGlobals(LDeclareGlobals* instr) {
2609 __ push(rsi); // The context is the first argument.
2610 __ PushHeapObject(instr->hydrogen()->pairs());
2611 __ Push(Smi::FromInt(instr->hydrogen()->flags()));
2612 CallRuntime(Runtime::kDeclareGlobals, 3, instr);
2613 }
2614
2615
2608 void LCodeGen::DoGlobalObject(LGlobalObject* instr) { 2616 void LCodeGen::DoGlobalObject(LGlobalObject* instr) {
2609 Register result = ToRegister(instr->result()); 2617 Register result = ToRegister(instr->result());
2610 __ movq(result, GlobalObjectOperand()); 2618 __ movq(result, GlobalObjectOperand());
2611 } 2619 }
2612 2620
2613 2621
2614 void LCodeGen::DoGlobalReceiver(LGlobalReceiver* instr) { 2622 void LCodeGen::DoGlobalReceiver(LGlobalReceiver* instr) {
2615 Register global = ToRegister(instr->global()); 2623 Register global = ToRegister(instr->global());
2616 Register result = ToRegister(instr->result()); 2624 Register result = ToRegister(instr->result());
2617 __ movq(result, FieldOperand(global, GlobalObject::kGlobalReceiverOffset)); 2625 __ movq(result, FieldOperand(global, GlobalObject::kGlobalReceiverOffset));
(...skipping 1786 matching lines...) Expand 10 before | Expand all | Expand 10 after
4404 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt); 4412 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt);
4405 ASSERT(osr_pc_offset_ == -1); 4413 ASSERT(osr_pc_offset_ == -1);
4406 osr_pc_offset_ = masm()->pc_offset(); 4414 osr_pc_offset_ = masm()->pc_offset();
4407 } 4415 }
4408 4416
4409 #undef __ 4417 #undef __
4410 4418
4411 } } // namespace v8::internal 4419 } } // namespace v8::internal
4412 4420
4413 #endif // V8_TARGET_ARCH_X64 4421 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/compiler.cc ('K') | « src/x64/full-codegen-x64.cc ('k') | src/x64/lithium-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698