Commit graph

109 commits

Author SHA1 Message Date
Mark Pizzolato
4d923dbccf PDP8: Compiler warning cleanup
- Initialize local state variables to 0.  Likely non functional changes due
  to lack of depth in static analysis scan.  Coverity detects real problems
  like this.
- Fix inconsistent statement indentation.
2020-10-19 12:30:10 -07:00
Bob Supnik
6e7d808bb5 PDP8: Fixed comments in DT device bootstrap 2020-09-15 14:38:45 -07:00
Mark Pizzolato
ae825c9afb All: Declare sim_stop_messages as an array SCPE_BASE long
This avoids a potential invalid pointer dereference when formatting
the return value from sim_instr() if it is < SCPE_BASE but greater
than the previously defined static array size.sizeof

Update simh.doc to reflect this generic change.
2020-09-02 15:56:07 -07:00
Mark Pizzolato
0045601823 PDP11, PDP8: Allow console input to configure parity and KSR mode 2020-07-24 19:05:04 -07:00
Mark Pizzolato
4a56d8703c PDP8: Avoid potential loss of photo cell unit events in RF device 2020-07-19 06:20:29 -07:00
Mark Pizzolato
798389428c PDP8: Report unimplemented DUMP command and give suggestion
As discussed in #852
2020-06-02 10:31:20 -07:00
Bob Supnik
0e95c3e666 PDP8: Correct comments attributing Bernhard Baehr's description of the TSC8-75 2020-05-29 09:14:49 -07:00
Mark Pizzolato
323cd48244 PDP8: Open LPT, PTP devices for append
This implements the principle of "least surprise", in that users won't
normally expect to start overwriting an existing file on these devices.
Real hardware didn't behave that way.  A new (empty) file can always
be created with the -N switch on the ATTACH.
2020-04-30 05:08:29 -07:00
Mark Pizzolato
f9883668f1 NOVA, ECLIPSE, PDP11, PDP8, SIGMA, Unibus VAXen: Call tape detach API on unload 2020-04-04 09:49:15 -07:00
Mark Pizzolato
27c2dfa8f0 All DECtape devices: Undo previous unnecessary change relating to -A switch
Although these devices interpret a -A switch at attach time, they are not
sequential output devices and thus don't have an ambiguous interpretation
of the switch.

Incorrectly mentioned in #821
2020-03-24 08:35:55 -07:00
Mark Pizzolato
1c589030ae TIMER: Provide a means for VM to indicate its expected calibration rate
As reported and discussed in #817

This allows RUNLIMIT to provide useful results on fast or slow host systems.
2020-03-23 07:48:45 -07:00
Mark Pizzolato
614ad52091 All: Fix devices that attach files and have special meaning for -A switch
The -A attach time switch implicitly means to open files in append
mode.

Some devices used -A to indicate ASCII data or AUTOSIZE of disk or
fixed size tapes - DECtape.  These devices are either read only devices
(Paper tape readers or card readers), so explicit forcing of the attach
to be -R avoids unexpected positioning errors.  The random access
Disk and fixed sized tapes buffer the container contents in memory
so append mode isn't relevant, but care must be taken to assure that
the buffer reading starts at the beginning of the file without regard
to the explicit open mode.

As reported in #821
2020-03-22 09:54:54 -07:00
Mark Pizzolato
ee317e0cb4 SCP: Adjust RUNLIMIT time values on slow host systems
As reported and discussed in #819
2020-03-21 21:30:58 -07:00
Mats Engstrom
eef738e7fb Fix prematurely stopped diag test 2020-01-20 11:54:59 +01:00
Mark Pizzolato
68cfea6a71 PDP8: A 2 minute execution limit to diagnostic tests 2020-01-09 02:49:22 -08:00
B. Scott Michel
89a9414aeb PDP8: Add initial round of PDP-8 system diags 2020-01-01 16:03:54 -08:00
Mark Pizzolato
281837c68a PDP11, PDP8, VAX8200: Fix Coverity flagged warnings 2019-10-20 22:57:02 -07:00
Mark Pizzolato
f75f28aa21 TIMER: Add mechanism to pre-calibrate the instruction execution rate 2019-05-28 23:56:58 -07:00
Mark Pizzolato
880c8a89b7 PDP11, PDP18b, PDP8, VAX750, SCP: Silence Coverity identified complaints 2019-02-20 08:32:37 -08:00
Mark Pizzolato
6fa8f6012c PDP8: Add device descriptions to all devices 2018-12-15 12:55:54 -08:00
Mark Pizzolato
a92dc610a4 alpha, pdp18b, PDP8, sigma: removed stray tabs which crept in over time. 2018-04-01 14:22:30 -07:00
Bob Supnik
e270da1530 GRI, PDP11, PDP8, VAX: Misc formatting and typo cleanups 2018-03-09 14:04:19 -08:00
Bob Supnik
5b5e0f9c35 H316, I7094, NOVA, PDP1, PDP10, PDP8, SDS: Coverity singleton errors
Most history routines defined a local sim_eval of the proper length, but the
erroneous ones were fixed length machines that defined an integer variable
instead of an integer array of length 1. The VAX used the global sim_eval.
The changes follow the VAX practice.
2017-09-07 09:59:04 -07:00
Bob Supnik
c97f466457 PDP8: Annotate fall through paths in switch statements
The code is a bit difficult to understand, but it represents the 'normal'
path for processing a DECtape word. The code always flows all the
way to the break.

For start of block, there's extra code to check for a timing error; but
then the first word is processed (case 0).

For a normal word, a 3-cycle data break is done - increment word
count and current address, check for word count overflow, put the
word in the buffer; but then check for end of block (case DTO_WCO).

If the word count has already overflowed,  just check for end of block.

So yes, the end of case 0 should be labeled 'fall through' as well.

FNC_WRIT has the same structure and needs the same comment.
2017-03-30 07:12:57 -07:00
Bob Supnik
3eb4598456 SCP: Removed KBD_WAIT and friends 2017-03-20 22:33:38 -07:00
Bob Supnik
62879beb70 PDP1, PDP8, PDP18B, PDP11: Fixed dt_seterr to clear successor states
For the PDP11, this includes deferring the setting of DONE on an error, allowing RSTS V4 to work correctly.

There was a minor (possibly only theoretical) bug in dt_seterr as well.
dt_seterr is supposed to stop the drive. If the drive is accelerating, at
speed, or stopped, it works fine. But if the drive is decelerating, it did
not clear out the "successor" states. In theory, the drive could be in the
middle of reversing - that is, there are successor states of accelerating
(in reverse) and at speed. So the successor states need to be cleared,
or the drive won't actually stop.

The fifth DECtape controller (the PDP8's TD8E) is much simpler and
doesn't have the problem.
2017-03-15 10:04:52 -07:00
Bob Supnik
d1768d2771 PDP10, PDP11, PDP18B, PDP8: Annotate switch case fall through (COVERITY) 2017-03-13 10:59:06 -07:00
Bob Supnik
f26fa3d17f PDP8: Fixed PCQ_ENTRY for interrupts (COVERITY) 2017-03-09 19:49:34 -08:00
Bob Supnik
c02584440b PDP8: Change RESET CPU to clear L'AC
As discussed in #400 and described in the maintenance manuals and/or
schematics for all five PDP-8 models (8, 8/S, 8/I, 8/E, 8/A).
2017-02-19 21:39:02 -08:00
Bob Supnik
d14243c858 PDP8: Renamed switch register variable to SR
As discussed in: #385
2017-01-28 12:15:34 -08:00
Mark Pizzolato
d8dbc7e6b5 SCP: Migrate all stdio writes to pass through SCP provided Fprintf() 2017-01-14 20:48:09 -08:00
Mark Pizzolato
e52ac6d57f SCP: Add help for NOEXPECT and spelling cleanups 2016-12-29 13:52:06 -08:00
David Gesswein
5ced037b4b PDP8: Add device codes for TTIX & TTOX devices to show command output 2016-12-19 04:55:43 -08:00
Mark Pizzolato
7964e2b72d PDP8: Fix SHOW TTIX SUMMARY
It was defined in lowercase and has now been made upper case for consistency.
The code which performs the match also has been change to do a case
insensitive compare.
2016-12-17 13:38:22 -08:00
Bob Supnik
5fc4744d8a PDP8: Added LS8E decode (6660) for WPS8 and PKSTF
As discussed in #353
2016-12-16 14:54:23 -08:00
David Gesswein
9c32c97d38 PDP8: Printing from wps-8
As discussed in #353
2016-12-16 10:03:40 -08:00
Mark Pizzolato
9c0b0ffb46 PDP8: Add support for 16 terminals in the TTIX device 2016-10-10 16:59:03 -07:00
Mark Pizzolato
da3f5359bb VAX, PDP11, PDP8, PDP1: Properly declare timer with clock unit 2016-09-26 15:55:50 -07:00
Mark Pizzolato
063cec087a PDP8: Changed console input polling to poll for input 500ms has passed 2016-09-24 05:02:47 -07:00
Mark Pizzolato
5531ccb175 ALL: Massive 'const' cleanup
These changes facilitate more robust parameter type checking and helps
to identify unexpected coding errors.

Most simulators can now also be compiled with a C++ compiler without
warnings.

Additionally, these changes have also been configured to facilitate easier
backporting of simulator and device simulation modules to run under the
simh v3.9+ SCP framework.
2016-05-15 15:25:33 -07:00
Ray Jewhurst
60c9289c1d PDP-8: Update FPP register descriptions 2016-04-10 23:24:24 -07:00
Ray Jewhurst
81f68216ec PDP-8: added register description and fixed typo in doc 2016-04-10 12:54:18 -07:00
Mark Pizzolato
e153b7f224 PDP8, VAX750: Fix compiler detected errors in REG initializers 2016-03-18 15:43:30 -07:00
Mark Pizzolato
41978eca80 All: Convert from C runtime library perror() to sim_perror so that all messages will arrive in the same place(s). 2015-04-03 19:56:37 -07:00
Mark Pizzolato
66dba79418 ALPHA, ALTAIR, AltairZ80, I7094, NOVA, PDP1, PDP10, PDP11, PDP18B, PDP8, SAGE, sigma, swtp6800, TX-0, VAX: Change tabs to spaces which had crept in over time 2015-03-30 10:24:24 -07:00
Mark Pizzolato
e768629009 SCP: Added the capability for EXAMINE command output to be written directly to a socket. 2015-02-21 12:40:36 -08:00
Mark Pizzolato
54a4845fb2 ALL: Revert "ALL: make sure all useful state is in simh registers while processing events"
This reverts commit 5551a0dd9c.

The original idea was that the state being put into simh registers would be required to have all useful information available when remote console executed commands.  These steps were taken from the code that sim_instr() executed as it was exiting.  After this change was made it was realized that once a remote console command executed it might change state that directly affected instruction execution.  To solve this, the logic that executes before the instructions in sim_instr() would then need to be executed whenever the event dispatch processing completed.  This approach is messy, burdensome and potentially a lot of overhead for every event dispatch even though almost none of the event dispatches would be for remote console command execution.  A completely different approach was suggested by J. David Bryan.  That alternative approach would be to have remote console commands execute outside of the sim_instr() routine.  Thus allowing the existing prelude and postlude code in sim_instr() to be performed naturally and let the remote console activities run in the same context as all other simh commands.  Recent changes to scp and sim_console implement this alternative approach and thus these original changes are completely irrelevant and are thus being removed.
2015-02-15 12:42:32 -08:00
Mark Pizzolato
5551a0dd9c ALL: make sure all useful state is in simh registers while processing events 2015-01-15 12:37:07 -08:00
Mark Pizzolato
995ab8f1e2 More General cleanup migrate to using sim_printf vs separate calls to printf and fprintf(sim_log). 2014-10-24 14:37:37 -07:00
Mark Pizzolato
6ce8d99cd8 SCP: Added generic output routine sim_printf to output to stdout and sim_log (and sim_deb when enabled)
The goals here being to simplify calling code while getting consistent output delivered everywhere it may be useful.

Modified most places which explicitly used sim_log or merely called printf to now avoid doing that and merely call sim_printf().
2014-03-28 08:20:05 -07:00