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

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

Issue 842263002: Really really fix mac x64 debug build by using more fixed-length encoding and long jumps. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 11 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
« runtime/vm/assembler_x64.cc ('K') | « runtime/vm/assembler_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 (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" 5 #include "vm/globals.h"
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/compiler.h" 9 #include "vm/compiler.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 1088 matching lines...) Expand 10 before | Expand all | Expand 10 after
1099 __ leaq(RCX, FieldAddress(RAX, Instance::NextFieldOffset())); 1099 __ leaq(RCX, FieldAddress(RAX, Instance::NextFieldOffset()));
1100 // Loop until the whole object is initialized. 1100 // Loop until the whole object is initialized.
1101 // RAX: new object (tagged). 1101 // RAX: new object (tagged).
1102 // RBX: next object start. 1102 // RBX: next object start.
1103 // RCX: next word to be initialized. 1103 // RCX: next word to be initialized.
1104 // RDX: new object type arguments (if is_cls_parameterized). 1104 // RDX: new object type arguments (if is_cls_parameterized).
1105 Label init_loop; 1105 Label init_loop;
1106 Label done; 1106 Label done;
1107 __ Bind(&init_loop); 1107 __ Bind(&init_loop);
1108 __ cmpq(RCX, RBX); 1108 __ cmpq(RCX, RBX);
1109 __ j(ABOVE_EQUAL, &done, Assembler::kNearJump); 1109 #if defined(DEBUG)
1110 static const bool kJumpLength = Assembler::kFarJump;
1111 #else
1112 static const bool kJumpLength = Assembler::kNearJump;
1113 #endif // DEBUG
1114 __ j(ABOVE_EQUAL, &done, kJumpLength);
1110 __ InitializeFieldNoBarrier(RAX, Address(RCX, 0), R12); 1115 __ InitializeFieldNoBarrier(RAX, Address(RCX, 0), R12);
1111 __ addq(RCX, Immediate(kWordSize)); 1116 __ addq(RCX, Immediate(kWordSize));
1112 __ jmp(&init_loop, Assembler::kNearJump); 1117 __ jmp(&init_loop, Assembler::kNearJump);
1113 __ Bind(&done); 1118 __ Bind(&done);
1114 } 1119 }
1115 if (is_cls_parameterized) { 1120 if (is_cls_parameterized) {
1116 // RDX: new object type arguments. 1121 // RDX: new object type arguments.
1117 // Set the type arguments in the new object. 1122 // Set the type arguments in the new object.
1118 intptr_t offset = cls.type_arguments_field_offset(); 1123 intptr_t offset = cls.type_arguments_field_offset();
1119 __ InitializeFieldNoBarrier(RAX, FieldAddress(RAX, offset), RDX); 1124 __ InitializeFieldNoBarrier(RAX, FieldAddress(RAX, offset), RDX);
(...skipping 968 matching lines...) Expand 10 before | Expand all | Expand 10 after
2088 2093
2089 __ movq(left, Address(RSP, 2 * kWordSize)); 2094 __ movq(left, Address(RSP, 2 * kWordSize));
2090 __ movq(right, Address(RSP, 1 * kWordSize)); 2095 __ movq(right, Address(RSP, 1 * kWordSize));
2091 GenerateIdenticalWithNumberCheckStub(assembler, left, right); 2096 GenerateIdenticalWithNumberCheckStub(assembler, left, right);
2092 __ ret(); 2097 __ ret();
2093 } 2098 }
2094 2099
2095 } // namespace dart 2100 } // namespace dart
2096 2101
2097 #endif // defined TARGET_ARCH_X64 2102 #endif // defined TARGET_ARCH_X64
OLDNEW
« runtime/vm/assembler_x64.cc ('K') | « runtime/vm/assembler_x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698