Diff for /np2/i386c/ia32/groups.c between versions 1.2 and 1.7

version 1.2, 2003/12/11 15:06:50 version 1.7, 2005/03/12 12:32:54
Line 12 Line 12
  * 2. Redistributions in binary form must reproduce the above copyright   * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the   *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.   *    documentation and/or other materials provided with the distribution.
  * 3. The name of the author may not be used to endorse or promote products  
  *    derived from this software without specific prior written permission.  
  *   *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR   * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES   * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
Line 38 Line 36
 void  void
 Grp1_EbIb(void)  Grp1_EbIb(void)
 {  {
         BYTE *out;          UINT8 *out;
         DWORD op, madr, src;          UINT32 madr;
           UINT32 op, src;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
         if (op >= 0xc0) {          if (op >= 0xc0) {
                 CPU_WORKCLOCK(3);                  CPU_WORKCLOCK(2);
                 out = reg8_b20[op];                  out = reg8_b20[op];
                 GET_PCBYTE(src);                  GET_PCBYTE(src);
                 (*insttable_G1EbIb[idx])(out, src);                  (*insttable_G1EbIb[idx])(out, src);
Line 60  Grp1_EbIb(void) Line 59  Grp1_EbIb(void)
 void  void
 Grp1_EwIb(void)  Grp1_EwIb(void)
 {  {
         WORD *out;          UINT16 *out;
         DWORD op, madr, src;          UINT32 madr, src;
           UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
         if (op >= 0xc0) {          if (op >= 0xc0) {
                 CPU_WORKCLOCK(3);                  CPU_WORKCLOCK(2);
                 out = reg16_b20[op];                  out = reg16_b20[op];
                 GET_PCBYTES(src);                  GET_PCBYTES(src);
                 (*insttable_G1EwIx[idx])(out, src);                  (*insttable_G1EwIx[idx])(out, src);
Line 82  Grp1_EwIb(void) Line 82  Grp1_EwIb(void)
 void  void
 Grp1_EdIb(void)  Grp1_EdIb(void)
 {  {
         DWORD *out;          UINT32 *out;
         DWORD op, madr, src;          UINT32 madr, src;
           UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
         if (op >= 0xc0) {          if (op >= 0xc0) {
                 CPU_WORKCLOCK(3);                  CPU_WORKCLOCK(2);
                 out = reg32_b20[op];                  out = reg32_b20[op];
                 GET_PCBYTESD(src);                  GET_PCBYTESD(src);
                 (*insttable_G1EdIx[idx])(out, src);                  (*insttable_G1EdIx[idx])(out, src);
Line 104  Grp1_EdIb(void) Line 105  Grp1_EdIb(void)
 void  void
 Grp1_EwIw(void)  Grp1_EwIw(void)
 {  {
         WORD *out;          UINT16 *out;
         DWORD op, madr, src;          UINT32 madr, src;
           UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
         if (op >= 0xc0) {          if (op >= 0xc0) {
                 CPU_WORKCLOCK(3);                  CPU_WORKCLOCK(2);
                 out = reg16_b20[op];                  out = reg16_b20[op];
                 GET_PCWORD(src);                  GET_PCWORD(src);
                 (*insttable_G1EwIx[idx])(out, src);                  (*insttable_G1EwIx[idx])(out, src);
Line 126  Grp1_EwIw(void) Line 128  Grp1_EwIw(void)
 void  void
 Grp1_EdId(void)  Grp1_EdId(void)
 {  {
         DWORD *out;          UINT32 *out;
         DWORD op, madr, src;          UINT32 madr, src;
           UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
         if (op >= 0xc0) {          if (op >= 0xc0) {
                 CPU_WORKCLOCK(3);                  CPU_WORKCLOCK(2);
                 out = reg32_b20[op];                  out = reg32_b20[op];
                 GET_PCDWORD(src);                  GET_PCDWORD(src);
                 (*insttable_G1EdIx[idx])(out, src);                  (*insttable_G1EdIx[idx])(out, src);
Line 150  Grp1_EdId(void) Line 153  Grp1_EdId(void)
 void  void
 Grp2_EbIb(void)  Grp2_EbIb(void)
 {  {
         BYTE *out;          UINT8 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 175  Grp2_EbIb(void) Line 179  Grp2_EbIb(void)
 void  void
 Grp2_EwIb(void)  Grp2_EwIb(void)
 {  {
         WORD *out;          UINT16 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 200  Grp2_EwIb(void) Line 205  Grp2_EwIb(void)
 void  void
 Grp2_EdIb(void)  Grp2_EdIb(void)
 {  {
         DWORD *out;          UINT32 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 225  Grp2_EdIb(void) Line 231  Grp2_EdIb(void)
 void  void
 Grp2_Eb(void)  Grp2_Eb(void)
 {  {
         DWORD op;          UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
Line 242  Grp2_Eb(void) Line 248  Grp2_Eb(void)
 void  void
 Grp2_Ew(void)  Grp2_Ew(void)
 {  {
         DWORD op;          UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
Line 259  Grp2_Ew(void) Line 265  Grp2_Ew(void)
 void  void
 Grp2_Ed(void)  Grp2_Ed(void)
 {  {
         DWORD op;          UINT32 op;
         int idx;          int idx;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
Line 276  Grp2_Ed(void) Line 282  Grp2_Ed(void)
 void  void
 Grp2_EbCL(void)  Grp2_EbCL(void)
 {  {
         BYTE *out;          UINT8 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 287  Grp2_EbCL(void) Line 294  Grp2_EbCL(void)
                 CPU_WORKCLOCK(5);                  CPU_WORKCLOCK(5);
                 out = reg8_b20[op];                  out = reg8_b20[op];
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EbCL[idx])(out, cl);                  (*insttable_G2EbCL[idx])(out, cl);
         } else {          } else {
                 CPU_WORKCLOCK(8);                  CPU_WORKCLOCK(8);
                 madr = calc_ea_dst(op);                  madr = calc_ea_dst(op);
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EbCL_ext[idx])(madr, cl);                  (*insttable_G2EbCL_ext[idx])(madr, cl);
         }          }
 }  }
Line 301  Grp2_EbCL(void) Line 310  Grp2_EbCL(void)
 void  void
 Grp2_EwCL(void)  Grp2_EwCL(void)
 {  {
         WORD *out;          UINT16 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 312  Grp2_EwCL(void) Line 322  Grp2_EwCL(void)
                 CPU_WORKCLOCK(5);                  CPU_WORKCLOCK(5);
                 out = reg16_b20[op];                  out = reg16_b20[op];
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EwCL[idx])(out, cl);                  (*insttable_G2EwCL[idx])(out, cl);
         } else {          } else {
                 CPU_WORKCLOCK(8);                  CPU_WORKCLOCK(8);
                 madr = calc_ea_dst(op);                  madr = calc_ea_dst(op);
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EwCL_ext[idx])(madr, cl);                  (*insttable_G2EwCL_ext[idx])(madr, cl);
         }          }
 }  }
Line 326  Grp2_EwCL(void) Line 338  Grp2_EwCL(void)
 void  void
 Grp2_EdCL(void)  Grp2_EdCL(void)
 {  {
         DWORD *out;          UINT32 *out;
         DWORD op, madr;          UINT32 madr;
           UINT32 op;
           UINT32 cl;
         int idx;          int idx;
         BYTE  cl;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         idx = (op >> 3) & 7;          idx = (op >> 3) & 7;
Line 337  Grp2_EdCL(void) Line 350  Grp2_EdCL(void)
                 CPU_WORKCLOCK(5);                  CPU_WORKCLOCK(5);
                 out = reg32_b20[op];                  out = reg32_b20[op];
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EdCL[idx])(out, cl);                  (*insttable_G2EdCL[idx])(out, cl);
         } else {          } else {
                 CPU_WORKCLOCK(8);                  CPU_WORKCLOCK(8);
                 madr = calc_ea_dst(op);                  madr = calc_ea_dst(op);
                 cl = CPU_CL;                  cl = CPU_CL;
                 CPU_WORKCLOCK(cl & 0x1f);                  cl &= 0x1f;
                   CPU_WORKCLOCK(cl);
                 (*insttable_G2EdCL_ext[idx])(madr, cl);                  (*insttable_G2EdCL_ext[idx])(madr, cl);
         }          }
 }  }
Line 353  Grp2_EdCL(void) Line 368  Grp2_EdCL(void)
 void  void
 Grp3_Eb(void)  Grp3_Eb(void)
 {  {
           UINT32 op;
         DWORD op;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G3Eb[(op >> 3) & 7])(op);          (*insttable_G3Eb[(op >> 3) & 7])(op);
Line 363  Grp3_Eb(void) Line 377  Grp3_Eb(void)
 void  void
 Grp3_Ew(void)  Grp3_Ew(void)
 {  {
           UINT32 op;
         DWORD op;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G3Ew[(op >> 3) & 7])(op);          (*insttable_G3Ew[(op >> 3) & 7])(op);
Line 373  Grp3_Ew(void) Line 386  Grp3_Ew(void)
 void  void
 Grp3_Ed(void)  Grp3_Ed(void)
 {  {
           UINT32 op;
         DWORD op;  
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G3Ed[(op >> 3) & 7])(op);          (*insttable_G3Ed[(op >> 3) & 7])(op);
Line 385  Grp3_Ed(void) Line 397  Grp3_Ed(void)
 void  void
 Grp4(void)  Grp4(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G4[(op >> 3) & 7])(op);          (*insttable_G4[(op >> 3) & 7])(op);
Line 396  Grp4(void) Line 408  Grp4(void)
 void  void
 Grp5_Ew(void)  Grp5_Ew(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G5Ew[(op >> 3) & 7])(op);          (*insttable_G5Ew[(op >> 3) & 7])(op);
Line 405  Grp5_Ew(void) Line 417  Grp5_Ew(void)
 void  void
 Grp5_Ed(void)  Grp5_Ed(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G5Ed[(op >> 3) & 7])(op);          (*insttable_G5Ed[(op >> 3) & 7])(op);
Line 414  Grp5_Ed(void) Line 426  Grp5_Ed(void)
   
 /* group 6 */  /* group 6 */
 void  void
 Grp6_16(void)  Grp6(void)
 {  
         DWORD op;  
   
         GET_PCBYTE(op);  
         (*insttable_G6_16[(op >> 3) & 7])(op);  
 }  
   
 void  
 Grp6_32(void)  
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G6_32[(op >> 3) & 7])(op);          (*insttable_G6[(op >> 3) & 7])(op);
 }  }
   
   
 /* group 7 */  /* group 7 */
 void  void
 Grp7_16(void)  Grp7(void)
 {  
         DWORD op;  
   
         GET_PCBYTE(op);  
         (*insttable_G7_16[(op >> 3) & 7])(op);  
 }  
   
 void  
 Grp7_32(void)  
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G7_32[(op >> 3) & 7])(op);          (*insttable_G7[(op >> 3) & 7])(op);
 }  }
   
   
Line 456  Grp7_32(void) Line 450  Grp7_32(void)
 void  void
 Grp8_EwIb(void)  Grp8_EwIb(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G8EwIb[(op >> 3) & 7])(op);          (*insttable_G8EwIb[(op >> 3) & 7])(op);
Line 465  Grp8_EwIb(void) Line 459  Grp8_EwIb(void)
 void  void
 Grp8_EdIb(void)  Grp8_EdIb(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G8EdIb[(op >> 3) & 7])(op);          (*insttable_G8EdIb[(op >> 3) & 7])(op);
Line 476  Grp8_EdIb(void) Line 470  Grp8_EdIb(void)
 void  void
 Grp9(void)  Grp9(void)
 {  {
         DWORD op;          UINT32 op;
   
         GET_PCBYTE(op);          GET_PCBYTE(op);
         (*insttable_G9[(op >> 3) & 7])(op);          (*insttable_G9[(op >> 3) & 7])(op);

Removed from v.1.2  
changed lines
  Added in v.1.7


RetroPC.NET-CVS <cvs@retropc.net>