mirror of
https://github.com/cc65/cc65.git
synced 2024-09-08 16:54:52 +00:00
Working on the backend
git-svn-id: svn://svn.cc65.org/cc65/trunk@767 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
a9674c071a
commit
9ce1e413e4
@ -58,6 +58,27 @@
|
|||||||
const OPCDesc OPCTable[OPCODE_COUNT] = {
|
const OPCDesc OPCTable[OPCODE_COUNT] = {
|
||||||
|
|
||||||
/* Opcodes for the virtual stack machine */
|
/* Opcodes for the virtual stack machine */
|
||||||
|
{ OPC_CALL, /* opcode */
|
||||||
|
"call", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_NONE, /* use */
|
||||||
|
REG_NONE, /* chg */
|
||||||
|
OF_CPU_VM | OF_CALL /* flags */
|
||||||
|
},
|
||||||
|
{ OPC_ENTER, /* opcode */
|
||||||
|
"enter", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_Y, /* use */
|
||||||
|
REG_AXY, /* chg */
|
||||||
|
OF_CPU_VM /* flags */
|
||||||
|
},
|
||||||
|
{ OPC_JMP, /* opcode */
|
||||||
|
"jump", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_NONE, /* use */
|
||||||
|
REG_NONE, /* chg */
|
||||||
|
OF_CPU_VM | OF_UBRA /* flags */
|
||||||
|
},
|
||||||
{ OPC_LDA, /* opcode */
|
{ OPC_LDA, /* opcode */
|
||||||
"loada", /* mnemonic */
|
"loada", /* mnemonic */
|
||||||
0, /* size */
|
0, /* size */
|
||||||
@ -79,6 +100,20 @@ const OPCDesc OPCTable[OPCODE_COUNT] = {
|
|||||||
REG_EAX, /* chg */
|
REG_EAX, /* chg */
|
||||||
OF_CPU_VM | OF_LOAD /* flags */
|
OF_CPU_VM | OF_LOAD /* flags */
|
||||||
},
|
},
|
||||||
|
{ OPC_LEA, /* opcode */
|
||||||
|
"lea", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_NONE, /* use */
|
||||||
|
REG_AX, /* chg */
|
||||||
|
OF_CPU_VM /* flags */
|
||||||
|
},
|
||||||
|
{ OPC_LEAVE, /* opcode */
|
||||||
|
"leave", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_NONE, /* use */
|
||||||
|
REG_NONE, /* chg */
|
||||||
|
OF_CPU_VM /* flags */
|
||||||
|
},
|
||||||
{ OPC_PHA, /* opcode */
|
{ OPC_PHA, /* opcode */
|
||||||
"pusha", /* mnemonic */
|
"pusha", /* mnemonic */
|
||||||
0, /* size */
|
0, /* size */
|
||||||
@ -100,6 +135,13 @@ const OPCDesc OPCTable[OPCODE_COUNT] = {
|
|||||||
REG_NONE, /* chg */
|
REG_NONE, /* chg */
|
||||||
OF_CPU_VM /* flags */
|
OF_CPU_VM /* flags */
|
||||||
},
|
},
|
||||||
|
{ OPC_SPACE, /* opcode */
|
||||||
|
"space", /* mnemonic */
|
||||||
|
0, /* size */
|
||||||
|
REG_NONE, /* use */
|
||||||
|
REG_NONE, /* chg */
|
||||||
|
OF_CPU_VM /* flags */
|
||||||
|
},
|
||||||
{ OPC_STA, /* opcode */
|
{ OPC_STA, /* opcode */
|
||||||
"storea", /* mnemonic */
|
"storea", /* mnemonic */
|
||||||
0, /* size */
|
0, /* size */
|
||||||
@ -121,20 +163,6 @@ const OPCDesc OPCTable[OPCODE_COUNT] = {
|
|||||||
REG_NONE, /* chg */
|
REG_NONE, /* chg */
|
||||||
OF_CPU_VM /* flags */
|
OF_CPU_VM /* flags */
|
||||||
},
|
},
|
||||||
{ OPC_LEA, /* opcode */
|
|
||||||
"lea", /* mnemonic */
|
|
||||||
0, /* size */
|
|
||||||
REG_NONE, /* use */
|
|
||||||
REG_AX, /* chg */
|
|
||||||
OF_CPU_VM /* flags */
|
|
||||||
},
|
|
||||||
{ OPC_JMP, /* opcode */
|
|
||||||
"jump", /* mnemonic */
|
|
||||||
0, /* size */
|
|
||||||
REG_NONE, /* use */
|
|
||||||
REG_NONE, /* chg */
|
|
||||||
OF_CPU_VM | OF_UBRA /* flags */
|
|
||||||
},
|
|
||||||
|
|
||||||
/* 65XX opcodes */
|
/* 65XX opcodes */
|
||||||
{ OP65_ADC, /* opcode */
|
{ OP65_ADC, /* opcode */
|
||||||
|
@ -53,17 +53,21 @@
|
|||||||
typedef enum {
|
typedef enum {
|
||||||
|
|
||||||
/* Opcodes for the virtual stack machine */
|
/* Opcodes for the virtual stack machine */
|
||||||
|
OPC_CALL,
|
||||||
|
OPC_ENTER,
|
||||||
|
OPC_JMP,
|
||||||
OPC_LDA,
|
OPC_LDA,
|
||||||
OPC_LDAX,
|
OPC_LDAX,
|
||||||
OPC_LDEAX,
|
OPC_LDEAX,
|
||||||
|
OPC_LEA,
|
||||||
|
OPC_LEAVE,
|
||||||
OPC_PHA,
|
OPC_PHA,
|
||||||
OPC_PHAX,
|
OPC_PHAX,
|
||||||
OPC_PHEAX,
|
OPC_PHEAX,
|
||||||
|
OPC_SPACE,
|
||||||
OPC_STA,
|
OPC_STA,
|
||||||
OPC_STAX,
|
OPC_STAX,
|
||||||
OPC_STEAX,
|
OPC_STEAX,
|
||||||
OPC_LEA,
|
|
||||||
OPC_JMP,
|
|
||||||
|
|
||||||
/* 65XX opcodes */
|
/* 65XX opcodes */
|
||||||
OP65_ADC,
|
OP65_ADC,
|
||||||
|
Loading…
Reference in New Issue
Block a user