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

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

Issue 10453110: Implement optimized unary ops for ia32 as well. Fix a crash in disassembler. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 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_ia32.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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_X64. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64.
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "lib/error.h" 10 #include "lib/error.h"
(...skipping 1400 matching lines...) Expand 10 before | Expand all | Expand 10 after
1411 const Class& double_class = 1411 const Class& double_class =
1412 Class::ZoneHandle(Isolate::Current()->object_store()->double_class()); 1412 Class::ZoneHandle(Isolate::Current()->object_store()->double_class());
1413 const Code& stub = 1413 const Code& stub =
1414 Code::Handle(StubCode::GetAllocationStubForClass(double_class)); 1414 Code::Handle(StubCode::GetAllocationStubForClass(double_class));
1415 const ExternalLabel label(double_class.ToCString(), stub.EntryPoint()); 1415 const ExternalLabel label(double_class.ToCString(), stub.EntryPoint());
1416 __ pushq(value); 1416 __ pushq(value);
1417 compiler->GenerateCall(instance_call()->token_index(), 1417 compiler->GenerateCall(instance_call()->token_index(),
1418 instance_call()->try_index(), 1418 instance_call()->try_index(),
1419 &label, 1419 &label,
1420 PcDescriptors::kOther); 1420 PcDescriptors::kOther);
1421 // Result is in EAX. 1421 // Result is in RAX.
1422 ASSERT(result != temp);
1422 __ movq(result, RAX); 1423 __ movq(result, RAX);
1423 __ popq(temp); 1424 __ popq(temp);
1424 __ movsd(XMM0, FieldAddress(temp, Double::value_offset())); 1425 __ movsd(XMM0, FieldAddress(temp, Double::value_offset()));
1425 __ DoubleNegate(XMM0); 1426 __ DoubleNegate(XMM0);
1426 __ movsd(FieldAddress(result, Double::value_offset()), XMM0); 1427 __ movsd(FieldAddress(result, Double::value_offset()), XMM0);
1427 } else { 1428 } else {
1428 UNREACHABLE(); 1429 UNREACHABLE();
1429 } 1430 }
1430 } 1431 }
1431 1432
1432 } // namespace dart 1433 } // namespace dart
1433 1434
1434 #undef __ 1435 #undef __
1435 1436
1436 #endif // defined TARGET_ARCH_X64 1437 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698