Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IMLAC: Type consistency warnings. #430

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions imlac/imlac_cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,8 @@ static void cpu_class1 (uint16 insn)

static void cpu_ral (int n)
{
int i, x;
int i;
uint16 x;
for (i = 0; i < n; i++) {
x = L;
L = AC >> 15;
Expand All @@ -221,7 +222,9 @@ static void cpu_ral (int n)

static void cpu_rar (int n)
{
int i, x;
int i;
uint16 x;

for (i = 0; i < n; i++) {
x = L;
L = AC & 1;
Expand Down Expand Up @@ -252,7 +255,7 @@ static void cpu_class2 (uint16 insn)
x = 01600000 >> n;
else
x = 0;
AC = x | ((AC & 077777) >> n);
AC = (uint16) (x | ((AC & 077777) >> n));
break;
}
}
Expand Down Expand Up @@ -485,7 +488,7 @@ t_stat sim_instr (void)
}
}

return SCPE_OK;
/* unreachable: return SCPE_OK; */
}

static t_stat
Expand Down
5 changes: 3 additions & 2 deletions imlac/imlac_crt.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ static UNIT crt_unit = {
};

static DEBTAB crt_deb[] = {
{ "DBG", DBG },
{ "DBG", DBG },
{ "VVID", SIM_VID_DBG_VIDEO },
{ NULL, 0 }
};

Expand Down Expand Up @@ -90,8 +91,8 @@ crt_reset (DEVICE *dptr)
} else {
display_reset ();
display_init (DIS_IMLAC, 1, dptr);
sim_activate_abs (&crt_unit, 0);
vid_register_quit_callback (&crt_quit_callback);
sim_activate_abs (&crt_unit, 0);
}
#endif
return SCPE_OK;
Expand Down
12 changes: 10 additions & 2 deletions imlac/imlac_dp.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ static uint16 SYNC = 1;
/* Function declaration. */
static uint16 dp_iot (uint16, uint16);
static t_stat dp_svc (UNIT *uptr);
static t_stat dp_reset(DEVICE *dptr);
static uint16 sync_iot (uint16, uint16);
static t_stat sync_svc (UNIT *uptr);

Expand Down Expand Up @@ -83,7 +84,7 @@ static DEBTAB dp_deb[] = {
DEVICE dp_dev = {
"DP", &dp_unit, dp_reg, NULL,
1, 8, 16, 1, 8, 16,
NULL, NULL, NULL,
NULL, NULL, dp_reset,
NULL, NULL, NULL, &dp_imdev, DEV_DEBUG, 0, dp_deb,
NULL, NULL, NULL, NULL, NULL, NULL
};
Expand Down Expand Up @@ -131,7 +132,7 @@ dp_on (int flag)
if (SYNC && HALT)
flag_on (FLAG_SYNC);
}
ON = flag;
ON = (uint16) flag;
}

uint16
Expand Down Expand Up @@ -474,6 +475,13 @@ dp_svc(UNIT * uptr)
return SCPE_OK;
}

static t_stat
dp_reset(DEVICE * uptr)
{
sim_activate_abs (&dp_unit, 0);
return SCPE_OK;
}

static t_stat
sync_svc (UNIT *uptr)
{
Expand Down
Loading