Permalink
Browse files

- Fixed Movss

  • Loading branch information...
1 parent a78ee62 commit 983010016734f47a86f543b2037a89e416c284d7 @tgiphil tgiphil committed Sep 25, 2016
Showing with 7 additions and 1 deletion.
  1. +3 −0 Scripts/Readme.md
  2. +4 −1 Source/Mosa.Platform.x86/Instructions/MovssStore.cs
View
@@ -0,0 +1,3 @@
+This directory contains useful scripts for compiling and using the MOSA tools.
+
+**** INCOMPLETE ***
@@ -56,7 +56,10 @@ private static void MovssRegToMemory(InstructionNode node, MachineCodeEmitter em
.AppendNibble(Bits.b1111) // 4:opcode
.AppendNibble(Bits.b0001) // 4:opcode
.AppendNibble(Bits.b0001) // 4:opcode
- .ModRegRMSIBDisplacement(true, node.Operand1, node.Operand3, node.Operand2) // Mod-Reg-RM-?SIB-?Displacement
+
+ // This opcode has a directionality bit, and it is set to 0
+ // This means we must swap around operand1 and operand3
+ .ModRegRMSIBDisplacement(true, node.Operand3, node.Operand1, node.Operand2) // Mod-Reg-RM-?SIB-?Displacement
.AppendConditionalIntegerValue(node.Operand1.IsLinkerResolved, 0); // 32:memory
if (node.Operand1.IsLinkerResolved)

0 comments on commit 9830100

Please sign in to comment.