mirror of
https://github.com/reactos/reactos.git
synced 2026-07-06 06:44:20 +08:00
41 lines
1.9 KiB
C
41 lines
1.9 KiB
C
|
|
#include "../../misc.h"
|
|
|
|
|
|
/* example how setup a opcode, this opcode is 16bit long (taken from M68K)
|
|
* 0 and 1 mean normal bit, 2 mean mask bit the bit that are determent diffent
|
|
* thing in the opcode, example which reg so on, it can be etither 0 or 1 in
|
|
* the opcode. but a opcode have also normal bit that is always been set to
|
|
* same. thuse bit are always 0 or 1
|
|
*/
|
|
|
|
/* FIXME RA should be 0 in stwu */
|
|
CPU_BYTE cpuPPCInit_Blr[32] = {0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,0,0,1,1,1,0};
|
|
CPU_BYTE cpuPPCInit_Li[32] = {2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,0,0,0,0,0,0,1,1,1,0,2,2};
|
|
CPU_BYTE cpuPPCInit_stw[32] = {2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,1,0,0,2,2};
|
|
CPU_BYTE cpuPPCInit_stwu[32] = {2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,1,0,1,2,2};
|
|
CPU_BYTE cpuPPCInit_mr[32] = {0,1,1,1,1,0,0,0,0,0,0,0,1,0,1,1,2,2,2,2,2,2,2,2,0,1,1,1,1,1,2,2};
|
|
|
|
|
|
/*
|
|
CPU_BYTE cpuPPCInit_stw[32] = {2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,1,0,0,2,2};
|
|
CPU_BYTE cpuPPCInit_stwu[32] = {2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,0,0,1,0,1,2,2};
|
|
CPU_BYTE cpuPPCInit_mr[32] = {0,1,1,1,1,0,0,0,0,0,0,0,1,0,1,1,2,2,2,2,2,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