#include <perms.h>
// Edinburgh IMP77 Compiler - Version 8.4
//
// 1 !Graham Toal - new development version of SKIMPD 13/02/80 13.27
// 2
// 3 %const %string (1) snl = "
const _imp_string1 SNL = _imp_str_init("\n");
// 4+ "
// 5
// 6 %external %integer %array %spec a(1 : 500)
extern int A[500];
struct _imp_dv A_dv = {A, sizeof(int) /*, dims, <bounds> */};
// 7
// 8 %external %byte %integer %array %spec named(1 : 1024)
extern unsigned char NAMED[1024];
struct _imp_dv NAMED_dv = {NAMED, sizeof(unsigned char) /*, dims, <bounds> */};
// 9
// 10 %external %integer %array %spec namedlink(0 : 255)
extern int NAMEDLINK[256];
struct _imp_dv NAMEDLINK_dv = {NAMEDLINK, sizeof(int) /*, dims, <bounds> */};
// 11
// 12 %external %integer %array %spec taglink(0 : 255)
extern int TAGLINK[256];
struct _imp_dv TAGLINK_dv = {TAGLINK, sizeof(int) /*, dims, <bounds> */};
// 13
// 14 %external %integer %array %spec tag(1 : 512)
extern int TAG[512];
struct _imp_dv TAG_dv = {TAG, sizeof(int) /*, dims, <bounds> */};
// 15
// 16 %external %integer %array %spec link(1 : 512)
extern int LINK[512];
struct _imp_dv LINK_dv = {LINK, sizeof(int) /*, dims, <bounds> */};
// 17
// 18 %external %integer %array %spec nextrad(0 : 15)
extern int NEXTRAD[16];
struct _imp_dv NEXTRAD_dv = {NEXTRAD, sizeof(int) /*, dims, <bounds> */};
// 19
// 20 %external %integer %array %spec rt(0 : 15)
extern int RT[16];
struct _imp_dv RT_dv = {RT, sizeof(int) /*, dims, <bounds> */};
// 21
// 22 %external %integer %array %spec parms(0 : 15)
extern int PARMS[16];
struct _imp_dv PARMS_dv = {PARMS, sizeof(int) /*, dims, <bounds> */};
// 23
// 24 %external %string (5) %array %spec display(0 : 15)
extern _imp_string5 DISPLAY[16];
struct _imp_dv DISPLAY_dv = {DISPLAY, sizeof(_imp_string) /*, dims, <bounds> */};
// 25
// 26 %external %integer faults = 0
int FAULTS = 0;
// 27 %external %integer %spec tagasl, level, tagsopt, nextcad, namedp, %c
extern int TAGASL;
extern int LEVEL;
extern int TAGSOPT;
extern int NEXTCAD;
extern int NAMEDP;
extern int TRACEOPT;
extern int AOPT;
extern int PSTR;
// 28+ traceopt, aopt, pstr
// 29 !-----------------------------------------------------------------------
// 30 %external %integer %fn %spec intstr(%string (6) val)
extern int INTSTR(_imp_string6 VAL);
// 31 %external %routine %spec expr(%integer exprp)
extern void EXPR(int EXPRP);
static void POPITEM(int *FLAG, int *PLAB);
// 32 %routine %spec popitem(%integer %name f, l)
// 33 ! Local
// 34 %external %integer %fn %spec outstream
extern int OUTSTREAM(void);
// 35 !-----------------------------------------------------------------------
// 36 %own %integer %array used(0 : 15) = 0(*)
static int USED[16] = {[0 ... 15] = 0};
struct _imp_dv USED_dv = {USED, sizeof(int) /*, dims, <bounds> */};
// 37
// 38 %own %integer %array worklist(0 : 15) = 0(16)
static int WORKLIST[16] = {[0 ... 15] = 0};
struct _imp_dv WORKLIST_dv = {WORKLIST, sizeof(int) /*, dims, <bounds> */};
// 39
// 40 %own %integer %array namelist(0 : 15) = 0(16)
static int NAMELIST[16] = {[0 ... 15] = 0};
struct _imp_dv NAMELIST_dv = {NAMELIST, sizeof(int) /*, dims, <bounds> */};
// 41
// 42 %own %integer %array branchlist(0 : 15) = 0(16)
static int BRANCHLIST[16] = {[0 ... 15] = 0};
struct _imp_dv BRANCHLIST_dv = {BRANCHLIST, sizeof(int) /*, dims, <bounds> */};
// 43
// 44 %own %integer %array startlist(0 : 15) = 0(16)
static int STARTLIST[16] = {[0 ... 15] = 0};
struct _imp_dv STARTLIST_dv = {STARTLIST, sizeof(int) /*, dims, <bounds> */};
// 45
// 46 %own %integer %array cot(0 : 127)
static int COT[128];
struct _imp_dv COT_dv = {COT, sizeof(int) /*, dims, <bounds> */};
// 47
// 48 %own %integer cotp, params
static int COTP;
static int PARAMS;
// 49 !-----------------------------------------------------------------------
// 50 %external %string (255) %fn strint(%integer n, p)
_imp_string255 STRINT(int N, int P) {
// 51 %string (255) r
_imp_string255 R;
// 52 %string (1) s
_imp_string1 S;
// 53 %if n < 0 %then s = "-" %and n = -n %else s = ""
if (N >= 0) goto L_0001;
/* clang-format off */
_imp_strncpy(/*?*/&S, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("-"); (void *)&tmp;}), /*max:*/1);
/* clang-format on */
N = -N;
goto L_0002;
L_0001:;
/* clang-format off */
_imp_strncpy(/*?*/&S, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/1);
/* clang-format on */
L_0002:;
// 54 r = ""
/* clang-format off */
_imp_strncpy(/*?*/&R, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/255);
/* clang-format on */
// 55 r = tostring(n - n // 10 * 10 + '0') . r %and n = n // 10 %until n = 0
L_0003:;
/* clang-format off */
_imp_strncpy(/*?*/&R, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string1) tmp; /*D*/ tmp = _imp_TOSTRING(N - ( (long)N / (long)10 ) * 10 + 48); (void *)&tmp;}), (_imp_string *)/*?*/&R); (_imp_string255 *)&tmp;}); (void *)&tmp;}), /*max:*/255);
/* clang-format on */
N = ((long)N / (long)10);
if (N == 0) goto L_0004;
goto L_0003;
L_0004:;
// 56 r = s . r
/* clang-format off */
_imp_strncpy(/*?*/&R, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&S, (_imp_string *)/*?*/&R); (_imp_string255 *)&tmp;}); (void *)&tmp;}), /*max:*/255);
/* clang-format on */
// 57 r = " " . r %while length(r) < p
L_0005:;
if (*_imp_LENGTH((_imp_string255 *)/*p*/ /*?*/ &R) >= P) goto L_0006;
/* clang-format off */
_imp_strncpy(/*?*/&R, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr(" "), (_imp_string *)/*?*/&R); (_imp_string255 *)&tmp;}); (void *)&tmp;}), /*max:*/255);
/* clang-format on */
goto L_0005;
L_0006:;
// 58 %result = r
return *(_imp_string255 *)/*?*/ &R;
// 59 %end
} /* end of STRINT */
// 60 !-----------------------------------------------------------------------
// 61 %external %string (7) %fn s(%integer i)
_imp_string7 S(int I) {
// 62 %result = strint(i, 0)
return *(_imp_string7 *)/*?*/ &STRINT(I, 0);
// 63 %end
} /* end of S */
// 64 !-----------------------------------------------------------------------
// 65 %external %string (8) %fn strhex(%integer n)
_imp_string8 STRHEX(int N) {
// 66 %const %string (1) %array h(0 : 15) = %c
const _imp_string1 H[16] = {_imp_str_init("0"), _imp_str_init("1"), _imp_str_init("2"), _imp_str_init("3"),
_imp_str_init("4"), _imp_str_init("5"), _imp_str_init("6"), _imp_str_init("7"),
_imp_str_init("8"), _imp_str_init("9"), _imp_str_init("A"), _imp_str_init("B"),
_imp_str_init("C"), _imp_str_init("D"), _imp_str_init("E"), _imp_str_init("F")};
struct _imp_dv H_dv = {H, sizeof(_imp_string) /*, dims, <bounds> */};
// 67+ "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F"
// 68
// 69 %integer i
int I;
// 70 %string (8) sh
_imp_string8 SH;
// 71 sh = ""
/* clang-format off */
_imp_strncpy(/*?*/&SH, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/8);
/* clang-format on */
// 72 %for i = 1, 1, 8 %cycle
// %for I = 1, 1, 8 %cycle
{
I = 0;
L_0007:
if (I == 8) goto L_0008;
I += 1;
// 73 sh = h(n & 16_F) . sh
/* clang-format off */
_imp_strncpy(/*?*/&SH, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&H[N & 15], (_imp_string *)/*?*/&SH); (_imp_string255 *)&tmp;}); (void *)&tmp;}), /*max:*/8);
/* clang-format on */
// 74 n = n >> 4
N = (unsigned int)N >> 4;
// 75 %repeat
goto L_0007;
}
L_0008:;
// 76 %result = sh
return *(_imp_string8 *)/*?*/ &SH;
// 77 %end
} /* end of STRHEX */
// 78 !-----------------------------------------------------------------------
// 79 %external %routine fault(%string (63) mess)
void FAULT(_imp_string63 MESS) {
// 80 %integer st
int ST;
// 81 printstring("? " . mess . "
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("? "), (_imp_string *)/*?*/&MESS); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr("\n\n")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 82+
// 83+ ")
// 84 st = outstream
ST = OUTSTREAM();
// 85 selectoutput(0)
_imp_SELECTOUTPUT(0);
// 86 printstring("*" . mess . snl)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("*"), (_imp_string *)/*?*/&MESS); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/&SNL); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 87 selectoutput(st)
_imp_SELECTOUTPUT(ST);
// 88 faults = faults + 1
FAULTS = FAULTS + 1;
// 89 %end
return;
} /* end of FAULT */
// 90 !-----------------------------------------------------------------------
// 91 %external %routine dump(%string (7) lab, op, reg, addr)
void DUMP(_imp_string7 LAB, _imp_string7 OP, _imp_string7 REG, _imp_string7 ADDR) {
// 92 %own %string (7) label = ""
static _imp_string7 LABEL = _imp_str_init("");
auto void CODEOUT(_imp_string7 LAB, _imp_string7 OP, _imp_string7 REG, _imp_string7 ADDR);
// 93 %routine %spec codeout(%string (7) l, o, r, a)
// 94 %if label # "" %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LABEL, (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_000A;
/* clang-format on */
// 95 %if lab = "" %then lab = label %else %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) != 0) goto L_000B;
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&LAB, ({__typeof__(_imp_string7) tmp;/*B*/ tmp = LABEL; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
goto L_000C;
L_000B:;
// 96 codeout(label, "EQU", "", "*")
CODEOUT(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LABEL/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""), _imp_str_literal_size(7, "*"));
// 97 label = ""
/* clang-format off */
_imp_strncpy(/*?*/&LABEL, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 98 %finish
L_000C:;
// 99 %finish
L_000A:;
// 100 %if (op = "ADD" %or op = "SUB" %or op = "EOR" %or op = "OR") %and addr = "#0" %then %return
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("ADD")) == 0) goto L_0009;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("SUB")) == 0) goto L_0009;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("EOR")) == 0) goto L_0009;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("OR")) != 0) goto L_000D;
/* clang-format on */
L_0009:;
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#0")) != 0) goto L_000D;
/* clang-format on */
return;
L_000D:;
// 101 %if (op = "AND" %or op = "LD") %and reg # "D" %and addr = "#0" %then op = "CLR" %and addr = ""
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("AND")) == 0) goto L_000E;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_000F;
/* clang-format on */
L_000E:;
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("D")) == 0) goto L_000F;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#0")) != 0) goto L_000F;
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("CLR"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&ADDR, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
L_000F:;
// 102 %if op = "ADD" %and addr = "#1" %and reg # "D" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("ADD")) != 0) goto L_0010;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#1")) != 0) goto L_0010;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("D")) == 0) goto L_0010;
/* clang-format on */
// 103 op = "INC"
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("INC"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 104 addr = ""
/* clang-format off */
_imp_strncpy(/*?*/&ADDR, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 105 %finish
L_0010:;
// 106 %if op = "SUB" %and addr = "#1" %and reg # "D" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("SUB")) != 0) goto L_0011;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#1")) != 0) goto L_0011;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("D")) == 0) goto L_0011;
/* clang-format on */
// 107 op = "DEC"
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("DEC"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 108 addr = ""
/* clang-format off */
_imp_strncpy(/*?*/&ADDR, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 109 %finish
L_0011:;
// 110 %if op = "CMP" %and addr = "#0" %and reg # "D" %then op = "TST" %and addr = ""
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("CMP")) != 0) goto L_0012;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#0")) != 0) goto L_0012;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("D")) == 0) goto L_0012;
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("TST"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&ADDR, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
L_0012:;
// 111 %if op = "EQU" %and addr = "*" %then label = lab %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("EQU")) != 0) goto L_0013;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("*")) != 0) goto L_0013;
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&LABEL, ({__typeof__(_imp_string7) tmp;/*B*/ tmp = LAB; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
goto L_0014;
L_0013:;
/* clang-format off */
_imp_strncpy(/*?*/&LABEL, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
CODEOUT(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
L_0014:;
// 112+ %else label = "" %and codeout(lab, op, reg, addr)
// 113
// 114 %routine codeout(%string (7) lab, op, reg, addr)
void CODEOUT(_imp_string7 LAB, _imp_string7 OP, _imp_string7 REG, _imp_string7 ADDR) {
// 115 %string (6) nums
_imp_string6 NUMS;
// 116 %integer i
int I;
// 117 %routine dump2(%string (7) lab, op, reg, addr)
void DUMP2(_imp_string7 LAB, _imp_string7 OP, _imp_string7 REG, _imp_string7 ADDR) {
// 118 %own %string (7) lastop = "silly"
static _imp_string7 LASTOP = _imp_str_init("silly");
// 119 %own %integer inhibit = 0
static int INHIBIT = 0;
// 120 %if reg = "B" %and op = "LD" %and addr -> ("#") . nums %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("B")) != 0) goto L_0015;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_0015;
/* clang-format on */
if (!(_imp_resolve(*({
_imp_string7 tmp = ADDR;
(_imp_string255 *)&tmp;
}),
0 /*NULL*/, *({
_imp_string tmp = _imp_str_literal("#");
(_imp_string255 *)&tmp;
}),
(_imp_string255 *)/*?*/ &NUMS)))
goto L_0015;
if (_imp_resolve(*({
_imp_string6 tmp = NUMS;
(_imp_string255 *)&tmp;
}),
0 /*NULL*/, *({
_imp_string tmp = _imp_str_literal("-");
(_imp_string255 *)&tmp;
}),
(_imp_string255 *)/*?*/ &NUMS))
goto L_0015;
if (INTSTR(
/* clang-format off */
*({ __typeof__(_imp_string6) tmp = NUMS/*q*/; (_imp_string6 *)&tmp; })
/* clang-format on */
) <= 255)
goto L_0015;
/* clang-format off */
_imp_strncpy(/*?*/®, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("D"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
L_0015:;
// 121+ %and (%not nums -> ("-") . nums) %and intstr(nums) > 255 %then reg = "D"
// 122 %if lab # "" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_0016;
/* clang-format on */
// 123 %if op = "EQU" %and addr = "*" %then inhibit = 0
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("EQU")) != 0) goto L_0017;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("*")) != 0) goto L_0017;
/* clang-format on */
INHIBIT = 0;
L_0017:;
// 124 %if op # "EQU" %then inhibit = 0
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("EQU")) == 0) goto L_0018;
/* clang-format on */
INHIBIT = 0;
L_0018:;
// 125 %finish
L_0016:;
// 126 %if inhibit = 0 %or op = "EQU" %then %start
if (INHIBIT == 0) goto L_0019;
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("EQU")) != 0) goto L_001A;
/* clang-format on */
L_0019:;
// 127 lastop = op
/* clang-format off */
_imp_strncpy(/*?*/&LASTOP, ({__typeof__(_imp_string7) tmp;/*B*/ tmp = OP; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 128 %return %if op = "TST" %and reg = "B" %and lab = ""
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("TST")) != 0) goto L_001B;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("B")) != 0) goto L_001B;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) != 0) goto L_001B;
/* clang-format on */
return;
L_001B:;
// 129 ! ****FRIG****
// 130 %if op = "CMP" %and addr = "#1" %then addr = "" %and op = "DEC"
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("CMP")) != 0) goto L_001C;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("#1")) != 0) goto L_001C;
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&ADDR, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(""); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("DEC"); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
L_001C:;
// 131 printstring(lab)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 132 spaces(10 - length(lab))
_imp_SPACES(10 - *_imp_LENGTH((_imp_string255 *)/*p*/ /*?*/ &LAB));
// 133 op = op . reg
/* clang-format off */
_imp_strncpy(/*?*/&OP, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/®); (_imp_string255 *)&tmp;}); (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 134 printstring(op)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 135 spaces(10 - length(op))
_imp_SPACES(10 - *_imp_LENGTH((_imp_string255 *)/*p*/ /*?*/ &OP));
// 136 printstring(addr)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 137 newline
_imp_NEWLINE();
// 138 nextcad = nextcad + 1
NEXTCAD = NEXTCAD + 1;
// 139 %finish
L_001A:;
// 140 %if op = "LBRA" %or op = "SWI2" %or (op = "SWI" %and reg = "2") %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("LBRA")) == 0) goto L_001D;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("SWI2")) == 0) goto L_001D;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("SWI")) != 0) goto L_001E;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("2")) != 0) goto L_001E;
/* clang-format on */
L_001D:;
INHIBIT = 1;
L_001E:;
// 141+ %then inhibit = 1
// 142 %return %unless op = "LBSR"
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("LBSR")) == 0) goto L_001F;
/* clang-format on */
return;
L_001F:;
// 143 %if addr = "SHL" %then used(12) = 1
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("SHL")) != 0) goto L_0020;
/* clang-format on */
USED[12] = 1;
L_0020:;
// 144 %if addr = "SHR" %then used(13) = 1
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("SHR")) != 0) goto L_0021;
/* clang-format on */
USED[13] = 1;
L_0021:;
// 145 %if addr = "EXP" %then used(14) = 1
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("EXP")) != 0) goto L_0022;
/* clang-format on */
USED[14] = 1;
L_0022:;
// 146 %if addr = "DIV" %then used(15) = 1
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&ADDR, (_imp_string *)/*?*/_imp_str_literal_ptr("DIV")) != 0) goto L_0023;
/* clang-format on */
USED[15] = 1;
L_0023:;
// 147 %end
return;
} /* end of DUMP2 */
// 148 %own %string (7) %array l(1 : 2) = ""(2)
static _imp_string7 L[2] = {[0 ... 1] = _imp_str_init("")};
struct _imp_dv L_dv = {L, sizeof(_imp_string) /*, dims, <bounds> */};
// 149
// 150 %own %string (7) %array o(1 : 2) = ""(2)
static _imp_string7 O[2] = {[0 ... 1] = _imp_str_init("")};
struct _imp_dv O_dv = {O, sizeof(_imp_string) /*, dims, <bounds> */};
// 151
// 152 %own %string (7) %array r(1 : 2) = ""(2)
static _imp_string7 R[2] = {[0 ... 1] = _imp_str_init("")};
struct _imp_dv R_dv = {R, sizeof(_imp_string) /*, dims, <bounds> */};
// 153
// 154 %own %string (7) %array a(1 : 2) = ""(2)
static _imp_string7 A[2] = {[0 ... 1] = _imp_str_init("")};
struct _imp_dv A_dv = {A, sizeof(_imp_string) /*, dims, <bounds> */};
// 155
// 156 %own %integer buffptr = 0
static int BUFFPTR = 0;
// 157 %switch load(0:2)
int LOAD_index;
int LOAD_line;
char *LOAD_file;
static const void *LOAD[3] = {&&case_LOAD_missing, &&case_LOAD_missing, &&case_LOAD_missing};
// 158 %switch store(0:2)
int STORE_index;
int STORE_line;
char *STORE_file;
static const void *STORE[3] = {&&case_STORE_missing, &&case_STORE_missing, &&case_STORE_missing};
// 159 %routine flushbuffer
void FLUSHBUFFER(void) {
// 160 %integer i
int I;
// 161 %for i = 1, 1, buffptr %cycle
// %for I = 1, 1, BUFFPTR %cycle
{
int _final = BUFFPTR;
if (invalid_for_loop(1, 1, _final)) _imp_signal(5, 1, 0, "Illegal cycle I = 1, 1, BUFFPTR");
I = 0;
L_0024:
if (I == _final) goto L_0025;
I += 1;
// 162 dump2(l(i), o(i), r(i), a(i))
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[I - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = O[I - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = R[I - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = A[I - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 163 %repeat
goto L_0024;
}
L_0025:;
// 164 buffptr = 0
BUFFPTR = 0;
// 165 %end
return;
} /* end of FLUSHBUFFER */
// 166 %routine checklabel(%integer buff)
void CHECKLABEL(int BUFF) {
// 167 %if buff = 3 %then %start
if (BUFF != 3) goto L_0027;
// 168 %if lab # "" %then dump2(lab, "EQU", "", "*")
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_0028;
/* clang-format on */
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""), _imp_str_literal_size(7, "*"));
L_0028:;
// 169 %return
return;
// 170 %finish
L_0027:;
// 171 %if l(buff) # "" %then dump2(l(buff), "EQU", "", "*")
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&L[BUFF - 1], (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_0029;
/* clang-format on */
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[BUFF - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""), _imp_str_literal_size(7, "*"));
L_0029:;
// 172 %end
return;
} /* end of CHECKLABEL */
// 173 %routine savethisinstr
void SAVETHISINSTR(void) {
// 174 buffptr = buffptr + 1
BUFFPTR = BUFFPTR + 1;
// 175 %if buffptr > 2 %then %start
if (BUFFPTR <= 2) goto L_002A;
// 176 printstring("*?????Buffer full..." . snl)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("*?????Buffer full..."), (_imp_string *)/*?*/&SNL); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 177 flushbuffer
FLUSHBUFFER();
// 178 %finish
L_002A:;
// 179 l(buffptr) = lab
/* clang-format off */
_imp_strncpy(/*?*/&L[BUFFPTR - 1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = LAB; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 180 o(buffptr) = op
/* clang-format off */
_imp_strncpy(/*?*/&O[BUFFPTR - 1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = OP; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 181 r(buffptr) = reg
/* clang-format off */
_imp_strncpy(/*?*/&R[BUFFPTR - 1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = REG; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 182 a(buffptr) = addr
/* clang-format off */
_imp_strncpy(/*?*/&A[BUFFPTR - 1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = ADDR; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 183 %end
return;
} /* end of SAVETHISINSTR */
// 184 %if op = "SEX" %and buffptr # 0 %and o(buffptr) = "LD" %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("SEX")) != 0) goto L_002B;
/* clang-format on */
if (BUFFPTR == 0) goto L_002B;
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[BUFFPTR - 1], (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_002B;
/* clang-format on */
if (!(_imp_resolve(*({
_imp_string7 tmp = A[BUFFPTR - 1];
(_imp_string255 *)&tmp;
}),
0 /*NULL*/, *({
_imp_string tmp = _imp_str_literal("#");
(_imp_string255 *)&tmp;
}),
(_imp_string255 *)/*?*/ &NUMS)))
goto L_002B;
if (_imp_resolve(*({
_imp_string6 tmp = NUMS;
(_imp_string255 *)&tmp;
}),
0 /*NULL*/, *({
_imp_string tmp = _imp_str_literal("-");
(_imp_string255 *)&tmp;
}),
(_imp_string255 *)/*?*/ &NUMS))
goto L_002B;
if (INTSTR(
/* clang-format off */
*({ __typeof__(_imp_string6) tmp = NUMS/*q*/; (_imp_string6 *)&tmp; })
/* clang-format on */
) <= 255)
goto L_002B;
return;
L_002B:;
// 185+ %and a(buffptr) -> ("#") . nums %and (%not nums -> ("-") . nums) %c
// 186+ %and intstr(nums) > 255 %then %return
// 187 %if reg # "B" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("B")) == 0) goto L_002C;
/* clang-format on */
// 188 flushbuffer
FLUSHBUFFER();
// 189 dump2(lab, op, reg, addr)
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 190 %return
return;
// 191 %finish
L_002C:;
// 192 %if op = "LD" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_002D;
/* clang-format on */
// 193 -> load(buffptr)
LOAD_line = __LINE__;
LOAD_file = __FILE__;
LOAD_index = BUFFPTR;
goto case_LOAD_dispatch;
// 194 load(0):
case_LOAD_0:;
// 195 savethisinstr
SAVETHISINSTR();
// 196 %return
return;
// 197 load(1):
case_LOAD_1:;
// 198 %if o(1) = "LD" %then checklabel(1) %and buffptr = 0 %else %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_002F;
/* clang-format on */
CHECKLABEL(1);
BUFFPTR = 0;
goto L_0030;
L_002F:;
// 199 %if o(1) = "ST" %and a(1) = addr %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("ST")) != 0) goto L_0031;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&A[0], (_imp_string *)/*?*/&ADDR) != 0) goto L_0031;
/* clang-format on */
// 200 %if lab # "" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_0032;
/* clang-format on */
// 201 flushbuffer
FLUSHBUFFER();
// 202 savethisinstr
SAVETHISINSTR();
// 203 %return
return;
// 204 %finish %else %return
L_0032:;
return;
// 205 %finish
L_0031:;
// 206 %finish
L_0030:;
// 207 savethisinstr
SAVETHISINSTR();
// 208 %return
return;
// 209 load(2):
case_LOAD_2:;
// 210 dump2(l(1), o(1), r(1), a(1))
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = O[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = R[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = A[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 211 l(1) = l(2)
/* clang-format off */
_imp_strncpy(/*?*/&L[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = L[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 212 r(1) = r(2)
/* clang-format off */
_imp_strncpy(/*?*/&R[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = R[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 213 o(1) = o(2)
/* clang-format off */
_imp_strncpy(/*?*/&O[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = O[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 214 a(1) = a(2)
/* clang-format off */
_imp_strncpy(/*?*/&A[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = A[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 215 buffptr = 1
BUFFPTR = 1;
// 216 printstring("?***** Unexpected third el = load" . snl)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("?***** Unexpected third el = load"), (_imp_string *)/*?*/&SNL); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 217 -> load(1)
LOAD_line = __LINE__;
LOAD_file = __FILE__;
LOAD_index = 1;
goto case_LOAD_dispatch;
// 218 %finish
L_002D:;
// 219 %if op = "ST" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("ST")) != 0) goto L_0033;
/* clang-format on */
// 220 -> store(buffptr)
STORE_line = __LINE__;
STORE_file = __FILE__;
STORE_index = BUFFPTR;
goto case_STORE_dispatch;
// 221 store(0):
case_STORE_0:;
// 222 savethisinstr
SAVETHISINSTR();
// 223 %return
return;
// 224 store(1):
case_STORE_1:;
// 225 %if o(1) = "LD" %or o(1) = "ST" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) == 0) goto L_0035;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("ST")) != 0) goto L_0036;
/* clang-format on */
L_0035:;
// 226 %if a(1) = addr %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&A[0], (_imp_string *)/*?*/&ADDR) != 0) goto L_0037;
/* clang-format on */
// 227 %if lab # "" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&LAB, (_imp_string *)/*?*/_imp_str_literal_ptr("")) == 0) goto L_0038;
/* clang-format on */
// 228 flushbuffer
FLUSHBUFFER();
// 229 savethisinstr
SAVETHISINSTR();
// 230 %return
return;
// 231 %finish %else %return
L_0038:;
return;
// 232 %finish %else %start
L_0037:;
// 233 flushbuffer
FLUSHBUFFER();
// 234 savethisinstr
SAVETHISINSTR();
// 235 %return
return;
// 236 %finish
// 237 %finish
L_0036:;
// 238 %if o(1) = "CLR" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("CLR")) != 0) goto L_0039;
/* clang-format on */
// 239 checklabel(1)
CHECKLABEL(1);
// 240 buffptr = 0
BUFFPTR = 0;
// 241 dump2(lab, "CLR", "", addr)
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "CLR"), _imp_str_literal_size(7, ""),
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 242 %return
return;
// 243 %finish
L_0039:;
// 244 flushbuffer
FLUSHBUFFER();
// 245 savethisinstr
SAVETHISINSTR();
// 246 %return
return;
// 247 store(2):
case_STORE_2:;
// 248 %if o(1) = "LD" %and a(1) = addr %and (o(2) = "INC" %or o(2) = "DEC" %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[0], (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_003A;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&A[0], (_imp_string *)/*?*/&ADDR) != 0) goto L_003A;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[1], (_imp_string *)/*?*/_imp_str_literal_ptr("INC")) == 0) goto L_003B;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[1], (_imp_string *)/*?*/_imp_str_literal_ptr("DEC")) == 0) goto L_003B;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[1], (_imp_string *)/*?*/_imp_str_literal_ptr("NEG")) == 0) goto L_003B;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[1], (_imp_string *)/*?*/_imp_str_literal_ptr("COM")) != 0) goto L_003A;
/* clang-format on */
L_003B:;
// 249+ %or o(2) = "NEG" %or o(2) = "COM") %then %start
// 250 checklabel(2)
CHECKLABEL(2);
// 251 checklabel(3)
CHECKLABEL(3);
// 252 dump2(l(1), o(2), "", addr)
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = O[1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, ""),
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 253 buffptr = 0
BUFFPTR = 0;
// 254 %return
return;
// 255 %finish
L_003A:;
// 256 dump2(l(1), o(1), r(1), a(1))
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = O[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = R[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = A[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 257 l(1) = l(2)
/* clang-format off */
_imp_strncpy(/*?*/&L[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = L[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 258 o(1) = o(2)
/* clang-format off */
_imp_strncpy(/*?*/&O[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = O[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 259 r(1) = r(2)
/* clang-format off */
_imp_strncpy(/*?*/&R[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = R[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 260 a(1) = a(2)
/* clang-format off */
_imp_strncpy(/*?*/&A[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = A[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 261 buffptr = 1
BUFFPTR = 1;
// 262 -> store(1)
STORE_line = __LINE__;
STORE_file = __FILE__;
STORE_index = 1;
goto case_STORE_dispatch;
// 263 %finish
L_0033:;
// 264 %if op = "TST" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("TST")) != 0) goto L_003C;
/* clang-format on */
// 265 %if buffptr # 0 %then %start
if (BUFFPTR == 0) goto L_003D;
// 266 %if o(buffptr) = "LD" %then %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&O[BUFFPTR - 1], (_imp_string *)/*?*/_imp_str_literal_ptr("LD")) != 0) goto L_003E;
/* clang-format on */
// 267 dump2(l(buffptr), op, "", a(buffptr))
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[BUFFPTR - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, ""),
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = A[BUFFPTR - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 268 checklabel(3)
CHECKLABEL(3);
// 269 buffptr = buffptr - 1
BUFFPTR = BUFFPTR - 1;
// 270 %return
return;
// 271 %finish
L_003E:;
// 272 %finish
L_003D:;
// 273 flushbuffer
FLUSHBUFFER();
// 274 dump2(lab, op, reg, addr)
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 275 %return
return;
// 276 %finish
L_003C:;
// 277 %if op = "INC" %or op = "DEC" %or op = "CLR" %or op = "NEG" %c
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("INC")) == 0) goto L_0026;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("DEC")) == 0) goto L_0026;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("CLR")) == 0) goto L_0026;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("NEG")) == 0) goto L_0026;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&OP, (_imp_string *)/*?*/_imp_str_literal_ptr("COM")) != 0) goto L_003F;
/* clang-format on */
L_0026:;
// 278+ %or op = "COM" %then %start
// 279 %if buffptr = 2 %then %start
if (BUFFPTR != 2) goto L_0040;
// 280 dump2(l(1), o(1), r(1), a(1))
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = L[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = O[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = R[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = A[0]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 281 l(1) = l(2)
/* clang-format off */
_imp_strncpy(/*?*/&L[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = L[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 282 o(1) = o(2)
/* clang-format off */
_imp_strncpy(/*?*/&O[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = O[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 283 r(1) = r(2)
/* clang-format off */
_imp_strncpy(/*?*/&R[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = R[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 284 a(1) = a(2)
/* clang-format off */
_imp_strncpy(/*?*/&A[0], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = A[1]; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 285 l(2) = lab
/* clang-format off */
_imp_strncpy(/*?*/&L[1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = LAB; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 286 o(2) = op
/* clang-format off */
_imp_strncpy(/*?*/&O[1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = OP; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 287 r(2) = reg
/* clang-format off */
_imp_strncpy(/*?*/&R[1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = REG; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 288 a(2) = addr
/* clang-format off */
_imp_strncpy(/*?*/&A[1], ({__typeof__(_imp_string7) tmp;/*B*/ tmp = ADDR; (void *)&tmp;}), /*max:*/7);
/* clang-format on */
// 289 buffptr = 2
BUFFPTR = 2;
// 290 %return
return;
// 291 %finish
L_0040:;
// 292 savethisinstr
SAVETHISINSTR();
// 293 %return
return;
// 294 %finish
L_003F:;
// 295 flushbuffer
FLUSHBUFFER();
// 296 dump2(lab, op, reg, addr)
DUMP2(
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = LAB/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = OP/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string7) tmp = ADDR/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 297 %end
return;
case_LOAD_dispatch:
if (LOAD_index < 0 || LOAD_index > 2)
_imp_signalf(6, 3, LOAD_index, "->LOAD(%d) out of bounds at %s line %d", LOAD_index, LOAD_file, LOAD_line);
goto *LOAD[LOAD_index - 0];
case_LOAD_missing:
_imp_signalf(8, 2, LOAD_index, "switch jump to undefined label LOAD(%d): at %s line %d", LOAD_index, LOAD_file,
LOAD_line);
case_STORE_dispatch:
if (STORE_index < 0 || STORE_index > 2)
_imp_signalf(6, 3, STORE_index, "->STORE(%d) out of bounds at %s line %d", STORE_index, STORE_file, STORE_line);
goto *STORE[STORE_index - 0];
case_STORE_missing:
_imp_signalf(8, 2, STORE_index, "switch jump to undefined label STORE(%d): at %s line %d", STORE_index, STORE_file,
STORE_line);
} /* end of CODEOUT */
// ?I unused
// 298 %end
return;
} /* end of DUMP */
// 299 !-----------------------------------------------------------------------
// 300 %external %string (255) %fn name(%integer ident)
_imp_string255 NAME(int IDENT) {
// 301 %unless 0 <= ident <= 255 %and namedlink(ident) # 0 %then %result = ""
{
// Double-sided test on IDENT (Part I)
int tmp;
if (0 > (tmp = IDENT)) goto L_0041;
// Double-sided test on IDENT (Part II)
if (tmp > 255) goto L_0041;
}
if (NAMEDLINK[IDENT] != 0) goto L_0042;
L_0041:;
return *(_imp_string255 *)/*?*/ _imp_str_literal_ptr("");
L_0042:;
// 302 %result = string(addr(named(namedlink(ident))))
return *(_imp_string255 *)_imp_STRING(_imp_ADDR(/*?*/ &NAMED[NAMEDLINK[IDENT] - 1]));
// 303 %end
} /* end of NAME */
// 304 !-----------------------------------------------------------------------
// 305 %external %integer %fn newtag
int NEWTAG(void) {
// 306 %integer i
int I;
// 307 %if tagasl = 0 %then fault("TAG SPACE FULL") %and %stop
if (TAGASL != 0) goto L_0043;
FAULT(_imp_str_literal_size(63, "TAG SPACE FULL"));
_imp_stop(0);
L_0043:;
// 308 i = tagasl
I = TAGASL;
// 309 tagasl = link(tagasl)
TAGASL = LINK[TAGASL - 1];
// 310 %result = i
return I;
// 311 %end
} /* end of NEWTAG */
// 312 !-----------------------------------------------------------------------
// 313 %external %integer %fn returntag(%integer tagi)
int RETURNTAG(int TAGI) {
// 314 %integer l
int L;
// 315 l = link(tagi)
L = LINK[TAGI - 1];
// 316 link(tagi) = tagasl
LINK[TAGI - 1] = TAGASL;
// 317 tagasl = tagi
TAGASL = TAGI;
// 318 %result = l
return L;
// 319 %end
} /* end of RETURNTAG */
// 320 !-----------------------------------------------------------------------
// 321 %external %integer %fn getwork
int GETWORK(void) {
// 322 !%integername cell
// 323 ! cell==worklist(level)
// 324 ! %while cell#0 %cycle
// 325 ! %if tag(cell)<0 %then tag(cell)=-tag(cell) %and %result=tag(cell)
// 326 ! cell==link(cell)
// 327 ! %repeat
// 328 ! cell=newtag
// 329 ! tag(cell)=nextrad(level)
// 330 ! nextrad(level)=nextrad(level)+1
// 331 ! link(cell)=0
// 332 ! %result=tag(cell)
// 333 %result = 0
return 0;
// 334 %end
} /* end of GETWORK */
// 335 !-----------------------------------------------------------------------
// 336 %external %routine returnwork(%integer work)
void RETURNWORK(int WORK) {
// 337 !%integer cell
// 338 ! cell=worklist(level)
// 339 ! %while cell#0 %cycle
// 340 ! %if tag(cell)=work %then tag(cell)=-work %and %return
// 341 ! cell=link(cell)
// 342 ! %repeat
// 343 %end
return;
} /* end of RETURNWORK */
// ?WORK unused
// 344 !-----------------------------------------------------------------------
// 345 %external %routine clearwork
void CLEARWORK(void) {
// 346 %integer cell
int CELL;
// 347 cell = worklist(level)
CELL = WORKLIST[LEVEL];
// 348 cell = returntag(cell) %while cell # 0
L_0044:;
if (CELL == 0) goto L_0045;
CELL = RETURNTAG(CELL);
goto L_0044;
L_0045:;
// 349 worklist(level) = 0
WORKLIST[LEVEL] = 0;
// 350 %end
return;
} /* end of CLEARWORK */
// 351 !-----------------------------------------------------------------------
// 352 %external %integer %fn getcoti(%integer const)
int GETCOTI(int CONST) {
// 353 %integer coti
int COTI;
// 354 %if cotp > 0 %then %start
if (COTP <= 0) goto L_0046;
// 355 %for coti = 0, 1, cotp - 1 %cycle
// %for COTI = 0, 1, COTP - 1 %cycle
{
int _final = COTP - 1;
if (invalid_for_loop(0, 1, _final)) _imp_signal(5, 1, 0, "Illegal cycle COTI = 0, 1, COTP - 1");
COTI = -1;
L_0047:
if (COTI == _final) goto L_0048;
COTI += 1;
// 356 %if cot(coti) = const %then %result = coti
if (COT[COTI] != CONST) goto L_004A;
return COTI;
L_004A:;
// 357 %repeat
goto L_0047;
}
L_0048:;
// 358 %finish
L_0046:;
// 359 %if cotp = 128 %then fault("CONSTANT TABLE FULL") %and %stop
if (COTP != 128) goto L_004B;
FAULT(_imp_str_literal_size(63, "CONSTANT TABLE FULL"));
_imp_stop(0);
L_004B:;
// 360 cot(cotp) = const
COT[COTP] = CONST;
// 361 cotp = cotp + 1
COTP = COTP + 1;
// 362 %result = cotp - 1
return COTP - 1;
// 363 %end
} /* end of GETCOTI */
// 364 !-----------------------------------------------------------------------
// 365 %external %routine pushtag(%integer ident, form, type, dim, level, rad)
void PUSHTAG(int IDENT, int FORM, int TYPE, int DIM, int LEVEL, int RAD) {
// 366 %integer tagi
int TAGI;
// 367 %if taglink(ident) # 0 %and tag(taglink(ident)) >> 16 & 16_F = level %c
if (TAGLINK[IDENT] == 0) goto L_004C;
if ((unsigned int)TAG[TAGLINK[IDENT] - 1] >> 16 & 15 != LEVEL) goto L_004C;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("NAME "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = NAME(IDENT); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" DECLARED TWICE")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_004C:;
// 368+ %then fault("NAME " . name(ident) . " DECLARED TWICE")
// 369 tagi = newtag
TAGI = NEWTAG();
// 370 tag(tagi) = form << 28 ! type << 24 ! dim << 20 ! level << 16 ! rad
TAG[TAGI - 1] = FORM << 28 | TYPE << 24 | DIM << 20 | LEVEL << 16 | RAD;
// 371 link(tagi) = taglink(ident)
LINK[TAGI - 1] = TAGLINK[IDENT];
// 372 taglink(ident) = tagi
TAGLINK[IDENT] = TAGI;
// 373 tagi = newtag
TAGI = NEWTAG();
// 374 tag(tagi) = ident
TAG[TAGI - 1] = IDENT;
// 375 link(tagi) = namelist(level)
LINK[TAGI - 1] = NAMELIST[LEVEL];
// 376 namelist(level) = tagi
NAMELIST[LEVEL] = TAGI;
// 377 %end
return;
} /* end of PUSHTAG */
// 378 !-----------------------------------------------------------------------
// 379 %external %routine poptags
void POPTAGS(void) {
// 380 %integer cell, ident, nametag, params
int CELL;
int IDENT;
int NAMETAG;
int PARAMS;
// 381 %string (63) s
_imp_string63 S;
// 382 %if tagsopt = 1 %then newline
if (TAGSOPT != 1) goto L_004D;
_imp_NEWLINE();
L_004D:;
// 383 cell = namelist(level)
CELL = NAMELIST[LEVEL];
// 384 %while cell # 0 %cycle
L_004E:;
if (CELL == 0) goto L_004F;
// 385 ident = tag(cell)
IDENT = TAG[CELL - 1];
// 386 cell = returntag(cell)
CELL = RETURNTAG(CELL);
// 387 nametag = tag(taglink(ident))
NAMETAG = TAG[TAGLINK[IDENT] - 1];
// 388 taglink(ident) = returntag(taglink(ident))
TAGLINK[IDENT] = RETURNTAG(TAGLINK[IDENT]);
// 389 %if tagsopt = 1 %then %start
if (TAGSOPT != 1) goto L_0050;
// 390 s = name(ident)
/* clang-format off */
_imp_strncpy(/*?*/&S, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = NAME(IDENT); (void *)&tmp;}), /*max:*/63);
/* clang-format on */
// 391 printstring(strint(ident, 3) . " " . s)
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = STRINT(IDENT, 3); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" ")); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/&S); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 392 spaces(10 - length(s))
_imp_SPACES(10 - *_imp_LENGTH((_imp_string255 *)/*p*/ /*?*/ &S));
// 393 printstring(strhex(nametag))
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string8) tmp = STRHEX(NAMETAG)/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 394 %finish
L_0050:;
// 395 %if nametag >> 28 = 4 %then %start
if ((unsigned int)NAMETAG >> 28 != 4) goto L_0051;
// 396 ! procedure type
// 397 params = nametag >> 20 & 16_F
PARAMS = (unsigned int)NAMETAG >> 20 & 15;
// 398 %while params # 0 %cycle
L_0052:;
if (PARAMS == 0) goto L_0053;
// 399 %if tagsopt = 1 %then printstring("
if (TAGSOPT != 1) goto L_0054;
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("\n "), ({__typeof__(_imp_string8) tmp; /*E*/ tmp = STRHEX(TAG[TAGLINK[IDENT] - 1]); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
L_0054:;
// 400+ " . strhex(tag(taglink(ident))))
// 401 taglink(ident) = returntag(taglink(ident))
TAGLINK[IDENT] = RETURNTAG(TAGLINK[IDENT]);
// 402 params = params - 1
PARAMS = PARAMS - 1;
// 403 ! pop up parameter tags
// 404 %repeat
goto L_0052;
L_0053:;
// 405 %finish
L_0051:;
// 406 %if tagsopt = 1 %then newline
if (TAGSOPT != 1) goto L_0055;
_imp_NEWLINE();
L_0055:;
// 407 %if taglink(ident) = 0 %then namedp = namedlink(ident) %and namedlink(ident) = 0
if (TAGLINK[IDENT] != 0) goto L_0056;
NAMEDP = NAMEDLINK[IDENT];
NAMEDLINK[IDENT] = 0;
L_0056:;
// 408 ! backtrack name dictionary
// 409 %repeat
goto L_004E;
L_004F:;
// 410 %if tagsopt = 1 %then newline
if (TAGSOPT != 1) goto L_0057;
_imp_NEWLINE();
L_0057:;
// 411 namelist(level) = 0
NAMELIST[LEVEL] = 0;
// 412 %end
return;
} /* end of POPTAGS */
// 413 !-----------------------------------------------------------------------
// 414 %external %integer %fn getlabel(%integer constp)
int GETLABEL(int CONSTP) {
// 415 %integer label
int LABEL;
// 416 label = a(constp + 1)
LABEL = A[CONSTP + 1 - 1];
// 417 %if label > 9999 %then fault("LABEL " . strint(label, 1) . " TOO LARGE") %c
if (LABEL <= 9999) goto L_0058;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("LABEL "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = STRINT(LABEL, 1); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" TOO LARGE")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
return -1;
L_0058:;
return LABEL;
// 418+ %and %result = -1 %else %result = label
// 419 %end
} /* end of GETLABEL */
// 420 !-----------------------------------------------------------------------
// 421 %external %routine filllabel(%integer label)
void FILLLABEL(int LABEL) {
// 422 !%integer cell
// 423 %return %if label < 0
if (LABEL >= 0) goto L_0059;
return;
L_0059:;
// 424 ! for conditional statements
// 425 ! cell=branchlist(level)
// 426 ! %while cell#0 %cycle
// 427 ! %if tag(cell)>>16=label %then %start
// 428 ! %if tag(cell)&16_8000=0 %then fault("DUPLICATE LABEL ". ! strint(label,1)) %else %start
// 429 dump("L" . s(label), "EQU", "", "*")
DUMP(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("L"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(LABEL); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""), _imp_str_literal_size(7, "*"));
// 430 ! tag(cell)=label<<16!nextcad
// 431 ! %finish
// 432 ! %return
// 433 ! %finish
// 434 ! cell=link(cell)
// 435 ! %repeat
// 436 ! cell=newtag
// 437 ! link(cell)=branchlist(level)
// 438 ! branchlist(level)=cell
// 439 ! tag(cell)=label<<16!nextcad
// 440 %end
return;
} /* end of FILLLABEL */
// 441 !-----------------------------------------------------------------------
// 442 %external %integer %fn fillbranch(%integer label)
int FILLBRANCH(int LABEL) {
// 443 %integer cell, cad
int CELL;
int CAD;
// 444 %result = 0 %if label < 0
if (LABEL >= 0) goto L_005A;
return 0;
L_005A:;
// 445 cell = branchlist(level)
CELL = BRANCHLIST[LEVEL];
// 446 %while cell # 0 %cycle
L_005B:;
if (CELL == 0) goto L_005C;
// 447 %if tag(cell) >> 16 = label %then %start
if ((unsigned int)TAG[CELL - 1] >> 16 != LABEL) goto L_005D;
// 448 cad = tag(cell) & 16_7FFF
CAD = TAG[CELL - 1] & 32767;
// 449 %if tag(cell) & 16_8000 # 0 %then tag(cell) = label << 16 ! 16_8000 ! nextcad
if (TAG[CELL - 1] & 32768 == 0) goto L_005E;
TAG[CELL - 1] = LABEL << 16 | 32768 | NEXTCAD;
L_005E:;
// 450 %result = cad
return CAD;
// 451 %finish
L_005D:;
// 452 cell = link(cell)
CELL = LINK[CELL - 1];
// 453 %repeat
goto L_005B;
L_005C:;
// 454 cell = newtag
CELL = NEWTAG();
// 455 link(cell) = branchlist(level)
LINK[CELL - 1] = BRANCHLIST[LEVEL];
// 456 branchlist(level) = cell
BRANCHLIST[LEVEL] = CELL;
// 457 tag(cell) = label << 16 ! 16_8000 ! nextcad
TAG[CELL - 1] = LABEL << 16 | 32768 | NEXTCAD;
// 458 %result = 0
return 0;
// 459 %end
} /* end of FILLBRANCH */
// 460 !-----------------------------------------------------------------------
// 461 %external %routine poplabels
void POPLABELS(void) {
// 462 %integer cell
int CELL;
// 463 cell = branchlist(level)
CELL = BRANCHLIST[LEVEL];
// 464 %while cell # 0 %cycle
L_005F:;
if (CELL == 0) goto L_0060;
// 465 %if tag(cell) & 16_8000 # 0 %then fault("LABEL " . strint(tag(cell) >> 16, 1) . %c
if (TAG[CELL - 1] & 32768 == 0) goto L_0061;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("LABEL "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = STRINT((unsigned int)TAG[CELL - 1] >> 16, 1); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" NOT SET (BRANCH LIST ")); (_imp_string255 *)&tmp;}), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = STRINT(TAG[CELL - 1] & 32767, 1); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(")")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_0061:;
// 466+ " NOT SET (BRANCH LIST " . strint(tag(cell) & 16_7FFF, 1) . ")")
// 467 cell = returntag(cell)
CELL = RETURNTAG(CELL);
// 468 %repeat
goto L_005F;
L_0060:;
// 469 branchlist(level) = 0
BRANCHLIST[LEVEL] = 0;
// 470 %end
return;
} /* end of POPLABELS */
// 471 !-----------------------------------------------------------------------
// 472 %external %integer %fn nextplabel
int NEXTPLABEL(void) {
// 473 %own %integer plabel = 9999
static int PLABEL = 9999;
// 474 plabel = plabel + 1
PLABEL = PLABEL + 1;
// 475 %result = plabel
return PLABEL;
// 476 %end
} /* end of NEXTPLABEL */
// 477 !-----------------------------------------------------------------------
// 478 %external %routine pushstart(%integer flag, plab)
void PUSHSTART(int FLAG, int PLAB) {
// 479 %integer cell
int CELL;
// 480 cell = newtag
CELL = NEWTAG();
// 481 tag(cell) = flag << 16 ! plab & 16_FFFF
TAG[CELL - 1] = FLAG << 16 | PLAB & 65535;
// 482 ! plab may be -1
// 483 link(cell) = startlist(level)
LINK[CELL - 1] = STARTLIST[LEVEL];
// 484 startlist(level) = cell
STARTLIST[LEVEL] = CELL;
// 485 %end
return;
} /* end of PUSHSTART */
// 486 %external %predicate find(%integer type, %integer %name t, lab)
int FIND(int TYPE, int *T, int *LAB) {
// 487 %integer cell
int CELL;
// 488 cell = startlist(level)
CELL = STARTLIST[LEVEL];
// 489 %while cell # 0 %cycle
L_0062:;
if (CELL == 0) goto L_0063;
// 490 t = tag(cell) >> 16
*T = (unsigned int)TAG[CELL - 1] >> 16;
// 491 %if t & 2 = type %then %start
if (*T & 2 != TYPE) goto L_0064;
// 492 lab = tag(cell) & 16_FFFF
*LAB = TAG[CELL - 1] & 65535;
// 493 %true
return 1 /*TRUE*/;
// 494 %finish
L_0064:;
// 495 cell = link(cell)
CELL = LINK[CELL - 1];
// 496 %repeat
goto L_0062;
L_0063:;
// 497 t = 0
*T = 0;
// 498 lab = 0
*LAB = 0;
// 499 %false
return 0 /*FALSE*/;
// 500 %end
} /* end of FIND */
// 501 %external %routine findcontinue(%integer %name type, lab)
void FINDCONTINUE(int *TYPE, int *LAB) {
// 502 %if find(2, type, lab) %then lab = lab + 1 %c
if (!(FIND(2, TYPE, LAB))) goto L_0065;
*LAB = *LAB + 1;
goto L_0066;
L_0065:;
*TYPE = 0;
*LAB = 0;
FAULT(_imp_str_literal_size(63, "%CYCLE MISSING"));
L_0066:;
// 503+ %else type = 0 %and lab = 0 %and fault("%CYCLE MISSING")
// 504 %end
return;
} /* end of FINDCONTINUE */
// 505 %external %routine findexit(%integer %name type, lab)
void FINDEXIT(int *TYPE, int *LAB) {
// 506 %if find(2, type, lab) %then lab = lab + 2 %c
if (!(FIND(2, TYPE, LAB))) goto L_0067;
*LAB = *LAB + 2;
goto L_0068;
L_0067:;
*TYPE = 0;
*LAB = 0;
FAULT(_imp_str_literal_size(63, "%CYCLE MISSING"));
L_0068:;
// 507+ %else type = 0 %and lab = 0 %and fault("%CYCLE MISSING")
// 508 %end
return;
} /* end of FINDEXIT */
// 509 %predicate findcycle
static int FINDCYCLE(void) {
// 510 %integer t, l
int T;
int L;
// 511 %if find(2, t, l) %then %true
if (!(FIND(2, /*?*/ &T, /*?*/ &L))) goto L_0069;
return 1 /*TRUE*/;
L_0069:;
// 512 %false
return 0 /*FALSE*/;
// 513 %end
} /* end of FINDCYCLE */
// 514 %predicate findstart
static int FINDSTART(void) {
// 515 %integer t, l
int T;
int L;
// 516 %if find(0, t, l) %then %true
if (!(FIND(0, /*?*/ &T, /*?*/ &L))) goto L_006A;
return 1 /*TRUE*/;
L_006A:;
// 517 %false
return 0 /*FALSE*/;
// 518 %end
} /* end of FINDSTART */
// 519 %external %routine popcycle(%integer %name type, lab)
void POPCYCLE(int *TYPE, int *LAB) {
// 520 popitem(type, lab)
POPITEM(TYPE, LAB);
// 521 %if type & 2 = 0 %then %start
if (*TYPE & 2 != 0) goto L_006B;
// 522 %if findcycle %then %start
if (!(FINDCYCLE())) goto L_006C;
// 523 fault("%FINISH MISSING {Or spurious %REPEAT??}")
FAULT(_imp_str_literal_size(63, "%FINISH MISSING {Or spurious %REPEAT??}"));
// 524 %finish %else %start
goto L_006D;
L_006C:;
// 525 fault("SPURIOUS %REPEAT")
FAULT(_imp_str_literal_size(63, "SPURIOUS %REPEAT"));
// 526 pushstart(type, lab) %if lab # 0
if (*LAB == 0) goto L_006E;
PUSHSTART(*TYPE, *LAB);
L_006E:;
// 527 %finish
L_006D:;
// 528 lab = 0
*LAB = 0;
// 529 type = 3
*TYPE = 3;
// 530 %finish
L_006B:;
// 531 %end
return;
} /* end of POPCYCLE */
// 532 %external %routine popstart(%integer %name type, lab)
void POPSTART(int *TYPE, int *LAB) {
// 533 popitem(type, lab)
POPITEM(TYPE, LAB);
// 534 %if type & 2 = 2 %or lab = 0 %then %start
if (*TYPE & 2 == 2) goto L_006F;
if (*LAB != 0) goto L_0070;
L_006F:;
// 535 %if findstart %then %start
if (!(FINDSTART())) goto L_0071;
// 536 fault("%REPEAT MISSING {Or spurious %FINISH??}")
FAULT(_imp_str_literal_size(63, "%REPEAT MISSING {Or spurious %FINISH??}"));
// 537 %finish %else %start
goto L_0072;
L_0071:;
// 538 fault("SPURIOUS %FINISH")
FAULT(_imp_str_literal_size(63, "SPURIOUS %FINISH"));
// 539 pushstart(type, lab) %if lab # 0
if (*LAB == 0) goto L_0073;
PUSHSTART(*TYPE, *LAB);
L_0073:;
// 540 %finish
L_0072:;
// 541 lab = 0
*LAB = 0;
// 542 type = 0
*TYPE = 0;
// 543 %finish
L_0070:;
// 544 %end
return;
} /* end of POPSTART */
// 545 !-----------------------------------------------------------------------
// 546 %routine popitem(%integer %name flag, plab)
static void POPITEM(int *FLAG, int *PLAB) {
// 547 %integer cell
int CELL;
// 548 cell = startlist(level)
CELL = STARTLIST[LEVEL];
// 549 %if cell = 0 %then %start
if (CELL != 0) goto L_0074;
// 550 flag = 0
*FLAG = 0;
// 551 plab = 0
*PLAB = 0;
// 552 %finish %else %start
goto L_0075;
L_0074:;
// 553 flag = tag(cell) >> 16
*FLAG = (unsigned int)TAG[CELL - 1] >> 16;
// 554 plab = tag(cell) & 16_FFFF
*PLAB = TAG[CELL - 1] & 65535;
// 555 %if plab = 16_FFFF %then plab = -1
if (*PLAB != 65535) goto L_0076;
*PLAB = -1;
L_0076:;
// 556 startlist(level) = returntag(cell)
STARTLIST[LEVEL] = RETURNTAG(CELL);
// 557 %finish
L_0075:;
// 558 %end
return;
} /* end of POPITEM */
// 559 !-----------------------------------------------------------------------
// 560 %external %routine clearstart
void CLEARSTART(void) {
// 561 %integer cell
int CELL;
// 562 %const %string (7) %array what(0 : 1) = "%FINISH", "%REPEAT"
const _imp_string7 WHAT[2] = {_imp_str_init("%FINISH"), _imp_str_init("%REPEAT")};
struct _imp_dv WHAT_dv = {WHAT, sizeof(_imp_string) /*, dims, <bounds> */};
// 563
// 564 cell = startlist(level)
CELL = STARTLIST[LEVEL];
// 565 %while cell # 0 %cycle
L_0077:;
if (CELL == 0) goto L_0078;
// 566 fault(what(tag(cell) >> 17) . " MISSING")
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&WHAT[(unsigned int)TAG[CELL - 1] >> 17], (_imp_string *)/*?*/_imp_str_literal_ptr(" MISSING")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
// 567 cell = returntag(cell)
CELL = RETURNTAG(CELL);
// 568 %repeat
goto L_0077;
L_0078:;
// 569 startlist(level) = 0
STARTLIST[LEVEL] = 0;
// 570 %end
return;
} /* end of CLEARSTART */
// 571 !-----------------------------------------------------------------------
// 572 %external %integer %fn enter
int ENTER(void) {
// 573 %own %string (4) %array regs(1 : 2) = "A", "A,B"
static _imp_string4 REGS[2] = {_imp_str_init("A"), _imp_str_init("A,B")};
struct _imp_dv REGS_dv = {REGS, sizeof(_imp_string) /*, dims, <bounds> */};
// 574
// 575 %string (4) base
_imp_string4 BASE;
// 576 %integer alloc, dim
int ALLOC;
int DIM;
// 577 %if level = 1 %then %start
if (LEVEL != 1) goto L_0079;
// 578 %if nextcad # 1 %then fault("%BEGIN NOT FIRST STATEMENT")
if (NEXTCAD == 1) goto L_007A;
FAULT(_imp_str_literal_size(63, "%BEGIN NOT FIRST STATEMENT"));
L_007A:;
// 579 dump("", "ORG", "", "$F800")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ORG"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "$F800"));
// 580 dump("START", "EQU", "", "*")
DUMP(_imp_str_literal_size(7, "START"), _imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "*"));
// 581 dump("", "SWI", "3", "") %if traceopt = 1
if (TRACEOPT != 1) goto L_007B;
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SWI"), _imp_str_literal_size(7, "3"),
_imp_str_literal_size(7, ""));
L_007B:;
// 582 dump("", "LD", "U", "#STACK")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "U"),
_imp_str_literal_size(7, "#STACK"));
// 583 dump("", "LEA", "X", "-USTK,U")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "X"),
_imp_str_literal_size(7, "-USTK,U"));
// 584 base = ",X"
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(",X"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 585 alloc = 34
ALLOC = 34;
// 586 ! Already set up by calling program
// 587 ! Rest for I/O buffers and perm locations.
// 588 %finish %else %start
goto L_007C;
L_0079:;
// 589 ! STORE STP (=Y) IF NECCESARY
// 590 %if level > 2 %start
if (LEVEL <= 2) goto L_007D;
// 591 dump("", "ST", "Y", display(level - 1))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"), _imp_str_literal_size(7, "Y"),
/* clang-format off */
*({ __typeof__(_imp_string5) tmp = DISPLAY[LEVEL - 1]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 592 %finish
L_007D:;
// 593 dump("", "PSH", "S", "Y")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "PSH"), _imp_str_literal_size(7, "S"),
_imp_str_literal_size(7, "Y"));
// 594 dump("", "TFR", "", "S,Y")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TFR"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "S,Y"));
// 595 alloc = 0
ALLOC = 0;
// 596 base = ",Y"
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(",Y"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 597 %finish
L_007C:;
// 598 ! cad=nextcad
// 599 %if level # 1 %then %start
if (LEVEL == 1) goto L_007E;
// 600 ! REMOVED TO 'SKIMPB'
// 601 %finish %else %start
goto L_007F;
L_007E:;
// 602 dump("", "LEA", "S", "-A" . s(rt(level)) . ",X")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "S"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-A"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(RT[LEVEL]); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",X")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 603 %finish
L_007F:;
// 604 nextrad(level) = alloc
NEXTRAD[LEVEL] = ALLOC;
// 605 %result = alloc
return ALLOC;
// 606 %end
} /* end of ENTER */
// ?DIM unused
// ?REGS unused
// 607 !-----------------------------------------------------------------------
// 608 %external %routine dumpreturn
void DUMPRETURN(void) {
// 609 dump("", "TFR", "", "Y,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TFR"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "Y,S"));
// 610 dump("", "PUL", "S", "Y,PC")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "PUL"), _imp_str_literal_size(7, "S"),
_imp_str_literal_size(7, "Y,PC"));
// 611 %end
return;
} /* end of DUMPRETURN */
// 612 !-----------------------------------------------------------------------
// 613 %external %routine array(%integer arrayp)
void ARRAY(int ARRAYP) {
// 614 %integer namep, actualp, exprp, exprsp, ident, nametag, basep, disp
int NAMEP;
int ACTUALP;
int EXPRP;
int EXPRSP;
int IDENT;
int NAMETAG;
int BASEP;
int DISP;
// 615 %string (4) base
_imp_string4 BASE;
// 616 namep = a(arrayp + 1)
NAMEP = A[ARRAYP + 1 - 1];
// 617 actualp = a(arrayp + 2)
ACTUALP = A[ARRAYP + 2 - 1];
// 618 ident = a(namep + 1)
IDENT = A[NAMEP + 1 - 1];
// 619 %if a(actualp) = 1 %then %start
if (A[ACTUALP - 1] != 1) goto L_0080;
// 620 dump(" ", "CLR", "A", "")
DUMP(_imp_str_literal_size(7, " "), _imp_str_literal_size(7, "CLR"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, ""));
// 621 dump("", "ANDCC", "", "0")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ANDCC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "0"));
// 622 exprp = a(actualp + 1)
EXPRP = A[ACTUALP + 1 - 1];
// 623 exprsp = a(actualp + 2)
EXPRSP = A[ACTUALP + 2 - 1];
// 624 expr(exprp)
EXPR(EXPRP);
// 625 nametag = tag(taglink(ident))
NAMETAG = TAG[TAGLINK[IDENT] - 1];
// 626 basep = nametag >> 16 & 16_F
BASEP = (unsigned int)NAMETAG >> 16 & 15;
// 627 base = display(basep)
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string5) tmp;/*B*/ tmp = DISPLAY[BASEP]; (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 628 base = ",Y" %if basep = level
if (BASEP != LEVEL) goto L_0081;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(",Y"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
L_0081:;
// 629 base = ",X" %if basep = 1
if (BASEP != 1) goto L_0082;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal(",X"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
L_0082:;
// 630 disp = nametag & 16_FFFF
DISP = NAMETAG & 65535;
// 631 dump("", "BCC", "", "*+3")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BCC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "*+3"));
// 632 dump("", "INC", "A", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, ""));
// 633 %if basep = 1 %or basep = level %start
if (BASEP == 1) goto L_0049;
if (BASEP != LEVEL) goto L_0083;
L_0049:;
// 634 dump("", "ADD", "D", "-" . s(disp) . base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ADD"), _imp_str_literal_size(7, "D"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/&BASE); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 635 %finish %else %start
goto L_0084;
L_0083:;
// 636 dump("", "PSH", "U", "A,B")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "PSH"), _imp_str_literal_size(7, "U"),
_imp_str_literal_size(7, "A,B"));
// 637 dump("", "LD", "D", display(basep))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "D"),
/* clang-format off */
*({ __typeof__(_imp_string5) tmp = DISPLAY[BASEP]/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 638 dump("", "SUB", "D", "#" . s(disp))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"), _imp_str_literal_size(7, "D"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("#"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 639 dump("", "ST", "D", "0,X")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"), _imp_str_literal_size(7, "D"),
_imp_str_literal_size(7, "0,X"));
// 640 dump("", "LD", "D", "[0,X]")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "D"),
_imp_str_literal_size(7, "[0,X]"));
// 641 dump("", "ADD", "D", ",U++")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ADD"), _imp_str_literal_size(7, "D"),
_imp_str_literal_size(7, ",U++"));
// 642 %finish
L_0084:;
// 643 dump("", "ST", "D", "0,X") %if aopt = 0
if (AOPT != 0) goto L_0085;
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"), _imp_str_literal_size(7, "D"),
_imp_str_literal_size(7, "0,X"));
L_0085:;
// 644 aopt = 0
AOPT = 0;
// 645 ! dump("ADD","ACC",display(nametag>>16&16_f),nametag&16_ffff)
// 646 %if a(exprsp) = 1 %then fault("ARRAY " . name(ident) . " HAS EXTRA INDEX")
if (A[EXPRSP - 1] != 1) goto L_0086;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("ARRAY "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = NAME(IDENT); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" HAS EXTRA INDEX")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_0086:;
// 647 %finish %else fault("ARRAY " . name(ident) . " HAS NO INDEX")
goto L_0087;
L_0080:;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("ARRAY "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = NAME(IDENT); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" HAS NO INDEX")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_0087:;
// 648 %end
return;
} /* end of ARRAY */
// 649 !-----------------------------------------------------------------------
// 650 %external %routine proc(%integer procp)
void PROC(int PROCP) {
// 651 %string (4) opn, base, reg
_imp_string4 OPN;
_imp_string4 BASE;
_imp_string4 REG;
// 652 %integer namep, ident, nametag, ptagl, l, actualp, exprp, unaryp, operandp, %c
int NAMEP;
int IDENT;
int NAMETAG;
int PTAGL;
int L;
int ACTUALP;
int EXPRP;
int UNARYP;
int OPERANDP;
int NPARS;
int PTAG;
int PNAMEP;
int PIDENT;
int PNAMETAG;
int PACTUALP;
int DISP;
int EXPRRESTP;
int EXPRSP;
int OLDPARAMS;
int BASEP;
int SIZE;
// 653+ npars, ptag, pnamep, pident, pnametag, pactualp, disp, exprrestp, exprsp, %c
// 654+ oldparams, basep, size
// 655 ! %if params>2 %then dump("LDA","STP","STP",params)
// 656 !***! hack !***!
// 657 %if params >= 2 %then dump("", "LEA", "S", "-" . s(params + 1) . ",S")
if (PARAMS < 2) goto L_0088;
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "S"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(PARAMS + 1); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",S")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
L_0088:;
// 658 !***! hack !***!
// 659 oldparams = params
OLDPARAMS = PARAMS;
// 660 params = 4
PARAMS = 4;
// 661 namep = a(procp + 1)
NAMEP = A[PROCP + 1 - 1];
// 662 actualp = a(procp + 2)
ACTUALP = A[PROCP + 2 - 1];
// 663 ident = a(namep + 1)
IDENT = A[NAMEP + 1 - 1];
// 664 l = taglink(ident)
L = TAGLINK[IDENT];
// 665 nametag = tag(l)
NAMETAG = TAG[L - 1];
// 666 ptagl = link(l)
PTAGL = LINK[L - 1];
// 667 npars = nametag >> 20 & 16_F
NPARS = (unsigned int)NAMETAG >> 20 & 15;
// 668 %if npars = 0 %then %start
if (NPARS != 0) goto L_0089;
// 669 %if a(actualp) = 1 %then fault(name(ident) . " HAS PARAMETERS") %and %return
if (A[ACTUALP - 1] != 1) goto L_008A;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(IDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" HAS PARAMETERS")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
return;
L_008A:;
// 670 %finish %else %start
goto L_008B;
L_0089:;
// 671 %if a(actualp) = 2 %then fault(name(ident) . " MISSING PARAMETERS") %and %return
if (A[ACTUALP - 1] != 2) goto L_008C;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(IDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" MISSING PARAMETERS")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
return;
L_008C:;
// 672 exprp = a(actualp + 1)
EXPRP = A[ACTUALP + 1 - 1];
// 673 exprsp = a(actualp + 2)
EXPRSP = A[ACTUALP + 2 - 1];
// 674 %cycle
L_008D:;
// 675 ! for each parameter
// 676 ptag = tag(ptagl)
PTAG = TAG[PTAGL - 1];
// 677 %if ptag >> 28 = 0 %then expr(exprp) %and reg = "B" %else %start
if ((unsigned int)PTAG >> 28 != 0) goto L_008E;
EXPR(EXPRP);
/* clang-format off */
_imp_strncpy(/*?*/®, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("B"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
goto L_008F;
L_008E:;
// 678 reg = "D"
/* clang-format off */
_imp_strncpy(/*?*/®, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("D"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 679 unaryp = a(exprp + 1)
UNARYP = A[EXPRP + 1 - 1];
// 680 operandp = a(exprp + 2)
OPERANDP = A[EXPRP + 2 - 1];
// 681 exprrestp = a(exprp + 3)
EXPRRESTP = A[EXPRP + 3 - 1];
// 682 %unless a(unaryp) = 4 %and a(operandp) = 1 %and a(exprrestp) = 2 %c
if (A[UNARYP - 1] != 4) goto L_0090;
if (A[OPERANDP - 1] != 1) goto L_0090;
if (A[EXPRRESTP - 1] == 2) goto L_0091;
L_0090:;
FAULT(_imp_str_literal_size(63, "NOT A %NAME PARAMETER"));
goto L_0092;
L_0091:;
// 683+ %then fault("NOT A %NAME PARAMETER") %else %start
// 684 pnamep = a(operandp + 1)
PNAMEP = A[OPERANDP + 1 - 1];
// 685 pactualp = a(operandp + 2)
PACTUALP = A[OPERANDP + 2 - 1];
// 686 pident = a(pnamep + 1)
PIDENT = A[PNAMEP + 1 - 1];
// 687 !? %if taglink(pident)=0 %then fault(name(pident). !? " NOT DECLARED") %else %start
// 688 %if taglink(pident) = 0 %then %start
if (TAGLINK[PIDENT] != 0) goto L_0093;
// 689 dump("", "LD", "B", name(pident))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "B"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = NAME(PIDENT)/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 690 %finish %else %start
goto L_0094;
L_0093:;
// 691 pnametag = tag(taglink(pident))
PNAMETAG = TAG[TAGLINK[PIDENT] - 1];
// 692 %if pnametag >> 28 = 4 %then fault(name(pident) . " NOT A %NAME") %else %start
if ((unsigned int)PNAMETAG >> 28 != 4) goto L_0095;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(PIDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" NOT A %NAME")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
goto L_0096;
L_0095:;
// 693 basep = pnametag >> 16 & 16_F
BASEP = (unsigned int)PNAMETAG >> 16 & 15;
// 694 base = display(basep)
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string5) tmp;/*B*/ tmp = DISPLAY[BASEP]; (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 695 disp = pnametag & 16_FFFF
DISP = PNAMETAG & 65535;
// 696 base = "Y" %if basep = level
if (BASEP != LEVEL) goto L_0097;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("Y"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
L_0097:;
// 697 base = "X" %if basep = 1
if (BASEP != 1) goto L_0098;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("X"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
L_0098:;
// 698 %if ptag >> 28 = 1 %then %start
if ((unsigned int)PTAG >> 28 != 1) goto L_0099;
// 699 ! %name
// 700 %if pnametag >> 28 >= 2 %then aopt = 1 %and array(operandp) %else %start
if ((unsigned int)PNAMETAG >> 28 < 2) goto L_009A;
AOPT = 1;
ARRAY(OPERANDP);
goto L_009B;
L_009A:;
// 701 %if pnametag >> 28 = 1 %then %start
if ((unsigned int)PNAMETAG >> 28 != 1) goto L_009C;
// 702 %if 1 < basep < level %start
{
// Double-sided test on BASEP (Part I)
int tmp;
if (1 >= (tmp = BASEP)) goto L_009D;
// Double-sided test on BASEP (Part II)
if (tmp >= LEVEL) goto L_009D;
}
// 703 dump("", "LD", reg, base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = BASE/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 704 dump("", "SUB", reg, "#" . s(disp))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("#"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 705 dump("", "ST", reg, "0,X")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "0,X"));
// 706 dump("", "LD", reg, "[0,X]")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "[0,X]"));
// 707 %finish %else %start
goto L_009E;
L_009D:;
// 708 dump("", "LD", reg, "-" . s(disp) . "," . base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",")); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/&BASE); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 709 %finish
L_009E:;
// 710 %finish %else %start
goto L_009F;
L_009C:;
// 711 %if 1 < basep < level %start
{
// Double-sided test on BASEP (Part I)
int tmp;
if (1 >= (tmp = BASEP)) goto L_00A0;
// Double-sided test on BASEP (Part II)
if (tmp >= LEVEL) goto L_00A0;
}
// 712 dump("", "LD", reg, base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = BASE/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 713 dump("", "SUB", reg, "#" . s(disp))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("#"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 714 %finish %else %start
goto L_00A1;
L_00A0:;
// 715 %if basep = 1 = level %then %start
{
// Double-sided test on 1 (Part I)
int tmp;
if (BASEP != (tmp = 1)) goto L_00A2;
// Double-sided test on 1 (Part II)
if (tmp != LEVEL) goto L_00A2;
}
// 716 dump("", "LEA", "Y", "-" . s(disp) . ",X")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "Y"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",X")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 717 reg = "Y"
/* clang-format off */
_imp_strncpy(/*?*/®, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("Y"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
// 718 %finish %else %start
goto L_00A3;
L_00A2:;
// 719 dump("", "TFR", "", base . ",D")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TFR"), _imp_str_literal_size(7, ""),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&BASE, (_imp_string *)/*?*/_imp_str_literal_ptr(",D")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 720 dump("", "SUB", reg, "#" . s(disp))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("#"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 721 %finish
L_00A3:;
// 722 ! GET ADDRESS OF A %NAME INTO B
// 723 %finish
L_00A1:;
// 724 %finish
L_009F:;
// 725 ! CHECK FOR SILLY BASE REGISTER
// 726 ! dump(opn,"ACC",base,disp)
// 727 %if a(pactualp) = 1 %then fault(name(pident) . " DECLARED AS SCALAR")
if (A[PACTUALP - 1] != 1) goto L_00A4;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(PIDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" DECLARED AS SCALAR")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_00A4:;
// 728 %finish
L_009B:;
// 729 %finish %else %start
goto L_00A5;
L_0099:;
// 730 ! dump("LOAD","ACC",base,disp) ;! %array
// 731 %if base = "Y" %or base = "X" %start
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&BASE, (_imp_string *)/*?*/_imp_str_literal_ptr("Y")) == 0) goto L_00A6;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/&BASE, (_imp_string *)/*?*/_imp_str_literal_ptr("X")) != 0) goto L_00A7;
/* clang-format on */
L_00A6:;
// 732 dump("", "LD", reg, "-" . s(disp) . "," . base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",")); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/&BASE); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 733 %finish %else %start
goto L_00A8;
L_00A7:;
// 734 dump("", "LD", reg, base)
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = BASE/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 735 dump("", "SUB", reg, "#" . s(disp))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("#"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(DISP); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 736 dump("", "ST", reg, "0,X")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "0,X"));
// 737 dump("", "LD", reg, "[0,X]")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LD"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
_imp_str_literal_size(7, "[0,X]"));
// 738 %finish
L_00A8:;
// 739 ! CHECK SILLY BASE REGISTER
// 740 %if a(pactualp) = 1 %then fault("%ARRAYNAME " . name(pident) . " HAS INDEX")
if (A[PACTUALP - 1] != 1) goto L_00A9;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("%ARRAYNAME "), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = NAME(PIDENT); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" HAS INDEX")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_00A9:;
// 741 %finish
L_00A5:;
// 742 %finish
L_0096:;
// 743 %finish
L_0094:;
// 744 %finish
L_0092:;
// 745 %finish
L_008F:;
// 746 ! dump("STR","ACC","STP",params)
// 747 %if reg = "D" %or reg = "Y" %then size = 2 %else size = 1
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("D")) == 0) goto L_00AA;
/* clang-format on */
/* clang-format off */
if (_imp_strcmp((_imp_string *)/*?*/®, (_imp_string *)/*?*/_imp_str_literal_ptr("Y")) != 0) goto L_00AB;
/* clang-format on */
L_00AA:;
SIZE = 2;
goto L_00AC;
L_00AB:;
SIZE = 1;
L_00AC:;
// 748 params = params + size
PARAMS = PARAMS + SIZE;
// 749 dump("", "ST", reg, "-" . s(params) . ",S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"),
/* clang-format off */
*({ __typeof__(_imp_string4) tmp = REG/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
,
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("-"), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(PARAMS); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",S")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 750 npars = npars - 1
NPARS = NPARS - 1;
// 751 %if npars = 0 %then %start
if (NPARS != 0) goto L_00AD;
// 752 %if a(exprsp) = 1 %then fault(name(ident) . " HAS EXTRA PARAMETERS")
if (A[EXPRSP - 1] != 1) goto L_00AE;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(IDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" HAS EXTRA PARAMETERS")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
L_00AE:;
// 753 %exit
goto L_00AF;
// 754 %finish
L_00AD:;
// 755 ptagl = link(ptagl)
PTAGL = LINK[PTAGL - 1];
// 756 %if a(exprsp) = 2 %then fault(name(ident) . " IS MISSING PARAMETERS") %and %exit
if (A[EXPRSP - 1] != 2) goto L_00B0;
FAULT(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string255) tmp; /*D*/ tmp = NAME(IDENT); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" IS MISSING PARAMETERS")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string63 *)&tmp; })
/* clang-format on */
);
goto L_00AF;
L_00B0:;
// 757 exprp = a(exprsp + 1)
EXPRP = A[EXPRSP + 1 - 1];
// 758 exprsp = a(exprsp + 2)
EXPRSP = A[EXPRSP + 2 - 1];
// 759 %repeat
goto L_008D;
L_00AF:;
// 760 %finish
L_008B:;
// 761 ! external i/o routines at level 0
// 762 %if nametag >> 16 & 16_F = 0 %then base = "EXT" %else base = "E"
if ((unsigned int)NAMETAG >> 16 & 15 != 0) goto L_00B1;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("EXT"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
goto L_00B2;
L_00B1:;
/* clang-format off */
_imp_strncpy(/*?*/&BASE, ({__typeof__(_imp_string255) tmp;/*B*/ tmp = _imp_str_literal("E"); (void *)&tmp;}), /*max:*/4);
/* clang-format on */
L_00B2:;
// 763 %if nametag >> 16 & 16_F = 0 %then %start
if ((unsigned int)NAMETAG >> 16 & 15 != 0) goto L_00B3;
// 764 used(nametag & 16_F) = 1
USED[NAMETAG & 15] = 1;
// 765 %finish
L_00B3:;
// 766 dump("", "LBSR", "", base . s(nametag & 16_FFFF))
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LBSR"), _imp_str_literal_size(7, ""),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&BASE, ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(NAMETAG & 65535); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
// 767 params = oldparams
PARAMS = OLDPARAMS;
// 768 ! EH??????
// 769 !***! frig !***!
// 770 %if params >= 2 %then dump("", "LEA", "S", s(params + 1) . ",S")
if (PARAMS < 2) goto L_00B4;
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "S"),
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join(({__typeof__(_imp_string7) tmp; /*D*/ tmp = S(PARAMS + 1); (void *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(",S")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string7 *)&tmp; })
/* clang-format on */
);
L_00B4:;
// 771 ! %if params>2 %then dump("SUB","STP","COT",getcoti(params))
// 772 %end
return;
} /* end of PROC */
// ?OPN unused
// 773 !-----------------------------------------------------------------------
// 774 %external %routine endofprog
void ENDOFPROG(void) {
// 775 %integer i
int I;
// 776 dump("", "SWI", "2", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SWI"), _imp_str_literal_size(7, "2"),
_imp_str_literal_size(7, ""));
// 777 dump("STACK", "EQU", "", "$0800-1")
DUMP(_imp_str_literal_size(7, "STACK"), _imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "$0800-1"));
// 778 dump("USTK", "EQU", "", "$20")
DUMP(_imp_str_literal_size(7, "USTK"), _imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "$20"));
// 779 ! DUMP("EXT1","EQU","","") %IF USED(1)=1
// 780 ! DUMP("EXT2","EQU","","") %IF USED(2)=1
// 781 ! DUMP("EXT3","EQU","","") %IF USED(3)=1
// 782 ! DUMP("EXT4","EQU","","") %IF USED(4)=1
// 783 ! DUMP("EXT5","EQU","","") %IF USED(5)=1
// 784 ! DUMP("EXT6","EQU","","") %IF USED(6)=1
// 785 ! DUMP("EXT7","EQU","","") %IF USED(7)=1
// 786 ! DUMP("EXT8","EQU","","") %IF USED(8)=1
// 787 ! DUMP("EXT9","EQU","","") %IF USED(9)=1
// 788 ! DUMP("EXT10","EQU","","") %IF USED(10)=1
// 789 !! READSYMBOL POSING AS READ
// 790 ! DUMP("EXT11","EQU","","") %AND USED(15)=1 %IF USED(11)=1
// 791 %if used(12) = 1 %then %start
if (USED[12] != 1) goto L_00B5;
// 792 dump("DOSHL", "LSL", "B", "")
DUMP(_imp_str_literal_size(7, "DOSHL"), _imp_str_literal_size(7, "LSL"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 793 dump("", "SUB", "A", "#1")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#1"));
// 794 dump("SHL", "CMP", "A", "#0")
DUMP(_imp_str_literal_size(7, "SHL"), _imp_str_literal_size(7, "CMP"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#0"));
// 795 dump("", "BGT", "", "DOSHL")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BGT"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "DOSHL"));
// 796 dump("", "RTS", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "RTS"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 797 %finish
L_00B5:;
// 798 %if used(13) = 1 %then %start
if (USED[13] != 1) goto L_00B6;
// 799 dump("DOSHR", "LSR", "B", "")
DUMP(_imp_str_literal_size(7, "DOSHR"), _imp_str_literal_size(7, "LSR"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 800 dump("", "SUB", "A", "#1")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#1"));
// 801 dump("SHR", "CMP", "A", "#0")
DUMP(_imp_str_literal_size(7, "SHR"), _imp_str_literal_size(7, "CMP"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#0"));
// 802 dump("", "BGT", "", "DOSHR")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BGT"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "DOSHR"));
// 803 dump("", "RTS", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "RTS"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 804 %finish
L_00B6:;
// 805 %if used(14) = 1 %then %start
if (USED[14] != 1) goto L_00B7;
// 806 dump("EXP", "PSH", "S", "B")
DUMP(_imp_str_literal_size(7, "EXP"), _imp_str_literal_size(7, "PSH"), _imp_str_literal_size(7, "S"),
_imp_str_literal_size(7, "B"));
// 807 dump("EXP2", "CMP", "A", "#1")
DUMP(_imp_str_literal_size(7, "EXP2"), _imp_str_literal_size(7, "CMP"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#1"));
// 808 dump("", "BGT", "", "DOEXP")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BGT"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "DOEXP"));
// 809 dump("", "LEA", "S", "1,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LEA"), _imp_str_literal_size(7, "S"),
_imp_str_literal_size(7, "1,S"));
// 810 dump("", "RTS", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "RTS"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 811 dump("DOEXP", "PSH", "U", "A")
DUMP(_imp_str_literal_size(7, "DOEXP"), _imp_str_literal_size(7, "PSH"), _imp_str_literal_size(7, "U"),
_imp_str_literal_size(7, "A"));
// 812 dump("", "LDA", "", "0,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "LDA"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "0,S"));
// 813 dump("", "MUL", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "MUL"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 814 dump("", "PUL", "U", "A")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "PUL"), _imp_str_literal_size(7, "U"),
_imp_str_literal_size(7, "A"));
// 815 dump("", "SUB", "A", "#1")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#1"));
// 816 dump("", "BRA", "", "EXP2")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BRA"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "EXP2"));
// 817 %finish
L_00B7:;
// 818 %if used(15) = 1 %then %start
if (USED[15] != 1) goto L_00B8;
// 819 ! 'B'//'A'
// 820 dump("DIV", "EQU", "", "*")
DUMP(_imp_str_literal_size(7, "DIV"), _imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "*"));
// 821 dump("", "CLR", "", "-1,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "CLR"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-1,S"));
// 822 dump("", "CLR", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "CLR"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 823 dump("", "INC", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 824 dump("", "TST", "B", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TST"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 825 dump("", "BGE", "", "TRYA")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BGE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "TRYA"));
// 826 dump("", "NEG", "B", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "NEG"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 827 dump("", "CLR", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "CLR"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 828 dump("TRYA", "TST", "A", "")
DUMP(_imp_str_literal_size(7, "TRYA"), _imp_str_literal_size(7, "TST"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, ""));
// 829 dump("", "BGE", "", "OK")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BGE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "OK"));
// 830 dump("", "NEG", "A", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "NEG"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, ""));
// 831 dump("", "TST", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TST"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 832 dump("", "BNE", "", "OK")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BNE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "OK"));
// 833 dump("", "INC", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 834 dump("OK", "TST", "B", "")
DUMP(_imp_str_literal_size(7, "OK"), _imp_str_literal_size(7, "TST"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 835 dump("", "BLT", "", "DONE")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BLT"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "DONE"));
// 836 dump("", "INC", "", "-1,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-1,S"));
// 837 dump("", "PSH", "U", "A")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "PSH"), _imp_str_literal_size(7, "U"),
_imp_str_literal_size(7, "A"));
// 838 dump("", "SUB", "B", ",U+")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "SUB"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ",U+"));
// 839 dump("", "BRA", "", "OK")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BRA"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "OK"));
// 840 dump("DONE", "DEC", "", "-1,S")
DUMP(_imp_str_literal_size(7, "DONE"), _imp_str_literal_size(7, "DEC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-1,S"));
// 841 dump("", "TST", "", "-2,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "TST"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-2,S"));
// 842 dump("", "BNE", "", "RET")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BNE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "RET"));
// 843 dump("", "NEG", "", "-1,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "NEG"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "-1,S"));
// 844 dump("RET", "LD", "B", "-1,S")
DUMP(_imp_str_literal_size(7, "RET"), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, "-1,S"));
// 845 dump("", "RTS", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "RTS"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 846 %finish %else dump("DIV", "EQU", "", "0")
goto L_00B9;
L_00B8:;
DUMP(_imp_str_literal_size(7, "DIV"), _imp_str_literal_size(7, "EQU"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "0"));
L_00B9:;
// 847 ! newline
// 848 %if pstr # 0 %then %start
if (PSTR == 0) goto L_00BA;
// 849 dump("OUTCH", "LD", "A", "ACIAS")
DUMP(_imp_str_literal_size(7, "OUTCH"), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "ACIAS"));
// 850 dump("", "AND", "A", "#2")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "AND"), _imp_str_literal_size(7, "A"),
_imp_str_literal_size(7, "#2"));
// 851 dump("", "BEQ", "", "OUTCH")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BEQ"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "OUTCH"));
// 852 dump("", "ST", "B", "ACIAD")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "ST"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, "ACIAD"));
// 853 dump("WAITX", "LD", "B", "#$FF")
DUMP(_imp_str_literal_size(7, "WAITX"), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, "#$FF"));
// 854 dump("", "DEC", "B", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "DEC"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, ""));
// 855 dump("", "BNE", "", "WAITX")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BNE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "WAITX"));
// 856 dump("PSTR", "LD", "B", "[0,S]")
DUMP(_imp_str_literal_size(7, "PSTR"), _imp_str_literal_size(7, "LD"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, "[0,S]"));
// 857 dump("", "INC", "", "1,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "1,S"));
// 858 dump("", "BNE", "", "NOCAR")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BNE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "NOCAR"));
// 859 dump("", "INC", "", "0,S")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "INC"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "0,S"));
// 860 dump("NOCAR", "CMP", "B", "#$80")
DUMP(_imp_str_literal_size(7, "NOCAR"), _imp_str_literal_size(7, "CMP"), _imp_str_literal_size(7, "B"),
_imp_str_literal_size(7, "#$80"));
// 861 dump("", "BNE", "", "OUTCH")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "BNE"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, "OUTCH"));
// 862 dump("", "RTS", "", "")
DUMP(_imp_str_literal_size(7, ""), _imp_str_literal_size(7, "RTS"), _imp_str_literal_size(7, ""),
_imp_str_literal_size(7, ""));
// 863 %finish
L_00BA:;
// 864 %if faults > 0 %start
if (FAULTS <= 0) goto L_00BB;
// 865 %begin
{ /*%begin*/
// 866 %integer st
int ST;
// 867 st = outstream
ST = OUTSTREAM();
// 868 selectoutput(0)
_imp_SELECTOUTPUT(0);
// 869 printstring("Program contains " . s(faults) . " fault")
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/&*({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("Program contains "), ({__typeof__(_imp_string7) tmp; /*E*/ tmp = S(FAULTS); (void *)&tmp;})); (_imp_string255 *)&tmp;}), (_imp_string *)/*?*/_imp_str_literal_ptr(" fault")); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
// 870 printsymbol('s') %if faults > 1
if (FAULTS <= 1) goto L_00BB;
_imp_PRINTSYMBOL(115);
L_00BB:;
// 871 newline
_imp_NEWLINE();
// 872 selectoutput(st)
_imp_SELECTOUTPUT(ST);
// 873 %end
goto end_1000;
end_1000:;
}
// 874 %finish
L_00BC:;
// 875 newline
_imp_NEWLINE();
// 876 %if faults > 0 %then printstring("?" . strint(faults, 4)) %else printstring("*NO")
if (FAULTS <= 0) goto L_00BC;
_imp_PRINTSTRING(
/* clang-format off */
*({ __typeof__(_imp_string255) tmp = *({_imp_string255 tmp = _imp_join((_imp_string *)/*?*/_imp_str_literal_ptr("?"), ({__typeof__(_imp_string255) tmp; /*E*/ tmp = STRINT(FAULTS, 4); (void *)&tmp;})); (_imp_string255 *)&tmp;})/*q*/; (_imp_string255 *)&tmp; })
/* clang-format on */
);
goto L_00BD;
L_00BC:;
_imp_PRINTSTRING(_imp_str_literal("*NO"));
L_00BD:;
// 877 printstring(" FAULT")
_imp_PRINTSTRING(_imp_str_literal(" FAULT"));
// 878 printsymbol('S') %if faults # 1
if (FAULTS == 1) goto L_00BE;
_imp_PRINTSYMBOL(83);
L_00BE:;
// 879 printstring(" IN THIS PROGRAM
_imp_PRINTSTRING(_imp_str_literal(" IN THIS PROGRAM\n"));
// 880+ ")
// 881 %signal %event 13
_imp_signal(13, 0, 0, "");
// 882 ! Not again!!!
// 883 %end
return;
} /* end of ENDOFPROG */
// ?I unused
// 884 %end %of %file