Explorar el Código

bugfix gnu-assembler platform i386 vcvtsi2sd,vcvtsi2ss,vcvtusi2sd,vcvtusi2ss

git-svn-id: branches/tg74/avx512-0037785@47441 -
tg74 hace 4 años
padre
commit
aef337e67c

+ 4 - 4
compiler/i386/i386atts.inc

@@ -789,8 +789,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
@@ -1222,8 +1222,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,

+ 1 - 1
compiler/i386/i386nop.inc

@@ -1,2 +1,2 @@
 { don't edit, this file is generated from x86ins.dat }
 { don't edit, this file is generated from x86ins.dat }
-4172;
+4168;

+ 41 - 20
compiler/i386/i386tab.inc

@@ -10839,30 +10839,44 @@
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #220#232#242#248#1#42#61#80;
     code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #220#232#242#248#1#42#61#80;
     code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
+  ),
+  (
+    opcode  : A_VCVTSI2SD;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #220#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #219#232#242#248#1#42#61#80;
     code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #219#232#242#248#1#42#61#80;
     code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
+  ),
+  (
+    opcode  : A_VCVTSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #219#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSS2SD;
     opcode  : A_VCVTSS2SD;
@@ -22340,38 +22354,45 @@
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
-    code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #220#232#248#1#123#61#80;
+    flags   : [if_avx512]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
-    code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
+    code    : #220#232#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
-    code    : #220#232#248#1#123#61#80;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #220#232#234#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits64,ot_none);
-    code    : #219#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #219#232#248#1#123#61#80;
+    flags   : [if_avx512]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #219#232#248#1#123#61#80;
     code    : #219#232#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
+  (
+    opcode  : A_VCVTUSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #219#232#234#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
+  ),
   (
   (
     opcode  : A_VDBPSADBW;
     opcode  : A_VDBPSADBW;
     ops     : 4;
     ops     : 4;

+ 4 - 4
compiler/i8086/i8086atts.inc

@@ -789,8 +789,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
@@ -1236,8 +1236,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,

+ 1 - 1
compiler/i8086/i8086nop.inc

@@ -1,2 +1,2 @@
 { don't edit, this file is generated from x86ins.dat }
 { don't edit, this file is generated from x86ins.dat }
-4204;
+4200;

+ 41 - 20
compiler/i8086/i8086tab.inc

@@ -10867,30 +10867,44 @@
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #220#232#242#248#1#42#61#80;
     code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #220#232#242#248#1#42#61#80;
     code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
+  ),
+  (
+    opcode  : A_VCVTSI2SD;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #220#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #219#232#242#248#1#42#61#80;
     code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #219#232#242#248#1#42#61#80;
     code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
+  ),
+  (
+    opcode  : A_VCVTSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #219#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSS2SD;
     opcode  : A_VCVTSS2SD;
@@ -22564,38 +22578,45 @@
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
-    code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #220#232#248#1#123#61#80;
+    flags   : [if_avx512]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
-    code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
+    code    : #220#232#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
-    code    : #220#232#248#1#123#61#80;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #220#232#234#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits64,ot_none);
-    code    : #219#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #219#232#248#1#123#61#80;
+    flags   : [if_avx512]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #219#232#248#1#123#61#80;
     code    : #219#232#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
+  (
+    opcode  : A_VCVTUSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #219#232#234#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
+  ),
   (
   (
     opcode  : A_VDBPSADBW;
     opcode  : A_VDBPSADBW;
     ops     : 4;
     ops     : 4;

+ 5 - 0
compiler/utils/mkx86ins.pp

@@ -325,6 +325,11 @@ begin
                     dec(attopcode[0]);
                     dec(attopcode[0]);
                     attsuffix:='attsufMMX';
                     attsuffix:='attsufMMX';
                   end;
                   end;
+                'S' :
+		  begin
+                    dec(attopcode[0]);
+                    attsuffix:='attsufMMS';
+		  end;	  
                 'X' :
                 'X' :
                   begin
                   begin
                     dec(attopcode[0]);
                     dec(attopcode[0]);

+ 1 - 1
compiler/x86/itcpugas.pas

@@ -29,7 +29,7 @@ interface
       cgbase,cpubase;
       cgbase,cpubase;
 
 
     type
     type
-      TAttSuffix = (AttSufNONE,AttSufINT,AttSufFPU,AttSufFPUint,AttSufINTdual,AttSufMM,AttSufMMX);
+      TAttSuffix = (AttSufNONE,AttSufINT,AttSufFPU,AttSufFPUint,AttSufINTdual,AttSufMM,AttSufMMX,AttSufMMS);
 
 
     const
     const
       { include mnemonic strings }
       { include mnemonic strings }

+ 12 - 3
compiler/x86/rax86.pas

@@ -239,7 +239,7 @@ begin
           ;
           ;
       end;
       end;
     end
     end
-  else if gas_needsuffix[opcode] in [AttSufMM, AttSufMMX] then
+  else if gas_needsuffix[opcode] in [AttSufMM, AttSufMMX, AttSufMMS] then
   begin
   begin
     if (opr.typ=OPR_Reference) then
     if (opr.typ=OPR_Reference) then
     begin
     begin
@@ -1469,7 +1469,16 @@ procedure Tx86Instruction.SetInstructionOpsize;
                    result := true;
                    result := true;
                  end;
                  end;
             end;
             end;
-          end;
+          end
+	  else if gas_needsuffix[opcode] = AttSufMMS then
+ 	  begin
+ 	    // spezial handling - use source operand
+            if ops > 0 then
+	    begin	    
+              opsize:=tx86operand(operands[1]).opsize;
+              result := true;
+            end;  
+	  end;	  
         end;
         end;
       end;
       end;
     end;
     end;
@@ -1567,7 +1576,7 @@ begin
             //A_VCVTSI2SD,
             //A_VCVTSI2SD,
             //A_VCVTUSI2SS,
             //A_VCVTUSI2SS,
             //A_VCVTUSI2SD:
             //A_VCVTUSI2SD:
-            //  iops:=tx86operand(operands[1]).opsize;
+            //  opsize:=tx86operand(operands[1]).opsize;
             //A_VFPCLASSPD,
             //A_VFPCLASSPD,
             //A_VFPCLASSPS:
             //A_VFPCLASSPS:
             //  iops:=tx86operand(operands[2]).opsize;
             //  iops:=tx86operand(operands[2]).opsize;

+ 1 - 1
compiler/x86/rax86att.pas

@@ -1041,7 +1041,7 @@ Implementation
                        actopsize:=att_sizefpusuffix[sufidx]
                        actopsize:=att_sizefpusuffix[sufidx]
                       else if gas_needsuffix[actopcode]=attsufFPUint then
                       else if gas_needsuffix[actopcode]=attsufFPUint then
                        actopsize:=att_sizefpuintsuffix[sufidx]
                        actopsize:=att_sizefpuintsuffix[sufidx]
-                      else if gas_needsuffix[actopcode]=attsufMM then
+                      else if gas_needsuffix[actopcode]in[attsufMM,attsufMMS] then
                        actopsize:=att_sizemmsuffix[sufidx]
                        actopsize:=att_sizemmsuffix[sufidx]
                       else if gas_needsuffix[actopcode]=attsufMMX then
                       else if gas_needsuffix[actopcode]=attsufMMX then
                        actopsize:=att_sizemmXsuffix[sufidx]
                        actopsize:=att_sizemmXsuffix[sufidx]

+ 30 - 17
compiler/x86/x86ins.dat

@@ -4243,19 +4243,26 @@ reg64,xmmreg_er                           \334\350\352\362\363\370\1\x2D\110
 xmmreg_mz,xmmreg,mem64                    \334\350\352\362\370\1\x5A\75\120         AVX,SANDYBRIDGE,T1S
 xmmreg_mz,xmmreg,mem64                    \334\350\352\362\370\1\x5A\75\120         AVX,SANDYBRIDGE,T1S
 xmmreg_mz,xmmreg,xmmreg_er                \334\350\352\362\370\1\x5A\75\120         AVX,SANDYBRIDGE
 xmmreg_mz,xmmreg,xmmreg_er                \334\350\352\362\370\1\x5A\75\120         AVX,SANDYBRIDGE
 
 
-[VCVTSI2SD,vcvtsi2sdX]
+
+
+; special handling - gas suffix "S" =>> instructions-opsize = source-operand
+[VCVTSI2SD,vcvtsi2sdS]
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
-xmmreg,xmmreg,reg32                       \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD
-xmmreg,xmmreg,mem32                       \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD,T1S
+;xmmreg,xmmreg,reg32                       \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD
+;xmmreg,xmmreg,mem32                       \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD,T1S
+;xmmreg,xmmreg_er,reg64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64
+;xmmreg,xmmreg_er,mem64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64,T1S
+xmmreg,xmmreg_er,reg32                    \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE
 xmmreg,xmmreg_er,reg64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64
 xmmreg,xmmreg_er,reg64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64
-xmmreg,xmmreg_er,mem64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64,T1S
+xmmreg,xmmreg_er,mem32                    \334\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,T1S
+xmmreg,xmmreg_er,mem64                    \334\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,T1S
 
 
-[VCVTSI2SS,vcvtsi2ssX]
+[VCVTSI2SS,vcvtsi2ssS]
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
-xmmreg,xmmreg,reg32                       \333\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD
-xmmreg,xmmreg,mem32                       \333\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,SD,T1S
+xmmreg,xmmreg_er,reg32                    \333\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE
 xmmreg,xmmreg_er,reg64                    \333\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64
 xmmreg,xmmreg_er,reg64                    \333\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64
-xmmreg,xmmreg_er,mem64                    \333\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,X86_64,T1S
+xmmreg,xmmreg_er,mem32                    \333\350\362\370\1\x2A\75\120             AVX,SANDYBRIDGE,T1S
+xmmreg,xmmreg_er,mem64                    \333\350\352\362\363\370\1\x2A\75\120     AVX,SANDYBRIDGE,T1S
 
 
 [VCVTSS2SD]
 [VCVTSS2SD]
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
 (Ch_Wop3, Ch_Rop2, Ch_Rop1)
@@ -7493,16 +7500,22 @@ ymmreg_mz,mem512                          \334\350\351\352\370\1\x7A\110
 ymmreg_mz,bmem64                          \334\350\351\352\370\1\x7A\110            AVX512,BCST8,TFV
 ymmreg_mz,bmem64                          \334\350\351\352\370\1\x7A\110            AVX512,BCST8,TFV
 ymmreg_mz,zmmreg_er                       \334\350\351\352\370\1\x7A\110            AVX512
 ymmreg_mz,zmmreg_er                       \334\350\351\352\370\1\x7A\110            AVX512
 
 
-[VCVTUSI2SD,vcvtusi2sdX]
-(Ch_Wop2, Ch_Rop1)
-xmmreg,xmmreg_er,mem64                     \334\350\352\370\1\x7B\75\120               AVX512,T1S
-xmmreg,xmmreg_er,reg64                     \334\350\352\370\1\x7B\75\120               AVX512
-xmmreg,xmmreg_er,rm32                     \334\350\370\1\x7B\75\120                    AVX512,T1S
+; special handling - gas suffix "S" =>> instructions-opsize = source-operand
+[VCVTUSI2SD,vcvtusi2sdS]
+(Ch_All)
+xmmreg,xmmreg_er,reg32                    \334\350\370\1\x7B\75\120                 AVX512
+xmmreg,xmmreg_er,reg64                    \334\350\352\370\1\x7B\75\120             AVX512,X86_64
+xmmreg,xmmreg_er,mem32                    \334\350\370\1\x7B\75\120                 AVX512,T1S
+xmmreg,xmmreg_er,mem64                    \334\350\352\370\1\x7B\75\120             AVX512,T1S
 
 
-[VCVTUSI2SS,vcvtusi2ssX]
-(Ch_Wop2, Ch_Rop1)
-xmmreg,xmmreg_er,rm64                     \333\350\352\370\1\x7B\75\120                AVX512,T1S
-xmmreg,xmmreg_er,rm32                     \333\350\370\1\x7B\75\120                    AVX512,T1S
+
+; special handling - gas suffix "S" =>> instructions-opsize = source-operand
+[VCVTUSI2SS,vcvtusi2ssS]
+(Ch_All)
+xmmreg,xmmreg_er,reg32                    \333\350\370\1\x7B\75\120                 AVX512
+xmmreg,xmmreg_er,reg64                    \333\350\352\370\1\x7B\75\120             AVX512,X86_64
+xmmreg,xmmreg_er,mem32                    \333\350\370\1\x7B\75\120                 AVX512,T1S
+xmmreg,xmmreg_er,mem64                    \333\350\352\370\1\x7B\75\120             AVX512,T1S
 
 
 [VDBPSADBW]
 [VDBPSADBW]
 (Ch_All)
 (Ch_All)

+ 4 - 4
compiler/x86_64/x8664ats.inc

@@ -785,8 +785,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
@@ -1218,8 +1218,8 @@ attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufMMX,
 attsufMMX,
-attsufINT,
-attsufINT,
+attsufMMS,
+attsufMMS,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,
 attsufNONE,

+ 1 - 1
compiler/x86_64/x8664nop.inc

@@ -1,2 +1,2 @@
 { don't edit, this file is generated from x86ins.dat }
 { don't edit, this file is generated from x86ins.dat }
-4236;
+4232;

+ 47 - 26
compiler/x86_64/x8664tab.inc

@@ -11140,58 +11140,58 @@
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #220#232#242#248#1#42#61#80;
     code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
-    code    : #220#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
+    code    : #220#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_x86_64]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
-    code    : #220#232#234#242#243#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_x86_64]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
+    code    : #220#232#242#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SD;
     opcode  : A_VCVTSI2SD;
     ops     : 3;
     ops     : 3;
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
     code    : #220#232#234#242#243#248#1#42#61#80;
     code    : #220#232#234#242#243#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_x86_64,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_reg32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
     code    : #219#232#242#248#1#42#61#80;
     code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd]
+    flags   : [if_avx,if_sandybridge]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg,ot_memory or ot_bits32,ot_none);
-    code    : #219#232#242#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_sd,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
+    code    : #219#232#234#242#243#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_x86_64]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
-    code    : #219#232#234#242#243#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_x86_64]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
+    code    : #219#232#242#248#1#42#61#80;
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSI2SS;
     opcode  : A_VCVTSI2SS;
     ops     : 3;
     ops     : 3;
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
     code    : #219#232#234#242#243#248#1#42#61#80;
     code    : #219#232#234#242#243#248#1#42#61#80;
-    flags   : [if_avx,if_sandybridge,if_x86_64,if_t1s]
+    flags   : [if_avx,if_sandybridge,if_t1s]
   ),
   ),
   (
   (
     opcode  : A_VCVTSS2SD;
     opcode  : A_VCVTSS2SD;
@@ -22788,38 +22788,59 @@
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
-    code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #220#232#248#1#123#61#80;
+    flags   : [if_avx512]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
     optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
     code    : #220#232#234#248#1#123#61#80;
     code    : #220#232#234#248#1#123#61#80;
-    flags   : [if_avx512]
+    flags   : [if_avx512,if_x86_64]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SD;
     opcode  : A_VCVTUSI2SD;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #220#232#248#1#123#61#80;
     code    : #220#232#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
+  (
+    opcode  : A_VCVTUSI2SD;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #220#232#234#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
+  ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits64,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg32,ot_none);
+    code    : #219#232#248#1#123#61#80;
+    flags   : [if_avx512]
+  ),
+  (
+    opcode  : A_VCVTUSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_reg64,ot_none);
     code    : #219#232#234#248#1#123#61#80;
     code    : #219#232#234#248#1#123#61#80;
-    flags   : [if_avx512,if_t1s]
+    flags   : [if_avx512,if_x86_64]
   ),
   ),
   (
   (
     opcode  : A_VCVTUSI2SS;
     opcode  : A_VCVTUSI2SS;
     ops     : 3;
     ops     : 3;
-    optypes : (ot_xmmreg,ot_xmmreg_er,ot_rm_gpr or ot_bits32,ot_none);
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits32,ot_none);
     code    : #219#232#248#1#123#61#80;
     code    : #219#232#248#1#123#61#80;
     flags   : [if_avx512,if_t1s]
     flags   : [if_avx512,if_t1s]
   ),
   ),
+  (
+    opcode  : A_VCVTUSI2SS;
+    ops     : 3;
+    optypes : (ot_xmmreg,ot_xmmreg_er,ot_memory or ot_bits64,ot_none);
+    code    : #219#232#234#248#1#123#61#80;
+    flags   : [if_avx512,if_t1s]
+  ),
   (
   (
     opcode  : A_VDBPSADBW;
     opcode  : A_VDBPSADBW;
     ops     : 4;
     ops     : 4;

+ 8 - 4
tests/utils/avx/avxopcodes.pas

@@ -1923,10 +1923,14 @@ begin
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,mem512,,');
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,mem512,,');
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,8b64,,');
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,8b64,,');
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,zmmreg_er,,');
   FOpCodeList.Add('vcvtuqq2ps,1,1,1,ymmreg_mz,zmmreg_er,,');
-  FOpCodeList.Add('vcvtusi2sd,1,1,1,xmmreg,xmmreg_er,rm32,');
-  FOpCodeList.Add('vcvtusi2sd,1,1,1,xmmreg,xmmreg_er,rm64,');
-  FOpCodeList.Add('vcvtusi2ss,1,1,1,xmmreg,xmmreg_er,rm32,');
-  FOpCodeList.Add('vcvtusi2ss,1,1,1,xmmreg,xmmreg_er,rm64,');
+  FOpCodeList.Add('vcvtusi2sd,1,1,1,xmmreg,xmmreg_er,reg32,');
+  FOpCodeList.Add('vcvtusi2sd,1,1,1,xmmreg,xmmreg_er,mem32,');
+  FOpCodeList.Add('vcvtusi2sd,0,1,1,xmmreg,xmmreg_er,reg64,');
+  FOpCodeList.Add('vcvtusi2sd,0,1,1,xmmreg,xmmreg_er,mem64,');
+  FOpCodeList.Add('vcvtusi2ss,1,1,1,xmmreg,xmmreg_er,reg32,');
+  FOpCodeList.Add('vcvtusi2ss,1,1,1,xmmreg,xmmreg_er,mem32,');
+  FOpCodeList.Add('vcvtusi2ss,0,1,1,xmmreg,xmmreg_er,reg64,');
+  FOpCodeList.Add('vcvtusi2ss,0,1,1,xmmreg,xmmreg_er,mem64,');
   FOpCodeList.Add('vdbpsadbw,1,1,1,xmmreg_mz,xmmreg,xmmrm,imm8');
   FOpCodeList.Add('vdbpsadbw,1,1,1,xmmreg_mz,xmmreg,xmmrm,imm8');
   FOpCodeList.Add('vdbpsadbw,1,1,1,ymmreg_mz,ymmreg,ymmrm,imm8');
   FOpCodeList.Add('vdbpsadbw,1,1,1,ymmreg_mz,ymmreg,ymmrm,imm8');
   FOpCodeList.Add('vdbpsadbw,1,1,1,zmmreg_mz,zmmreg,zmmrm,imm8');
   FOpCodeList.Add('vdbpsadbw,1,1,1,zmmreg_mz,zmmreg,zmmrm,imm8');