Esempio n. 1
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int mode = 0; mode < 3; mode++)
            {
                if (mode == 0)
                {
                    baseAddress = 0xc140;
                    i           = new AnonymousInstruction(this);
                }
                else if (mode == 1)
                {
                    baseAddress = 0xc148;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xc188;
                    i           = new AnonymousInstruction2(this);
                }

                for (int rx = 0; rx < 8; rx++)
                {
                    for (int ry = 0; ry < 8; ry++)
                    {
                        instructionSet.AddInstruction(baseAddress + (rx << 9) + ry, i);
                    }
                }
            }
        }
Esempio n. 2
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xb108;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xb148;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xb188;
                    i           = new AnonymousInstruction2(this);
                }

                for (int ax = 0; ax < 8; ax++)
                {
                    for (int ay = 0; ay < 8; ay++)
                    {
                        instructionSet.AddInstruction(baseAddress + (ax << 9) + ay, i);
                    }
                }
            }
        }
Esempio n. 3
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress = 0x01c0;
            IInstruction i;

            for (int ea_mode = 0; ea_mode < 8; ea_mode++)
            {
                if (ea_mode == 1)
                {
                    continue;
                }
                if (ea_mode == 0)
                {
                    i = new AnonymousInstruction(this);
                }
                else
                {
                    i = new AnonymousInstruction1(this);
                }

                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    for (int r = 0; r < 8; r++)
                    {
                        instructionSet.AddInstruction(baseAddress + (r << 9) + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }

            baseAddress = 0x08c0;
            for (int ea_mode = 0; ea_mode < 8; ea_mode++)
            {
                if (ea_mode == 1)
                {
                    continue;
                }
                if (ea_mode == 0)
                {
                    i = new AnonymousInstruction2(this);
                }
                else
                {
                    i = new AnonymousInstruction3(this);
                }

                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                }
            }
        }
Esempio n. 4
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x9100;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x9140;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x9180;
                    i           = new AnonymousInstruction2(this);
                }

                for (int regx = 0; regx < 8; regx++)
                {
                    for (int regy = 0; regy < 8; regy++)
                    {
                        instructionSet.AddInstruction(baseAddress + (regx << 9) + regy, i);
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x9108;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x9148;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0x9188;
                    i           = new AnonymousInstruction5(this);
                }

                for (int regx = 0; regx < 8; regx++)
                {
                    for (int regy = 0; regy < 8; regy++)
                    {
                        instructionSet.AddInstruction(baseAddress + (regx << 9) + regy, i);
                    }
                }
            }
        }
Esempio n. 5
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 2; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x0188;
                    i           = new AnonymousInstruction(this);
                }
                else
                {
                    baseAddress = 0x01c8;
                    i           = new AnonymousInstruction1(this);
                }

                for (int dreg = 0; dreg < 8; dreg++)
                {
                    for (int areg = 0; areg < 8; areg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (dreg << 9) + areg, i);
                    }
                }
            }

            for (int sz = 0; sz < 2; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x0108;
                    i           = new AnonymousInstruction2(this);
                }
                else
                {
                    baseAddress = 0x0148;
                    i           = new AnonymousInstruction3(this);
                }

                for (int dreg = 0; dreg < 8; dreg++)
                {
                    for (int areg = 0; areg < 8; areg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (dreg << 9) + areg, i);
                    }
                }
            }
        }
Esempio n. 6
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x1000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x3000;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x2000;
                    i           = new AnonymousInstruction2(this);
                }

                for (int sea_mode = 0; sea_mode < 8; sea_mode++)
                {
                    for (int sea_reg = 0; sea_reg < 8; sea_reg++)
                    {
                        if (sea_mode == 7 && sea_reg > 4)
                        {
                            break;
                        }
                        for (int dea_mode = 0; dea_mode < 8; dea_mode++)
                        {
                            if (dea_mode == 1)
                            {
                                continue;
                            }
                            for (int dea_reg = 0; dea_reg < 8; dea_reg++)
                            {
                                if (dea_mode == 7 && dea_reg > 1)
                                {
                                    break;
                                }
                                instructionSet.AddInstruction(baseAddress + (dea_reg << 9) + (dea_mode << 6) + (sea_mode << 3) + sea_reg, i);
                            }
                        }
                    }
                }
            }
        }
Esempio n. 7
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x5000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x5040;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x5080;
                    i           = new AnonymousInstruction2(this);
                }

                for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                {
                    if (sz == 0 && ea_mode == 1)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && ea_reg > 1)
                        {
                            break;
                        }
                        for (int imm = 0; imm < 8; imm++)
                        {
                            instructionSet.AddInstruction(baseAddress + (imm << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }
        }
Esempio n. 8
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x0a00;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x0a40;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x0a80;
                    i           = new AnonymousInstruction2(this);
                }

                for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                {
                    if (ea_mode == 1)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && (ea_reg == 2 || ea_reg == 3 || ea_reg == 4))
                        {
                            continue;
                        }
                        instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }
        }
Esempio n. 9
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xb000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xb040;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xb080;
                    i           = new AnonymousInstruction2(this);
                }

                for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                {
                    if (ea_mode == 1 && sz == 0)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && ea_reg > 4)
                        {
                            break;
                        }
                        for (int r = 0; r < 8; r++)
                        {
                            instructionSet.AddInstruction(baseAddress + (r << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }
        }
Esempio n. 10
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x0000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x0040;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x0080;
                    i           = new AnonymousInstruction2(this);
                }

                for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                {
                    if (ea_mode == 1)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && (ea_reg == 2 || ea_reg == 3 || ea_reg == 4))
                        {
                            continue;
                        }
                        instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }
        }
Esempio n. 11
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xe100;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xe140;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xe180;
                    i           = new AnonymousInstruction2(this);
                }

                for (int imm = 0; imm < 8; imm++)
                {
                    for (int reg = 0; reg < 8; reg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (imm << 9) + reg, i);
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xe120;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xe160;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0xe1a0;
                    i           = new AnonymousInstruction5(this);
                }

                for (int imm = 0; imm < 8; imm++)
                {
                    for (int reg = 0; reg < 8; reg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (imm << 9) + reg, i);
                    }
                }
            }

            baseAddress = 0xe1c0;
            i           = new AnonymousInstruction6(this);
            for (int ea_mode = 2; ea_mode < 8; ea_mode++)
            {
                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                }
            }
        }
Esempio n. 12
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xd100;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xd140;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xd180;
                    i           = new AnonymousInstruction2(this);
                }

                for (int regx = 0; regx < 8; regx++)
                {
                    for (int regy = 0; regy < 8; regy++)
                    {
                        instructionSet.AddInstruction(baseAddress + (regx << 9) + regy, i);
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xd108;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xd148;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0xd188;
                    i           = new AnonymousInstruction5(this);
                }

                for (int regx = 0; regx < 8; regx++)
                {
                    for (int regy = 0; regy < 8; regy++)
                    {
                        instructionSet.AddInstruction(baseAddress + (regx << 9) + regy, i);
                    }
                }
            }
        }
Esempio n. 13
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 2; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x4880;
                    i           = new AnonymousInstruction(this);
                }
                else
                {
                    baseAddress = 0x48c0;
                    i           = new AnonymousInstruction1(this);
                }

                for (int ea_mode = 2; ea_mode < 8; ea_mode++)
                {
                    if (ea_mode == 3)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && ea_reg > 1)
                        {
                            break;
                        }
                        instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }

            for (int sz = 0; sz < 2; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x4c80;
                    i           = new AnonymousInstruction2(this);
                }
                else
                {
                    baseAddress = 0x4cc0;
                    i           = new AnonymousInstruction3(this);
                }

                for (int ea_mode = 2; ea_mode < 8; ea_mode++)
                {
                    if (ea_mode == 4)
                    {
                        continue;
                    }
                    for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                    {
                        if (ea_mode == 7 && ea_reg > 3)
                        {
                            break;
                        }
                        instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }
        }
Esempio n. 14
0
        public void Register(IInstructionSet instructionSet)
        {
            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x9000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x9040;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0x9080;
                    i           = new AnonymousInstruction2(this);
                }

                for (int reg = 0; reg < 8; reg++)
                {
                    for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                    {
                        for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                        {
                            if (ea_mode == 7 && ea_reg > 4)
                            {
                                break;
                            }
                            instructionSet.AddInstruction(baseAddress + (reg << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0x9100;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0x9140;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0x9180;
                    i           = new AnonymousInstruction5(this);
                }

                for (int reg = 0; reg < 8; reg++)
                {
                    for (int ea_mode = 2; ea_mode < 8; ea_mode++)
                    {
                        for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                        {
                            if (ea_mode == 7 && ea_reg > 1)
                            {
                                break;
                            }
                            instructionSet.AddInstruction(baseAddress + (reg << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }
        }
Esempio n. 15
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress = 0x0140;
            IInstruction i;

            for (int ea_mode = 0; ea_mode < 8; ea_mode++)
            {
                if (ea_mode == 1)
                {
                    continue;
                }
                if (ea_mode == 0)
                {
                    i = new AnonymousInstruction(this);
                }
                else
                {
                    i = new AnonymousInstruction1(this);
                }

                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    for (int r = 0; r < 8; r++)
                    {
                        instructionSet.AddInstruction(baseAddress + (r << 9) + (ea_mode << 3) + ea_reg, i);
                    }
                }
            }

            baseAddress = 0x0840;
            for (int ea_mode = 0; ea_mode < 8; ea_mode++)
            {
                if (ea_mode == 1)
                {
                    continue;
                }
                if (ea_mode == 0)
                {
                    i = new AnonymousInstruction2(this);
                }
                else
                {
                    i = new AnonymousInstruction3(this);
                }

                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                }
            }
        }
Esempio n. 16
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xd000;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xd040;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xd080;
                    i           = new AnonymousInstruction2(this);
                }

                for (int reg = 0; reg < 8; reg++)
                {
                    for (int ea_mode = 0; ea_mode < 8; ea_mode++)
                    {
                        for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                        {
                            if (ea_mode == 7 && ea_reg > 4)
                            {
                                break;
                            }

                            instructionSet.AddInstruction(baseAddress + (reg << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xd100;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xd140;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0xd180;
                    i           = new AnonymousInstruction5(this);
                }

                for (int reg = 0; reg < 8; reg++)
                {
                    for (int ea_mode = 2; ea_mode < 8; ea_mode++)
                    {
                        for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                        {
                            if (ea_mode == 7 && ea_reg > 1)
                            {
                                break;
                            }

                            instructionSet.AddInstruction(baseAddress + (reg << 9) + (ea_mode << 3) + ea_reg, i);
                        }
                    }
                }
            }
        }
Esempio n. 17
0
        public void Register(IInstructionSet instructionSet)
        {
            if (instructionSet is null)
            {
                throw new System.ArgumentNullException(nameof(instructionSet));
            }

            int          baseAddress;
            IInstruction i;

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xe108;
                    i           = new AnonymousInstruction(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xe148;
                    i           = new AnonymousInstruction1(this);
                }
                else
                {
                    baseAddress = 0xe188;
                    i           = new AnonymousInstruction2(this);
                }

                for (int imm = 0; imm < 8; imm++)
                {
                    for (int reg = 0; reg < 8; reg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (imm << 9) + reg, i);
                    }
                }
            }

            for (int sz = 0; sz < 3; sz++)
            {
                if (sz == 0)
                {
                    baseAddress = 0xe128;
                    i           = new AnonymousInstruction3(this);
                }
                else if (sz == 1)
                {
                    baseAddress = 0xe168;
                    i           = new AnonymousInstruction4(this);
                }
                else
                {
                    baseAddress = 0xe1a8;
                    i           = new AnonymousInstruction5(this);
                }

                for (int imm = 0; imm < 8; imm++)
                {
                    for (int reg = 0; reg < 8; reg++)
                    {
                        instructionSet.AddInstruction(baseAddress + (imm << 9) + reg, i);
                    }
                }
            }

            baseAddress = 0xe3c0;
            i           = new AnonymousInstruction6(this);
            for (int ea_mode = 2; ea_mode < 8; ea_mode++)
            {
                for (int ea_reg = 0; ea_reg < 8; ea_reg++)
                {
                    if (ea_mode == 7 && ea_reg > 1)
                    {
                        break;
                    }
                    instructionSet.AddInstruction(baseAddress + (ea_mode << 3) + ea_reg, i);
                }
            }
        }