DOSBox-X
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines
src/cpu/modrm.h
00001 /*
00002  *  Copyright (C) 2002-2013  The DOSBox Team
00003  *
00004  *  This program is free software; you can redistribute it and/or modify
00005  *  it under the terms of the GNU General Public License as published by
00006  *  the Free Software Foundation; either version 2 of the License, or
00007  *  (at your option) any later version.
00008  *
00009  *  This program is distributed in the hope that it will be useful,
00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  *  GNU General Public License for more details.
00013  *
00014  *  You should have received a copy of the GNU General Public License
00015  *  along with this program; if not, write to the Free Software
00016  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00017  */
00018 
00019 extern Bit8u  * lookupRMregb[];
00020 extern Bit16u * lookupRMregw[];
00021 extern Bit32u * lookupRMregd[];
00022 extern Bit8u  * lookupRMEAregb[256];
00023 extern Bit16u * lookupRMEAregw[256];
00024 extern Bit32u * lookupRMEAregd[256];
00025 
00026 #define GetRM                                                                                           \
00027         Bit8u rm=Fetchb();
00028 
00029 #define Getrb                                                                                           \
00030         Bit8u * rmrb;                                                                                   \
00031         rmrb=lookupRMregb[rm];                  
00032         
00033 #define Getrw                                                                                           \
00034         Bit16u * rmrw;                                                                                  \
00035         rmrw=lookupRMregw[rm];                  
00036 
00037 #define Getrd                                                                                           \
00038         Bit32u * rmrd;                                                                                  \
00039         rmrd=lookupRMregd[rm];                  
00040 
00041 
00042 #define GetRMrb                                                                                         \
00043         GetRM;                                                                                                  \
00044         Getrb;                                                                                                  
00045 
00046 #define GetRMrw                                                                                         \
00047         GetRM;                                                                                                  \
00048         Getrw;                                                                                                  
00049 
00050 #define GetRMrd                                                                                         \
00051         GetRM;                                                                                                  \
00052         Getrd;                                                                                                  
00053 
00054 
00055 #define GetEArb                                                                                         \
00056         Bit8u * earb=lookupRMEAregb[rm];
00057 
00058 #define GetEArw                                                                                         \
00059         Bit16u * earw=lookupRMEAregw[rm];
00060 
00061 #define GetEArd                                                                                         \
00062         Bit32u * eard=lookupRMEAregd[rm];
00063 
00064