Compiler suggested cleanups.
This commit is contained in:
parent
c638492048
commit
c548b34772
36 changed files with 877 additions and 882 deletions
|
@ -179,8 +179,8 @@ typedef struct _UDP_PACKET UDP_PACKET;
|
||||||
#define UDP_HEADER_LEN (2*sizeof(uint32) + sizeof(uint16))
|
#define UDP_HEADER_LEN (2*sizeof(uint32) + sizeof(uint16))
|
||||||
|
|
||||||
// Locals ...
|
// Locals ...
|
||||||
UDP_LINK udp_links[MAXLINKS] = {0}; // data for every active connection
|
UDP_LINK udp_links[MAXLINKS] = { {0} }; // data for every active connection
|
||||||
TMLN udp_lines[MAXLINKS] = { 0 }; // line descriptors
|
TMLN udp_lines[MAXLINKS] = { {0} }; // line descriptors
|
||||||
TMXR udp_tmxr = { MAXLINKS, NULL, 0, udp_lines};// datagram mux
|
TMXR udp_tmxr = { MAXLINKS, NULL, 0, udp_lines};// datagram mux
|
||||||
|
|
||||||
int32 udp_find_free_link (void)
|
int32 udp_find_free_link (void)
|
||||||
|
@ -402,7 +402,7 @@ int32 udp_receive (DEVICE *dptr, int32 link, uint16 *pdata, uint16 maxbuf)
|
||||||
|
|
||||||
while ((pktlen = udp_receive_packet(link, &pkt)) > 0) {
|
while ((pktlen = udp_receive_packet(link, &pkt)) > 0) {
|
||||||
// First do some header checks for a valid UDP packet ...
|
// First do some header checks for a valid UDP packet ...
|
||||||
if (pktlen < UDP_HEADER_LEN) {
|
if (((size_t)pktlen) < UDP_HEADER_LEN) {
|
||||||
sim_debug(IMP_DBG_UDP, dptr, "link %d - received packet w/o header (length=%d)\n", link, pktlen);
|
sim_debug(IMP_DBG_UDP, dptr, "link %d - received packet w/o header (length=%d)\n", link, pktlen);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,171 +1,171 @@
|
||||||
0x01, "DUP - COMMON SUBROUTINES",
|
{0x01, "DUP - COMMON SUBROUTINES"},
|
||||||
0x02, "DUP - CTRL RECORD PROCESSOR",
|
{0x02, "DUP - CTRL RECORD PROCESSOR"},
|
||||||
0x03, "DUP - STORE PHASE",
|
{0x03, "DUP - STORE PHASE"},
|
||||||
0x04, "DUP - *FILES, *LOCAL, *NOCAL PHASE",
|
{0x04, "DUP - *FILES, *LOCAL, *NOCAL PHASE"},
|
||||||
0x05, "DUP - DUMP PHASE",
|
{0x05, "DUP - DUMP PHASE"},
|
||||||
0x06, "DUP - DUMP LET/FLET PHASE",
|
{0x06, "DUP - DUMP LET/FLET PHASE"},
|
||||||
0x07, "DUP - DELETE PHASE",
|
{0x07, "DUP - DELETE PHASE"},
|
||||||
0x08, "DUP - DEFINE PHASE",
|
{0x08, "DUP - DEFINE PHASE"},
|
||||||
0x09, "DUP - EXIT PHASE",
|
{0x09, "DUP - EXIT PHASE"},
|
||||||
0x0A, "DUP - CARD I/O INTERFACE",
|
{0x0A, "DUP - CARD I/O INTERFACE"},
|
||||||
0x0B, "DUP - KEYBOARD INPUT INTERFACE",
|
{0x0B, "DUP - KEYBOARD INPUT INTERFACE"},
|
||||||
0x0C, "DUP - PAPER TAPE I/O INTERFACE",
|
{0x0C, "DUP - PAPER TAPE I/O INTERFACE"},
|
||||||
0x0D, "DUP - SAVED UPCOR PHASE",
|
{0x0D, "DUP - SAVED UPCOR PHASE"},
|
||||||
0x0E, "DUP - PRINCIPAL I/O DUMMY PHASE",
|
{0x0E, "DUP - PRINCIPAL I/O DUMMY PHASE"},
|
||||||
0x0F, "DUP - PRINCIPAL I/O (W/O KB) DUMMY PHASE",
|
{0x0F, "DUP - PRINCIPAL I/O (W/O KB) DUMMY PHASE"},
|
||||||
0x10, "DUP - PAPER TAPE I/O DUMMY PHASE",
|
{0x10, "DUP - PAPER TAPE I/O DUMMY PHASE"},
|
||||||
0x11, "DUP - MOVE DCI PROGRAMS TO UA OR FXA",
|
{0x11, "DUP - MOVE DCI PROGRAMS TO UA OR FXA"},
|
||||||
0x12, "DUP - EXIT TO MODIF DUMMY PHASE",
|
{0x12, "DUP - EXIT TO MODIF DUMMY PHASE"},
|
||||||
|
|
||||||
0x1F, "FOR - INPUT PHASE",
|
{0x1F, "FOR - INPUT PHASE"},
|
||||||
0x20, "FOR - CLASSIFIERPHASE",
|
{0x20, "FOR - CLASSIFIERPHASE"},
|
||||||
0x21, "FOR - CHECK ORDER/ST NO PHASE",
|
{0x21, "FOR - CHECK ORDER/ST NO PHASE"},
|
||||||
0x22, "FOR - COMMON SUBR OR FUNCTION PHASE",
|
{0x22, "FOR - COMMON SUBR OR FUNCTION PHASE"},
|
||||||
0x23, "FOR - DIMENSION/REAL/INTEGER PHASE",
|
{0x23, "FOR - DIMENSION/REAL/INTEGER PHASE"},
|
||||||
0x24, "FOR - REAL CONSTANT PHASE",
|
{0x24, "FOR - REAL CONSTANT PHASE"},
|
||||||
0x25, "FOR - DEFINE FILE, CALL LINK/EXIT PHASE",
|
{0x25, "FOR - DEFINE FILE, CALL LINK/EXIT PHASE"},
|
||||||
0x26, "FOR - VARIABLE, STMT FUNC PHASE",
|
{0x26, "FOR - VARIABLE, STMT FUNC PHASE"},
|
||||||
0x27, "FOR - DATA STATEMENT PHASE",
|
{0x27, "FOR - DATA STATEMENT PHASE"},
|
||||||
0x28, "FOR - FORMAT STATEMENT PHASE",
|
{0x28, "FOR - FORMAT STATEMENT PHASE"},
|
||||||
0x29, "FOR - SUBTRACT DECOMPOSITION PHASE",
|
{0x29, "FOR - SUBTRACT DECOMPOSITION PHASE"},
|
||||||
0x2A, "FOR - ASCAN I PHASE",
|
{0x2A, "FOR - ASCAN I PHASE"},
|
||||||
0x2B, "FOR - ASCAN II PHASE",
|
{0x2B, "FOR - ASCAN II PHASE"},
|
||||||
0x2C, "FOR - DO/CONTINUE/ETC PHASE",
|
{0x2C, "FOR - DO/CONTINUE/ETC PHASE"},
|
||||||
0x2D, "FOR - SUBSCRIPT OPTIMIZATION PHASE",
|
{0x2D, "FOR - SUBSCRIPT OPTIMIZATION PHASE"},
|
||||||
0x2E, "FOR - SCAN PHASE",
|
{0x2E, "FOR - SCAN PHASE"},
|
||||||
0x2F, "FOR - EXPANDER I PHASE",
|
{0x2F, "FOR - EXPANDER I PHASE"},
|
||||||
0x30, "FOR - EXPANDER II PHASE",
|
{0x30, "FOR - EXPANDER II PHASE"},
|
||||||
0x31, "FOR - DATA ALLOCATION PHASE",
|
{0x31, "FOR - DATA ALLOCATION PHASE"},
|
||||||
0x32, "FOR - COMPILATION ERROR PHASE",
|
{0x32, "FOR - COMPILATION ERROR PHASE"},
|
||||||
0x33, "FOR - STATEMENT ALLOCATION PHASE",
|
{0x33, "FOR - STATEMENT ALLOCATION PHASE"},
|
||||||
0x34, "FOR - LIST STATEMENT PHASE",
|
{0x34, "FOR - LIST STATEMENT PHASE"},
|
||||||
0x35, "FOR - LIST SYMBOL TABLE PHASE",
|
{0x35, "FOR - LIST SYMBOL TABLE PHASE"},
|
||||||
0x36, "FOR - LIST CONSTANTS PHASE",
|
{0x36, "FOR - LIST CONSTANTS PHASE"},
|
||||||
0x37, "FOR - OUTPUT I PHASE",
|
{0x37, "FOR - OUTPUT I PHASE"},
|
||||||
0x38, "FOR - OUTPUT II PHASE",
|
{0x38, "FOR - OUTPUT II PHASE"},
|
||||||
0x39, "FOR - RECOVERY/EXIT PHASE",
|
{0x39, "FOR - RECOVERY/EXIT PHASE"},
|
||||||
|
|
||||||
0X51, "COBOL 51",
|
{0X51, "COBOL 51"},
|
||||||
0X52, "COBOL 52",
|
{0X52, "COBOL 52"},
|
||||||
0X53, "COBOL 53",
|
{0X53, "COBOL 53"},
|
||||||
0X54, "COBOL 54",
|
{0X54, "COBOL 54"},
|
||||||
0X55, "COBOL 55",
|
{0X55, "COBOL 55"},
|
||||||
0X56, "COBOL 56",
|
{0X56, "COBOL 56"},
|
||||||
0X57, "COBOL 57",
|
{0X57, "COBOL 57"},
|
||||||
0X58, "COBOL 58",
|
{0X58, "COBOL 58"},
|
||||||
0X59, "COBOL 59",
|
{0X59, "COBOL 59"},
|
||||||
0X5A, "COBOL 5A",
|
{0X5A, "COBOL 5A"},
|
||||||
0X5B, "COBOL 5B",
|
{0X5B, "COBOL 5B"},
|
||||||
0X5C, "COBOL 5C",
|
{0X5C, "COBOL 5C"},
|
||||||
|
|
||||||
0X6E, "SUP PHASE 1 - MONITOR CONTROL RECORD ANALYZER",
|
{0X6E, "SUP PHASE 1 - MONITOR CONTROL RECORD ANALYZER"},
|
||||||
0x6F, "SUP PHASE 2 - JOB PROCESSING",
|
{0x6F, "SUP PHASE 2 - JOB PROCESSING"},
|
||||||
0x70, "SUP PHASE 3 - DELETE TEMPORARY LET",
|
{0x70, "SUP PHASE 3 - DELETE TEMPORARY LET"},
|
||||||
0x71, "SUP PHASE 4 - XEQ PROCESSING",
|
{0x71, "SUP PHASE 4 - XEQ PROCESSING"},
|
||||||
0x72, "SUP PHASE 5 - SUPV CONTROL REC PROCESSING",
|
{0x72, "SUP PHASE 5 - SUPV CONTROL REC PROCESSING"},
|
||||||
0X73, "SYSTEM DUMP-CORE-TO-PRINTER",
|
{0X73, "SYSTEM DUMP-CORE-TO-PRINTER"},
|
||||||
0X74, "AUXILIARY SUPERVISOR",
|
{0X74, "AUXILIARY SUPERVISOR"},
|
||||||
0X78, "CORE LOAD BUILDER, PHASE 1",
|
{0X78, "CORE LOAD BUILDER, PHASE 1"},
|
||||||
0x79, "CORE LOAD BUILDER, PHASE 2",
|
{0x79, "CORE LOAD BUILDER, PHASE 2"},
|
||||||
0x7A, "CORE LOAD BUILDER, PHASE 3",
|
{0x7A, "CORE LOAD BUILDER, PHASE 3"},
|
||||||
0x7B, "CORE LOAD BUILDER, PHASE 4",
|
{0x7B, "CORE LOAD BUILDER, PHASE 4"},
|
||||||
0x7C, "CORE LOAD BUILDER, PHASE 5",
|
{0x7C, "CORE LOAD BUILDER, PHASE 5"},
|
||||||
0x7D, "CORE LOAD BUILDER, PHASE 6",
|
{0x7D, "CORE LOAD BUILDER, PHASE 6"},
|
||||||
0x7E, "CORE LOAD BUILDER, PHASE 7",
|
{0x7E, "CORE LOAD BUILDER, PHASE 7"},
|
||||||
0x7F, "CORE LOAD BUILDER, PHASE 8",
|
{0x7F, "CORE LOAD BUILDER, PHASE 8"},
|
||||||
0x80, "CORE LOAD BUILDER, PHASE 9",
|
{0x80, "CORE LOAD BUILDER, PHASE 9"},
|
||||||
0x81, "CORE LOAD BUILDER, PHASE 10",
|
{0x81, "CORE LOAD BUILDER, PHASE 10"},
|
||||||
0x82, "CORE LOAD BUILDER, PHASE 11",
|
{0x82, "CORE LOAD BUILDER, PHASE 11"},
|
||||||
0x83, "CORE LOAD BUILDER, PHASE 12",
|
{0x83, "CORE LOAD BUILDER, PHASE 12"},
|
||||||
0x84, "CORE LOAD BUILDER, PHASE 13",
|
{0x84, "CORE LOAD BUILDER, PHASE 13"},
|
||||||
|
|
||||||
0X8C, "SYS 1403 READER",
|
{0X8C, "SYS 1403 READER"},
|
||||||
0x8D, "SYS 1132 PRINTER",
|
{0x8D, "SYS 1132 PRINTER"},
|
||||||
0x8E, "SYS CONSOLE PRINTER",
|
{0x8E, "SYS CONSOLE PRINTER"},
|
||||||
0x8F, "SYS 2501/1442 READER",
|
{0x8F, "SYS 2501/1442 READER"},
|
||||||
0x90, "SYS 1442/1442 READER",
|
{0x90, "SYS 1442/1442 READER"},
|
||||||
0x91, "SYS 1134/1055 PAPER TAPE IO",
|
{0x91, "SYS 1134/1055 PAPER TAPE IO"},
|
||||||
0x92, "SYS KEYBOARD",
|
{0x92, "SYS KEYBOARD"},
|
||||||
0x93, "SYS 2501/1442 CONVERSION",
|
{0x93, "SYS 2501/1442 CONVERSION"},
|
||||||
0x94, "SYS 1134/1055 CONVERSION",
|
{0x94, "SYS 1134/1055 CONVERSION"},
|
||||||
0x95, "SYS KEYBOARD CONVERSION",
|
{0x95, "SYS KEYBOARD CONVERSION"},
|
||||||
0x96, "DISKZ",
|
{0x96, "DISKZ"},
|
||||||
0x97, "SYS DISK1",
|
{0x97, "SYS DISK1"},
|
||||||
0x98, "SYS DISKN",
|
{0x98, "SYS DISKN"},
|
||||||
|
|
||||||
0xA0, "CIL CORE IMAGE LOADER - PHASE 1",
|
{0xA0, "CIL CORE IMAGE LOADER - PHASE 1"},
|
||||||
0xA1, "CIL CORE IMAGE LOADER - PHASE 2",
|
{0xA1, "CIL CORE IMAGE LOADER - PHASE 2"},
|
||||||
|
|
||||||
0XB0, "RPG B0",
|
{0XB0, "RPG B0"},
|
||||||
0XB1, "RPG B1",
|
{0XB1, "RPG B1"},
|
||||||
0XB2, "RPG B2",
|
{0XB2, "RPG B2"},
|
||||||
0XB3, "RPG B3",
|
{0XB3, "RPG B3"},
|
||||||
0XB4, "RPG B4",
|
{0XB4, "RPG B4"},
|
||||||
0XB5, "RPG B5",
|
{0XB5, "RPG B5"},
|
||||||
0XB6, "RPG B6",
|
{0XB6, "RPG B6"},
|
||||||
0XB7, "RPG B7",
|
{0XB7, "RPG B7"},
|
||||||
0XB8, "RPG B8",
|
{0XB8, "RPG B8"},
|
||||||
0XB9, "RPG B9",
|
{0XB9, "RPG B9"},
|
||||||
0XBA, "RPG BA",
|
{0XBA, "RPG BA"},
|
||||||
0XBB, "RPG BB",
|
{0XBB, "RPG BB"},
|
||||||
0XBC, "RPG BC",
|
{0XBC, "RPG BC"},
|
||||||
0XBD, "RPG BD",
|
{0XBD, "RPG BD"},
|
||||||
0XBE, "RPG BE",
|
{0XBE, "RPG BE"},
|
||||||
0XBF, "RPG BF",
|
{0XBF, "RPG BF"},
|
||||||
0XC0, "RPG C0",
|
{0XC0, "RPG C0"},
|
||||||
0XC1, "RPG C1",
|
{0XC1, "RPG C1"},
|
||||||
0XC2, "RPG C2",
|
{0XC2, "RPG C2"},
|
||||||
0XC3, "RPG C3",
|
{0XC3, "RPG C3"},
|
||||||
0XC4, "RPG C4",
|
{0XC4, "RPG C4"},
|
||||||
0XC5, "RPG C5",
|
{0XC5, "RPG C5"},
|
||||||
0XC6, "RPG C6",
|
{0XC6, "RPG C6"},
|
||||||
0XC7, "RPG C7",
|
{0XC7, "RPG C7"},
|
||||||
0XC8, "RPG C8",
|
{0XC8, "RPG C8"},
|
||||||
0XC9, "RPG C9",
|
{0XC9, "RPG C9"},
|
||||||
0XCA, "RPG CA",
|
{0XCA, "RPG CA"},
|
||||||
0XCB, "RPG CB",
|
{0XCB, "RPG CB"},
|
||||||
0XCC, "RPG CC",
|
{0XCC, "RPG CC"},
|
||||||
|
|
||||||
0XCD, "DUP PART 2 - CTRL",
|
{0XCD, "DUP PART 2 - CTRL"},
|
||||||
0XCE, "DUP PART 2 - MACRO UPDATE",
|
{0XCE, "DUP PART 2 - MACRO UPDATE"},
|
||||||
|
|
||||||
0XCF, "ASM INITIALIZATION PHASE",
|
{0XCF, "ASM INITIALIZATION PHASE"},
|
||||||
0xD0, "ASM CARD CONVERSION PHASE",
|
{0xD0, "ASM CARD CONVERSION PHASE"},
|
||||||
0xD1, "ASM DSF OUTPUT PHASE",
|
{0xD1, "ASM DSF OUTPUT PHASE"},
|
||||||
0xD2, "ASM INTERMEDIATE INPUT PHASE",
|
{0xD2, "ASM INTERMEDIATE INPUT PHASE"},
|
||||||
0xD3, "ASM END STATEMENT PHASE",
|
{0xD3, "ASM END STATEMENT PHASE"},
|
||||||
0xD4, "ASM ASSEMBLY ERROR PHASE",
|
{0xD4, "ASM ASSEMBLY ERROR PHASE"},
|
||||||
0xD5, "ASM CONTROL CARDS I",
|
{0xD5, "ASM CONTROL CARDS I"},
|
||||||
0xD6, "ASM CONTROL CARDS 2",
|
{0xD6, "ASM CONTROL CARDS 2"},
|
||||||
0xD7, "ASM DUMMY SYST SYMBOL TBL",
|
{0xD7, "ASM DUMMY SYST SYMBOL TBL"},
|
||||||
0xD8, "ASM SYMBOL TABLE OPTIONS PHASE",
|
{0xD8, "ASM SYMBOL TABLE OPTIONS PHASE"},
|
||||||
0xD9, "ASM EXIT PHASE",
|
{0xD9, "ASM EXIT PHASE"},
|
||||||
0xDA, "ASM PROG HEADER MNEMONICS PH",
|
{0xDA, "ASM PROG HEADER MNEMONICS PH"},
|
||||||
0xDB, "ASM FILE STATEMENT PHASE",
|
{0xDB, "ASM FILE STATEMENT PHASE"},
|
||||||
0xDC, "ASM COMMON SUBROUTINES,ASCOM",
|
{0xDC, "ASM COMMON SUBROUTINES,ASCOM"},
|
||||||
0xE4, "ASM INTERMEDIATE I/O",
|
{0xE4, "ASM INTERMEDIATE I/O"},
|
||||||
0xE5, "ASM SYMBOL TABLE OVERFLOW",
|
{0xE5, "ASM SYMBOL TABLE OVERFLOW"},
|
||||||
0xDD, "ASM PROG CONTROL MNEMONICS PH",
|
{0xDD, "ASM PROG CONTROL MNEMONICS PH"},
|
||||||
0xDE, "ASM IMPERATIVE STATEMENTS PH",
|
{0xDE, "ASM IMPERATIVE STATEMENTS PH"},
|
||||||
0xDF, "ASM DECML,XFLC PROCESSING PH",
|
{0xDF, "ASM DECML,XFLC PROCESSING PH"},
|
||||||
0xE0, "ASM DECIMAL CONVERSION PH",
|
{0xE0, "ASM DECIMAL CONVERSION PH"},
|
||||||
0xE1, "ASM PROG LINKAGE PHASE",
|
{0xE1, "ASM PROG LINKAGE PHASE"},
|
||||||
0xE2, "ASM DMES PROCESSING PHASE",
|
{0xE2, "ASM DMES PROCESSING PHASE"},
|
||||||
0xE3, "ASM PUNCH CONVERSION PHASE",
|
{0xE3, "ASM PUNCH CONVERSION PHASE"},
|
||||||
0xE6, "ASM GRAPHIC ORDER PHASE",
|
{0xE6, "ASM GRAPHIC ORDER PHASE"},
|
||||||
0xE8, "ASM CONTROL CARDS III",
|
{0xE8, "ASM CONTROL CARDS III"},
|
||||||
0xE9, "ASM MACRO PH 1 - SPECIAL OP AND PREPROCESSI",
|
{0xE9, "ASM MACRO PH 1 - SPECIAL OP AND PREPROCESSI"},
|
||||||
0xEA, "MACRO PHASE 1A - SPECIAL PSEUDO OPS",
|
{0xEA, "MACRO PHASE 1A - SPECIAL PSEUDO OPS"},
|
||||||
0xEB, "MACRO PHASE 1B - CONDITIONAL ASM PSEUDO OPS",
|
{0xEB, "MACRO PHASE 1B - CONDITIONAL ASM PSEUDO OPS"},
|
||||||
0xEC, "ASM MACRO PHASE 2 - MACRO DEFINITION",
|
{0xEC, "ASM MACRO PHASE 2 - MACRO DEFINITION"},
|
||||||
0xED, "MACRO PHASE 2A - MACRO DEFINITION",
|
{0xED, "MACRO PHASE 2A - MACRO DEFINITION"},
|
||||||
0xEE, "MACRO PHASE 2B - MACRO DEFINITION",
|
{0xEE, "MACRO PHASE 2B - MACRO DEFINITION"},
|
||||||
0xEF, "MACRO PHASE 3 - MACRO EXPANSION",
|
{0xEF, "MACRO PHASE 3 - MACRO EXPANSION"},
|
||||||
0xF0, "MACRO PHASE 3A - MACRO EXPANSION",
|
{0xF0, "MACRO PHASE 3A - MACRO EXPANSION"},
|
||||||
0xF1, "MACRO PHASE 3B - MACRO EXPANSION",
|
{0xF1, "MACRO PHASE 3B - MACRO EXPANSION"},
|
||||||
0xE7, "ASM DIVISION OPERATOR",
|
{0xE7, "ASM DIVISION OPERATOR"},
|
||||||
0xF2, "ASM CROSS-REFERENCE PART I",
|
{0xF2, "ASM CROSS-REFERENCE PART I"},
|
||||||
0xF3, "ASM CROSS-REFERENCE PART 2A",
|
{0xF3, "ASM CROSS-REFERENCE PART 2A"},
|
||||||
0xF4, "ASM CROSS-REFERENCE PART 2B",
|
{0xF4, "ASM CROSS-REFERENCE PART 2B"},
|
||||||
0xF5, "ASM CROSS-REFERENCE PART 2C",
|
{0xF5, "ASM CROSS-REFERENCE PART 2C"},
|
||||||
0xF6, "ASM CROSS-REFERENCE PART III",
|
{0xF6, "ASM CROSS-REFERENCE PART III"},
|
||||||
|
|
|
@ -1,129 +1,129 @@
|
||||||
/* DMS R2V12 SLET without RPG, for debugging only */
|
/* DMS R2V12 SLET without RPG, for debugging only */
|
||||||
|
|
||||||
0x0001, 0x7c50, 0x032f, 0x0008,
|
{0x0001, 0x7c50, 0x032f, 0x0008},
|
||||||
0x0002, 0x11de, 0x05a2, 0x000b,
|
{0x0002, 0x11de, 0x05a2, 0x000b},
|
||||||
0x0003, 0x21de, 0x05a2, 0x0010,
|
{0x0003, 0x21de, 0x05a2, 0x0010},
|
||||||
0x0004, 0x01de, 0x03c0, 0x0015,
|
{0x0004, 0x01de, 0x03c0, 0x0015},
|
||||||
0x0005, 0x41de, 0x0550, 0x0018,
|
{0x0005, 0x41de, 0x0550, 0x0018},
|
||||||
0x0006, 0x01de, 0x03c0, 0x001d,
|
{0x0006, 0x01de, 0x03c0, 0x001d},
|
||||||
0x0007, 0x01de, 0x05a2, 0x0020,
|
{0x0007, 0x01de, 0x05a2, 0x0020},
|
||||||
0x0008, 0x01de, 0x05a2, 0x0025,
|
{0x0008, 0x01de, 0x05a2, 0x0025},
|
||||||
0x0009, 0x01de, 0x0500, 0x002a,
|
{0x0009, 0x01de, 0x0500, 0x002a},
|
||||||
0x000a, 0x7a06, 0x00db, 0x002e,
|
{0x000a, 0x7a06, 0x00db, 0x002e},
|
||||||
0x000b, 0x7a06, 0x0035, 0x002f,
|
{0x000b, 0x7a06, 0x0035, 0x002f},
|
||||||
0x000c, 0x7a06, 0x00d8, 0x0030,
|
{0x000c, 0x7a06, 0x00d8, 0x0030},
|
||||||
0x000d, 0x7782, 0x087c, 0x0031,
|
{0x000d, 0x7782, 0x087c, 0x0031},
|
||||||
0x000e, 0x7a06, 0x0248, 0x0038,
|
{0x000e, 0x7a06, 0x0248, 0x0038},
|
||||||
0x000f, 0x7a06, 0x0248, 0x003a,
|
{0x000f, 0x7a06, 0x0248, 0x003a},
|
||||||
0x0010, 0x7a06, 0x0248, 0x003c,
|
{0x0010, 0x7a06, 0x0248, 0x003c},
|
||||||
0x0011, 0x01de, 0x0280, 0x003e,
|
{0x0011, 0x01de, 0x0280, 0x003e},
|
||||||
0x0012, 0x0e6e, 0x0140, 0x0040,
|
{0x0012, 0x0e6e, 0x0140, 0x0040},
|
||||||
0x001f, 0x760c, 0x09f1, 0x0041,
|
{0x001f, 0x760c, 0x09f1, 0x0041},
|
||||||
0x0020, 0x7a34, 0x0500, 0x0049,
|
{0x0020, 0x7a34, 0x0500, 0x0049},
|
||||||
0x0021, 0x7a34, 0x0280, 0x004d,
|
{0x0021, 0x7a34, 0x0280, 0x004d},
|
||||||
0x0022, 0x7a34, 0x03c0, 0x004f,
|
{0x0022, 0x7a34, 0x03c0, 0x004f},
|
||||||
0x0023, 0x7a34, 0x0500, 0x0052,
|
{0x0023, 0x7a34, 0x0500, 0x0052},
|
||||||
0x0024, 0x7a34, 0x03c0, 0x0056,
|
{0x0024, 0x7a34, 0x03c0, 0x0056},
|
||||||
0x0025, 0x7a34, 0x0280, 0x0059,
|
{0x0025, 0x7a34, 0x0280, 0x0059},
|
||||||
0x0026, 0x7a34, 0x0500, 0x005b,
|
{0x0026, 0x7a34, 0x0500, 0x005b},
|
||||||
0x0027, 0x7a34, 0x03f0, 0x005f,
|
{0x0027, 0x7a34, 0x03f0, 0x005f},
|
||||||
0x0028, 0x7a34, 0x03c0, 0x0063,
|
{0x0028, 0x7a34, 0x03c0, 0x0063},
|
||||||
0x0029, 0x7a34, 0x03c0, 0x0066,
|
{0x0029, 0x7a34, 0x03c0, 0x0066},
|
||||||
0x002a, 0x7a34, 0x03c0, 0x0069,
|
{0x002a, 0x7a34, 0x03c0, 0x0069},
|
||||||
0x002b, 0x7a34, 0x03c0, 0x006c,
|
{0x002b, 0x7a34, 0x03c0, 0x006c},
|
||||||
0x002c, 0x7a34, 0x0500, 0x006f,
|
{0x002c, 0x7a34, 0x0500, 0x006f},
|
||||||
0x002d, 0x7a34, 0x0500, 0x0073,
|
{0x002d, 0x7a34, 0x0500, 0x0073},
|
||||||
0x002e, 0x7a34, 0x0500, 0x0077,
|
{0x002e, 0x7a34, 0x0500, 0x0077},
|
||||||
0x002f, 0x7a34, 0x0500, 0x007b,
|
{0x002f, 0x7a34, 0x0500, 0x007b},
|
||||||
0x0030, 0x7a34, 0x0500, 0x007f,
|
{0x0030, 0x7a34, 0x0500, 0x007f},
|
||||||
0x0031, 0x7a34, 0x0404, 0x0083,
|
{0x0031, 0x7a34, 0x0404, 0x0083},
|
||||||
0x0032, 0x7a34, 0x03c0, 0x0087,
|
{0x0032, 0x7a34, 0x03c0, 0x0087},
|
||||||
0x0033, 0x7a34, 0x03c0, 0x008a,
|
{0x0033, 0x7a34, 0x03c0, 0x008a},
|
||||||
0x0034, 0x7a34, 0x0280, 0x008d,
|
{0x0034, 0x7a34, 0x0280, 0x008d},
|
||||||
0x0035, 0x7a34, 0x03c0, 0x008f,
|
{0x0035, 0x7a34, 0x03c0, 0x008f},
|
||||||
0x0036, 0x7a34, 0x03c0, 0x0092,
|
{0x0036, 0x7a34, 0x03c0, 0x0092},
|
||||||
0x0037, 0x7a34, 0x0500, 0x0095,
|
{0x0037, 0x7a34, 0x0500, 0x0095},
|
||||||
0x0038, 0x7b96, 0x03c0, 0x0099,
|
{0x0038, 0x7b96, 0x03c0, 0x0099},
|
||||||
0x0039, 0x766e, 0x013e, 0x009c,
|
{0x0039, 0x766e, 0x013e, 0x009c},
|
||||||
0x006e, 0x04fe, 0x02fe, 0x009d,
|
{0x006e, 0x04fe, 0x02fe, 0x009d},
|
||||||
0x006f, 0x07fe, 0x052b, 0x00a0,
|
{0x006f, 0x07fe, 0x052b, 0x00a0},
|
||||||
0x0070, 0x07fe, 0x0280, 0x00a5,
|
{0x0070, 0x07fe, 0x0280, 0x00a5},
|
||||||
0x0071, 0x07fe, 0x0280, 0x00a7,
|
{0x0071, 0x07fe, 0x0280, 0x00a7},
|
||||||
0x0072, 0x07fe, 0x03ea, 0x00a9,
|
{0x0072, 0x07fe, 0x03ea, 0x00a9},
|
||||||
0x0073, 0x0506, 0x04f8, 0x00ad,
|
{0x0073, 0x0506, 0x04f8, 0x00ad},
|
||||||
0x0074, 0x0400, 0x0189, 0x00b1,
|
{0x0074, 0x0400, 0x0189, 0x00b1},
|
||||||
0x0078, 0x01e0, 0x0782, 0x00b3,
|
{0x0078, 0x01e0, 0x0782, 0x00b3},
|
||||||
0x0079, 0x05bc, 0x04dd, 0x00ba,
|
{0x0079, 0x05bc, 0x04dd, 0x00ba},
|
||||||
0x007a, 0x08b6, 0x01e8, 0x00be,
|
{0x007a, 0x08b6, 0x01e8, 0x00be},
|
||||||
0x007b, 0x08b6, 0x01e8, 0x00c0,
|
{0x007b, 0x08b6, 0x01e8, 0x00c0},
|
||||||
0x007c, 0x08b6, 0x01e8, 0x00c2,
|
{0x007c, 0x08b6, 0x01e8, 0x00c2},
|
||||||
0x007d, 0x08b6, 0x01e8, 0x00c4,
|
{0x007d, 0x08b6, 0x01e8, 0x00c4},
|
||||||
0x007e, 0x0aa0, 0x0140, 0x00c6,
|
{0x007e, 0x0aa0, 0x0140, 0x00c6},
|
||||||
0x007f, 0x0aa0, 0x0140, 0x00c7,
|
{0x007f, 0x0aa0, 0x0140, 0x00c7},
|
||||||
0x0080, 0x0aa0, 0x0140, 0x00c8,
|
{0x0080, 0x0aa0, 0x0140, 0x00c8},
|
||||||
0x0081, 0x0aa0, 0x0140, 0x00c9,
|
{0x0081, 0x0aa0, 0x0140, 0x00c9},
|
||||||
0x0082, 0x0be2, 0x0140, 0x00ca,
|
{0x0082, 0x0be2, 0x0140, 0x00ca},
|
||||||
0x0083, 0x08b6, 0x01e8, 0x00cb,
|
{0x0083, 0x08b6, 0x01e8, 0x00cb},
|
||||||
0x0084, 0x0aa0, 0x0140, 0x00cd,
|
{0x0084, 0x0aa0, 0x0140, 0x00cd},
|
||||||
0x008c, 0x0000, 0x0134, (int16)0x80ce,
|
{0x008c, 0x0000, 0x0134, (int16)0x80ce},
|
||||||
0x008d, 0x0000, 0x0113, 0x00cf,
|
{0x008d, 0x0000, 0x0113, 0x00cf},
|
||||||
0x008e, 0x0000, 0x011f, 0x00d0,
|
{0x008e, 0x0000, 0x011f, 0x00d0},
|
||||||
0x008f, 0x0000, 0x009c, (int16)0x80d1,
|
{0x008f, 0x0000, 0x009c, (int16)0x80d1},
|
||||||
0x0090, 0x0000, 0x00ab, 0x00d2,
|
{0x0090, 0x0000, 0x00ab, 0x00d2},
|
||||||
0x0091, 0x0000, 0x016c, (int16)0x80d3,
|
{0x0091, 0x0000, 0x016c, (int16)0x80d3},
|
||||||
0x0092, 0x0000, 0x0174, 0x00d5,
|
{0x0092, 0x0000, 0x0174, 0x00d5},
|
||||||
0x0093, 0x0000, 0x00b9, 0x00d7,
|
{0x0093, 0x0000, 0x00b9, 0x00d7},
|
||||||
0x0094, 0x0000, 0x0003, (int16)0x80d8,
|
{0x0094, 0x0000, 0x0003, (int16)0x80d8},
|
||||||
0x0095, 0x0000, 0x0003, 0x00d9,
|
{0x0095, 0x0000, 0x0003, 0x00d9},
|
||||||
0x0096, 0x00f0, 0x00ec, 0x00da,
|
{0x0096, 0x00f0, 0x00ec, 0x00da},
|
||||||
0x0097, 0x00f0, 0x01a2, 0x00db,
|
{0x0097, 0x00f0, 0x01a2, 0x00db},
|
||||||
0x0098, 0x00f0, 0x02b0, 0x00dd,
|
{0x0098, 0x00f0, 0x02b0, 0x00dd},
|
||||||
0x0099, 0x0000, 0x0113, 0x00cf,
|
{0x0099, 0x0000, 0x0113, 0x00cf},
|
||||||
0x009a, 0x0000, 0x00ab, 0x00d2,
|
{0x009a, 0x0000, 0x00ab, 0x00d2},
|
||||||
0x009b, 0x0000, 0x00ab, 0x00d2,
|
{0x009b, 0x0000, 0x00ab, 0x00d2},
|
||||||
0x009c, 0x0000, 0x00b9, 0x00d7,
|
{0x009c, 0x0000, 0x00b9, 0x00d7},
|
||||||
0x009d, 0x0000, 0x00b9, 0x00d7,
|
{0x009d, 0x0000, 0x00b9, 0x00d7},
|
||||||
0x00a0, 0x0000, 0x016c, 0x00e0,
|
{0x00a0, 0x0000, 0x016c, 0x00e0},
|
||||||
0x00a1, 0x0000, 0x01c0, 0x00e2,
|
{0x00a1, 0x0000, 0x01c0, 0x00e2},
|
||||||
0x00cd, 0x11de, 0x0280, 0x00e4,
|
{0x00cd, 0x11de, 0x0280, 0x00e4},
|
||||||
0x00ce, 0x01de, 0x11df, 0x00e6,
|
{0x00ce, 0x01de, 0x11df, 0x00e6},
|
||||||
0x00cf, 0x01e0, 0x026b, 0x00f5,
|
{0x00cf, 0x01e0, 0x026b, 0x00f5},
|
||||||
0x00d0, 0x01e8, 0x00bb, 0x00f7,
|
{0x00d0, 0x01e8, 0x00bb, 0x00f7},
|
||||||
0x00d1, 0x01e8, 0x005f, 0x00f8,
|
{0x00d1, 0x01e8, 0x005f, 0x00f8},
|
||||||
0x00d2, 0x01e8, 0x005f, 0x00f9,
|
{0x00d2, 0x01e8, 0x005f, 0x00f9},
|
||||||
0x00d3, 0x0280, 0x01d5, 0x00fa,
|
{0x00d3, 0x0280, 0x01d5, 0x00fa},
|
||||||
0x00d4, 0x0ad0, 0x0145, 0x00fc,
|
{0x00d4, 0x0ad0, 0x0145, 0x00fc},
|
||||||
0x00d5, 0x0280, 0x01d6, 0x00fe,
|
{0x00d5, 0x0280, 0x01d6, 0x00fe},
|
||||||
0x00d6, 0x0280, 0x0113, 0x0100,
|
{0x00d6, 0x0280, 0x0113, 0x0100},
|
||||||
0x00d7, 0x0000, 0x0130, 0x0101,
|
{0x00d7, 0x0000, 0x0130, 0x0101},
|
||||||
0x00d8, 0x07a8, 0x0254, 0x0102,
|
{0x00d8, 0x07a8, 0x0254, 0x0102},
|
||||||
0x00d9, 0x0280, 0x01d7, 0x0104,
|
{0x00d9, 0x0280, 0x01d7, 0x0104},
|
||||||
0x00da, 0x0280, 0x01a0, 0x0106,
|
{0x00da, 0x0280, 0x01a0, 0x0106},
|
||||||
0x00db, 0x0282, 0x00a3, 0x0108,
|
{0x00db, 0x0282, 0x00a3, 0x0108},
|
||||||
0x00dc, 0x0458, 0x05a7, 0x0109,
|
{0x00dc, 0x0458, 0x05a7, 0x0109},
|
||||||
0x00dd, 0x0280, 0x01d5, 0x010e,
|
{0x00dd, 0x0280, 0x01d5, 0x010e},
|
||||||
0x00de, 0x0280, 0x01d6, 0x0110,
|
{0x00de, 0x0280, 0x01d6, 0x0110},
|
||||||
0x00df, 0x0280, 0x017c, 0x0112,
|
{0x00df, 0x0280, 0x017c, 0x0112},
|
||||||
0x00e0, 0x0282, 0x0127, 0x0114,
|
{0x00e0, 0x0282, 0x0127, 0x0114},
|
||||||
0x00e1, 0x0280, 0x0196, 0x0115,
|
{0x00e1, 0x0280, 0x0196, 0x0115},
|
||||||
0x00e2, 0x0280, 0x01d8, 0x0117,
|
{0x00e2, 0x0280, 0x01d8, 0x0117},
|
||||||
0x00e3, 0x0280, 0x0099, 0x0119,
|
{0x00e3, 0x0280, 0x0099, 0x0119},
|
||||||
0x00e4, 0x098a, 0x005f, 0x011a,
|
{0x00e4, 0x098a, 0x005f, 0x011a},
|
||||||
0x00e5, 0x098a, 0x0062, 0x011b,
|
{0x00e5, 0x098a, 0x0062, 0x011b},
|
||||||
0x00e6, 0x0eca, 0x03c1, 0x011c,
|
{0x00e6, 0x0eca, 0x03c1, 0x011c},
|
||||||
0x00e7, 0x0280, 0x00b8, 0x0120,
|
{0x00e7, 0x0280, 0x00b8, 0x0120},
|
||||||
0x00e8, 0x0280, 0x017f, 0x0121,
|
{0x00e8, 0x0280, 0x017f, 0x0121},
|
||||||
0x00e9, 0x0280, 0x01d6, 0x0123,
|
{0x00e9, 0x0280, 0x01d6, 0x0123},
|
||||||
0x00ea, 0x0280, 0x01d9, 0x0125,
|
{0x00ea, 0x0280, 0x01d9, 0x0125},
|
||||||
0x00eb, 0x0280, 0x01d9, 0x0127,
|
{0x00eb, 0x0280, 0x01d9, 0x0127},
|
||||||
0x00ec, 0x0280, 0x01ca, 0x0129,
|
{0x00ec, 0x0280, 0x01ca, 0x0129},
|
||||||
0x00ed, 0x0280, 0x01c2, 0x012b,
|
{0x00ed, 0x0280, 0x01c2, 0x012b},
|
||||||
0x00ee, 0x05dc, 0x0158, 0x012d,
|
{0x00ee, 0x05dc, 0x0158, 0x012d},
|
||||||
0x00ef, 0x07ac, 0x0051, 0x012f,
|
{0x00ef, 0x07ac, 0x0051, 0x012f},
|
||||||
0x00f0, 0x0280, 0x01af, 0x0130,
|
{0x00f0, 0x0280, 0x01af, 0x0130},
|
||||||
0x00f1, 0x12f4, 0x027f, 0x0132,
|
{0x00f1, 0x12f4, 0x027f, 0x0132},
|
||||||
0x00f2, 0x0280, 0x01c7, 0x0134,
|
{0x00f2, 0x0280, 0x01c7, 0x0134},
|
||||||
0x00f3, 0x07a8, 0x0052, 0x0136,
|
{0x00f3, 0x07a8, 0x0052, 0x0136},
|
||||||
0x00f4, 0x0924, 0x005b, 0x0137,
|
{0x00f4, 0x0924, 0x005b, 0x0137},
|
||||||
0x00f5, 0x0886, 0x003d, 0x0138,
|
{0x00f5, 0x0886, 0x003d, 0x0138},
|
||||||
0x00f6, 0x0eca, 0x03b2, 0x0139,
|
{0x00f6, 0x0eca, 0x03b2, 0x0139},
|
||||||
|
|
|
@ -1063,7 +1063,7 @@ t_stat sim_instr (void)
|
||||||
if (src2 == 0) {
|
if (src2 == 0) {
|
||||||
V = 1; /* divide by zero just sets overflow, ACC & EXT are undefined */
|
V = 1; /* divide by zero just sets overflow, ACC & EXT are undefined */
|
||||||
}
|
}
|
||||||
else if (src2 == -1 && src == 0x80000000) {
|
else if ((src2 == -1) && ((uint32)src == 0x80000000)) {
|
||||||
V = 1; /* another special case: max negative int / -1 also overflows */
|
V = 1; /* another special case: max negative int / -1 also overflows */
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
|
@ -514,212 +514,212 @@ typedef struct {
|
||||||
|
|
||||||
static CPCODE cardcode_029[] =
|
static CPCODE cardcode_029[] =
|
||||||
{
|
{
|
||||||
0x0000, ' ',
|
{0x0000, ' '},
|
||||||
0x8000, '&', /* + in 026 Fortran */
|
{0x8000, '&'}, /* + in 026 Fortran */
|
||||||
0x4000, '-',
|
{0x4000, '-'},
|
||||||
0x2000, '0',
|
{0x2000, '0'},
|
||||||
0x1000, '1',
|
{0x1000, '1'},
|
||||||
0x0800, '2',
|
{0x0800, '2'},
|
||||||
0x0400, '3',
|
{0x0400, '3'},
|
||||||
0x0200, '4',
|
{0x0200, '4'},
|
||||||
0x0100, '5',
|
{0x0100, '5'},
|
||||||
0x0080, '6',
|
{0x0080, '6'},
|
||||||
0x0040, '7',
|
{0x0040, '7'},
|
||||||
0x0020, '8',
|
{0x0020, '8'},
|
||||||
0x0010, '9',
|
{0x0010, '9'},
|
||||||
0x9000, 'A',
|
{0x9000, 'A'},
|
||||||
0x8800, 'B',
|
{0x8800, 'B'},
|
||||||
0x8400, 'C',
|
{0x8400, 'C'},
|
||||||
0x8200, 'D',
|
{0x8200, 'D'},
|
||||||
0x8100, 'E',
|
{0x8100, 'E'},
|
||||||
0x8080, 'F',
|
{0x8080, 'F'},
|
||||||
0x8040, 'G',
|
{0x8040, 'G'},
|
||||||
0x8020, 'H',
|
{0x8020, 'H'},
|
||||||
0x8010, 'I',
|
{0x8010, 'I'},
|
||||||
0x5000, 'J',
|
{0x5000, 'J'},
|
||||||
0x4800, 'K',
|
{0x4800, 'K'},
|
||||||
0x4400, 'L',
|
{0x4400, 'L'},
|
||||||
0x4200, 'M',
|
{0x4200, 'M'},
|
||||||
0x4100, 'N',
|
{0x4100, 'N'},
|
||||||
0x4080, 'O',
|
{0x4080, 'O'},
|
||||||
0x4040, 'P',
|
{0x4040, 'P'},
|
||||||
0x4020, 'Q',
|
{0x4020, 'Q'},
|
||||||
0x4010, 'R',
|
{0x4010, 'R'},
|
||||||
0x3000, '/',
|
{0x3000, '/'},
|
||||||
0x2800, 'S',
|
{0x2800, 'S'},
|
||||||
0x2400, 'T',
|
{0x2400, 'T'},
|
||||||
0x2200, 'U',
|
{0x2200, 'U'},
|
||||||
0x2100, 'V',
|
{0x2100, 'V'},
|
||||||
0x2080, 'W',
|
{0x2080, 'W'},
|
||||||
0x2040, 'X',
|
{0x2040, 'X'},
|
||||||
0x2020, 'Y',
|
{0x2020, 'Y'},
|
||||||
0x2010, 'Z',
|
{0x2010, 'Z'},
|
||||||
0x0820, ':',
|
{0x0820, ':'},
|
||||||
0x0420, '#', /* = in 026 Fortran */
|
{0x0420, '#'}, /* = in 026 Fortran */
|
||||||
0x0220, '@', /* ' in 026 Fortran */
|
{0x0220, '@'}, /* ' in 026 Fortran */
|
||||||
0x0120, '\'',
|
{0x0120, '\''},
|
||||||
0x00A0, '=',
|
{0x00A0, '='},
|
||||||
0x0060, '"',
|
{0x0060, '"'},
|
||||||
0x8820, (unsigned char) '\xA2', /* cent, in MS-DOS encoding (this is in guess_cr_code as well) */
|
{0x8820, (unsigned char) '\xA2'}, /* cent, in MS-DOS encoding (this is in guess_cr_code as well) */
|
||||||
0x8420, '.',
|
{0x8420, '.'},
|
||||||
0x8220, '<', /* ) in 026 Fortran */
|
{0x8220, '<'}, /* ) in 026 Fortran */
|
||||||
0x8120, '(',
|
{0x8120, '('},
|
||||||
0x80A0, '+',
|
{0x80A0, '+'},
|
||||||
0x8060, '|',
|
{0x8060, '|'},
|
||||||
0x4820, '!',
|
{0x4820, '!'},
|
||||||
0x4420, '$',
|
{0x4420, '$'},
|
||||||
0x4220, '*',
|
{0x4220, '*'},
|
||||||
0x4120, ')',
|
{0x4120, ')'},
|
||||||
0x40A0, ';',
|
{0x40A0, ';'},
|
||||||
0x4060, (unsigned char) '\xAC', /* not, in MS-DOS encoding (this is in guess_cr_code as well) */
|
{0x4060, (unsigned char) '\xAC'}, /* not, in MS-DOS encoding (this is in guess_cr_code as well) */
|
||||||
0x2420, ',',
|
{0x2420, ','},
|
||||||
0x2220, '%', /* ( in 026 Fortran */
|
{0x2220, '%'}, /* ( in 026 Fortran */
|
||||||
0x2120, '_',
|
{0x2120, '_'},
|
||||||
0x20A0, '>',
|
{0x20A0, '>'},
|
||||||
0xB000, 'a',
|
{0xB000, 'a'},
|
||||||
0xA800, 'b',
|
{0xA800, 'b'},
|
||||||
0xA400, 'c',
|
{0xA400, 'c'},
|
||||||
0xA200, 'd',
|
{0xA200, 'd'},
|
||||||
0xA100, 'e',
|
{0xA100, 'e'},
|
||||||
0xA080, 'f',
|
{0xA080, 'f'},
|
||||||
0xA040, 'g',
|
{0xA040, 'g'},
|
||||||
0xA020, 'h',
|
{0xA020, 'h'},
|
||||||
0xA010, 'i',
|
{0xA010, 'i'},
|
||||||
0xD000, 'j',
|
{0xD000, 'j'},
|
||||||
0xC800, 'k',
|
{0xC800, 'k'},
|
||||||
0xC400, 'l',
|
{0xC400, 'l'},
|
||||||
0xC200, 'm',
|
{0xC200, 'm'},
|
||||||
0xC100, 'n',
|
{0xC100, 'n'},
|
||||||
0xC080, 'o',
|
{0xC080, 'o'},
|
||||||
0xC040, 'p',
|
{0xC040, 'p'},
|
||||||
0xC020, 'q',
|
{0xC020, 'q'},
|
||||||
0xC010, 'r',
|
{0xC010, 'r'},
|
||||||
0x6800, 's',
|
{0x6800, 's'},
|
||||||
0x6400, 't',
|
{0x6400, 't'},
|
||||||
0x6200, 'u',
|
{0x6200, 'u'},
|
||||||
0x6100, 'v',
|
{0x6100, 'v'},
|
||||||
0x6080, 'w',
|
{0x6080, 'w'},
|
||||||
0x6040, 'x',
|
{0x6040, 'x'},
|
||||||
0x6020, 'y',
|
{0x6020, 'y'},
|
||||||
0x6010, 'z', /* these odd punch codes are used by APL: */
|
{0x6010, 'z'}, /* these odd punch codes are used by APL: */
|
||||||
0x1010, '\001', /* no corresponding ASCII using ^A */
|
{0x1010, '\001'}, /* no corresponding ASCII using ^A */
|
||||||
0x0810, '\002', /* SYN using ^B */
|
{0x0810, '\002'}, /* SYN using ^B */
|
||||||
0x0410, '\003', /* no corresponding ASCII using ^C */
|
{0x0410, '\003'}, /* no corresponding ASCII using ^C */
|
||||||
0x0210, '\004', /* PUNCH ON using ^D */
|
{0x0210, '\004'}, /* PUNCH ON using ^D */
|
||||||
0x0110, '\005', /* READER STOP using ^E */
|
{0x0110, '\005'}, /* READER STOP using ^E */
|
||||||
0x0090, '\006', /* UPPER CASE using ^F */
|
{0x0090, '\006'}, /* UPPER CASE using ^F */
|
||||||
0x0050, '\013', /* EOT using ^K */
|
{0x0050, '\013'}, /* EOT using ^K */
|
||||||
0x0030, '\016', /* no corresponding ASCII using ^N */
|
{0x0030, '\016'}, /* no corresponding ASCII using ^N */
|
||||||
0x1030, '\017', /* no corresponding ASCII using ^O */
|
{0x1030, '\017'}, /* no corresponding ASCII using ^O */
|
||||||
0x0830, '\020', /* no corresponding ASCII using ^P */
|
{0x0830, '\020'}, /* no corresponding ASCII using ^P */
|
||||||
};
|
};
|
||||||
|
|
||||||
static CPCODE cardcode_026F[] = /* 026 fortran */
|
static CPCODE cardcode_026F[] = /* 026 fortran */
|
||||||
{
|
{
|
||||||
0x0000, ' ',
|
{0x0000, ' '},
|
||||||
0x8000, '+',
|
{0x8000, '+'},
|
||||||
0x4000, '-',
|
{0x4000, '-'},
|
||||||
0x2000, '0',
|
{0x2000, '0'},
|
||||||
0x1000, '1',
|
{0x1000, '1'},
|
||||||
0x0800, '2',
|
{0x0800, '2'},
|
||||||
0x0400, '3',
|
{0x0400, '3'},
|
||||||
0x0200, '4',
|
{0x0200, '4'},
|
||||||
0x0100, '5',
|
{0x0100, '5'},
|
||||||
0x0080, '6',
|
{0x0080, '6'},
|
||||||
0x0040, '7',
|
{0x0040, '7'},
|
||||||
0x0020, '8',
|
{0x0020, '8'},
|
||||||
0x0010, '9',
|
{0x0010, '9'},
|
||||||
0x9000, 'A',
|
{0x9000, 'A'},
|
||||||
0x8800, 'B',
|
{0x8800, 'B'},
|
||||||
0x8400, 'C',
|
{0x8400, 'C'},
|
||||||
0x8200, 'D',
|
{0x8200, 'D'},
|
||||||
0x8100, 'E',
|
{0x8100, 'E'},
|
||||||
0x8080, 'F',
|
{0x8080, 'F'},
|
||||||
0x8040, 'G',
|
{0x8040, 'G'},
|
||||||
0x8020, 'H',
|
{0x8020, 'H'},
|
||||||
0x8010, 'I',
|
{0x8010, 'I'},
|
||||||
0x5000, 'J',
|
{0x5000, 'J'},
|
||||||
0x4800, 'K',
|
{0x4800, 'K'},
|
||||||
0x4400, 'L',
|
{0x4400, 'L'},
|
||||||
0x4200, 'M',
|
{0x4200, 'M'},
|
||||||
0x4100, 'N',
|
{0x4100, 'N'},
|
||||||
0x4080, 'O',
|
{0x4080, 'O'},
|
||||||
0x4040, 'P',
|
{0x4040, 'P'},
|
||||||
0x4020, 'Q',
|
{0x4020, 'Q'},
|
||||||
0x4010, 'R',
|
{0x4010, 'R'},
|
||||||
0x3000, '/',
|
{0x3000, '/'},
|
||||||
0x2800, 'S',
|
{0x2800, 'S'},
|
||||||
0x2400, 'T',
|
{0x2400, 'T'},
|
||||||
0x2200, 'U',
|
{0x2200, 'U'},
|
||||||
0x2100, 'V',
|
{0x2100, 'V'},
|
||||||
0x2080, 'W',
|
{0x2080, 'W'},
|
||||||
0x2040, 'X',
|
{0x2040, 'X'},
|
||||||
0x2020, 'Y',
|
{0x2020, 'Y'},
|
||||||
0x2010, 'Z',
|
{0x2010, 'Z'},
|
||||||
0x0420, '=',
|
{0x0420, '='},
|
||||||
0x0220, '\'',
|
{0x0220, '\''},
|
||||||
0x8420, '.',
|
{0x8420, '.'},
|
||||||
0x8220, ')',
|
{0x8220, ')'},
|
||||||
0x8220, '<', /* if ASCII has <, treat like ) */
|
{0x8220, '<'}, /* if ASCII has <, treat like ) */
|
||||||
0x4420, '$',
|
{0x4420, '$'},
|
||||||
0x4220, '*',
|
{0x4220, '*'},
|
||||||
0x2420, ',',
|
{0x2420, ','},
|
||||||
0x2220, '(',
|
{0x2220, '('},
|
||||||
0x2220, '%', /* if ASCII has %, treat like ) */
|
{0x2220, '%'}, /* if ASCII has %, treat like ) */
|
||||||
};
|
};
|
||||||
|
|
||||||
static CPCODE cardcode_026C[] = /* 026 commercial */
|
static CPCODE cardcode_026C[] = /* 026 commercial */
|
||||||
{
|
{
|
||||||
0x0000, ' ',
|
{0x0000, ' '},
|
||||||
0x8000, '+',
|
{0x8000, '+'},
|
||||||
0x4000, '-',
|
{0x4000, '-'},
|
||||||
0x2000, '0',
|
{0x2000, '0'},
|
||||||
0x1000, '1',
|
{0x1000, '1'},
|
||||||
0x0800, '2',
|
{0x0800, '2'},
|
||||||
0x0400, '3',
|
{0x0400, '3'},
|
||||||
0x0200, '4',
|
{0x0200, '4'},
|
||||||
0x0100, '5',
|
{0x0100, '5'},
|
||||||
0x0080, '6',
|
{0x0080, '6'},
|
||||||
0x0040, '7',
|
{0x0040, '7'},
|
||||||
0x0020, '8',
|
{0x0020, '8'},
|
||||||
0x0010, '9',
|
{0x0010, '9'},
|
||||||
0x9000, 'A',
|
{0x9000, 'A'},
|
||||||
0x8800, 'B',
|
{0x8800, 'B'},
|
||||||
0x8400, 'C',
|
{0x8400, 'C'},
|
||||||
0x8200, 'D',
|
{0x8200, 'D'},
|
||||||
0x8100, 'E',
|
{0x8100, 'E'},
|
||||||
0x8080, 'F',
|
{0x8080, 'F'},
|
||||||
0x8040, 'G',
|
{0x8040, 'G'},
|
||||||
0x8020, 'H',
|
{0x8020, 'H'},
|
||||||
0x8010, 'I',
|
{0x8010, 'I'},
|
||||||
0x5000, 'J',
|
{0x5000, 'J'},
|
||||||
0x4800, 'K',
|
{0x4800, 'K'},
|
||||||
0x4400, 'L',
|
{0x4400, 'L'},
|
||||||
0x4200, 'M',
|
{0x4200, 'M'},
|
||||||
0x4100, 'N',
|
{0x4100, 'N'},
|
||||||
0x4080, 'O',
|
{0x4080, 'O'},
|
||||||
0x4040, 'P',
|
{0x4040, 'P'},
|
||||||
0x4020, 'Q',
|
{0x4020, 'Q'},
|
||||||
0x4010, 'R',
|
{0x4010, 'R'},
|
||||||
0x3000, '/',
|
{0x3000, '/'},
|
||||||
0x2800, 'S',
|
{0x2800, 'S'},
|
||||||
0x2400, 'T',
|
{0x2400, 'T'},
|
||||||
0x2200, 'U',
|
{0x2200, 'U'},
|
||||||
0x2100, 'V',
|
{0x2100, 'V'},
|
||||||
0x2080, 'W',
|
{0x2080, 'W'},
|
||||||
0x2040, 'X',
|
{0x2040, 'X'},
|
||||||
0x2020, 'Y',
|
{0x2020, 'Y'},
|
||||||
0x2010, 'Z',
|
{0x2010, 'Z'},
|
||||||
0x0420, '=',
|
{0x0420, '='},
|
||||||
0x0220, '\'',
|
{0x0220, '\''},
|
||||||
0x8420, '.',
|
{0x8420, '.'},
|
||||||
0x8220, '<',
|
{0x8220, '<'},
|
||||||
0x8220, ')', /* if ASCII has ), treat like < */
|
{0x8220, ')'}, /* if ASCII has ), treat like < */
|
||||||
0x4420, '$',
|
{0x4420, '$'},
|
||||||
0x4220, '*',
|
{0x4220, '*'},
|
||||||
0x2420, ',',
|
{0x2420, ','},
|
||||||
0x2220, '%',
|
{0x2220, '%'},
|
||||||
0x2220, '(', /* if ASCII has (, treat like % */
|
{0x2220, '('}, /* if ASCII has (, treat like % */
|
||||||
};
|
};
|
||||||
|
|
||||||
extern int cgi;
|
extern int cgi;
|
||||||
|
|
|
@ -586,7 +586,7 @@ static struct {
|
||||||
char *name;
|
char *name;
|
||||||
} phase[] = {
|
} phase[] = {
|
||||||
# include "dmsr2v12phases.h"
|
# include "dmsr2v12phases.h"
|
||||||
0xFFFF, ""
|
{0xFFFF, ""}
|
||||||
};
|
};
|
||||||
|
|
||||||
#pragma pack(2)
|
#pragma pack(2)
|
||||||
|
@ -597,7 +597,7 @@ struct tag_slet {
|
||||||
int16 nwords;
|
int16 nwords;
|
||||||
int16 sector;
|
int16 sector;
|
||||||
} slet[MAXSLET] = {
|
} slet[MAXSLET] = {
|
||||||
# include "dmsr2v12slet.h" /* without RPG, use this info until overwritten by actual data from disk */
|
#include "dmsr2v12slet.h" /* without RPG, use this info until overwritten by actual data from disk */
|
||||||
};
|
};
|
||||||
|
|
||||||
#pragma pack()
|
#pragma pack()
|
||||||
|
|
|
@ -198,11 +198,11 @@ static struct tag_ccpunches { /* list of rows and punches on tape */
|
||||||
int row, channels;
|
int row, channels;
|
||||||
}
|
}
|
||||||
ccpunches[] = {
|
ccpunches[] = {
|
||||||
2, CC_CHANNEL_1, /* channel 1 = top of form */
|
{ 2, CC_CHANNEL_1}, /* channel 1 = top of form */
|
||||||
62, CC_CHANNEL_12 /* channel 12 = bottom of form */
|
{62, CC_CHANNEL_12} /* channel 12 = bottom of form */
|
||||||
},
|
},
|
||||||
cccgi[] = {
|
cccgi[] = {
|
||||||
2, CC_CHANNEL_1 /* channel 1 = top of form; no bottom of form */
|
{2, CC_CHANNEL_1} /* channel 1 = top of form; no bottom of form */
|
||||||
};
|
};
|
||||||
|
|
||||||
#include "ibm1130_prtwheel.h"
|
#include "ibm1130_prtwheel.h"
|
||||||
|
@ -505,7 +505,8 @@ static t_stat prt1132_svc (UNIT *uptr)
|
||||||
|
|
||||||
void save_1403_prt_line (int32 addr)
|
void save_1403_prt_line (int32 addr)
|
||||||
{
|
{
|
||||||
int i, j, r, ch, even = TRUE;
|
size_t j;
|
||||||
|
int i, r, ch, even = TRUE;
|
||||||
unsigned char ebcdic;
|
unsigned char ebcdic;
|
||||||
int32 wd;
|
int32 wd;
|
||||||
|
|
||||||
|
@ -671,7 +672,7 @@ static t_stat delete_cmd (int32 flag, char *cptr)
|
||||||
static t_stat prt_reset (DEVICE *dptr)
|
static t_stat prt_reset (DEVICE *dptr)
|
||||||
{
|
{
|
||||||
UNIT *uptr = &prt_unit[0];
|
UNIT *uptr = &prt_unit[0];
|
||||||
int i;
|
size_t i;
|
||||||
|
|
||||||
/* add a DELETE filename command so we can be sure to have clean listings */
|
/* add a DELETE filename command so we can be sure to have clean listings */
|
||||||
register_cmd("DELETE", &delete_cmd, 0, "del{ete} filename remove file\n");
|
register_cmd("DELETE", &delete_cmd, 0, "del{ete} filename remove file\n");
|
||||||
|
|
|
@ -16,109 +16,109 @@ struct tag_codewheel {
|
||||||
|
|
||||||
static struct tag_codewheel codewheel1132[] =
|
static struct tag_codewheel codewheel1132[] =
|
||||||
{ /* characters and EBCDIC codes in printwheel order */
|
{ /* characters and EBCDIC codes in printwheel order */
|
||||||
'A', 0xC1,
|
{'A', 0xC1},
|
||||||
'B', 0xC2,
|
{'B', 0xC2},
|
||||||
'C', 0xC3,
|
{'C', 0xC3},
|
||||||
'D', 0xC4,
|
{'D', 0xC4},
|
||||||
'F', 0xC6,
|
{'F', 0xC6},
|
||||||
'H', 0xC8,
|
{'H', 0xC8},
|
||||||
'I', 0xC9,
|
{'I', 0xC9},
|
||||||
'S', 0xE2,
|
{'S', 0xE2},
|
||||||
'T', 0xE3,
|
{'T', 0xE3},
|
||||||
'U', 0xE4,
|
{'U', 0xE4},
|
||||||
'V', 0xE5,
|
{'V', 0xE5},
|
||||||
'1', 0xF1,
|
{'1', 0xF1},
|
||||||
'2', 0xF2,
|
{'2', 0xF2},
|
||||||
'3', 0xF3,
|
{'3', 0xF3},
|
||||||
'4', 0xF4,
|
{'4', 0xF4},
|
||||||
'5', 0xF5,
|
{'5', 0xF5},
|
||||||
'6', 0xF6,
|
{'6', 0xF6},
|
||||||
'7', 0xF7,
|
{'7', 0xF7},
|
||||||
'8', 0xF8,
|
{'8', 0xF8},
|
||||||
'9', 0xF9,
|
{'9', 0xF9},
|
||||||
'0', 0xF0,
|
{'0', 0xF0},
|
||||||
'=', 0x7E,
|
{'=', 0x7E},
|
||||||
'$', 0x5B,
|
{'$', 0x5B},
|
||||||
'.', 0x4B,
|
{'.', 0x4B},
|
||||||
'\'', 0x7D,
|
{'\'', 0x7D},
|
||||||
',', 0x6B,
|
{',', 0x6B},
|
||||||
')', 0x5D,
|
{')', 0x5D},
|
||||||
'-', 0x60,
|
{'-', 0x60},
|
||||||
'(', 0x4D,
|
{'(', 0x4D},
|
||||||
'+', 0x4E,
|
{'+', 0x4E},
|
||||||
'/', 0x61,
|
{'/', 0x61},
|
||||||
'*', 0x5C,
|
{'*', 0x5C},
|
||||||
'&', 0x50,
|
{'&', 0x50},
|
||||||
'J', 0xD1,
|
{'J', 0xD1},
|
||||||
'K', 0xD2,
|
{'K', 0xD2},
|
||||||
'L', 0xD3,
|
{'L', 0xD3},
|
||||||
'M', 0xD4,
|
{'M', 0xD4},
|
||||||
'N', 0xD5,
|
{'N', 0xD5},
|
||||||
'O', 0xD6,
|
{'O', 0xD6},
|
||||||
'P', 0xD7,
|
{'P', 0xD7},
|
||||||
'Q', 0xD8,
|
{'Q', 0xD8},
|
||||||
'R', 0xD9,
|
{'R', 0xD9},
|
||||||
'E', 0xC5,
|
{'E', 0xC5},
|
||||||
'G', 0xC7,
|
{'G', 0xC7},
|
||||||
'W', 0xE6,
|
{'W', 0xE6},
|
||||||
'X', 0xE7,
|
{'X', 0xE7},
|
||||||
'Y', 0xE8,
|
{'Y', 0xE8},
|
||||||
'Z', 0xE9,
|
{'Z', 0xE9},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define WHEELCHARS_1132 (sizeof(codewheel1132)/sizeof(codewheel1132[0]))
|
#define WHEELCHARS_1132 (sizeof(codewheel1132)/sizeof(codewheel1132[0]))
|
||||||
|
|
||||||
static struct tag_codewheel codewheel1403[] =
|
static struct tag_codewheel codewheel1403[] =
|
||||||
{
|
{
|
||||||
'A', 0x64,
|
{'A', 0x64},
|
||||||
'B', 0x25,
|
{'B', 0x25},
|
||||||
'C', 0x26,
|
{'C', 0x26},
|
||||||
'D', 0x67,
|
{'D', 0x67},
|
||||||
'E', 0x68,
|
{'E', 0x68},
|
||||||
'F', 0x29,
|
{'F', 0x29},
|
||||||
'G', 0x2A,
|
{'G', 0x2A},
|
||||||
'H', 0x6B,
|
{'H', 0x6B},
|
||||||
'I', 0x2C,
|
{'I', 0x2C},
|
||||||
'J', 0x58,
|
{'J', 0x58},
|
||||||
'K', 0x19,
|
{'K', 0x19},
|
||||||
'L', 0x1A,
|
{'L', 0x1A},
|
||||||
'M', 0x5B,
|
{'M', 0x5B},
|
||||||
'N', 0x1C,
|
{'N', 0x1C},
|
||||||
'O', 0x5D,
|
{'O', 0x5D},
|
||||||
'P', 0x5E,
|
{'P', 0x5E},
|
||||||
'Q', 0x1F,
|
{'Q', 0x1F},
|
||||||
'R', 0x20,
|
{'R', 0x20},
|
||||||
'S', 0x0D,
|
{'S', 0x0D},
|
||||||
'T', 0x0E,
|
{'T', 0x0E},
|
||||||
'U', 0x4F,
|
{'U', 0x4F},
|
||||||
'V', 0x10,
|
{'V', 0x10},
|
||||||
'W', 0x51,
|
{'W', 0x51},
|
||||||
'X', 0x52,
|
{'X', 0x52},
|
||||||
'Y', 0x13,
|
{'Y', 0x13},
|
||||||
'Z', 0x54,
|
{'Z', 0x54},
|
||||||
'0', 0x49,
|
{'0', 0x49},
|
||||||
'1', 0x40,
|
{'1', 0x40},
|
||||||
'2', 0x01,
|
{'2', 0x01},
|
||||||
'3', 0x02,
|
{'3', 0x02},
|
||||||
'4', 0x43,
|
{'4', 0x43},
|
||||||
'5', 0x04,
|
{'5', 0x04},
|
||||||
'6', 0x45,
|
{'6', 0x45},
|
||||||
'7', 0x46,
|
{'7', 0x46},
|
||||||
'8', 0x07,
|
{'8', 0x07},
|
||||||
'9', 0x08,
|
{'9', 0x08},
|
||||||
' ', 0x7F,
|
{' ', 0x7F},
|
||||||
'.', 0x6E,
|
{'.', 0x6E},
|
||||||
'(', 0x57,
|
{'(', 0x57},
|
||||||
'+', 0x6D,
|
{'+', 0x6D},
|
||||||
'&', 0x15,
|
{'&', 0x15},
|
||||||
'$', 0x62,
|
{'$', 0x62},
|
||||||
'*', 0x23,
|
{'*', 0x23},
|
||||||
')', 0x2F,
|
{')', 0x2F},
|
||||||
'-', 0x61,
|
{'-', 0x61},
|
||||||
'/', 0x4C,
|
{'/', 0x4C},
|
||||||
',', 0x16,
|
{',', 0x16},
|
||||||
'\'', 0x0B,
|
{'\'', 0x0B},
|
||||||
'=', 0x4A,
|
{'=', 0x4A},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define WHEELCHARS_1403 (sizeof(codewheel1403)/sizeof(codewheel1403[0]))
|
#define WHEELCHARS_1403 (sizeof(codewheel1403)/sizeof(codewheel1403[0]))
|
||||||
|
|
|
@ -518,18 +518,18 @@ static struct { /* default input mapping for APL */
|
||||||
unsigned char out;
|
unsigned char out;
|
||||||
} conin_to_APL[] =
|
} conin_to_APL[] =
|
||||||
{ /* these map input keys to those in like positions on 1130 keyboard */
|
{ /* these map input keys to those in like positions on 1130 keyboard */
|
||||||
'[', '\r', /* enter (EOF) is APL left arrow */
|
{'[', '\r'}, /* enter (EOF) is APL left arrow */
|
||||||
';', '\b', /* backspace is APL [ */
|
{';', '\b'}, /* backspace is APL [ */
|
||||||
'\'', '\x15', /* ctrl-U, erase field, is APL ]*/
|
{'\'', '\x15'}, /* ctrl-U, erase field, is APL ]*/
|
||||||
'2', '@', /* APL upshift */
|
{'2', '@'}, /* APL upshift */
|
||||||
'3', '%', /* APL rightshift */
|
{'3', '%'}, /* APL rightshift */
|
||||||
'4', '*', /* APL + and - */
|
{'4', '*'}, /* APL + and - */
|
||||||
'5', '<', /* APL x and divide */
|
{'5', '<'}, /* APL x and divide */
|
||||||
'8', '-', /* APL return */
|
{'8', '-'}, /* APL return */
|
||||||
'9', '/', /* APL backspace */
|
{'9', '/'}, /* APL backspace */
|
||||||
'-', IRQ_KEY, /* ctrl-q (INT REQ), APL ATTN */
|
{'-', IRQ_KEY}, /* ctrl-q (INT REQ), APL ATTN */
|
||||||
'\r', '-', /* APL return */
|
{'\r', '-'}, /* APL return */
|
||||||
'\b', '/' /* APL backspace */
|
{'\b', '/'} /* APL backspace */
|
||||||
};
|
};
|
||||||
|
|
||||||
#define NCONIN_TO_APL (sizeof(conin_to_APL)/sizeof(conin_to_APL[0]))
|
#define NCONIN_TO_APL (sizeof(conin_to_APL)/sizeof(conin_to_APL[0]))
|
||||||
|
@ -539,136 +539,136 @@ static struct { /* default output mapping for APLPLUS font */
|
||||||
unsigned char out;
|
unsigned char out;
|
||||||
} conout_to_APL[] =
|
} conout_to_APL[] =
|
||||||
{
|
{
|
||||||
'\x01', IGNR_, /* controls */
|
{'\x01', IGNR_}, /* controls */
|
||||||
'\x03', '\n',
|
{'\x03', '\n'},
|
||||||
'\x05', IGNR_, /* (black and red are handled by ansi sequences) */
|
{'\x05', IGNR_}, /* (black and red are handled by ansi sequences) */
|
||||||
'\x09', IGNR_,
|
{'\x09', IGNR_},
|
||||||
'\x11', '\b',
|
{'\x11', '\b'},
|
||||||
'\x21', ' ',
|
{'\x21', ' '},
|
||||||
'\x41', '\t',
|
{'\x41', '\t'},
|
||||||
'\x81', CRLF_,
|
{'\x81', CRLF_},
|
||||||
|
|
||||||
'\xC4', '\x30', /* (if you're curious, order here is position on APL typeball) */
|
{'\xC4', '\x30'}, /* (if you're curious, order here is position on APL typeball) */
|
||||||
'\xE4', '\x38',
|
{'\xE4', '\x38'},
|
||||||
'\xD4', '\x37',
|
{'\xD4', '\x37'},
|
||||||
'\xF4', '\x35',
|
{'\xF4', '\x35'},
|
||||||
'\xDC', '\x33',
|
{'\xDC', '\x33'},
|
||||||
'\xFC', '\x31',
|
{'\xFC', '\x31'},
|
||||||
'\xC2', '\x29',
|
{'\xC2', '\x29'},
|
||||||
'\xE2', '\x9F',
|
{'\xE2', '\x9F'},
|
||||||
'\xD2', '\x89',
|
{'\xD2', '\x89'},
|
||||||
'\xF2', '\x88',
|
{'\xF2', '\x88'},
|
||||||
'\xDA', '\xAF',
|
{'\xDA', '\xAF'},
|
||||||
'\xC6', '\x5E',
|
{'\xC6', '\x5E'},
|
||||||
'\xE6', '\xAC',
|
{'\xE6', '\xAC'},
|
||||||
'\xD6', '\x3E',
|
{'\xD6', '\x3E'},
|
||||||
'\xF6', '\x3D',
|
{'\xF6', '\x3D'},
|
||||||
'\xDE', '\x3C',
|
{'\xDE', '\x3C'},
|
||||||
'\xFE', '\xA8',
|
{'\xFE', '\xA8'},
|
||||||
'\xC0', '\x5D',
|
{'\xC0', '\x5D'},
|
||||||
'\xE0', '\x39',
|
{'\xE0', '\x39'},
|
||||||
'\xD0', '\x36',
|
{'\xD0', '\x36'},
|
||||||
'\xF0', '\x34',
|
{'\xF0', '\x34'},
|
||||||
'\xD8', '\x32',
|
{'\xD8', '\x32'},
|
||||||
|
|
||||||
'\x84', '\x84',
|
{'\x84', '\x84'},
|
||||||
'\xA4', '\x59',
|
{'\xA4', '\x59'},
|
||||||
'\x94', '\x58',
|
{'\x94', '\x58'},
|
||||||
'\xB4', '\x56',
|
{'\xB4', '\x56'},
|
||||||
'\x9C', '\x54',
|
{'\x9C', '\x54'},
|
||||||
'\xBC', '\x2F',
|
{'\xBC', '\x2F'},
|
||||||
'\x82', '\x3B',
|
{'\x82', '\x3B'},
|
||||||
'\xA2', '\x9B',
|
{'\xA2', '\x9B'},
|
||||||
'\x92', '\xBE',
|
{'\x92', '\xBE'},
|
||||||
'\xB2', '\x87',
|
{'\xB2', '\x87'},
|
||||||
'\x9A', '\x97',
|
{'\x9A', '\x97'},
|
||||||
'\x86', '\x85',
|
{'\x86', '\x85'},
|
||||||
'\xA6', '\x86',
|
{'\xA6', '\x86'},
|
||||||
'\x96', '\x9C',
|
{'\x96', '\x9C'},
|
||||||
'\xB6', '\x9E',
|
{'\xB6', '\x9E'},
|
||||||
'\x9E', '\x7E',
|
{'\x9E', '\x7E'},
|
||||||
'\xBE', '\x5C',
|
{'\xBE', '\x5C'},
|
||||||
'\x80', '\x2C',
|
{'\x80', '\x2C'},
|
||||||
'\xA0', '\x5A',
|
{'\xA0', '\x5A'},
|
||||||
'\x90', '\x57',
|
{'\x90', '\x57'},
|
||||||
'\xB0', '\x55',
|
{'\xB0', '\x55'},
|
||||||
'\x98', '\x53',
|
{'\x98', '\x53'},
|
||||||
|
|
||||||
'\x44', '\x2B',
|
{'\x44', '\x2B'},
|
||||||
'\x64', '\x51',
|
{'\x64', '\x51'},
|
||||||
'\x54', '\x50',
|
{'\x54', '\x50'},
|
||||||
'\x74', '\x4E',
|
{'\x74', '\x4E'},
|
||||||
'\x5C', '\x4C',
|
{'\x5C', '\x4C'},
|
||||||
'\x7C', '\x4A',
|
{'\x7C', '\x4A'},
|
||||||
'\x42', '\x28',
|
{'\x42', '\x28'},
|
||||||
'\x62', '\xBD',
|
{'\x62', '\xBD'},
|
||||||
'\x52', '\xB1',
|
{'\x52', '\xB1'},
|
||||||
'\x72', '\x7C',
|
{'\x72', '\x7C'},
|
||||||
'\x5A', '\x27',
|
{'\x5A', '\x27'},
|
||||||
'\x46', '\x2D',
|
{'\x46', '\x2D'},
|
||||||
'\x66', '\x3F',
|
{'\x66', '\x3F'},
|
||||||
'\x56', '\x2A',
|
{'\x56', '\x2A'},
|
||||||
'\x76', '\x82',
|
{'\x76', '\x82'},
|
||||||
'\x5E', '\x8C',
|
{'\x5E', '\x8C'},
|
||||||
'\x7E', '\xB0',
|
{'\x7E', '\xB0'},
|
||||||
'\x40', '\x5B',
|
{'\x40', '\x5B'},
|
||||||
'\x60', '\x52',
|
{'\x60', '\x52'},
|
||||||
'\x50', '\x4F',
|
{'\x50', '\x4F'},
|
||||||
'\x70', '\x4D',
|
{'\x70', '\x4D'},
|
||||||
'\x58', '\x4B',
|
{'\x58', '\x4B'},
|
||||||
|
|
||||||
'\x04', '\xD7',
|
{'\x04', '\xD7'},
|
||||||
'\x24', '\x48',
|
{'\x24', '\x48'},
|
||||||
'\x14', '\x47',
|
{'\x14', '\x47'},
|
||||||
'\x34', '\x45',
|
{'\x34', '\x45'},
|
||||||
'\x1C', '\x43',
|
{'\x1C', '\x43'},
|
||||||
'\x3C', '\x41',
|
{'\x3C', '\x41'},
|
||||||
'\x02', '\x3A',
|
{'\x02', '\x3A'},
|
||||||
'\x22', '\xBC',
|
{'\x22', '\xBC'},
|
||||||
'\x12', '\x5F',
|
{'\x12', '\x5F'},
|
||||||
'\x32', '\x98',
|
{'\x32', '\x98'},
|
||||||
'\x1A', '\x83',
|
{'\x1A', '\x83'},
|
||||||
'\x06', '\xF7',
|
{'\x06', '\xF7'},
|
||||||
'\x26', '\x91',
|
{'\x26', '\x91'},
|
||||||
'\x16', '\x92',
|
{'\x16', '\x92'},
|
||||||
'\x36', '\xB9',
|
{'\x36', '\xB9'},
|
||||||
'\x1E', '\x9D',
|
{'\x1E', '\x9D'},
|
||||||
'\x3E', '\xB8',
|
{'\x3E', '\xB8'},
|
||||||
'\x00', '\x2E',
|
{'\x00', '\x2E'},
|
||||||
'\x20', '\x49',
|
{'\x20', '\x49'},
|
||||||
'\x10', '\x46',
|
{'\x10', '\x46'},
|
||||||
'\x30', '\x44',
|
{'\x30', '\x44'},
|
||||||
'\x18', '\x42',
|
{'\x18', '\x42'},
|
||||||
};
|
};
|
||||||
|
|
||||||
#define NCONOUT_TO_APL (sizeof(conout_to_APL)/sizeof(conout_to_APL[0]))
|
#define NCONOUT_TO_APL (sizeof(conout_to_APL)/sizeof(conout_to_APL[0]))
|
||||||
|
|
||||||
static OS_MAP default_os_map[] = /* overstrike mapping for APLPLUS font */
|
static OS_MAP default_os_map[] = /* overstrike mapping for APLPLUS font */
|
||||||
{
|
{
|
||||||
'\x8a', 2, "\x5e\x7e",
|
{'\x8a', 2, "\x5e\x7e"},
|
||||||
'\x8b', 2, "\x9f\x7e",
|
{'\x8b', 2, "\x9f\x7e"},
|
||||||
'\x8d', 2, "\x8c\x27",
|
{'\x8d', 2, "\x8c\x27"},
|
||||||
'\x8e', 3, "\x8c\x2d\x3a",
|
{'\x8e', 3, "\x8c\x2d\x3a"},
|
||||||
'\x8f', 2, "\x91\x5f",
|
{'\x8f', 2, "\x91\x5f"},
|
||||||
'\x90', 2, "\x92\x7e",
|
{'\x90', 2, "\x92\x7e"},
|
||||||
'\x93', 2, "\x91\x7c",
|
{'\x93', 2, "\x91\x7c"},
|
||||||
'\x94', 2, "\x92\x7c",
|
{'\x94', 2, "\x92\x7c"},
|
||||||
'\x95', 2, "\xb0\x82",
|
{'\x95', 2, "\xb0\x82"},
|
||||||
'\x96', 2, "\xb0\x83",
|
{'\x96', 2, "\xb0\x83"},
|
||||||
'\x99', 2, "\x2d\x5c",
|
{'\x99', 2, "\x2d\x5c"},
|
||||||
'\x9a', 2, "\x2d\x2f",
|
{'\x9a', 2, "\x2d\x2f"},
|
||||||
'\xae', 2, "\x2c\x2d",
|
{'\xae', 2, "\x2c\x2d"},
|
||||||
'\xb2', 2, "\xb1\x7c",
|
{'\xb2', 2, "\xb1\x7c"},
|
||||||
'\xb3', 2, "\xb1\x5c",
|
{'\xb3', 2, "\xb1\x5c"},
|
||||||
'\xb4', 2, "\xb1\x2d",
|
{'\xb4', 2, "\xb1\x2d"},
|
||||||
'\xb5', 2, "\xb1\x2a",
|
{'\xb5', 2, "\xb1\x2a"},
|
||||||
'\xba', 2, "\xb9\x5f",
|
{'\xba', 2, "\xb9\x5f"},
|
||||||
'\xd0', 2, "\x30\x7e",
|
{'\xd0', 2, "\x30\x7e"},
|
||||||
'\xd8', 2, "\x4f\x2f",
|
{'\xd8', 2, "\x4f\x2f"},
|
||||||
'\x21', 2, "\x27\x2e",
|
{'\x21', 2, "\x27\x2e"},
|
||||||
'\xa4', 2, "\xb0\xb1", /* map degree in circle to circle cross (APL uses this as character error symbol) */
|
{'\xa4', 2, "\xb0\xb1"}, /* map degree in circle to circle cross (APL uses this as character error symbol) */
|
||||||
'\xf0', 2, "\xb0\xa8",
|
{'\xf0', 2, "\xb0\xa8"},
|
||||||
'\xfe', 2, "\x3a\xa8",
|
{'\xfe', 2, "\x3a\xa8"},
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef __SUNPRO_C
|
#ifdef __SUNPRO_C
|
||||||
|
|
|
@ -193,7 +193,7 @@ uint32 GREG[16] = { 0 }; /* general registers */
|
||||||
uint16 *M = NULL; /* memory */
|
uint16 *M = NULL; /* memory */
|
||||||
uint32 *R = &GREG[0]; /* register set ptr */
|
uint32 *R = &GREG[0]; /* register set ptr */
|
||||||
uint32 F[8] = { 0 }; /* sp fp registers */
|
uint32 F[8] = { 0 }; /* sp fp registers */
|
||||||
dpr_t D[8] = { 0 }; /* dp fp registers */
|
dpr_t D[8] = { {0, 0} }; /* dp fp registers */
|
||||||
uint32 PSW = 0; /* processor status word */
|
uint32 PSW = 0; /* processor status word */
|
||||||
uint32 psw_mask = PSW_x16; /* PSW mask */
|
uint32 psw_mask = PSW_x16; /* PSW mask */
|
||||||
uint32 PC = 0; /* program counter */
|
uint32 PC = 0; /* program counter */
|
||||||
|
|
|
@ -352,9 +352,8 @@ return -1;
|
||||||
|
|
||||||
t_stat fprint_sym_m (FILE *of, t_addr addr, t_value *val)
|
t_stat fprint_sym_m (FILE *of, t_addr addr, t_value *val)
|
||||||
{
|
{
|
||||||
uint32 i, j, inst, r1, r2, ea, vp;
|
uint32 i, j, inst, r1, r2, ea;
|
||||||
|
|
||||||
vp = 0;
|
|
||||||
inst = val[0]; /* first 16b */
|
inst = val[0]; /* first 16b */
|
||||||
ea = val[1]; /* second 16b */
|
ea = val[1]; /* second 16b */
|
||||||
for (i = 0; opcode[i] != NULL; i++) { /* loop thru ops */
|
for (i = 0; opcode[i] != NULL; i++) { /* loop thru ops */
|
||||||
|
@ -570,7 +569,7 @@ return -1;
|
||||||
t_stat parse_sym_m (char *cptr, t_addr addr, t_value *val)
|
t_stat parse_sym_m (char *cptr, t_addr addr, t_value *val)
|
||||||
{
|
{
|
||||||
uint32 i, j, t, df, db, inst;
|
uint32 i, j, t, df, db, inst;
|
||||||
int32 st, r1, r2;
|
int32 r1, r2;
|
||||||
t_stat r;
|
t_stat r;
|
||||||
char *tptr, gbuf[CBUFSIZE];
|
char *tptr, gbuf[CBUFSIZE];
|
||||||
|
|
||||||
|
@ -627,7 +626,6 @@ switch (j) { /* case on class */
|
||||||
r = get_addr (gbuf, &tptr, &t, addr); /* get addr */
|
r = get_addr (gbuf, &tptr, &t, addr); /* get addr */
|
||||||
if ((r != SCPE_OK) || (t & 1) || *tptr) /* error if odd */
|
if ((r != SCPE_OK) || (t & 1) || *tptr) /* error if odd */
|
||||||
return SCPE_ARG;
|
return SCPE_ARG;
|
||||||
st = t; /* signed version */
|
|
||||||
db = (addr - t) & 0x1F; /* back displ */
|
db = (addr - t) & 0x1F; /* back displ */
|
||||||
df = (t - addr) & 0x1F; /* fwd displ */
|
df = (t - addr) & 0x1F; /* fwd displ */
|
||||||
if ((t == ((addr - db) & VAMASK16)) && /* back work and */
|
if ((t == ((addr - db) & VAMASK16)) && /* back work and */
|
||||||
|
|
|
@ -2315,7 +2315,7 @@ t_stat cpu_set_size (UNIT *uptr, int32 val, char *cptr, void *desc)
|
||||||
uint32 mc = 0;
|
uint32 mc = 0;
|
||||||
uint32 i;
|
uint32 i;
|
||||||
|
|
||||||
if ((val <= 0) || (val > MAXMEMSIZE32) || ((val & 0xFFFF) != 0))
|
if ((val <= 0) || (((unsigned)val) > MAXMEMSIZE32) || ((val & 0xFFFF) != 0))
|
||||||
return SCPE_ARG;
|
return SCPE_ARG;
|
||||||
for (i = val; i < MEMSIZE; i = i + 4)
|
for (i = val; i < MEMSIZE; i = i + 4)
|
||||||
mc = mc | M[i >> 2];
|
mc = mc | M[i >> 2];
|
||||||
|
|
|
@ -669,12 +669,11 @@ return -3;
|
||||||
|
|
||||||
t_stat parse_sym_m (char *cptr, t_addr addr, t_value *val)
|
t_stat parse_sym_m (char *cptr, t_addr addr, t_value *val)
|
||||||
{
|
{
|
||||||
uint32 i, j, df, db, t, inst, vp;
|
uint32 i, j, df, db, t, inst;
|
||||||
int32 st, r1, r2, rx2;
|
int32 st, r1, r2, rx2;
|
||||||
t_stat r;
|
t_stat r;
|
||||||
char *tptr, gbuf[CBUFSIZE];
|
char *tptr, gbuf[CBUFSIZE];
|
||||||
|
|
||||||
vp = 0;
|
|
||||||
cptr = get_glyph (cptr, gbuf, 0); /* get opcode */
|
cptr = get_glyph (cptr, gbuf, 0); /* get opcode */
|
||||||
for (i = 0; (opcode[i] != NULL) && (strcmp (opcode[i], gbuf) != 0) ; i++) ;
|
for (i = 0; (opcode[i] != NULL) && (strcmp (opcode[i], gbuf) != 0) ; i++) ;
|
||||||
if (opcode[i] == NULL)
|
if (opcode[i] == NULL)
|
||||||
|
|
|
@ -392,7 +392,6 @@ t_stat dp_svc (UNIT *uptr)
|
||||||
uint32 u = uptr - dp_dev.units; /* get unit number */
|
uint32 u = uptr - dp_dev.units; /* get unit number */
|
||||||
int32 cyl = uptr->CYL; /* get cylinder */
|
int32 cyl = uptr->CYL; /* get cylinder */
|
||||||
uint32 dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
uint32 dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
||||||
uint32 t;
|
|
||||||
t_stat r;
|
t_stat r;
|
||||||
|
|
||||||
if (uptr->STD & STD_MOV) { /* seek? */
|
if (uptr->STD & STD_MOV) { /* seek? */
|
||||||
|
@ -421,7 +420,7 @@ switch (dp_cmd & 0x7) { /* case on func */
|
||||||
if ((r = dp_rds (uptr))) /* read sec, err? */
|
if ((r = dp_rds (uptr))) /* read sec, err? */
|
||||||
return r;
|
return r;
|
||||||
dp_1st = 0;
|
dp_1st = 0;
|
||||||
t = sch_wrmem (dp_dib.sch, dpxb, DP_NUMBY); /* write to memory */
|
sch_wrmem (dp_dib.sch, dpxb, DP_NUMBY); /* write to memory */
|
||||||
if (sch_actv (dp_dib.sch, dp_dib.dno)) { /* more to do? */
|
if (sch_actv (dp_dib.sch, dp_dib.dno)) { /* more to do? */
|
||||||
sim_activate (uptr, dp_rtime); /* reschedule */
|
sim_activate (uptr, dp_rtime); /* reschedule */
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
|
|
|
@ -503,7 +503,6 @@ t_stat idc_svc (UNIT *uptr)
|
||||||
int32 diff;
|
int32 diff;
|
||||||
uint32 f, u = uptr - idc_dev.units; /* get unit number */
|
uint32 f, u = uptr - idc_dev.units; /* get unit number */
|
||||||
uint32 dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
uint32 dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
||||||
uint32 t;
|
|
||||||
t_stat r;
|
t_stat r;
|
||||||
|
|
||||||
if (uptr->FNC & CMC_DRV) { /* drive cmd? */
|
if (uptr->FNC & CMC_DRV) { /* drive cmd? */
|
||||||
|
@ -579,7 +578,7 @@ switch (uptr->FNC & CMC_MASK) { /* case on func */
|
||||||
if ((r = idc_rds (uptr))) /* read sec, err? */
|
if ((r = idc_rds (uptr))) /* read sec, err? */
|
||||||
return r;
|
return r;
|
||||||
idc_1st = 0;
|
idc_1st = 0;
|
||||||
t = sch_wrmem (idc_dib.sch, idcxb, IDC_NUMBY); /* write mem */
|
sch_wrmem (idc_dib.sch, idcxb, IDC_NUMBY); /* write mem */
|
||||||
if (sch_actv (idc_dib.sch, idc_dib.dno)) { /* more to do? */
|
if (sch_actv (idc_dib.sch, idc_dib.dno)) { /* more to do? */
|
||||||
sim_activate (uptr, idc_rtime); /* reschedule */
|
sim_activate (uptr, idc_rtime); /* reschedule */
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
|
|
|
@ -5925,7 +5925,7 @@ static const int32 boot_rom[] = {
|
||||||
|
|
||||||
t_stat cpu_boot (int32 unitno, DEVICE *dptr)
|
t_stat cpu_boot (int32 unitno, DEVICE *dptr)
|
||||||
{
|
{
|
||||||
int32 i;
|
size_t i;
|
||||||
extern int32 saved_PC;
|
extern int32 saved_PC;
|
||||||
|
|
||||||
for (i = 0; i < BOOT_LEN; i++) M[BOOT_START + i] = boot_rom[i];
|
for (i = 0; i < BOOT_LEN; i++) M[BOOT_START + i] = boot_rom[i];
|
||||||
|
|
|
@ -133,7 +133,7 @@ int32 qty_auto = 0 ; /* QTY auto disconnect
|
||||||
int32 qty_polls = 0 ; /* total 'qty_svc' polls */
|
int32 qty_polls = 0 ; /* total 'qty_svc' polls */
|
||||||
|
|
||||||
|
|
||||||
TMLN qty_ldsc[ QTY_MAX ] = { 0 } ; /* QTY line descriptors */
|
TMLN qty_ldsc[ QTY_MAX ] = { {0} } ; /* QTY line descriptors */
|
||||||
TMXR qty_desc = { QTY_MAX, 0, 0, qty_ldsc } ; /* mux descriptor */
|
TMXR qty_desc = { QTY_MAX, 0, 0, qty_ldsc } ; /* mux descriptor */
|
||||||
int32 qty_status[ QTY_MAX ] = { 0 } ; /* QTY line status */
|
int32 qty_status[ QTY_MAX ] = { 0 } ; /* QTY line status */
|
||||||
/* (must be at least 32 bits) */
|
/* (must be at least 32 bits) */
|
||||||
|
|
|
@ -1606,7 +1606,7 @@ t_stat cpu_set_size (UNIT *uptr, int32 val, char *cptr, void *desc)
|
||||||
int32 mc = 0;
|
int32 mc = 0;
|
||||||
uint32 i;
|
uint32 i;
|
||||||
|
|
||||||
if ((val <= 0) || (val > MAXMEMSIZE) || ((val & 07777) != 0))
|
if ((val <= 0) || (((size_t)val) > MAXMEMSIZE) || ((val & 07777) != 0))
|
||||||
return SCPE_ARG;
|
return SCPE_ARG;
|
||||||
for (i = val; i < MEMSIZE; i++)
|
for (i = val; i < MEMSIZE; i++)
|
||||||
mc = mc | M[i];
|
mc = mc | M[i];
|
||||||
|
|
|
@ -2385,7 +2385,7 @@ a10 ea;
|
||||||
d10 inst, indrct;
|
d10 inst, indrct;
|
||||||
int32 i, pflgs = 0;
|
int32 i, pflgs = 0;
|
||||||
t_addr adn, max_returns = MAX_SUB_RETURN_SKIP;
|
t_addr adn, max_returns = MAX_SUB_RETURN_SKIP;
|
||||||
int32 xr, ac;
|
int32 xr;
|
||||||
|
|
||||||
if (!caveats_displayed) {
|
if (!caveats_displayed) {
|
||||||
caveats_displayed = TRUE;
|
caveats_displayed = TRUE;
|
||||||
|
@ -2400,7 +2400,6 @@ switch (GET_OP(inst))
|
||||||
case 0265: /* JSP */
|
case 0265: /* JSP */
|
||||||
case 0266: /* JSA */
|
case 0266: /* JSA */
|
||||||
case 0267: /* JRA */
|
case 0267: /* JRA */
|
||||||
ac = GET_AC (inst); /* get AC */
|
|
||||||
for (indrct = inst, i = 0; i < ind_max; i++) {/* calc eff addr */
|
for (indrct = inst, i = 0; i < ind_max; i++) {/* calc eff addr */
|
||||||
ea = GET_ADDR (indrct);
|
ea = GET_ADDR (indrct);
|
||||||
xr = GET_XR (indrct);
|
xr = GET_XR (indrct);
|
||||||
|
|
|
@ -1110,7 +1110,7 @@ while (!feof(vfile)) {
|
||||||
c = fscanf (vfile, " %u:", &line);
|
c = fscanf (vfile, " %u:", &line);
|
||||||
if (c == EOF)
|
if (c == EOF)
|
||||||
break;
|
break;
|
||||||
if ((c < 1) || (line < 0) || (line >= (sizeof (davfu)/sizeof davfu[0])))
|
if ((c < 1) || (line < 0) || (((size_t)line) >= (sizeof (davfu)/sizeof davfu[0])))
|
||||||
goto fmt_err;
|
goto fmt_err;
|
||||||
if (line+1 > dvlnt)
|
if (line+1 > dvlnt)
|
||||||
dvlnt = line+1;
|
dvlnt = line+1;
|
||||||
|
|
|
@ -615,12 +615,11 @@ return SCPE_OK;
|
||||||
|
|
||||||
t_stat rp_wr (int32 data, int32 PA, int32 access)
|
t_stat rp_wr (int32 data, int32 PA, int32 access)
|
||||||
{
|
{
|
||||||
int32 cs1f, drv, dtype, i, j;
|
int32 cs1f, drv, i, j;
|
||||||
UNIT *uptr;
|
UNIT *uptr;
|
||||||
|
|
||||||
cs1f = 0; /* no int on cs1 upd */
|
cs1f = 0; /* no int on cs1 upd */
|
||||||
drv = GET_UNIT (rpcs2); /* get current unit */
|
drv = GET_UNIT (rpcs2); /* get current unit */
|
||||||
dtype = GET_DTYPE (rp_unit[drv].flags); /* get drive type */
|
|
||||||
uptr = rp_dev.units + drv; /* get unit */
|
uptr = rp_dev.units + drv; /* get unit */
|
||||||
j = (PA >> 1) & 037; /* get reg offset */
|
j = (PA >> 1) & 037; /* get reg offset */
|
||||||
if (reg_in_drive[j] && (rp_unit[drv].flags & UNIT_DIS)) { /* nx disk */
|
if (reg_in_drive[j] && (rp_unit[drv].flags & UNIT_DIS)) { /* nx disk */
|
||||||
|
|
|
@ -700,11 +700,10 @@ static const char *devnam[NUMDEV] = {
|
||||||
t_stat fprint_sym (FILE *of, t_addr addr, t_value *val,
|
t_stat fprint_sym (FILE *of, t_addr addr, t_value *val,
|
||||||
UNIT *uptr, int32 sw)
|
UNIT *uptr, int32 sw)
|
||||||
{
|
{
|
||||||
int32 i, j, c, cflag, ac, xr, y, dev;
|
int32 i, j, c, ac, xr, y, dev;
|
||||||
d10 inst;
|
d10 inst;
|
||||||
|
|
||||||
inst = val[0];
|
inst = val[0];
|
||||||
cflag = (uptr == NULL) || (uptr == &cpu_unit);
|
|
||||||
if (sw & SWMASK ('A')) { /* ASCII? */
|
if (sw & SWMASK ('A')) { /* ASCII? */
|
||||||
if (inst > 0377)
|
if (inst > 0377)
|
||||||
return SCPE_ARG;
|
return SCPE_ARG;
|
||||||
|
@ -827,12 +826,11 @@ return (ind | (xr << 18) | val);
|
||||||
|
|
||||||
t_stat parse_sym (char *cptr, t_addr addr, UNIT *uptr, t_value *val, int32 sw)
|
t_stat parse_sym (char *cptr, t_addr addr, UNIT *uptr, t_value *val, int32 sw)
|
||||||
{
|
{
|
||||||
int32 cflag, i, j;
|
int32 i, j;
|
||||||
t_value ac, dev;
|
t_value ac, dev;
|
||||||
t_stat r;
|
t_stat r;
|
||||||
char gbuf[CBUFSIZE];
|
char gbuf[CBUFSIZE];
|
||||||
|
|
||||||
cflag = (uptr == NULL) || (uptr == &cpu_unit);
|
|
||||||
while (isspace (*cptr)) cptr++;
|
while (isspace (*cptr)) cptr++;
|
||||||
for (i = 0; i < 6; i++) {
|
for (i = 0; i < 6; i++) {
|
||||||
if (cptr[i] == 0) {
|
if (cptr[i] == 0) {
|
||||||
|
|
|
@ -203,98 +203,99 @@ extern int32 calc_ints (int32 nipl, int32 trq);
|
||||||
/* Table of instruction operands */
|
/* Table of instruction operands */
|
||||||
|
|
||||||
static int32 opntab[128][MAXOPN] = {
|
static int32 opntab[128][MAXOPN] = {
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 000 - 007 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 000 - 007 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 010 - 017 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 010 - 017 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* LD2R */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* LD2R */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, /* MOVC */
|
{0, 0, 0, 0}, /* MOVC */
|
||||||
0, 0, 0, 0, /* MOVRC */
|
{0, 0, 0, 0}, /* MOVRC */
|
||||||
0, 0, 0, 0, /* MOVTC */
|
{0, 0, 0, 0}, /* MOVTC */
|
||||||
0, 0, 0, 0, /* 033 */
|
{0, 0, 0, 0}, /* 033 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 034 - 037 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 034 - 037 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, /* LOCC */
|
{0, 0, 0, 0}, /* LOCC */
|
||||||
0, 0, 0, 0, /* SKPC */
|
{0, 0, 0, 0}, /* SKPC */
|
||||||
0, 0, 0, 0, /* SCANC */
|
{0, 0, 0, 0}, /* SCANC */
|
||||||
0, 0, 0, 0, /* SPANC */
|
{0, 0, 0, 0}, /* SPANC */
|
||||||
0, 0, 0, 0, /* CMPC */
|
{0, 0, 0, 0}, /* CMPC */
|
||||||
0, 0, 0, 0, /* MATC */
|
{0, 0, 0, 0}, /* MATC */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 046 - 047 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 046 - 047 */
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* ADDN */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* ADDN */
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* SUBN */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* SUBN */
|
||||||
R0_DESC, R2_DESC, 0, 0, /* CMPN */
|
{R0_DESC, R2_DESC, 0, 0}, /* CMPN */
|
||||||
R0_DESC, 0, 0, 0, /* CVTNL */
|
{R0_DESC, 0, 0, 0}, /* CVTNL */
|
||||||
R0_DESC, R2_DESC, 0, 0, /* CVTPN */
|
{R0_DESC, R2_DESC, 0, 0}, /* CVTPN */
|
||||||
R0_DESC, R2_DESC, 0, 0, /* CVTNP */
|
{R0_DESC, R2_DESC, 0, 0}, /* CVTNP */
|
||||||
R0_DESC, R2_DESC, R4_ARG, 0, /* ASHN */
|
{R0_DESC, R2_DESC, R4_ARG, 0}, /* ASHN */
|
||||||
R0_DESC, 0, 0, 0, /* CVTLN */
|
{R0_DESC, 0, 0, 0}, /* CVTLN */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* LD3R */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* LD3R */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* ADDP */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* ADDP */
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* SUBP */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* SUBP */
|
||||||
R0_DESC, R2_DESC, 0, 0, /* CMPP */
|
{R0_DESC, R2_DESC, 0, 0}, /* CMPP */
|
||||||
R0_DESC, 0, 0, 0, /* CVTPL */
|
{R0_DESC, 0, 0, 0}, /* CVTPL */
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* MULP */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* MULP */
|
||||||
R0_DESC, R2_DESC, R4_DESC, 0, /* DIVP */
|
{R0_DESC, R2_DESC, R4_DESC, 0}, /* DIVP */
|
||||||
R0_DESC, R2_DESC, R4_ARG, 0, /* ASHP */
|
{R0_DESC, R2_DESC, R4_ARG, 0}, /* ASHP */
|
||||||
R0_DESC, 0, 0, 0, /* CVTLP */
|
{R0_DESC, 0, 0, 0}, /* CVTLP */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 100 - 107 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 100 - 107 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 110 - 117 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 110 - 117 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 120 - 127 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 120 - 127 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
IN_DESC, IN_DESC, IN_ARG, 0, /* MOVCI */
|
{IN_DESC, IN_DESC, IN_ARG, 0}, /* MOVCI */
|
||||||
IN_DESC, IN_DESC, IN_ARG, 0, /* MOVRCI */
|
{IN_DESC, IN_DESC, IN_ARG, 0}, /* MOVRCI */
|
||||||
IN_DESC, IN_DESC, IN_ARG, IN_ARG, /* MOVTCI */
|
{IN_DESC, IN_DESC, IN_ARG, IN_ARG}, /* MOVTCI */
|
||||||
0, 0, 0, 0, /* 133 */
|
{0, 0, 0, 0}, /* 133 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 134 - 137 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 134 - 137 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
IN_DESC, IN_ARG, 0, 0, /* LOCCI */
|
{IN_DESC, IN_ARG, 0, 0}, /* LOCCI */
|
||||||
IN_DESC, IN_ARG, 0, 0, /* SKPCI */
|
{IN_DESC, IN_ARG, 0, 0}, /* SKPCI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* SCANCI */
|
{IN_DESC, IN_DESC, 0, 0}, /* SCANCI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* SPANCI */
|
{IN_DESC, IN_DESC, 0, 0}, /* SPANCI */
|
||||||
IN_DESC, IN_DESC, IN_ARG, 0, /* CMPCI */
|
{IN_DESC, IN_DESC, IN_ARG, 0}, /* CMPCI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* MATCI */
|
{IN_DESC, IN_DESC, 0, 0}, /* MATCI */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 146 - 147 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 146 - 147 */
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* ADDNI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* ADDNI */
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* SUBNI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* SUBNI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* CMPNI */
|
{IN_DESC, IN_DESC, 0, 0}, /* CMPNI */
|
||||||
IN_DESC, IN_ARG, 0, 0, /* CVTNLI */
|
{IN_DESC, IN_ARG, 0, 0}, /* CVTNLI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* CVTPNI */
|
{IN_DESC, IN_DESC, 0, 0}, /* CVTPNI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* CVTNPI */
|
{IN_DESC, IN_DESC, 0, 0}, /* CVTNPI */
|
||||||
IN_DESC, IN_DESC, IN_ARG, 0, /* ASHNI */
|
{IN_DESC, IN_DESC, IN_ARG, 0}, /* ASHNI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* CVTLNI */
|
{IN_DESC, IN_DESC, 0, 0}, /* CVTLNI */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0, /* 160 - 167 */
|
{0, 0, 0, 0}, {0, 0, 0, 0}, /* 160 - 167 */
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
0, 0, 0, 0, 0, 0, 0, 0,
|
{0, 0, 0, 0}, {0, 0, 0, 0},
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* ADDPI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* ADDPI */
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* SUBPI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* SUBPI */
|
||||||
IN_DESC, IN_DESC, 0, 0, /* CMPPI */
|
{IN_DESC, IN_DESC, 0, 0}, /* CMPPI */
|
||||||
IN_DESC, IN_ARG, 0, 0, /* CVTPLI */
|
{IN_DESC, IN_ARG, 0, 0}, /* CVTPLI */
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* MULPI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* MULPI */
|
||||||
IN_DESC, IN_DESC, IN_DESC, 0, /* DIVPI */
|
{IN_DESC, IN_DESC, IN_DESC, 0}, /* DIVPI */
|
||||||
IN_DESC, IN_DESC, IN_ARG, 0, /* ASHPI */
|
{IN_DESC, IN_DESC, IN_ARG, 0}, /* ASHPI */
|
||||||
IN_DESC, IN_DESC, 0, 0 /* CVTLPI */
|
{IN_DESC, IN_DESC, 0, 0} /* CVTLPI */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/* ASCII to overpunch table: sign is <7>, digit is <4:0> */
|
/* ASCII to overpunch table: sign is <7>, digit is <4:0> */
|
||||||
|
|
||||||
static int32 overbin[128] = {
|
static int32 overbin[128] = {
|
||||||
|
|
|
@ -1523,7 +1523,7 @@ while (reason == 0) {
|
||||||
Z = V = C = 1; /* N = 0, Z = 1 */
|
Z = V = C = 1; /* N = 0, Z = 1 */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if ((src == 020000000000) && (src2 == 0177777)) {
|
if ((((uint32)src) == 020000000000) && (src2 == 0177777)) {
|
||||||
V = 1; /* J11,11/70 compat */
|
V = 1; /* J11,11/70 compat */
|
||||||
N = Z = C = 0; /* N = Z = 0 */
|
N = Z = C = 0; /* N = Z = 0 */
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -1426,7 +1426,7 @@ t_stat cr_reset ( DEVICE *dptr )
|
||||||
fprintf (sim_deb, "cr_reset\n");
|
fprintf (sim_deb, "cr_reset\n");
|
||||||
|
|
||||||
if (!translation_help) {
|
if (!translation_help) {
|
||||||
int i;
|
size_t i;
|
||||||
const char trans_hlp[] = "TRANSLATION={";
|
const char trans_hlp[] = "TRANSLATION={";
|
||||||
size_t size = sizeof(trans_hlp) +1;
|
size_t size = sizeof(trans_hlp) +1;
|
||||||
|
|
||||||
|
@ -1729,7 +1729,7 @@ t_stat cr_set_trans ( UNIT *uptr,
|
||||||
char *cptr,
|
char *cptr,
|
||||||
void *desc )
|
void *desc )
|
||||||
{
|
{
|
||||||
int i;
|
size_t i;
|
||||||
|
|
||||||
if (!cptr)
|
if (!cptr)
|
||||||
return (SCPE_MISVAL);
|
return (SCPE_MISVAL);
|
||||||
|
@ -1750,7 +1750,8 @@ t_stat cr_show_trans ( FILE *st,
|
||||||
int32 val,
|
int32 val,
|
||||||
void *desc )
|
void *desc )
|
||||||
{
|
{
|
||||||
int i;
|
size_t i;
|
||||||
|
|
||||||
for (i = 1; i < NTRANS; i++ )
|
for (i = 1; i < NTRANS; i++ )
|
||||||
if (transcodes[i].table == codeTbl) {
|
if (transcodes[i].table == codeTbl) {
|
||||||
fprintf (st, "translation=%s", transcodes[i].name);
|
fprintf (st, "translation=%s", transcodes[i].name);
|
||||||
|
|
|
@ -1998,7 +1998,7 @@ static void kdp_receive(int32 dupidx, int count) {
|
||||||
UNIT *rxup;
|
UNIT *rxup;
|
||||||
UNUSED_ARG (count);
|
UNUSED_ARG (count);
|
||||||
|
|
||||||
assert ((dupidx >= 0) && (dupidx < DIM(dupState)));
|
assert ((dupidx >= 0) && (((size_t)dupidx) < DIM(dupState)));
|
||||||
d = &dupState[dupidx];
|
d = &dupState[dupidx];
|
||||||
assert (dupidx == d->dupidx);
|
assert (dupidx == d->dupidx);
|
||||||
k = d->kmc;
|
k = d->kmc;
|
||||||
|
|
|
@ -563,7 +563,7 @@ text3 =
|
||||||
"\n"
|
"\n"
|
||||||
" RF11 data files are buffered in memory; therefore, end of file and OS\n"
|
" RF11 data files are buffered in memory; therefore, end of file and OS\n"
|
||||||
" I/O errors cannot occur.\n";
|
" I/O errors cannot occur.\n";
|
||||||
fprintf (st, "%s", text2);
|
fprintf (st, "%s", text3);
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -200,21 +200,21 @@ char *rs_description (DEVICE *dptr);
|
||||||
DIB rs_dib = { MBA_RS, 0, &rs_mbrd, &rs_mbwr, 0, 0, 0, { &rs_abort } };
|
DIB rs_dib = { MBA_RS, 0, &rs_mbrd, &rs_mbwr, 0, 0, 0, { &rs_abort } };
|
||||||
|
|
||||||
UNIT rs_unit[] = {
|
UNIT rs_unit[] = {
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) },
|
||||||
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO+
|
{ UDATA (&rs_svc, UNIT_FIX|UNIT_ATTABLE|UNIT_DISABLE|UNIT_AUTO|
|
||||||
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) }
|
UNIT_BUFABLE|UNIT_MUSTBUF|(RS04_DTYPE << UNIT_V_DTYPE), RS04_SIZE) }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -330,7 +330,6 @@ return SCPE_OK;
|
||||||
|
|
||||||
t_stat rs_mbwr (int32 data, int32 ofs, int32 drv)
|
t_stat rs_mbwr (int32 data, int32 ofs, int32 drv)
|
||||||
{
|
{
|
||||||
int32 dtype;
|
|
||||||
UNIT *uptr;
|
UNIT *uptr;
|
||||||
|
|
||||||
uptr = rs_dev.units + drv; /* get unit */
|
uptr = rs_dev.units + drv; /* get unit */
|
||||||
|
@ -341,7 +340,6 @@ if ((ofs != RS_AS_OF) && sim_is_active (uptr)) { /* unit busy? */
|
||||||
rs_update_ds (0, drv);
|
rs_update_ds (0, drv);
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
}
|
}
|
||||||
dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
|
||||||
ofs = ofs & MBA_RMASK; /* mask offset */
|
ofs = ofs & MBA_RMASK; /* mask offset */
|
||||||
|
|
||||||
switch (ofs) { /* decode PA<5:1> */
|
switch (ofs) { /* decode PA<5:1> */
|
||||||
|
@ -382,7 +380,7 @@ return SCPE_OK;
|
||||||
|
|
||||||
t_stat rs_go (int32 drv)
|
t_stat rs_go (int32 drv)
|
||||||
{
|
{
|
||||||
int32 fnc, dtype, t;
|
int32 fnc, t;
|
||||||
UNIT *uptr;
|
UNIT *uptr;
|
||||||
|
|
||||||
fnc = GET_FNC (rscs1[drv]); /* get function */
|
fnc = GET_FNC (rscs1[drv]); /* get function */
|
||||||
|
@ -391,7 +389,6 @@ if (DEBUG_PRS (rs_dev))
|
||||||
drv, rs_fname[fnc], rsds[drv], rsda[drv], rser[drv]);
|
drv, rs_fname[fnc], rsds[drv], rsda[drv], rser[drv]);
|
||||||
uptr = rs_dev.units + drv; /* get unit */
|
uptr = rs_dev.units + drv; /* get unit */
|
||||||
rs_clr_as (AS_U0 << drv); /* clear attention */
|
rs_clr_as (AS_U0 << drv); /* clear attention */
|
||||||
dtype = GET_DTYPE (uptr->flags); /* get drive type */
|
|
||||||
if ((fnc != FNC_DCLR) && (rsds[drv] & DS_ERR)) { /* err & ~clear? */
|
if ((fnc != FNC_DCLR) && (rsds[drv] & DS_ERR)) { /* err & ~clear? */
|
||||||
rs_set_er (ER_ILF, drv); /* not allowed */
|
rs_set_er (ER_ILF, drv); /* not allowed */
|
||||||
rs_update_ds (DS_ATA, drv); /* set attention */
|
rs_update_ds (DS_ATA, drv); /* set attention */
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* pdp11_ts.c: TS11/TSV05 magnetic tape simulator
|
/* pdp11_ts.c: TS11/TSV05 magnetic tape simulator
|
||||||
|
|
||||||
Copyright (c) 1993-2013, Robert M Supnik
|
Copyright (c) 1993-2014, Robert M Supnik
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
@ -25,6 +25,7 @@
|
||||||
|
|
||||||
ts TS11/TSV05 magtape
|
ts TS11/TSV05 magtape
|
||||||
|
|
||||||
|
27-Oct-14 RMS Fixed bug in read forward with byte swap
|
||||||
23-Oct-13 RMS Revised for new boot setup routine
|
23-Oct-13 RMS Revised for new boot setup routine
|
||||||
19-Mar-12 RMS Fixed declaration of cpu_opt (Mark Pizzolato)
|
19-Mar-12 RMS Fixed declaration of cpu_opt (Mark Pizzolato)
|
||||||
22-May-10 RMS Fixed t_addr printouts for 64b big-endian systems
|
22-May-10 RMS Fixed t_addr printouts for 64b big-endian systems
|
||||||
|
@ -591,7 +592,7 @@ msgxs0 = msgxs0 | XS0_MOT; /* tape has moved */
|
||||||
if (cmdhdr & CMD_SWP) { /* swapped? */
|
if (cmdhdr & CMD_SWP) { /* swapped? */
|
||||||
for (i = 0; i < wbc; i++) { /* copy buffer */
|
for (i = 0; i < wbc; i++) { /* copy buffer */
|
||||||
wa = tsba ^ 1; /* apply OPP */
|
wa = tsba ^ 1; /* apply OPP */
|
||||||
if (Map_WriteB (tsba, 1, &tsxb[i])) { /* store byte, nxm? */
|
if (Map_WriteB (wa, 1, &tsxb[i])) { /* store byte, nxm? */
|
||||||
tssr = ts_updtssr (tssr | TSSR_NXM); /* set error */
|
tssr = ts_updtssr (tssr | TSSR_NXM); /* set error */
|
||||||
return (XTC (XS0_RLS, TC4));
|
return (XTC (XS0_RLS, TC4));
|
||||||
}
|
}
|
||||||
|
@ -627,7 +628,7 @@ if (st != MTSE_OK) /* error? */
|
||||||
return ts_map_status (st);
|
return ts_map_status (st);
|
||||||
if (fc == 0) /* byte count */
|
if (fc == 0) /* byte count */
|
||||||
fc = 0200000;
|
fc = 0200000;
|
||||||
tsba = (cmdadh << 16) | cmdadl + fc; /* buf addr */
|
tsba = ((cmdadh << 16) | cmdadl) + fc; /* buf addr */
|
||||||
wbc = (tbc > fc)? fc: tbc; /* cap buf size */
|
wbc = (tbc > fc)? fc: tbc; /* cap buf size */
|
||||||
msgxs0 = msgxs0 | XS0_MOT; /* tape has moved */
|
msgxs0 = msgxs0 | XS0_MOT; /* tape has moved */
|
||||||
for (i = wbc; i > 0; i--) { /* copy buffer */
|
for (i = wbc; i > 0; i--) { /* copy buffer */
|
||||||
|
|
|
@ -515,8 +515,7 @@ return;
|
||||||
|
|
||||||
int32 machine_check (int32 p1, int32 opc, int32 cc, int32 delta)
|
int32 machine_check (int32 p1, int32 opc, int32 cc, int32 delta)
|
||||||
{
|
{
|
||||||
int32 acc, err;
|
int32 acc;
|
||||||
err = (GET_TRAP (trpirq) << 4) | (pme << 3) | ASTLVL; /* error word */
|
|
||||||
if (p1 == MCHK_BPE) /* bus error? */
|
if (p1 == MCHK_BPE) /* bus error? */
|
||||||
cc = intexc (SCB_MCHK, cc, 0, IE_EXC); /* take normal exception */
|
cc = intexc (SCB_MCHK, cc, 0, IE_EXC); /* take normal exception */
|
||||||
else
|
else
|
||||||
|
|
|
@ -234,7 +234,6 @@ return "Memory controller";
|
||||||
|
|
||||||
t_stat cpu_show_memory (FILE* st, UNIT* uptr, int32 val, void* desc)
|
t_stat cpu_show_memory (FILE* st, UNIT* uptr, int32 val, void* desc)
|
||||||
{
|
{
|
||||||
uint32 memsize = (uint32)(MEMSIZE>>10);
|
|
||||||
uint32 baseaddr = 0;
|
uint32 baseaddr = 0;
|
||||||
struct {
|
struct {
|
||||||
uint32 capacity;
|
uint32 capacity;
|
||||||
|
|
|
@ -554,7 +554,7 @@ return buf;
|
||||||
|
|
||||||
t_stat sim_instr (void)
|
t_stat sim_instr (void)
|
||||||
{
|
{
|
||||||
volatile int32 opc, cc; /* used by setjmp */
|
volatile int32 opc = 0, cc; /* used by setjmp */
|
||||||
volatile int32 acc; /* set by setjmp */
|
volatile int32 acc; /* set by setjmp */
|
||||||
int abortval;
|
int abortval;
|
||||||
t_stat r;
|
t_stat r;
|
||||||
|
|
14
scp.c
14
scp.c
|
@ -3244,8 +3244,8 @@ return SCPE_OK;
|
||||||
|
|
||||||
t_stat send_cmd (int32 flag, char *cptr)
|
t_stat send_cmd (int32 flag, char *cptr)
|
||||||
{
|
{
|
||||||
char gbuf[CBUFSIZE], *gptr = gbuf, *tptr;
|
char gbuf[CBUFSIZE], *tptr;
|
||||||
uint8 dbuf[CBUFSIZE], *dptr = dbuf;
|
uint8 dbuf[CBUFSIZE];
|
||||||
uint32 dsize = 0;
|
uint32 dsize = 0;
|
||||||
uint32 delay = 0;
|
uint32 delay = 0;
|
||||||
uint32 after = 0;
|
uint32 after = 0;
|
||||||
|
@ -4696,14 +4696,16 @@ if (dir) {
|
||||||
#endif
|
#endif
|
||||||
t_offset FileSize, TotalSize = 0;
|
t_offset FileSize, TotalSize = 0;
|
||||||
int DirCount = 0, FileCount = 0;
|
int DirCount = 0, FileCount = 0;
|
||||||
char FileName[PATH_MAX + 1], *MatchName;
|
char FileName[PATH_MAX + 1];
|
||||||
|
#if defined (HAVE_FNMATCH)
|
||||||
|
char *MatchName = 1 + strrchr (cptr, '/');;
|
||||||
|
#endif
|
||||||
char *c;
|
char *c;
|
||||||
struct tm *local;
|
struct tm *local;
|
||||||
#if defined (HAVE_GLOB)
|
#if defined (HAVE_GLOB)
|
||||||
int i;
|
size_t i;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
MatchName = 1 + strrchr (cptr, '/');
|
|
||||||
sim_printf (" Directory of %s\n\n", DirName[0] ? DirName : "/");
|
sim_printf (" Directory of %s\n\n", DirName[0] ? DirName : "/");
|
||||||
#if defined (HAVE_GLOB)
|
#if defined (HAVE_GLOB)
|
||||||
for (i=0; i<paths.gl_pathc; i++) {
|
for (i=0; i<paths.gl_pathc; i++) {
|
||||||
|
@ -8537,7 +8539,7 @@ return SCPE_OK;
|
||||||
|
|
||||||
t_stat sim_set_expect (EXPECT *exp, char *cptr)
|
t_stat sim_set_expect (EXPECT *exp, char *cptr)
|
||||||
{
|
{
|
||||||
char gbuf[CBUFSIZE], *gptr = gbuf, *tptr;
|
char gbuf[CBUFSIZE], *tptr;
|
||||||
const char *c1ptr;
|
const char *c1ptr;
|
||||||
uint32 after = exp->after;
|
uint32 after = exp->after;
|
||||||
int32 cnt = 0;
|
int32 cnt = 0;
|
||||||
|
|
|
@ -611,11 +611,14 @@ t_stat stat_nomessage = stat & SCPE_NOMESSAGE; /* extract possible message supr
|
||||||
|
|
||||||
cmdp = find_cmd (cmd);
|
cmdp = find_cmd (cmd);
|
||||||
stat = SCPE_BARE_STATUS(stat); /* remove possible flag */
|
stat = SCPE_BARE_STATUS(stat); /* remove possible flag */
|
||||||
if (cmdp && (cmdp->message)) /* special message handler? */
|
if (!stat_nomessage) {
|
||||||
|
if (cmdp && (cmdp->message)) /* special message handler? */
|
||||||
cmdp->message (NULL, stat); /* let it deal with display */
|
cmdp->message (NULL, stat); /* let it deal with display */
|
||||||
else
|
else {
|
||||||
if (stat >= SCPE_BASE) /* error? */
|
if (stat >= SCPE_BASE) /* error? */
|
||||||
sim_printf ("%s\r\n", sim_error_text (stat));
|
sim_printf ("%s\r\n", sim_error_text (stat));
|
||||||
|
}
|
||||||
|
}
|
||||||
return stat;
|
return stat;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -374,10 +374,10 @@ t_offset capac = ((t_offset)uptr->capac)*((dptr->flags & DEV_SECTORS) ? 512 : 1)
|
||||||
if (ctx->capac_factor == 2)
|
if (ctx->capac_factor == 2)
|
||||||
cap_units = "W";
|
cap_units = "W";
|
||||||
if (capac) {
|
if (capac) {
|
||||||
if (capac >= (t_addr) 1000000)
|
if (capac >= (t_offset) 1000000)
|
||||||
fprintf (st, "capacity=%dM%s", (uint32) (capac / ((t_addr) 1000000)), cap_units);
|
fprintf (st, "capacity=%dM%s", (uint32) (capac / ((t_offset) 1000000)), cap_units);
|
||||||
else if (uptr->capac >= (t_addr) 1000)
|
else if (uptr->capac >= (t_addr) 1000)
|
||||||
fprintf (st, "capacity=%dK%s", (uint32) (capac / ((t_addr) 1000)), cap_units);
|
fprintf (st, "capacity=%dK%s", (uint32) (capac / ((t_offset) 1000)), cap_units);
|
||||||
else fprintf (st, "capacity=%d%s", (uint32) capac, cap_units);
|
else fprintf (st, "capacity=%d%s", (uint32) capac, cap_units);
|
||||||
}
|
}
|
||||||
else fprintf (st, "undefined capacity");
|
else fprintf (st, "undefined capacity");
|
||||||
|
|
|
@ -630,7 +630,7 @@ static int32 loop_read (TMLN *lp, char *buf, int32 bufsize)
|
||||||
if (lp->datagram) {
|
if (lp->datagram) {
|
||||||
int32 pktsize;
|
int32 pktsize;
|
||||||
|
|
||||||
if (lp->lpbcnt < sizeof(pktsize))
|
if (lp->lpbcnt < (int32)sizeof(pktsize))
|
||||||
return 0;
|
return 0;
|
||||||
if ((sizeof(pktsize) != loop_read_ex (lp, (char *)&pktsize, sizeof(pktsize))) ||
|
if ((sizeof(pktsize) != loop_read_ex (lp, (char *)&pktsize, sizeof(pktsize))) ||
|
||||||
(pktsize > bufsize))
|
(pktsize > bufsize))
|
||||||
|
|
Loading…
Add table
Reference in a new issue