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

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

Issue 1013733002: Fix assembling of paddd, psubd instructions on x64. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 9 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 | « no previous file | runtime/vm/assembler_x64_test.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" // NOLINT 5 #include "vm/globals.h" // NOLINT
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/cpu.h" 9 #include "vm/cpu.h"
10 #include "vm/heap.h" 10 #include "vm/heap.h"
(...skipping 704 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 EmitUint8(0xF2); 715 EmitUint8(0xF2);
716 EmitREX_RB(dst, src); 716 EmitREX_RB(dst, src);
717 EmitUint8(0x0F); 717 EmitUint8(0x0F);
718 EmitUint8(0x5E); 718 EmitUint8(0x5E);
719 EmitXmmRegisterOperand(dst & 7, src); 719 EmitXmmRegisterOperand(dst & 7, src);
720 } 720 }
721 721
722 722
723 void Assembler::addpl(XmmRegister dst, XmmRegister src) { 723 void Assembler::addpl(XmmRegister dst, XmmRegister src) {
724 AssemblerBuffer::EnsureCapacity ensured(&buffer_); 724 AssemblerBuffer::EnsureCapacity ensured(&buffer_);
725 EmitUint8(0x66);
725 EmitREX_RB(dst, src); 726 EmitREX_RB(dst, src);
726 EmitUint8(0x66);
727 EmitUint8(0x0F); 727 EmitUint8(0x0F);
728 EmitUint8(0xFE); 728 EmitUint8(0xFE);
729 EmitXmmRegisterOperand(dst, src); 729 EmitXmmRegisterOperand(dst& 7, src);
730 } 730 }
731 731
732 732
733 void Assembler::subpl(XmmRegister dst, XmmRegister src) { 733 void Assembler::subpl(XmmRegister dst, XmmRegister src) {
734 AssemblerBuffer::EnsureCapacity ensured(&buffer_); 734 AssemblerBuffer::EnsureCapacity ensured(&buffer_);
735 EmitUint8(0x66);
735 EmitREX_RB(dst, src); 736 EmitREX_RB(dst, src);
736 EmitUint8(0x66);
737 EmitUint8(0x0F); 737 EmitUint8(0x0F);
738 EmitUint8(0xFA); 738 EmitUint8(0xFA);
739 EmitXmmRegisterOperand(dst, src); 739 EmitXmmRegisterOperand(dst & 7, src);
740 } 740 }
741 741
742 742
743 void Assembler::addps(XmmRegister dst, XmmRegister src) { 743 void Assembler::addps(XmmRegister dst, XmmRegister src) {
744 AssemblerBuffer::EnsureCapacity ensured(&buffer_); 744 AssemblerBuffer::EnsureCapacity ensured(&buffer_);
745 EmitREX_RB(dst, src); 745 EmitREX_RB(dst, src);
746 EmitUint8(0x0F); 746 EmitUint8(0x0F);
747 EmitUint8(0x58); 747 EmitUint8(0x58);
748 EmitXmmRegisterOperand(dst & 7, src); 748 EmitXmmRegisterOperand(dst & 7, src);
749 } 749 }
(...skipping 3145 matching lines...) Expand 10 before | Expand all | Expand 10 after
3895 3895
3896 3896
3897 const char* Assembler::FpuRegisterName(FpuRegister reg) { 3897 const char* Assembler::FpuRegisterName(FpuRegister reg) {
3898 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters)); 3898 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters));
3899 return xmm_reg_names[reg]; 3899 return xmm_reg_names[reg];
3900 } 3900 }
3901 3901
3902 } // namespace dart 3902 } // namespace dart
3903 3903
3904 #endif // defined TARGET_ARCH_X64 3904 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/assembler_x64_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698