summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu
diff options
context:
space:
mode:
author Angelo Salese <angelosa@users.noreply.github.com>2012-01-15 21:40:54 +0000
committer Angelo Salese <angelosa@users.noreply.github.com>2012-01-15 21:40:54 +0000
commit7b631e4c5bf72f59ec59ffa487278cf00b24d7d9 (patch)
treec3298756c6adbeae27487f6975d64f8c4b607f80 /src/emu
parent71bb1c081811082d2ad4127064835a7f4addd353 (diff)
Clean-ups and version bumpmame0144u6
Diffstat (limited to 'src/emu')
-rw-r--r--src/emu/cpu/arm7/arm7.c2
-rw-r--r--src/emu/cpu/arm7/arm7ops.c16
-rw-r--r--src/emu/cpu/arm7/arm7ops.h2
-rw-r--r--src/emu/cpu/arm7/arm7thmb.c200
-rw-r--r--src/emu/cpu/i386/i386.c226
-rw-r--r--src/emu/cpu/i386/i386priv.h2
-rw-r--r--src/emu/delegate.h4
-rw-r--r--src/emu/drivers/empty.c2
-rw-r--r--src/emu/drivers/testcpu.c22
-rw-r--r--src/emu/imagedev/cartslot.h10
-rw-r--r--src/emu/machine/idectrl.c18
-rw-r--r--src/emu/machine/laserdsc.c22
-rw-r--r--src/emu/machine/laserdsc.h4
-rw-r--r--src/emu/machine/ldpr8210.c22
-rw-r--r--src/emu/machine/ldv1000.c28
-rw-r--r--src/emu/machine/ldvp931.c32
-rw-r--r--src/emu/render.c2
-rw-r--r--src/emu/screen.c20
-rw-r--r--src/emu/screen.h20
-rw-r--r--src/emu/softlist.c4
-rw-r--r--src/emu/video/pc_vga.c2
-rw-r--r--src/emu/video/v9938.c18
-rw-r--r--src/emu/video/v9938.h8
23 files changed, 343 insertions, 343 deletions
diff --git a/src/emu/cpu/arm7/arm7.c b/src/emu/cpu/arm7/arm7.c
index 8699205a67c..430f1924e2c 100644
--- a/src/emu/cpu/arm7/arm7.c
+++ b/src/emu/cpu/arm7/arm7.c
@@ -551,7 +551,7 @@ static CPU_EXECUTE( arm7 )
insn = cpustate->direct->read_decrypted_word(raddr);
thumb_handler[(insn & 0xffc0) >> 6](cpustate, pc, insn);
-
+
}
else
{
diff --git a/src/emu/cpu/arm7/arm7ops.c b/src/emu/cpu/arm7/arm7ops.c
index 9ca4b26e4c7..4d3d31ade09 100644
--- a/src/emu/cpu/arm7/arm7ops.c
+++ b/src/emu/cpu/arm7/arm7ops.c
@@ -1840,7 +1840,7 @@ const void arm7ops_0123(arm_state *cpustate, UINT32 insn)
HandleALU(cpustate, insn);
}
}
-// break;
+// break;
}
const void arm7ops_4567(arm_state *cpustate, UINT32 insn) /* Data Transfer - Single Data Access */
@@ -1851,16 +1851,16 @@ const void arm7ops_4567(arm_state *cpustate, UINT32 insn) /* Data Transfer - Sin
//case 7:
HandleMemSingle(cpustate, insn);
R15 += 4;
-// break;
+// break;
}
-
+
const void arm7ops_89(arm_state *cpustate, UINT32 insn) /* Block Data Transfer/Access */
{
//case 8:
//case 9:
HandleMemBlock(cpustate, insn);
R15 += 4;
-// break;
+// break;
}
const void arm7ops_ab(arm_state *cpustate, UINT32 insn) /* Branch or Branch & Link */
@@ -1868,7 +1868,7 @@ const void arm7ops_ab(arm_state *cpustate, UINT32 insn) /* Branch or Branch & Li
//case 0xa:
//case 0xb:
HandleBranch(cpustate, insn);
-// break;
+// break;
}
const void arm7ops_cd(arm_state *cpustate, UINT32 insn) /* Co-Processor Data Transfer */
@@ -1877,7 +1877,7 @@ const void arm7ops_cd(arm_state *cpustate, UINT32 insn) /* Co-Processor Data Tra
//case 0xd:
HandleCoProcDT(cpustate, insn);
R15 += 4;
-// break;
+// break;
}
const void arm7ops_e(arm_state *cpustate, UINT32 insn) /* Co-Processor Data Operation or Register Transfer */
@@ -1888,7 +1888,7 @@ const void arm7ops_e(arm_state *cpustate, UINT32 insn) /* Co-Processor Data Oper
else
HandleCoProcDO(cpustate, insn);
R15 += 4;
-// break;
+// break;
}
const void arm7ops_f(arm_state *cpustate, UINT32 insn) /* Software Interrupt */
@@ -1896,5 +1896,5 @@ const void arm7ops_f(arm_state *cpustate, UINT32 insn) /* Software Interrupt */
cpustate->pendingSwi = 1;
ARM7_CHECKIRQ;
//couldn't find any cycle counts for SWI
-// break;
+// break;
}
diff --git a/src/emu/cpu/arm7/arm7ops.h b/src/emu/cpu/arm7/arm7ops.h
index 66564c8d612..e797ae89056 100644
--- a/src/emu/cpu/arm7/arm7ops.h
+++ b/src/emu/cpu/arm7/arm7ops.h
@@ -5,4 +5,4 @@ const void arm7ops_89(arm_state *cpustate, UINT32 insn);
const void arm7ops_ab(arm_state *cpustate, UINT32 insn);
const void arm7ops_cd(arm_state *cpustate, UINT32 insn);
const void arm7ops_e(arm_state *cpustate, UINT32 insn);
-const void arm7ops_f(arm_state *cpustate, UINT32 insn); \ No newline at end of file
+const void arm7ops_f(arm_state *cpustate, UINT32 insn);
diff --git a/src/emu/cpu/arm7/arm7thmb.c b/src/emu/cpu/arm7/arm7thmb.c
index 9abfbc4126c..11453f1bd65 100644
--- a/src/emu/cpu/arm7/arm7thmb.c
+++ b/src/emu/cpu/arm7/arm7thmb.c
@@ -29,11 +29,11 @@ arm7thumb_ophandler thumb_handler[0x40*0x10] =
// #define THUMB_RELADDR_SP ((UINT16)0x0800)
tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_0, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1, tg0a_1,
// #define THUMB_STACKOP_TYPE ((UINT16)0x0f00)
- tg0b_0, tg0b_0, tg0b_0, tg0b_0, tg0b_1, tg0b_1, tg0b_1, tg0b_1, tg0b_2, tg0b_2, tg0b_2, tg0b_2, tg0b_3, tg0b_3, tg0b_3, tg0b_3, tg0b_4, tg0b_4, tg0b_4, tg0b_4, tg0b_5, tg0b_5, tg0b_5, tg0b_5, tg0b_6, tg0b_6, tg0b_6, tg0b_6, tg0b_7, tg0b_7, tg0b_7, tg0b_7, tg0b_8, tg0b_8, tg0b_8, tg0b_8, tg0b_9, tg0b_9, tg0b_9, tg0b_9, tg0b_a, tg0b_a, tg0b_a, tg0b_a, tg0b_b, tg0b_b, tg0b_b, tg0b_b, tg0b_c, tg0b_c, tg0b_c, tg0b_c, tg0b_d, tg0b_d, tg0b_d, tg0b_d, tg0b_e, tg0b_e, tg0b_e, tg0b_e, tg0b_f, tg0b_f, tg0b_f, tg0b_f,
+ tg0b_0, tg0b_0, tg0b_0, tg0b_0, tg0b_1, tg0b_1, tg0b_1, tg0b_1, tg0b_2, tg0b_2, tg0b_2, tg0b_2, tg0b_3, tg0b_3, tg0b_3, tg0b_3, tg0b_4, tg0b_4, tg0b_4, tg0b_4, tg0b_5, tg0b_5, tg0b_5, tg0b_5, tg0b_6, tg0b_6, tg0b_6, tg0b_6, tg0b_7, tg0b_7, tg0b_7, tg0b_7, tg0b_8, tg0b_8, tg0b_8, tg0b_8, tg0b_9, tg0b_9, tg0b_9, tg0b_9, tg0b_a, tg0b_a, tg0b_a, tg0b_a, tg0b_b, tg0b_b, tg0b_b, tg0b_b, tg0b_c, tg0b_c, tg0b_c, tg0b_c, tg0b_d, tg0b_d, tg0b_d, tg0b_d, tg0b_e, tg0b_e, tg0b_e, tg0b_e, tg0b_f, tg0b_f, tg0b_f, tg0b_f,
// #define THUMB_MULTLS ((UINT16)0x0800)
tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_0, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1, tg0c_1,
// #define THUMB_COND_TYPE ((UINT16)0x0f00)
- tg0d_0, tg0d_0, tg0d_0, tg0d_0, tg0d_1, tg0d_1, tg0d_1, tg0d_1, tg0d_2, tg0d_2, tg0d_2, tg0d_2, tg0d_3, tg0d_3, tg0d_3, tg0d_3, tg0d_4, tg0d_4, tg0d_4, tg0d_4, tg0d_5, tg0d_5, tg0d_5, tg0d_5, tg0d_6, tg0d_6, tg0d_6, tg0d_6, tg0d_7, tg0d_7, tg0d_7, tg0d_7, tg0d_8, tg0d_8, tg0d_8, tg0d_8, tg0d_9, tg0d_9, tg0d_9, tg0d_9, tg0d_a, tg0d_a, tg0d_a, tg0d_a, tg0d_b, tg0d_b, tg0d_b, tg0d_b, tg0d_c, tg0d_c, tg0d_c, tg0d_c, tg0d_d, tg0d_d, tg0d_d, tg0d_d, tg0d_e, tg0d_e, tg0d_e, tg0d_e, tg0d_f, tg0d_f, tg0d_f, tg0d_f,
+ tg0d_0, tg0d_0, tg0d_0, tg0d_0, tg0d_1, tg0d_1, tg0d_1, tg0d_1, tg0d_2, tg0d_2, tg0d_2, tg0d_2, tg0d_3, tg0d_3, tg0d_3, tg0d_3, tg0d_4, tg0d_4, tg0d_4, tg0d_4, tg0d_5, tg0d_5, tg0d_5, tg0d_5, tg0d_6, tg0d_6, tg0d_6, tg0d_6, tg0d_7, tg0d_7, tg0d_7, tg0d_7, tg0d_8, tg0d_8, tg0d_8, tg0d_8, tg0d_9, tg0d_9, tg0d_9, tg0d_9, tg0d_a, tg0d_a, tg0d_a, tg0d_a, tg0d_b, tg0d_b, tg0d_b, tg0d_b, tg0d_c, tg0d_c, tg0d_c, tg0d_c, tg0d_d, tg0d_d, tg0d_d, tg0d_d, tg0d_e, tg0d_e, tg0d_e, tg0d_e, tg0d_f, tg0d_f, tg0d_f, tg0d_f,
// #define THUMB_BLOP_LO ((UINT16)0x0800)
tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_0, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1, tg0e_1,
// #define THUMB_BLOP_LO ((UINT16)0x0800)
@@ -116,7 +116,7 @@ const void tg00_1(arm_state *cpustate, UINT32 pc, UINT32 insn) /* Shift right */
/* Arithmetic */
-const void tg01_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
+const void tg01_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
UINT32 rs, rd, rrs;
INT32 offs;
@@ -168,7 +168,7 @@ const void tg01_10(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD Rd, Rs,
{
UINT32 rn, rs, rd;
-
+
rn = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RNIMM) >> THUMB_ADDSUB_RNIMM_SHIFT);
rs = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT);
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
@@ -180,7 +180,7 @@ const void tg01_10(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD Rd, Rs,
const void tg01_11(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SUB Rd, Rs, Rn */
{
UINT32 rn, rs, rd;
-
+
rn = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RNIMM) >> THUMB_ADDSUB_RNIMM_SHIFT);
rs = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT);
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
@@ -192,7 +192,7 @@ const void tg01_11(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SUB Rd, Rs, R
const void tg01_12(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD Rd, Rs, #imm */
{
UINT32 rs, rd, imm;
-
+
imm = (insn & THUMB_ADDSUB_RNIMM) >> THUMB_ADDSUB_RNIMM_SHIFT;
rs = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT);
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
@@ -204,7 +204,7 @@ const void tg01_12(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD Rd, Rs, #
const void tg01_13(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SUB Rd, Rs, #imm */
{
UINT32 rs, rd, imm;
-
+
imm = (insn & THUMB_ADDSUB_RNIMM) >> THUMB_ADDSUB_RNIMM_SHIFT;
rs = GET_REGISTER(cpustate, (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT);
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
@@ -215,7 +215,7 @@ const void tg01_13(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SUB Rd, Rs, #
/* CMP / MOV */
-const void tg02_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
+const void tg02_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
UINT32 rd, op2;
@@ -227,7 +227,7 @@ const void tg02_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
R15 += 2;
}
-const void tg02_1(arm_state *cpustate, UINT32 pc, UINT32 insn)
+const void tg02_1(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
UINT32 rn, rd, op2;
@@ -273,7 +273,7 @@ const void tg03_1(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SUB Rd, #Offse
const void tg04_00_00(arm_state *cpustate, UINT32 pc, UINT32 insn) /* AND Rd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rd) & GET_REGISTER(cpustate, rs));
@@ -286,7 +286,7 @@ const void tg04_00_00(arm_state *cpustate, UINT32 pc, UINT32 insn) /* AND Rd, Rs
const void tg04_00_01(arm_state *cpustate, UINT32 pc, UINT32 insn) /* EOR Rd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rd) ^ GET_REGISTER(cpustate, rs));
@@ -300,7 +300,7 @@ const void tg04_00_02(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LSL Rd, Rs
{
UINT32 rs, rd, rrd;
INT32 offs;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rrd = GET_REGISTER(cpustate, rd);
@@ -347,7 +347,7 @@ const void tg04_00_03(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LSR Rd, Rs
{
UINT32 rs, rd, rrd;
INT32 offs;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rrd = GET_REGISTER(cpustate, rd);
@@ -393,7 +393,7 @@ const void tg04_00_03(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LSR Rd, Rs
const void tg04_00_04(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ASR Rd, Rs */
{
UINT32 rs, rd, rrs, rrd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rrs = GET_REGISTER(cpustate, rs)&0xff;
@@ -436,7 +436,7 @@ const void tg04_00_04(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ASR Rd, Rs
const void tg04_00_05(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADC Rd, Rs */
{
UINT32 rn, rs, rd, op2;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
op2=(GET_CPSR & C_MASK) ? 1 : 0;
@@ -462,7 +462,7 @@ const void tg04_00_06(arm_state *cpustate, UINT32 pc, UINT32 insn) /* SBC Rd, R
const void tg04_00_07(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ROR Rd, Rs */
{
UINT32 rs, rd, imm, rrd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rrd = GET_REGISTER(cpustate, rd);
@@ -485,7 +485,7 @@ const void tg04_00_07(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ROR Rd, Rs
const void tg04_00_08(arm_state *cpustate, UINT32 pc, UINT32 insn) /* TST Rd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
SET_CPSR(GET_CPSR & ~(Z_MASK | N_MASK));
@@ -497,7 +497,7 @@ const void tg04_00_08(arm_state *cpustate, UINT32 pc, UINT32 insn) /* TST Rd, Rs
const void tg04_00_09(arm_state *cpustate, UINT32 pc, UINT32 insn) /* NEG Rd, Rs */
{
UINT32 rn, rs, rd, rrs;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rrs = GET_REGISTER(cpustate, rs);
@@ -510,7 +510,7 @@ const void tg04_00_09(arm_state *cpustate, UINT32 pc, UINT32 insn) /* NEG Rd, Rs
const void tg04_00_0a(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Rd, Rs */
{
UINT32 rn, rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rn = GET_REGISTER(cpustate, rd) - GET_REGISTER(cpustate, rs);
@@ -522,7 +522,7 @@ const void tg04_00_0a(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Rd, Rs
const void tg04_00_0b(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMN Rd, Rs - check flags, add dasm */
{
UINT32 rn, rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rn = GET_REGISTER(cpustate, rd) + GET_REGISTER(cpustate, rs);
@@ -533,7 +533,7 @@ const void tg04_00_0b(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMN Rd, Rs
const void tg04_00_0c(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ORR Rd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rd) | GET_REGISTER(cpustate, rs));
@@ -546,7 +546,7 @@ const void tg04_00_0c(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ORR Rd, Rs
const void tg04_00_0d(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MUL Rd, Rs */
{
UINT32 rn, rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
rn = GET_REGISTER(cpustate, rd) * GET_REGISTER(cpustate, rs);
@@ -560,7 +560,7 @@ const void tg04_00_0d(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MUL Rd, Rs
const void tg04_00_0e(arm_state *cpustate, UINT32 pc, UINT32 insn) /* BIC Rd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rd) & (~GET_REGISTER(cpustate, rs)));
@@ -572,7 +572,7 @@ const void tg04_00_0e(arm_state *cpustate, UINT32 pc, UINT32 insn) /* BIC Rd, Rs
const void tg04_00_0f(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MVN Rd, Rs */
{
UINT32 rs, rd, op2;
-
+
rs = (insn & THUMB_ADDSUB_RS) >> THUMB_ADDSUB_RS_SHIFT;
rd = (insn & THUMB_ADDSUB_RD) >> THUMB_ADDSUB_RD_SHIFT;
op2 = GET_REGISTER(cpustate, rs);
@@ -587,9 +587,9 @@ const void tg04_00_0f(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MVN Rd, Rs
const void tg04_01_00(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 rs, rd;
-// rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
-// rd = insn & THUMB_HIREG_RD;
+// UINT32 rs, rd;
+// rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
+// rd = insn & THUMB_HIREG_RD;
fatalerror("%08x: G4-1-0 Undefined Thumb instruction: %04x %x\n", pc, insn, (insn & THUMB_HIREG_H) >> THUMB_HIREG_H_SHIFT);
@@ -604,7 +604,7 @@ const void tg04_01_01(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD Rd, HR
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
-
+
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rd) + GET_REGISTER(cpustate, rs+8));
// emulate the effects of pre-fetch
if (rs == 7)
@@ -621,7 +621,7 @@ const void tg04_01_02(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD HRd, R
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
-
+
SET_REGISTER(cpustate, rd+8, GET_REGISTER(cpustate, rd+8) + GET_REGISTER(cpustate, rs));
if (rd == 7)
{
@@ -637,7 +637,7 @@ const void tg04_01_03(arm_state *cpustate, UINT32 pc, UINT32 insn) /* Add HRd, H
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
-
+
SET_REGISTER(cpustate, rd+8, GET_REGISTER(cpustate, rd+8) + GET_REGISTER(cpustate, rs+8));
// emulate the effects of pre-fetch
if (rs == 7)
@@ -667,7 +667,7 @@ const void tg04_01_10(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Rd, R
const void tg04_01_11(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Rd, Hs */
{
UINT32 rn, rs, rd;
-
+
rs = GET_REGISTER(cpustate, ((insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT) + 8);
rd = GET_REGISTER(cpustate, insn & THUMB_HIREG_RD);
rn = rd - rs;
@@ -678,7 +678,7 @@ const void tg04_01_11(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Rd, Hs
const void tg04_01_12(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Hd, Rs */
{
UINT32 rn, rs, rd;
-
+
rs = GET_REGISTER(cpustate, ((insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT));
rd = GET_REGISTER(cpustate, (insn & THUMB_HIREG_RD) + 8);
rn = rd - rs;
@@ -689,7 +689,7 @@ const void tg04_01_12(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Hd, Rs
const void tg04_01_13(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Hd, Hs */
{
UINT32 rn, rs, rd;
-
+
rs = GET_REGISTER(cpustate, ((insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT) + 8);
rd = GET_REGISTER(cpustate, (insn & THUMB_HIREG_RD) + 8);
rn = rd - rs;
@@ -703,8 +703,8 @@ const void tg04_01_13(arm_state *cpustate, UINT32 pc, UINT32 insn) /* CMP Hd, Hs
const void tg04_01_20(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Rd, Rs (undefined) */
{
UINT32 rs, rd;
-
-
+
+
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
SET_REGISTER(cpustate, rd, GET_REGISTER(cpustate, rs));
@@ -715,7 +715,7 @@ const void tg04_01_20(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Rd, Rs
const void tg04_01_21(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Rd, Hs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
if (rs == 7)
@@ -733,7 +733,7 @@ const void tg04_01_21(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Rd, Hs
const void tg04_01_22(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Hd, Rs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
SET_REGISTER(cpustate, rd + 8, GET_REGISTER(cpustate, rs));
@@ -751,7 +751,7 @@ const void tg04_01_22(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Hd, Rs
const void tg04_01_23(arm_state *cpustate, UINT32 pc, UINT32 insn) /* MOV Hd, Hs */
{
UINT32 rs, rd;
-
+
rs = (insn & THUMB_HIREG_RS) >> THUMB_HIREG_RS_SHIFT;
rd = insn & THUMB_HIREG_RD;
if (rs == 7)
@@ -826,8 +826,8 @@ const void tg04_01_31(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg04_01_32(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// UINT32 rd;
+// UINT32 addr;
+// UINT32 rd;
fatalerror("%08x: G4-3 Undefined Thumb instruction: %04x\n", pc, insn);
@@ -837,8 +837,8 @@ const void tg04_01_32(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg04_01_33(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// UINT32 rd;
+// UINT32 addr;
+// UINT32 rd;
fatalerror("%08x: G4-3 Undefined Thumb instruction: %04x\n", pc, insn);
@@ -851,7 +851,7 @@ const void tg04_01_33(arm_state *cpustate, UINT32 pc, UINT32 insn)
-const void tg04_0203(arm_state *cpustate, UINT32 pc, UINT32 insn)
+const void tg04_0203(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
UINT32 readword;
@@ -866,21 +866,21 @@ const void tg05_0(arm_state *cpustate, UINT32 pc, UINT32 insn) /* STR Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
addr = GET_REGISTER(cpustate, rn) + GET_REGISTER(cpustate, rm);
WRITE32(addr, GET_REGISTER(cpustate, rd));
R15 += 2;
-
+
}
const void tg05_1(arm_state *cpustate, UINT32 pc, UINT32 insn) /* STRH Rd, [Rn, Rm] */
{
UINT32 addr;
UINT32 rm, rn, rd;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -894,7 +894,7 @@ const void tg05_2(arm_state *cpustate, UINT32 pc, UINT32 insn) /* STRB Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -908,7 +908,7 @@ const void tg05_3(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LDSB Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd, op2;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -927,7 +927,7 @@ const void tg05_4(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LDR Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd, op2;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -942,7 +942,7 @@ const void tg05_5(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LDRH Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd, op2;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -957,7 +957,7 @@ const void tg05_6(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LDRB Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd, op2;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -972,7 +972,7 @@ const void tg05_7(arm_state *cpustate, UINT32 pc, UINT32 insn) /* LDSH Rd, [Rn,
{
UINT32 addr;
UINT32 rm, rn, rd, op2;
-
+
rm = (insn & THUMB_GROUP5_RM) >> THUMB_GROUP5_RM_SHIFT;
rn = (insn & THUMB_GROUP5_RN) >> THUMB_GROUP5_RN_SHIFT;
rd = (insn & THUMB_GROUP5_RD) >> THUMB_GROUP5_RD_SHIFT;
@@ -1119,7 +1119,7 @@ const void tg0b_0(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD SP, #imm *
{
UINT32 addr;
-
+
addr = (insn & THUMB_INSN_IMM);
addr &= ~THUMB_INSN_IMM_S;
SET_REGISTER(cpustate, 13, GET_REGISTER(cpustate, 13) + ((insn & THUMB_INSN_IMM_S) ? -(addr << 2) : (addr << 2)));
@@ -1129,8 +1129,8 @@ const void tg0b_0(arm_state *cpustate, UINT32 pc, UINT32 insn) /* ADD SP, #imm *
const void tg0b_1(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1139,8 +1139,8 @@ const void tg0b_1(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_2(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1149,8 +1149,8 @@ const void tg0b_2(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_3(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1160,7 +1160,7 @@ const void tg0b_3(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_4(arm_state *cpustate, UINT32 pc, UINT32 insn) /* PUSH {Rlist} */
{
INT32 offs;
-
+
for (offs = 7; offs >= 0; offs--)
{
if (insn & (1 << offs))
@@ -1176,7 +1176,7 @@ const void tg0b_4(arm_state *cpustate, UINT32 pc, UINT32 insn) /* PUSH {Rlist} *
const void tg0b_5(arm_state *cpustate, UINT32 pc, UINT32 insn) /* PUSH {Rlist}{LR} */
{
INT32 offs;
-
+
SET_REGISTER(cpustate, 13, GET_REGISTER(cpustate, 13) - 4);
WRITE32(GET_REGISTER(cpustate, 13), GET_REGISTER(cpustate, 14));
for (offs = 7; offs >= 0; offs--)
@@ -1193,8 +1193,8 @@ const void tg0b_5(arm_state *cpustate, UINT32 pc, UINT32 insn) /* PUSH {Rlist}{L
const void tg0b_6(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1203,8 +1203,8 @@ const void tg0b_6(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_7(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1213,8 +1213,8 @@ const void tg0b_7(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_8(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1223,8 +1223,8 @@ const void tg0b_8(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_9(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1233,8 +1233,8 @@ const void tg0b_9(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_a(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1243,8 +1243,8 @@ const void tg0b_a(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_b(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1254,7 +1254,7 @@ const void tg0b_b(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_c(arm_state *cpustate, UINT32 pc, UINT32 insn) /* POP {Rlist} */
{
INT32 offs;
-
+
for (offs = 0; offs < 8; offs++)
{
if (insn & (1 << offs))
@@ -1270,7 +1270,7 @@ const void tg0b_c(arm_state *cpustate, UINT32 pc, UINT32 insn) /* POP {Rlist} */
const void tg0b_d(arm_state *cpustate, UINT32 pc, UINT32 insn) /* POP {Rlist}{PC} */
{
INT32 offs;
-
+
for (offs = 0; offs < 8; offs++)
{
if (insn & (1 << offs))
@@ -1286,8 +1286,8 @@ const void tg0b_d(arm_state *cpustate, UINT32 pc, UINT32 insn) /* POP {Rlist}{PC
const void tg0b_e(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1296,8 +1296,8 @@ const void tg0b_e(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0b_f(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
-// UINT32 addr;
-// INT32 offs;
+// UINT32 addr;
+// INT32 offs;
fatalerror("%08x: Gb Undefined Thumb instruction: %04x\n", pc, insn);
R15 += 2;
@@ -1361,10 +1361,10 @@ const void tg0c_1(arm_state *cpustate, UINT32 pc, UINT32 insn) /* Load */
ld_st_address += 4;
}
}
-
+
if (!rd_in_list)
SET_REGISTER(cpustate, rd, ld_st_address);
-
+
R15 += 2;
}
@@ -1375,7 +1375,7 @@ const void tg0d_0(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_EQ:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (Z_IS_SET(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1392,7 +1392,7 @@ const void tg0d_1(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_NE:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (Z_IS_CLEAR(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1409,7 +1409,7 @@ const void tg0d_2(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_CS:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (C_IS_SET(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1426,7 +1426,7 @@ const void tg0d_3(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_CC:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (C_IS_CLEAR(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1443,7 +1443,7 @@ const void tg0d_4(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_MI:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (N_IS_SET(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1460,7 +1460,7 @@ const void tg0d_5(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_PL:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (N_IS_CLEAR(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1477,7 +1477,7 @@ const void tg0d_6(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_VS:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (V_IS_SET(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1494,7 +1494,7 @@ const void tg0d_7(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_VC:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (V_IS_CLEAR(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1511,7 +1511,7 @@ const void tg0d_8(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_HI:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (C_IS_SET(GET_CPSR) && Z_IS_CLEAR(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1528,7 +1528,7 @@ const void tg0d_9(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_LS:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (C_IS_CLEAR(GET_CPSR) || Z_IS_SET(GET_CPSR))
{
R15 += 4 + (offs << 1);
@@ -1545,7 +1545,7 @@ const void tg0d_a(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_GE:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (!(GET_CPSR & N_MASK) == !(GET_CPSR & V_MASK))
{
R15 += 4 + (offs << 1);
@@ -1562,7 +1562,7 @@ const void tg0d_b(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_LT:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (!(GET_CPSR & N_MASK) != !(GET_CPSR & V_MASK))
{
R15 += 4 + (offs << 1);
@@ -1579,7 +1579,7 @@ const void tg0d_c(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_GT:
INT32 offs;
offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
if (Z_IS_CLEAR(GET_CPSR) && !(GET_CPSR & N_MASK) == !(GET_CPSR & V_MASK))
{
R15 += 4 + (offs << 1);
@@ -1610,10 +1610,10 @@ const void tg0d_d(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_LE:
const void tg0d_e(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_AL:
{
-// INT32 offs;
+// INT32 offs;
// offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
fatalerror("%08x: Undefined Thumb instruction: %04x (ARM9 reserved)\n", pc, insn);
R15 += 2;
@@ -1621,11 +1621,11 @@ const void tg0d_e(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_AL:
const void tg0d_f(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_NV: // SWI (this is sort of a "hole" in the opcode encoding)
{
-// INT32 offs;
+// INT32 offs;
// offs = (INT8)(insn & THUMB_INSN_IMM);
-//case
+//case
cpustate->pendingSwi = 1;
ARM7_CHECKIRQ;
@@ -1633,7 +1633,7 @@ const void tg0d_f(arm_state *cpustate, UINT32 pc, UINT32 insn) // COND_NV: //
/* B #offs */
-const void tg0e_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
+const void tg0e_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
INT32 offs;
@@ -1649,7 +1649,7 @@ const void tg0e_0(arm_state *cpustate, UINT32 pc, UINT32 insn)
const void tg0e_1(arm_state *cpustate, UINT32 pc, UINT32 insn)
{
UINT32 addr;
-
+
addr = GET_REGISTER(cpustate, 14);
addr += (insn & THUMB_BLOP_OFFS) << 1;
addr &= 0xfffffffc;
diff --git a/src/emu/cpu/i386/i386.c b/src/emu/cpu/i386/i386.c
index 47275884fb6..5e186b99ccc 100644
--- a/src/emu/cpu/i386/i386.c
+++ b/src/emu/cpu/i386/i386.c
@@ -2260,7 +2260,7 @@ static void i386_protected_mode_iret(i386_state* cpustate, int operand32)
{
if(newflags & 0x00020000) // if returning to virtual 8086 mode
{
-// UINT8 SSRPL,SSDPL;
+// UINT8 SSRPL,SSDPL;
memset(&desc, 0, sizeof(desc));
desc.selector = newCS;
i386_load_protected_mode_segment(cpustate,&desc);
@@ -2275,118 +2275,118 @@ static void i386_protected_mode_iret(i386_state* cpustate, int operand32)
/* Return to v86 mode */
logerror("IRET (%08x): Returning to Virtual 8086 mode.\n",cpustate->pc);
// Should these be done at this point? The 386 programmers' reference is a bit confusing about this
-/* if(RPL != 3)
- {
- logerror("IRET to V86 (%08x): Return CS RPL is not 3\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- if(operand32 == 0)
- {
- if(REG16(SP)+36 > cpustate->sreg[SS].limit)
- {
- logerror("IRET to V86 (%08x): Stack does not have enough room left\n",cpustate->pc);
- FAULT(FAULT_SS,0);
- }
- }
- else
- {
- if(REG32(ESP)+36 > cpustate->sreg[SS].limit)
- {
- logerror("IRET to V86 (%08x): Stack does not have enough space left\n",cpustate->pc);
- FAULT(FAULT_SS,0);
- }
- }
- // code segment checks
- if((newCS & ~0x07) == 0)
- {
- logerror("IRET to V86 (%08x): Return CS selector is null\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- if(desc.flags & 0x04)
- { // LDT
- if(newCS > cpustate->ldtr.limit)
- {
- logerror("IRET to V86 (%08x): Return CS selector is past LDT limit\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- }
- else
- { // GDT
- if(newCS > cpustate->gdtr.limit)
- {
- logerror("IRET to V86 (%08x): Return CS selector is past GDT limit\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- }
- if((desc.flags & 0x18) != 0x18)
- {
- logerror("IRET to V86 (%08x): Return CS segment is not a code segment\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- if(DPL != 3)
- {
- logerror("IRET to V86 (%08x): Return CS segment does not have a DPL of 3\n",cpustate->pc);
- FAULT(FAULT_GP,newCS);
- }
- if(!(desc.flags & 0x0080))
- {
- logerror("IRET to V86 (%08x): Return CS segment is not present\n",cpustate->pc);
- FAULT(FAULT_NP,newCS);
- }
- // Stack segment checks
- if((newSS & ~0x07) == 0)
- {
- logerror("IRET to V86 (%08x): Return SS segment is null\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- if(desc.flags & 0x04)
- { // LDT
- if(newSS > cpustate->ldtr.limit)
- {
- logerror("IRET to V86 (%08x): Return SS selector is past LDT limit\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- }
- else
- { // GDT
- if(newSS > cpustate->gdtr.limit)
- {
- logerror("IRET to V86 (%08x): Return SS selector is past GDT limit\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- }
- if(SSRPL != RPL)
- {
- logerror("IRET to V86 (%08x): Return SS selector RPL is not equal to CS selector RPL\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- if(((stack.flags & 0x0018) != 0x10) && (!(stack.flags & 0x02)))
- {
- logerror("IRET to V86 (%08x): Return SS segment is not a writable data segment\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- if(SSDPL != RPL)
- {
- logerror("IRET to V86 (%08x): Return SS segment DPL is not equal to CS selector RPL\n",cpustate->pc);
- FAULT(FAULT_GP,newSS);
- }
- if(!(stack.flags & 0x0080))
- {
- logerror("IRET to V86 (%08x): Return SS segment is not present\n",cpustate->pc);
- FAULT(FAULT_NP,newSS);
- }
-
- if(newEIP > desc.limit)
- {
- logerror("IRET to V86 (%08x): New EIP is past CS segment limit\n",cpustate->pc);
- FAULT(FAULT_GP,0);
- }
- */
+/* if(RPL != 3)
+ {
+ logerror("IRET to V86 (%08x): Return CS RPL is not 3\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ if(operand32 == 0)
+ {
+ if(REG16(SP)+36 > cpustate->sreg[SS].limit)
+ {
+ logerror("IRET to V86 (%08x): Stack does not have enough room left\n",cpustate->pc);
+ FAULT(FAULT_SS,0);
+ }
+ }
+ else
+ {
+ if(REG32(ESP)+36 > cpustate->sreg[SS].limit)
+ {
+ logerror("IRET to V86 (%08x): Stack does not have enough space left\n",cpustate->pc);
+ FAULT(FAULT_SS,0);
+ }
+ }
+ // code segment checks
+ if((newCS & ~0x07) == 0)
+ {
+ logerror("IRET to V86 (%08x): Return CS selector is null\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ if(desc.flags & 0x04)
+ { // LDT
+ if(newCS > cpustate->ldtr.limit)
+ {
+ logerror("IRET to V86 (%08x): Return CS selector is past LDT limit\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ }
+ else
+ { // GDT
+ if(newCS > cpustate->gdtr.limit)
+ {
+ logerror("IRET to V86 (%08x): Return CS selector is past GDT limit\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ }
+ if((desc.flags & 0x18) != 0x18)
+ {
+ logerror("IRET to V86 (%08x): Return CS segment is not a code segment\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ if(DPL != 3)
+ {
+ logerror("IRET to V86 (%08x): Return CS segment does not have a DPL of 3\n",cpustate->pc);
+ FAULT(FAULT_GP,newCS);
+ }
+ if(!(desc.flags & 0x0080))
+ {
+ logerror("IRET to V86 (%08x): Return CS segment is not present\n",cpustate->pc);
+ FAULT(FAULT_NP,newCS);
+ }
+ // Stack segment checks
+ if((newSS & ~0x07) == 0)
+ {
+ logerror("IRET to V86 (%08x): Return SS segment is null\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ if(desc.flags & 0x04)
+ { // LDT
+ if(newSS > cpustate->ldtr.limit)
+ {
+ logerror("IRET to V86 (%08x): Return SS selector is past LDT limit\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ }
+ else
+ { // GDT
+ if(newSS > cpustate->gdtr.limit)
+ {
+ logerror("IRET to V86 (%08x): Return SS selector is past GDT limit\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ }
+ if(SSRPL != RPL)
+ {
+ logerror("IRET to V86 (%08x): Return SS selector RPL is not equal to CS selector RPL\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ if(((stack.flags & 0x0018) != 0x10) && (!(stack.flags & 0x02)))
+ {
+ logerror("IRET to V86 (%08x): Return SS segment is not a writable data segment\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ if(SSDPL != RPL)
+ {
+ logerror("IRET to V86 (%08x): Return SS segment DPL is not equal to CS selector RPL\n",cpustate->pc);
+ FAULT(FAULT_GP,newSS);
+ }
+ if(!(stack.flags & 0x0080))
+ {
+ logerror("IRET to V86 (%08x): Return SS segment is not present\n",cpustate->pc);
+ FAULT(FAULT_NP,newSS);
+ }
+
+ if(newEIP > desc.limit)
+ {
+ logerror("IRET to V86 (%08x): New EIP is past CS segment limit\n",cpustate->pc);
+ FAULT(FAULT_GP,0);
+ }
+ */
set_flags(cpustate,newflags);
cpustate->eip = POP32(cpustate) & 0xffff; // high 16 bits are ignored
cpustate->sreg[CS].selector = POP32(cpustate) & 0xffff;
POP32(cpustate); // already set flags
-// if(RPL > CPL)
+// if(RPL > CPL)
{
newESP = POP32(cpustate);
newSS = POP32(cpustate) & 0xffff;
@@ -2649,10 +2649,10 @@ static void i386_protected_mode_iret(i386_state* cpustate, int operand32)
FAULT(FAULT_GP,0)
}
-// if(operand32 == 0)
-// REG16(SP) += 10;
-// else
-// REG32(ESP) += 20;
+// if(operand32 == 0)
+// REG16(SP) += 10;
+// else
+// REG32(ESP) += 20;
if(operand32 == 0)
{
diff --git a/src/emu/cpu/i386/i386priv.h b/src/emu/cpu/i386/i386priv.h
index 3d08a047b64..f424d71e261 100644
--- a/src/emu/cpu/i386/i386priv.h
+++ b/src/emu/cpu/i386/i386priv.h
@@ -419,7 +419,7 @@ INLINE int translate_address(i386_state *cpustate, bool rw, UINT32 *address, UIN
*address = (page_entry & 0xfffff000) | offset;
}
}
- if(!ret)
+ if(!ret)
{
*error = ((rw && 1)<<1) | ((cpustate->CPL==3)?1<<2:0);
return 0;
diff --git a/src/emu/delegate.h b/src/emu/delegate.h
index ef5155f5d32..2c2a9ebd711 100644
--- a/src/emu/delegate.h
+++ b/src/emu/delegate.h
@@ -278,7 +278,7 @@ class delegate_base
public:
// define our traits
- template<class _FunctionClass>
+ template<class _FunctionClass>
struct traits
{
typedef typename delegate_traits<_FunctionClass, _ReturnType, _P1Type, _P2Type, _P3Type, _P4Type, _P5Type>::member_func_type member_func_type;
@@ -530,7 +530,7 @@ class delegate_base
public:
// define our traits
- template<class _FunctionClass>
+ template<class _FunctionClass>
struct traits
{
typedef typename delegate_traits<_FunctionClass, _ReturnType, _P1Type, _P2Type, _P3Type, _P4Type, _P5Type>::member_func_type member_func_type;
diff --git a/src/emu/drivers/empty.c b/src/emu/drivers/empty.c
index fd9d4f63c6b..71e790f0a31 100644
--- a/src/emu/drivers/empty.c
+++ b/src/emu/drivers/empty.c
@@ -61,7 +61,7 @@ public:
// force the UI to show the game select screen
ui_menu_force_game_select(machine(), &machine().render().ui_container());
}
-
+
UINT32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
{
bitmap.fill(RGB_BLACK);
diff --git a/src/emu/drivers/testcpu.c b/src/emu/drivers/testcpu.c
index 7dde4deb4d7..9df02974259 100644
--- a/src/emu/drivers/testcpu.c
+++ b/src/emu/drivers/testcpu.c
@@ -80,14 +80,14 @@ public:
0x986a0070 // stb r3,0x0070(r10)
};
- // iterate over instructions
+ // iterate over instructions
for (int instnum = 0; instnum < ARRAY_LENGTH(sample_instructions); instnum++)
{
// write the instruction to execute, followed by a BLR which will terminate the
// basic block in the DRC
m_space->write_dword(RAM_BASE, sample_instructions[instnum]);
m_space->write_dword(RAM_BASE + 4, 0x4e800020);
-
+
// initialize the register state
m_cpu->set_state(PPC_PC, RAM_BASE);
for (int regnum = 0; regnum < 32; regnum++)
@@ -110,29 +110,29 @@ public:
// execute one instruction
*m_cpu->m_icountptr = 0;
m_cpu->run();
-
+
// dump the final register state
printf("Final state:\n");
dump_state(false);
}
-
+
// all done; just bail
throw emu_fatalerror(0, "All done");
}
-
+
// startup code; do basic configuration and set a timer to go off immediately
virtual void machine_start()
{
// find the CPU's address space
m_space = m_cpu->space(AS_PROGRAM);
-
+
// configure DRC in the most compatible mode
ppcdrc_set_options(m_cpu, PPCDRC_COMPATIBLE_OPTIONS);
// set a timer to go off right away
timer_set(attotime::zero);
}
-
+
// dump the current CPU state
void dump_state(bool disassemble)
{
@@ -147,10 +147,10 @@ public:
for (int bytenum = 0; bytenum < maxbytes; bytenum++)
instruction[bytenum] = m_space->read_byte(RAM_BASE + bytenum);
- // disassemble the current instruction
+ // disassemble the current instruction
bytes = m_cpu->disassemble(buffer, RAM_BASE, instruction, instruction) & DASMFLAG_LENGTHMASK;
}
-
+
// output the registers
printf("PC : %08X", UINT32(m_cpu->state(PPC_PC)));
if (disassemble && bytes > 0)
@@ -167,7 +167,7 @@ public:
if (regnum % 4 == 3) printf("\n");
}
printf("CR : %08X LR : %08X CTR: %08X XER: %08X\n",
- UINT32(m_cpu->state(PPC_CR)), UINT32(m_cpu->state(PPC_LR)),
+ UINT32(m_cpu->state(PPC_CR)), UINT32(m_cpu->state(PPC_LR)),
UINT32(m_cpu->state(PPC_CTR)), UINT32(m_cpu->state(PPC_XER)));
for (int regnum = 0; regnum < 32; regnum++)
{
@@ -175,7 +175,7 @@ public:
if (regnum % 4 == 3) printf("\n");
}
}
-
+
// report reads from anywhere
READ64_MEMBER( general_r )
{
diff --git a/src/emu/imagedev/cartslot.h b/src/emu/imagedev/cartslot.h
index de22680c899..e42287f0f3e 100644
--- a/src/emu/imagedev/cartslot.h
+++ b/src/emu/imagedev/cartslot.h
@@ -40,9 +40,9 @@ public:
virtual bool call_load();
virtual void call_unload();
virtual void call_display_info() { if (m_device_displayinfo) m_device_displayinfo(*this); }
- virtual bool call_softlist_load(char *swlist, char *swname, rom_entry *start_entry) { load_software_part_region( this, swlist, swname, start_entry ); return TRUE; }
+ virtual bool call_softlist_load(char *swlist, char *swname, rom_entry *start_entry) { load_software_part_region( this, swlist, swname, start_entry ); return TRUE; }
virtual device_image_partialhash_func get_partial_hash() const { return m_device_partialhash; }
-
+
virtual iodevice_t image_type() const { return IO_CARTSLOT; }
virtual bool is_readable() const { return 1; }
@@ -53,7 +53,7 @@ public:
virtual const char *image_interface() const { return m_interface; }
virtual const char *file_extensions() const { return m_extensions; }
virtual const option_guide *create_option_guide() const { return NULL; }
-
+
void set_extensions(const char *_extensions) { m_extensions = _extensions; }
void set_interface(const char *_interface) { m_interface = _interface; }
void set_must_be_loaded(bool _must_be_loaded) { m_must_be_loaded = _must_be_loaded; }
@@ -67,10 +67,10 @@ protected:
// device-level overrides
virtual void device_config_complete();
virtual void device_start();
-
+
int load_cartridge(const rom_entry *romrgn, const rom_entry *roment, bool load);
int process_cartridge(bool load);
-
+
const char * m_extensions;
const char * m_interface;
diff --git a/src/emu/machine/idectrl.c b/src/emu/machine/idectrl.c
index 45aed293c85..440596007ed 100644
--- a/src/emu/machine/idectrl.c
+++ b/src/emu/machine/idectrl.c
@@ -120,11 +120,11 @@ struct _ide_device
UINT16 num_cylinders;
UINT8 num_sectors;
UINT8 num_heads;
-
+
chd_file *handle;
hard_disk_file *disk;
- bool is_image_device;
-};
+ bool is_image_device;
+};
typedef struct _ide_state ide_state;
@@ -173,7 +173,7 @@ struct _ide_state
UINT8 gnetreadlock;
ide_hardware * hardware;
-
+
UINT8 cur_drive;
ide_device drive[2];
};
@@ -1872,7 +1872,7 @@ static DEVICE_START( ide_controller )
/* set MAME harddisk handle */
config = (const ide_config *)downcast<const legacy_device_base *>(device)->inline_config();
-
+
ide->drive[0].handle = get_disk_handle(device->machine(), (config->master != NULL) ? config->master : device->tag());
ide->drive[0].disk = hard_disk_open(ide->drive[0].handle);
ide->drive[0].is_image_device = false;
@@ -1914,7 +1914,7 @@ static DEVICE_START( ide_controller )
/* build the features page */
ide_build_features(ide,0);
- }
+ }
if (ide->drive[1].disk != NULL)
{
hdinfo = hard_disk_get_info(ide->drive[1].disk);
@@ -1928,7 +1928,7 @@ static DEVICE_START( ide_controller )
/* build the features page */
ide_build_features(ide,1);
- }
+ }
if (config->hardware != NULL) {
ide->hardware = (ide_hardware *)config->hardware;
ide->hardware->get_info(ide->device, ide->drive[0].features, ide->drive[0].num_cylinders, ide->drive[0].num_sectors, ide->drive[0].num_heads);
@@ -2055,7 +2055,7 @@ static DEVICE_RESET( ide_controller )
}
}
}
- }
+ }
if (device->machine().device( hardtag_slave.cstr() )) {
if (!ide->drive[1].disk)
{
@@ -2084,7 +2084,7 @@ static DEVICE_RESET( ide_controller )
}
}
}
- }
+ }
if (ide->hardware != NULL) {
ide->hardware->get_info(ide->device, ide->drive[0].features, ide->drive[0].num_cylinders, ide->drive[0].num_sectors, ide->drive[0].num_heads);
ide_generate_features (ide,0);
diff --git a/src/emu/machine/laserdsc.c b/src/emu/machine/laserdsc.c
index 4bc0878fc8e..42d50493171 100644
--- a/src/emu/machine/laserdsc.c
+++ b/src/emu/machine/laserdsc.c
@@ -143,7 +143,7 @@ laserdisc_device::~laserdisc_device()
//**************************************************************************
//-------------------------------------------------
-// get_field_code - return raw field information
+// get_field_code - return raw field information
// read from the disc
//-------------------------------------------------
@@ -244,7 +244,7 @@ void laserdisc_device::static_set_screen(device_t &device, const char *screen)
//-------------------------------------------------
-// static_set_get_disc - set the get disc
+// static_set_get_disc - set the get disc
// delegate
//-------------------------------------------------
@@ -255,7 +255,7 @@ void laserdisc_device::static_set_get_disc(device_t &device, laserdisc_get_disc_
//-------------------------------------------------
-// static_set_get_disc - set the audio interceptor
+// static_set_get_disc - set the audio interceptor
// delegate
//-------------------------------------------------
@@ -292,7 +292,7 @@ void laserdisc_device::static_set_overlay(device_t &device, UINT32 width, UINT32
//-------------------------------------------------
// static_set_overlay - set the overlay visible
-// subregion
+// subregion
//-------------------------------------------------
void laserdisc_device::static_set_overlay_clip(device_t &device, INT32 minx, INT32 maxx, INT32 miny, INT32 maxy)
@@ -302,7 +302,7 @@ void laserdisc_device::static_set_overlay_clip(device_t &device, INT32 minx, INT
//-------------------------------------------------
-// static_set_overlay_position - set the overlay
+// static_set_overlay_position - set the overlay
// position parameters
//-------------------------------------------------
@@ -316,7 +316,7 @@ void laserdisc_device::static_set_overlay_position(device_t &device, float posx,
//-------------------------------------------------
// static_set_overlay_scale - set the overlay
-// scale parameters
+// scale parameters
//-------------------------------------------------
void laserdisc_device::static_set_overlay_scale(device_t &device, float scalex, float scaley)
@@ -528,7 +528,7 @@ void laserdisc_device::advance_slider(INT32 numtracks)
{
// first update to the current time
update_slider_pos();
-
+
// then update the track position
add_and_clamp_track(numtracks);
if (LOG_SLIDER)
@@ -729,7 +729,7 @@ INT32 laserdisc_device::generic_update(const vbi_metadata &vbi, int fieldnum, at
advanceby = 1;
}
break;
-
+
default:
// do nothing
break;
@@ -855,7 +855,7 @@ void laserdisc_device::init_video()
// bind our handlers
m_overupdate_ind16.bind_relative_to(*owner());
m_overupdate_rgb32.bind_relative_to(*owner());
-
+
// configure bitmap formats
bitmap_format format = !m_overupdate_ind16.isnull() ? BITMAP_FORMAT_IND16 : BITMAP_FORMAT_RGB32;
texture_format texformat = !m_overupdate_ind16.isnull() ? TEXFORMAT_PALETTEA16 : TEXFORMAT_ARGB32;
@@ -867,7 +867,7 @@ void laserdisc_device::init_video()
m_overbitmap[index].set_palette(machine().palette);
m_overbitmap[index].resize(m_overwidth, m_overheight);
}
-
+
// allocate overlay texture
m_overtex = machine().render().texture_alloc();
if (m_overtex == NULL)
@@ -930,7 +930,7 @@ void laserdisc_device::fillbitmap_yuy16(bitmap_yuy16 &bitmap, UINT8 yval, UINT8
void laserdisc_device::update_slider_pos()
{
attotime curtime = machine().time();
-
+
// if not moving, update to now
if (m_attospertrack == 0)
m_sliderupdate = curtime;
diff --git a/src/emu/machine/laserdsc.h b/src/emu/machine/laserdsc.h
index 3fda4e5d030..185b2296586 100644
--- a/src/emu/machine/laserdsc.h
+++ b/src/emu/machine/laserdsc.h
@@ -165,7 +165,7 @@ struct laserdisc_overlay_config
// ======================> laserdisc_device
// base laserdisc class
-class laserdisc_device : public device_t,
+class laserdisc_device : public device_t,
public device_sound_interface,
public laserdisc_overlay_config
{
@@ -372,7 +372,7 @@ private:
bool m_videoenable; // is video enabled?
render_texture * m_videotex; // texture for the video
palette_t * m_videopalette; // palette for the video
-
+
// overlays
bool m_overenable; // is the overlay enabled?
screen_bitmap m_overbitmap[2]; // overlay bitmaps
diff --git a/src/emu/machine/ldpr8210.c b/src/emu/machine/ldpr8210.c
index 5bc2036f480..b73bbc9dc86 100644
--- a/src/emu/machine/ldpr8210.c
+++ b/src/emu/machine/ldpr8210.c
@@ -240,10 +240,10 @@ pioneer_pr8210_device::pioneer_pr8210_device(const machine_config &mconfig, devi
m_i8049_port2(0)
{
}
-
+
//-------------------------------------------------
-// control_w - write callback when the CONTROL
+// control_w - write callback when the CONTROL
// line is toggled
//-------------------------------------------------
@@ -252,7 +252,7 @@ void pioneer_pr8210_device::control_w(UINT8 data)
// set the new value and remember the last
UINT8 prev = m_control;
m_control = data;
-
+
// handle rising edge
if (prev != ASSERT_LINE && data == ASSERT_LINE)
{
@@ -351,7 +351,7 @@ void pioneer_pr8210_device::device_timer(emu_timer &timer, device_timer_id id, i
switch (id)
{
// update the VBI data in the PIA as soon as it is ready;
- // this must happen early in the frame because the player
+ // this must happen early in the frame because the player
// logic relies on fetching it here
case TID_VBI_DATA_FETCH:
@@ -396,12 +396,12 @@ void pioneer_pr8210_device::device_timer(emu_timer &timer, device_timer_id id, i
}
}
break;
-
+
// clear the VSYNC flag
case TID_VSYNC_OFF:
m_vsync = false;
break;
-
+
// pass everything else onto the parent
default:
laserdisc_device::device_timer(timer, id, param, ptr);
@@ -458,7 +458,7 @@ void pioneer_pr8210_device::player_vsync(const vbi_metadata &vbi, int fieldnum,
//-------------------------------------------------
-// player_update - update callback, called on the
+// player_update - update callback, called on the
// first visible line of the frame
//-------------------------------------------------
@@ -639,7 +639,7 @@ READ8_MEMBER( pioneer_pr8210_device::i8049_bus_r )
$04 = (in) SIZE 8/12
$02 = (in) FG via op-amp (spindle motor stop detector)
$01 = (in) SLOW TIMER OUT
- */
+ */
UINT8 result = 0x00;
@@ -684,7 +684,7 @@ WRITE8_MEMBER( pioneer_pr8210_device::i8049_port1_w )
$02 = (out) SCAN A (/SCAN)
$01 = (out) JUMP TRG (jump back trigger, clock on high->low)
*/
-
+
// set the new value
UINT8 prev = m_i8049_port1;
m_i8049_port1 = data;
@@ -933,7 +933,7 @@ simutrek_special_device::simutrek_special_device(const machine_config &mconfig,
//-------------------------------------------------
-// data_w - write callback when the parallel data
+// data_w - write callback when the parallel data
// port is written to
//-------------------------------------------------
@@ -1028,7 +1028,7 @@ void simutrek_special_device::device_timer(emu_timer &timer, device_timer_id id,
case TID_IRQ_OFF:
m_i8748_cpu->set_input_line(MCS48_INPUT_IRQ, CLEAR_LINE);
break;
-
+
// latch data
case TID_LATCH_DATA:
m_data = param;
diff --git a/src/emu/machine/ldv1000.c b/src/emu/machine/ldv1000.c
index 62fdd19d2bd..a22dbf0a91a 100644
--- a/src/emu/machine/ldv1000.c
+++ b/src/emu/machine/ldv1000.c
@@ -107,22 +107,22 @@ ADDRESS_MAP_END
static const ppi8255_interface ppi0intf =
{
- DEVCB_NULL,
- DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_portb_r),
+ DEVCB_NULL,
+ DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_portb_r),
DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_portc_r),
- DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_porta_w),
- DEVCB_NULL,
+ DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_porta_w),
+ DEVCB_NULL,
DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi0_portc_w)
};
static const ppi8255_interface ppi1intf =
{
- DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi1_porta_r),
- DEVCB_NULL,
+ DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi1_porta_r),
+ DEVCB_NULL,
+ DEVCB_NULL,
DEVCB_NULL,
- DEVCB_NULL,
- DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi1_portb_w),
+ DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi1_portb_w),
DEVCB_DEVICE_MEMBER(DEVICE_SELF_OWNER, pioneer_ldv1000_device, ppi1_portc_w)
};
@@ -193,7 +193,7 @@ pioneer_ldv1000_device::pioneer_ldv1000_device(const machine_config &mconfig, co
//-------------------------------------------------
-// data_w - handle a parallel data write to the
+// data_w - handle a parallel data write to the
// LD-V1000
//-------------------------------------------------
@@ -222,7 +222,7 @@ void pioneer_ldv1000_device::device_start()
{
// pass through to the parent
laserdisc_device::device_start();
-
+
// allocate timers
m_multitimer = timer_alloc(TID_MULTIJUMP);
}
@@ -273,11 +273,11 @@ void pioneer_ldv1000_device::device_timer(emu_timer &timer, device_timer_id id,
timer.adjust(MULTIJUMP_TRACK_TIME);
break;
}
-
+
case TID_VSYNC_OFF:
m_vsync = false;
break;
-
+
case TID_VBI_DATA_FETCH:
{
// appears to return data in reverse order
@@ -315,7 +315,7 @@ void pioneer_ldv1000_device::device_timer(emu_timer &timer, device_timer_id id,
m_vbiindex = 0;
break;
}
-
+
// pass everything else onto the parent
default:
laserdisc_device::device_timer(timer, id, param, ptr);
@@ -398,7 +398,7 @@ WRITE_LINE_MEMBER( pioneer_ldv1000_device::ctc_interrupt )
//-------------------------------------------------
-// z80_decoder_display_port_w - handle writes to
+// z80_decoder_display_port_w - handle writes to
// the decoder/display chips
//-------------------------------------------------
diff --git a/src/emu/machine/ldvp931.c b/src/emu/machine/ldvp931.c
index 622fe162fdb..3d7862ca25c 100644
--- a/src/emu/machine/ldvp931.c
+++ b/src/emu/machine/ldvp931.c
@@ -146,7 +146,7 @@ void phillips_22vp931_device::reset_w(UINT8 data)
{
// control the CPU state
m_i8049_cpu->set_input_line(INPUT_LINE_RESET, data);
-
+
// on an assert, reset the device state as well
if (data == ASSERT_LINE)
reset();
@@ -154,7 +154,7 @@ void phillips_22vp931_device::reset_w(UINT8 data)
//-------------------------------------------------
-// data_r - handle a parallel data read from the
+// data_r - handle a parallel data read from the
// 22VP931
//-------------------------------------------------
@@ -182,7 +182,7 @@ void phillips_22vp931_device::device_start()
{
// pass through to the parent
laserdisc_device::device_start();
-
+
// allocate a timer
m_tracktimer = timer_alloc(TID_HALF_TRACK);
}
@@ -201,19 +201,19 @@ void phillips_22vp931_device::device_reset()
m_i8049_out0 = 0;
m_i8049_out1 = 0;
m_i8049_port1 = 0;
-
+
m_daticval = 0;
m_daticerp = 0;
m_datastrobe = 0;
-
+
m_fromcontroller = 0;
m_fromcontroller_pending = false;
m_tocontroller = 0;
m_tocontroller_pending = false;
-
+
m_trackdir = 0;
m_trackstate = 0;
-
+
m_cmdcount = 0;
m_advanced = 0;
}
@@ -263,7 +263,7 @@ void phillips_22vp931_device::device_timer(emu_timer &timer, device_timer_id id,
timer_set(screen().time_until_pos(line*2, which * 2 * screen().width() / 4), TID_VBI_DATA_FETCH, (line << 2) + which);
break;
}
-
+
case TID_DEFERRED_DATA:
// set the value and mark it pending
if (LOG_COMMANDS && m_fromcontroller_pending)
@@ -279,19 +279,19 @@ void phillips_22vp931_device::device_timer(emu_timer &timer, device_timer_id id,
printf("Cmd: %02X %02X %02X\n", m_cmdbuf[0], m_cmdbuf[1], m_cmdbuf[2]);
}
break;
-
+
case TID_IRQ_OFF:
m_i8049_cpu->set_input_line(MCS48_INPUT_IRQ, CLEAR_LINE);
break;
-
+
case TID_DATA_STROBE_OFF:
m_datastrobe = 0;
break;
-
+
case TID_ERP_OFF:
m_daticerp = 0;
break;
-
+
case TID_HALF_TRACK:
// advance by the count and toggle the state
m_trackstate ^= 1;
@@ -301,7 +301,7 @@ void phillips_22vp931_device::device_timer(emu_timer &timer, device_timer_id id,
m_advanced += m_trackdir;
}
break;
-
+
// pass everything else onto the parent
default:
laserdisc_device::device_timer(timer, id, param, ptr);
@@ -471,7 +471,7 @@ READ8_MEMBER( phillips_22vp931_device::i8049_unknown_r )
//-------------------------------------------------
-// i8049_keypad_r - vestigial keypad/button
+// i8049_keypad_r - vestigial keypad/button
// controls
//-------------------------------------------------
@@ -517,7 +517,7 @@ READ8_MEMBER( phillips_22vp931_device::i8049_from_controller_r )
//-------------------------------------------------
-// i8049_to_controller_w - write a value back to
+// i8049_to_controller_w - write a value back to
// the external controller
//-------------------------------------------------
@@ -672,7 +672,7 @@ READ8_MEMBER( phillips_22vp931_device::i8049_t0_r )
//-------------------------------------------------
-// i8049_t1_r - return the T1 line status, which
+// i8049_t1_r - return the T1 line status, which
// is connected to the tracking state and is used
// to count the number of tracks advanced
//-------------------------------------------------
diff --git a/src/emu/render.c b/src/emu/render.c
index c9e7f575f83..ba4b78f08ac 100644
--- a/src/emu/render.c
+++ b/src/emu/render.c
@@ -503,7 +503,7 @@ bool render_texture::get_scaled(UINT32 dwidth, UINT32 dheight, render_texinfo &t
texinfo.seqid = ++m_curseq;
return true;
}
-
+
// make sure we can recover the original argb32 bitmap
bitmap_argb32 &srcbitmap = downcast<bitmap_argb32 &>(*m_bitmap);
diff --git a/src/emu/screen.c b/src/emu/screen.c
index e4a11fa05af..ce2e694e372 100644
--- a/src/emu/screen.c
+++ b/src/emu/screen.c
@@ -232,7 +232,7 @@ void screen_device::static_set_screen_update(device_t &device, screen_update_rgb
//-------------------------------------------------
-// static_set_screen_vblank - set the screen
+// static_set_screen_vblank - set the screen
// VBLANK callback in the device configuration
//-------------------------------------------------
@@ -284,7 +284,7 @@ bool screen_device::device_validity_check(emu_options &options, const game_drive
mame_printf_error("%s: %s screen '%s' has a zero refresh rate\n", driver.source_file, driver.name, tag());
error = true;
}
-
+
return error;
}
@@ -299,7 +299,7 @@ void screen_device::device_start()
m_screen_update_ind16.bind_relative_to(*owner());
m_screen_update_rgb32.bind_relative_to(*owner());
m_screen_vblank.bind_relative_to(*owner());
-
+
// configure bitmap formats and allocate screen bitmaps
texture_format texformat = !m_screen_update_ind16.isnull() ? TEXFORMAT_PALETTE16 : TEXFORMAT_RGB32;
for (int index = 0; index < ARRAY_LENGTH(m_bitmap); index++)
@@ -414,17 +414,17 @@ void screen_device::device_timer(emu_timer &timer, device_timer_id id, int param
case TID_VBLANK_START:
vblank_begin();
break;
-
+
// signal VBLANK end
case TID_VBLANK_END:
vblank_end();
break;
-
+
// first visible scanline
case TID_SCANLINE0:
reset_partial_updates();
break;
-
+
// subsequent scanlines when scanline updates are enabled
case TID_SCANLINE:
@@ -797,7 +797,7 @@ void screen_device::register_screen_bitmap(bitmap_t &bitmap)
//-------------------------------------------------
-// vblank_begin - call any external callbacks to
+// vblank_begin - call any external callbacks to
// signal the VBLANK period has begun
//-------------------------------------------------
@@ -829,7 +829,7 @@ void screen_device::vblank_begin()
//-------------------------------------------------
-// vblank_end - call any external callbacks to
+// vblank_end - call any external callbacks to
// signal the VBLANK period has ended
//-------------------------------------------------
@@ -908,7 +908,7 @@ void screen_device::update_burnin()
int ystart = ((UINT32)rand() % 32767) * ystep / 32767;
int srcx, srcy;
int x, y;
-
+
switch (curbitmap.format())
{
default:
@@ -929,7 +929,7 @@ void screen_device::update_burnin()
}
break;
}
-
+
case BITMAP_FORMAT_RGB32:
{
// iterate over rows in the destination
diff --git a/src/emu/screen.h b/src/emu/screen.h
index 9b9def655df..d9bcb38488e 100644
--- a/src/emu/screen.h
+++ b/src/emu/screen.h
@@ -88,15 +88,15 @@ public:
m_live(&m_rgb32) { }
screen_bitmap(bitmap_ind16 &orig)
: m_format(BITMAP_FORMAT_IND16),
- m_texformat(TEXFORMAT_PALETTE16),
+ m_texformat(TEXFORMAT_PALETTE16),
m_live(&m_ind16),
m_ind16(orig, orig.cliprect()) { }
screen_bitmap(bitmap_rgb32 &orig)
: m_format(BITMAP_FORMAT_RGB32),
- m_texformat(TEXFORMAT_RGB32),
+ m_texformat(TEXFORMAT_RGB32),
m_live(&m_rgb32),
m_rgb32(orig, orig.cliprect()) { }
-
+
// resizing
void resize(int width, int height) { live().resize(width, height); }
@@ -104,7 +104,7 @@ public:
operator bitmap_t &() { return live(); }
bitmap_ind16 &as_ind16() { assert(m_format == BITMAP_FORMAT_IND16); return m_ind16; }
bitmap_rgb32 &as_rgb32() { assert(m_format == BITMAP_FORMAT_RGB32); return m_rgb32; }
-
+
// getters
INT32 width() const { return live().width(); }
INT32 height() const { return live().height(); }
@@ -132,7 +132,7 @@ public:
m_ind16.reset();
m_rgb32.reset();
}
-
+
private:
// internal state
bitmap_format m_format;
@@ -219,7 +219,7 @@ public:
bool update_partial(int scanline);
void update_now();
void reset_partial_updates();
-
+
// additional helpers
void register_vblank_callback(vblank_state_delegate vblank_callback);
void register_screen_bitmap(bitmap_t &bitmap);
@@ -323,7 +323,7 @@ private:
: m_next(NULL),
m_bitmap(bitmap) { }
auto_bitmap_item *next() const { return m_next; }
-
+
auto_bitmap_item * m_next;
bitmap_t & m_bitmap;
};
@@ -406,9 +406,9 @@ extern const device_type SCREEN;
//-------------------------------------------------
// screen_update_delegate_smart - collection of
-// inline helpers which create the appropriate
-// screen_update_delegate based on the input
-// function type
+// inline helpers which create the appropriate
+// screen_update_delegate based on the input
+// function type
//-------------------------------------------------
inline screen_update_ind16_delegate screen_update_delegate_smart(UINT32 (*callback)(device_t *, screen_device &, bitmap_ind16 &, const rectangle &), const char *name)
diff --git a/src/emu/softlist.c b/src/emu/softlist.c
index c417816066c..1bb5dd3dc2d 100644
--- a/src/emu/softlist.c
+++ b/src/emu/softlist.c
@@ -2015,11 +2015,11 @@ void validate_softlists(emu_options &options)
mame_printf_error("%s: %s has a part (%s) with no data\n", list->file->filename(), swinfo->shortname, swpart->name);
error = TRUE;
}
-
+
if (part_names.add(swpart->name, swinfo, FALSE) == TMERR_DUPLICATE)
{
mame_printf_error("%s: %s has a part (%s) whose name is duplicate\n", list->file->filename(), swinfo->shortname, swpart->name);
- error = TRUE;
+ error = TRUE;
}
for (struct rom_entry *swdata = software_find_romdata(swpart, NULL); swdata != NULL; swdata = software_romdata_next(swdata))
diff --git a/src/emu/video/pc_vga.c b/src/emu/video/pc_vga.c
index 7a715d6cc02..3e427231a7f 100644
--- a/src/emu/video/pc_vga.c
+++ b/src/emu/video/pc_vga.c
@@ -181,7 +181,7 @@ static VIDEO_RESET( vga );
void pc_video_start(running_machine &machine)
{
-// pc_choosevideomode = choosevideomode;
+// pc_choosevideomode = choosevideomode;
pc_current_height = -1;
pc_current_width = -1;
}
diff --git a/src/emu/video/v9938.c b/src/emu/video/v9938.c
index f4f28a37cf0..8569b6bb122 100644
--- a/src/emu/video/v9938.c
+++ b/src/emu/video/v9938.c
@@ -257,7 +257,7 @@ PALETTE_INIT( v9958 )
// init v9938 512-color palette
PALETTE_INIT_CALL(v9938);
-
+
if (v99x8_device::s_pal_indYJK == NULL)
v99x8_device::s_pal_indYJK = global_alloc_array(UINT16, 0x20000);
@@ -585,7 +585,7 @@ void v99x8_device::device_start()
assert(m_screen != NULL);
if (!m_screen->started())
throw device_missing_dependencies();
-
+
if (!m_int_callback.isnull())
{
device_t *device = (m_int_callback_device_name != NULL) ? machine().device(m_int_callback_device_name) : NULL;
@@ -1867,7 +1867,7 @@ skip_first_cc_set:
#define SHORT_WIDTH (256 + 16)
#define LONG_WIDTH (512 + 32)
-
+
const v99x8_device::v99x8_mode v99x8_device::s_modes[] = {
{ 0x02,
&v99x8_device::mode_text1<UINT16, LONG_WIDTH>,
@@ -2274,10 +2274,10 @@ void v99x8_device::interrupt_start_vblank ()
#define CM_HMMC 0xF
/*************************************************************/
-// Many VDP commands are executed in some kind of loop but
-// essentially, there are only a few basic loop structures
-// that are re-used. We define the loop structures that are
-// re-used here so that they have to be entered only once
+// Many VDP commands are executed in some kind of loop but
+// essentially, there are only a few basic loop structures
+// that are re-used. We define the loop structures that are
+// re-used here so that they have to be entered only once
/*************************************************************/
#define pre_loop \
while ((cnt-=delta) > 0) {
@@ -2331,7 +2331,7 @@ static const int PPL[4] = { 256,512,512,256 };
// ScrOf ScrOn ScrOf ScrOn
static const int srch_timing[8]={
818, 1025, 818, 830, // ntsc
- 696, 854, 696, 684 // pal
+ 696, 854, 696, 684 // pal
};
static const int line_timing[8]={
1063, 1259, 1063, 1161,
@@ -3106,7 +3106,7 @@ UINT8 v99x8_device::command_unit_w (UINT8 Op)
if (ScrMode<5)
return(0);
- SM = ScrMode-5; // Screen mode index 0..3
+ SM = ScrMode-5; // Screen mode index 0..3
m_mmc.CM = Op>>4;
if ((m_mmc.CM & 0x0C) != 0x0C && m_mmc.CM != 0)
diff --git a/src/emu/video/v9938.h b/src/emu/video/v9938.h
index 3b0805197c8..9df7c61d20f 100644
--- a/src/emu/video/v9938.h
+++ b/src/emu/video/v9938.h
@@ -79,7 +79,7 @@ public:
int get_transpen();
bitmap_ind16 &get_bitmap() { return m_bitmap; }
void update_mouse_state(int mx_delta, int my_delta, int button_state);
-
+
UINT32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
DECLARE_READ8_MEMBER( read );
@@ -98,7 +98,7 @@ public:
protected:
int m_model;
-
+
// device overrides
virtual void device_start();
virtual void device_reset();
@@ -110,7 +110,7 @@ private:
int vram_read (int offset);
void check_int ();
void register_write (int reg, int data);
-
+
template<typename _PixelType, int _Width> void default_border(const pen_t *pens, _PixelType *ln);
template<typename _PixelType, int _Width> void graphic7_border(const pen_t *pens, _PixelType *ln);
template<typename _PixelType, int _Width> void graphic5_border(const pen_t *pens, _PixelType *ln);
@@ -135,7 +135,7 @@ private:
void refresh_line (int line);
void interrupt_start_vblank ();
-
+
UINT8 *VDPVRMP(UINT8 M, int MX, int X, int Y);
UINT8 VDPpoint5(int MXS, int SX, int SY);