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

Side by Side Diff: runtime/vm/intermediate_language_ia32.cc

Issue 626523002: VM: Improve generated code for loading the current context. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 2 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 | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_mips.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 (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32.
6 #if defined(TARGET_ARCH_IA32) 6 #if defined(TARGET_ARCH_IA32)
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 6506 matching lines...) Expand 10 before | Expand all | Expand 10 after
6517 } 6517 }
6518 6518
6519 // We can fall through if the successor is the next block in the list. 6519 // We can fall through if the successor is the next block in the list.
6520 // Otherwise, we need a jump. 6520 // Otherwise, we need a jump.
6521 if (!compiler->CanFallThroughTo(successor())) { 6521 if (!compiler->CanFallThroughTo(successor())) {
6522 __ jmp(compiler->GetJumpLabel(successor())); 6522 __ jmp(compiler->GetJumpLabel(successor()));
6523 } 6523 }
6524 } 6524 }
6525 6525
6526 6526
6527 LocationSummary* CurrentContextInstr::MakeLocationSummary(Isolate* isolate,
6528 bool opt) const {
6529 return LocationSummary::Make(isolate,
6530 0,
6531 Location::RequiresRegister(),
6532 LocationSummary::kNoCall);
6533 }
6534
6535
6536 void CurrentContextInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
6537 __ MoveRegister(locs()->out(0).reg(), CTX);
6538 }
6539
6540
6541 LocationSummary* StrictCompareInstr::MakeLocationSummary(Isolate* isolate, 6527 LocationSummary* StrictCompareInstr::MakeLocationSummary(Isolate* isolate,
6542 bool opt) const { 6528 bool opt) const {
6543 const intptr_t kNumInputs = 2; 6529 const intptr_t kNumInputs = 2;
6544 const intptr_t kNumTemps = 0; 6530 const intptr_t kNumTemps = 0;
6545 if (needs_number_check()) { 6531 if (needs_number_check()) {
6546 LocationSummary* locs = new(isolate) LocationSummary( 6532 LocationSummary* locs = new(isolate) LocationSummary(
6547 isolate, kNumInputs, kNumTemps, LocationSummary::kCall); 6533 isolate, kNumInputs, kNumTemps, LocationSummary::kCall);
6548 locs->set_in(0, Location::RegisterLocation(EAX)); 6534 locs->set_in(0, Location::RegisterLocation(EAX));
6549 locs->set_in(1, Location::RegisterLocation(ECX)); 6535 locs->set_in(1, Location::RegisterLocation(ECX));
6550 locs->set_out(0, Location::RegisterLocation(EAX)); 6536 locs->set_out(0, Location::RegisterLocation(EAX));
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
6785 __ movl(EDX, Immediate(kInvalidObjectPointer)); 6771 __ movl(EDX, Immediate(kInvalidObjectPointer));
6786 __ movl(EDX, Immediate(kInvalidObjectPointer)); 6772 __ movl(EDX, Immediate(kInvalidObjectPointer));
6787 #endif 6773 #endif
6788 } 6774 }
6789 6775
6790 } // namespace dart 6776 } // namespace dart
6791 6777
6792 #undef __ 6778 #undef __
6793 6779
6794 #endif // defined TARGET_ARCH_IA32 6780 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_arm64.cc ('k') | runtime/vm/intermediate_language_mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698