From 0aa88da3010838451b05737645d87d24aee10bf2 Mon Sep 17 00:00:00 2001 From: Jeff Date: Thu, 23 Feb 2017 09:02:48 -0800 Subject: [PATCH 01/30] Updated information on PDP timings --- modules/pdp10/lib/cpu.js | 25 ------------------------- modules/pdp10/lib/cpustate.js | 12 +++++++++++- modules/pdp11/lib/cpu.js | 25 ------------------------- modules/pdp11/lib/cpustate.js | 25 +++++++++++++++++++++++-- 4 files changed, 34 insertions(+), 53 deletions(-) diff --git a/modules/pdp10/lib/cpu.js b/modules/pdp10/lib/cpu.js index 407662401..b8c9e6753 100644 --- a/modules/pdp10/lib/cpu.js +++ b/modules/pdp10/lib/cpu.js @@ -34,31 +34,6 @@ if (NODE) { var MessagesPDP10 = require("./messages"); } -/* - * A word (or more) about PDP-11 speeds: - * - * After looking over the timings of PDP-11/70 instructions, nearly all of them appear - * to be multiples of 150ns. So that's what we'll consider a cycle. How many 150ns are - * in one second? Approximately 6666667. So by way of comparison to other PCjs machines, - * that makes the PDP-11 (or at least the PDP-11/70) look like a 6.67Mhz machine. - * - * I've started with the PDP-11/70, since that's what Paul Nankervis started with. When - * I go back and add support for earlier PDP-11 models (primarily by neutering functions - * that didn't exist), I will no doubt have to tweak some instruction cycle counts, too. - * - * Examples of operations that take 1 extra cycle (150ns): single and double operand byte - * instructions with an odd address (except MOV/MTPI/MTPD/JMP/JRS), ADD/SUB/BIC/BIS/MOVB/CMP/BIT - * instructions with src of R1-R7 and dst of R6-R7, RORB/ASRB with an odd address, and each - * shift of ASH/ASHC. As you can see, the rules are not simple. - * - * We're not simulating cache hardware, but our timings should be optimistic and assume 100% - * cache hits; for cache hits, each read cycle is 300ns. As for write cycles, they are always - * 750ns. My initial take on DEC's timings is that they are including the write time as part - * of the total EF (execute/fetch) time. So, for instructions that write to memory, it looks - * like we'll normally need to add 5 cycles (750/150) to the instruction's base time, but - * we'll need to keep an eye out for exceptions. - */ - /** * @class CPUPDP10 * @unrestricted diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index b5bf1e8e3..44db31942 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -92,6 +92,16 @@ class CPUStatePDP10 extends CPUPDP10 { * constructor, along with a default speed (cycles per second) based on the specified (or default) * CPU model number. * + * Speeds are highly instruction-specific and are not broken down into cycles; DEC documents them + * as a number of microseconds, with two decimal places of accuracy. The simplest instructions + * execute in 1-3us, a number of others require 5-6us, and the most time-consuming take anywhere + * from 10us (MUL) to 17us (DIV). Of course, instructions that perform multiple indirect memory + * accesses take even longer. + * + * I think we'll just say that the original PDP-10 was roughly a 1Mhz machine, and pretend that all + * instructions completed in 1 or more multiples of a microsecond. I'm not sure that trying to be + * accurate to the nearest 1/100 of a microsecond would have much observable benefit. + * * @param {Object} parmsCPU */ constructor(parmsCPU) @@ -102,7 +112,7 @@ class CPUStatePDP10 extends CPUPDP10 { switch(model) { case PDP10.MODEL_KA10: default: - nCyclesDefault = 6666667; + nCyclesDefault = 1000000; break; } diff --git a/modules/pdp11/lib/cpu.js b/modules/pdp11/lib/cpu.js index a548a8c4c..fbd4a39e4 100644 --- a/modules/pdp11/lib/cpu.js +++ b/modules/pdp11/lib/cpu.js @@ -34,31 +34,6 @@ if (NODE) { var MessagesPDP11 = require("./messages"); } -/* - * A word (or more) about PDP-11 speeds: - * - * After looking over the timings of PDP-11/70 instructions, nearly all of them appear - * to be multiples of 150ns. So that's what we'll consider a cycle. How many 150ns are - * in one second? Approximately 6666667. So by way of comparison to other PCjs machines, - * that makes the PDP-11 (or at least the PDP-11/70) look like a 6.67Mhz machine. - * - * I've started with the PDP-11/70, since that's what Paul Nankervis started with. When - * I go back and add support for earlier PDP-11 models (primarily by neutering functions - * that didn't exist), I will no doubt have to tweak some instruction cycle counts, too. - * - * Examples of operations that take 1 extra cycle (150ns): single and double operand byte - * instructions with an odd address (except MOV/MTPI/MTPD/JMP/JRS), ADD/SUB/BIC/BIS/MOVB/CMP/BIT - * instructions with src of R1-R7 and dst of R6-R7, RORB/ASRB with an odd address, and each - * shift of ASH/ASHC. As you can see, the rules are not simple. - * - * We're not simulating cache hardware, but our timings should be optimistic and assume 100% - * cache hits; for cache hits, each read cycle is 300ns. As for write cycles, they are always - * 750ns. My initial take on DEC's timings is that they are including the write time as part - * of the total EF (execute/fetch) time. So, for instructions that write to memory, it looks - * like we'll normally need to add 5 cycles (750/150) to the instruction's base time, but - * we'll need to keep an eye out for exceptions. - */ - class CPUPDP11 extends Component { /** * CPUPDP11(parmsCPU, nCyclesDefault) diff --git a/modules/pdp11/lib/cpustate.js b/modules/pdp11/lib/cpustate.js index 067c50c83..a451ed3bb 100644 --- a/modules/pdp11/lib/cpustate.js +++ b/modules/pdp11/lib/cpustate.js @@ -88,8 +88,29 @@ class CPUStatePDP11 extends CPUPDP11 { * addrReset: reset address (default is 0) * * This extends the CPU class and passes any remaining parmsCPU properties to the CPU class - * constructor, along with a default speed (cycles per second) based on the specified (or default) - * CPU model number. + * constructor, along with a default speed (cycles per second) based on the specified + * (or default) CPU model number. + * + * After looking over the timings of PDP-11/70 instructions, nearly all of them appear + * to be multiples of 150ns. So that's what we'll consider a cycle. How many 150ns are + * in one second? Approximately 6666667. So by way of comparison to other PCjs machines, + * that makes the PDP-11 (or at least the PDP-11/70) look like a 6.67Mhz machine. + * + * I've started with the PDP-11/70, since that's what Paul Nankervis started with. When + * I go back and add support for earlier PDP-11 models (primarily by neutering functions + * that didn't exist), I will no doubt have to tweak some instruction cycle counts, too. + * + * Examples of operations that take 1 extra cycle (150ns): single and double operand byte + * instructions with an odd address (except MOV/MTPI/MTPD/JMP/JRS), ADD/SUB/BIC/BIS/MOVB/CMP/BIT + * instructions with src of R1-R7 and dst of R6-R7, RORB/ASRB with an odd address, and each + * shift of ASH/ASHC. As you can see, the rules are not simple. + * + * We're not simulating cache hardware, but our timings should be optimistic and assume 100% + * cache hits; for cache hits, each read cycle is 300ns. As for write cycles, they are always + * 750ns. My initial take on DEC's timings is that they are including the write time as part + * of the total EF (execute/fetch) time. So, for instructions that write to memory, it looks + * like we'll normally need to add 5 cycles (750/150) to the instruction's base time, but + * we'll need to keep an eye out for exceptions. * * @param {Object} parmsCPU */ From c25ad00c413673773aa124d5fa9ebab64224be55 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Thu, 23 Feb 2017 11:34:19 -0800 Subject: [PATCH 02/30] Minimal infrastructure for instantiating a PDP-10 test machine --- devices/pdp10/README.md | 14 +++++++++++ devices/pdp10/machine/README.md | 12 ++++++++++ devices/pdp10/machine/ka10/README.md | 12 ++++++++++ devices/pdp10/machine/ka10/test/README.md | 15 ++++++++++++ .../machine/ka10/test/debugger/README.md | 16 +++++++++++++ .../machine/ka10/test/debugger/machine.xml | 12 ++++++++++ devices/pdp10/machine/ka10/test/machine.xml | 11 +++++++++ devices/pdp10/panel/README.md | 10 ++++++++ devices/pdp10/panel/test/README.md | 10 ++++++++ devices/pdp10/panel/test/debugger/README.md | 10 ++++++++ .../pdp10/panel/test/debugger/terminal.xml | 23 +++++++++++++++++++ devices/pdp10/panel/test/terminal.xml | 17 ++++++++++++++ modules/htmlout/lib/htmlout.js | 4 +++- modules/pdp10/lib/defines.js | 12 ---------- modules/shared/lib/embed.js | 16 +++++++++++++ 15 files changed, 181 insertions(+), 13 deletions(-) create mode 100644 devices/pdp10/README.md create mode 100644 devices/pdp10/machine/README.md create mode 100644 devices/pdp10/machine/ka10/README.md create mode 100644 devices/pdp10/machine/ka10/test/README.md create mode 100644 devices/pdp10/machine/ka10/test/debugger/README.md create mode 100644 devices/pdp10/machine/ka10/test/debugger/machine.xml create mode 100644 devices/pdp10/machine/ka10/test/machine.xml create mode 100644 devices/pdp10/panel/README.md create mode 100644 devices/pdp10/panel/test/README.md create mode 100644 devices/pdp10/panel/test/debugger/README.md create mode 100644 devices/pdp10/panel/test/debugger/terminal.xml create mode 100644 devices/pdp10/panel/test/terminal.xml diff --git a/devices/pdp10/README.md b/devices/pdp10/README.md new file mode 100644 index 000000000..4a0fdc9f5 --- /dev/null +++ b/devices/pdp10/README.md @@ -0,0 +1,14 @@ +--- +layout: page +title: PDP-10 Device Configurations +permalink: /devices/pdp10/ +--- + +PDP-10 Device Configurations +---------------------------- + +[PDP-10 Machines](/devices/pdp10/machine/) rely on a variety of machine configuration files and resources, including: + +* [Control Panels](panel/) + +Test machines include a [PDP-10 (Model KA10) with Debugger](/devices/pdp11/machine/ka10/panel/debugger/). diff --git a/devices/pdp10/machine/README.md b/devices/pdp10/machine/README.md new file mode 100644 index 000000000..77a799cc5 --- /dev/null +++ b/devices/pdp10/machine/README.md @@ -0,0 +1,12 @@ +--- +layout: page +title: PDP-10 Machine Configurations +permalink: /devices/pdp10/machine/ +--- + +PDP-10 Machine Configurations +----------------------------- + +PDPjs supports the following PDP-10 machine configurations: + +* [PDP-10 Model KA10](/devices/pdp10/machine/ka10/) diff --git a/devices/pdp10/machine/ka10/README.md b/devices/pdp10/machine/ka10/README.md new file mode 100644 index 000000000..60e0c79b5 --- /dev/null +++ b/devices/pdp10/machine/ka10/README.md @@ -0,0 +1,12 @@ +--- +layout: page +title: PDP-10 (Model KA10) Machine Configurations +permalink: /devices/pdp10/machine/ka10/ +--- + +PDP-10 (Model KA10) Machine Configurations +------------------------------------------ + +PDPjs supports the following PDP-10 Model KA10 machine configurations: + +* [PDP-10 Model KA10 Test Machine](/devices/pdp10/machine/ka10/test/) (with [Debugger](/devices/pdp10/machine/ka10/test/debugger/)) diff --git a/devices/pdp10/machine/ka10/test/README.md b/devices/pdp10/machine/ka10/test/README.md new file mode 100644 index 000000000..afe4379af --- /dev/null +++ b/devices/pdp10/machine/ka10/test/README.md @@ -0,0 +1,15 @@ +--- +layout: page +title: PDP-10 (Model KA10) Test Machine +permalink: /devices/pdp10/machine/ka10/test/ +machines: + - id: ka10test + type: pdp10 +--- + +PDP-10 Test Machine +------------------- + +A PDP-10 (Model KA10) is simulated below. + +{% include machine.html id="ka10test" %} diff --git a/devices/pdp10/machine/ka10/test/debugger/README.md b/devices/pdp10/machine/ka10/test/debugger/README.md new file mode 100644 index 000000000..acc87c29c --- /dev/null +++ b/devices/pdp10/machine/ka10/test/debugger/README.md @@ -0,0 +1,16 @@ +--- +layout: page +title: PDP-10 (Model KA10) Test Machine with Debugger +permalink: /devices/pdp10/machine/ka10/test/debugger/ +machines: + - id: ka10test + type: pdp10 + debugger: true +--- + +PDP-10 Test Machine with Debugger +--------------------------------- + +A PDP-10 (Model KA10) is simulated below. + +{% include machine.html id="ka10test" %} diff --git a/devices/pdp10/machine/ka10/test/debugger/machine.xml b/devices/pdp10/machine/ka10/test/debugger/machine.xml new file mode 100644 index 000000000..470a11fec --- /dev/null +++ b/devices/pdp10/machine/ka10/test/debugger/machine.xml @@ -0,0 +1,12 @@ + + + + PDP-10 Test Machine with Debugger + + + + + + + + diff --git a/devices/pdp10/machine/ka10/test/machine.xml b/devices/pdp10/machine/ka10/test/machine.xml new file mode 100644 index 000000000..2a951bf8d --- /dev/null +++ b/devices/pdp10/machine/ka10/test/machine.xml @@ -0,0 +1,11 @@ + + + + PDP-10 Test Machine + + + + + + + diff --git a/devices/pdp10/panel/README.md b/devices/pdp10/panel/README.md new file mode 100644 index 000000000..b6cea17fc --- /dev/null +++ b/devices/pdp10/panel/README.md @@ -0,0 +1,10 @@ +--- +layout: page +title: PDP-10 Control Panels +permalink: /devices/pdp11/panel/ +--- + +PDP-10 Control Panels +--------------------- + +* [Terminal Test Panels](test/) diff --git a/devices/pdp10/panel/test/README.md b/devices/pdp10/panel/test/README.md new file mode 100644 index 000000000..ed5fee625 --- /dev/null +++ b/devices/pdp10/panel/test/README.md @@ -0,0 +1,10 @@ +--- +layout: page +title: PDP-10 Test Panels +permalink: /devices/pdp10/panel/test/ +--- + +PDP-10 Test Panels +------------------ + +* [Terminal Test Panel](terminal.xml) (with [Debugger](debugger/terminal.xml)) diff --git a/devices/pdp10/panel/test/debugger/README.md b/devices/pdp10/panel/test/debugger/README.md new file mode 100644 index 000000000..a13c0ad2a --- /dev/null +++ b/devices/pdp10/panel/test/debugger/README.md @@ -0,0 +1,10 @@ +--- +layout: page +title: PDP-10 Test Panel with Debugger +permalink: /devices/pdp10/panel/test/debugger/ +--- + +PDP-10 Test Panel with Debugger +------------------------------- + +* [Terminal Test Panel with Debugger](terminal.xml) diff --git a/devices/pdp10/panel/test/debugger/terminal.xml b/devices/pdp10/panel/test/debugger/terminal.xml new file mode 100644 index 000000000..1bd1dae7b --- /dev/null +++ b/devices/pdp10/panel/test/debugger/terminal.xml @@ -0,0 +1,23 @@ + + + Control Panel + + + + + Enter + Clear + + + + Registers + 000000 + + + Run + Step + Reset + Fast + Stopped + + diff --git a/devices/pdp10/panel/test/terminal.xml b/devices/pdp10/panel/test/terminal.xml new file mode 100644 index 000000000..2439fcde5 --- /dev/null +++ b/devices/pdp10/panel/test/terminal.xml @@ -0,0 +1,17 @@ + + + Control Panel + + + + + Registers + 000000 + + + Run + Reset + Fast + Stopped + + diff --git a/modules/htmlout/lib/htmlout.js b/modules/htmlout/lib/htmlout.js index 694974570..9c79e296b 100644 --- a/modules/htmlout/lib/htmlout.js +++ b/modules/htmlout/lib/htmlout.js @@ -54,6 +54,7 @@ var usr = require("../../shared/lib/usrlib"); * @property {Array.} pcCSSFiles * @property {Array.} pcX86Files * @property {Array.} pc8080Files + * @property {Array.} pdp10Files * @property {Array.} pdp11Files */ var pkg = require("../../../package.json"); @@ -169,6 +170,7 @@ var aMachineFiles = { 'PC': pkg.pcCSSFiles.concat(pkg.pcX86Files), // deprecated (same as PCx86) 'PCx86': pkg.pcCSSFiles.concat(pkg.pcX86Files), 'PC8080': pkg.pcCSSFiles.concat(pkg.pc8080Files), + 'PDP10': pkg.pcCSSFiles.concat(pkg.pdp10Files), 'PDP11': pkg.pcCSSFiles.concat(pkg.pdp11Files) }; var aMachineFileTypes = { @@ -1872,7 +1874,7 @@ HTMLOut.prototype.getRandomString = function(sIndent) * * At a minimum, each machine object should contain the following properties: * - * 'type' (eg, a machine type, such as "C1P", "PCx86", "PC8080", or "PDP11") + * 'type' (eg, a machine type, such as "C1P", "PCx86", "PC8080", "PDP10", or "PDP11") * 'version' (eg, "1.10", "*" to select the current version, or "uncompiled"; "*" is the default) * 'debugger' (eg, true or false; false is the default) * diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 2560419e3..3c4749612 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -75,18 +75,6 @@ var PDP10 = { /* * CPU model numbers (supported) - * - * The 11/20 includes the 11/10, which is not identified separately because there was - * nothing functionally different about it. - * - * The 11/40 added the MODE bits to the PSW (but only KERNEL=00 and USER=11) and 18-bit - * addressing via an MMU; there was still only one register set. - * - * The 11/45 added REGSET bit to the PSW (to support a second register set), SUPER=01 - * mode to the existing KERNEL=00 and USER=11 modes, separate I/D spaces, and other MMU - * extensions (eg, MMR1 and MMR3). - * - * The 11/70 added 22-bit addressing and corresponding extensions to the MMU. */ MODEL_KA10: 1001, diff --git a/modules/shared/lib/embed.js b/modules/shared/lib/embed.js index 65ac2e2cd..4a0f930c7 100644 --- a/modules/shared/lib/embed.js +++ b/modules/shared/lib/embed.js @@ -579,6 +579,21 @@ function embedPC8080(idMachine, sXMLFile, sXSLFile, sParms) return embedMachine("PC8080", "pc8080", APPVERSION, idMachine, sXMLFile, sXSLFile, sParms); } +/** + * embedPDP10(idMachine, sXMLFile, sXSLFile, sParms) + * + * @param {string} idMachine + * @param {string} sXMLFile + * @param {string} sXSLFile + * @param {string} [sParms] + * @return {boolean} true if successful, false if error + */ +function embedPDP10(idMachine, sXMLFile, sXSLFile, sParms) +{ + if (fAsync) Web.enablePageEvents(false); + return embedMachine("PDPjs", "pdp10", APPVERSION, idMachine, sXMLFile, sXSLFile, sParms); +} + /** * embedPDP11(idMachine, sXMLFile, sXSLFile, sParms) * @@ -635,6 +650,7 @@ if (APPNAME == "PC8080") { window['embedPC8080'] = embedPC8080; } if (APPNAME == "PDPjs") { + window['embedPDP10'] = embedPDP10; window['embedPDP11'] = embedPDP11; } From 8320f58d44b9c527864294206c112c76adf3a115 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Thu, 23 Feb 2017 15:14:51 -0800 Subject: [PATCH 03/30] Documentation updates to accommodate the PDP-10 work that's starting now --- README.md | 4 +- devices/pdp10/machine/README.md | 2 + devices/pdp10/machine/ka10/README.md | 2 + devices/pdp10/machine/ka10/test/README.md | 2 + .../machine/ka10/test/debugger/README.md | 2 + docs/pdpjs/README.md | 27 +++++++ modules/README.md | 2 +- modules/pdp10/README.md | 30 +++++++ modules/pdp10/lib/bus.js | 43 ++++++++++ modules/pdp10/lib/debugger.js | 4 +- modules/pdp10/lib/defines.js | 5 +- modules/pdp10/lib/memory.js | 81 +++++++------------ modules/pdp11/README.md | 11 +-- modules/pdp11/lib/memory.js | 2 +- pubs/dec/README.md | 1 + pubs/dec/pdp10/README.md | 14 ++++ versions/c1pjs/README.md | 2 +- versions/pc8080/README.md | 2 +- versions/pcx86/README.md | 2 +- versions/pdpjs/README.md | 3 +- 20 files changed, 172 insertions(+), 69 deletions(-) create mode 100644 docs/pdpjs/README.md create mode 100644 modules/pdp10/README.md create mode 100644 pubs/dec/pdp10/README.md diff --git a/README.md b/README.md index 4e83502ba..4374aa725 100644 --- a/README.md +++ b/README.md @@ -5,10 +5,10 @@ Welcome to PCjs, home of [PCx86](/docs/pcx86/), the original IBM PC simulation t one of several JavaScript Machines in the [PCjs Project](https://github.com/jeffpar/pcjs), an open-source project that includes: -* [PCx86](/docs/pcx86/), an x86-based emulator of [IBM PC and PC-compatible Machines](/devices/pcx86/machine/) +* [PCx86](/docs/pcx86/), an x86-based emulator of [IBM PC and PC-compatible](/devices/pcx86/machine/) machines * [PC8080](/modules/pc8080/), an 8080 machine emulator (e.g., [Space Invaders](/devices/pc8080/machine/invaders/) and the [VT100 Terminal](/devices/pc8080/machine/vt100/)) * [C1Pjs](/docs/c1pjs/), an emulation of the 6502-based [Ohio Scientific Challenger 1P](/devices/c1p/) -* [PDPjs](/modules/pdp11/), a [PDP-11 Machine](/devices/pdp11/machine/) emulator that supports the [PDP-11/20](/devices/pdp11/machine/1120/), [PDP-11/45](/devices/pdp11/machine/1145/), and [PDP-11/70](/devices/pdp11/machine/1170/) +* [PDPjs](/docs/pdpjs/) emulators, with support for [PDP-10](/devices/pdp10/machine/) and [PDP-11](/devices/pdp11/machine/) machines All PCjs machine simulations are written entirely in [JavaScript](/modules/). No Flash, Java or other plugins are required. Supported browsers include modern versions of Chrome, Safari, Firefox, Internet Explorer (v9.0 and up), Edge, diff --git a/devices/pdp10/machine/README.md b/devices/pdp10/machine/README.md index 77a799cc5..cc99127e5 100644 --- a/devices/pdp10/machine/README.md +++ b/devices/pdp10/machine/README.md @@ -10,3 +10,5 @@ PDP-10 Machine Configurations PDPjs supports the following PDP-10 machine configurations: * [PDP-10 Model KA10](/devices/pdp10/machine/ka10/) + +**WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. diff --git a/devices/pdp10/machine/ka10/README.md b/devices/pdp10/machine/ka10/README.md index 60e0c79b5..aaeb0d9c4 100644 --- a/devices/pdp10/machine/ka10/README.md +++ b/devices/pdp10/machine/ka10/README.md @@ -10,3 +10,5 @@ PDP-10 (Model KA10) Machine Configurations PDPjs supports the following PDP-10 Model KA10 machine configurations: * [PDP-10 Model KA10 Test Machine](/devices/pdp10/machine/ka10/test/) (with [Debugger](/devices/pdp10/machine/ka10/test/debugger/)) + +**WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. diff --git a/devices/pdp10/machine/ka10/test/README.md b/devices/pdp10/machine/ka10/test/README.md index afe4379af..bccf4f095 100644 --- a/devices/pdp10/machine/ka10/test/README.md +++ b/devices/pdp10/machine/ka10/test/README.md @@ -12,4 +12,6 @@ PDP-10 Test Machine A PDP-10 (Model KA10) is simulated below. +**WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. + {% include machine.html id="ka10test" %} diff --git a/devices/pdp10/machine/ka10/test/debugger/README.md b/devices/pdp10/machine/ka10/test/debugger/README.md index acc87c29c..ad8b6c6ea 100644 --- a/devices/pdp10/machine/ka10/test/debugger/README.md +++ b/devices/pdp10/machine/ka10/test/debugger/README.md @@ -13,4 +13,6 @@ PDP-10 Test Machine with Debugger A PDP-10 (Model KA10) is simulated below. +**WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. + {% include machine.html id="ka10test" %} diff --git a/docs/pdpjs/README.md b/docs/pdpjs/README.md new file mode 100644 index 000000000..193277c3d --- /dev/null +++ b/docs/pdpjs/README.md @@ -0,0 +1,27 @@ +--- +layout: page +title: PDPjs Overview +permalink: /docs/pdpjs/ +--- + +PDPjs Overview +--- + +PDPjs is a collection of JavaScript modules used to simulate an assortment of classic DEC computers. + +It currently includes the following hardware emulation modules: + +* [PDP-10 Module](/modules/pdp10/) +* [PDP-11 Module](/modules/pdp11/) + +Related hardware and software documentation has also been archived here: + +* [PDP-10 Documentation](/pubs/dec/pdp10/) +* [PDP-11 Documentation](/pubs/dec/pdp11/) + +Explore our collection of pre-configured machine simulations: + +* [PDP-10 Machines](/devices/pdp10/machine/) +* [PDP-11 Machines](/devices/pdp11/machine/) + +More information about creating custom PDP-10 and PDP-11 machine simulations will be provided at a later date. diff --git a/modules/README.md b/modules/README.md index fa354efbe..04fa5c930 100644 --- a/modules/README.md +++ b/modules/README.md @@ -15,7 +15,7 @@ The project currently includes these emulation modules: * [C1Pjs](c1pjs/): 6502 emulation module for the [Challenger 1P](/devices/c1p/) * [PCx86](pcx86/): x86 emulation module for [IBM PC machines](/devices/pcx86/) * [PC8080](pc8080/): 8080 emulation module for [8080-based machines](/devices/pc8080/) -* [PDPjs](pdp11/): PDP-11 emulation module for [PDP-11 machines](/devices/pdp11/) (eg, PDP-11/20, PDP-11/70) +* [PDPjs](/docs/pdpjs/): emulation modules for [PDP-10](pdp10/) and [PDP-11](pdp11/) machines along with variety of Node support modules, such as: diff --git a/modules/pdp10/README.md b/modules/pdp10/README.md new file mode 100644 index 000000000..f451d98c4 --- /dev/null +++ b/modules/pdp10/README.md @@ -0,0 +1,30 @@ +--- +layout: page +title: PDPjs Support for PDP-10 Machines +permalink: /modules/pdp10/ +--- + +PDPjs Support for PDP-10 Machines +================================= + +Overview +--- + +This PDPjs module for [PDP-10 Machines](/devices/pdp10/machine/) was added to the PCjs Project in 2017. + +The module is currently comprised of the following components, as listed in [package.json](../../package.json) +(see the *pdp10Files* property): + +* [bus.js](/modules/pdp10/lib/bus.js) +* [computer.js](/modules/pdp10/lib/computer.js) +* [cpu.js](/modules/pdp10/lib/cpu.js) +* [cpustate.js](/modules/pdp10/lib/cpustate.js) +* [debugger.js](/modules/pdp10/lib/debugger.js) +* [defines.js](/modules/pdp10/lib/defines.js) +* [device.js](/modules/pdp10/lib/device.js) +* [memory.js](/modules/pdp10/lib/memory.js) +* [messages.js](/modules/pdp10/lib/messages.js) +* [panel.js](/modules/pdp10/lib/panel.js) +* [ram.js](/modules/pdp10/lib/ram.js) +* [rom.js](/modules/pdp10/lib/rom.js) +* [serial.js](/modules/pdp10/lib/serial.js) diff --git a/modules/pdp10/lib/bus.js b/modules/pdp10/lib/bus.js index b27033749..2f2b9fedb 100644 --- a/modules/pdp10/lib/bus.js +++ b/modules/pdp10/lib/bus.js @@ -119,6 +119,9 @@ class BusPDP10 extends Component { this.nBlockMask = this.nBlockTotal - 1; this.assert(this.nBlockMask <= BlockInfoPDP10.num.mask); + this.nDisableFaults = 0; + this.fFault = false; + /* * Define all the properties to be initialized by initMemory() */ @@ -524,7 +527,9 @@ class BusPDP10 extends Component { var w; var off = addr & this.nBlockLimit; var block = this.getBlockDirect(addr); + this.nDisableFaults++; w = block.readWordDirect(off, addr); + this.nDisableFaults--; return w; } @@ -541,7 +546,9 @@ class BusPDP10 extends Component { { var off = addr & this.nBlockLimit; var block = this.getBlockDirect(addr); + this.nDisableFaults++; block.writeWordDirect(off, w & 0xffff, addr); + this.nDisableFaults--; } /** @@ -683,6 +690,42 @@ class BusPDP10 extends Component { return addr; } + /** + * fault(addr, err, access) + * + * Bus interface for signaling alignment errors, invalid memory, etc. + * + * @this {BusPDP10} + * @param {number} addr + * @param {number} [err] + * @param {number} [access] (for diagnostic purposes only) + */ + fault(addr, err, access) + { + this.fFault = true; + if (!this.nDisableFaults) { + if (DEBUGGER && this.dbg && this.dbg.messageEnabled(MessagesPDP10.FAULT)) { + this.dbg.printMessage("memory fault on " + this.dbg.toStrBase(addr), true, true); + this.dbg.stopCPU(); + } + } + } + + /** + * checkFault() + * + * This also serves as a clearFault() function. + * + * @this {BusPDP10} + * @return {boolean} + */ + checkFault() + { + var f = this.fFault; + this.fFault = false; + return f; + } + /** * reportError(errNum, addr, size, fQuiet) * diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 7d04e1a7d..478ab9cdf 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -757,7 +757,7 @@ class DebuggerPDP10 extends Debugger { messageInit(sEnable) { this.dbg = this; - this.bitsMessage = this.bitsWarning = MessagesPDP10.WARN; + this.bitsMessage = this.bitsWarning = MessagesPDP10.FAULT | MessagesPDP10.WARN; this.sMessagePrev = null; this.aMessageBuffer = []; /* @@ -1311,7 +1311,7 @@ class DebuggerPDP10 extends Debugger { */ if (!nState) { opCode = this.cpu.readWord(addr); - if (opCode == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { + if ((opCode & PDP10.OPCODE.HALTMASK) == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { addr = this.cpu.advancePC(1); } } diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 3c4749612..a44b303a4 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -103,7 +103,10 @@ var PDP10 = { * Assorted common opcodes */ OPCODE: { - HALT: 0o000000000000, // TODO: Resolve + INSMASK: 0o777000000000, + ACCMASK: 0o000740000000, + HALTMASK: 0o777740000000, + HALT: 0o254200000000, INVALID: 0o777777777777 // TODO: Resolve }, /* diff --git a/modules/pdp10/lib/memory.js b/modules/pdp10/lib/memory.js index 96d7b05f3..6ae06cba9 100644 --- a/modules/pdp10/lib/memory.js +++ b/modules/pdp10/lib/memory.js @@ -84,9 +84,9 @@ class MemoryPDP10 { this.fReadOnly = (type == MemoryPDP10.TYPE.ROM); this.dbg = null; this.readBits = this.readBitsDirect = this.readNone; - this.readWord = this.readWordDirect = this.readWordDefault; + this.readWord = this.readWordDirect = this.readNone; this.writeBits = this.writeBitsDirect = this.writeNone; - this.writeWord = this.writeWordDirect = this.writeWordDefault; + this.writeWord = this.writeWordDirect = this.writeNone; this.cReadBreakpoints = this.cWriteBreakpoints = 0; this.copyBreakpoints(); // initialize the block's Debugger info; the caller will reinitialize @@ -261,11 +261,11 @@ class MemoryPDP10 { { if (!fDirect || !this.cReadBreakpoints) { this.readBits = afn[0] || this.readNone; - this.readWord = afn[2] || this.readWordDefault; + this.readWord = afn[2] || this.readNone; } if (fDirect || fDirect === undefined) { this.readBitsDirect = afn[0] || this.readNone; - this.readWordDirect = afn[2] || this.readWordDefault; + this.readWordDirect = afn[2] || this.readNone; } } @@ -280,11 +280,11 @@ class MemoryPDP10 { { if (!fDirect || !this.cWriteBreakpoints) { this.writeBits = !this.fReadOnly && afn[1] || this.writeNone; - this.writeWord = !this.fReadOnly && afn[3] || this.writeWordDefault; + this.writeWord = !this.fReadOnly && afn[3] || this.writeNone; } if (fDirect || fDirect === undefined) { this.writeBitsDirect = afn[1] || this.writeNone; - this.writeWordDirect = afn[3] || this.writeWordDefault; + this.writeWordDirect = afn[3] || this.writeNone; } } @@ -307,7 +307,7 @@ class MemoryPDP10 { resetWriteAccess() { this.writeBits = this.fReadOnly? this.writeNone : this.writeBitsDirect; - this.writeWord = this.fReadOnly? this.writeWordDefault : this.writeWordDirect; + this.writeWord = this.fReadOnly? this.writeNone : this.writeWordDirect; } /** @@ -393,7 +393,7 @@ class MemoryPDP10 { } /** - * readNone(off) + * readNone(off, addr) * * @this {MemoryPDP10} * @param {number} off @@ -405,6 +405,7 @@ class MemoryPDP10 { if (DEBUGGER && this.dbg && this.dbg.messageEnabled(MessagesPDP10.MEMORY) /* && !off */) { this.dbg.printMessage("attempt to read invalid address " + this.dbg.toStrBase(addr), true); } + this.bus.fault(addr); return 0; } @@ -424,42 +425,16 @@ class MemoryPDP10 { } /** - * readWordDefault(off, addr) + * readBitsMemory(off, addr, offBits, lenBits) * * @this {MemoryPDP10} * @param {number} off * @param {number} addr - * @return {number} - */ - readWordDefault(off, addr) - { - return this.readWord(off, addr); - } - - /** - * writeWordDefault(w, off, addr) - * - * @this {MemoryPDP10} - * @param {number} w - * @param {number} off - * @param {number} addr - */ - writeWordDefault(w, off, addr) - { - this.writeWord(w, off, addr); - } - - /** - * readBitsMemory(offBits, lenBits, off, addr) - * - * @this {MemoryPDP10} * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) * @param {number} lenBits - * @param {number} off - * @param {number} addr * @return {number} */ - readBitsMemory(offBits, lenBits, off, addr) + readBitsMemory(off, addr, offBits, lenBits) { var w = this.aw[off]; if (offBits + lenBits <= 32) { @@ -484,16 +459,16 @@ class MemoryPDP10 { } /** - * writeBitsMemory(offBits, lenBits, bits, off, addr) + * writeBitsMemory(bits, off, addr, offBits, lenBits) * * @this {MemoryPDP10} - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits - * @param {number} bits (only the right-most lenBits of bits are used, so this value doesn't need to be pre-masked) + * @param {number} bits (only the right-most lenBits of bits are used, so it doesn't need to be pre-masked) * @param {number} off * @param {number} addr + * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) + * @param {number} lenBits */ - writeBitsMemory(offBits, lenBits, bits, off, addr) + writeBitsMemory(bits, off, addr, offBits, lenBits) { var w = this.aw[off]; var shiftBits = Math.pow(2, offBits); @@ -521,21 +496,21 @@ class MemoryPDP10 { } /** - * readBitsChecked(offBits, lenBits, off, addr) + * readBitsChecked(off, addr, offBits, lenBits) * * @this {MemoryPDP10} - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits * @param {number} off * @param {number} addr + * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) + * @param {number} lenBits * @return {number} */ - readBitsChecked(offBits, lenBits, off, addr) + readBitsChecked(off, addr, offBits, lenBits) { if (DEBUGGER && this.dbg && this.addr != null) { this.dbg.checkMemoryRead(this.addr + off); } - return this.readBitsDirect(offBits, lenBits, off, addr); + return this.readBitsDirect(off, addr, offBits, lenBits); } /** @@ -555,21 +530,21 @@ class MemoryPDP10 { } /** - * writeBitsChecked(offBits, lenBits, bits, off, addr) + * writeBitsChecked(bits, off, addr, offBits, lenBits) * * @this {MemoryPDP10} - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits * @param {number} bits * @param {number} off * @param {number} addr + * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) + * @param {number} lenBits */ - writeBitsChecked(offBits, lenBits, bits, off, addr) + writeBitsChecked(bits, off, addr, offBits, lenBits) { if (DEBUGGER && this.dbg && this.addr != null) { this.dbg.checkMemoryWrite(this.addr + off); } - if (this.fReadOnly) this.writeNone(bits, off, addr); else this.writeBitsDirect(offBits, lenBits, bits, off, addr); + if (this.fReadOnly) this.writeNone(bits, off, addr); else this.writeBitsDirect(bits, off, addr, offBits, lenBits); } /** @@ -617,8 +592,8 @@ MemoryPDP10.idBlock = 0; MemoryPDP10.afnNone = [ MemoryPDP10.prototype.readNone, MemoryPDP10.prototype.writeNone, - MemoryPDP10.prototype.readWordDefault, - MemoryPDP10.prototype.writeWordDefault + MemoryPDP10.prototype.readNone, + MemoryPDP10.prototype.writeNone ]; */ MemoryPDP10.afnNone = []; diff --git a/modules/pdp11/README.md b/modules/pdp11/README.md index 4f17c84a3..03e7449fd 100644 --- a/modules/pdp11/README.md +++ b/modules/pdp11/README.md @@ -1,20 +1,21 @@ --- layout: page -title: PDP-11 Machine Emulation Module (PDPjs) +title: PDPjs Support for PDP-11 Machines permalink: /modules/pdp11/ --- -PDP-11 Machine Emulation Module (PDPjs) -======================================= +PDPjs Support for PDP-11 Machines +================================= Overview --- -PDPjs, our [PDP-11 Machine](/devices/pdp11/machine/) emulation module, was added to the PCjs Project in 2016. + +This PDPjs module for [PDP-11 Machines](/devices/pdp11/machine/) was added to the PCjs Project in 2016. It was adapted from the [PDP-11/70 Emulator](http://skn.noip.me/pdp11/pdp11.html) written by Paul Nankervis, with permission. -PDPjs is currently comprised of the following PDP-11 components, as listed in [package.json](../../package.json) +The module is currently comprised of the following components, as listed in [package.json](../../package.json) (see the *pdp11Files* property): * [bus.js](/modules/pdp11/lib/bus.js) diff --git a/modules/pdp11/lib/memory.js b/modules/pdp11/lib/memory.js index 37d4eef08..4198cb870 100644 --- a/modules/pdp11/lib/memory.js +++ b/modules/pdp11/lib/memory.js @@ -534,7 +534,7 @@ class MemoryPDP11 { } /** - * readNone(off) + * readNone(off, addr) * * Previously, this always returned 0x00, but the initial memory probe by the COMPAQ DeskPro 386 ROM BIOS * writes 0x0000 to the first word of every 64Kb block in the nearly 16Mb address space it supports, and diff --git a/pubs/dec/README.md b/pubs/dec/README.md index ff17db28c..d8f024e9c 100644 --- a/pubs/dec/README.md +++ b/pubs/dec/README.md @@ -7,5 +7,6 @@ permalink: /pubs/dec/ Digital Equipment Corporation (DEC) Publications ------------------------------------------------ +* [PDP-10](pdp10/) * [PDP-11](pdp11/) * [VT100](vt100/) diff --git a/pubs/dec/pdp10/README.md b/pubs/dec/pdp10/README.md new file mode 100644 index 000000000..9b7bbcedc --- /dev/null +++ b/pubs/dec/pdp10/README.md @@ -0,0 +1,14 @@ +--- +layout: page +title: DEC PDP-10 Publications and Papers +permalink: /pubs/dec/pdp10/ +--- + +PDP-10 Hardware Publications +--- + +This page summarizes PDP-10 documentation that was useful in creating [PDPjs](/docs/pdpjs/). In most cases, +these documents came from the PDF Document Archive at [bitsavers.org](http://bitsavers.org), in the [/pdf/dec/pdp10/](http://bitsavers.org/pdf/dec/pdp10/) +directory. If a PDF was not searchable, it was "OCR'ed" before being archived below. + +- [PDP-10 System Reference Manual (1968)](http://archive.pcjs.org/pubs/dec/pdp10/ka10/DEC-10-HGAA-D_PDP-10_System_Reference_Manual_May1968.pdf) [[Original PDF](http://bitsavers.trailing-edge.com/pdf/dec/pdp10/KA10/DEC-10-HGAA-D_PDP-10_System_Reference_Manual_May1968.pdf)] diff --git a/versions/c1pjs/README.md b/versions/c1pjs/README.md index ec44ef4e6..c1303d308 100644 --- a/versions/c1pjs/README.md +++ b/versions/c1pjs/README.md @@ -7,4 +7,4 @@ permalink: /versions/c1pjs/ C1Pjs Emulator Releases --- -The current version of C1Pjs is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/c1p.js). +The current C1Pjs emulator version is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/c1p.js). diff --git a/versions/pc8080/README.md b/versions/pc8080/README.md index aef6f615c..cb5ac3b35 100644 --- a/versions/pc8080/README.md +++ b/versions/pc8080/README.md @@ -7,4 +7,4 @@ permalink: /versions/pc8080/ PC8080 Emulator Releases --- -The current version of PC8080 is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pc8080.js). +The current PC8080 emulator version is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pc8080.js). diff --git a/versions/pcx86/README.md b/versions/pcx86/README.md index 85d19010c..703cc7159 100644 --- a/versions/pcx86/README.md +++ b/versions/pcx86/README.md @@ -7,4 +7,4 @@ permalink: /versions/pcx86/ PCx86 Emulator Releases --- -The current version of PCx86 is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pcx86.js). +The current PCx86 emulator version is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pcx86.js). diff --git a/versions/pdpjs/README.md b/versions/pdpjs/README.md index 499fe5f04..442ede41a 100644 --- a/versions/pdpjs/README.md +++ b/versions/pdpjs/README.md @@ -7,4 +7,5 @@ permalink: /versions/pdpjs/ PDPjs Emulator Releases --- -The current version of the PDPjs PDP-11 emulator is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pdp11.js). +* The current [PDP-10](/devices/pdp10/machine/) emulator version is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pdp10.js) +* The current [PDP-11](/devices/pdp11/machine/) emulator version is [{{ site.pcjs.version }}]({{ site.pcjs.version }}/pdp11.js) From 884b74d96f8ca2210d62c3d3b3390e9d8a371252 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Thu, 23 Feb 2017 16:56:08 -0800 Subject: [PATCH 04/30] Cleaned up PDP register dump code --- README.md | 2 +- modules/pdp10/lib/debugger.js | 10 +- modules/pdp11/lib/debugger.js | 71 +--- versions/pdpjs/1.34.0/pdp10-dbg.js | 306 ++++++++-------- versions/pdpjs/1.34.0/pdp10.js | 190 +++++----- versions/pdpjs/1.34.0/pdp11-dbg.js | 541 ++++++++++++++--------------- versions/pdpjs/1.34.0/pdp11.js | 70 ++-- 7 files changed, 574 insertions(+), 616 deletions(-) diff --git a/README.md b/README.md index 4374aa725..219c2274b 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ includes: * [PCx86](/docs/pcx86/), an x86-based emulator of [IBM PC and PC-compatible](/devices/pcx86/machine/) machines * [PC8080](/modules/pc8080/), an 8080 machine emulator (e.g., [Space Invaders](/devices/pc8080/machine/invaders/) and the [VT100 Terminal](/devices/pc8080/machine/vt100/)) * [C1Pjs](/docs/c1pjs/), an emulation of the 6502-based [Ohio Scientific Challenger 1P](/devices/c1p/) -* [PDPjs](/docs/pdpjs/) emulators, with support for [PDP-10](/devices/pdp10/machine/) and [PDP-11](/devices/pdp11/machine/) machines +* [PDPjs](/docs/pdpjs/), a set of emulation modules supporting [PDP-10](/devices/pdp10/machine/) and [PDP-11](/devices/pdp11/machine/) machines All PCjs machine simulations are written entirely in [JavaScript](/modules/). No Flash, Java or other plugins are required. Supported browsers include modern versions of Chrome, Safari, Firefox, Internet Explorer (v9.0 and up), Edge, diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 478ab9cdf..173457c11 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -812,11 +812,11 @@ class DebuggerPDP10 extends Debugger { * * @this {DebuggerPDP10} * @param {number} iReg (0-7; not used for other registers) - * @return {string|undefined} + * @return {string} */ getRegName(iReg) { - return DebuggerPDP10.REGNAMES[iReg]; + return DebuggerPDP10.REGNAMES[iReg] || ""; } /** @@ -1885,8 +1885,10 @@ class DebuggerPDP10 extends Debugger { */ getRegOutput(iReg) { - var sReg = this.getRegName(iReg) || "undefined"; - if (sReg) sReg += ' '; + var sReg = this.getRegName(iReg); + if (sReg) { + sReg += '=' + this.toStrBase(this.getRegValue(iReg)) + ' '; + } return sReg; } diff --git a/modules/pdp11/lib/debugger.js b/modules/pdp11/lib/debugger.js index d11d53b56..468738cb9 100644 --- a/modules/pdp11/lib/debugger.js +++ b/modules/pdp11/lib/debugger.js @@ -912,7 +912,9 @@ class DebuggerPDP11 extends Debugger { */ getRegName(iReg) { - return (iReg < 6? ("R" + iReg) : (iReg == 6? "SP" : "PC")); + var sReg; + if (iReg < DebuggerPDP11.REG_AR || this.panel) sReg = DebuggerPDP11.REGNAMES[iReg]; + return sReg || ""; } /** @@ -2273,63 +2275,10 @@ class DebuggerPDP11 extends Debugger { */ getRegOutput(iReg) { - var sReg = ""; - var cpu = this.cpu; - - if (iReg < 8) { - sReg = this.getRegName(iReg); - sReg += '=' + this.toStrBase(cpu.regsGen[iReg]); + var sReg = this.getRegName(iReg); + if (sReg) { + sReg += '=' + this.toStrBase(this.getRegValue(iReg)) + ' '; } - else if (iReg < 13) { - sReg = "A" + (iReg - 8) + '=' + this.toStrBase(cpu.regsAlt[iReg - 8]); - } - else if (iReg >= 16 && iReg < 20) { - sReg = "S" + (iReg - 16) + '=' + this.toStrBase(cpu.regsAltStack[iReg - 16]); - } - else { - switch(iReg) { - case DebuggerPDP11.REG_PS: - sReg = "PS=" + this.toStrBase(cpu.getPSW()); - break; - case DebuggerPDP11.REG_PI: - sReg = "PI=" + this.toStrBase(cpu.getPIR()); - break; - case DebuggerPDP11.REG_ER: - sReg = "ER=" + this.toStrBase(cpu.regErr); - break; - case DebuggerPDP11.REG_SL: - sReg = "SL=" + this.toStrBase(cpu.getSLR()); - break; - case DebuggerPDP11.REG_M0: - sReg = "M0=" + this.toStrBase(cpu.getMMR0()); - break; - case DebuggerPDP11.REG_M1: - sReg = "M1=" + this.toStrBase(cpu.getMMR1()); - break; - case DebuggerPDP11.REG_M2: - sReg = "M2=" + this.toStrBase(cpu.getMMR2()); - break; - case DebuggerPDP11.REG_M3: - sReg = "M3=" + this.toStrBase(cpu.getMMR3()); - break; - case DebuggerPDP11.REG_AR: - if (this.panel) { - sReg = "AR=" + this.toStrBase(this.panel.getAR(), 3); - } - break; - case DebuggerPDP11.REG_DR: - if (this.panel) { - sReg = "DR=" + this.toStrBase(this.panel.getDR()); - } - break; - case DebuggerPDP11.REG_SR: - if (this.panel) { - sReg = "SR=" + this.toStrBase(this.panel.getSR(), 3); - } - break; - } - } - if (sReg) sReg += ' '; return sReg; } @@ -4181,6 +4130,14 @@ if (DEBUGGER) { "SR": DebuggerPDP11.REG_SR }; + DebuggerPDP11.REGNAMES = [ + "R0", "R1", "R2", "R3", "R4", "R5", "SP", "PC", + "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7", + "S0", "S1", "S2", "S3", + "PS", "PI", "ER", "SL", "M0", "M1", "M2", "M3", + "AR", "DR", "SR" + ]; + DebuggerPDP11.MODES = ["KI","KD","SI","SD","??","??","UI","UD"]; /* diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 199809a2f..465ffc82a 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -31,174 +31,174 @@ var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:functi function ha(){ea();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return oa(this)}});ha=function(){}}function oa(a){var b=0;return pa(function(){return ba?-b:b}});qa("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ra=Math.pow(2,36),sa=-Math.pow(2,35),t={Yb:0,nb:1,$b:2,ac:3,bc:4,cc:5,dc:6,ec:7,Ya:8,fc:9,ob:10,gc:11,hc:12,pb:13,ic:14,jc:15,kc:16,lc:17,mc:18,nc:19,oc:20,pc:21,qc:22,rc:23,sc:24,tc:25,uc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Xa:65,Xb:66,Zb:67,vc:68,E:69,wc:70,xc:71,yc:72,zc:73,Ac:74,Bc:75,Cc:76,Dc:77,Ec:78,Fc:79,Gc:80,Q:81, -Hc:82,Ic:83,Jc:84,Kc:85,Lc:86,Mc:87,Nc:88,Oc:89,sb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Pc:97,Qc:98,Rc:99,d:100,e:101,Sc:102,Tc:103,Uc:104,Vc:105,Wc:106,k:107,Xc:108,Yc:109,n:110,Zc:111,p:112,q:113,r:114,$c:115,t:116,bd:117,cd:118,dd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,qb:127}; -function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.$a=b.comment;this.rb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.i={ready:!1,Ea:!1,Ua:!1,S:!1,error:!1};this.Na=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.B=this.C=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} -function x(a){window&&window.alert(a)}function xa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b":62,"?":63,"@":64,Va:65,Ub:66,Wb:67,sc:68,E:69,tc:70,uc:71,vc:72,wc:73,xc:74,yc:75,zc:76,Ac:77,Bc:78,Cc:79,Dc:80,Q:81, +Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Mc:97,Nc:98,Oc:99,d:100,e:101,Pc:102,Qc:103,Rc:104,Sc:105,Tc:106,k:107,Uc:108,Vc:109,n:110,Wc:111,p:112,q:113,r:114,Xc:115,t:116,Zc:117,$c:118,ad:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,mb:127}; +function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.i={ready:!1,Ea:!1,Sa:!1,T:!1,error:!1};this.Oa=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>=3;return(c?"0o":"")+d}function H(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} +function Oa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=3;return(c?"0o":"")+d}function H(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} function I(a){return H(a,4,!0)}function Qa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return gb[a]})}function hb(a,b){return(a+" ").slice(0,b)} -function ib(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var gb={"&":"&","<":"<",">":">",'"':""","'":"'"};function jb(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function J(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function lb(a,b){var c,d={W:null,R:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.R=g.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c":">",'"':""","'":"'"};function jb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} +function lb(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else d.W=f;d.S=f.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Db,a];this.A=this.b=this.B=this.C=null;this.exports={hold:this.vb,toggle:this.Qb,reset:this.Mb, -set:this.Pb};F(this)}q(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; -l.da=function(a,b,c,d){if(this.C&&this.C.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.D[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, -b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Nb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Ob(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.ta=function(a,b,c,d){this.C=a;this.B=b;this.b=c;this.A=d;Pb(this);Qb(this)};l.la=function(a,b){if(!b)if(this.U&&Rb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new N(this);a.set(0,[this.j,this.w,this.v]);return a.data()};l.restore=function(a){if(a=a[0])Sb(this,this.j=a[0]),Mb(this,this.w=a[1]),Tb(this,a[2]);return!0};l.Mb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Qb(this);return!0};function Ub(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Pb(a,b){for(var c in a.D)Ub(a,c,null!=b?b:a.D[c])} -function Vb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Qb(a){for(var b in a.g)Vb(a,b,a.g[b][1])}l.vb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d,b);a&&a()},+c);return!1}Ob(this,b)}return!0};l.Pb=function(a,b){if("SR"==a)return Tb(this,Oa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Vb(this,a,c[1]),!0):!1};l.Qb=function(a){return Nb(this,a)?(Ob(this,a),!0):!1}; -function Nb(a,b){var c=a.g[b];return c?(Vb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Wb&&(a.N=b==Xb,a.O=b==Yb),!0):!1}function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Eb=function(a){a||this.b.i.J||(this.b.g=this.j%Ib,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Fb=function(){};l.zb=function(a){a||this.b.T()}; -l.xb=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ac(a,0,null),Ma(a,!1);else try{var b=this.b.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.g["S"+b][1]=a.v&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.j;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.u)return h.Ga+=h.u-e,h.u=e,!0;if(e>=h.u+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.u+m;e=k+16384;f-=m;g++;continue}}return lc(mc,e,f)}e=new V(0,e,m,16384,d);ic(e,a.A,h);a.g[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Pa(b)),!0):lc(oc,b,c)}function gc(a,b){return a.g[(b&a.v)>>>a.j].Oa(b&16383,b)} -function fc(a,b,c){a.g[(b&a.v)>>>a.j].Ha(b&16383,c&65535,b)}function jc(a){for(var b=0,c=[],d=0;d=a+b?c>>a&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Zc(a)&&(a.P=a.Z=-1,Vc(a),a.T(),c=!0);c&&a.f(Zc(a)+" cycles: checksum="+H(a.ma))}} -l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.i.S)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.xa*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&cd(a.C)}cc(a,a.w);a.w=0;a.v=va();a.G=0;ad(a);return d}function dd(a,b){for(var c=a.D.length-1;0<=c;c--){var d=a.D[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ed(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function fd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} -l.Nb=function(){if(this.i.J){this.ra>=this.za&&ad(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.ya&&(this.v+=a,this.v>this.ga&&(this.v=this.ga))}try{do{var b=dd(this,this.i.Ba?1:this.oa);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=fd(this,!0);this.aa+=b;this.w+=b;dc(this,b);bc(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Aa>=gd&&(this.C&&P(this.C,void 0),this.Aa=0);break}}while(this.i.J)}catch(e){this.T();this.C&&this.C.stop(va(),Zc(this));Ia(this,e.stack|| -e.message);return}if(this.i.J){a=setTimeout;b=this.bb;this.G=va();var c=this.ya;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.v;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,$c(this)));if(0>c||this.Lc&&(this.v-=c),c=0;this.ra+=this.aa;this.G+=c;a(b,c)}}}; -function $b(a,b){if(!Ja(a))if(a.i.J)a.f(a.toString()+" busy");else{$c(a);a.i.J=!0;a.i.Ra=!0;var c=a.F.run;c&&(c.textContent="Halt");a.C&&(b&&cd(a.C,!0),a.C.start(a.v,Zc(a)));a.A||a.status("Started");setTimeout(a.bb,0)}}l.Ia=function(){return 0};l.T=function(a){var b=!1;if(this.i.J){fd(this);cc(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.C&&this.C.stop(va(),Zc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var bd=30,gd=15,Sc=["power","reset"]; -function hd(a){var b=+a.model||1001;Rc.call(this,a,6666667);this.ab=b;this.La=+a.addrReset||0;this.fa=null;this.Da=[];this.i.complete=!1}q(hd,Rc);l=hd.prototype;l.reset=function(){this.status("Model "+this.ab);this.i.J&&this.T();this.ea=this.g=this.sa=this.La;this.j=0;this.pa=this.Jb;this.Ca=this.Wb;this.fa=null;Uc(this);this.i.error=!1;Rc.prototype.reset.call(this)};l.ib=function(){return 0}; -l.save=function(){var a=new N(this);a.set(0,[this.g,this.sa,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,id(this));a.set(4,ed(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):oa(b);this.g=b.next().value;this.sa=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];$c(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].pa(a&16383,a)};l.Wb=function(a,b){var c=this.B;a=this.ea=a;c.g[(a&c.v)>>>c.j].Ca(a&16383,b,a)}; -l.Ia=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.T();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.T();break}if(0>c)break}}this.j&=15;a=this.g;this.pa(a);this.g=(a+1)%Ib}while(0>>f.j;0>>= -f.j;0>>a.j;0g&&g>=sa&&(g+=ra);g=Math.trunc(Math.abs(g))%ra;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){G(a,"invalid block at offset "+I(p),4096);break}for(var k=k+2,n=b[k++]&255|(b[k++]&255)<<8,r=b[k++]&255|(b[k++]&255)<<8,m=m+((n&255)+(n>>8)+(r&255)+(r>>8)),Q=k,wa=n-=6;0=b.length){G(a,"insufficient data for block at offset "+I(p),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(p),4096);break}if(wa)for(G(a,"loading "+I(wa)+" bytes at "+I(r)+"-"+I(r+wa),4096);wa--;)fc(a.B,r++,b[Q++]);else r&1?g=!0:null==d&&(d=r),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Xa&&c<=t.sb&&(b=c-(t.Xa-t.nb));b&&(a.preventDefault&&a.preventDefault(),d.Pa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.pb&&(b=t.ob);d.Pa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Pa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ta=function(a,b,c,d){this.C=a;this.B=b;this.b=c;this.A=d;F(this)}; -l.lb=function(a){if(!this.g){var b=Tc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=ib(c[0]);if(d!=this.Ja)return;c=ib(c[1]);if(this.g=Ca(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.v);if(this.D=e.receiveData){this.v=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.lb(this.v),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new N(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Pa=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.v.length&&(a.w=0);if(0>a.w||b!=a.v[a.w])a.v.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.v[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(ib(b.substring(c,f))),c=f+1}}return a} -function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; -case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,Q--;g=n+g;d>>=8}d=H(c,0,!0)+" "+c+". "+Pa(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +var C="pdp10",Hb="PDPjs",Ib=Math.pow(2,18),Jb=Math.pow(2,36),C="pdp10",Hb="PDPjs",N={cpu:1,trap:2,fault:4,"int":8,bus:16,memory:32,mmu:64,rom:128,device:256,panel:512,keyboard:1024,key:2048,paper:4096,read:16384,write:32768,serial:1048576,timer:2097152,speaker:16777216,computer:33554432,log:268435456,warn:536870912,buffer:1073741824,halt:-2147483648}; +function Kb(a,b){u.call(this,"Panel",a,512);this.I=this.K=0;this.U=b;this.j=this.H=this.u=this.w=0;this.L=this.M=-1;this.N=this.O=this.G=!1;this.P=Lb;this.B={};this.g={START:[1,1,!0,!1,this.Bb],STEP:[1,1,!1,!1,this.Cb],ENABLE:[1,1,!1,!1,this.wb],CONT:[1,1,!0,!1,this.ub],DEP:[0,0,!0,!1,this.vb],EXAM:[1,1,!0,!1,this.xb],LOAD:[1,1,!0,!1,this.zb],TEST:[0,0,!0,!1,this.yb]};for(a=0;22>a;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, +set:this.Mb};E(this)}q(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; +l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, +b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Nb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Ob(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Pb(this);Qb(this)};l.la=function(a,b){if(!b)if(this.U&&Rb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()};l.restore=function(a){if(a=a[0])Sb(this,this.j=a[0]),Mb(this,this.w=a[1]),Tb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Qb(this);return!0};function Ub(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Pb(a,b){for(var c in a.B)Ub(a,c,null!=b?b:a.B[c])} +function Vb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Qb(a){for(var b in a.g)Vb(a,b,a.g[b][1])}l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d,b);a&&a()},+c);return!1}Ob(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Tb(this,Oa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Vb(this,a,c[1]),!0):!1};l.Nb=function(a){return Nb(this,a)?(Ob(this,a),!0):!1}; +function Nb(a,b){var c=a.g[b];return c?(Vb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Wb&&(a.N=b==Xb,a.O=b==Yb),!0):!1}function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Ib,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; +l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ac(a,0,null),Ma(a,!1);else try{var b=this.b.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.v+m;e=k+16384;g-=m;f++;continue}}return lc(mc,e,g)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Pa(b)),!0):lc(oc,b,c)} +function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(b&16383,c&65535,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Zc(a)&&(a.P=a.Z=-1,Vc(a),a.R(),c=!0);c&&a.f(Zc(a)+" cycles: checksum="+H(a.ma))}} +l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&cd(a.D)}cc(a,a.w);a.w=0;a.u=va();a.G=0;ad(a);return d}function dd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ed(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function fd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} +l.Kb=function(){if(this.i.J){this.qa>=this.Aa&&ad(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=dd(this,this.i.Ca?1:this.oa);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=fd(this,!0);this.aa+=b;this.w+=b;dc(this,b);bc(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=gd&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Zc(this));Ia(this,e.stack|| +e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,$c(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.qa+=this.aa;this.G+=c;a(b,c)}}}; +function $b(a,b){if(!Ja(a))if(a.i.J)a.f(a.toString()+" busy");else{$c(a);a.i.J=!0;a.i.Ra=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&cd(a.D,!0),a.D.start(a.u,Zc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){fd(this);cc(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Zc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var bd=30,gd=15,Sc=["power","reset"]; +function hd(a){var b=+a.model||1001;Rc.call(this,a,1E6);this.Za=b;this.Ma=+a.addrReset||0;this.fa=null;this.Da=[];this.i.complete=!1}q(hd,Rc);l=hd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.ra=this.Ma;this.j=0;this.ta=this.Gb;this.Ia=this.Tb;this.fa=null;Uc(this);this.i.error=!1;Rc.prototype.reset.call(this)};l.gb=function(){return 0}; +l.save=function(){var a=new O(this);a.set(0,[this.g,this.ra,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,id(this));a.set(4,ed(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):oa(b);this.g=b.next().value;this.ra=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];$c(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(a&16383,b,a)}; +l.Ja=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.g;this.ta(a);this.g=(a+1)%Ib}while(0>>g.j;0>>= +g.j;0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,r=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(r&255)+(r>>8)),K=k,ya=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= +b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(ya)for(G(a,"loading "+I(ya)+" bytes at "+I(r)+"-"+I(r+ya),4096);ya--;)fc(a.C,r++,b[K++]);else r&1?f=!0:null==d&&(d=r),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Va&&c<=t.ob&&(b=c-(t.Va-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Pa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Pa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Pa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; +l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=ib(c[0]);if(d!=this.Ka)return;c=ib(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Pa=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(ib(b.substring(c,g))),c=g+1}}return a} +function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Pa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Cd(a){td.call(this,a);this.xa=!1;this.ma=!0;this.I=X();this.wa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.qa=void 0;Ed(this);this.A=this;this.na={};this.V=this.fb=0;this.U=null;this.M=[];Fd(this,a.messages);this.sa=a.commands;this.Aa=Gd;this.La=[];this.L=0;this.Da=this.ra=null;this.D=this.za=this.ya=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]= -function(a){return Yc(b,a)})}q(Cd,td);function Y(a){a=a&&a.u;null==a&&(a=-1);return a}function X(a,b,c){return{u:void 0===a?null:a,ub:void 0===b?!1:b,ka:!1,ba:c}}function Hd(a){return[a.u,a.ub,a.ba,a.ka,a.Qa]}function Id(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.cb=ud(a,c.Qa=b[4]));return c}l=Cd.prototype; -l.ta=function(a,b,c,d){this.B=b;this.C=a;this.b=c;this.ea=a.v;(a=Tc(a,"messages"))&&Fd(this,a);Jd(this,function(a){a:{var b=d.B.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.B.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var p=b[e];p.type==c?m++||d.f("..."):(c=p.type,m=nc[c],p&&d.f(H(p.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=nc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.pa(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.u=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0}l.ua=function(a,b,c){var d=!0;c||te(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.u)),d=!1;else{var f=this.B;f.g[e>>>f.j].ua(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(ue(this,a,a.length-1,"set"),Ed(this)));return d}; -function te(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.j],b==a.G));h.ka||Ed(a);break}}return f}function ve(a,b){for(var c=1;cd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} +function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0}l.va=function(a,b,c){var d=!0;c||te(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(ue(this,a,a.length-1,"set"),Ed(this)));return d}; +function te(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Ed(a);break}}return g}function ve(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],n=jb(p,k,a.gb);0>n&&p.splice(-(n+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({ad:b,u:c,wb:d,R:e,eb:f})} -function Ae(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.wb;if(e>=g&&eb[0]?1:a[0]>>0,f],p=jb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})} +function Ae(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=xe(a,b,g,f);a.f(f);a.I=b;e-=b.u-k;c++}}} -function we(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.u)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ka(a)&&0p||"z"S.length&&(a.f("note: only "+S.length+" available"),K=S.length);O-=K;0>O&&(null==S[S.length-1].u?(K=O+K,O=0):O+=S.length);var tc=[];"call"==Xd&&(Wa=1E5,tc=["CALL"]);for(void 0!==Wd&&a.f(K+" instructions earlier:");0=S.length&&(O=0);a.qa=K;Zd++;Wa--}}Zd||(a.f("no "+Yd+"history available"), -a.qa=void 0)}else{var ja=Z(a,R);if(ja){var ka=0,be="ds"==Ua;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||ff,ka=yd(a,ca);else{var ce=Z(a,ca);ce&&(ka=ce.u-ja.u)}0>ka&&(ka=0);65536wc?String.fromCharCode(wc):"."),Ya=Ya/ -256}la&&(la+="\n");la=be?la+(ma+","):la+(R+": "+ma+(de?"":" "+vc))}la&&a.f(la);a.wa=ja;a.ba=hf}}}}break;case "e":if("else"==g[0])break;var Za,ee,fe,ge,he=g[0],xc=g[1];"e"==he||"ew"==he?(Za=2,ee=65535,fe=a.va,ge=a.Za):xc=null;if(null==xc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,xc);if(Cb)for(var Db=2;DbAc;){for(var na=null,nf=256;65536>bb.u>>>0;){Bc.u=a.va(bb,2);if(null==bb.u||!nf--)break;if(!(Bc.u&1)){for(var of=a,Eb=Bc,je=null,cb=Eb.u,ke=cb,Cc=1;6>=Cc&&cb;Cc++){if(2h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=xe(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} +function we(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ka(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Xd&&(Wa=1E5,tc=["CALL"]);for(void 0!==Wd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;Zd++;Wa--}}Zd||(a.f("no "+Yd+"history available"), +a.pa=void 0)}else{var ja=Z(a,R);if(ja){var ka=0,be="ds"==Ua;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||gf,ka=yd(a,ca);else{var ce=Z(a,ca);ce&&(ka=ce.v-ja.v)}0>ka&&(ka=0);65536wc?String.fromCharCode(wc):"."),Ya=Ya/ +256}la&&(la+="\n");la=be?la+(ma+","):la+(R+": "+ma+(de?"":" "+vc))}la&&a.f(la);a.xa=ja;a.ba=jf}}}}break;case "e":if("else"==f[0])break;var Za,ee,fe,ge,he=f[0],xc=f[1];"e"==he||"ew"==he?(Za=2,ee=65535,fe=a.wa,ge=a.Xa):xc=null;if(null==xc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,xc);if(Cb)for(var Db=2;DbAc;){for(var na=null,of=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!of--)break;if(!(Bc.v&1)){for(var pf=a,Eb=Bc,je=null,cb=Eb.v,ke=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> "; -L(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bLe){if(Me(d,this.K)){this.D=new N(this,"1.34.0",Ve);Me(this.D)&&(We(this,d),a=Xe,Ye(this.D));this.D.set(Se,kb());Ze(this.D);var e=this.g&&!this.I;if(a==Te||xa("Click OK to restore the previous "+Hb+" machine state, or CANCEL to reset the machine.")){if(c=Re(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Me(d,g):("error"==f&&"no machine state"!= -g?(this.Y("Error: "+g),"unable to verify user"==g&&(pb($e,""),this.j=null)):this.f(f+": "+g),Ye(d),Me(d)?(c=Re(d),e=!0):c=!1))}e&&Pe(this,c?d:null)}else a==Xe&&d.clear()}else Pe(this);delete this.K;delete this.H}e=y(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.S=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(af(this,this.b,b,c,a),P(this,-2),this.b.X());this.N&&(We(this,b),b.clear());!c&&this.D&&(this.D.clear(),delete this.D);this.w=0}; -function We(a,b){if(xa("There may be a problem with your "+Hb+" machine.\n\nTo help us diagnose it, click OK to send this "+Hb+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Hb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function Ge(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new N(a,"1.34.0"),g=new N(a,"1.34.0",Qe),h=kb();g.set(Se,h);f.set(Se,h);f.set(bf,"1.34.0");f.set(cf,window?window.location.href:null);f.set(df,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.T()),d=a.b.ca(b,c),"object"===typeof d&&f.set(a.b.id,d),c&&(a.b.i.S=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.wa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.wa=0)}if(a.v&&(a=a.v,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Pa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0\nLicense: GPL version 3 or later ");for(b=0;bLe){if(Me(d,this.K)){this.B=new O(this,"1.34.0",Ve);Me(this.B)&&(We(this,d),a=Xe,Ye(this.B));this.B.set(Se,kb());Ze(this.B);var e=this.g&&!this.I;if(a==Te||wa("Click OK to restore the previous "+Hb+" machine state, or CANCEL to reset the machine.")){if(c=Re(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Me(d,f):("error"==g&&"no machine state"!= +f?(this.Y("Error: "+f),"unable to verify user"==f&&(pb($e,""),this.j=null)):this.f(g+": "+f),Ye(d),Me(d)?(c=Re(d),e=!0):c=!1))}e&&Pe(this,c?d:null)}else a==Xe&&d.clear()}else Pe(this);delete this.K;delete this.H}e=y(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(af(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(We(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function We(a,b){if(wa("There may be a problem with your "+Hb+" machine.\n\nTo help us diagnose it, click OK to send this "+Hb+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Hb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} +function Ge(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new O(a,"1.34.0"),f=new O(a,"1.34.0",Qe),h=kb();f.set(Se,h);g.set(Se,h);g.set(bf,"1.34.0");g.set(cf,window?window.location.href:null);g.set(df,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&g.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Pa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1pdp11$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Af(a,b,c)}})}else c(a,null)} -function Bf(a,b,c,d){function e(a){if(void 0===h){var b=g&&D(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=Va(a))}function f(a){e("Error: "+a);k&&(--xf||zb(!0));k=!1}var g,h,k=!0;xf++;ua[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css";n.styleSheet?n.styleSheet.cssText=m:n.appendChild(document.createTextNode(m));p.appendChild(n)}c|| -(c="/versions/pdpjs/1.34.0/components.xsl");m=function(d,h){h?yf(c,null,null,!1,e,function(d,k){k?(ta(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--xf||zb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--xf||zb(!0)):f("invalid machine element: "+ -a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?yf(b,a,d,!0,e,m):zf(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(r){f(r.message)}return k}window.embedPDP11=function(a,b,c,d){zb(!1);return Bf(a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Ea[a]){for(var c=!0,d=Ea,e=a,f=b.length,g=[],h=[],k="",m=null,p=0;pf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);Af(a,b,c)}})}else c(a,null)} +function Bf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--xf||zb(!0));m=!1}var h,k,m=!0;xf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css";r.styleSheet?r.styleSheet.cssText=n:r.appendChild(document.createTextNode(n));p.appendChild(r)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?yf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--xf||zb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--xf|| +zb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?yf(c,b,a,e,!0,g,n):zf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(K){f(K.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Bf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Bf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Ea[a]){for(var c=!0,d=Ea,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),t={Ab:0,Qa:1,Cb:2,Db:3,Eb:4,Fb:5,Gb:6,Hb:7,Fa:8,Ib:9,Ra:10,Jb:11,Kb:12,Sa:13,Lb:14,Mb:15,Nb:16,Ob:17,Pb:18,Qb:19,Rb:20,Sb:21,Tb:22,Ub:23,Vb:24,Wb:25,Xb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ea:65,zb:66,Bb:67,Yb:68,E:69,Zb:70,$b:71,ac:72,bc:73,cc:74,dc:75,ec:76,fc:77,gc:78,hc:79,ic:80,Q:81, -jc:82,kc:83,lc:84,mc:85,nc:86,oc:87,pc:88,qc:89,Wa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,rc:97,sc:98,tc:99,d:100,e:101,uc:102,vc:103,wc:104,xc:105,yc:106,k:107,zc:108,Ac:109,n:110,Bc:111,p:112,q:113,r:114,Cc:115,t:116,Dc:117,Ec:118,Fc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ta:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ia=b.comment;this.Va=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ha=this.id:(this.ia=this.id.substr(0,a),this.ha=this.id.substr(a+1));this.b={ready:!1,ma:!1,za:!1,w:!1,error:!1};this.pa=null;this.b.error=!1;this.o=this.c=this.j=this.m=this.Y=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ja=-Math.pow(2,35),t={yb:0,Oa:1,Ab:2,Bb:3,Cb:4,Db:5,Eb:6,Fb:7,Fa:8,Gb:9,Pa:10,Hb:11,Ib:12,Qa:13,Jb:14,Kb:15,Lb:16,Mb:17,Nb:18,Ob:19,Pb:20,Qb:21,Rb:22,Sb:23,Tb:24,Ub:25,Vb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ea:65,xb:66,zb:67,Wb:68,E:69,Xb:70,Yb:71,Zb:72,$b:73,ac:74,bc:75,cc:76,dc:77,ec:78,fc:79,gc:80,Q:81, +hc:82,ic:83,jc:84,kc:85,lc:86,mc:87,nc:88,oc:89,Ua:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pc:97,qc:98,rc:99,d:100,e:101,sc:102,tc:103,uc:104,vc:105,wc:106,k:107,xc:108,yc:109,n:110,zc:111,p:112,q:113,r:114,Ac:115,t:116,Bc:117,Cc:118,Dc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ra:127}; +function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ia=b.comment;this.Ta=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ia=this.id:(this.ja=this.id.substr(0,a),this.ia=this.id.substr(a+1));this.b={ready:!1,na:!1,Ba:!1,w:!1,error:!1};this.qa=null;this.b.error=!1;this.o=this.c=this.j=this.m=this.Y=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>=3;return""+c}function F(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function wa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Aa[a]})}function Ba(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Aa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function Ca(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,h=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),h;var g=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(g.onreadystatechange=function(){4===g.readyState&&(f=g.responseText,200==g.status||!g.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=g.status||-1),d&&d(a, -f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");g.open("POST",a,c);g.setRequestHeader("Content-type","application/x-www-form-urlencoded");g.send(l)}else g.open("GET",a,c),"bytes"==b&&g.overrideMimeType("text/plain; charset=x-user-defined"),g.send();c||(f=g.responseText,200!=g.status&&(e=g.status||-1),d&&d(a,f,e),h=[f,e]);return h} -function Da(a,b){var c,d={D:null,I:null,R:null,P:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,h;if("<"==b.substr(0,1))throw Error(b);h=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.R=h.load;d.P=h.exec;if(e=h.bytes)d.D=e;else if(e=h.words)for(d.D=Array(2*e.length),f=c=0;c>8&255;else if(e=h.data)for(d.D=Array(4*e.length),f=c=0;c>8&255,d.D[f++]=e[c]>>16&255,d.D[f++]=e[c]>>24&255;else d.D=h;d.I=h.symbols;d.D.length?1==d.D.length&&(x(d.D[0]),d=null):(x("Empty resource: "+a),d=null)}catch(g){x("Resource data error ("+a+"): "+g.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c>=3;return""+c}function F(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function xa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ba[a]})}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ba={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function Da(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function Ea(a,b){var c,d={D:null,I:null,R:null,P:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.R=g.load;d.P=g.exec;if(e=g.bytes)d.D=e;else if(e=g.words)for(d.D=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.D=Array(4*e.length),f=c=0;c>8&255,d.D[f++]=e[c]>>16&255,d.D[f++]=e[c]>>24&255;else d.D=g;d.I=g.symbols;d.D.length?1==d.D.length&&(x(d.D[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.fb,a];this.o=this.c=this.j=this.m=null;this.exports={hold:this.Ya,toggle:this.sb,reset:this.ob, -set:this.rb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; +function Ua(a,b){u.call(this,"Panel",a);this.A=this.B=0;this.O=b;this.f=this.v=this.g=this.h=0;this.F=this.H=-1;this.K=this.L=this.s=!1;this.M=Va;this.l={};this.a={START:[1,1,!0,!1,this.eb],STEP:[1,1,!1,!1,this.fb],ENABLE:[1,1,!1,!1,this.Za],CONT:[1,1,!0,!1,this.Xa],DEP:[0,0,!0,!1,this.Ya],EXAM:[1,1,!0,!1,this.$a],LOAD:[1,1,!0,!1,this.bb],TEST:[0,0,!0,!1,this.ab]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.cb,a];this.o=this.c=this.j=this.m=null;this.exports={hold:this.Wa,toggle:this.qb,reset:this.mb, +set:this.pb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.l[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this, -b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0}; -k.save=function(){var a=new O(this);a.set(0,[this.f,this.h,this.g]);return a.data()};k.restore=function(a){if(a=a[0])P(this,this.f=a[0]),M(this,this.h=a[1]),$a(this,a[2]);return!0};k.ob=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.l)ab(a,c,null!=b?b:a.l[c])} -function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])}k.Ya=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; -k.rb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.f].Ba(b&16383,b)}else a=this.c.Z(this.f);M(this,this.h=a)}};k.eb=function(a){a||this.c.b.u||P(this,this.g)};k.cb=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.fb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),h=0;h>>a.f;0f&&(m=f);if(g&&g.size){if(g.type==d){if(e+f<=g.X)return g.ra+=g.X-e,g.X=e,!0;if(e>=g.X+g.ra){m=g.size-(e-l);m>f&&(m=f);g.ra=e-g.X+m;e=l+16384;f-=m;h++;continue}}return pb(qb,e,f)}e=new T(0,e,m,16384,d);mb(e,g);a.a[h++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+va(b)),!0):pb(sb,b,c)}function kb(a,b,c){a.a[(b&a.g)>>>a.f].sa(b&16383,c&65535,b)} -function nb(a){for(var b=0,c=[],d=0;d=a+b?c>>a&(1<=a.K&&(a.K+=a.da,c=!0);0<=a.ea&&a.ea<=W(a)&&(a.da=a.ea=-1,Fb(a),R(a),c=!0);c&&a.J(W(a)+" cycles: checksum="+F(a.ja))}} -k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,g=y(a.id);for(c=0;ca.F/a.H&&(b=1);a.L=b;b=a.va*a.L;if(a.H!=b){a.H=b;b=a.H.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.J("target speed: "+b)}c&&a.m&&(c=a.m,c.Y&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Y.focus(),window&&window.scrollTo(b,d)))}hb(a,a.h);a.h=0;a.g=w();a.s=0;Hb(a)}function Jb(a){for(var b=[],c=0;c>>a.f].Ca(b&16383,b)}else a=this.c.ba(this.f);N(this,this.h=a)}};k.bb=function(a){a||this.c.b.u||Q(this,this.g)};k.ab=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.cb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(0,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){a.a[(b&a.g)>>>a.f].ua(b&16383,c&65535,b)} +function nb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.K&&(a.K+=a.ea,c=!0);0<=a.fa&&a.fa<=X(a)&&(a.ea=a.fa=-1,Fb(a),S(a),c=!0);c&&a.J(X(a)+" cycles: checksum="+F(a.ka))}} +k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.F/a.H&&(b=1);a.L=b;b=a.xa*a.L;if(a.H!=b){a.H=b;b=a.H.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.J("target speed: "+b)}c&&a.m&&(c=a.m,c.Y&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Y.focus(),window&&window.scrollTo(b,d)))}hb(a,a.h);a.h=0;a.g=w();a.s=0;Hb(a)}function Jb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Kb(a,b){var c=a.v-=a.A;a.A=0;b&&(a.v=0);return c} -k.pb=function(){if(this.b.u){this.la>=this.xa&&Hb(this,!0);this.O=0;this.ba=w();if(this.s){var a=this.ba-this.s;a>this.wa&&(this.g+=a,this.g>this.ba&&(this.g=this.ba))}try{do{for(var b,c=this.b.na?1:this.fa,d=this.l.length-1;0<=d;d--){var e=this.l[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.ta(b)}catch(f){if("number"!=typeof f)throw f;}b=Kb(this,!0);this.O+=b;this.h+=b;ib(this,b);gb(this,b);this.M-=b;if(0>=this.M){this.M+=this.fa;++this.ya>=Lb&&(this.m&&S(this.m,void 0),this.ya=0);break}}while(this.b.u)}catch(f){R(this); -this.m&&this.m.stop(w(),W(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.u){a=setTimeout;b=this.Ja;this.s=w();c=this.wa;this.O&&(c=Math.round(c*this.O/this.fa));c-=this.s-this.ba;if(d=this.s-this.g)this.F=Math.round(this.h/(10*d))/100,864E5<=d&&(this.B=0,X(this));if(0>c||this.Fc&&(this.g-=c),c=0;this.la+=this.O;this.s+=c;a(b,c)}}}; -function Q(a){var b;a.b.error?(a.J(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.u)a.J(a.toString()+" busy");else{X(a);a.b.u=!0;a.b.Ca=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.g,W(a));a.o||a.status("Started");setTimeout(a.Ja,0)}}k.ta=function(){return 0};function R(a){var b=!1;if(a.b.u){Kb(a);hb(a,a.h);a.h=0;a.b.u=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),W(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Ib=30,Lb=15,Db=["power","reset"]; -function Mb(a){var b=+a.model||1001;U.call(this,a,6666667);this.Ua=b;this.Ha=+a.addrReset||0;this.W=null;this.Ga=[];this.b.complete=!1}r(Mb,U);k=Mb.prototype;k.reset=function(){this.status("Model "+this.Ua);this.b.u&&R(this);this.V=this.f=this.Ka=this.Ha;this.a=0;this.Z=this.lb;this.ca=this.yb;this.W=null;Eb(this);this.b.error=!1;U.prototype.reset.call(this)};k.Ma=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[this.f,this.Ka,this.V,this.a]);a.set(1,[]);a.set(2,[this.B,this.L,this.b.G]);a.set(3,Nb(this));a.set(4,Jb(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.f=b.next().value;this.Ka=b.next().value;this.V=b.next().value;this.a=b.next().value;b=a[2];this.B=b[0];X(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.f].Z(a&16383,a)};k.yb=function(a,b){var c=this.j;a=this.V=a;c.a[(a&c.g)>>>c.f].ca(a&16383,b,a)}; -k.ta=function(a){this.b.complete=!0;var b=a?this.b.Ca?0:1:-1;this.b.Ca=!1;this.v=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){R(this);break}if(0>b)break}this.a&=15;a=this.f;this.Z(a);this.f=(a+1)%Sa}while(0=this.za&&Hb(this,!0);this.O=0;this.ca=w();if(this.s){var a=this.ca-this.s;a>this.ya&&(this.g+=a,this.g>this.ca&&(this.g=this.ca))}try{do{for(var b,c=this.b.oa?1:this.ga,d=this.l.length-1;0<=d;d--){var e=this.l[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.va(b)}catch(f){if("number"!=typeof f)throw f;}b=Kb(this,!0);this.O+=b;this.h+=b;ib(this,b);gb(this,b);this.M-=b;if(0>=this.M){this.M+=this.ga;++this.Aa>=Lb&&(this.m&&T(this.m,void 0),this.Aa=0);break}}while(this.b.u)}catch(f){S(this); +this.m&&this.m.stop(w(),X(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.u){a=setTimeout;b=this.Ja;this.s=w();c=this.ya;this.O&&(c=Math.round(c*this.O/this.ga));c-=this.s-this.ca;if(d=this.s-this.g)this.F=Math.round(this.h/(10*d))/100,864E5<=d&&(this.B=0,Gb(this));if(0>c||this.Fc&&(this.g-=c),c=0;this.ma+=this.O;this.s+=c;a(b,c)}}}; +function R(a){var b;a.b.error?(a.J(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.u)a.J(a.toString()+" busy");else{Gb(a);a.b.u=!0;a.b.Da=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.g,X(a));a.o||a.status("Started");setTimeout(a.Ja,0)}}k.va=function(){return 0};function S(a){var b=!1;if(a.b.u){Kb(a);hb(a,a.h);a.h=0;a.b.u=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),X(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Ib=30,Lb=15,Db=["power","reset"]; +function Mb(a){var b=+a.model||1001;V.call(this,a,1E6);this.Sa=b;this.Ha=+a.addrReset||0;this.W=null;this.Ga=[];this.b.complete=!1}r(Mb,V);k=Mb.prototype;k.reset=function(){this.status("Model "+this.Sa);this.b.u&&S(this);this.V=this.f=this.Ka=this.Ha;this.a=0;this.ba=this.jb;this.ta=this.wb;this.W=null;Eb(this);this.b.error=!1;V.prototype.reset.call(this)};k.Ma=function(){return 0}; +k.save=function(){var a=new P(this);a.set(0,[this.f,this.Ka,this.V,this.a]);a.set(1,[]);a.set(2,[this.B,this.L,this.b.G]);a.set(3,Nb(this));a.set(4,Jb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.f=b.next().value;this.Ka=b.next().value;this.V=b.next().value;this.a=b.next().value;b=a[2];this.B=b[0];Gb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.f].ba(a&16383,a)};k.wb=function(a,b){var c=this.j;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(a&16383,b,a)}; +k.va=function(a){this.b.complete=!0;var b=a?this.b.Da?0:1:-1;this.b.Da=!1;this.v=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){S(this);break}if(0>b)break}this.a&=15;a=this.f;this.ba(a);this.f=(a+1)%Sa}while(0>>f.f;0>>=f.f;0>>f.f;0>>=f.f;0>>a.f;0h&&h>=ja&&(h+=ia);h=Math.trunc(Math.abs(h))%ia;void 0===f&&(f=e.size);for(g=d;f--&&g=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,n=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(n&255)+(n>>8)),Qa=l,Gb=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(Gb)for(;Gb--;)kb(a.j,n++,b[Qa++]);else n&1?h=!0:null==d&&(d=n);g=!0}else l++;else l+=2}if(!g&&(null==c&&(c=e),null!=c)){for(g=0;g< -b.length;g++)kb(a.j,c+g,b[g]);g=!0}if(g){if(null==d||h)R(a.c),f=!1;null!=d&&(a=a.c,a.Ha=d,a.f=d%Sa,f?a.b.w?a.b.u||Q(a):a.b.G=!0:a.o&&a.b.w?R(a)||a.m.b.reset||(a.o.g(),S(a.m,-1)):!1===f&&R(a),!a.b.u&&a.ga&&a.ga.stop())}return g}I(function(){for(var a=D(document,C,"ram"),b=0;b=t.Ea&&c<=t.Wa&&(b=c-(t.Ea-t.Qa));b&&(a.preventDefault&&a.preventDefault(),d.qa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.Sa&&(b=t.Ra);d.qa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.qa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;E(this)}; -k.Na=function(a){if(!this.a){var b=V(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ba(c[0]);if(d!=this.ha)return;c=Ba(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.l=e.receiveData){this.g=a;this.status("Connected "+this.ia+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.Na(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.qa=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,n=b[l++]&255|(b[l++]&255)<<8,p=b[l++]&255|(b[l++]&255)<<8,m=m+((n&255)+(n>>8)+(p&255)+(p>>8)),M=l,qa=n-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(qa)for(;qa--;)kb(a.j,p++,b[M++]);else p&1?g=!0:null==d&&(d=p);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ea&&c<=t.Ua&&(b=c-(t.Ea-t.Oa));b&&(a.preventDefault&&a.preventDefault(),d.ra(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.Qa&&(b=t.Pa);d.ra(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ra(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;E(this)}; +k.Na=function(a){if(!this.a){var b=W(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ia)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.l=e.receiveData){this.g=a;this.status("Connected "+this.ja+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.Na(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ra=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bXb){if(Z(d,this.B)){this.l=new O(this,"1.34.0",fc);Z(this.l)&&(gc(this,d),a=hc,ic(this.l));this.l.set(cc,Ca());jc(this.l);var e=this.a&&!this.A;if(a==dc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=bc(d)){var f=d.get("code"),h=d.get("data");f&&("ok"==f?Z(d,h):("error"==f&&"no machine state"!= -h?(this.C("Error: "+h),"unable to verify user"==h&&(Ha(kc,""),this.f=null)):this.J(f+": "+h),ic(d),Z(d)?(c=bc(d),e=!0):c=!1))}e&&$b(this,c?d:null)}else a==hc&&d.clear()}else $b(this);delete this.B;delete this.v}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.c&&(lc(this,this.c,b,c,a),S(this,-2),this.c.G());this.K&&(gc(this,b),b.clear());!c&&this.l&&(this.l.clear(),delete this.l);this.h=0}; +function Ub(a,b,c){u.call(this,"Computer",a);this.b.w=!1;this.L=null;Vb(this,b);this.H=W(this,"autoPower",a,6);this.h=0;this.V=+a.busWidth||+a.buswidth;this.B=this.s=this.F=null;this.A=this.O=!1;this.v=this.l=null;this.M=this.K=!1;this.W=W(this,"url")||"";(Math.random()+.1).toString(36);this.f=Wb(this);if(this.c=z("CPU",this.id)){this.o=z("Debugger",this.id);this.j=new lb({id:this.ja+".bus",busWidth:this.V},this.c,this.o);var d,e=y(this.id);if((this.g=z("Panel",this.id))&&this.g.Y)for(b=0;b\nLicense: GPL version 3 or later ");for(b=0;bXb){if(Z(d,this.B)){this.l=new P(this,"1.34.0",fc);Z(this.l)&&(gc(this,d),a=hc,ic(this.l));this.l.set(cc,Da());jc(this.l);var e=this.a&&!this.A;if(a==dc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=bc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(kc,""),this.f=null)):this.J(f+": "+g),ic(d),Z(d)?(c=bc(d),e=!0):c=!1))}e&&$b(this,c?d:null)}else a==hc&&d.clear()}else $b(this);delete this.B;delete this.v}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.c&&(lc(this,this.c,b,c,a),T(this,-2),this.c.G());this.K&&(gc(this,b),b.clear());!c&&this.l&&(this.l.clear(),delete this.l);this.h=0}; function gc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.f||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function mc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),h=new O(a,"1.34.0",ac),g=Ca();h.set(cc,g);f.set(cc,g);f.set(nc,"1.34.0");f.set(oc,window?window.location.href:null);f.set(pc,window?window.navigator.userAgent:"");a.c&&a.c.N&&(c&&(b&&(a.c.b.G=a.c.b.u),R(a.c)),d=a.c.N(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.b.w=!1,!1===d&&(e=null)));for(var g=y(a.id),l=0;l=d||30<=(c.ua+=d))&&(e.textContent=c.b.u?c.F.toFixed(2)+"Mhz":"Stopped",c.ua=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.c.b.u;d=!!(a.c.a&8);if(0>=b||60<=(a.A+=b)){e=a.c.f;if(a.i.PC){var f=a.o&&a.o.l||8,e=e||0,e=8==f?va(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.f=a.c.f:0=d||30<=(c.wa+=d))&&(e.textContent=c.b.u?c.F.toFixed(2)+"Mhz":"Stopped",c.wa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.c.b.u;d=!!(a.c.a&8);if(0>=b||60<=(a.A+=b)){e=a.c.f;if(a.i.PC){var f=a.o&&a.o.l||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.f=a.c.f:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1pdp11$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,h,g){if(g||!h)c(a,"unable to resolve XML reference: "+d[0]+" ("+g+")");else{if(f=d[3])if(g=h.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=g[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);g[0]!=l&&(h=h.replace(g[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}h=h.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],h);xc(a,b,c)}})}else c(a,null)} -function yc(a,b,c,d){function e(a){if(void 0===g){var b=h&&D(h,"machine-warning");g=b&&b[0]||h}g&&(g.innerHTML=za(a))}function f(a){e("Error: "+a);l&&(--uc||K(!0));l=!1}var h,g,l=!0;uc++;la[a]={};try{if(h=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css";n.styleSheet?n.styleSheet.cssText=m:n.appendChild(document.createTextNode(m));p.appendChild(n)}c|| -(c="/versions/pdpjs/1.34.0/components.xsl");m=function(d,g){g?vc(c,null,null,!1,e,function(d,l){l?(ka(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(l=g.transformNode(l))?(h.outerHTML=l,--uc||K(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(l),(l=d.transformToFragment(g,document))?h.parentNode?(h.parentNode.replaceChild(l,h),--uc||K(!0)):f("invalid machine element: "+a): -f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?vc(b,a,d,!0,e,m):wc(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(Qa){f(Qa.message)}return l}window.embedPDP11=function(a,b,c,d){K(!1);return yc(a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,h=[],g=[],l="",m=null,p=0;pg.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);xc(a,b,c)}})}else c(a,null)} +function yc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);m&&(--uc||K(!0));m=!1}var h,l,m=!0;uc++;la[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],M=document.createElement("style");M.type="text/css";M.styleSheet?M.styleSheet.cssText=n:M.appendChild(document.createTextNode(n));p.appendChild(M)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,l){l?vc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--uc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--uc|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?vc(c,b,a,e,!0,f,n):wc(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(qa){g(qa.message)}return m}window.embedPDP10=function(a,b,c,d){K(!1);return yc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return yc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",m=null,n=0;nc&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,Id:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,qk:98,tk:99,d:100,e:101,uk:102,vk:103,wk:104,xk:105,Bk:106,k:107,Ck:108,Dk:109,n:110,Ek:111,p:112,q:113,r:114,Fk:115,t:116,Ik:117,Jk:118,Kk:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Vd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.wb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,fb:!1,wd:!1,aa:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.F=this.f=this.D=this.J=this.Ua=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} +var ka={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[40,2,9,,253],737280:[80,2,9,,249],1228800:[80,2,15,,249],1474560:[80,2,18,,240],2949120:[80,2,36,,240],21368320:[615,4,17],256256:[77,1,26,128],2494464:[203,2,12,512],5242880:[256,2,40,256],10485760:[512,2,40,256]},la={Ai:0,Fe:1,Hi:2,Ii:3,Ji:4,Ki:5,Li:6,Mi:7,Nd:8,Ni:9,Ge:10,Oi:11,Pi:12,He:13,Qi:14,Ri:15,Si:16,Ti:17,Ui:18,Vi:19,Wi:20,Xi:21,Yi:22,Zi:23,$i:24,aj:25,bj:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39, +"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Jd:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,qk:98,tk:99,d:100,e:101,uk:102,vk:103,wk:104,xk:105,Bk:106,k:107,Ck:108,Dk:109,n:110,Ek:111,p:112,q:113,r:114,Fk:115,t:116,Ik:117,Jk:118,Kk:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Wd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,aa:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.F=this.f=this.D=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} function qa(){return Date.now()||+new Date}function v(a){window&&window.alert(a)}function ra(a){var b=!1;window&&(b=window.confirm(a));return b}function ta(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;bb?1:a>1,k;k=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function bb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var k=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(k.onreadystatechange=function(){4===k.readyState&&(f=k.responseText,200==k.status||!k.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=k.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");k.open("POST",a,c);k.setRequestHeader("Content-type","application/x-www-form-urlencoded");k.send(l)}else k.open("GET",a,c),"bytes"==b&&k.overrideMimeType("text/plain; charset=x-user-defined"),k.send();c||(f=k.responseText,200!=k.status&&(e=k.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function cb(a,b){var c,d={da:null,ga:null,za:null,ya:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.za=g.load;d.ya=g.exec;if(e=g.bytes)d.da=e;else if(e=g.words)for(d.da=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.da=Array(4*e.length),f=c=0;c>8&255,d.da[f++]=e[c]>>16&255,d.da[f++]=e[c]>>24&255;else d.da=g;d.ga=g.symbols;d.da.length?1==d.da.length&&(v(d.da[0]),d=null):(v("Empty resource: "+a),d=null)}catch(k){v("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ya=g.load;d.xa=g.exec;if(e=g.bytes)d.ca=e;else if(e=g.words)for(d.ca=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.ca=Array(4*e.length),f=c=0;c>8&255,d.ca[f++]=e[c]>>16&255,d.ca[f++]=e[c]>>24&255;else d.ca=g;d.ga=g.symbols;d.ca.length?1==d.ca.length&&(v(d.ca[0]),d=null):(v("Empty resource: "+a),d=null)}catch(k){v("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Sf,a];this.F=this.f=this.D=this.J=null;this.exports={hold:this.Hf,toggle:this.lh, -reset:this.gh,set:this.kh};y(this)}p(Rb,r);function Tb(a,b){return Ub(a,a.qb=b)}h=Rb.prototype;h.reset=function(a){this.stop();a&&Tb(this,0)}; +function Rb(a,b){u.call(this,"Panel",a,512);this.j=this.u=0;this.M=b;this.fa=this.g=this.Wa=this.Eb=0;this.B=this.C=-1;this.G=this.I=this.w=!1;this.L=Sb;this.i={};this.b={START:[1,1,!0,!1,this.Tf],STEP:[1,1,!1,!1,this.Uf],ENABLE:[1,1,!1,!1,this.Of],CONT:[1,1,!0,!1,this.Mf],DEP:[0,0,!0,!1,this.Nf],EXAM:[1,1,!0,!1,this.Pf],LOAD:[1,1,!0,!1,this.Rf],TEST:[0,0,!0,!1,this.Qf]};for(a=0;22>a;a++)this.b["S"+a]=[0,0,!1,!1,this.Sf,a];this.F=this.f=this.D=this.J=null;this.exports={hold:this.Hf,toggle:this.lh, +reset:this.gh,set:this.kh};y(this)}p(Rb,u);function Tb(a,b){return Ub(a,a.Eb=b)}h=Rb.prototype;h.reset=function(a){this.stop();a&&Tb(this,0)}; h.va=function(a,b,c,d){if(this.J&&this.J.va(a,b,c,d)||this.f&&this.f.va(a,b,c,d)||this.F&&this.F.va(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.H[b]=c,this.u++,!0;default:return"led"==a||"rled"==a?(this.H[b]=c,this.i[b]=d?1:0,this.u++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.H[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, -b){return function(){Vb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Wb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Vb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Wb(a,b)}}(this,b),!0):r.prototype.va.call(this,a,b,c,d)}};h.Aa=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;Xb(b,this,dc);ec(b,this.reset.bind(this));fc(this);gc(this)}; -h.Da=function(a,b){if(!b)if(this.M&&hc(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};h.Ca=function(a){return a?this.save():!0};h.save=function(){var a=new G(this);a.set(0,[this.ba,this.qb,this.Ra]);return a.data()};h.restore=function(a){if(a=a[0])ic(this,this.ba=a[0]),Tb(this,a[1]),jc(this,a[2]);return!0};h.gh=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}gc(this);return!0};function kc(a,b,c){if(a=a.H[b])a.style.backgroundColor=c?"#ff0000":"#000000"} -function fc(a,b){for(var c in a.i)kc(a,c,null!=b?b:a.i[c])}function lc(a,b,c){if(a=a.H[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function gc(a){for(var b in a.b)lc(a,b,a.b[b][1])}function mc(a,b,c,d){if(a.H[b]){var e=a.F&&a.F.Ba||8;c=c||0;c=8==e?E(c,d):F(c,d);a.H[b].textContent!=c&&(a.H[b].textContent=c)}}h.Hf=function(a,b,c){if(Vb(this,b)){if(c){var d=this;setTimeout(function(){Wb(d,b);a&&a()},+c);return!1}Wb(this,b)}return!0}; +b){return function(){Vb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Wb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Vb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Wb(a,b)}}(this,b),!0):u.prototype.va.call(this,a,b,c,d)}};h.za=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;Xb(b,this,dc);ec(b,this.reset.bind(this));fc(this);gc(this)}; +h.Ca=function(a,b){if(!b)if(this.M&&hc(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.save=function(){var a=new G(this);a.set(0,[this.fa,this.Eb,this.Wa]);return a.data()};h.restore=function(a){if(a=a[0])ic(this,this.fa=a[0]),Tb(this,a[1]),jc(this,a[2]);return!0};h.gh=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}gc(this);return!0};function kc(a,b,c){if(a=a.H[b])a.style.backgroundColor=c?"#ff0000":"#000000"} +function fc(a,b){for(var c in a.i)kc(a,c,null!=b?b:a.i[c])}function lc(a,b,c){if(a=a.H[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function gc(a){for(var b in a.b)lc(a,b,a.b[b][1])}function mc(a,b,c,d){if(a.H[b]){var e=a.F&&a.F.Aa||8;c=c||0;c=8==e?E(c,d):F(c,d);a.H[b].textContent!=c&&(a.H[b].textContent=c)}}h.Hf=function(a,b,c){if(Vb(this,b)){if(c){var d=this;setTimeout(function(){Wb(d,b);a&&a()},+c);return!1}Wb(this,b)}return!0}; h.kh=function(a,b){if("SR"==a)return jc(this,Ka(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,lc(this,a,c[1]),!0):!1};h.lh=function(a){return Vb(this,a)?(Wb(this,a),!0):!1};function Vb(a,b){var c=a.b[b];return c?(lc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=nc&&(a.G=b==oc,a.I=b==pc),!0):!1}function Wb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(lc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} -h.Tf=function(a){a||this.f.A.V||(qc(this.f,this.ba),a=this.f,a.D.reset(),rc(a),this.b[sc]&&this.b[sc][1]&&tc(this.f))};h.Uf=function(){};h.Of=function(a){a||this.f.ca()};h.Mf=function(a){if(!a&&!this.f.A.V)if(this.b[sc]&&this.b[sc][1])tc(this.f);else{if((a=this.F)&&!Ha(a,!0))Ja(a,!0),uc(a,0,null),Ja(a,!1);else try{var b=this.f.Cc(1);0=a.f.ka?8:16,c=65472<=a.ba&&a.ba<65472+b,b=c?1:2,c=c?15:a.D.I;a.b[nc]&&a.b[nc][1]||(b=-b);ic(a,a.ba&~c|a.ba+b&c)}function ic(a,b){a.ba=b&a.D.I;if(a.B!==a.ba){a.B=a.ba;b=a.B;for(var c=0;22>c;c++)Dc(a,"A"+c,b&1<c;c++)Dc(a,"D"+c,b&1<b;b++)a.b["S"+b][1]=a.Ra&1<>2;this.i=this.j-1;this.G=this.M/this.j|0;this.S=this.G-1;this.Pa=[];this.na=0;this.C=!1;this.N=[];this.yf=[Hc,Ic,Jc,Kc];this.b=this.u=[];this.B=this.L=this.w=this.O=this.P=0;a=new I(this);Wc(a,this.F);this.b=Array(this.G);this.u=Array(this.G);for(b=0;b>>this.g;this.L=0;this.w=this.I;y(this)}p(Fc,r);function Zc(a,b){if(b!=a.L){for(var c=0;c>>a.g,a.u[a.P]=a.b[a.O])}}h=Fc.prototype;h.reset=function(){for(var a=0;a=a.f.ka?8:16,c=65472<=a.fa&&a.fa<65472+b,b=c?1:2,c=c?15:a.D.I;a.b[nc]&&a.b[nc][1]||(b=-b);ic(a,a.fa&~c|a.fa+b&c)}function ic(a,b){a.fa=b&a.D.I;if(a.B!==a.fa){a.B=a.fa;b=a.B;for(var c=0;22>c;c++)Dc(a,"A"+c,b&1<c;c++)Dc(a,"D"+c,b&1<b;b++)a.b["S"+b][1]=a.Wa&1<>2;this.i=this.j-1;this.G=this.M/this.j|0;this.S=this.G-1;this.Pa=[];this.na=0;this.C=!1;this.N=[];this.yf=[Hc,Ic,Jc,Kc];this.b=this.u=[];this.B=this.L=this.w=this.O=this.P=0;a=new I(this);Wc(a,this.F);this.b=Array(this.G);this.u=Array(this.G);for(b=0;b>>this.g;this.L=0;this.w=this.I;y(this)}p(Fc,u);function Zc(a,b){if(b!=a.L){for(var c=0;c>>a.g,a.u[a.P]=a.b[a.O])}}h=Fc.prototype;h.reset=function(){for(var a=0;a>>a.g;0g&&(n=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.K)return l.Xb+=l.K-f,l.K=f,!0;if(f>=l.K+l.Xb){n=l.size-(f-m);n>g&&(n=g);l.Xb=f-l.K+n;f=m+a.j;g-=n;k++;continue}}return ad(bd,f,g)}f=new I(a,f,n,a.j,d,e);Wc(f,a.F,l);a.b[k++]=f;f=m+a.j;g-=n}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+cd[d]+" at "+E(b)),!0):ad(dd,b,c)}h.Jd=function(a){return this.u[(a&this.w)>>>this.g].Eb(a&this.i,a)}; -h.Bc=function(a){var b=a&this.i,c=(a&this.w)>>>this.g;return Kb||b!=this.i?this.u[c].oa(b,a):this.u[c++].Eb(b,a)|this.u[c&this.S].Eb(0,a+1)<<8};h.Kd=function(a,b){this.u[(a&this.w)>>>this.g].Gb(a&this.i,b,a)};h.ac=function(a,b){var c=a&this.i,d=(a&this.w)>>>this.g;Kb||c!=this.i?this.u[d].Hb(c,b,a):(this.u[d++].Gb(c,b&255,a),this.u[d&this.S].Gb(0,b>>8&255,a+1))};function ed(a,b){return a.b[(b&a.I)>>>a.g]} +function Xc(a,b,c,d,e){for(var f=b,g=c,k=f>>>a.g;0g&&(n=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.K)return l.Xb+=l.K-f,l.K=f,!0;if(f>=l.K+l.Xb){n=l.size-(f-m);n>g&&(n=g);l.Xb=f-l.K+n;f=m+a.j;g-=n;k++;continue}}return ad(bd,f,g)}f=new I(a,f,n,a.j,d,e);Wc(f,a.F,l);a.b[k++]=f;f=m+a.j;g-=n}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+cd[d]+" at "+E(b)),!0):ad(dd,b,c)}h.Kd=function(a){return this.u[(a&this.w)>>>this.g].Db(a&this.i,a)}; +h.Bc=function(a){var b=a&this.i,c=(a&this.w)>>>this.g;return Kb||b!=this.i?this.u[c].oa(b,a):this.u[c++].Db(b,a)|this.u[c&this.S].Db(0,a+1)<<8};h.Ld=function(a,b){this.u[(a&this.w)>>>this.g].Gb(a&this.i,b,a)};h.ac=function(a,b){var c=a&this.i,d=(a&this.w)>>>this.g;Kb||c!=this.i?this.u[d].Hb(c,b,a):(this.u[d++].Gb(c,b&255,a),this.u[d&this.S].Gb(0,b>>8&255,a+1))};function ed(a,b){return a.b[(b&a.I)>>>a.g]} function Bc(a,b){var c;a.C=!1;a.na++;var d=b&a.i,e=ed(a,b);Kb||d!=a.i?c=e.B(d,b):c=e.J(d,b)|ed(a,b+1).J(0,b+1)<<8;a.na--;return c}function fd(a,b,c){a.C=!1;a.na++;ed(a,b).F(b&a.i,c&255,b);a.na--}function zc(a,b,c){a.C=!1;a.na++;var d=b&a.i,e=ed(a,b);Kb||d!=a.i?e.C(d,c&65535,b):(e.F(d,c&255,b),ed(a,b+1).F(0,c>>8&255,b+1));a.na--} -function $c(a){for(var b=0,c=[],d=0;da.f.ka)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,n=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&n&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(n)));for(var q=g[4],t=g[5]||1,u=0;ua.f.ka)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,n=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&n&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(n)));for(var q=g[4],t=g[5]||1,r=0;r>8:e[2](f)&255):f&1&&(e=d.Pa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return this.f&&z(this.f,16|e[5])&&C(this.f,e[4]+".readByte("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,3);c=255;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to byte @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} function Ic(a,b,c){var d=!1,e=this.controller,f=e.Pa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Pa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d?this.f&&z(this.f,16|f[5])&&C(this.f,f[4]+".writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,5),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to byte @"+K(this.f,c)+": "+K(this.f, b),!0,!e.na))}function Jc(a,b){var c=-1,d=this.controller;a=d.Pa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".readWord("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,2);c=65535;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to word @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} -function Kc(a,b,c){var d=!1,e=this.controller;a=e.Pa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d?this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,4),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to word @"+K(this.f,c)+": "+K(this.f,b),!0,!e.na))}function L(a){r.call(this,"Device",a,256);this.b={hb:128,Gd:-1}}p(L,r);h=L.prototype; -h.Aa=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.F=d;var e=this;this.b.Gd=ld(c,function(){e.b.hb|=128;e.b.hb&64&&md(e.f,e.b.Qa);e.J&&H(e.J,1);nd(e.f,e.b.Gd,1E3/60)});this.b.Qa=od(c,64,6,2097152);Xb(b,this,pd);ec(b,this.reset.bind(this));d&&qd(d,64,function(a){var b=e.f;rd(e,"KIPDR",b.B[0],0,a[0]);rd(e,"KDPDR",b.B[0],8,a[0]);rd(e,"KIPAR",b.M[0],0,a[0]);rd(e,"KDPAR",b.M[0],8,a[0],!0);rd(e,"SIPDR",b.B[1],0,a[0]);rd(e,"SDPDR",b.B[1],8,a[0]);rd(e,"SIPAR",b.M[1],0,a[0]);rd(e,"SDPAR",b.M[1],8,a[0], -!0);rd(e,"UIPDR",b.B[3],0,a[0]);rd(e,"UDPDR",b.B[3],8,a[0]);rd(e,"UIPAR",b.M[3],0,a[0]);rd(e,"UDPAR",b.M[3],8,a[0],!0);b.U&32&&rd(e,"UNIMAP",b.Ha,-1,a[0])});y(this)};function rd(a,b,c,d,e,f){a=a.F;if(!(e&&0>b.indexOf(e.toUpperCase()))){e=8;var g="",k=!1,l=0,m=8;0>d&&(e=c.length,d=0,k=!0,l=3,m=4);for(var n=0;n>1&63;var b=this.f.Ha[a>>1];return a&1?b>>16:b&65535};h.mi=function(a,b){b=b>>1&63;var c=b>>1;this.f.Ha[c]=b&1?this.f.Ha[c]&65535|(a&63)<<16:this.f.Ha[c]&-65536|a&65534};h.Pg=function(a){return this.f.B[1][a>>1&7]};h.fi=function(a,b){this.f.B[1][b>>1&7]=a&65295};h.Ng=function(a){return this.f.B[1][(a>>1&7)+8]};h.di=function(a,b){this.f.B[1][(b>>1&7)+8]=a&65295};h.Og=function(a){return this.f.M[1][a>>1&7]}; +function Kc(a,b,c){var d=!1,e=this.controller;a=e.Pa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d?this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,4),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to word @"+K(this.f,c)+": "+K(this.f,b),!0,!e.na))}function L(a){u.call(this,"Device",a,256);this.b={gb:128,Hd:-1}}p(L,u);h=L.prototype; +h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.F=d;var e=this;this.b.Hd=ld(c,function(){e.b.gb|=128;e.b.gb&64&&md(e.f,e.b.Qa);e.J&&H(e.J,1);nd(e.f,e.b.Hd,1E3/60)});this.b.Qa=od(c,64,6,2097152);Xb(b,this,pd);ec(b,this.reset.bind(this));d&&qd(d,64,function(a){var b=e.f;rd(e,"KIPDR",b.B[0],0,a[0]);rd(e,"KDPDR",b.B[0],8,a[0]);rd(e,"KIPAR",b.M[0],0,a[0]);rd(e,"KDPAR",b.M[0],8,a[0],!0);rd(e,"SIPDR",b.B[1],0,a[0]);rd(e,"SDPDR",b.B[1],8,a[0]);rd(e,"SIPAR",b.M[1],0,a[0]);rd(e,"SDPAR",b.M[1],8,a[0], +!0);rd(e,"UIPDR",b.B[3],0,a[0]);rd(e,"UDPDR",b.B[3],8,a[0]);rd(e,"UIPAR",b.M[3],0,a[0]);rd(e,"UDPAR",b.M[3],8,a[0],!0);b.W&32&&rd(e,"UNIMAP",b.Ha,-1,a[0])});y(this)};function rd(a,b,c,d,e,f){a=a.F;if(!(e&&0>b.indexOf(e.toUpperCase()))){e=8;var g="",k=!1,l=0,m=8;0>d&&(e=c.length,d=0,k=!0,l=3,m=4);for(var n=0;n>1&63;var b=this.f.Ha[a>>1];return a&1?b>>16:b&65535};h.mi=function(a,b){b=b>>1&63;var c=b>>1;this.f.Ha[c]=b&1?this.f.Ha[c]&65535|(a&63)<<16:this.f.Ha[c]&-65536|a&65534};h.Pg=function(a){return this.f.B[1][a>>1&7]};h.fi=function(a,b){this.f.B[1][b>>1&7]=a&65295};h.Ng=function(a){return this.f.B[1][(a>>1&7)+8]};h.di=function(a,b){this.f.B[1][(b>>1&7)+8]=a&65295};h.Og=function(a){return this.f.M[1][a>>1&7]}; h.ei=function(a,b){b=b>>1&7;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.Mg=function(a){return this.f.M[1][(a>>1&7)+8]};h.ci=function(a,b){b=(b>>1&7)+8;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.eg=function(a){return this.f.B[0][a>>1&7]};h.xh=function(a,b){this.f.B[0][b>>1&7]=a&65295};h.cg=function(a){return this.f.B[0][(a>>1&7)+8]};h.vh=function(a,b){this.f.B[0][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.f.M[0][a>>1&7]};h.wh=function(a,b){b=b>>1&7;this.f.M[0][b]=a;this.f.B[0][b]&=65295}; h.bg=function(a){return this.f.M[0][(a>>1&7)+8]};h.uh=function(a,b){b=(b>>1&7)+8;this.f.M[0][b]=a;this.f.B[0][b]&=65295};h.Vg=function(a){return this.f.B[3][a>>1&7]};h.li=function(a,b){this.f.B[3][b>>1&7]=a&65295};h.Tg=function(a){return this.f.B[3][(a>>1&7)+8]};h.ji=function(a,b){this.f.B[3][(b>>1&7)+8]=a&65295};h.Ug=function(a){return this.f.M[3][a>>1&7]};h.ki=function(a,b){b=b>>1&7;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Sg=function(a){return this.f.M[3][(a>>1&7)+8]}; -h.ii=function(a,b){b=(b>>1&7)+8;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Vb=function(a){a&=7;return this.f.w&2048?this.f.qa[a]:this.f.g[a]};h.Zb=function(a,b){b&=7;this.f.w&2048?this.f.qa[b]=a:this.f.g[b]=a};h.rg=function(){return this.f.w&49152?this.f.W[0]:this.f.g[6]};h.Ih=function(a){this.f.w&49152?this.f.W[0]=a:this.f.g[6]=a};h.ug=function(){return this.f.g[7]};h.Lh=function(a){this.f.g[7]=a};h.Wb=function(a){a&=7;return this.f.w&2048?this.f.g[a]:this.f.qa[a]}; -h.$b=function(a,b){b&=7;this.f.w&2048?this.f.g[b]=a:this.f.qa[b]=a};h.sg=function(){return 1==(this.f.w&49152)>>14?this.f.g[6]:this.f.W[1]};h.Jh=function(a){1==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.W[1]=a};h.tg=function(){return 3==(this.f.w&49152)>>14?this.f.g[6]:this.f.W[3]};h.Kh=function(a){3==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.W[3]=a};h.ag=function(a){return this.f.xc[a-65504>>1]};h.th=function(a,b){this.f.xc[b-65504>>1]=a};h.xe=function(a){return 65520==a?(gd(this.D)>>6)-1:0}; -h.Ce=function(){};h.Rg=function(){return 1};h.hi=function(){};h.$f=function(){return this.f.P};h.sh=function(){this.f.P=0};h.gg=function(){return this.f.uc};h.zh=function(a,b){b&1||(a&=255);this.f.uc=a};h.lg=function(a,b){return b?0:this.f.cb};h.Ch=function(a){yd(this.f,a)};h.Qg=function(a,b){return b?0:this.f.xa&65280};h.gi=function(a){this.f.xa=a|255};h.qg=function(){return zd(this.f)};h.Hh=function(a){Ad(this.f,a)};h.Be=function(a,b){z(this)&&C(this,"writeIgnored("+E(b)+"): "+E(a),!0,!0)}; +h.ii=function(a,b){b=(b>>1&7)+8;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Vb=function(a){a&=7;return this.f.w&2048?this.f.ta[a]:this.f.g[a]};h.Zb=function(a,b){b&=7;this.f.w&2048?this.f.ta[b]=a:this.f.g[b]=a};h.rg=function(){return this.f.w&49152?this.f.X[0]:this.f.g[6]};h.Ih=function(a){this.f.w&49152?this.f.X[0]=a:this.f.g[6]=a};h.ug=function(){return this.f.g[7]};h.Lh=function(a){this.f.g[7]=a};h.Wb=function(a){a&=7;return this.f.w&2048?this.f.g[a]:this.f.ta[a]}; +h.$b=function(a,b){b&=7;this.f.w&2048?this.f.g[b]=a:this.f.ta[b]=a};h.sg=function(){return 1==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[1]};h.Jh=function(a){1==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[1]=a};h.tg=function(){return 3==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[3]};h.Kh=function(a){3==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[3]=a};h.ag=function(a){return this.f.xc[a-65504>>1]};h.th=function(a,b){this.f.xc[b-65504>>1]=a};h.xe=function(a){return 65520==a?(gd(this.D)>>6)-1:0}; +h.Ce=function(){};h.Rg=function(){return 1};h.hi=function(){};h.$f=function(){return this.f.P};h.sh=function(){this.f.P=0};h.gg=function(){return this.f.uc};h.zh=function(a,b){b&1||(a&=255);this.f.uc=a};h.lg=function(a,b){return b?0:this.f.ob};h.Ch=function(a){yd(this.f,a)};h.Qg=function(a,b){return b?0:this.f.Ga&65280};h.gi=function(a){this.f.Ga=a|255};h.qg=function(){return zd(this.f)};h.Hh=function(a){Ad(this.f,a)};h.Be=function(a,b){z(this)&&C(this,"writeIgnored("+E(b)+"): "+E(a),!0,!0)}; var M={},pd=(M[61568]=[null,null,L.prototype.Wg,L.prototype.mi,"UNIMAP",64,1170],M[62592]=[null,null,L.prototype.Pg,L.prototype.fi,"SIPDR",8,1145,64],M[62608]=[null,null,L.prototype.Ng,L.prototype.di,"SDPDR",8,1145,64],M[62624]=[null,null,L.prototype.Og,L.prototype.ei,"SIPAR",8,1145,64],M[62640]=[null,null,L.prototype.Mg,L.prototype.ci,"SDPAR",8,1145,64],M[62656]=[null,null,L.prototype.eg,L.prototype.xh,"KIPDR",8,1140,64],M[62672]=[null,null,L.prototype.cg,L.prototype.vh,"KDPDR",8,1145,64],M[62688]= [null,null,L.prototype.dg,L.prototype.wh,"KIPAR",8,1140,64],M[62704]=[null,null,L.prototype.bg,L.prototype.uh,"KDPAR",8,1145,64],M[62798]=[null,null,L.prototype.kg,L.prototype.Bh,"MMR3",1,1145,64],M[65382]=[null,null,L.prototype.fg,L.prototype.yh,"LKS"],M[65402]=[null,null,L.prototype.hg,L.prototype.Ah,"MMR0",1,1140,64],M[65404]=[null,null,L.prototype.ig,L.prototype.Be,"MMR1",1,1145,64],M[65406]=[null,null,L.prototype.jg,L.prototype.Be,"MMR2",1,1140,64],M[65408]=[null,null,L.prototype.Vg,L.prototype.li, "UIPDR",8,1140,64],M[65424]=[null,null,L.prototype.Tg,L.prototype.ji,"UDPDR",8,1145,64],M[65440]=[null,null,L.prototype.Ug,L.prototype.ki,"UIPAR",8,1140,64],M[65456]=[null,null,L.prototype.Sg,L.prototype.ii,"UDPAR",8,1145,64],M[65472]=[null,null,L.prototype.Vb,L.prototype.Zb,"R0SET0"],M[65473]=[null,null,L.prototype.Vb,L.prototype.Zb,"R1SET0"],M[65474]=[null,null,L.prototype.Vb,L.prototype.Zb,"R2SET0"],M[65475]=[null,null,L.prototype.Vb,L.prototype.Zb,"R3SET0"],M[65476]=[null,null,L.prototype.Vb, L.prototype.Zb,"R4SET0"],M[65477]=[null,null,L.prototype.Vb,L.prototype.Zb,"R5SET0"],M[65478]=[null,null,L.prototype.rg,L.prototype.Ih,"R6KERNEL"],M[65479]=[null,null,L.prototype.ug,L.prototype.Lh,"R7KERNEL"],M[65480]=[null,null,L.prototype.Wb,L.prototype.$b,"R0SET1",1,1145],M[65481]=[null,null,L.prototype.Wb,L.prototype.$b,"R1SET1",1,1145],M[65482]=[null,null,L.prototype.Wb,L.prototype.$b,"R2SET1",1,1145],M[65483]=[null,null,L.prototype.Wb,L.prototype.$b,"R3SET1",1,1145],M[65484]=[null,null,L.prototype.Wb, L.prototype.$b,"R4SET1",1,1145],M[65485]=[null,null,L.prototype.Wb,L.prototype.$b,"R5SET1",1,1145],M[65486]=[null,null,L.prototype.sg,L.prototype.Jh,"R6SUPER",1,1145],M[65487]=[null,null,L.prototype.tg,L.prototype.Kh,"R6USER",1,1145],M[65504]=[null,null,L.prototype.ag,L.prototype.th,"CTRL",8,1170],M[65520]=[null,null,L.prototype.xe,L.prototype.Ce,"LSIZE",1,1170],M[65522]=[null,null,L.prototype.xe,L.prototype.Ce,"HSIZE",1,1170],M[65524]=[null,null,L.prototype.Rg,L.prototype.hi,"SYSID",1,1170],M[65526]= [null,null,L.prototype.$f,L.prototype.sh,"ERR",1,1170],M[65528]=[null,null,L.prototype.gg,L.prototype.zh,"MBR",1,1170],M[65530]=[null,null,L.prototype.lg,L.prototype.Ch,"PIR"],M[65532]=[null,null,L.prototype.Qg,L.prototype.gi,"SLR"],M[65534]=[null,null,L.prototype.qg,L.prototype.Hh,"PSW"],M); -rb(function(){for(var a=x(document,w,"device"),b=0;b>1),this.b=new Int32Array(this.u,0,this.size>>2),Id(this,Jd?Kd:Ld);else{a=this.b=Array(this.size>>2);for(f=0;f>2),b=0;b>8,c)};h.Yf=function(a){return this.b[a>>2]>>>((a&3)<<3)&255};h.bh=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);b=a>>2;a=(a&3)<<3;var c=this.b[b]>>a;return 24>a?c&65535:c&255|(this.b[b+1]&255)<<8}; -h.qh=function(a,b){var c=a>>2;a=(a&3)<<3;this.b[c]=this.b[c]&~(255<>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.gb=!0};h.Wf=function(a,b){this.f&&null!=this.K&&Sd(this.f,this.K+a);return this.J(a,b)};h.Yg=function(a,b){this.f&&null!=this.K&&Sd(this.f,this.K+a,2);return this.B(a,b)}; -h.oh=function(a,b,c){this.f&&null!=this.K&&Td(this.f,this.K+a);this.j?this.Yb(0,b,c):this.F(a,b,c)};h.oi=function(a,b,c){this.f&&null!=this.K&&Td(this.f,this.K+a,2);this.j?this.Yb(0,b,c):this.C(a,b,c)};h.Vf=function(a){return this.g[a]};h.Xf=function(a,b){a=this.g[a];this.f&&z(this.f,32)&&C(this.f,"Memory.readByte("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.Xg=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);return this.w.getUint16(a,!0)}; -h.ah=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);a=!Kb&&a&1?this.g[a]|this.g[a+1]<<8:this.G[a>>1];this.f&&z(this.f,32)&&C(this.f,"Memory.readWord("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.nh=function(a,b){this.g[a]=b;this.gb=!0};h.ph=function(a,b,c){this.g[a]=b;this.gb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0)};h.ni=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);this.w.setUint16(a,b,!0);this.gb=!0}; -h.pi=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);!Kb&&a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.G[a>>1]=b;this.gb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0)};var Gd=0,hd=1,Hd=2,Yc=4,cd=["NONE","RAM","ROM","VID","H/W"],Ed=0,Nd=[],Md=[I.prototype.Yf,I.prototype.qh,I.prototype.bh,I.prototype.ri],Qd=[I.prototype.Wf,I.prototype.oh,I.prototype.Yg,I.prototype.oi]; -if(Fb)var Ld=[I.prototype.Vf,I.prototype.nh,I.prototype.Xg,I.prototype.ni],Kd=[I.prototype.Xf,I.prototype.ph,I.prototype.ah,I.prototype.pi];var Ud;if(Fb){var Vd=new ArrayBuffer(2);(new DataView(Vd)).setUint16(0,256,!0);Ud=256===(new Uint16Array(Vd))[0]}else Ud=!1;var Jd=Ud; -function Wd(a,b){r.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.nb=c;this.ld=Math.round(this.Xc/1E4)/100;this.yb=this.ld*this.nb;this.md=this.qc=this.Bb=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.ra=a.autoStart;"string"==typeof this.A.ra&&(this.A.ra="true"==this.A.ra);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.ae=this.hh.bind(this);this.ob=this.Ka=this.mb=this.b=this.la=this.Ja=this.nc=this.lb=this.Sb= -this.nd=this.xb=0;this.ta=null;y(this)}p(Wd,r);h=Wd.prototype;h.Aa=function(a,b,c,d){this.J=a;this.D=b;this.F=d;this.ta=a.i;for(a=0;a=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=le(a)&&(a.Ob=a.Rb=-1,he(a),a.ca(),c=!0);c&&a.v(le(a)+" cycles: checksum="+F(a.oc))}} -h.va=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.H[b]=c,!0;case "run":return this.H[b]=c,c.onclick=function(){var a;if(a=d.J)if(a=d.J,a.A.aa)a=!0;else{var b=null,c,k=ta(a.id);for(c=0;ca.xb/a.yb?b=1:d=!0;a.nb=b;b=a.ld*a.nb;if(a.yb!=b){a.yb=b;b=a.yb.toFixed(2)+"Mhz";var e=a.H.setSpeed;e&&(e.textContent=b);a.v("target speed: "+b)}c&&a.J&&pe(a.J)}wc(a,a.Ka);a.Ka=0;a.Ja=qa();a.lb=0;ne(a);return d}function ld(a,b){var c=a.ia.length;a.ia.push([-1,b]);return c}function nd(a,b,c,d){0<=b&&ba.ia[b][0])&&(c=a.Xc*a.nb/1E3*c|0,a.A.V&&(c+=qe(a)),a.ia[b][0]=c)} -function re(a,b){for(var c=a.ia.length-1;0<=c;c--){var d=a.ia[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function se(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function qe(a,b){var c=a.mb-=a.b;a.b=a.la=0;b&&(a.mb=0);return c} -h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&ne(this,!0);this.Sb=0;this.nc=qa();if(this.lb){var a=this.nc-this.lb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=re(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=qe(this,!0);this.Sb+=b;this.Ka+=b;xc(this,b);vc(this,b);this.Bb-=b;if(0>=this.Bb){this.Bb+=this.qc;++this.nd>=te&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ca();this.J&&this.J.stop(qa(),le(this)); -Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.ae;this.lb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.lb-this.nc),d=this.lb-this.Ja;d&&(this.xb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.ob=0,me(this)));if(0>c||this.xbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.lb+=c;a(b,c)}}}; -function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.F||a.status("Started");setTimeout(a.ae,0)}}h.Cc=function(){return 0};h.ca=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.F||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,Xd=["power","reset"]; -function ue(a){var b=+a.model||1170;Wd.call(this,a,6666667);this.ka=b;this.Ud=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.qa=this.W=[];this.M=this.B=this.Ha=this.xc=[];this.jb=this.O=this.Sd=this.zb=this.Ab=this.sb=this.kb=this.P=this.uc=this.cb=this.xa=this.S=this.vc=this.wc=this.U=this.i=0;this.Xd=[4,2,0,1];this.zc=0;this.Yd=255;1120>=this.ka?(this.Rd=ve.bind(this),this.Lb=this.Cf,this.zc=8,this.Yd=-1,this.ee=255,this.de=0):(this.Rd=we.bind(this),this.Lb=this.Df, -this.ee=~(1792|(1140>=this.ka?2048:0))&65535,this.de=1140e.Fb&&(e.Fb=c,c+=4)}return Wd.prototype.Da.call(this,a,b)}; -h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ca();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Ud,-1,-2,-3,-4,-5,-6,-7,-8];this.qa=[0,0,0,0,0,0];this.W=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, -65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.X=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;Wd.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.U=0;a.P=0;a.cb=0;a.xa=255;a.zb=0;a.Ab=0;a.sb=0;a.kb=262143;a.jb=a.g[7];a.O=0;a.R=null;a.D&&(xe(a),a.Sd=gd(a.D))} -function xe(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.oe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.zb?(a.Ia=65536,a.vb=a.U&16?4186112:253952,a.Ga=a.se,a.oa=a.sc?a.$g:a.Dd,a.Hb=a.tc?a.ti:a.Hd,Zc(a.D,a.U&16?22:18)):(a.Ia=0,a.vb=57344,a.Ga=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,Zc(a.D,16))}function td(a){var b=a.S;b&57344||(b=b&-3199|a.Ab<<5|a.sb<<1);return b} -function ud(a,b){b&=-3073;if(a.S!=b){b&57344&&!(a.S&57344)&&(a.vc=a.O>>16&65535,a.wc=a.O&65535);a.S=b;a.Ab=(b&96)>>5;a.sb=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.zb!=c&&(a.zb=c,xe(a))}}function vd(a){a.S&57344||(a.vc=a.O>>16&65535);a=a.vc;a&65280&&(a=(a<<8|a>>8)&65535);return a}function wd(a){a.S&57344||(a.wc=a.O&65535);return a.wc}function xd(a,b){1170>a.ka&&(b&=-49);a.U!=b&&(a.U=b,a.kb=b&16?4194303:262143,xe(a))} -function ye(a,b,c,d){a.Ud=b;qc(a,b);Ad(a,0);a.D.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.aa?a.A.V||tc(a):a.A.ra=!0}else a.F&&a.A.aa?a.ca()||a.J.A.reset||(ie(a.F),H(a.J,-1)):!1===c&&a.ca();!a.A.V&&a.ta&&a.ta.stop()}h.pe=function(){return 0}; -h.save=function(){var a=new G(this);a.set(0,[this.g,this.qa,this.W,this.M,this.B,this.Ha,this.xc,this.P,this.uc,this.cb,this.xa,this.Ab,this.sb,this.jb,this.i,this.O,this.bb,this.Ac,this.Dc]);a.set(1,[zd(this),td(this),vd(this),wd(this),this.U]);a.set(2,[this.ob,this.nb,this.A.ra]);a.set(3,ze(this));a.set(4,se(this));return a.data()}; -h.restore=function(a){var b=ia(a[0]);this.g=b.next().value;this.qa=b.next().value;this.W=b.next().value;this.M=b.next().value;this.B=b.next().value;this.Ha=b.next().value;this.xc=b.next().value;this.P=b.next().value;this.uc=b.next().value;this.cb=b.next().value;this.xa=b.next().value;this.Ab=b.next().value;this.sb=b.next().value;this.jb=b.next().value;this.i=b.next().value;this.O=b.next().value;this.bb=b.next().value;this.Ac=b.next().value;this.Dc=b.next().value;b=a[1];Ad(this,b[0]);ud(this,b[1]); -this.vc=b[2];this.wc=b[3];xd(this,b[4]);b=a[2];this.ob=b[0];me(this,b[1]);this.A.ra=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>1),this.b=new Int32Array(this.u,0,this.size>>2),Id(this,Jd?Kd:Td);else{a=this.b=Array(this.size>>2);for(f=0;f>2),b=0;b>8,c)};h.Yf=function(a){return this.b[a>>2]>>>((a&3)<<3)&255};h.bh=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);b=a>>2;a=(a&3)<<3;var c=this.b[b]>>a;return 24>a?c&65535:c&255|(this.b[b+1]&255)<<8}; +h.qh=function(a,b){var c=a>>2;a=(a&3)<<3;this.b[c]=this.b[c]&~(255<>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.fb=!0};h.Wf=function(a,b){this.f&&null!=this.K&&$d(this.f,this.K+a);return this.J(a,b)};h.Yg=function(a,b){this.f&&null!=this.K&&$d(this.f,this.K+a,2);return this.B(a,b)}; +h.oh=function(a,b,c){this.f&&null!=this.K&&ae(this.f,this.K+a);this.j?this.Yb(0,b,c):this.F(a,b,c)};h.oi=function(a,b,c){this.f&&null!=this.K&&ae(this.f,this.K+a,2);this.j?this.Yb(0,b,c):this.C(a,b,c)};h.Vf=function(a){return this.g[a]};h.Xf=function(a,b){a=this.g[a];this.f&&z(this.f,32)&&C(this.f,"Memory.readByte("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.Xg=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);return this.w.getUint16(a,!0)}; +h.ah=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);a=!Kb&&a&1?this.g[a]|this.g[a+1]<<8:this.G[a>>1];this.f&&z(this.f,32)&&C(this.f,"Memory.readWord("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.nh=function(a,b){this.g[a]=b;this.fb=!0};h.ph=function(a,b,c){this.g[a]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0)};h.ni=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);this.w.setUint16(a,b,!0);this.fb=!0}; +h.pi=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);!Kb&&a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.G[a>>1]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0)};var Gd=0,hd=1,Hd=2,Yc=4,cd=["NONE","RAM","ROM","VID","H/W"],Fd=0,Vd=[],Ud=[I.prototype.Yf,I.prototype.qh,I.prototype.bh,I.prototype.ri],Yd=[I.prototype.Wf,I.prototype.oh,I.prototype.Yg,I.prototype.oi]; +if(Fb)var Td=[I.prototype.Vf,I.prototype.nh,I.prototype.Xg,I.prototype.ni],Kd=[I.prototype.Xf,I.prototype.ph,I.prototype.ah,I.prototype.pi];var be;if(Fb){var ce=new ArrayBuffer(2);(new DataView(ce)).setUint16(0,256,!0);be=256===(new Uint16Array(ce))[0]}else be=!1;var Jd=be; +function de(a,b){u.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.mb=c;this.ld=Math.round(this.Xc/1E4)/100;this.xb=this.ld*this.mb;this.md=this.qc=this.Ab=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.qa=a.autoStart;"string"==typeof this.A.qa&&(this.A.qa="true"==this.A.qa);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.be=this.hh.bind(this);this.nb=this.Ka=this.lb=this.b=this.la=this.Ja=this.nc=this.kb=this.Sb= +this.nd=this.wb=0;this.sa=null;y(this)}p(de,u);h=de.prototype;h.za=function(a,b,c,d){this.J=a;this.D=b;this.F=d;this.sa=a.i;for(a=0;a=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=le(a)&&(a.Ob=a.Rb=-1,he(a),a.ba(),c=!0);c&&a.v(le(a)+" cycles: checksum="+F(a.oc))}} +h.va=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.H[b]=c,!0;case "run":return this.H[b]=c,c.onclick=function(){var a;if(a=d.J)if(a=d.J,a.A.aa)a=!0;else{var b=null,c,k=ta(a.id);for(c=0;ca.wb/a.xb?b=1:d=!0;a.mb=b;b=a.ld*a.mb;if(a.xb!=b){a.xb=b;b=a.xb.toFixed(2)+"Mhz";var e=a.H.setSpeed;e&&(e.textContent=b);a.v("target speed: "+b)}c&&a.J&&pe(a.J)}wc(a,a.Ka);a.Ka=0;a.Ja=qa();a.kb=0;ne(a);return d}function ld(a,b){var c=a.ia.length;a.ia.push([-1,b]);return c}function nd(a,b,c,d){0<=b&&ba.ia[b][0])&&(c=a.Xc*a.mb/1E3*c|0,a.A.V&&(c+=qe(a)),a.ia[b][0]=c)} +function re(a,b){for(var c=a.ia.length-1;0<=c;c--){var d=a.ia[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function se(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function qe(a,b){var c=a.lb-=a.b;a.b=a.la=0;b&&(a.lb=0);return c} +h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&ne(this,!0);this.Sb=0;this.nc=qa();if(this.kb){var a=this.nc-this.kb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=re(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=qe(this,!0);this.Sb+=b;this.Ka+=b;xc(this,b);vc(this,b);this.Ab-=b;if(0>=this.Ab){this.Ab+=this.qc;++this.nd>=te&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ba();this.J&&this.J.stop(qa(),le(this)); +Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.be;this.kb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.kb-this.nc),d=this.kb-this.Ja;d&&(this.wb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.nb=0,me(this)));if(0>c||this.wbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.kb+=c;a(b,c)}}}; +function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.F||a.status("Started");setTimeout(a.be,0)}}h.Cc=function(){return 0};h.ba=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.F||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,ee=["power","reset"]; +function ue(a){var b=+a.model||1170;de.call(this,a,6666667);this.ka=b;this.Vd=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.ta=this.X=[];this.M=this.B=this.Ha=this.xc=[];this.ib=this.O=this.Td=this.yb=this.zb=this.rb=this.jb=this.P=this.uc=this.ob=this.Ga=this.S=this.vc=this.wc=this.W=this.i=0;this.Yd=[4,2,0,1];this.zc=0;this.Zd=255;1120>=this.ka?(this.Sd=ve.bind(this),this.Lb=this.Cf,this.zc=8,this.Zd=-1,this.fe=255,this.ee=0):(this.Sd=we.bind(this),this.Lb=this.Df, +this.fe=~(1792|(1140>=this.ka?2048:0))&65535,this.ee=1140e.Fb&&(e.Fb=c,c+=4)}return de.prototype.Ca.call(this,a,b)}; +h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ba();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Vd,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;de.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.D&&(xe(a),a.Td=gd(a.D))} +function xe(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.pe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.yb?(a.Ia=65536,a.ub=a.W&16?4186112:253952,a.Fa=a.se,a.oa=a.sc?a.$g:a.Ed,a.Hb=a.tc?a.ti:a.Id,Zc(a.D,a.W&16?22:18)):(a.Ia=0,a.ub=57344,a.Fa=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,Zc(a.D,16))}function td(a){var b=a.S;b&57344||(b=b&-3199|a.zb<<5|a.rb<<1);return b} +function ud(a,b){b&=-3073;if(a.S!=b){b&57344&&!(a.S&57344)&&(a.vc=a.O>>16&65535,a.wc=a.O&65535);a.S=b;a.zb=(b&96)>>5;a.rb=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.yb!=c&&(a.yb=c,xe(a))}}function vd(a){a.S&57344||(a.vc=a.O>>16&65535);a=a.vc;a&65280&&(a=(a<<8|a>>8)&65535);return a}function wd(a){a.S&57344||(a.wc=a.O&65535);return a.wc}function xd(a,b){1170>a.ka&&(b&=-49);a.W!=b&&(a.W=b,a.jb=b&16?4194303:262143,xe(a))} +function ye(a,b,c,d){a.Vd=b;qc(a,b);Ad(a,0);a.D.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.aa?a.A.V||tc(a):a.A.qa=!0}else a.F&&a.A.aa?a.ba()||a.J.A.reset||(ie(a.F),H(a.J,-1)):!1===c&&a.ba();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; +h.save=function(){var a=new G(this);a.set(0,[this.g,this.ta,this.X,this.M,this.B,this.Ha,this.xc,this.P,this.uc,this.ob,this.Ga,this.zb,this.rb,this.ib,this.i,this.O,this.bb,this.Ac,this.Dc]);a.set(1,[zd(this),td(this),vd(this),wd(this),this.W]);a.set(2,[this.nb,this.mb,this.A.qa]);a.set(3,ze(this));a.set(4,se(this));return a.data()}; +h.restore=function(a){var b=ia(a[0]);this.g=b.next().value;this.ta=b.next().value;this.X=b.next().value;this.M=b.next().value;this.B=b.next().value;this.Ha=b.next().value;this.xc=b.next().value;this.P=b.next().value;this.uc=b.next().value;this.ob=b.next().value;this.Ga=b.next().value;this.zb=b.next().value;this.rb=b.next().value;this.ib=b.next().value;this.i=b.next().value;this.O=b.next().value;this.bb=b.next().value;this.Ac=b.next().value;this.Dc=b.next().value;b=a[1];Ad(this,b[0]);ud(this,b[1]); +this.vc=b[2];this.wc=b[3];xd(this,b[4]);b=a[2];this.nb=b[0];me(this,b[1]);this.A.qa=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>23)),a.b-=2);a.b-=3}function qc(a,b){a.g[7]=b&65535}function od(a,b,c,d){b={Fb:b,pb:c,message:d||0,name:Pb[b],next:null};a.mc.push(b);return b}function Ge(a,b){var c=a.R;if(c==b)a.R=b.next;else for(;c;){var d=c.next;if(d==b){c.next=d.next;break}c=d}a.R&&(a.i|=1)} function md(a,b){if(b){if(b!=a.R){var c=a.R;if(!c||c.pb<=b.pb)b.next=c,a.R=b;else{do{var d=c.next;if(!d||d.pb<=b.pb){b.next=d;c.next=b;break}c=d}while(c)}}a.i|=1;b.message&&z(a,b.message|8)&&C(a,"setIRQ(vector="+E(b.Fb)+",priority="+b.pb+")",!0,!0)}}function sd(a,b){b&&(Ge(a,b),b.message&&z(a,b.message|8)&&C(a,"clearIRQ(vector="+E(b.Fb)+",priority="+b.pb+")",!0,!0))}function ze(a){var b=[];for(a=a.R;a;)b.push(a.Fb),a=a.next;return b} -function He(a){return a.i&64?(a.sa(168,64,-6),!0):a.i&32?(a.sa(4,32,-5),!0):a.i&16?(a.sa(12,16,-7),!0):!1}function zd(a){return a.w=a.w&63728|De(a)|Ce(a)|Be(a)|Ae(a)}function Ad(a,b){b&=a.ee;a.I=b<<12;a.L=~b&4;a.G=b<<14;a.C=b<<16;if((b^a.w)&a.de)for(var c=a.qa.length;0<=--c;){var d=a.g[c];a.g[c]=a.qa[c];a.qa[c]=d}a.N=b>>14&3;c=a.w>>14&3;a.N!=c&&(a.W[c]=a.g[6],a.g[6]=a.W[a.N]);a.w=b;a.i&=-3;a.i|=a.R?2:1}function yd(a,b){if(b&=65024){var c=b>>9;do b+=34;while(c>>=1);a.i|=1}a.cb=b} -h.Ea=function(a){this.I=this.L=a;this.G=0};h.rb=function(a,b){this.I=this.L=this.C=a;this.G=b||0};function Ie(a,b){a.I=a.L=a.C=b;a.G=a.I^a.C>>1}function Je(a,b,c,d){a.I=a.L=a.C=b;a.G=(c^d)&(d^b)} -h.sa=function(a,b,c){if(!this.pa){0>this.bb?this.bb=zd(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Ad(this,e&-12289|this.bb>>2&12288);Ke(this,this.bb);Ke(this,this.g[7]);qc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ca();if(-4<=c)throw a;}}; -function Le(a){var b=Me(a),c=Me(a);a.w&49152&&(c=c&-225|a.w&63712);qc(a,b);Ad(a,c);a.i&=-17}function Ne(a,b){var c=b>>13&31;31>c&&(b=a.U&32?a.Ha[c]+(b&8191)&4194303:b&-3932161);return b} -function Oe(a,b,c){var d=[];if(c){c=Ne(a,b);var e=b>>13&31;d.push(c);d.push(e);a.U&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.zb){var e=a.N<<1,f=b>>13;7>13;a.U&a.Xd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.kb;3932160<=f&&(f=Ne(a,f));if(a.pa)return f;f>=a.Sd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& -(g|=16384));a.B[a.N][d]=e;if(f!=(4194170&a.kb)||a.N)a.Ab=a.N,a.sb=d;g&&(g&57344&&(0<=a.bb&&(g|=128),a.S&57344||(g|=a.S&4096|a.Ab<<5|a.sb<<1,ud(a,a.S&-61695|g&61694)),a.sa(168,64,-2)),a.S&61440||!(f<(4191360&a.kb)||f>(4194239&a.kb))||(a.S|=4096,a.S&512&&(a.i|=64)));return f}function Me(a){var b=a.oa(a.g[6]|a.Ia);a.g[6]=a.g[6]+2&65535;return b}function Ke(a,b){var c=a.g[6]-2&65535;a.g[6]=c;a.O=a.O&65535|(a.O&-65536)<<8|16121856;a.i&256||a.Lb(4,-2,c);a.Hb(c,b)} -function Pe(a,b,c,d){var e,f,g=d&8?0:a.Ia;switch(b){case 0:return a.sa(4,0,-3),0;case 1:return 6==c&&a.Lb(d,0,a.g[6]),a.b-=3,7==c?a.g[c]:a.g[c]|g;case 2:f=2;e=a.g[c];6==c&&a.Lb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.g[c];7!=c&&(e|=g);e=a.oa(e);e|=g;a.b-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.g[c]+f&65535;6==c&&a.Lb(d,f,e);7!=c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.g[c]-2&65535;7!=c&&(e|=g);e=a.oa(e)|g;a.b-=8;break;case 6:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,6==c&&a.Lb(d, -0,e),a.b-=6,e|g;case 7:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.xa&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.xa&&(c<=this.xa-32?this.sa(4,0,-4):(this.P|=8,this.i|=32)))};h.oe=function(a){this.F&&Sd(this.F,a,1);return this.ad(a)};h.te=function(a){this.F&&Sd(this.F,a,2);return this.cd(a)}; -h.ze=function(a,b){this.F&&Td(this.F,a,1);this.dd(a,b)};h.Ae=function(a,b){this.F&&Td(this.F,a,2);this.jd(a,b)};function Cc(a,b){a.pa++;b=a.D.Bc(Ac(a,b,2));a.pa--;return b}function Qe(a,b){(b?--a.tc:--a.sc)||xe(a)}h.Gf=function(a,b,c){return Pe(this,a,b,c)};h.se=function(a,b,c){return Ac(this,Pe(this,a,b,c),c)};h.ye=function(a){return this.D.Bc(this.jb=a)};h.Zg=function(a){this.F&&Sd(this.F,a,2);return this.ye(a)};h.Dd=function(a){return this.D.Bc(this.jb=Ac(this,a,2))}; -h.$g=function(a){this.F&&Sd(this.F,a,2);return this.Dd(a)};h.De=function(a,b){this.D.ac(this.jb=a,b)};h.si=function(a,b){this.F&&Td(this.F,a,2);this.De(a,b)};h.Hd=function(a,b){this.D.ac(this.jb=Ac(this,a,4),b)};h.ti=function(a,b){this.F&&Td(this.F,a,2);this.Hd(a,b)};function Re(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Pe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.W[a.w>>12&3];return c} -function Se(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Pe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Ac(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.W[a.w>>12&3]=d}function Te(a,b){b>>=6;var c=a.Y=b&7;return(b=a.X=(b&56)>>3)?a.jc(a.Ga(b,c,3)):a.g[c+a.zc]&a.Yd}function Ue(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.X=(b&56)>>3)?c=a.kc(a.Ga(b,d,2)):c=a.g[d+a.zc];return c}function Ve(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Pe(a,b,c,8)} -function We(a,b){var c=a.j=b&7;return(b=a.u=(b&56)>>3)?a.jc(a.Ga(b,c,3)):a.g[c]&255}function Xe(a,b){var c,d=a.j=b&7;(b=a.u=(b&56)>>3)?c=a.kc(a.Ga(b,d,2)):c=a.g[d];return c}function Ye(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Wc=a.Ga(b,e,7),c=0>c?a.g[-c-1]&255:c,a.Tc(e,d.call(a,c,a.jc(e))),e&1&&a.b--):(b=a.g[e],c=0>c?a.g[-c-1]&255:c,a.g[e]=b&65280|d.call(a,c,b&255))} -function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Ga(b,e,6),a.lc(e,d.call(a,0>c?a.g[-c-1]:c,a.kc(e)))):a.g[e]=d.call(a,0>c?a.g[-c-1]:c,a.g[e])}function Ze(a,b,c,d,e){var f=a.j=b&7;(b=a.u=(b&56)>>3)?(d=a.Ga(b,f,5),e.call(a,(c=0>c?a.g[-c-1]&255:c)<<8),a.Tc(d,c),d&1&&a.b--):(c?(c=0>c?a.g[-c-1]&255:c,a.g[f]=a.g[f]&~d|c<<24>>24&d):a.g[f]&=~d,e.call(a,c<<8))} -function $e(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Ga(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} -h.Cc=function(a){this.A.complete=!0;var b=this.F?af(this.F)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.mb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(bf(this.F,this.g[7],c)){this.ca();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.cb&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.sa(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.cb||(this.i&=-3)}else this.i& -1&&this.i++;if(a){if(this.i&4&&bf(this.F,this.g[7],c)){this.ca();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ca();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.Rd(f)}while(0>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Ea(a);return a}function Ff(a,b){a=b&~a;this.Ea(a<<8);return a} -function Gf(a,b){a|=b;this.Ea(a);return a}function Hf(a,b){a|=b;this.Ea(a<<8);return a}function If(a,b){a=~b|65536;this.rb(a);return a&65535}function Jf(a,b){a=~b|256;this.rb(a<<8);return a&255}function Kf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Lf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Mf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Nf(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} -function Of(a,b){a=-b;this.rb(a,a&b&32768);return a&65535}function Pf(a,b){a=-b;this.rb(a<<8,(a&b&128)<<8);return a&255}function Qf(a,b){a=b<<1|this.C>>16&1;Ie(this,a);return a&65535}function Rf(a,b){a=b<<1|this.C>>16&1;Ie(this,a<<8);return a&255}function Sf(a,b){a=(this.C&65536|b)>>1|b<<16;Ie(this,a);return a&65535}function Tf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Ie(this,a<<8);return a&255}function Uf(a,b){var c=b-a;Je(this,c,a,b);return c&65535} -function Vf(a,b){var c=b-a;Je(this,c<<8,a<<8,b<<8);return c&255}function Wf(a,b){this.I=this.L=b&65280;this.G=this.C=0;return(b<<8|b>>8)&65535}function Xf(a,b){a^=b;this.Ea(a);return a&65535}function Yf(a){P(this,a,Ue(this,a),yf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)} +function He(a){return a.i&64?(a.ra(168,64,-6),!0):a.i&32?(a.ra(4,32,-5),!0):a.i&16?(a.ra(12,16,-7),!0):!1}function zd(a){return a.w=a.w&63728|De(a)|Ce(a)|Be(a)|Ae(a)}function Ad(a,b){b&=a.fe;a.I=b<<12;a.L=~b&4;a.G=b<<14;a.C=b<<16;if((b^a.w)&a.ee)for(var c=a.ta.length;0<=--c;){var d=a.g[c];a.g[c]=a.ta[c];a.ta[c]=d}a.N=b>>14&3;c=a.w>>14&3;a.N!=c&&(a.X[c]=a.g[6],a.g[6]=a.X[a.N]);a.w=b;a.i&=-3;a.i|=a.R?2:1}function yd(a,b){if(b&=65024){var c=b>>9;do b+=34;while(c>>=1);a.i|=1}a.ob=b} +h.Da=function(a){this.I=this.L=a;this.G=0};h.qb=function(a,b){this.I=this.L=this.C=a;this.G=b||0};function Ie(a,b){a.I=a.L=a.C=b;a.G=a.I^a.C>>1}function Je(a,b,c,d){a.I=a.L=a.C=b;a.G=(c^d)&(d^b)} +h.ra=function(a,b,c){if(!this.pa){0>this.bb?this.bb=zd(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Ad(this,e&-12289|this.bb>>2&12288);Ke(this,this.bb);Ke(this,this.g[7]);qc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ba();if(-4<=c)throw a;}}; +function Le(a){var b=Me(a),c=Me(a);a.w&49152&&(c=c&-225|a.w&63712);qc(a,b);Ad(a,c);a.i&=-17}function Ne(a,b){var c=b>>13&31;31>c&&(b=a.W&32?a.Ha[c]+(b&8191)&4194303:b&-3932161);return b} +function Oe(a,b,c){var d=[];if(c){c=Ne(a,b);var e=b>>13&31;d.push(c);d.push(e);a.W&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.yb){var e=a.N<<1,f=b>>13;7>13;a.W&a.Yd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.jb;3932160<=f&&(f=Ne(a,f));if(a.pa)return f;f>=a.Td&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& +(g|=16384));a.B[a.N][d]=e;if(f!=(4194170&a.jb)||a.N)a.zb=a.N,a.rb=d;g&&(g&57344&&(0<=a.bb&&(g|=128),a.S&57344||(g|=a.S&4096|a.zb<<5|a.rb<<1,ud(a,a.S&-61695|g&61694)),a.ra(168,64,-2)),a.S&61440||!(f<(4191360&a.jb)||f>(4194239&a.jb))||(a.S|=4096,a.S&512&&(a.i|=64)));return f}function Me(a){var b=a.oa(a.g[6]|a.Ia);a.g[6]=a.g[6]+2&65535;return b}function Ke(a,b){var c=a.g[6]-2&65535;a.g[6]=c;a.O=a.O&65535|(a.O&-65536)<<8|16121856;a.i&256||a.Lb(4,-2,c);a.Hb(c,b)} +function Pe(a,b,c,d){var e,f,g=d&8?0:a.Ia;switch(b){case 0:return a.ra(4,0,-3),0;case 1:return 6==c&&a.Lb(d,0,a.g[6]),a.b-=3,7==c?a.g[c]:a.g[c]|g;case 2:f=2;e=a.g[c];6==c&&a.Lb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.g[c];7!=c&&(e|=g);e=a.oa(e);e|=g;a.b-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.g[c]+f&65535;6==c&&a.Lb(d,f,e);7!=c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.g[c]-2&65535;7!=c&&(e|=g);e=a.oa(e)|g;a.b-=8;break;case 6:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,6==c&&a.Lb(d, +0,e),a.b-=6,e|g;case 7:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.Ga&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.Ga&&(c<=this.Ga-32?this.ra(4,0,-4):(this.P|=8,this.i|=32)))};h.pe=function(a){this.F&&$d(this.F,a,1);return this.ad(a)};h.te=function(a){this.F&&$d(this.F,a,2);return this.cd(a)}; +h.ze=function(a,b){this.F&&ae(this.F,a,1);this.dd(a,b)};h.Ae=function(a,b){this.F&&ae(this.F,a,2);this.jd(a,b)};function Cc(a,b){a.pa++;b=a.D.Bc(Ac(a,b,2));a.pa--;return b}function Qe(a,b){(b?--a.tc:--a.sc)||xe(a)}h.Gf=function(a,b,c){return Pe(this,a,b,c)};h.se=function(a,b,c){return Ac(this,Pe(this,a,b,c),c)};h.ye=function(a){return this.D.Bc(this.ib=a)};h.Zg=function(a){this.F&&$d(this.F,a,2);return this.ye(a)};h.Ed=function(a){return this.D.Bc(this.ib=Ac(this,a,2))}; +h.$g=function(a){this.F&&$d(this.F,a,2);return this.Ed(a)};h.De=function(a,b){this.D.ac(this.ib=a,b)};h.si=function(a,b){this.F&&ae(this.F,a,2);this.De(a,b)};h.Id=function(a,b){this.D.ac(this.ib=Ac(this,a,4),b)};h.ti=function(a,b){this.F&&ae(this.F,a,2);this.Id(a,b)};function Re(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Pe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.X[a.w>>12&3];return c} +function Se(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Pe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Ac(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.X[a.w>>12&3]=d}function Te(a,b){b>>=6;var c=a.Y=b&7;return(b=a.U=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c+a.zc]&a.Zd}function Ue(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.U=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d+a.zc];return c}function Ve(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Pe(a,b,c,8)} +function We(a,b){var c=a.j=b&7;return(b=a.u=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c]&255}function Xe(a,b){var c,d=a.j=b&7;(b=a.u=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d];return c}function Ye(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Wc=a.Fa(b,e,7),c=0>c?a.g[-c-1]&255:c,a.Tc(e,d.call(a,c,a.jc(e))),e&1&&a.b--):(b=a.g[e],c=0>c?a.g[-c-1]&255:c,a.g[e]=b&65280|d.call(a,c,b&255))} +function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,6),a.lc(e,d.call(a,0>c?a.g[-c-1]:c,a.kc(e)))):a.g[e]=d.call(a,0>c?a.g[-c-1]:c,a.g[e])}function Ze(a,b,c,d,e){var f=a.j=b&7;(b=a.u=(b&56)>>3)?(d=a.Fa(b,f,5),e.call(a,(c=0>c?a.g[-c-1]&255:c)<<8),a.Tc(d,c),d&1&&a.b--):(c?(c=0>c?a.g[-c-1]&255:c,a.g[f]=a.g[f]&~d|c<<24>>24&d):a.g[f]&=~d,e.call(a,c<<8))} +function $e(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} +h.Cc=function(a){this.A.complete=!0;var b=this.F?af(this.F)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.lb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(bf(this.F,this.g[7],c)){this.ba();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.ob&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& +1&&this.i++;if(a){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.Sd(f)}while(0>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Da(a);return a}function Ff(a,b){a=b&~a;this.Da(a<<8);return a} +function Gf(a,b){a|=b;this.Da(a);return a}function Hf(a,b){a|=b;this.Da(a<<8);return a}function If(a,b){a=~b|65536;this.qb(a);return a&65535}function Jf(a,b){a=~b|256;this.qb(a<<8);return a&255}function Kf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Lf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Mf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Nf(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} +function Of(a,b){a=-b;this.qb(a,a&b&32768);return a&65535}function Pf(a,b){a=-b;this.qb(a<<8,(a&b&128)<<8);return a&255}function Qf(a,b){a=b<<1|this.C>>16&1;Ie(this,a);return a&65535}function Rf(a,b){a=b<<1|this.C>>16&1;Ie(this,a<<8);return a&255}function Sf(a,b){a=(this.C&65536|b)>>1|b<<16;Ie(this,a);return a&65535}function Tf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Ie(this,a<<8);return a&255}function Uf(a,b){var c=b-a;Je(this,c,a,b);return c&65535} +function Vf(a,b){var c=b-a;Je(this,c<<8,a<<8,b<<8);return c&255}function Wf(a,b){this.I=this.L=b&65280;this.G=this.C=0;return(b<<8|b>>8)&65535}function Xf(a,b){a^=b;this.Da(a);return a&65535}function Yf(a){P(this,a,Ue(this,a),yf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} function Zf(a){var b=Xe(this,a);a=a>>6&7;var c=this.g[a];c&32768&&(c|=4294901760);this.C=this.G=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.G=32768)}this.g[a]=c&65535;this.I=this.L=c;this.b-=(this.u?6:7)+b} function $f(a){var b=Xe(this,a);a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&=63;if(b&32){b=64-b;32>b-1;this.C=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.g[a|1]=d&65535;this.I=d>>16;this.L=d>>16|d;this.b-=(this.u?6:7)+b}function ag(a){Fe(this,a,!Ae(this))}function bg(a){Fe(this,a,Ae(this))} -function cg(a){P(this,a,Ue(this,a),Ef);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)}function dg(a){Ye(this,a,Te(this,a),Ff);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)}function eg(a){P(this,a,Ue(this,a),Gf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)}function fg(a){Ye(this,a,Te(this,a),Hf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)} -function gg(a){var b=Ue(this,a);a=Xe(this,a);this.Ea((0>b?this.g[-b-1]:b)&a);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.X?4:3)+(7==this.j?2:0)}function hg(a){var b=Te(this,a);a=We(this,a);this.Ea(((0>b?this.g[-b-1]&255:b)&a)<<8);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.X?4:3)+(7==this.j?2:0)}function ig(a){Fe(this,a,Ce(this))}function jg(a){Fe(this,a,!De(this)==!Be(this))}function kg(a){Fe(this,a,!Ce(this)&&!De(this)==!Be(this))}function lg(a){Fe(this,a,!Ae(this)&&!Ce(this))} -function mg(a){Fe(this,a,Ce(this)||!De(this)!=!Be(this))}function ng(a){Fe(this,a,Ae(this)||Ce(this))}function og(a){Fe(this,a,!De(this)!=!Be(this))}function pg(a){Fe(this,a,De(this))}function qg(a){Fe(this,a,!Ce(this))}function rg(a){Fe(this,a,!De(this))}function sg(){this.sa(12,0,-9)}function tg(a){Fe(this,a,!0)}function ug(a){Fe(this,a,!Be(this))}function vg(a){Fe(this,a,Be(this))}function wg(a){a&1&&(this.C=0);a&2&&(this.G=0);a&4&&(this.L=1);a&8&&(this.I=0);this.b-=5} -function xg(a){var b=Ue(this,a);a=Xe(this,a);var c=(b=0>b?this.g[-b-1]:b)-a;Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.X?4:3)+(7==this.j?2:0)}function yg(a){var b=Te(this,a);a=We(this,a);var c=(b=(0>b?this.g[-b-1]&255:b)<<8)-(a<<=8);Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.X?4:3)+(7==this.j?2:0)} -function zg(a){var b=Xe(this,a);if(b){a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.g[a]=d&65535,this.g[a|1]=c-d*b&65535,this.L=d>>16|d,this.I=d>>16):(this.G=32768,this.L=d>>15|d,this.I=c>>16,-1===b&&65534===this.g[a]&&(this.g[a]=this.g[a|1]=1));this.b-=53}else this.L=this.I=0,this.G=32768,this.C=65536,this.b-=7}function Ag(){this.sa(24,0,-9);this.b-=20} -function Bg(){this.w&49152?(this.P|=128,this.sa(4,0,-8)):(this.ta&&1120==this.ka&&this.ta.setData(this.g[0],!0),this.F?Cg(this.F):this.ca());this.b-=7}function Dg(){this.sa(16,0,-9);this.b-=20}var Eg=[0,7,7,10,7,11,9,13];function Fg(a){this.la=this.b;qc(this,Ve(this,a));this.b=this.la-Eg[this.u]}var Gg=[0,14,14,17,14,18,16,20];function Hg(a){this.la=this.b;var b=Ve(this,a);a=a>>6&7;Ke(this,this.g[a]);this.g[a]=this.g[7];qc(this,b);this.b=this.la-Gg[this.u]} -var Ig=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Jg(a){var b=Ue(this,a);this.la=this.b;$e(this,a,b,this.Ea);this.b=this.la-Ig[(this.X?8:0)+this.u]+(7!=this.j||this.u?0:2)}function Kg(a){var b=Te(this,a);Ze(this,a,b,65535,this.Ea);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)}var Lg=[7,13,13,17,14,18,17,21]; -function Mg(a){var b=Xe(this,a);a=a>>6&7;b=(b<<16>>16)*(this.g[a]<<16>>16);this.g[a]=b>>16&65535;this.g[a|1]=b&65535;b|=0;this.I=b>>16;this.L=this.I|b;this.G=0;this.C=-32768>b||32767>6;if(this.g[b]=this.g[b]-1&65535)qc(this,this.g[7]-((a&63)<<1)),this.b+=1;this.b-=6}function Tg(a){P(this,a,Ue(this,a),Uf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.X?5:3)+(7==this.j?2:0)}function Ug(a){P(this,a,0,Wf);this.b-=this.u?9:3+(7==this.j?2:0)}function Vg(){this.sa(28,0,-9)} -function Wg(){this.ta&&(this.ta.Fd(this.g[7],!0),this.ta.setData(this.g[0],!0));this.i|=8;Ee(this,-2);this.b-=3}function Xg(a){P(this,a,this.g[(a>>6&7)+this.zc],Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.F)b=this.F,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Cg(b)):b=!1;b||this.sa(8,0,-9)}function ve(a){Yg[a>>12].call(this,a)}function Zg(a){$g[a>>6&3].call(this,a)}function ah(a){bh[a>>6&3].call(this,a)}function ch(a){dh[a>>6&3].call(this,a)} +function cg(a){P(this,a,Ue(this,a),Ef);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function dg(a){Ye(this,a,Te(this,a),Ff);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function eg(a){P(this,a,Ue(this,a),Gf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function fg(a){Ye(this,a,Te(this,a),Hf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} +function gg(a){var b=Ue(this,a);a=Xe(this,a);this.Da((0>b?this.g[-b-1]:b)&a);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function hg(a){var b=Te(this,a);a=We(this,a);this.Da(((0>b?this.g[-b-1]&255:b)&a)<<8);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function ig(a){Fe(this,a,Ce(this))}function jg(a){Fe(this,a,!De(this)==!Be(this))}function kg(a){Fe(this,a,!Ce(this)&&!De(this)==!Be(this))}function lg(a){Fe(this,a,!Ae(this)&&!Ce(this))} +function mg(a){Fe(this,a,Ce(this)||!De(this)!=!Be(this))}function ng(a){Fe(this,a,Ae(this)||Ce(this))}function og(a){Fe(this,a,!De(this)!=!Be(this))}function pg(a){Fe(this,a,De(this))}function qg(a){Fe(this,a,!Ce(this))}function rg(a){Fe(this,a,!De(this))}function sg(){this.ra(12,0,-9)}function tg(a){Fe(this,a,!0)}function ug(a){Fe(this,a,!Be(this))}function vg(a){Fe(this,a,Be(this))}function wg(a){a&1&&(this.C=0);a&2&&(this.G=0);a&4&&(this.L=1);a&8&&(this.I=0);this.b-=5} +function xg(a){var b=Ue(this,a);a=Xe(this,a);var c=(b=0>b?this.g[-b-1]:b)-a;Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function yg(a){var b=Te(this,a);a=We(this,a);var c=(b=(0>b?this.g[-b-1]&255:b)<<8)-(a<<=8);Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)} +function zg(a){var b=Xe(this,a);if(b){a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.g[a]=d&65535,this.g[a|1]=c-d*b&65535,this.L=d>>16|d,this.I=d>>16):(this.G=32768,this.L=d>>15|d,this.I=c>>16,-1===b&&65534===this.g[a]&&(this.g[a]=this.g[a|1]=1));this.b-=53}else this.L=this.I=0,this.G=32768,this.C=65536,this.b-=7}function Ag(){this.ra(24,0,-9);this.b-=20} +function Bg(){this.w&49152?(this.P|=128,this.ra(4,0,-8)):(this.sa&&1120==this.ka&&this.sa.setData(this.g[0],!0),this.F?Cg(this.F):this.ba());this.b-=7}function Dg(){this.ra(16,0,-9);this.b-=20}var Eg=[0,7,7,10,7,11,9,13];function Fg(a){this.la=this.b;qc(this,Ve(this,a));this.b=this.la-Eg[this.u]}var Gg=[0,14,14,17,14,18,16,20];function Hg(a){this.la=this.b;var b=Ve(this,a);a=a>>6&7;Ke(this,this.g[a]);this.g[a]=this.g[7];qc(this,b);this.b=this.la-Gg[this.u]} +var Ig=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Jg(a){var b=Ue(this,a);this.la=this.b;$e(this,a,b,this.Da);this.b=this.la-Ig[(this.U?8:0)+this.u]+(7!=this.j||this.u?0:2)}function Kg(a){var b=Te(this,a);Ze(this,a,b,65535,this.Da);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}var Lg=[7,13,13,17,14,18,17,21]; +function Mg(a){var b=Xe(this,a);a=a>>6&7;b=(b<<16>>16)*(this.g[a]<<16>>16);this.g[a]=b>>16&65535;this.g[a|1]=b&65535;b|=0;this.I=b>>16;this.L=this.I|b;this.G=0;this.C=-32768>b||32767>6;if(this.g[b]=this.g[b]-1&65535)qc(this,this.g[7]-((a&63)<<1)),this.b+=1;this.b-=6}function Tg(a){P(this,a,Ue(this,a),Uf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function Ug(a){P(this,a,0,Wf);this.b-=this.u?9:3+(7==this.j?2:0)}function Vg(){this.ra(28,0,-9)} +function Wg(){this.sa&&(this.sa.Gd(this.g[7],!0),this.sa.setData(this.g[0],!0));this.i|=8;Ee(this,-2);this.b-=3}function Xg(a){P(this,a,this.g[(a>>6&7)+this.zc],Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.F)b=this.F,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Cg(b)):b=!1;b||this.ra(8,0,-9)}function ve(a){Yg[a>>12].call(this,a)}function Zg(a){$g[a>>6&3].call(this,a)}function ah(a){bh[a>>6&3].call(this,a)}function ch(a){dh[a>>6&3].call(this,a)} function eh(a){fh[a&15].call(this,a)}function gh(a){hh[a&15].call(this,a)}function ih(a){jh[a>>6&3].call(this,a)}function kh(a){lh[a>>6&3].call(this,a)}function mh(a){nh[a>>6&3].call(this,a)} -var Yg=[function(a){oh[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,Q,function(a){ph[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],oh=[function(a){qh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,Q,Q,Q],$g=[function(a){$e(this,a,0,this.rb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,If);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Mf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Kf);this.b-=this.u?9:3+(7==this.j?2:0)}],bh=[function(a){P(this,a,0,Of); -this.b-=this.u?11:6},function(a){P(this,a,Ae(this)?1:0,yf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Ae(this)?1:0,Uf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this,a);this.rb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],dh=[function(a){P(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Qf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Af);this.b-=this.u?9:3+(7==this.j?2:0)}],qh= +var Yg=[function(a){oh[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,Q,function(a){ph[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],oh=[function(a){qh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,Q,Q,Q],$g=[function(a){$e(this,a,0,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,If);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Mf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Kf);this.b-=this.u?9:3+(7==this.j?2:0)}],bh=[function(a){P(this,a,0,Of); +this.b-=this.u?11:6},function(a){P(this,a,Ae(this)?1:0,yf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Ae(this)?1:0,Uf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this,a);this.qb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],dh=[function(a){P(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Qf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Af);this.b-=this.u?9:3+(7==this.j?2:0)}],qh= [function(a){rh[a&15].call(this,a)},Q,Q,Q,Fg,Fg,Fg,Fg,Pg,Q,eh,gh,Ug,Ug,Ug,Ug],rh=[Bg,Wg,Qg,sg,Dg,Og,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q],fh=[Ng,function(){this.C=0;this.b-=5},function(){this.G=0;this.b-=5},wg,function(){this.L=1;this.b-=5},wg,wg,wg,function(){this.I=0;this.b-=5},wg,wg,wg,wg,wg,wg,wg],hh=[Ng,function(){this.C=65536;this.b-=5},function(){this.G=32768;this.b-=5},Rg,function(){this.L=0;this.b-=5},Rg,Rg,Rg,function(){this.I=32768;this.b-=5},Rg,Rg,Rg,Rg,Rg,Rg,Rg],ph=[rg,pg,lg,ng,ug,vg,ag,bg,Ag,Vg,ih,kh, -mh,Q,Q,Q],jh=[function(a){Ze(this,a,0,255,this.rb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Jf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Nf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Lf);this.b-=this.u?9:3+(7==this.j?2:0)}],lh=[function(a){Ye(this,a,0,Pf);this.b-=this.u?11:6},function(a){Ye(this,a,Ae(this)?1:0,zf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,Ae(this)?1:0,Vf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=We(this, -a);this.rb(a<<8);this.b-=this.u?4:3+(7==this.j?2:0)}],nh=[function(a){Ye(this,a,0,Tf);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Rf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Df);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Bf);this.b-=this.u?9:3+(7==this.j?2:0)}];function we(a){sh[a>>12].call(this,a)} -var sh=[function(a){th[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,function(a){uh[a>>8&15].call(this,a)},function(a){vh[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],th=[function(a){wh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,function(a){xh[a>>6&3].call(this,a)},Q,Q],xh=[function(a){a=this.g[7]+((a&63)<<1)&65535;var b=this.oa(a|this.Ia);qc(this,this.g[5]);this.g[6]=a+2&65535;this.g[5]=b;this.b-=8},function(a){a=Re(this,a,0);this.Ea(a);Ke(this,a);this.b-=11},function(a){var b=Me(this); -this.la=this.b;this.Ea(b);Se(this,a,0,b);this.b=this.la-Lg[this.u]},function(a){$e(this,a,De(this)?65535:0,this.Ea);this.b-=this.u?9:3+(7==this.j?2:0)}],wh=[function(a){yh[a&15].call(this,a)},Q,Q,Q,Fg,Fg,Fg,Fg,Pg,function(a){!(a&8)||1145>this.ka?Q.call(this,a):(this.w&49152||(this.w=this.w&-225|(a&7)<<5,this.i|=1,this.i&=-3),this.b-=5)},eh,gh,Ug,Ug,Ug,Ug],yh=[Bg,Wg,function(){Le(this);this.i|=this.w&16;this.b-=13},sg,Dg,Og,Qg,function(a){Q.call(this,a)},Q,Q,Q,Q,Q,Q,Q,Q],uh=[Mg,Mg,zg,zg,Zf,Zf,$f,$f, -Xg,Xg,Q,Q,Q,Q,Sg,Sg],vh=[rg,pg,lg,ng,ug,vg,ag,bg,Ag,Vg,ih,kh,mh,function(a){1145>this.ka?Q.call(this,a):zh[a>>6&3].call(this,a)},Q,Q],zh=[function(a){Q.call(this,a)},function(a){a=Re(this,a,65536);this.Ea(a);Ke(this,a);this.b-=11},function(a){var b=Me(this);this.la=this.b;this.Ea(b);Se(this,a,65536,b);this.b=this.la-Lg[this.u]},function(a){Q.call(this,a)}]; -function Ah(a){r.call(this,"ROM",a,128);this.ga=this.g=null;this.u=+a.addr;this.b=+a.size;this.w=!1;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.j=a.file;this.B=Oa(this.j);if(this.j){a=this.j;var b=Pa(this.B);"json"!=b&&"hex"!=b&&(a=db()+"/api/v1/dump?file="+this.j+"&format=bytes&decimal=true");var c=this;bb(a,null,!0,function(a,b,f){f?(c.T("Unable to load ROM resource (error "+f+": "+a+")"),c.j=null):(na(c.wb,a,b),(a=cb(a,b))?(c.g=a.da,c.ga=a.ga):c.j=null);Bh(c)})}}p(Ah,r); -h=Ah.prototype;h.Aa=function(a,b,c,d){this.D=b;this.f=c;this.F=d;Bh(this)};h.Da=function(){this.ga&&(this.F&&Ch(this.F,this.id,this.u,this.b,this.ga),delete this.ga);return!0};h.Ca=function(){return!0}; +mh,Q,Q,Q],jh=[function(a){Ze(this,a,0,255,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Jf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Nf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Lf);this.b-=this.u?9:3+(7==this.j?2:0)}],lh=[function(a){Ye(this,a,0,Pf);this.b-=this.u?11:6},function(a){Ye(this,a,Ae(this)?1:0,zf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,Ae(this)?1:0,Vf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=We(this, +a);this.qb(a<<8);this.b-=this.u?4:3+(7==this.j?2:0)}],nh=[function(a){Ye(this,a,0,Tf);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Rf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Df);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Bf);this.b-=this.u?9:3+(7==this.j?2:0)}];function we(a){sh[a>>12].call(this,a)} +var sh=[function(a){th[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,function(a){uh[a>>8&15].call(this,a)},function(a){vh[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],th=[function(a){wh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,function(a){xh[a>>6&3].call(this,a)},Q,Q],xh=[function(a){a=this.g[7]+((a&63)<<1)&65535;var b=this.oa(a|this.Ia);qc(this,this.g[5]);this.g[6]=a+2&65535;this.g[5]=b;this.b-=8},function(a){a=Re(this,a,0);this.Da(a);Ke(this,a);this.b-=11},function(a){var b=Me(this); +this.la=this.b;this.Da(b);Se(this,a,0,b);this.b=this.la-Lg[this.u]},function(a){$e(this,a,De(this)?65535:0,this.Da);this.b-=this.u?9:3+(7==this.j?2:0)}],wh=[function(a){yh[a&15].call(this,a)},Q,Q,Q,Fg,Fg,Fg,Fg,Pg,function(a){!(a&8)||1145>this.ka?Q.call(this,a):(this.w&49152||(this.w=this.w&-225|(a&7)<<5,this.i|=1,this.i&=-3),this.b-=5)},eh,gh,Ug,Ug,Ug,Ug],yh=[Bg,Wg,function(){Le(this);this.i|=this.w&16;this.b-=13},sg,Dg,Og,Qg,function(a){Q.call(this,a)},Q,Q,Q,Q,Q,Q,Q,Q],uh=[Mg,Mg,zg,zg,Zf,Zf,$f,$f, +Xg,Xg,Q,Q,Q,Q,Sg,Sg],vh=[rg,pg,lg,ng,ug,vg,ag,bg,Ag,Vg,ih,kh,mh,function(a){1145>this.ka?Q.call(this,a):zh[a>>6&3].call(this,a)},Q,Q],zh=[function(a){Q.call(this,a)},function(a){a=Re(this,a,65536);this.Da(a);Ke(this,a);this.b-=11},function(a){var b=Me(this);this.la=this.b;this.Da(b);Se(this,a,65536,b);this.b=this.la-Lg[this.u]},function(a){Q.call(this,a)}]; +function Ah(a){u.call(this,"ROM",a,128);this.ga=this.g=null;this.u=+a.addr;this.b=+a.size;this.w=!1;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.j=a.file;this.B=Oa(this.j);if(this.j){a=this.j;var b=Pa(this.B);"json"!=b&&"hex"!=b&&(a=db()+"/api/v1/dump?file="+this.j+"&format=bytes&decimal=true");var c=this;bb(a,null,!0,function(a,b,f){f?(c.T("Unable to load ROM resource (error "+f+": "+a+")"),c.j=null):(na(c.vb,a,b),(a=cb(a,b))?(c.g=a.ca,c.ga=a.ga):c.j=null);Bh(c)})}}p(Ah,u); +h=Ah.prototype;h.za=function(a,b,c,d){this.D=b;this.f=c;this.F=d;Bh(this)};h.Ca=function(){this.ga&&(this.F&&Ch(this.F,this.id,this.u,this.b,this.ga),delete this.ga);return!0};h.Ba=function(){return!0}; function Bh(a){if(!Ga(a)){if(a.j){if(!a.g||!a.D)return;a.b||(a.b=a.g.length);if(a.g.length!=a.b)Ea(a,"ROM size ("+F(a.g.length,8,!0)+") does not match specified size ("+F(a.b,8,!0)+")");else{var b;a:{b=a.u;if(57344<=b&&b<57344+Gc){var c={},c=(c[b]=[Ah.prototype.Jg,Ah.prototype.$h,null,null,null,a.b>>1],c);if(Xb(a.D,a,c)){a.status("Added "+a.b+"-byte ROM at "+E(b));b=a.w=!0;break a}}else if(Xc(a.D,b,a.b,Hd)){for(c=0;c>>f.g;0>>=f.g;0>>a.g;0=b.length){C(a,"invalid block at offset "+Na(n),4096);break}for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,m=m+((q&255)+(q>>8)+(t&255)+(t>>8)),u=l,D=q-=6;0=b.length){C(a,"insufficient data for block at offset "+Na(n),4096); -break}m+=b[l++]&255;if(m&255){C(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+Na(n),4096);break}if(D)for(C(a,"loading "+Na(D)+" bytes at "+Na(t)+"-"+Na(t+D),4096);D--;)fd(a.D,t++,b[u++]&255);else t&1?g=!0:null==d&&(d=t),null!=d&&C(a,"starting address: "+Na(d),4096);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e=la.Id&&c<=la.xf&&(b=c-(la.Id-la.Fe));b&&(a.preventDefault&&a.preventDefault(),d.Oc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.He&&(b=la.Ge);d.Oc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +function Dh(a){u.call(this,"RAM",a);this.ga=this.g=null;this.i=+a.addr;this.j=+a.size;this.ya=a.load;this.xa=a.exec;null!=this.ya&&(this.ya=+this.ya);null!=this.xa&&(this.xa=+this.xa);this.u=!1;this.b=a.file;this.w=Oa(this.b);if(this.b){a=this.b;var b=Pa(this.w);"json"!=b&&"hex"!=b&&(a=db()+"/api/v1/dump?file="+this.b+"&format=bytes&decimal=true");var c=this;bb(a,null,!0,function(a,b,f){f?(c.T("Unable to load RAM resource (error "+f+": "+a+")"),c.b=null):(na(c.vb,a,b),(a=cb(a,b))?(c.g=a.ca,c.ga=a.ga, +null==c.ya&&(c.ya=a.ya),null==c.xa&&(c.xa=a.xa)):c.b=null);Eh(c)})}}p(Dh,u);Dh.prototype.za=function(a,b,c,d){this.D=b;this.f=c;this.F=d;Eh(this)};Dh.prototype.Ca=function(a,b){this.ga&&(this.F&&Ch(this.F,this.id,this.i,this.j,this.ga),delete this.ga);b||this.reset();return!0};Dh.prototype.Ba=function(){return!0}; +function Eh(a){if(a.D&&(!a.u&&a.j&&(Xc(a.D,a.i,a.j,hd)?a.u=!0:a.j=0),!Ga(a))){if(!a.u)v("No RAM allocated");else if(a.b){if(!a.g||!a.D)return;Fh(a,a.g,a.ya,a.xa,a.i)?a.status('Loaded image "'+a.w+'"'):a.T('Error loading image "'+a.w+'"')}y(a)}} +Dh.prototype.reset=function(){if(this.u){for(var a=this.D,b=this.i,c=this.j,d=b&a.i,b=b>>>a.g;0=b.length){C(a,"invalid block at offset "+Na(n),4096);break}for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,m=m+((q&255)+(q>>8)+(t&255)+(t>>8)),r=l,D=q-=6;0=b.length){C(a,"insufficient data for block at offset "+Na(n),4096); +break}m+=b[l++]&255;if(m&255){C(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+Na(n),4096);break}if(D)for(C(a,"loading "+Na(D)+" bytes at "+Na(t)+"-"+Na(t+D),4096);D--;)fd(a.D,t++,b[r++]&255);else t&1?g=!0:null==d&&(d=t),null!=d&&C(a,"starting address: "+Na(d),4096);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e=la.Jd&&c<=la.xf&&(b=c-(la.Jd-la.Fe));b&&(a.preventDefault&&a.preventDefault(),d.Oc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.He&&(b=la.Ge);d.Oc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oc(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1}; -h.Aa=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;var e=this;this.P=od(this.f,this.M?-1:48,4,1048576);this.R=ld(this.f,function(){var a;a=-1;e.i.length&&(a=e.i.shift()&255,C(e,"receiveByte("+F(a,2,!0)+")"),e.L&&97<=a&&122>a&&(a-=32),nd(e.f,e.R,1E3/Math.round(e.S/10)));0<=a&&(e.C=a,e.b&128?e.C|=49152:e.b|=128,e.b&64&&md(c,e.P))});this.N=od(this.f,this.M?-1:52,4,1048576);this.X=ld(this.f,function(){e.g|=128;e.g&64&&md(c,e.N)});Xb(b,this,Jh,this.M?64832+8*(this.M-1)-65392:0);ec(b,this.reset.bind(this)); -y(this)};h.ue=function(a){if(!this.j){var b=fe(this.J,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Mb)return;c=Ya(c[1]);if(this.j=ua(c)){var e=this.j.exports;if(e){var f=e.connect;f&&f.call(this.j,this.I);if(this.G=e.receiveData){this.I=a;this.O=e.receiveStatus;this.status("Connected "+this.wb+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; -h.Da=function(a,b){if(!b)if(this.ue(this.I),!a)this.reset();else if(!this.restore(a))return!1;return!0};h.Ca=function(a){return a?this.save():!0};h.reset=function(){Kh(this)};h.save=function(){var a=new G(this);a.set(0,[this.C,this.b,this.g,this.i]);return a.data()};h.restore=function(a){return Kh(this,a[0])};function Kh(a,b){b||(b=[0,8192,128,a.i]);b=ia(b);a.C=b.next().value;a.b=b.next().value;a.g=b.next().value;a.i=b.next().value;return!0} +h.za=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;var e=this;this.P=od(this.f,this.M?-1:48,4,1048576);this.R=ld(this.f,function(){var a;a=-1;e.i.length&&(a=e.i.shift()&255,C(e,"receiveByte("+F(a,2,!0)+")"),e.L&&97<=a&&122>a&&(a-=32),nd(e.f,e.R,1E3/Math.round(e.S/10)));0<=a&&(e.C=a,e.b&128?e.C|=49152:e.b|=128,e.b&64&&md(c,e.P))});this.N=od(this.f,this.M?-1:52,4,1048576);this.X=ld(this.f,function(){e.g|=128;e.g&64&&md(c,e.N)});Xb(b,this,Jh,this.M?64832+8*(this.M-1)-65392:0);ec(b,this.reset.bind(this)); +y(this)};h.ue=function(a){if(!this.j){var b=fe(this.J,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Mb)return;c=Ya(c[1]);if(this.j=ua(c)){var e=this.j.exports;if(e){var f=e.connect;f&&f.call(this.j,this.I);if(this.G=e.receiveData){this.I=a;this.O=e.receiveStatus;this.status("Connected "+this.vb+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +h.Ca=function(a,b){if(!b)if(this.ue(this.I),!a)this.reset();else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.reset=function(){Kh(this)};h.save=function(){var a=new G(this);a.set(0,[this.C,this.b,this.g,this.i]);return a.data()};h.restore=function(a){return Kh(this,a[0])};function Kh(a,b){b||(b=[0,8192,128,a.i]);b=ia(b);a.C=b.next().value;a.b=b.next().value;a.g=b.next().value;a.i=b.next().value;return!0} h.Oc=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.W||8,c=a-this.B%a,this.W&&(b=Xa("",c)));this.U&&!this.B&&c&&(b=String.fromCharCode(this.U)+b);this.u.value+=b;this.u.scrollTop=this.u.scrollHeight;this.B+=c}}else if(null!=this.w){if(10==a||1024<=this.w.length)this.v(this.w), this.w="";10!=a&&(this.w+=String.fromCharCode(a))}nd(this.f,this.X,1E3/Math.round(this.Y/10));this.g&=-129};var Ih="buffer",Lh={},Jh=(Lh[65392]=[null,null,Hh.prototype.wg,Hh.prototype.Nh,"RCSR"],Lh[65394]=[null,null,Hh.prototype.vg,Hh.prototype.Mh,"RBUF"],Lh[65396]=[null,null,Hh.prototype.eh,Hh.prototype.vi,"XCSR"],Lh[65398]=[null,null,Hh.prototype.dh,Hh.prototype.ui,"XBUF"],Lh);rb(function(){for(var a=x(document,w,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.H[b]=c,!0;case "readTape":e=Ph;case "loadTape":return e||(e=Qh),this.H[b]=c,c.onclick= function(){var a=d.H.listTapes;a&&Rh(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Rh(d,Oa(b,!0),b,Qh,a)}return!1};return!0;case Sh:return this.H[b]=c,!0}return!1}; -h.Aa=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;this.I=Th(a);var e=this;if(a=Mh(this,fe(this.J,"autoMount")))for(var f in a)"PTR"==f&&(this.N[f]=a[f]);this.G=od(this.f,56,4,4096);this.S=ld(this.f,function(){1!=(e.b&32769)||e.b&128||(e.ic.indexOf("/api/v1/dump")&&(e=Pa(c),f="json"==e||"gz"==e?encodeURI(c):db()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!bb(f,null,!0,function(e,f,g){var k=0>g&&!!a.J&&!a.J.A.aa;g?a.T('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.wb,e,f),(e=cb(e,f))&&di(a,b,c,d, -e.da,e.za,e.ya));a.A.fb=!1;a.g&&(a.g--,a.g||y(a));ai(a)})}function Wh(a,b,c,d){if((a=a.H.listTapes)&&a.options){for(var e=0;ec.indexOf("/api/v1/dump")&&(e=Pa(c),f="json"==e||"gz"==e?encodeURI(c):db()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!bb(f,null,!0,function(e,f,g){var k=0>g&&!!a.J&&!a.J.A.aa;g?a.T('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.vb,e,f),(e=cb(e,f))&&di(a,b,c,d, +e.ca,e.ya,e.xa));a.A.eb=!1;a.g&&(a.g--,a.g||y(a));ai(a)})}function Wh(a,b,c,d){if((a=a.H.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.b=Array(a.Z);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Pa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Qa(c,"/")&&(d="dir"),f=db()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.zd?"":e)+"&format=json"));return!!bb(f, +function gi(a,b,c){u.call(this,"Disk",{id:a.vb+".disk"+F(++hi,4)},8192);this.controller=a;this.J=a.J;this.F=a.F;this.u=b;this.Xa=b.name;this.Oa=this.Fd="";this.zd=b.zd;this.Z=this.ja=this.ea=this.ua=this.mode=0;this.b=[];this.i=null;this.j=!1;ii(this,c,b.Z,b.ja,b.ea,b.ua);this.g=this.w=null;y(this)}p(gi,u);h=gi.prototype;h.za=function(a,b,c,d){this.F=d}; +function ii(a,b,c,d,e,f){a.mode=b;a.Z=c;a.ja=d;a.ea=e;a.ua=f;a.b=[];if("preload"!=a.mode){b=Array(a.Z);for(c=0;c>2;var f=e=0,b=new DataView(b,0,d);a.b=Array(a.Z);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Pa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Qa(c,"/")&&(d="dir"),f=db()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.zd?"":e)+"&format=json"));return!!bb(f, null,!0,function(b,c,d){li(a,b,c,d)})} -function li(a,b,c,d){var e=null,f=0>d&&!!a.J&&!a.J.A.aa;a.j=!1;if(d)a.controller.T('Unable to load disk "'+a.Xa+'" (error '+d+": "+b+")",f);else{na(a.controller.wb,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ -c+")");if(k.length)if(1==k.length)v(k[0]);else{a.Z=k.length;a.ja=k[0].length;a.fa=k[0][0].length;var l=k[0][0][0];a.ua=l&&l.length||512;for(d=c=0;d>2,n=l.pattern;void 0===n&&(n=l.pattern=0);var q=l.data;if(void 0===q){var t=l.bytes;if(void 0!==t&&t.length){for(var u=m<<2,D=t.length;D>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.j)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.La?f=a.Wa+a.La&&(a.La+=f-(a.Wa+a.La)+1):(a.Wa=f,a.La=1);d[f]=d[f]&~(255<g)break;e|=g<d&&!!a.J&&!a.J.A.aa;a.j=!1;if(d)a.controller.T('Unable to load disk "'+a.Xa+'" (error '+d+": "+b+")",f);else{na(a.controller.vb,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ +c+")");if(k.length)if(1==k.length)v(k[0]);else{a.Z=k.length;a.ja=k[0].length;a.ea=k[0][0].length;var l=k[0][0][0];a.ua=l&&l.length||512;for(d=c=0;d>2,n=l.pattern;void 0===n&&(n=l.pattern=0);var q=l.data;if(void 0===q){var t=l.bytes;if(void 0!==t&&t.length){for(var r=m<<2,D=t.length;D>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.j)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.La?f=a.Va+a.La&&(a.La+=f-(a.Va+a.La)+1):(a.Va=f,a.La=1);d[f]=d[f]&~(255<g)break;e|=g<=this.b.length||l>=this.b[k].length||m>=this.b[k][l].length){c="sector (CHS="+k+":"+l+":"+m+") out of range ("+ -b+" changes applied)";b=-1;break}if(this.j){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.b[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.T("Unable to restore disk '"+this.Xa+": "+c);return b}; +b+" changes applied)";b=-1;break}if(this.j){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.b[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.T("Unable to restore disk '"+this.Xa+": "+c);return b}; h.toJSON=function(){var a;a=0;for(var b;b=ni(this,a++);)pi(b);a=JSON.stringify(this.b,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; -function pi(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var hi=0;function qi(a,b,c,d,e,f){r.call(this,a,b,c);this.N=ri(this,b.autoMount);this.M=0;this.R=d;this.S=e;this.U=f;this.P=d.Zc;this.g=Array(this.P);this.O=!ib("Mobi")&&window&&"FileReader"in window;this.B=[];this.Qa=null;this.exports={bootDisk:this.ke,loadDisk:this.Ad,selectDrive:this.ih,wait:this.mh}}p(qi,r); +function pi(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var hi=0;function qi(a,b,c,d,e,f){u.call(this,a,b,c);this.N=ri(this,b.autoMount);this.M=0;this.R=d;this.S=e;this.U=f;this.P=d.Zc;this.g=Array(this.P);this.O=!ib("Mobi")&&window&&"FileReader"in window;this.B=[];this.Qa=null;this.exports={bootDisk:this.le,loadDisk:this.Bd,selectDrive:this.ih,wait:this.mh}}p(qi,u); function ri(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){v(a.type+" auto-mount error: "+c.message+" ("+b+")"),b=null}return b||{}}h=qi.prototype; -h.va=function(a,b,c){var d=this;switch(b){case "listDisks":return this.H[b]=c,c.onchange=function(){si(d)},!0;case "descDisk":case "listDrives":return this.H[b]=c,c.onchange=function(){var a=Ka(c.value,10);null!=a&&ti(d,a)},!0;case "loadDisk":return this.H[b]=c,c.onclick=function(){d.Ad()},!0;case "bootDisk":return this.H[b]=c,c.onclick=function(){d.ke()},!0;case "saveDisk":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.onclick=function(){var a=d.H.listDrives;if(a&&a.options&&d.g)if(a= -d.g[Ka(a.value,10)||0])if(a=a.ea){var b;b="";for(var c=0,k;k=ni(a,c++);)for(var l=0,m=k.length;lg||9d||d>=this.g.length)return this.T("Unable to load the selected drive"),!1;if(!b)return Ti(this,d),!0;if(b==Qi)return this.T('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Ri){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Oa(b);this.status("Attempting to load "+b+' as "'+ -a+'"')}Xi(this,d,a,b,!1,c);return!0};h.ke=function(){var a,b=this.H.listDrives,b=b&&Ka(b.value,10);if(null==b||0>b||b>=this.g.length||!(a=this.g[b]))return this.T("Unable to boot the selected drive"),!1;if(!a.ea)return this.T("Load a disk into the drive first"),!1;ye(this.f,0,!0,b);return(a=this.Ub(a,a.If,a.Jf,a.Kf,a.Bf,0,2))?(this.T("Unable to read the boot sector ("+a+")"),!1):!0}; -function Xi(a,b,c,d,e,f){var g=-1,k=a.g[b];k.Oa.toLowerCase()!=d.toLowerCase()&&(g++,Ti(a,b,!0),k.Mc?a.T(a.type+" busy"):(k.Mc=!0,e&&(k.yd=!0,a.M++,z(a)&&C(a,"auto-loading disk: "+c)),k.Pb=!!f,ki(new gi(a,k,"preload"),c,d,f,a.ne)&&g++));return g} -h.ne=function(a,b,c,d,e){a.Mc=!1;b&&(b.Z>a.Z||b.ja>a.ja)&&(this.T('Disk "'+c+'" too large for drive '+(this.g[a.Tb].Qc||"---")),b=null);b?(a.ea=b,a.Xa=c,a.Oa=d,this.we(a.Tb),Yi(this,c,d,b),this.T('Loaded disk "'+c+'" in drive '+(this.g[a.Tb].Qc||"---"),a.yd||e),this.J&&pe(this.J)):a.Pb=!1;a.yd&&(a.yd=!1,--this.M||y(this));ti(this,a.Tb);a.ic&&(a.ic(),a.ic=null)}; +h.Bd=function(a,b,c){if(!a&&!b){var d=this.H.listDisks;d&&d.options&&(a=d.options[d.selectedIndex].text,b=d.value)}d=(d=this.H.listDrives)&&Ka(d.value,10);if(void 0===d||0>d||d>=this.g.length)return this.T("Unable to load the selected drive"),!1;if(!b)return Ti(this,d),!0;if(b==Qi)return this.T('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Ri){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Oa(b);this.status("Attempting to load "+b+' as "'+ +a+'"')}Xi(this,d,a,b,!1,c);return!0};h.le=function(){var a,b=this.H.listDrives,b=b&&Ka(b.value,10);if(null==b||0>b||b>=this.g.length||!(a=this.g[b]))return this.T("Unable to boot the selected drive"),!1;if(!a.da)return this.T("Load a disk into the drive first"),!1;ye(this.f,0,!0,b);return(a=this.Ub(a,a.If,a.Jf,a.Kf,a.Bf,0,2))?(this.T("Unable to read the boot sector ("+a+")"),!1):!0}; +function Xi(a,b,c,d,e,f){var g=-1,k=a.g[b];k.Oa.toLowerCase()!=d.toLowerCase()&&(g++,Ti(a,b,!0),k.Mc?a.T(a.type+" busy"):(k.Mc=!0,e&&(k.yd=!0,a.M++,z(a)&&C(a,"auto-loading disk: "+c)),k.Pb=!!f,ki(new gi(a,k,"preload"),c,d,f,a.oe)&&g++));return g} +h.oe=function(a,b,c,d,e){a.Mc=!1;b&&(b.Z>a.Z||b.ja>a.ja)&&(this.T('Disk "'+c+'" too large for drive '+(this.g[a.Tb].Qc||"---")),b=null);b?(a.da=b,a.Xa=c,a.Oa=d,this.we(a.Tb),Yi(this,c,d,b),this.T('Loaded disk "'+c+'" in drive '+(this.g[a.Tb].Qc||"---"),a.yd||e),this.J&&pe(this.J)):a.Pb=!1;a.yd&&(a.yd=!1,--this.M||y(this));ti(this,a.Tb);a.ic&&(a.ic(),a.ic=null)}; function Ni(a,b,c,d){if((a=a.H.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}h.mh=function(a){for(var b=0;b=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1);if(!n){m=S.be;break}q=0;++d>=a.fa&&(d=0,++c>=a.ja&&(c=0,++b))}var t,u;if(0>(t=a.read(n,q++))||0>(u=a.read(n,q++))){m=S.Fc;break}if(!k&&(zc(this.D,Ne(this.f,f),t|u<<8),kd(this.D))){m=S.ec;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; -h.Uc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.ea;var n=null,q;a||(m=S.Td,e=0);for(;e;){var t=Bc(this.D,Ne(this.f,f));if(kd(this.D)){m=S.ec;break}if(!n){if(b>=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1,!0);if(!n){m=S.be;break}q=0;++d>=a.fa&&(d=0,++c>=a.ja&&(c=0,++b))}if(k){var u,D;if(0>(u=a.read(n,q++))||0>(D=a.read(n,q++))){m=S.Fc;break}if(t!=(u|D<<8)){m=S.fe;break}}else if(!a.write(n,q++,t&255)||!a.write(n,q++,t>>8)){m=S.Fc;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; -h.Ze=function(a,b,c,d,e,f){this.u=f&65535;this.b=this.b&~R.Jb|f>>16-R.ma.Jb&R.Jb;this.w=65536-e&65535;this.j=this.j&~bj.rd|d&bj.rd;this.i|=a;cj(this);return!0};function cj(a){a.b&=~R.ib;a.i&&(a.i|=S.Je,a.b|=R.ib,a.i&S.ed&&(a.b|=R.ed),z(a)&&C(a,a.type+": ERROR: "+E(a.i)))}h.Bg=function(){return this.G};h.Sh=function(){};h.Cg=function(){return this.i};h.Th=function(){};h.yg=function(){return this.b&R.fc}; -h.Ph=function(a){this.b=this.b&~R.Ta|a&R.Ta;if(this.b&R.dc){a=!0;var b,c,d="",e=(this.j&bj.tb)>>bj.ma.tb,f=this.g[e],g,k,l,m,n,q;this.b&=~(R.Za|R.sd);this.i&=~S.qf;switch(c=this.b&R.wa){case dj.Ee:z(this)&&C(this,this.type+": CRESET("+e+")",!0);this.i=this.j=0;this.b=R.Za;break;case dj.Ue:d="RCHK";case dj.ub:d||(d="READ"),b=this.Ub;case dj.vd:d||(d="WCHK");case dj.hc:d||(d="WRITE");b||(b=this.Uc);g=(this.j&bj.bc)>>bj.ma.bc;k=(this.j&bj.hd)>>bj.ma.hd;l=this.j&bj.rd;m=65536-this.w&65535;n=(this.b&R.Jb)<< -16-R.ma.Jb|this.u;q=this.b&R.Qe?0:2;z(this)&&C(this,this.type+": "+d+"("+g+":"+k+":"+l+") "+E(n)+"--"+E(n+(m<<1)),!0,!0);if(g>=f.Z){this.i|=S.Ec;break}if(l>=f.fa){this.i|=S.Fc;break}a=b.call(this,f,g,k,l,m,n,q,c>=dj.vd,this.Ze.bind(this));break;case dj.Kc:g=(this.j&bj.bc)>>bj.ma.bc;z(this)&&C(this,this.type+": SEEK("+g+")",!0);g=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}var t,r;if(0>(t=a.read(n,q++))||0>(r=a.read(n,q++))){m=S.Fc;break}if(!k&&(zc(this.D,Ne(this.f,f),t|r<<8),kd(this.D))){m=S.ec;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Uc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.da;var n=null,q;a||(m=S.Ud,e=0);for(;e;){var t=Bc(this.D,Ne(this.f,f));if(kd(this.D)){m=S.ec;break}if(!n){if(b>=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1,!0);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}if(k){var r,D;if(0>(r=a.read(n,q++))||0>(D=a.read(n,q++))){m=S.Fc;break}if(t!=(r|D<<8)){m=S.ge;break}}else if(!a.write(n,q++,t&255)||!a.write(n,q++,t>>8)){m=S.Fc;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Ze=function(a,b,c,d,e,f){this.u=f&65535;this.b=this.b&~R.Jb|f>>16-R.ma.Jb&R.Jb;this.w=65536-e&65535;this.j=this.j&~bj.rd|d&bj.rd;this.i|=a;cj(this);return!0};function cj(a){a.b&=~R.hb;a.i&&(a.i|=S.Je,a.b|=R.hb,a.i&S.ed&&(a.b|=R.ed),z(a)&&C(a,a.type+": ERROR: "+E(a.i)))}h.Bg=function(){return this.G};h.Sh=function(){};h.Cg=function(){return this.i};h.Th=function(){};h.yg=function(){return this.b&R.fc}; +h.Ph=function(a){this.b=this.b&~R.Sa|a&R.Sa;if(this.b&R.dc){a=!0;var b,c,d="",e=(this.j&bj.sb)>>bj.ma.sb,f=this.g[e],g,k,l,m,n,q;this.b&=~(R.Za|R.sd);this.i&=~S.qf;switch(c=this.b&R.wa){case dj.Ee:z(this)&&C(this,this.type+": CRESET("+e+")",!0);this.i=this.j=0;this.b=R.Za;break;case dj.Ue:d="RCHK";case dj.tb:d||(d="READ"),b=this.Ub;case dj.vd:d||(d="WCHK");case dj.hc:d||(d="WRITE");b||(b=this.Uc);g=(this.j&bj.bc)>>bj.ma.bc;k=(this.j&bj.hd)>>bj.ma.hd;l=this.j&bj.rd;m=65536-this.w&65535;n=(this.b&R.Jb)<< +16-R.ma.Jb|this.u;q=this.b&R.Qe?0:2;z(this)&&C(this,this.type+": "+d+"("+g+":"+k+":"+l+") "+E(n)+"--"+E(n+(m<<1)),!0,!0);if(g>=f.Z){this.i|=S.Ec;break}if(l>=f.ea){this.i|=S.Fc;break}a=b.call(this,f,g,k,l,m,n,q,c>=dj.vd,this.Ze.bind(this));break;case dj.Kc:g=(this.j&bj.bc)>>bj.ma.bc;z(this)&&C(this,this.type+": SEEK("+g+")",!0);g(n=a.read(k,m++))||0>(q=a.read(k,m++))){g=gj.$a;break}zc(this.D,Ne(this.f,f),n|q<<8);if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(m>=a.ua&&(k=null,++d>=a.fa&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; -h.Uc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.ea;k=null;var m;a||(g=gj.$a,e=0);for(;e;){var n=Bc(this.D,Ne(this.f,f));if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=gj.$a;break}m=0}if(!a.write(k,m++,n&255)||!a.write(k,m++,n>>8)){g=gj.$a;break}if(m>=a.ua&&(k=null,++d>=a.fa&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; -h.df=function(a,b,c,d,e,f){this.C=f&65535;this.b=this.b&~U.Ya|f>>16-U.ma.Ya&U.Ya;this.u=f>>16&hj.ab;this.j=this.i=b<>U.ma.Ya;if(!(this.b&U.Za)){a=!0;var b,c="",d=this.g[(this.b&U.tb)>>U.ma.tb],e=d.ea,f,g,k;this.b&=~U.Fa;switch(this.b&U.wa){case jj.uf:this.w&kj.Qd&&(this.b&=U.Fa|U.wa|U.Ya);this.w=d.status|this.j&ij.Jc|(e&&512==e.Z?kj.Ne:0);break;case jj.Kc:(this.i&ij.Me)==ij.rf&&(b=this.i&ij.gc,c=(this.i&ij.tf)<<2,this.j=this.i&ij.sf?this.j+b:this.j-b,this.i=this.j=this.j&ij.gc|c);break;case jj.Ye:this.w=this.j;break;case jj.Ve:c="READ",b=this.Ub; -case jj.wf:c||(c="WRITE"),b||(b=this.Uc),f=this.i>>ij.ma.gc,g=this.i&ij.Jc?1:0,k=this.i&ij.$d,!e||f>=e.Z||k>=e.fa?this.b=this.b|gj.$a|U.ib:(a=65536-this.w&65535,e=(this.u&hj.ab)<<16|this.C,z(this)&&C(this,this.type+": "+c+"("+f+":"+g+":"+k+") "+E(e)+"--"+E(e+(a<<1)),!0,!0),a=b.call(this,d,f,g,k,a,e,2,!1,this.df.bind(this)))}a&&(this.b=this.b|U.Fa|U.Za,this.b&U.Ib&&md(this.f,this.Qa))}};h.Eg=function(){return this.C};h.Vh=function(a){this.C=a&lj.Ta};h.Hg=function(){return this.i}; +function Dd(a){qi.call(this,"RL11",a,131072,Nb,Nb.cf,fj);this.b=this.C=this.i=this.j=this.w=this.u=0}p(Dd,qi);h=Dd.prototype;h.Cb=function(a){a||(a=[U.Ea|U.Za,0,0,0,0,0]);a=ia(a);this.b=a.next().value;this.C=a.next().value;this.i=a.next().value;this.j=a.next().value;this.w=a.next().value;this.u=a.next().value;return!0};h.Rc=function(){return[this.b,this.C,this.i,this.j,this.w,this.u]}; +h.Ub=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=gj.$a,e=0);for(;e;){if(!k){k=a.seek(b,c,d+1);if(!k){g=gj.$a;break}m=0}var n,q;if(0>(n=a.read(k,m++))||0>(q=a.read(k,m++))){g=gj.$a;break}zc(this.D,Ne(this.f,f),n|q<<8);if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.Uc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=gj.$a,e=0);for(;e;){var n=Bc(this.D,Ne(this.f,f));if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=gj.$a;break}m=0}if(!a.write(k,m++,n&255)||!a.write(k,m++,n>>8)){g=gj.$a;break}if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.df=function(a,b,c,d,e,f){this.C=f&65535;this.b=this.b&~U.Ya|f>>16-U.ma.Ya&U.Ya;this.u=f>>16&hj.ab;this.j=this.i=b<>U.ma.Ya;if(!(this.b&U.Za)){a=!0;var b,c="",d=this.g[(this.b&U.sb)>>U.ma.sb],e=d.da,f,g,k;this.b&=~U.Ea;switch(this.b&U.wa){case jj.uf:this.w&kj.Rd&&(this.b&=U.Ea|U.wa|U.Ya);this.w=d.status|this.j&ij.Jc|(e&&512==e.Z?kj.Ne:0);break;case jj.Kc:(this.i&ij.Me)==ij.rf&&(b=this.i&ij.gc,c=(this.i&ij.tf)<<2,this.j=this.i&ij.sf?this.j+b:this.j-b,this.i=this.j=this.j&ij.gc|c);break;case jj.Ye:this.w=this.j;break;case jj.Ve:c="READ",b=this.Ub; +case jj.wf:c||(c="WRITE"),b||(b=this.Uc),f=this.i>>ij.ma.gc,g=this.i&ij.Jc?1:0,k=this.i&ij.ae,!e||f>=e.Z||k>=e.ea?this.b=this.b|gj.$a|U.hb:(a=65536-this.w&65535,e=(this.u&hj.ab)<<16|this.C,z(this)&&C(this,this.type+": "+c+"("+f+":"+g+":"+k+") "+E(e)+"--"+E(e+(a<<1)),!0,!0),a=b.call(this,d,f,g,k,a,e,2,!1,this.df.bind(this)))}a&&(this.b=this.b|U.Ea|U.Za,this.b&U.Ib&&md(this.f,this.Qa))}};h.Eg=function(){return this.C};h.Vh=function(a){this.C=a&lj.Sa};h.Hg=function(){return this.i}; h.Yh=function(a){this.i=a};h.Ig=function(){return this.w};h.Zh=function(a){this.w=a};h.Fg=function(){return this.u};h.Wh=function(a){this.u=a&hj.ab;this.b=this.b&~U.Ya|(this.u&3)<=m.Z){k=qj.Se;break}n=m.seek(b,c,d+1);if(!n){k=qj.pd;break}q=0;++d>=m.fa&&(d=0,++c>=m.ja&&(c=0,++b))}var t;if(0>(a=m.read(n,q++))||0>(t=m.read(n,q++))){k=qj.od;break}zc(this.D,Ne(this.f,f),a|t<<8);q>=m.ua&&(n=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; -function oj(a){var b=0,c=a.b&W.td?1:0,d=a.g[c],d=d&&d.ea,e=a.I&rj.ab,f=a.G&sj.ab;a.i&=~(tj.Ld|tj.Wd|tj.cc|tj.Fa);if(d)if(a.i|=tj.Fa,z(a)&&C(a,a.type+".readSector("+e+":0:"+f+")",!0,!0),c=d.seek(e,0,f,!0)){e=0;for(f=a.w.length;eg){b=qj.od;break}a.w[e++]=g}c.Ef&&(a.i|=tj.cc)}else b=qj.pd;else b=c?qj.gd:qj.fd;pj(a,b)} -h.Kg=function(a,b){a=this.b;if(!b)switch(a&=W.fc,this.j){case V.bd:case V.EMPTY:this.uthis.u&&(this.b|=W.eb)}return a}; -h.ai=function(a){this.b=this.b&~W.Ta|a&W.Ta;if(this.b&W.INIT)this.Db();else if(this.b&W.dc&&this.j==V.Kb)switch(this.j=this.b&W.wa,this.b&=~(W.dc|W.eb|W.DONE|W.ib),sd(this.f,this.Qa),z(this)&&C(this,this.type+".processCommand("+uj[this.j>>1]+")",!0,!0),this.j){case V.bd:case V.EMPTY:case V.ub:case V.hc:case V.Lc:this.u=0;break;case V.Xe:a=this.g[this.b&W.td?1:0];this.i&=~tj.Fa;a&&a.ea&&(this.i|=tj.Fa);this.C=this.i;pj(this);break;case V.We:this.C=this.L,pj(this)}else this.b&W.Ib?this.b&W.DONE&&md(this.f, -this.Qa):sd(this.f,this.Qa)};h.Lg=function(a,b){if(!b)switch(this.j){case V.EMPTY:this.b&W.eb&&(this.b&=~W.eb,this.C=this.w[this.u]&255,z(this)&&C(this,this.type+".readByte("+this.u+"): "+F(this.C,2,!0),!0,!0),++this.u>=this.w.length&&pj(this))}return this.C}; -h.bi=function(a){switch(this.j){case V.bd:this.b&W.eb&&(this.b&=~W.eb,this.w[this.u]=a&255,z(this)&&C(this,this.type+".writeByte("+this.u+","+F(a,2,!0)+")",!0,!0),++this.u>=this.w.length&&pj(this));break;case V.ub:case V.hc:case V.Lc:if(this.b&W.eb)switch(this.b&=~W.eb,this.u++){case 0:this.G=a;break;case 1:if(this.I=a,this.j==V.ub)oj(this);else{var b=this.j==V.Lc,c=0,d=this.b&W.td?1:0,e=this.g[d],e=e&&e.ea,f=this.I&rj.ab,g=this.G&sj.ab;this.i&=~(tj.Ld|tj.Wd|tj.cc|tj.Fa);if(e)if(this.i|=tj.Fa,z(this)&& -C(this,this.type+".writeSector("+f+":0:"+g+")",!0,!0),d=e.seek(f,0,g,!0))for(b&&(d.Ef=!0),b=0,f=this.w.length;b=m.Z){k=qj.Se;break}n=m.seek(b,c,d+1);if(!n){k=qj.pd;break}q=0;++d>=m.ea&&(d=0,++c>=m.ja&&(c=0,++b))}var t;if(0>(a=m.read(n,q++))||0>(t=m.read(n,q++))){k=qj.od;break}zc(this.D,Ne(this.f,f),a|t<<8);q>=m.ua&&(n=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +function oj(a){var b=0,c=a.b&W.td?1:0,d=a.g[c],d=d&&d.da,e=a.I&rj.ab,f=a.G&sj.ab;a.i&=~(tj.Md|tj.Xd|tj.cc|tj.Ea);if(d)if(a.i|=tj.Ea,z(a)&&C(a,a.type+".readSector("+e+":0:"+f+")",!0,!0),c=d.seek(e,0,f,!0)){e=0;for(f=a.w.length;eg){b=qj.od;break}a.w[e++]=g}c.Ef&&(a.i|=tj.cc)}else b=qj.pd;else b=c?qj.gd:qj.fd;pj(a,b)} +h.Kg=function(a,b){a=this.b;if(!b)switch(a&=W.fc,this.j){case V.bd:case V.EMPTY:this.uthis.u&&(this.b|=W.cb)}return a}; +h.ai=function(a){this.b=this.b&~W.Sa|a&W.Sa;if(this.b&W.INIT)this.Cb();else if(this.b&W.dc&&this.j==V.Kb)switch(this.j=this.b&W.wa,this.b&=~(W.dc|W.cb|W.DONE|W.hb),sd(this.f,this.Qa),z(this)&&C(this,this.type+".processCommand("+uj[this.j>>1]+")",!0,!0),this.j){case V.bd:case V.EMPTY:case V.tb:case V.hc:case V.Lc:this.u=0;break;case V.Xe:a=this.g[this.b&W.td?1:0];this.i&=~tj.Ea;a&&a.da&&(this.i|=tj.Ea);this.C=this.i;pj(this);break;case V.We:this.C=this.L,pj(this)}else this.b&W.Ib?this.b&W.DONE&&md(this.f, +this.Qa):sd(this.f,this.Qa)};h.Lg=function(a,b){if(!b)switch(this.j){case V.EMPTY:this.b&W.cb&&(this.b&=~W.cb,this.C=this.w[this.u]&255,z(this)&&C(this,this.type+".readByte("+this.u+"): "+F(this.C,2,!0),!0,!0),++this.u>=this.w.length&&pj(this))}return this.C}; +h.bi=function(a){switch(this.j){case V.bd:this.b&W.cb&&(this.b&=~W.cb,this.w[this.u]=a&255,z(this)&&C(this,this.type+".writeByte("+this.u+","+F(a,2,!0)+")",!0,!0),++this.u>=this.w.length&&pj(this));break;case V.tb:case V.hc:case V.Lc:if(this.b&W.cb)switch(this.b&=~W.cb,this.u++){case 0:this.G=a;break;case 1:if(this.I=a,this.j==V.tb)oj(this);else{var b=this.j==V.Lc,c=0,d=this.b&W.td?1:0,e=this.g[d],e=e&&e.da,f=this.I&rj.ab,g=this.G&sj.ab;this.i&=~(tj.Md|tj.Xd|tj.cc|tj.Ea);if(e)if(this.i|=tj.Ea,z(this)&& +C(this,this.type+".writeSector("+f+":0:"+g+")",!0,!0),d=e.seek(f,0,g,!0))for(b&&(d.Ef=!0),b=0,f=this.w.length;ba.u&&a.j.length&&(a.u=0);if(0>a.u||b!=a.j[a.u])a.j.splice(0,0,b),a.u=0;a.u--}else a.O?b="end":b=a.j[a.u+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ya(b.substring(c,f))),c=f+1}}return a} function yj(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} function zj(a,b,c){var d;if(b){b=Aj(a,b);for(var e=0,f=!1,g=b,k=[],l=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=8;d=F(c,0,!0)+" "+c+". "+E(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.v((null!=b?b+": ":"")+d);return e} -function Ej(a,b){if(b)return Dj(a,b,a.S[b]);var c=0;for(b in a.S)Dj(a,b,a.S[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Fj(a){wj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.xa=X();this.N=X();this.B=[];this.g=this.L=this.C=[];Gj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Hj(this);this.F=this;this.ka={};this.ha=this.je=0;this.R=null;this.M=[];Ij(this,a.messages);this.ta=a.commands;this.Ja=Jj;this.W=[];this.I=0;this.Ka=this.qa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.b=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return ke(b,a)}):void 0===global[w]&&(global[w]= -function(a){return ke(b,a)})}p(Fj,wj);function Kj(a){a=a&&a.K;null==a&&(a=-1);return a}function X(a,b,c){return{K:void 0===a?null:a,Ma:void 0===b?!1:b,Va:!1,Ba:c}}h=Fj.prototype;h.Fd=function(a,b){a.K=b;a.Va=!1;a.Ba=void 0;return a};function Lj(a){return[a.K,a.Ma,a.Ba,a.Va,a.Pc]}function Mj(a,b){var c=X(b[0],b[1],b[2]);c.Va=b[3];b[4]&&(c.ge=xj(a,c.Pc=b[4]));return c} -h.Aa=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.b=a.i;(a=fe(a,"messages"))&&Ij(this,a);1140>this.f.ka&&(this.W=this.W.concat(Nj));1145>this.f.ka&&(this.W=this.W.concat(Oj));qd(this,16,function(a){a:{var b=d.D.b,c=a[0],e=a=0,l=b.length;if(c){a=Kj(Pj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.D.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): +function Bj(a,b,c,d){var e;null!=b?(e=a.re(b),0<=e?e=a.Ad(e):(e=a.S[b],null==e&&(e=Ka(b,a.Aa))),null!=e||d||a.v("invalid "+(c?c:"value")+": "+b)):d||a.v("missing "+(c||"value"));return e}function Dj(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var f=4,g="";if(!f||4>=8;d=F(c,0,!0)+" "+c+". "+E(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.v((null!=b?b+": ":"")+d);return e} +function Ej(a,b){if(b)return Dj(a,b,a.S[b]);var c=0;for(b in a.S)Dj(a,b,a.S[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Fj(a){wj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.Fa=X();this.N=X();this.B=[];this.b=this.L=this.C=[];Gj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Hj(this);this.F=this;this.ka={};this.ha=this.ke=0;this.R=null;this.M=[];Ij(this,a.messages);this.ta=a.commands;this.Ja=Jj;this.W=[];this.I=0;this.Ka=this.sa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.g=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return ke(b,a)}):void 0===global[w]&&(global[w]= +function(a){return ke(b,a)})}p(Fj,wj);function Kj(a){a=a&&a.K;null==a&&(a=-1);return a}function X(a,b,c){return{K:void 0===a?null:a,Ma:void 0===b?!1:b,Ua:!1,Aa:c}}h=Fj.prototype;h.Gd=function(a,b){a.K=b;a.Ua=!1;a.Aa=void 0;return a};function Lj(a){return[a.K,a.Ma,a.Aa,a.Ua,a.Pc]}function Mj(a,b){var c=X(b[0],b[1],b[2]);c.Ua=b[3];b[4]&&(c.he=xj(a,c.Pc=b[4]));return c} +h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.g=a.i;(a=fe(a,"messages"))&&Ij(this,a);1140>this.f.ka&&(this.W=this.W.concat(Nj));1145>this.f.ka&&(this.W=this.W.concat(Oj));qd(this,16,function(a){a:{var b=d.D.b,c=a[0],e=a=0,l=b.length;if(c){a=Kj(Pj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.D.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): (c=n.type,m=cd[c],n&&d.v(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a?"R"+a:6==a?"SP":"PC"} -h.re=function(a){var b;if(0<=a)if(8>a)b=this.f.g[a];else if(16>a)b=this.f.qa[a-8];else if(20>a)b=this.f.W[a-16];else{var c=this.f,d=this.b;switch(a){case Vj:b=zd(this.f);break;case Wj:b=c.cb;break;case Xj:b=c.P;break;case Yj:b=c.xa&65280;break;case Zj:b=td(c);break;case ak:b=vd(c);break;case bk:b=wd(c);break;case ck:b=c.U;break;case dk:d&&(b=d.ba);break;case ek:d&&(b=d.qb);break;case fk:d&&(b=d.Ra)}}return b}; -h.message=function(a,b){b&&(a+=" @"+Sj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ca(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,qe(a),a.Bb=0,a.J&&H(a.J,void 0))}}; -function Hj(a){var b;if(!af(a))a.i&&a.i.length&&a.v("instruction history buffer freed"),a.P=0,a.i=[];else if(!a.i||!a.i.length){a.i=Array(gk);for(b=0;b>8;a.v("trapped to "+K(a,c&255,1)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?kk(a):lk(a)}}function ik(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.aa?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Da=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; -h.Ca=function(a,b){b&&this.v(a?"suspending":"shutting down");return a?this.save():!0};h.reset=function(a){Hj(this);this.X=0;this.R=null;this.w=0;this.G=X(this.f.g[7]);this.A.V=!1;mk(this);a||ie(this)};h.save=function(){var a=new G(this);a.set(0,Lj(this.G));a.set(1,Lj(this.N));a.set(2,[this.j,this.O,this.ha]);a.set(3,this.B);return a.data()}; +"";ke(d,a,!0);return!0}return!1}),!0;case "step":return this.H[b]=c,pb(c,function(a){var b=!1;Ha(d,!0)||(Ja(d,!0),b=uc(d,a?1:0,null),Ja(d,!1));return b}),!0}return!1};function je(a){if(a.U){var b=0,c=0;window&&(b=window.scrollX,c=window.scrollY);a.U.focus();window&&window.scrollTo(b,c)}}h.Od=function(a,b){var c=255,d=Kj(a);-1!==d&&(a.Ma||65535d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a)b=this.f.g[a];else if(16>a)b=this.f.ta[a-8];else if(20>a)b=this.f.X[a-16];else{var c=this.f,d=this.g;switch(a){case Xj:b=zd(this.f);break;case Yj:b=c.ob;break;case Zj:b=c.P;break;case ak:b=c.Ga&65280;break;case bk:b=td(c);break;case ck:b=vd(c);break;case dk:b=wd(c);break;case ek:b=c.W;break;case Vj:d&&(b=d.fa);break;case fk:d&&(b=d.Eb);break;case gk:d&&(b=d.Wa)}}return b}; +h.message=function(a,b){b&&(a+=" @"+Sj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ba(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,qe(a),a.Ab=0,a.J&&H(a.J,void 0))}}; +function Hj(a){var b;if(!af(a))a.i&&a.i.length&&a.v("instruction history buffer freed"),a.P=0,a.i=[];else if(!a.i||!a.i.length){a.i=Array(hk);for(b=0;b>8;a.v("trapped to "+K(a,c&255,1)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?lk(a):mk(a)}}function jk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.aa?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; +h.Ba=function(a,b){b&&this.v(a?"suspending":"shutting down");return a?this.save():!0};h.reset=function(a){Hj(this);this.X=0;this.R=null;this.w=0;this.G=X(this.f.g[7]);this.A.V=!1;nk(this);a||ie(this)};h.save=function(){var a=new G(this);a.set(0,Lj(this.G));a.set(1,Lj(this.N));a.set(2,[this.j,this.O,this.ha]);a.set(3,this.B);return a.data()}; h.restore=function(a){var b=0;void 0!==a[2]&&(this.G=Mj(this,a[b++]),this.N=Mj(this,a[b++]),this.j=a[b][0],"string"==typeof this.j&&(this.j=[this.j]),this.O=a[b][1],this.ha|=a[b][2]);a[3]&&(this.B=a[3]);return!0};h.start=function(a,b){this.I||this.v("running");this.A.V=!0;this.Ha=a;this.Ia=b}; -h.stop=function(a,b){if(this.A.V){this.A.V=!1;this.w=b-this.Ia;if(!this.I){b="stopped";if(this.w){a-=this.Ha;var c=0d&&(d=Cc(a.f,b)),65535!=(d&65535)&&(a.Fd(a.i[a.P],b),++a.P==a.i.length&&(a.P=0)));return!1}function Cg(a){var b=a.f;if(b.A.V)throw qc(b,a.f.O&65535),a.ca(),-1;return!1}function Sd(a,b,c){nk(a,b,c||1,a.L)&&a.ca(!1)}function Td(a,b,c){nk(a,b,c||1,a.C)&&a.ca(!1)} -function Gj(a){var b,c,d;a.g=["bp"];if(a.L)for(b=1;b>>c.g],!1)):Qe(a.f,!1);a.L=["br"];if(a.C)for(b=1;b>>c.g],!0)):Qe(a.f,!0);a.C=["bw"];a.la=0;a.Y=0} -h.Cb=function(a,b,c){var d=!0;c||ok(this,a,b,!1,!0);if(a!=this.g){var e=Kj(b);if(-1===e)this.v("invalid address: "+Sj(this,b)),d=!1;else{var f=a==this.C;65535>>g.g].Cb(e&g.i,f)}else e=this.f,(f?e.tc++:e.sc++)||xe(e)}}d&&(a.push(b),c?b.Va=!0:(pk(this,a,a.length-1,"set"),Hj(this)));return d}; -function ok(a,b,c,d,e){var f=!1;c=Kj(c);for(var g=1;g>>d.g],b)):Qe(a.f,b));k.Va||Hj(a);break}}return f}function qk(a,b){for(var c=1;c>23)&65535,A=K(u,t);else if(B==wk)t=t.K-((f&63)<<1)&65535,A=K(u,t);else if(B==xk)A=K(u,f&7,1);else if(B==yk)A=K(u,f&63,1);else if(B==zk)A=K(u,f&255,1);else if(B=f&D,D&Ak&&(B>>=6,D>>=6),D&Z){var D=null,J=B& -Bk;switch(B&Ck){case 0:A=Uj(J);break;case 8:A="@"+Uj(J);D=Dk(u,u.f.g[J]);break;case 16:7>J?A="("+Uj(J)+")+":(B=u.Sa(t,2),A="#"+K(u,B,0,!0));break;case 24:7>J?A="@("+Uj(J)+")+":(B=u.Sa(t,2),A="@#"+K(u,B,0,!0),D=Dk(u,B));break;case 32:A="-("+Uj(J)+")";break;case 40:A="@-("+Uj(J)+")";break;case 48:B=u.Sa(t,2);A=K(u,B,0,!0)+"("+Uj(J)+")";7==J&&(A=K(u,B=B+t.K&65535),D=Dk(u,B));break;case 56:B=u.Sa(t,2),A="@"+K(u,B)+"("+Uj(J)+")",7==J&&(A="@"+K(u,B=B+t.K&65535),D=Dk(u,Cc(u.f,B)))}D&&(A=[A,D])}u=A;if(!u|| -!u.length){k="INVALID";break}"string"!=typeof u&&(m=u[1],u=u[0]);0=a.f.vb&&b=c.B&&(b=c.Pa[b&jd])&&(a=b[4]);return a}function Ek(a,b){switch(b){case "N":a=De(a.f);break;case "Z":a=Ce(a.f);break;case "V":a=Be(a.f);break;case "C":a=Ae(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "} -function Fk(a,b){var c="",d=a.f;if(8>b)c=Uj(b),c+="="+K(a,d.g[b]);else if(13>b)c="A"+(b-8)+"="+K(a,d.qa[b-8]);else if(16<=b&&20>b)c="S"+(b-16)+"="+K(a,d.W[b-16]);else switch(b){case Vj:c="PS="+K(a,zd(d));break;case Wj:c="PI="+K(a,d.cb);break;case Xj:c="ER="+K(a,d.P);break;case Yj:c="SL="+K(a,d.xa&65280);break;case Zj:c="M0="+K(a,td(d));break;case ak:c="M1="+K(a,vd(d));break;case bk:c="M2="+K(a,wd(d));break;case ck:c="M3="+K(a,d.U);break;case dk:a.b&&(c="AR="+K(a,a.b.ba,3));break;case ek:a.b&&(c="DR="+ -K(a,a.b.qb));break;case fk:a.b&&(c="SR="+K(a,a.b.Ra,3))}c&&(c+=" ");return c}function Gk(a,b){var c,d="";for(c=0;6>c;c++)d+=Fk(a,c);d=d+"\n"+(Fk(a,6)+Fk(a,7));d+=Fk(a,Vj)+Fk(a,Wj)+Fk(a,Yj);d+=Ek(a,"T")+Ek(a,"N")+Ek(a,"Z")+Ek(a,"V")+Ek(a,"C");b&&(b=d,c=""+(Fk(a,Zj)+Fk(a,ak)),c+=Fk(a,bk)+Fk(a,ck)+Fk(a,Xj),c=c+"\n"+(Fk(a,fk)+Fk(a,dk)+Fk(a,ek)),d=b+("\n"+c));return d}h.le=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],q=$a(n,l,a.le);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Gk:b,K:c,Lf:d,ga:e,he:f})}function Hk(a,b,c){var d=[],e=Kj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&eb)){e.g[b]=g&65535;break}a.v("unknown register: "+ -f);return}H(a.J);a.v("updated registers:")}}a.v(Gk(a,d));c&&(a.G=X(e.g[7]),lk(a,Sj(a,a.G)))}}function Lk(a,b){b=Ya(b);var c=b.match(/^(['"])(.*?)\1$/);c?1k[0].indexOf("+"))){var m=k[0]+":";k[2]&&(m+=" "+k[2]);a.v(m)}k[3]&&(g=k[3],f=null);f=sk(a,b,g,f);a.v(f);a.G=b;e-=b.K-l;c++}}} -function rk(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.v(jk+b):(a.O&&(a.v("ended assemble at "+Sj(a,a.N)),a.G=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.R=null;if(Ga(a)&&0n||"z"d&&(d=Cc(a.f,b)),65535!=(d&65535)&&(a.Gd(a.i[a.P],b),++a.P==a.i.length&&(a.P=0)));return!1}function Cg(a){var b=a.f;if(b.A.V)throw qc(b,a.f.O&65535),a.ba(),-1;return!1}function $d(a,b,c){ok(a,b,c||1,a.L)&&a.ba(!1)}function ae(a,b,c){ok(a,b,c||1,a.C)&&a.ba(!1)} +function Gj(a){var b,c,d;a.b=["bp"];if(a.L)for(b=1;b>>c.g],!1)):Qe(a.f,!1);a.L=["br"];if(a.C)for(b=1;b>>c.g],!0)):Qe(a.f,!0);a.C=["bw"];a.la=0;a.Y=0} +h.Bb=function(a,b,c){var d=!0;c||pk(this,a,b,!1,!0);if(a!=this.b){var e=Kj(b);if(-1===e)this.v("invalid address: "+Sj(this,b)),d=!1;else{var f=a==this.C;65535>>g.g].Bb(e&g.i,f)}else e=this.f,(f?e.tc++:e.sc++)||xe(e)}}d&&(a.push(b),c?b.Ua=!0:(qk(this,a,a.length-1,"set"),Hj(this)));return d}; +function pk(a,b,c,d,e){var f=!1;c=Kj(c);for(var g=1;g>>d.g],b)):Qe(a.f,b));k.Ua||Hj(a);break}}return f}function rk(a,b){for(var c=1;c>23)&65535,A=K(r,t);else if(B==xk)t=t.K-((f&63)<<1)&65535,A=K(r,t);else if(B==yk)A=K(r,f&7,1);else if(B==zk)A=K(r,f&63,1);else if(B==Ak)A=K(r,f&255,1);else if(B=f&D,D&Bk&&(B>>=6,D>>=6),D&Z){var D=null,J=B& +Ck;switch(B&Dk){case 0:A=Uj(r,J);break;case 8:A="@"+Uj(r,J);D=Ek(r,r.f.g[J]);break;case 16:7>J?A="("+Uj(r,J)+")+":(B=r.Ra(t,2),A="#"+K(r,B,0,!0));break;case 24:7>J?A="@("+Uj(r,J)+")+":(B=r.Ra(t,2),A="@#"+K(r,B,0,!0),D=Ek(r,B));break;case 32:A="-("+Uj(r,J)+")";break;case 40:A="@-("+Uj(r,J)+")";break;case 48:B=r.Ra(t,2);A=K(r,B,0,!0)+"("+Uj(r,J)+")";7==J&&(A=K(r,B=B+t.K&65535),D=Ek(r,B));break;case 56:B=r.Ra(t,2),A="@"+K(r,B)+"("+Uj(r,J)+")",7==J&&(A="@"+K(r,B=B+t.K&65535),D=Ek(r,Cc(r.f,B)))}D&&(A= +[A,D])}r=A;if(!r||!r.length){k="INVALID";break}"string"!=typeof r&&(m=r[1],r=r[0]);0=a.f.ub&&b=c.B&&(b=c.Pa[b&jd])&&(a=b[4]);return a}function Fk(a,b){switch(b){case "N":a=De(a.f);break;case "Z":a=Ce(a.f);break;case "V":a=Be(a.f);break;case "C":a=Ae(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "}function Gk(a,b){var c=Uj(a,b);c&&(c+="="+K(a,a.Ad(b))+" ");return c} +function Hk(a,b){var c,d="";for(c=0;6>c;c++)d+=Gk(a,c);d=d+"\n"+(Gk(a,6)+Gk(a,7));d+=Gk(a,Xj)+Gk(a,Yj)+Gk(a,ak);d+=Fk(a,"T")+Fk(a,"N")+Fk(a,"Z")+Fk(a,"V")+Fk(a,"C");b&&(b=d,c=""+(Gk(a,bk)+Gk(a,ck)),c+=Gk(a,dk)+Gk(a,ek)+Gk(a,Zj),c=c+"\n"+(Gk(a,gk)+Gk(a,Vj)+Gk(a,fk)),d=b+("\n"+c));return d}h.me=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],q=$a(n,l,a.me);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Gk:b,K:c,Lf:d,ga:e,ie:f})}function Ik(a,b,c){var d=[],e=Kj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&eb)){e.g[b]=g&65535;break}a.v("unknown register: "+ +f);return}H(a.J);a.v("updated registers:")}}a.v(Hk(a,d));c&&(a.G=X(e.g[7]),mk(a,Sj(a,a.G)))}}function Mk(a,b){b=Ya(b);var c=b.match(/^(['"])(.*?)\1$/);c?1k[0].indexOf("+"))){var m=k[0]+":";k[2]&&(m+=" "+k[2]);a.v(m)}k[3]&&(g=k[3],f=null);f=tk(a,b,g,f);a.v(f);a.G=b;e-=b.K-l;c++}}} +function sk(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.v(kk+b):(a.O&&(a.v("ended assemble at "+Sj(a,a.N)),a.G=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.R=null;if(Ga(a)&&0n||"z"Ua.length&&(a.v("note: only "+Ua.length+" available"),Ca=Ua.length);Ia-=Ca;0>Ia&&(null==Ua[Ua.length-1].K?(Ca=Ia+Ca,Ia=0):Ia+=Ua.length);var ff=[];"call"==yi&&(Lc=1E5,ff=["CALL"]);for(void 0!==xi&&a.v(Ca+" instructions earlier:");0=Ua.length&&(Ia=0);a.pa=Ca;Ai++;Lc--}}Ai||(a.v("no "+zi+"history available"),a.pa=void 0)}else{var oa=Pj(a,Ta);if(oa)if("da"==jb){var gf=oa.Ma||65535O.length?(2xb&&(xb=0);65536lf?String.fromCharCode(lf):"."),$d=$d>>8}zb&&(zb+="\n");zb=hf?zb+(Ab+","):zb+(Ta+": "+Ab+(Zd?"":" "+kf))}zb&&a.v(zb);a.xa=oa;a.Ba=nl}}}}break;case "e":if("else"== -g[0])break;var bc,mf,nf,of,pf=g[0],qf=g[1];"eb"==pf?(bc=1,mf=255,nf=a.Nd,of=a.Od):"e"==pf||"ew"==pf?(bc=2,mf=65535,nf=a.Sa,of=a.Le):qf=null;if(null==qf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var ae=Pj(a,qf);if(ae)for(var be=2;betf;){for(var Bb=null,rl=256;65536>Rc.K>>>0;){uf.K=a.Sa(Rc,2);if(null==Rc.K||!rl--)break;if(!(uf.K&1)){for(var sl=a,ce=uf,Fi=null,Sc=ce.K,Gi=Sc,vf=1;6>=vf&⪼vf++){if(2> ";rb(function(){for(var a=x(document,w,"debugger"),b=0;b\nLicense: GPL version 3 or later ");this.v("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bTk){if(Uk(d,this.G)){this.u=new G(this,"1.34.0",bl);Uk(this.u)&&(cl(this,d),a=dl,el(this.u));this.u.set(Zk,ab());fl(this.u);var e=this.b&&!this.C;if(a==$k||ra("Click OK to restore the previous "+Gb+" machine state, or CANCEL to reset the machine.")){if(c=Yk(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Uk(d,g):("error"==f&&"no machine state"!= -g?(this.T("Error: "+g),"unable to verify user"==g&&(hb(gl,""),this.g=null)):this.v(f+": "+g),el(d),Uk(d)?(c=Yk(d),e=!0):c=!1))}e&&Wk(this,c?d:null)}else a==dl&&d.clear()}else Wk(this);delete this.G;delete this.B}e=ta(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.A.aa=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(hl(this,this.f,b,c,a),H(this,-2),this.f.ra());this.N&&(cl(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; -function cl(a,b){if(ra("There may be a problem with your "+Gb+" machine.\n\nTo help us diagnose it, click OK to send this "+Gb+" machine state to http://www.pcjs.org.")){var c=a.U;a=a.g||"";b=b.toString();var d={};d.app=Gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;bb("http://www.pcjs.org/api/v1/report",d,!0)}} -function Nk(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new G(a,"1.34.0"),g=new G(a,"1.34.0",Xk),k=ab();g.set(Zk,k);f.set(Zk,k);f.set(il,"1.34.0");f.set(jl,window?window.location.href:null);f.set(ml,window?window.navigator.userAgent:"");a.f&&a.f.Ca&&(c&&(b&&(a.f.A.ra=a.f.A.V),a.f.ca()),d=a.f.Ca(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.A.aa=!1,!1===d&&(e=null)));for(var k=ta(a.id),l=0;l=Ua.length&&(Ia=0);a.pa=Ca;Ai++;Lc--}}Ai||(a.v("no "+zi+"history available"),a.pa=void 0)}else{var oa=Pj(a,Ta);if(oa)if("da"==jb){var gf=oa.Ma||65535O.length?(2xb&&(xb=0);65536lf?String.fromCharCode(lf):"."),Nd=Nd>>8}zb&&(zb+="\n");zb=hf?zb+(Ab+","):zb+(Ta+": "+Ab+(Md?"":" "+kf))}zb&&a.v(zb);a.Fa=oa;a.Aa=pl}}}}break;case "e":if("else"== +g[0])break;var bc,mf,nf,of,pf=g[0],qf=g[1];"eb"==pf?(bc=1,mf=255,nf=a.Od,of=a.Pd):"e"==pf||"ew"==pf?(bc=2,mf=65535,nf=a.Ra,of=a.Le):qf=null;if(null==qf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var Od=Pj(a,qf);if(Od)for(var Pd=2;Pdtf;){for(var Bb=null,tl=256;65536>Rc.K>>>0;){uf.K=a.Ra(Rc,2);if(null==Rc.K||!tl--)break;if(!(uf.K&1)){for(var ul=a,Qd=uf,Fi=null,Sc=Qd.K,Gi=Sc,vf=1;6>=vf&⪼vf++){if(2> ";rb(function(){for(var a=x(document,w,"debugger"),b=0;b\nLicense: GPL version 3 or later ");this.v("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bUk){if(Vk(d,this.G)){this.u=new G(this,"1.34.0",cl);Vk(this.u)&&(dl(this,d),a=el,fl(this.u));this.u.set($k,ab());gl(this.u);var e=this.b&&!this.C;if(a==al||ra("Click OK to restore the previous "+Gb+" machine state, or CANCEL to reset the machine.")){if(c=Zk(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Vk(d,g):("error"==f&&"no machine state"!= +g?(this.T("Error: "+g),"unable to verify user"==g&&(hb(hl,""),this.g=null)):this.v(f+": "+g),fl(d),Vk(d)?(c=Zk(d),e=!0):c=!1))}e&&Xk(this,c?d:null)}else a==el&&d.clear()}else Xk(this);delete this.G;delete this.B}e=ta(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.A.aa=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(il(this,this.f,b,c,a),H(this,-2),this.f.qa());this.N&&(dl(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; +function dl(a,b){if(ra("There may be a problem with your "+Gb+" machine.\n\nTo help us diagnose it, click OK to send this "+Gb+" machine state to http://www.pcjs.org.")){var c=a.U;a=a.g||"";b=b.toString();var d={};d.app=Gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;bb("http://www.pcjs.org/api/v1/report",d,!0)}} +function Ok(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new G(a,"1.34.0"),g=new G(a,"1.34.0",Yk),k=ab();g.set($k,k);f.set($k,k);f.set(jl,"1.34.0");f.set(kl,window?window.location.href:null);f.set(ll,window?window.navigator.userAgent:"");a.f&&a.f.Ba&&(c&&(b&&(a.f.A.qa=a.f.A.V),a.f.ba()),d=a.f.Ba(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.A.aa=!1,!1===d&&(e=null)));for(var k=ta(a.id),l=0;l=d||30<=(c.$c+=d))&&(e.textContent=c.A.V?c.xb.toFixed(2)+"Mhz":"Stopped",c.$c=0)}if(a.i&&(a=a.i,b=b||0,a.u)){c=a.f.A.V;d=!!(a.f.i&8);if(0>=b||60<=(a.j+=b)){for(e=0;eb?a.ba=a.f.g[7]:0=d||30<=(c.$c+=d))&&(e.textContent=c.A.V?c.wb.toFixed(2)+"Mhz":"Stopped",c.$c=0)}if(a.i&&(a=a.i,b=b||0,a.u)){c=a.f.A.V;d=!!(a.f.i&8);if(0>=b||60<=(a.j+=b)){for(e=0;eb?a.fa=a.f.g[7]:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1pdp11$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(n){f=null,a=n.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");bb(e,null,!0,function(f,g,k){if(k||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+k+")");else{if(f=d[3])if(k=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=k[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);k[0]!=l&&(g=g.replace(k[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Dl(a,b,c)}})}else c(a,null)} -function El(a,b,c,d){function e(a){if(void 0===k){var b=g&&x(g,"machine-warning");k=b&&b[0]||g}k&&(k.innerHTML=Ra(a))}function f(a){e("Error: "+a);l&&(--Al||wb(!0));l=!1}var g,k,l=!0;Al++;pa[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var n=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=m:q.appendChild(document.createTextNode(m));n.appendChild(q)}c|| -(c="/versions/pdpjs/1.34.0/components.xsl");m=function(d,k){k?Bl(c,null,null,!1,e,function(d,l){l?(na(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(l=k.transformNode(l))?(g.outerHTML=l,--Al||wb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(l),(l=d.transformToFragment(k,document))?g.parentNode?(g.parentNode.replaceChild(l,g),--Al||wb(!0)):f("invalid machine element: "+ -a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?Bl(b,a,d,!0,e,m):Cl(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(t){f(t.message)}return l}window.embedPDP11=function(a,b,c,d){wb(!1);return El(a,b,c,d)};window.findMachineComponent=function(a,b){return va(b,a+".machine")}; +h.va=function(a,b,c){var d=this;switch(b){case "power":return this.H[b]=c,c.onclick=function(){d.j||(d.A.aa?Ok(d,!1,!0):d.yc(d.rc))},!0;case "reset":return this.H[b]=c,c.onclick=function(){if(d.A.aa&&!d.j)if(d.b&&!d.w){var a=ra("Click OK to save changes to this "+Gb+" machine.\n\nWARNING: If you CANCEL, all disk changes will be discarded.");Ok(d,a,!0);!a&&d.I?window&&window.location.reload():(a||(d.M=!0),d.rc(Uk),d.M=!1)}else d.reset(),d.f&&!d.F&&d.f.qa()},!0;case "save":if(Qa(db(),"pcjs.org"))c.parentNode.removeChild(c); +else return this.H[b]=c,c.onclick=function(){var a=Tk(d,!0);if(a){var b=!!(d.b&&!d.w||d.I),c=Ok(d,b);b?ol(d,a,c):d.T("Resume disabled, machine state not saved")}},!0}return!1}; +function Tk(a,b){var c=a.g;c||((c=gb(hl),void 0!==c)?!c&&b&&(b=null,window&&(b=window.prompt("Saving machine states on the pcjs.org server is currently unsupported.\n\nIf you're running your own server, enter your user ID below.","")),c=b)&&((c=zl(a,c))||a.T("The user ID is invalid.")):b&&a.T("Browser local storage is not available"));return c} +function zl(a,b){a.g=null;b=bb(db()+"/api/v1/user?req=verify&user="+b);var c=b[1];if(!b[0]&&c)try{b=eval("("+c+")"),b.code&&"ok"==b.code&&(hb(hl,b.data),a.g=b.data)}catch(d){v(d.message+" ("+c+")")}return a.g}function Wk(a){var b=null;a.g&&(b=db()+"/api/v1/user?req=load&user="+a.g+"&state="+Al(a,"1.34.0"));return b} +function ol(a,b,c){if(c){var d={req:"store"};d.user=b;d.state=Al(a,"1.34.0");d.data=c;b=bb(db()+"/api/v1/user",d);d=b[0];if(b[1]){if(d){var e=d.indexOf("\n");0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(q){g=null,a=q.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");bb(e,null,!0,function(f,g,k){if(k||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+k+")");else{if(f=d[3])if(k=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=k[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);k[0]!=l&&(g=g.replace(k[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);El(a,b,c)}})}else c(a,null)} +function Fl(a,b,c,d,e){function f(a){if(void 0===l){var b=k&&x(k,"machine-warning");l=b&&b[0]||k}l&&(l.innerHTML=Ra(a))}function g(a){f("Error: "+a);m&&(--Bl||wb(!0));m=!1}var k,l,m=!0;Bl++;pa[b]={};try{if(k=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var q=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style");t.type="text/css";t.styleSheet?t.styleSheet.cssText=n:t.appendChild(document.createTextNode(n));q.appendChild(t)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,l){l?Cl(d,null,a,null,!1,f,function(a,e){e?(na(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(k.outerHTML=e,--Bl||wb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?k.parentNode?(k.parentNode.replaceChild(e,k),--Bl|| +wb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Cl(c,b,a,e,!0,f,n):Dl(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(r){g(r.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Fl("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Fl("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return va(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,f=b.length,g=[],k=[],l="",m=null,n=0;n":62,"?":63,"@":64,hd:65,Lh:66,Rh:67,si:68,E:69,yi:70,Bi:71,Ni:72,Pi:73,Qi:74,Ri:75,Si:76,Vi:77,Xi:78,cj:79,fj:80,Q:81,hj:82,kj:83,tj:84,vj:85,xj:86,yj:87,Cj:88,Dj:89,Ke:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Ej:97,Fj:98,Ij:99,d:100,e:101,Jj:102,Kj:103,Lj:104,Mj:105,Qj:106,k:107,Rj:108,Sj:109,n:110,Tj:111,p:112,q:113,r:114,Uj:115,t:116,Wj:117,Xj:118,Yj:119,x:120, y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.sd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.qd=c||0;this.D=this.c=this.u=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} function pa(){return Date.now()||+new Date}function u(a){window&&window.alert(a)}function qa(a){var b=!1;window&&(b=window.confirm(a));return b}function ra(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;bb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ea=g.load;d.da=g.exec;if(e=g.bytes)d.N=e;else if(e=g.words)for(d.N=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.N=Array(4*e.length),f=c=0;c>8&255,d.N[f++]=e[c]>>16&255,d.N[f++]=e[c]>>24&255;else d.N=g;d.ia=g.symbols;d.N.length?1==d.N.length&&(u(d.N[0]),d=null):(u("Empty resource: "+a),d=null)}catch(k){u("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.ff,a];this.D=this.c=this.u=this.A=null;this.exports={hold:this.We,toggle:this.Bg,reset:this.ug, set:this.zg};B(this)}n(lb,r);h=lb.prototype;h.reset=function(a){this.stop();a&&nb(this,this.b=0)}; h.ma=function(a,b,c,d){if(this.A&&this.A.ma(a,b,c,d)||this.c&&this.c.ma(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.o[b]=c,this.m++,!0;default:return"led"==a||"rled"==a?(this.o[b]=c,this.h[b]=d?1:0,this.m++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.o[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){ob(a, @@ -81,7 +81,7 @@ h.gf=function(a){a||this.c.j.M||(F(this.c,this.U),a=this.c,a.u.reset(),Eb(a),thi h.$e=function(a){if(!a&&!this.c.j.M)if(this.a[Fb]&&this.a[Fb][1])Gb(this.c);else{a=this.D;var b;if(b=a)a.j.Ra&&(a.j.Wc=!0),b=!a.j.Ra;if(b)Aa(a,!0),a.f(0,null),Aa(a,!1);else try{var c=this.c.zc(1);0=a.c.sa?8:16,c=65472<=a.U&&a.U<65472+b,b=c?1:2,c=c?15:a.u.v;a.a[Bb]&&a.a[Bb][1]||(b=-b);wb(a,a.U&~c|a.U+b&c)}function wb(a,b){a.U=b&a.u.v;if(a.s!==a.U){a.s=a.U;b=a.s;for(var c=0;22>c;c++)Pb(a,"A"+c,b&1<c;c++)Pb(a,"D"+c,b&1<b;b++)a.a["S"+b][1]=a.f&1<b;b++)a.a["S"+b][1]=a.f&1<>2;this.f=this.g-1;this.s=this.C/this.g|0;this.K=this.s-1;this.Qa=[];this.m=0;this.l=!1;this.F=[];this.Le=[Tb,Ub,Vb,Wb];this.a=this.b=[];this.B=this.w=this.i=this.H=this.I=0;a=new H(this);Xb(a);this.a=Array(this.s);this.b=Array(this.s);for(b=0;b>>this.h;this.w=0;this.i=this.v;B(this)}n(Rb,r);function $b(a,b){if(b!=a.w){for(var c=0;c>>a.h,a.b[a.I]=a.a[a.H])}}h=Rb.prototype;h.reset=function(){for(var a=0;a>>this.h;return ib||b!=this.f?this. function Ob(a,b){var c;a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?c=e.D(d,b):c=e.i(d,b)|fc(a,b+1).i(0,b+1)<<8;a.m--;return c}function gc(a,b,c){a.l=!1;a.m++;fc(a,b).o(b&a.f,c&255,b);a.m--}function Mb(a,b,c){a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?e.m(d,c&65535,b):(e.o(d,c&255,b),fc(a,b+1).o(0,c>>8&255,b+1));a.m--} function ac(a){for(var b=0,c=[],d=0;da.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],x=g[5]||1,A=0;Aa.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],v=g[5]||1,y=0;y>8:e[2](f)&255):f&1&&(e=d.Qa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return c;I(d,b,16);return 255} function Ub(a,b,c){var d=!1,e=this.controller,f=e.Qa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Qa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d||I(e,c,16)}function Vb(a,b){var c=-1,d=this.controller;a=d.Qa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return c;I(d,b,16);return 65535} function Wb(a,b,c){var d=!1,e=this.controller;a=e.Qa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d||I(e,c,16)}function K(a){r.call(this,"Device",a,256);this.a={Ia:128,dd:-1}}n(K,r);h=K.prototype;h.ja=function(a,b,c,d){this.u=b;this.A=a;this.c=c;this.D=d;var e=this;this.a.dd=mc(c,function(){e.a.Ia|=128;e.a.Ia&64&&nc(e.c,e.a.qa);e.A&&Kb(e.A,1);oc(e.c,e.a.dd,1E3/60)});this.a.qa=pc(c,64,6,2097152);qb(b,this,qc);sb(b,this.reset.bind(this));B(this)}; @@ -108,7 +108,7 @@ var L={},qc=(L[61568]=[null,null,K.prototype.lg,K.prototype.Dh,"UNIMAP",64,1170] K.prototype.yb,"R4SET0"],L[65477]=[null,null,K.prototype.vb,K.prototype.yb,"R5SET0"],L[65478]=[null,null,K.prototype.Hf,K.prototype.Yg,"R6KERNEL"],L[65479]=[null,null,K.prototype.Kf,K.prototype.ah,"R7KERNEL"],L[65480]=[null,null,K.prototype.wb,K.prototype.zb,"R0SET1",1,1145],L[65481]=[null,null,K.prototype.wb,K.prototype.zb,"R1SET1",1,1145],L[65482]=[null,null,K.prototype.wb,K.prototype.zb,"R2SET1",1,1145],L[65483]=[null,null,K.prototype.wb,K.prototype.zb,"R3SET1",1,1145],L[65484]=[null,null,K.prototype.wb, K.prototype.zb,"R4SET1",1,1145],L[65485]=[null,null,K.prototype.wb,K.prototype.zb,"R5SET1",1,1145],L[65486]=[null,null,K.prototype.If,K.prototype.Zg,"R6SUPER",1,1145],L[65487]=[null,null,K.prototype.Jf,K.prototype.$g,"R6USER",1,1145],L[65504]=[null,null,K.prototype.qf,K.prototype.Jg,"CTRL",8,1170],L[65520]=[null,null,K.prototype.Md,K.prototype.Pd,"LSIZE",1,1170],L[65522]=[null,null,K.prototype.Md,K.prototype.Pd,"HSIZE",1,1170],L[65524]=[null,null,K.prototype.gg,K.prototype.yh,"SYSID",1,1170],L[65526]= [null,null,K.prototype.pf,K.prototype.Ig,"ERR",1,1170],L[65528]=[null,null,K.prototype.wf,K.prototype.Pg,"MBR",1,1170],L[65530]=[null,null,K.prototype.Bf,K.prototype.Sg,"PIR"],L[65532]=[null,null,K.prototype.fg,K.prototype.xh,"SLR"],L[65534]=[null,null,K.prototype.Gf,K.prototype.Xg,"PSW"],L); -Ya(function(){for(var a=z(document,y,"device"),b=0;b>1),this.c=new Int32Array(this.f,0,this.size>>2),Fc(this,Gc?Hc:Ic);else{a=this.c=Array(this.size>>2);for(f=0;f>2),b=0;b>=6;var c=a.S=b&7;return(b=a.K=(b&56)>>3)?a.kc(a.ra(b,c,3)):a function P(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.qc=a.ra(b,e,7),c=0>c?a.b[-c-1]&255:c,a.yc(e,d.call(a,c,a.kc(e))),e&1&&a.a--):(b=a.b[e],c=0>c?a.b[-c-1]&255:c,a.b[e]=b&65280|d.call(a,c,b&255))}function Q(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,6),a.mc(e,d.call(a,0>c?a.b[-c-1]:c,a.lc(e)))):a.b[e]=d.call(a,0>c?a.b[-c-1]:c,a.b[e])} function Bd(a,b,c,d,e){var f=a.f=b&7;(b=a.h=(b&56)>>3)?(d=a.ra(b,f,5),e.call(a,(c=0>c?a.b[-c-1]&255:c)<<8),a.yc(d,c),d&1&&a.a--):(c?(c=0>c?a.b[-c-1]&255:c,a.b[f]=a.b[f]&~d|c<<24>>24&d):a.b[f]&=~d,e.call(a,c<<8))}function Cd(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,4),d.call(a,c=0>c?a.b[-c-1]:c),a.mc(e,c)):(a.b[e]=c=0>c?a.b[-c-1]:c,d.call(a,c))} h.zc=function(a){this.j.complete=!0;var b=a?this.j.cd?0:1:-1;this.j.cd=!1;this.Ma=this.a=a;this.g=this.g&-5|0;do{if(this.g){if(a=this.g&11)if(a=!1,this.g&2){var c=160,d=(this.$a&224)>>5,e=this.I&&this.I.sb>d?this.I:null;e&&(c=e.Ub,d=e.sb);d>(this.i&224)>>5?(this.g&8&&(ld(this,2),this.g&=-9),J(this,c,0,-10),d=!0):d=!1;d&&(e&&rc(this,e),a=!0);this.I||this.$a||(this.g&=-3)}else this.g&1&&this.g++;if(a){if(this.g&4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}if(this.g&112&&md(this)){if(this.g& -4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.nd(e)}while(0b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.nd(e)}while(0>1|b<<16;nd(this,a);return a&65535}function Id(a,b){a=b&128|b>>1|b<<8;nd(this,a<<8);return a&255}function Jd(a,b){a=b&~a;this.fa(a);return a}function Kd(a,b){a=b&~a;this.fa(a<<8);return a}function Ld(a,b){a|=b;this.fa(a);return a}function Md(a,b){a|=b;this.fa(a<<8);return a} function Nd(a,b){a=~b|65536;this.Sa(a);return a&65535}function Od(a,b){a=~b|256;this.Sa(a<<8);return a&255}function Pd(a,b){this.w=this.l=a=b-a;this.m=b&(b^a);return a&65535}function Qd(a,b){a=b-a;var c=a<<8;b<<=8;this.w=this.l=c;this.m=b&(b^c);return a&255}function Rd(a,b){this.w=this.l=a=b+a;this.m=a&(b^a);return a&65535}function Sd(a,b){a=b+a;var c=a<<8;this.w=this.l=c;this.m=c&(b<<8^c);return a&255}function Td(a,b){a=-b;this.Sa(a,a&b&32768);return a&65535} function Ud(a,b){a=-b;this.Sa(a<<8,(a&b&128)<<8);return a&255}function Vd(a,b){a=b<<1|this.v>>16&1;nd(this,a);return a&65535}function Wd(a,b){a=b<<1|this.v>>16&1;nd(this,a<<8);return a&255}function Xd(a,b){a=(this.v&65536|b)>>1|b<<16;nd(this,a);return a&65535}function Yd(a,b){a=((this.v&65536)>>8|b)>>1|b<<8;nd(this,a<<8);return a&255}function Zd(a,b){var c=b-a;od(this,c,a,b);return c&65535}function $d(a,b){var c=b-a;od(this,c<<8,a<<8,b<<8);return c&255} @@ -181,13 +181,13 @@ R,R,R,We,We],Af=[we,ue,qe,se,ze,Ae,fe,ge,Fe,Ze,nf,pf,rf,function(a){1145>this.sa function Ff(a){r.call(this,"ROM",a,128);this.ia=this.b=null;this.h=+a.addr;this.a=+a.size;this.i=!1;this.f=a.alias;"string"==typeof this.f&&(this.f=eval(this.f));this.g=a.file;this.m=Ea(this.g);if(this.g){a=this.g;var b=Fa(this.m);"json"!=b&&"hex"!=b&&(a=Oa()+"/api/v1/dump?file="+this.g+"&format=bytes&decimal=true");var c=this;Ma(a,null,!0,function(a,b,f){f?(c.G("Unable to load ROM resource (error "+f+": "+a+")"),c.g=null):(na(c.Ua,a,b),(a=Na(a,b))?(c.b=a.N,c.ia=a.ia):c.g=null);Gf(c)})}}n(Ff,r); h=Ff.prototype;h.ja=function(a,b,c,d){this.u=b;this.c=c;this.D=d;Gf(this)};h.la=function(){this.ia&&(this.D&&this.D.a(this.id,this.h,this.a,this.ia),delete this.ia);return!0};h.ka=function(){return!0}; function Gf(a){if(!za(a)){if(a.g){if(!a.b||!a.u)return;a.a||(a.a=a.b.length);if(a.b.length!=a.a){var b="ROM size ("+Da(a.b.length,8,!0)+") does not match specified size ("+Da(a.a,8,!0)+")";a.j.error=!0;a.G(b)}else{a:{b=a.h;if(57344<=b&&b<57344+Sb){var c={},c=(c[b]=[Ff.prototype.Zf,Ff.prototype.qh,null,null,null,a.a>>1],c);if(qb(a.u,a,c)){a.status("Added "+a.a+"-byte ROM at "+Ca(b));b=a.i=!0;break a}}else if(Yb(a.u,b,a.a,Ec)){for(c=0;c>>f.h;0>>=f.h;0>>f.h;0>>=f.h;0>>a.h;0=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,q=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),x=l,A=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(A)for(;A--;)gc(a.u,q++,b[x++]&255);else q&1?g=!0:null==d&&(d=q);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e< -b.length;e++)gc(a.u,c+e,b[e]);k=!0}if(k){if(null==d||g)G(a.c),f=!1;null!=d&&hd(a.c,d,f)}return k}Ya(function(){for(var a=z(document,y,"ram"),b=0;b=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,q=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=l,y=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(y)for(;y--;)gc(a.u,q++,b[v++]&255);else q&1?g=!0:null==d&&(d=q);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e< +b.length;e++)gc(a.u,c+e,b[e]);k=!0}if(k){if(null==d||g)G(a.c),f=!1;null!=d&&hd(a.c,d,f)}return k}Ya(function(){for(var a=A(document,z,"ram"),b=0;b=la.hd&&c<=la.Ke&&(b=c-(la.hd-la.Ud));b&&(a.preventDefault&&a.preventDefault(),d.nc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.Wd&&(b=la.Vd);d.nc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); @@ -199,7 +199,7 @@ h.nc=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a h.Mf=function(){var a=this.a&65534;this.a&=-32769;return a};h.dh=function(a){var b=a^this.a;this.a=this.a&-112|a&111;this.F&&b&6&&(b=0,b=this.v?b|(a&4?32:0)|(a&2?320:0):b|(a&4?16:0)|(a&2?1048576:0),this.F.call(this.g,b))};h.Lf=function(){this.a&=-129;return this.l};h.bh=function(){};h.sg=function(){return this.b};h.Kh=function(a){if(this.b&128)if(a&64)nc(this.c,this.C);else{var b=this.C;b&&rc(this.c,b)}this.b=this.b&-70|a&69};h.rg=function(){return 0}; h.Jh=function(a){a&=255;this.s&&this.s.call(this.g,a);a&=127;if(this.h)if(13==a)this.m=0;else if(8==a)this.h.value=this.h.value.slice(0,-1),0":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.S||8,c=a-this.m%a,this.S&&(b=" ".slice(0,c)));this.K&&!this.m&&c&&(b=String.fromCharCode(this.K)+b);this.h.value+=b;this.h.scrollTop=this.h.scrollHeight;this.m+=c}}else if(null!= this.i){if(10==a||1024<=this.i.length)this.aa(this.i),this.i="";10!=a&&(this.i+=String.fromCharCode(a))}oc(this.c,this.X,1E3/Math.round(this.ba/10));this.b&=-129};var Mf="buffer",Pf={},Nf=(Pf[65392]=[null,null,Lf.prototype.Mf,Lf.prototype.dh,"RCSR"],Pf[65394]=[null,null,Lf.prototype.Lf,Lf.prototype.bh,"RBUF"],Pf[65396]=[null,null,Lf.prototype.sg,Lf.prototype.Kh,"XCSR"],Pf[65398]=[null,null,Lf.prototype.rg,Lf.prototype.Jh,"XBUF"],Pf); -Ya(function(){for(var a=z(document,y,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.o[b]=c,!0;case "readTape":e=Tf;case "loadTape":return e||(e=Uf),this.o[b]=c,c.onclick= function(){var a=d.o.listTapes;a&&Vf(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Vf(d,Ea(b,!0),b,Uf,a)}return!1};return!0;case Wf:return this.o[b]=c,!0}return!1}; @@ -208,18 +208,18 @@ h.la=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;re function Vf(a,b,c,d,e){if(c)if(c==ag)a.G('Use "Choose File" and "Mount" to select and load a local tape.');else{if(c==bg){c=window.prompt("Enter the URL of a remote tape image.","")||"";if(!c)return;b=Ea(c);a.status("Attempting to load "+c+' as "'+b+'"');a.i=bg}else a.i=c;dg(a,b,c,d,!1,e)}else fg(a,!1)}function dg(a,b,c,d,e,f){var g=-1;if(a.g.toLowerCase()!=c.toLowerCase()||a.f!=d)g++,fg(a,!0),a.j.Ra?a.G("PC11 busy"):(e&&a.b++,gg(a,b,c,d,f)?g++:a.j.Ra=!0);g&&hg(a,a.B,a.g,a.f,a.N,a.ea,a.da)} function gg(a,b,c,d,e){var f=c;if(e){var g=new FileReader;g.onload=function(){var e=g.result;e&&(e=new Uint8Array(e,0,e.byteLength),hg(a,b,c,d,e),a.i=ag);a.j.Ra=!1;eg(a)};g.readAsArrayBuffer(e);return!1}0>c.indexOf("/api/v1/dump")&&(e=Fa(c),f="json"==e||"gz"==e?encodeURI(c):Oa()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!Ma(f,null,!0,function(e,f,g){var k=0>g&&!!a.A&&!a.A.j.R;g?a.G('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.Ua,e,f),(e=Na(e,f))&&hg(a,b,c,d, e.N,e.ea,e.da));a.j.Ra=!1;a.b&&(a.b--,a.b||B(a));eg(a)})}function $f(a,b,c,d){if((a=a.o.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.a=Array(a.L);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Fa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Ga(c,"/")&&(d="dir"),f=Oa()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.Yc?"":e)+"&format=json"));return!!Ma(f, +function og(a,b,c,d,e){var f=c;if(a.b)return!0;a.xa=b;a.oa=c;a.bd=Ea(c);a.b=e;a.i=a.controller;if(d){var g=new FileReader;g.onload=function(){var b=g.result,c,d=b?b.byteLength:0,e=ka[d];if(e){a.L=e[0];a.T=e[1];a.P=e[2];a.Z=e[3]||512;c=a.Z>>2;var f=e=0,b=new DataView(b,0,d);a.a=Array(a.L);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Fa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Ga(c,"/")&&(d="dir"),f=Oa()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.Yc?"":e)+"&format=json"));return!!Ma(f, null,!0,function(b,c,d){pg(a,b,c,d)})} function pg(a,b,c,d){var e=null,f=0>d&&!!a.A&&!a.A.j.R;a.g=!1;if(d)a.controller.G('Unable to load disk "'+a.xa+'" (error '+d+": "+b+")",f);else{na(a.controller.Ua,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ -c+")");if(k.length)if(1==k.length)u(k[0]);else{a.L=k.length;a.T=k[0].length;a.P=k[0][0].length;var l=k[0][0][0];a.Z=l&&l.length||512;for(d=c=0;d>2,p=l.pattern;void 0===p&&(p=l.pattern=0);var q=l.data;if(void 0===q){var x=l.bytes;if(void 0!==x&&x.length){for(var A=m<<2,ma=x.length;ma>2,p=l.pattern;void 0===p&&(p=l.pattern=0);var q=l.data;if(void 0===q){var v=l.bytes;if(void 0!==v&&v.length){for(var y=m<<2,ma=v.length;ma>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.g)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.na?f=a.wa+a.na&&(a.na+=f-(a.wa+a.na)+1):(a.wa=f,a.na=1);d[f]=d[f]&~(255<g)break;e|=g<'+a+"");c.innerHTML=a}}h.Cg=function(a){for(var b=0;b=a.L){m=T.Zb;break}p=a.seek(b,c,d+1);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}var x,A;if(0>(x=a.read(p,q++))||0>(A=a.read(p,q++))){m=T.$b;break}if(!k&&(Mb(this.u,sd(this.c,f),x|A<<8),lc(this.u))){m=T.Eb;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; -h.vc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){var x=Ob(this.u,sd(this.c,f));if(lc(this.u)){m=T.Eb;break}if(!p){if(b>=a.L){m=T.Zb;break}p=a.seek(b,c,d+1,!0);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}if(k){var A,ma;if(0>(A=a.read(p,q++))||0>(ma=a.read(p,q++))){m=T.$b;break}if(x!=(A|ma<<8)){m=T.Cd;break}}else if(!a.write(p,q++,x&255)||!a.write(p,q++,x>>8)){m=T.$b;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.ub=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){if(!p){if(b>=a.L){m=T.Zb;break}p=a.seek(b,c,d+1);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}var v,y;if(0>(v=a.read(p,q++))||0>(y=a.read(p,q++))){m=T.$b;break}if(!k&&(Mb(this.u,sd(this.c,f),v|y<<8),lc(this.u))){m=T.Eb;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.vc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){var v=Ob(this.u,sd(this.c,f));if(lc(this.u)){m=T.Eb;break}if(!p){if(b>=a.L){m=T.Zb;break}p=a.seek(b,c,d+1,!0);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}if(k){var y,ma;if(0>(y=a.read(p,q++))||0>(ma=a.read(p,q++))){m=T.$b;break}if(v!=(y|ma<<8)){m=T.Cd;break}}else if(!a.write(p,q++,v&255)||!a.write(p,q++,v>>8)){m=T.$b;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; h.me=function(a,b,c,d,e,f){this.h=f&65535;this.a=this.a&~S.fb|f>>16-S.V.fb&S.fb;this.i=65536-e&65535;this.g=this.g&~Mg.Rc|d&Mg.Rc;this.f|=a;Ng(this);return!0};function Ng(a){a.a&=~S.Ja;a.f&&(a.f|=T.Yd,a.a|=S.Ja,a.f&T.Hc&&(a.a|=S.Hc))}h.Rf=function(){return this.s};h.ih=function(){};h.Sf=function(){return this.f};h.jh=function(){};h.Of=function(){return this.a&S.Fb}; h.fh=function(a){this.a=this.a&~S.va|a&S.va;if(this.a&S.Db){a=!0;var b,c,d=(this.g&Mg.Ta)>>Mg.V.Ta,e=this.b[d],f,g,k,l,m,p;this.a&=~(S.za|S.Sc);this.f&=~T.Ce;switch(c=this.a&S.ca){case Og.Td:this.f=this.g=0;this.a=S.za;break;case Og.he:case Og.Va:b=this.ub;case Og.Vc:case Og.Hb:b||(b=this.vc);f=(this.g&Mg.Bb)>>Mg.V.Bb;g=(this.g&Mg.Kc)>>Mg.V.Kc;k=this.g&Mg.Rc;l=65536-this.i&65535;m=(this.a&S.fb)<<16-S.V.fb|this.h;p=this.a&S.de?0:2;if(f>=e.L){this.f|=T.Zb;break}if(k>=e.P){this.f|=T.$b;break}a=b.call(this, e,f,g,k,l,m,p,c>=Og.Vc,this.me.bind(this));break;case Og.ec:f=(this.g&Mg.Bb)>>Mg.V.Bb;f>V.V.Gb,f=this.f&V.dc?1:0,g=this.f&V.yd,!d||e>=d.L||g>=d.P?this.a=this. h.mh=function(a){this.h=a&Sg.Fa;this.a=this.a&~U.ya|(this.h&3)<=m.L){k=Y.fe;break}p=m.seek(b,c,d+1);if(!p){k=Y.Pc;break}q=0;++d>=m.P&&(d=0,++c>=m.T&&(c=0,++b))}var x;if(0>(a=m.read(p,q++))||0>(x=m.read(p,q++))){k=Y.Oc;break}Mb(this.u,sd(this.c,f),a|x<<8);q>=m.Z&&(p=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +function Zg(a,b){b&&(a.w=b,a.l=a.f,a.a|=X.Ja);a.g=W.gb;a.a|=X.DONE;a.a&X.eb&&nc(a.c,a.qa)}h.ub=function(a,b,c,d,e,f,g,k,l){k=0;var m=a.O,p=null,q;m||(k=a.rb?Y.Jc:Y.Ic,e=0);for(;e;){if(!p){if(b>=m.L){k=Y.fe;break}p=m.seek(b,c,d+1);if(!p){k=Y.Pc;break}q=0;++d>=m.P&&(d=0,++c>=m.T&&(c=0,++b))}var v;if(0>(a=m.read(p,q++))||0>(v=m.read(p,q++))){k=Y.Oc;break}Mb(this.u,sd(this.c,f),a|v<<8);q>=m.Z&&(p=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; function Yg(a){var b=0,c=a.a&X.Tc?1:0,d=a.b[c],d=d&&d.O,e=a.v&$g.Fa,f=a.s&ah.Fa;a.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(d)if(a.f|=Z.ha,c=d.seek(e,0,f,!0)){e=0;for(f=a.h.length;eg){b=Y.Oc;break}a.h[e++]=g}c.Re&&(a.f|=Z.Cb)}else b=Y.Pc;else b=c?Y.Jc:Y.Ic;Zg(a,b)}h.$f=function(a,b){a=this.a;if(!b)switch(a&=X.Fb,this.g){case W.Ec:case W.EMPTY:this.ithis.i&&(this.a|=X.Ga)}return a}; h.rh=function(a){this.a=this.a&~X.va|a&X.va;if(this.a&X.INIT)this.bb();else if(this.a&X.Db&&this.g==W.gb)switch(this.g=this.a&X.ca,this.a&=~(X.Db|X.Ga|X.DONE|X.Ja),(a=this.qa)&&rc(this.c,a),this.g){case W.Ec:case W.EMPTY:case W.Va:case W.Hb:case W.fc:this.i=0;break;case W.ke:a=this.b[this.a&X.Tc?1:0];this.f&=~Z.ha;a&&a.O&&(this.f|=Z.ha);this.l=this.f;Zg(this);break;case W.je:this.l=this.w,Zg(this)}else this.a&X.eb?this.a&X.DONE&&nc(this.c,this.qa):(a=this.qa)&&rc(this.c,a)}; h.ag=function(a,b){if(!b)switch(this.g){case W.EMPTY:this.a&X.Ga&&(this.a&=~X.Ga,this.l=this.h[this.i]&255,++this.i>=this.h.length&&Zg(this))}return this.l}; @@ -273,8 +273,8 @@ function ch(a,b,c){r.call(this,"Computer",a,33554432);this.j.R=!1;this.F=null;dh "state")||(f=!0,a.state))this.v=b=a,f||(this.l=!0,this.a=fh),this.a&&(this.m=new E(this,"1.34.0"),gh(this.m)?b=null:delete this.m);!b&&this.a&&(b=hh(this))&&(this.l=!0);if(b){var g=this;Ma(b,null,!0,function(a,b,c){c?(g.i=null,g.l=!1,g.G("Unable to load machine state from server (error "+c+(b?": "+Ja(b):"")+")")):(g.s=b,g.I=!0);B(g)})}else B(this);this.o.power||(this.w=!0);!c&&this.w&&this.Vb(this.Sb)}else u("Unable to find CPU component")}n(ch,r); function dh(a,b){if(!b){var c;if("object"==typeof resources&&(c=resources.parms))try{b=eval("("+c+")")}catch(d){u(d.message+" ("+c+")")}}a.F=b}function Tc(a,b,c,d){var e=b.toLowerCase(),e=Va(b)||Va(e);void 0===e&&a.F&&(e=a.F[b]);void 0===e&&c&&(e=c[b]);void 0===e&&"object"==typeof resources&&resources[b]&&(e=b);void 0===e&&(e=void 0);if("string"==typeof e&&d)switch(d){case 4:e=+e;isNaN(e)&&(e=0);break;case 6:e="true"==e}return e}h=ch.prototype; h.Vb=function(a,b){for(var c=this,d=ra(this.id),e=0;e<=d.length;e++){var f=efh){if(gh(d,this.s)){this.h=new E(this,"1.34.0",qh);gh(this.h)&&(rh(this,d),a=sh,th(this.h));this.h.set(lh,La());uh(this.h);var e=this.a&&!this.l;if(a==mh||qa("Click OK to restore the previous "+gb+" machine state, or CANCEL to reset the machine.")){if(c=kh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gh(d,g):("error"==f&&"no machine state"!= -g?(this.G("Error: "+g),"unable to verify user"==g&&(Ta(vh,""),this.b=null)):this.aa(f+": "+g),th(d),gh(d)?(c=kh(d),e=!0):c=!1))}e&&ih(this,c?d:null)}else a==sh&&d.clear()}else ih(this);delete this.s;delete this.m}e=ra(this.id);for(f=0;ffh){if(gh(d,this.s)){this.h=new E(this,"1.34.0",qh);gh(this.h)&&(rh(this,d),a=sh,th(this.h));this.h.set(lh,La());uh(this.h);var e=this.a&&!this.l;if(a==mh||qa("Click OK to restore the previous "+gb+" machine state, or CANCEL to reset the machine.")){if(c=kh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gh(d,g):("error"==f&&"no machine state"!= +g?(this.G("Error: "+g),"unable to verify user"==g&&(Sa(vh,""),this.b=null)):this.aa(f+": "+g),th(d),gh(d)?(c=kh(d),e=!0):c=!1))}e&&ih(this,c?d:null)}else a==sh&&d.clear()}else ih(this);delete this.s;delete this.m}e=ra(this.id);for(f=0;fa[1];a=a[2];this.H=!0;this.j.R=!0;var d=this.o.power;d&&(d.textContent="Shutdown");this.c&&(wh(this,this.c,b,c,a),Kb(this,-2),this.c.Y());this.C&&(rh(this,b),b.clear());!c&&this.h&&(this.h.clear(),delete this.h);this.g=0}; function rh(a,b){if(qa("There may be a problem with your "+gb+" machine.\n\nTo help us diagnose it, click OK to send this "+gb+" machine state to http://www.pcjs.org.")){var c=a.K;a=a.b||"";b=b.toString();var d={};d.app=gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}} @@ -285,19 +285,19 @@ function Kb(a,b){if(a.c){var c=a.c,d=b||0,e=c.o.speed;e&&(0>=d||30<=(c.fd+=d))&& "B16",b&4)}} h.ma=function(a,b,c){var d=this;switch(b){case "power":return this.o[b]=c,c.onclick=function(){d.g||(d.j.R?xh(d,!1,!0):d.Vb(d.Sb))},!0;case "reset":return this.o[b]=c,c.onclick=function(){if(d.j.R&&!d.g)if(d.a&&!d.i){var a=qa("Click OK to save changes to this "+gb+" machine.\n\nWARNING: If you CANCEL, all disk changes will be discarded.");xh(d,a,!0);!a&&d.v?window&&window.location.reload():(a||(d.B=!0),d.Sb(fh),d.B=!1)}else d.reset(),d.c&&!d.D&&d.c.Y()},!0;case "save":if(Ga(Oa(),"pcjs.org"))c.parentNode.removeChild(c);else return this.o[b]= c,c.onclick=function(){var a=eh(d,!0);if(a){var b=!!(d.a&&!d.i||d.v),c=xh(d,b);b?Bh(d,a,c):d.G("Resume disabled, machine state not saved")}},!0}return!1};function eh(a,b){var c=a.b;c||((c=Ra(vh),void 0!==c)?!c&&b&&(b=null,window&&(b=window.prompt("Saving machine states on the pcjs.org server is currently unsupported.\n\nIf you're running your own server, enter your user ID below.","")),c=b)&&((c=Dh(a,c))||a.G("The user ID is invalid.")):b&&a.G("Browser local storage is not available"));return c} -function Dh(a,b){a.b=null;b=Ma(Oa()+"/api/v1/user?req=verify&user="+b);var c=b[1];if(!b[0]&&c)try{b=eval("("+c+")"),b.code&&"ok"==b.code&&(Ta(vh,b.data),a.b=b.data)}catch(d){u(d.message+" ("+c+")")}return a.b}function hh(a){var b=null;a.b&&(b=Oa()+"/api/v1/user?req=load&user="+a.b+"&state="+Eh(a,"1.34.0"));return b} -function Bh(a,b,c){if(c){var d={req:"store"};d.user=b;d.state=Eh(a,"1.34.0");d.data=c;b=Ma(Oa()+"/api/v1/user",d);d=b[0];if(b[1]){if(d){var e=d.indexOf("\n");0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1pdp11$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(q){g=null,a=q.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Ma(e,null,!0,function(f,g,k){if(k||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+k+")");else{if(f=d[3])if(k=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=k[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);k[0]!=l&&(g=g.replace(k[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, "");a=a.replace(d[0],g);Ih(a,b,c)}})}else c(a,null)} -function Jh(a,b,c,d){function e(a){if(void 0===k){var b=g&&z(g,"machine-warning");k=b&&b[0]||g}k&&(k.innerHTML=Ha(a))}function f(a){e("Error: "+a);l&&(--Fh||bb(!0));l=!1}var g,k,l=!0;Fh++;oa[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=m:q.appendChild(document.createTextNode(m));p.appendChild(q)}c|| -(c="/versions/pdpjs/1.34.0/components.xsl");m=function(d,k){k?Gh(c,null,null,!1,e,function(d,l){l?(na(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(l=k.transformNode(l))?(g.outerHTML=l,--Fh||bb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(l),(l=d.transformToFragment(k,document))?g.parentNode?(g.parentNode.replaceChild(l,g),--Fh||bb(!0)):f("invalid machine element: "+ -a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?Gh(b,a,d,!0,e,m):Hh(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(x){f(x.message)}return l}window.embedPDP11=function(a,b,c,d){bb(!1);return Jh(a,b,c,d)};window.findMachineComponent=function(a,b){return ta(b,a+".machine")}; +function Jh(a,b,c,d,e){function f(a){if(void 0===l){var b=k&&A(k,"machine-warning");l=b&&b[0]||k}l&&(l.innerHTML=Ha(a))}function g(a){f("Error: "+a);m&&(--Fh||bb(!0));m=!1}var k,l,m=!0;Fh++;oa[b]={};try{if(k=document.getElementById(b)){var p;if("object"==typeof resources&&(p=resources.css)){var q=document.head||document.getElementsByTagName("head")[0],v=document.createElement("style");v.type="text/css";v.styleSheet?v.styleSheet.cssText=p:v.appendChild(document.createTextNode(p));q.appendChild(v)}d|| +(p=a,"pdp"==a.substr(0,3)&&(p="pdpjs"),d="/versions/"+p+"/1.34.0/components.xsl");p=function(e,l){l?Gh(d,null,a,null,!1,f,function(a,e){e?(na(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(k.outerHTML=e,--Fh||bb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?k.parentNode?(k.parentNode.replaceChild(e,k),--Fh|| +bb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Gh(c,b,a,e,!0,f,p):Hh(c,null,b,a,e,!1,f,p)}else g("missing machine element: "+b)}catch(y){g(y.message)}return m}window.embedPDP10=function(a,b,c,d){bb(!1);return Jh("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){bb(!1);return Jh("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return ta(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!va[a]){for(var c=!0,d=va,e=a,f=b.length,g=[],k=[],l="",m=null,p=0;p Date: Fri, 24 Feb 2017 10:58:56 -0800 Subject: [PATCH 05/30] Changed toStrBase() to accept a number of bits rather than a number of bytes, because bytes aren't always 8 bits (see PDP-10) --- docs/pcx86/examples/pcx86-dbg.js | 2 +- modules/pdp10/lib/debugger.js | 60 +++--- modules/pdp10/lib/defines.js | 2 +- modules/pdp10/lib/memory.js | 2 +- modules/pdp11/lib/cpustate.js | 2 +- modules/pdp11/lib/debugger.js | 20 +- modules/pdp11/lib/device.js | 6 +- modules/shared/lib/debugger.js | 31 ++- modules/shared/lib/strlib.js | 30 +-- versions/pc8080/1.34.0/pc8080-dbg.js | 4 +- versions/pcx86/1.34.0/pcx86-dbg.js | 2 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 296 +++++++++++++-------------- versions/pdpjs/1.34.0/pdp10.js | 2 +- versions/pdpjs/1.34.0/pdp11-dbg.js | 40 ++-- 14 files changed, 260 insertions(+), 239 deletions(-) diff --git a/docs/pcx86/examples/pcx86-dbg.js b/docs/pcx86/examples/pcx86-dbg.js index 5aa39dcbc..07557823e 100644 --- a/docs/pcx86/examples/pcx86-dbg.js +++ b/docs/pcx86/examples/pcx86-dbg.js @@ -718,7 +718,7 @@ case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d function Px(a,b,c){var d;if(b){b=Qx(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function Vx(a,b){if(b)return Tx(a,b,a.da[b]);var c=0;for(b in a.da)Tx(a,b,a.da[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ux(a,b){var c;c=void 0===c?0:c;switch(a.ya){case 8:a=ja(b,0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Wx(a){Nx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=Xx(this);this.Ga=Xx(this);this.Z=Xx(this);this.D=[];this.B=this.Y=this.M=[];Yx(this);this.ta=0;Zx(this);this.za={};$x(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return ay(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return ay(b,a)})}ba(Wx,Nx);l=Wx.prototype; l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Ob(a,"FDC");this.Ha=Ob(a,"HDC");this.Tc=Ob(a,"FPU");this.G=Ob(a,"Mouse");(a=qd(a,"messages"))&&$x(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Kd(this.H,7,"DBG");this.ma=by;80186<=this.H.ca&&(this.ma=by.slice(),this.ma[15]=cy,80286<=this.H.ca&&(this.ma[15]=dy,80386<=this.H.ca&&(this.oa=8)));rl(this,64,function(a){ey(d,d.H.sc,a[0])});rl(this,4,function(a){if(a=a[0]){var b=Rx(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=fy(d, b,gy),d.P("dumpSel("+ka(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=hy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ka(a.ua&65535)+" off="+ka(a.Ka):"base="+q(a.ua,d.ha)+" limit="+iy(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ka(a.ext&-65296)+ diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 173457c11..aad5c5e1a 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -549,7 +549,7 @@ class DebuggerPDP10 extends Debugger { * * @this {DebuggerPDP10} * @param {number|null|undefined} [off] - * @return {string} the hex representation of off + * @return {string} default base representation of off */ toStrOffset(off) { @@ -561,13 +561,29 @@ class DebuggerPDP10 extends Debugger { * * @this {DebuggerPDP10} * @param {DbgAddrPDP10} dbgAddr - * @return {string} the hex representation of the address + * @return {string} default base representation of the address */ toStrAddr(dbgAddr) { return this.toStrOffset(dbgAddr.addr); } + /** + * toStrWord(w) + * + * @this {DebuggerPDP10} + * @param {number} w (up to, but not including, DATA_LIMIT) + * @return {string} octal representation of the 36-bit word, as two 18-bit values + */ + toStrWord(w) + { + /* + * ADDR_LIMIT is not derived from DATA_LIMIT; we're just taking advantage of the fact + * that ADDR_LIMIT happens to be exactly half of DATA_LIMIT, and they are both powers of two. + */ + return Str.toOct(w / PDP10.ADDR_LIMIT, 6) + ' ' + Str.toOct(w % PDP10.ADDR_LIMIT, 6); + } + /** * dumpBlocks(aBlocks, sAddr) * @@ -1759,7 +1775,7 @@ class DebuggerPDP10 extends Debugger { { var opNames = DebuggerPDP10.OPNAMES; var dbgAddrOp = this.newAddr(dbgAddr.addr); - var opCode = this.getWord(dbgAddr, 2); + var opCode = this.getWord(dbgAddr, 1); var opDesc; for (var mask in this.opTable) { @@ -1783,7 +1799,7 @@ class DebuggerPDP10 extends Debugger { var cOperands = opDesc.length - 1; if (!opNum && !cOperands) { - sOperands = this.toStrBase(opCode); + sOperands = this.toStrWord(opCode); } for (var iOperand = 1; iOperand <= cOperands; iOperand++) { @@ -1815,12 +1831,13 @@ class DebuggerPDP10 extends Debugger { var sLine = this.toStrAddr(dbgAddrOp) + ":"; if (dbgAddrOp.addr !== PDP10.ADDR_INVALID && dbgAddr.addr !== PDP10.ADDR_INVALID) { do { - sOpCodes += ' ' + this.toStrBase(this.getWord(dbgAddrOp, 2)); + var w = this.getWord(dbgAddrOp, 1); + sOpCodes += ' ' + this.toStrWord(w); if (dbgAddrOp.addr == null) break; } while (dbgAddrOp.addr != dbgAddr.addr); } - sLine += Str.pad(sOpCodes, 24); + sLine += Str.pad(sOpCodes, 16); sLine += Str.pad(sOpName, 5); if (sOperands) sLine += ' ' + sOperands; @@ -2450,9 +2467,9 @@ class DebuggerPDP10 extends Debugger { var nBase = this.nBase; if (dbgAddr.nBase) this.nBase = dbgAddr.nBase; - var nBitsPerWord = 36; + var size = (sCmd == "db"? 1 : 2); var nWords = len || 32; - var nWordsPerLine = 4; // fJSON? 16 : this.nBase; + var nWordsPerLine = (size == 1? 2 : 4); var nLines = (((nWords + nWordsPerLine - 1) / nWordsPerLine)|0) || 1; var sDump = ""; @@ -2464,23 +2481,22 @@ class DebuggerPDP10 extends Debugger { var w = this.getWord(dbgAddr, 1); if (fJSON) { if (sData) sData += ","; - sData += "0x"+ Str.toHex(w, nBitsPerWord >> 2); + sData += w; } else { - sData += this.toStrBase(w, nBitsPerWord >> 3); - sData += ' '; + sData += this.toStrWord(w); + sData += ' '; } - var nBytesPerWord = nBitsPerWord >> 3; - while (nBytesPerWord--) { - var c = w % 256; - sChars += (c >= 32 && c < 128? String.fromCharCode(c) : '.'); - w /= 256; + for (var i = 0; size == 1 && i < 6; i++) { + var c = ((w % 64)|0) + 33; + sChars += String.fromCharCode(c); + w /= 64; } } if (sDump) sDump += "\n"; if (fJSON) { sDump += sData + ","; } else { - sDump += sAddr + ": " + sData + ((n == 0)? (' ' + sChars) : ""); + sDump += sAddr + ": " + sData + ((n < 0)? (' ' + sChars) : ""); } } @@ -2498,13 +2514,10 @@ class DebuggerPDP10 extends Debugger { */ doEdit(asArgs) { - var size, mask; var fnGet, fnSet; var sCmd = asArgs[0]; var sAddr = asArgs[1]; if (sCmd == "e" || sCmd == "ew") { - size = 2; - mask = 0xffff; fnGet = this.getWord; fnSet = this.setWord; } else { @@ -2523,12 +2536,9 @@ class DebuggerPDP10 extends Debugger { this.println("unrecognized value: " + asArgs[i]); break; } - if (vNew & ~mask) { - this.println("warning: " + Str.toHex(vNew) + " exceeds " + size + "-byte value"); - } - this.println("changing " + this.toStrAddr(dbgAddr) + (this.messageEnabled(MessagesPDP10.BUS)? "" : (" from " + this.toStrBase(fnGet.call(this, dbgAddr), size))) + " to " + this.toStrBase(vNew, size)); + this.println("changing " + this.toStrAddr(dbgAddr) + " from " + this.toStrWord(fnGet.call(this, dbgAddr)) + " to " + this.toStrWord(vNew)); //noinspection JSUnresolvedFunction - fnSet.call(this, dbgAddr, vNew, size); + fnSet.call(this, dbgAddr, vNew, 1); } } diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index a44b303a4..cf0bdcec1 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -97,7 +97,7 @@ var PDP10 = { */ ADDR_INVALID: -1, ADDR_LIMIT: Math.pow(2, 18), - DATA_INVALID: 0, + DATA_INVALID: -1, DATA_LIMIT: Math.pow(2, 36), /* * Assorted common opcodes diff --git a/modules/pdp10/lib/memory.js b/modules/pdp10/lib/memory.js index 6ae06cba9..3c1fcbcd5 100644 --- a/modules/pdp10/lib/memory.js +++ b/modules/pdp10/lib/memory.js @@ -406,7 +406,7 @@ class MemoryPDP10 { this.dbg.printMessage("attempt to read invalid address " + this.dbg.toStrBase(addr), true); } this.bus.fault(addr); - return 0; + return PDP10.DATA_INVALID; } /** diff --git a/modules/pdp11/lib/cpustate.js b/modules/pdp11/lib/cpustate.js index a451ed3bb..c85c84953 100644 --- a/modules/pdp11/lib/cpustate.js +++ b/modules/pdp11/lib/cpustate.js @@ -1596,7 +1596,7 @@ class CPUStatePDP11 extends CPUPDP11 { if (DEBUG && this.dbg) { if (this.messageEnabled(MessagesPDP11.TRAP)) { var sReason = reason < 0? PDP11.REASONS[-reason] : this.dbg.toStrBase(reason); - this.printMessage("trap to vector " + this.dbg.toStrBase(vector, 1) + " (" + sReason + ")", MessagesPDP11.TRAP, true); + this.printMessage("trap to vector " + this.dbg.toStrBase(vector, 8) + " (" + sReason + ")", MessagesPDP11.TRAP, true); } } diff --git a/modules/pdp11/lib/debugger.js b/modules/pdp11/lib/debugger.js index 468738cb9..75121475d 100644 --- a/modules/pdp11/lib/debugger.js +++ b/modules/pdp11/lib/debugger.js @@ -1212,7 +1212,7 @@ class DebuggerPDP11 extends Debugger { if (trapStatus) { var reason = trapStatus >> 8; var sReason = reason < 0? PDP11.REASONS[-reason] : this.toStrBase(reason); - this.println("trapped to " + this.toStrBase(trapStatus & 0xff, 1) + " (" + sReason + ")"); + this.println("trapped to " + this.toStrBase(trapStatus & 0xff, 8) + " (" + sReason + ")"); } this.dbgAddrNextCode = this.newAddr(this.cpu.getPC()); @@ -2073,15 +2073,15 @@ class DebuggerPDP11 extends Debugger { } else if (opTypeOther == DebuggerPDP11.OP_DSTNUM3) { disp = (opCode & 0x07); - sOperand = this.toStrBase(disp, 1); + sOperand = this.toStrBase(disp, 3); } else if (opTypeOther == DebuggerPDP11.OP_DSTNUM6) { disp = (opCode & 0x3f); - sOperand = this.toStrBase(disp, 1); + sOperand = this.toStrBase(disp, 6); } else if (opTypeOther == DebuggerPDP11.OP_DSTNUM8) { disp = (opCode & 0xff); - sOperand = this.toStrBase(disp, 1); + sOperand = this.toStrBase(disp, 8); } else { /* @@ -2123,7 +2123,7 @@ class DebuggerPDP11 extends Debugger { * When using R7 (aka PC), POST-INCREMENT is known as IMMEDIATE */ wIndex = this.getWord(dbgAddr, 2); - sOperand = '#' + this.toStrBase(wIndex, 0, true); + sOperand = '#' + this.toStrBase(wIndex, -1); } break; @@ -2135,7 +2135,7 @@ class DebuggerPDP11 extends Debugger { * When using R7 (aka PC), POST-INCREMENT DEFERRED is known as ABSOLUTE */ wIndex = this.getWord(dbgAddr, 2); - sOperand = "@#" + this.toStrBase(wIndex, 0, true); + sOperand = "@#" + this.toStrBase(wIndex, -1); sTarget = this.getTarget(wIndex); } break; @@ -2150,7 +2150,7 @@ class DebuggerPDP11 extends Debugger { case PDP11.OPMODE.INDEX: // 0x6: INDEX wIndex = this.getWord(dbgAddr, 2); - sOperand = this.toStrBase(wIndex, 0, true) + '(' + this.getRegName(reg) + ')'; + sOperand = this.toStrBase(wIndex, -1) + '(' + this.getRegName(reg) + ')'; if (reg == 7) { /* * When using R7 (aka PC), INDEX is known as RELATIVE. However, instead of displaying @@ -2936,9 +2936,9 @@ class DebuggerPDP11 extends Debugger { if (shift == size) { if (fJSON) { if (sData) sData += ","; - sData += "0x"+ Str.toHex(data, size * 2); + sData += "0x"+ Str.toHex(data, size << 1); } else { - sData += this.toStrBase(data, size); + sData += this.toStrBase(data, size << 3); sData += (size == 1? (i == 9? '-' : ' ') : " "); } data = shift = 0; @@ -3007,7 +3007,7 @@ class DebuggerPDP11 extends Debugger { if (vNew & ~mask) { this.println("warning: " + Str.toHex(vNew) + " exceeds " + size + "-byte value"); } - this.println("changing " + this.toStrAddr(dbgAddr) + (this.messageEnabled(MessagesPDP11.BUS)? "" : (" from " + this.toStrBase(fnGet.call(this, dbgAddr), size))) + " to " + this.toStrBase(vNew, size)); + this.println("changing " + this.toStrAddr(dbgAddr) + (this.messageEnabled(MessagesPDP11.BUS)? "" : (" from " + this.toStrBase(fnGet.call(this, dbgAddr), size << 3))) + " to " + this.toStrBase(vNew, size << 3)); //noinspection JSUnresolvedFunction fnSet.call(this, dbgAddr, vNew, size); } diff --git a/modules/pdp11/lib/device.js b/modules/pdp11/lib/device.js index dfb4b796c..bad3412e6 100644 --- a/modules/pdp11/lib/device.js +++ b/modules/pdp11/lib/device.js @@ -146,16 +146,16 @@ class DevicePDP11 extends Component { if (DEBUGGER) { var dbg = this.dbg; if (sFilter && sName.indexOf(sFilter.toUpperCase()) < 0) return; + var nBits = 0; var nRegs = 8; var sDump = ""; var fIndex = false; - var nBytes = 0; var nWidth = 8; if (offset < 0) { + nBits = 22; nRegs = aRegs.length; offset = 0; fIndex = true; - nBytes = 3; nWidth = 4; } for (var i = 0; i < nRegs; i++) { @@ -163,7 +163,7 @@ class DevicePDP11 extends Component { if (sDump) sDump += '\n'; sDump += sName + (fIndex? ('[' + Str.toDec(i, 2) + ']') : '') + ':'; } - sDump += ' ' + dbg.toStrBase(aRegs[offset + i], nBytes); + sDump += ' ' + dbg.toStrBase(aRegs[offset + i], nBits); } dbg.println(sDump + (fBreak? '\n' : '')); } diff --git a/modules/shared/lib/debugger.js b/modules/shared/lib/debugger.js index 040f86528..5d36aab83 100644 --- a/modules/shared/lib/debugger.js +++ b/modules/shared/lib/debugger.js @@ -647,31 +647,42 @@ class Debugger extends Component { } /** - * toStrBase(n, nBytes, fStripLeadingZeros) + * toStrBase(n, nBits) * - * Use this instead of Str.toHex() or Str.toOct() to convert bytes/words to the Debugger's default base. + * Use this instead of Str's toOct()/toDec()/toHex() to convert numbers to the Debugger's default base. + * + * TODO: The 32-bit limitation on n is imposed by the Str functions we call, not us. Consider modifying + * those functions to support a higher number of bits (eg, 36), using arithmetic operators instead of bit-wise + * operators, and increasing the maximum number of supported bits to at least 52, while still using JavaScript + * floating-point numbers as the underlying data type. + * + * For now, the only component that really cares about supporting more than 32 bits (eg, 36 bits) is the PDP-10 + * Debugger, which currently uses its own functions (eg, toStrWord()) to divide quantities into smaller (eg, 18-bit) + * values. * * @this {Debugger} - * @param {number|null|undefined} n - * @param {number} [nBytes] is the number of bytes to display, which we translate into a number of characters - * @param {boolean} [fStripLeadingZeros] + * @param {number|null|undefined} n (interpreted as a 32-bit value) + * @param {number} [nBits] (-1 to strip leading zeros, 0 to allow a variable number of digits) * @return {string} */ - toStrBase(n, nBytes = 0, fStripLeadingZeros = false) { + toStrBase(n, nBits = 0) { var s; switch(this.nBase) { case 8: - s = Str.toOct(n, nBytes * 3 /* - (nBytes > 2? 1 : 0) */); + s = Str.toOct(n, nBits > 0? ((nBits + 2)/3)|0 : 0); break; case 10: - s = n.toString(); + /* + * The multiplier is actually Math.log(2)/Math.log(10), but an approximation is more than adequate. + */ + s = Str.toDec(n, nBits > 0? Math.ceil(nBits * 0.3) : 0); break; case 16: default: - s = Str.toHex(n, nBytes * 2); + s = Str.toHex(n, nBits > 0? ((nBits + 3) >> 2) : 0); break; } - return (fStripLeadingZeros? Str.stripLeadingZeros(s) : s); + return (nBits < 0? Str.stripLeadingZeros(s) : s); } } diff --git a/modules/shared/lib/strlib.js b/modules/shared/lib/strlib.js index a9dbf0bf8..feabdb7ec 100644 --- a/modules/shared/lib/strlib.js +++ b/modules/shared/lib/strlib.js @@ -143,7 +143,7 @@ class Str { * * Converts an integer to binary, with the specified number of digits (up to the default of 32). * - * @param {number|null|undefined} n is a 32-bit value + * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cch] is the desired number of binary digits (32 is both the default and the maximum) * @param {number} [grouping] * @return {string} the binary representation of n @@ -171,7 +171,7 @@ class Str { s = "," + s; group = grouping; } - s = (fInvalid ? '?' : ((n & 0x1) ? '1' : '0')) + s; + s = (fInvalid? '?' : ((n & 0x1)? '1' : '0')) + s; n >>= 1; group--; } @@ -183,7 +183,7 @@ class Str { * * Converts an integer to binary, with the specified number of bytes (up to the default of 4). * - * @param {number|null|undefined} n is a 32-bit value + * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cb] is the desired number of binary bytes (4 is both the default and the maximum) * @param {boolean} [fPrefix] * @return {string} the binary representation of n @@ -197,7 +197,7 @@ class Str { s = Str.toBin(n & 0xff, 8) + s; n >>= 8; } - return (fPrefix ? "0b" : "") + s; + return (fPrefix? "0b" : "") + s; } /** @@ -209,7 +209,7 @@ class Str { * doesn't properly convert negative values. Moreover, if n is undefined, n.toString() will throw * an exception, whereas this function will return '?' characters. * - * @param {number|null|undefined} n is a 32-bit value + * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cch] is the desired number of octal digits (0 or undefined for default of either 6 or 11) * @param {boolean} [fPrefix] * @return {string} the octal representation of n @@ -221,7 +221,7 @@ class Str { if (cch) { if (cch > 11) cch = 11; } else { - cch = (n & ~0xffffff) ? 11 : ((n & ~0xffff) ? 8 : 6); + cch = (n & ~0xffffff)? 11 : ((n & ~0xffff)? 8 : 6); } /* * An initial "falsey" check for null takes care of both null and undefined; @@ -240,7 +240,7 @@ class Str { n >>= 3; } } - return (fPrefix ? "0o" : "") + s; + return (fPrefix? "0o" : "") + s; } /** @@ -252,7 +252,7 @@ class Str { * doesn't properly convert negative values. Moreover, if n is undefined, n.toString() will throw * an exception, whereas this function will return '?' characters. * - * @param {number|null|undefined} n is a 32-bit value + * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cch] is the desired number of decimal digits (0 or undefined for default of either 5 or 10) * @return {string} the octal representation of n */ @@ -263,7 +263,7 @@ class Str { if (cch) { if (cch > 10) cch = 10; } else { - cch = (n & ~0xffff) ? 10 : 5; + cch = (n & ~0xffff)? 10 : 5; } /* * An initial "falsey" check for null takes care of both null and undefined; @@ -302,7 +302,7 @@ class Str { * s = "00000000".substr(0, 8 - s.length) + s; * s = s.substr(0, cch).toUpperCase(); * - * @param {number|null|undefined} n is a 32-bit value + * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cch] is the desired number of hex digits (0 or undefined for default of either 4 or 8) * @param {boolean} [fPrefix] * @return {string} the hex representation of n @@ -314,7 +314,7 @@ class Str { if (cch) { if (cch > 8) cch = 8; } else { - cch = (n & ~0xffff) ? 8 : 4; + cch = (n & ~0xffff)? 8 : 4; } /* * An initial "falsey" check for null takes care of both null and undefined; @@ -329,12 +329,12 @@ class Str { } else { while (cch-- > 0) { var d = n & 0xf; - d += (d >= 0 && d <= 9 ? 0x30 : 0x41 - 10); + d += (d >= 0 && d <= 9? 0x30 : 0x41 - 10); s = String.fromCharCode(d) + s; n >>= 4; } } - return (fPrefix ? "0x" : "") + s; + return (fPrefix? "0x" : "") + s; } /** @@ -492,7 +492,7 @@ class Str { * and the hyphen is last, you can avoid escaping those as well. */ k = k.replace(/([\\[\]*{}().+?])/g, "\\$1"); - sMatch += (sMatch ? '|' : '') + k; + sMatch += (sMatch? '|' : '') + k; } return s.replace(new RegExp('(' + sMatch + ')', "g"), function(m) { @@ -513,7 +513,7 @@ class Str { static pad(s, cch, fPadLeft) { var sPadding = " "; - return fPadLeft ? (sPadding + s).slice(-cch) : (s + sPadding).slice(0, cch); + return fPadLeft? (sPadding + s).slice(-cch) : (s + sPadding).slice(0, cch); } /** diff --git a/versions/pc8080/1.34.0/pc8080-dbg.js b/versions/pc8080/1.34.0/pc8080-dbg.js index c1fd40e69..1f1887909 100644 --- a/versions/pc8080/1.34.0/pc8080-dbg.js +++ b/versions/pc8080/1.34.0/pc8080-dbg.js @@ -202,8 +202,8 @@ function Vf(a,b,c){var d;if(b){b=Wf(a,b);for(var e=0,f=!1,g=b,h=[],k=[],p=b.spli d))}return d}function Wf(a,b){for(var c,d=/\{(.*?)\}/;(c=b.match(d))&&!(0<=c[1].indexOf("{"));){var e=Vf(a,c[1]);b=b.replace("{"+c[1]+"}",null!=e?$f(a,e):"undefined")}for(;(c=b.match(/\[(.*?)]/))&&!(0<=c[1].indexOf("["));)b=b.replace("["+c[1]+"]","unimplemented");for(;c=b.match(/\$([a-z]+)/i);){d=null;switch(c[1].toLowerCase()){case "ops":d=a.N-a.Y}if(null==d)break;b=b.replace(c[0],d.toString())}return b} function Xf(a,b,c,d){var e;null!=b?(e=a.Kb(b),0<=e?e=a.Lb(e):(e=a.S[b],null==e&&(e=Ha(b,a.na))),null!=e||d||a.i("invalid "+(c?c:"value")+": "+b)):d||a.i("missing "+(c||"value"));return e} function Zf(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var f=4,g="";if(!f||4>=1,y--;g=v+g;d>>=8}d=t(c,0,!0)+" "+c+". "+Ia(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.i((null!=b?b+": ":"")+d);return e} -function ag(a,b){if(b)return Zf(a,b,a.S[b]);var c=0;for(b in a.S)Zf(a,b,a.S[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function bg(a){Tf.call(this,a);this.style=cg;this.F=dg();this.la=dg();this.O=dg();this.A=[];this.j=this.I=this.w=[];eg(this);this.W=0;fg(this);this.Z={};gg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Fc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Fc(b,a)})}aa(bg,Tf);l=bg.prototype; +function ag(a,b){if(b)return Zf(a,b,a.S[b]);var c=0;for(b in a.S)Zf(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Yf={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};function bg(a){Tf.call(this,a);this.style=cg;this.F=dg();this.la=dg();this.O=dg();this.A=[];this.j=this.I=this.w=[];eg(this);this.W=0;fg(this);this.Z={};gg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Fc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Fc(b,a)})}aa(bg,Tf);l=bg.prototype; l.Ea=function(a,b,c,d){this.H=b;this.u=c;this.R=a;(a=Bc(a,"messages"))&&gg(this,a);this.ga=hg;Sd(this,64,function(a){a:{var b=d.H.b,c=a[0],e=a=0,k=b.length;if(c){a=ig(jg(d,c));if(-1===a){d.i("invalid address: "+c);break a}e=a>>>d.H.g;k=1}d.i("blockid physical blockaddr used size type");d.i("-------- --------- ---------- ------ ------ ----");for(var c=-1,p=0;k--;){var u=b[e];u.type==c?p++||d.i("..."):(c=u.type,p=Ib[c],u&&d.i(t(u.id)+" %"+t(e<=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function Vx(a,b){if(b)return Tx(a,b,a.da[b]);var c=0;for(b in a.da)Tx(a,b,a.da[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ux(a,b){var c;c=void 0===c?0:c;switch(a.ya){case 8:a=ja(b,0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Wx(a){Nx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=Xx(this);this.Ga=Xx(this);this.Z=Xx(this);this.D=[];this.B=this.Y=this.M=[];Yx(this);this.ta=0;Zx(this);this.za={};$x(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return ay(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return ay(b,a)})}ba(Wx,Nx);l=Wx.prototype; l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Ob(a,"FDC");this.Ha=Ob(a,"HDC");this.Tc=Ob(a,"FPU");this.G=Ob(a,"Mouse");(a=qd(a,"messages"))&&$x(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Kd(this.H,7,"DBG");this.ma=by;80186<=this.H.ca&&(this.ma=by.slice(),this.ma[15]=cy,80286<=this.H.ca&&(this.ma[15]=dy,80386<=this.H.ca&&(this.oa=8)));rl(this,64,function(a){ey(d,d.H.sc,a[0])});rl(this,4,function(a){if(a=a[0]){var b=Rx(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=fy(d, b,gy),d.P("dumpSel("+ka(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=hy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ka(a.ua&65535)+" off="+ka(a.Ka):"base="+q(a.ua,d.ha)+" limit="+iy(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ka(a.ext&-65296)+ diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 465ffc82a..3eaf02134 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -28,8 +28,8 @@ http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ea(){ea=function(){};ba.Symbol||(ba.Symbol=fa)}var ga=0;function fa(a){return"jscomp_symbol_"+(a||"")+ga++} -function ha(){ea();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return oa(this)}});ha=function(){}}function oa(a){var b=0;return pa(function(){return ba?-b:b}});qa("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); var ra=Math.pow(2,36),sa=-Math.pow(2,35),t={Vb:0,jb:1,Xb:2,Yb:3,Zb:4,$b:5,ac:6,bc:7,Wa:8,cc:9,kb:10,dc:11,ec:12,lb:13,fc:14,gc:15,hc:16,ic:17,jc:18,kc:19,lc:20,mc:21,nc:22,oc:23,pc:24,qc:25,rc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Va:65,Ub:66,Wb:67,sc:68,E:69,tc:70,uc:71,vc:72,wc:73,xc:74,yc:75,zc:76,Ac:77,Bc:78,Cc:79,Dc:80,Q:81, Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Mc:97,Nc:98,Oc:99,d:100,e:101,Pc:102,Qc:103,Rc:104,Sc:105,Tc:106,k:107,Uc:108,Vc:109,n:110,Wc:111,p:112,q:113,r:114,Xc:115,t:116,Zc:117,$c:118,ad:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,mb:127}; @@ -38,167 +38,167 @@ function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window. function z(a,b){var c;if(void 0!==a){var d;b&&(b=0<(d=b.indexOf("."))?b.substr(0,d+1):"");for(d=0;d>=3;return(c?"0o":"")+d}function H(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} -function I(a){return H(a,4,!0)}function Qa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return gb[a]})}function hb(a,b){return(a+" ").slice(0,b)} -function ib(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var gb={"&":"&","<":"<",">":">",'"':""","'":"'"};function jb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function Pa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=3;return(c?"0o":"")+d}function H(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} +function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)} +function fb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function lb(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else d.W=f;d.S=f.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, -set:this.Mb};E(this)}q(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; +function Ua(){return"http://"+(window?window.location.host:"www.pcjs.org")}function jb(){if(null==kb){var a=!1;if(window)try{window.localStorage.setItem("PCjs.localStorage","PCjs.localStorage"),a="PCjs.localStorage"==window.localStorage.getItem("PCjs.localStorage"),window.localStorage.removeItem("PCjs.localStorage")}catch(b){a=!1}kb=a}return kb}function lb(a){var b;if(window)try{b=window.localStorage.getItem(a)}catch(c){}return b} +function mb(a,b){try{return window.localStorage.setItem(a,b),!0}catch(c){}return!1}function nb(a){if(window){var b=window?window.navigator.userAgent:"";return"iOS"==a&&!!b.match(/(iPod|iPhone|iPad)/)&&!!b.match(/AppleWebKit/)||"MSIE"==a&&!!b.match(/(MSIE|Trident)/)||0<=b.indexOf(a)}return!1} +function ob(a){if(!pb){var b,c={};if(window){b||(b=window.location.search.substr(1));for(var d,e=/\+/g,g=/([^&=]+)=?([^&]*)/g;d=g.exec(b);)c[decodeURIComponent(d[1].replace(e," "))]=decodeURIComponent(d[2].replace(e," "))}pb=c}return pb[a]}function qb(a,b,c){function d(){--a;0<=a&&(b()||(a=0));0a;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, +set:this.Mb};E(this)}r(Ib,u);l=Ib.prototype;l.reset=function(a){this.stop();a&&Kb(this,this.w=0)}; l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, -b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Nb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Ob(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Pb(this);Qb(this)};l.la=function(a,b){if(!b)if(this.U&&Rb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()};l.restore=function(a){if(a=a[0])Sb(this,this.j=a[0]),Mb(this,this.w=a[1]),Tb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Qb(this);return!0};function Ub(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Pb(a,b){for(var c in a.B)Ub(a,c,null!=b?b:a.B[c])} -function Vb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Qb(a){for(var b in a.g)Vb(a,b,a.g[b][1])}l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d,b);a&&a()},+c);return!1}Ob(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Tb(this,Oa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Vb(this,a,c[1]),!0):!1};l.Nb=function(a){return Nb(this,a)?(Ob(this,a),!0):!1}; -function Nb(a,b){var c=a.g[b];return c?(Vb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Wb&&(a.N=b==Xb,a.O=b==Yb),!0):!1}function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Ib,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; -l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ac(a,0,null),Ma(a,!1);else try{var b=this.b.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.v+m;e=k+16384;g-=m;f++;continue}}return lc(mc,e,g)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Pa(b)),!0):lc(oc,b,c)} -function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(b&16383,c&65535,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Zc(a)&&(a.P=a.Z=-1,Vc(a),a.R(),c=!0);c&&a.f(Zc(a)+" cycles: checksum="+H(a.ma))}} -l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&cd(a.D)}cc(a,a.w);a.w=0;a.u=va();a.G=0;ad(a);return d}function dd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ed(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function fd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} -l.Kb=function(){if(this.i.J){this.qa>=this.Aa&&ad(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=dd(this,this.i.Ca?1:this.oa);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=fd(this,!0);this.aa+=b;this.w+=b;dc(this,b);bc(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=gd&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Zc(this));Ia(this,e.stack|| -e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,$c(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.qa+=this.aa;this.G+=c;a(b,c)}}}; -function $b(a,b){if(!Ja(a))if(a.i.J)a.f(a.toString()+" busy");else{$c(a);a.i.J=!0;a.i.Ra=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&cd(a.D,!0),a.D.start(a.u,Zc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){fd(this);cc(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Zc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var bd=30,gd=15,Sc=["power","reset"]; -function hd(a){var b=+a.model||1001;Rc.call(this,a,1E6);this.Za=b;this.Ma=+a.addrReset||0;this.fa=null;this.Da=[];this.i.complete=!1}q(hd,Rc);l=hd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.ra=this.Ma;this.j=0;this.ta=this.Gb;this.Ia=this.Tb;this.fa=null;Uc(this);this.i.error=!1;Rc.prototype.reset.call(this)};l.gb=function(){return 0}; -l.save=function(){var a=new O(this);a.set(0,[this.g,this.ra,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,id(this));a.set(4,ed(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):oa(b);this.g=b.next().value;this.ra=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];$c(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(a&16383,b,a)}; -l.Ja=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.g;this.ta(a);this.g=(a+1)%Ib}while(0>>g.j;0>>= -g.j;0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,r=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(r&255)+(r>>8)),K=k,ya=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(ya)for(G(a,"loading "+I(ya)+" bytes at "+I(r)+"-"+I(r+ya),4096);ya--;)fc(a.C,r++,b[K++]);else r&1?f=!0:null==d&&(d=r),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Va&&c<=t.ob&&(b=c-(t.Va-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Pa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Pa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +b){return function(){Lb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Mb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Lb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Mb(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Nb(this);Ob(this)};l.la=function(a,b){if(!b)if(this.U&&Pb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()};l.restore=function(a){if(a=a[0])Qb(this,this.j=a[0]),Kb(this,this.w=a[1]),Rb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Ob(this);return!0};function Sb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Nb(a,b){for(var c in a.B)Sb(a,c,null!=b?b:a.B[c])} +function Tb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ob(a){for(var b in a.g)Tb(a,b,a.g[b][1])}l.sb=function(a,b,c){if(Lb(this,b)){if(c){var d=this;setTimeout(function(){Mb(d,b);a&&a()},+c);return!1}Mb(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Rb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Tb(this,a,c[1]),!0):!1};l.Nb=function(a){return Lb(this,a)?(Mb(this,a),!0):!1}; +function Lb(a,b){var c=a.g[b];return c?(Tb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Ub&&(a.N=b==Vb,a.O=b==Wb),!0):!1}function Mb(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Tb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Xb]&&this.g[Xb][1]&&Yb(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; +l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Xb]&&this.g[Xb][1])Yb(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),Zb(a,0,null),Na(a,!1);else try{var b=this.b.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.v+m;e=k+16384;g-=m;f++;continue}}return jc(kc,e,g)}e=new V(a,e,m,16384,d);gc(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+lc[d]+" at "+Qa(b)),!0):jc(mc,b,c)} +function ec(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function dc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(b&16383,c&65535,b);a.w--}function hc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Xc(a)&&(a.P=a.Z=-1,Tc(a),a.R(),c=!0);c&&a.f(Xc(a)+" cycles: checksum="+H(a.ma))}} +l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&ad(a.D)}ac(a,a.w);a.w=0;a.u=va();a.G=0;Zc(a);return d}function bd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function cd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function dd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} +l.Kb=function(){if(this.i.J){this.qa>=this.Aa&&Zc(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=bd(this,this.i.Ca?1:this.oa);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=dd(this,!0);this.aa+=b;this.w+=b;bc(this,b);$b(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=ed&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Xc(this));Ja(this,e.stack|| +e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,Yc(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.qa+=this.aa;this.G+=c;a(b,c)}}}; +function Yb(a,b){if(!Ka(a))if(a.i.J)a.f(a.toString()+" busy");else{Yc(a);a.i.J=!0;a.i.Ra=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&ad(a.D,!0),a.D.start(a.u,Xc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){dd(this);ac(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Xc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var $c=30,ed=15,Qc=["power","reset"]; +function fd(a){var b=+a.model||1001;Pc.call(this,a,1E6);this.Za=b;this.Ma=+a.addrReset||0;this.fa=null;this.Da=[];this.i.complete=!1}r(fd,Pc);l=fd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.ra=this.Ma;this.j=0;this.ta=this.Gb;this.Ia=this.Tb;this.fa=null;Sc(this);this.i.error=!1;Pc.prototype.reset.call(this)};l.gb=function(){return 0}; +l.save=function(){var a=new O(this);a.set(0,[this.g,this.ra,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,gd(this));a.set(4,cd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.g=b.next().value;this.ra=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];Yc(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(a&16383,b,a)}; +l.Ja=function(a){this.i.complete=!0;var b=this.A?hd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(id(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&id(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>g.j;0>>= +g.j;0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,za=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= +b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(za)for(G(a,"loading "+I(za)+" bytes at "+I(q)+"-"+I(q+za),4096);za--;)dc(a.C,q++,b[K++]);else q&1?f=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Va&&c<=t.ob&&(b=c-(t.Va-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Pa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Pa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Pa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; -l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=ib(c[0]);if(d!=this.Ka)return;c=ib(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Pa=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(ib(b.substring(c,g))),c=g+1}}return a} -function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +l.ib=function(a){if(!this.g){var b=Rc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=fb(c[0]);if(d!=this.Ka)return;c=fb(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Pa=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(fb(b.substring(c,g))),c=g+1}}return a} +function td(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Pa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Cd(a){td.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Ed(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Fd(this,a.messages);this.ra=a.commands;this.Ba=Gd;this.Ma=[];this.L=0;this.Da=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]= -function(a){return Yc(b,a)})}q(Cd,td);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Hd(a){return[a.v,a.qb,a.ba,a.ka,a.Qa]}function Id(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=ud(a,c.Qa=b[4]));return c}l=Cd.prototype; -l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Tc(a,"messages"))&&Fd(this,a);Jd(this,function(a){a:{var b=d.C.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=nc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0}l.va=function(a,b,c){var d=!0;c||te(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(ue(this,a,a.length-1,"set"),Ed(this)));return d}; -function te(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Ed(a);break}}return g}function ve(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],p=jb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})} -function Ae(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=xe(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} -function we(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ka(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Xd&&(Wa=1E5,tc=["CALL"]);for(void 0!==Wd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;Zd++;Wa--}}Zd||(a.f("no "+Yd+"history available"), -a.pa=void 0)}else{var ja=Z(a,R);if(ja){var ka=0,be="ds"==Ua;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||gf,ka=yd(a,ca);else{var ce=Z(a,ca);ce&&(ka=ce.v-ja.v)}0>ka&&(ka=0);65536wc?String.fromCharCode(wc):"."),Ya=Ya/ -256}la&&(la+="\n");la=be?la+(ma+","):la+(R+": "+ma+(de?"":" "+vc))}la&&a.f(la);a.xa=ja;a.ba=jf}}}}break;case "e":if("else"==f[0])break;var Za,ee,fe,ge,he=f[0],xc=f[1];"e"==he||"ew"==he?(Za=2,ee=65535,fe=a.wa,ge=a.Xa):xc=null;if(null==xc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,xc);if(Cb)for(var Db=2;DbAc;){for(var na=null,of=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!of--)break;if(!(Bc.v&1)){for(var pf=a,Eb=Bc,je=null,cb=Eb.v,ke=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> "; -M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bLe){if(Me(d,this.K)){this.B=new O(this,"1.34.0",Ve);Me(this.B)&&(We(this,d),a=Xe,Ye(this.B));this.B.set(Se,kb());Ze(this.B);var e=this.g&&!this.I;if(a==Te||wa("Click OK to restore the previous "+Hb+" machine state, or CANCEL to reset the machine.")){if(c=Re(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Me(d,f):("error"==g&&"no machine state"!= -f?(this.Y("Error: "+f),"unable to verify user"==f&&(pb($e,""),this.j=null)):this.f(g+": "+f),Ye(d),Me(d)?(c=Re(d),e=!0):c=!1))}e&&Pe(this,c?d:null)}else a==Xe&&d.clear()}else Pe(this);delete this.K;delete this.H}e=y(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(af(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(We(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function We(a,b){if(wa("There may be a problem with your "+Hb+" machine.\n\nTo help us diagnose it, click OK to send this "+Hb+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Hb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function Ge(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new O(a,"1.34.0"),f=new O(a,"1.34.0",Qe),h=kb();f.set(Se,h);g.set(Se,h);g.set(bf,"1.34.0");g.set(cf,window?window.location.href:null);g.set(df,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&g.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function zd(a,b){if(b)return yd(a,b,a.Z[b]);var c=0;for(b in a.Z)yd(a,b,a.Z[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var xd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ad(a){rd.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Bd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Cd(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Dd(this,a.messages);this.ra=a.commands;this.Ba=Ed;this.Ma=[];this.L=0;this.Da=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Wc(b,a)}):void 0===global[C]&&(global[C]= +function(a){return Wc(b,a)})}r(Ad,rd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Fd(a){return[a.v,a.qb,a.ba,a.ka,a.Qa]}function Gd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=sd(a,c.Qa=b[4]));return c}l=Ad.prototype; +l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Rc(a,"messages"))&&Dd(this,a);Hd(this,function(a){a:{var b=d.C.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=lc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} +function Bd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0}l.va=function(a,b,c){var d=!0;c||ue(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(ve(this,a,a.length-1,"set"),Cd(this)));return d}; +function ue(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Cd(a);break}}return g}function we(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})} +function Be(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=ye(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} +function xe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Pd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var sc=[];"call"==Wd&&(Ya=1E5,sc=["CALL"]);for(void 0!==Vd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;Yd++;Ya--}}Yd||(a.f("no "+Xd+"history available"), +a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ae="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||hf,la=wd(a,ca);else{var be=Z(a,ca);be&&(la=be.v-ka.v)}0>la&&(la=0);65536fe;fe++)de+=String.fromCharCode((Ab%64|0)+33), +Ab/=64}ma&&(ma+="\n");ma=ae?ma+(na+","):ma+(R+": "+na+(0>ee?" "+de:""))}ma&&a.f(ma);a.xa=ka;a.ba=kf}}}}break;case "e":if("else"==f[0])break;var ge,he,ie=f[0],vc=f[1];"e"==ie||"ew"==ie?(ge=a.wa,he=a.Xa):vc=null;if(null==vc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Bb=Z(a,vc);if(Bb)for(var Cb=2;Cbzc;){for(var oa=null,of=256;65536>ab.v>>>0;){Ac.v=a.wa(ab,2);if(null==ab.v||!of--)break;if(!(Ac.v&1)){for(var pf=a,Db=Ac,ke=null,bb=Db.v,le=bb,Bc=1;6>=Bc&&bb;Bc++){if(2> "; +M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bMe){if(Ne(d,this.K)){this.B=new O(this,"1.34.0",We);Ne(this.B)&&(Xe(this,d),a=Ye,Ze(this.B));this.B.set(Te,hb());$e(this.B);var e=this.g&&!this.I;if(a==Ue||wa("Click OK to restore the previous "+Fb+" machine state, or CANCEL to reset the machine.")){if(c=Se(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Ne(d,f):("error"==g&&"no machine state"!= +f?(this.Y("Error: "+f),"unable to verify user"==f&&(mb(af,""),this.j=null)):this.f(g+": "+f),Ze(d),Ne(d)?(c=Se(d),e=!0):c=!1))}e&&Qe(this,c?d:null)}else a==Ye&&d.clear()}else Qe(this);delete this.K;delete this.H}e=y(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(bf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(Xe(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function Xe(a,b){if(wa("There may be a problem with your "+Fb+" machine.\n\nTo help us diagnose it, click OK to send this "+Fb+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Fb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} +function He(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new O(a,"1.34.0"),f=new O(a,"1.34.0",Re),h=hb();f.set(Te,h);g.set(Te,h);g.set(cf,"1.34.0");g.set(df,window?window.location.href:null);g.set(ef,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&g.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Pa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, "");a=a.replace(d[0],f);Af(a,b,c)}})}else c(a,null)} -function Bf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--xf||zb(!0));m=!1}var h,k,m=!0;xf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css";r.styleSheet?r.styleSheet.cssText=n:r.appendChild(document.createTextNode(n));p.appendChild(r)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?yf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--xf||zb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--xf|| -zb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?yf(c,b,a,e,!0,g,n):zf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(K){f(K.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Bf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Bf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Ea[a]){for(var c=!0,d=Ea,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n>>a.f;0=c+d?a>>c&(1<=c+d?a>>c&(1<>=1,f--;return d}function E(a,b,c){var d="";b?11>=3;return(c?"0o":"")+d} -function Ma(a){var b=2,c="";b?10=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Na(a){return F(a,4,!0)} +function Ma(a,b){var c="";b?10=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Na(a){return F(a,4,!0)} function Oa(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return Sa[a]})}function Xa(a,b){return(a+" ").slice(0,b)} function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Sa={"&":"&","<":"<",">":">",'"':""","'":"'"},Za={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function $a(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,k;k=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} @@ -100,7 +100,7 @@ function Ic(a,b,c){var d=!1,e=this.controller,f=e.Pa[a],g=c&65535;if(f)if(f[1])f b),!0,!e.na))}function Jc(a,b){var c=-1,d=this.controller;a=d.Pa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".readWord("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,2);c=65535;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to word @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} function Kc(a,b,c){var d=!1,e=this.controller;a=e.Pa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d?this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,4),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to word @"+K(this.f,c)+": "+K(this.f,b),!0,!e.na))}function L(a){u.call(this,"Device",a,256);this.b={gb:128,Hd:-1}}p(L,u);h=L.prototype; h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.F=d;var e=this;this.b.Hd=ld(c,function(){e.b.gb|=128;e.b.gb&64&&md(e.f,e.b.Qa);e.J&&H(e.J,1);nd(e.f,e.b.Hd,1E3/60)});this.b.Qa=od(c,64,6,2097152);Xb(b,this,pd);ec(b,this.reset.bind(this));d&&qd(d,64,function(a){var b=e.f;rd(e,"KIPDR",b.B[0],0,a[0]);rd(e,"KDPDR",b.B[0],8,a[0]);rd(e,"KIPAR",b.M[0],0,a[0]);rd(e,"KDPAR",b.M[0],8,a[0],!0);rd(e,"SIPDR",b.B[1],0,a[0]);rd(e,"SDPDR",b.B[1],8,a[0]);rd(e,"SIPAR",b.M[1],0,a[0]);rd(e,"SDPAR",b.M[1],8,a[0], -!0);rd(e,"UIPDR",b.B[3],0,a[0]);rd(e,"UDPDR",b.B[3],8,a[0]);rd(e,"UIPAR",b.M[3],0,a[0]);rd(e,"UDPAR",b.M[3],8,a[0],!0);b.W&32&&rd(e,"UNIMAP",b.Ha,-1,a[0])});y(this)};function rd(a,b,c,d,e,f){a=a.F;if(!(e&&0>b.indexOf(e.toUpperCase()))){e=8;var g="",k=!1,l=0,m=8;0>d&&(e=c.length,d=0,k=!0,l=3,m=4);for(var n=0;nb.indexOf(e.toUpperCase()))){e=0;var g=8,k="",l=!1,m=8;0>d&&(e=22,g=c.length,d=0,l=!0,m=4);for(var n=0;n>1&63;var b=this.f.Ha[a>>1];return a&1?b>>16:b&65535};h.mi=function(a,b){b=b>>1&63;var c=b>>1;this.f.Ha[c]=b&1?this.f.Ha[c]&65535|(a&63)<<16:this.f.Ha[c]&-65536|a&65534};h.Pg=function(a){return this.f.B[1][a>>1&7]};h.fi=function(a,b){this.f.B[1][b>>1&7]=a&65295};h.Ng=function(a){return this.f.B[1][(a>>1&7)+8]};h.di=function(a,b){this.f.B[1][(b>>1&7)+8]=a&65295};h.Og=function(a){return this.f.M[1][a>>1&7]}; h.ei=function(a,b){b=b>>1&7;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.Mg=function(a){return this.f.M[1][(a>>1&7)+8]};h.ci=function(a,b){b=(b>>1&7)+8;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.eg=function(a){return this.f.B[0][a>>1&7]};h.xh=function(a,b){this.f.B[0][b>>1&7]=a&65295};h.cg=function(a){return this.f.B[0][(a>>1&7)+8]};h.vh=function(a,b){this.f.B[0][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.f.M[0][a>>1&7]};h.wh=function(a,b){b=b>>1&7;this.f.M[0][b]=a;this.f.B[0][b]&=65295}; @@ -166,10 +166,10 @@ function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,6),a.lc(e,d.call function $e(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} h.Cc=function(a){this.A.complete=!0;var b=this.F?af(this.F)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.lb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(bf(this.F,this.g[7],c)){this.ba();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.ob&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& 1&&this.i++;if(a){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.Sd(f)}while(0>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Da(a);return a}function Ff(a,b){a=b&~a;this.Da(a<<8);return a} +function cf(a,b){var c=b+a;this.I=this.L=this.C=c;this.G=(a^c)&(b^c);return c&65535}function zf(a,b){var c=b+a,d=c<<8;this.I=this.L=this.C=d;this.G=(a<<8^d)&(b<<8^d);return c&255}function Af(a,b){a=b<<1;Ie(this,a);return a&65535}function Bf(a,b){a=b<<1;Ie(this,a<<8);return a&255}function Cf(a,b){a=b&32768|b>>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Da(a);return a}function Ff(a,b){a=b&~a;this.Da(a<<8);return a} function Gf(a,b){a|=b;this.Da(a);return a}function Hf(a,b){a|=b;this.Da(a<<8);return a}function If(a,b){a=~b|65536;this.qb(a);return a&65535}function Jf(a,b){a=~b|256;this.qb(a<<8);return a&255}function Kf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Lf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Mf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Nf(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} function Of(a,b){a=-b;this.qb(a,a&b&32768);return a&65535}function Pf(a,b){a=-b;this.qb(a<<8,(a&b&128)<<8);return a&255}function Qf(a,b){a=b<<1|this.C>>16&1;Ie(this,a);return a&65535}function Rf(a,b){a=b<<1|this.C>>16&1;Ie(this,a<<8);return a&255}function Sf(a,b){a=(this.C&65536|b)>>1|b<<16;Ie(this,a);return a&65535}function Tf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Ie(this,a<<8);return a&255}function Uf(a,b){var c=b-a;Je(this,c,a,b);return c&65535} -function Vf(a,b){var c=b-a;Je(this,c<<8,a<<8,b<<8);return c&255}function Wf(a,b){this.I=this.L=b&65280;this.G=this.C=0;return(b<<8|b>>8)&65535}function Xf(a,b){a^=b;this.Da(a);return a&65535}function Yf(a){P(this,a,Ue(this,a),yf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} +function Vf(a,b){var c=b-a;Je(this,c<<8,a<<8,b<<8);return c&255}function Wf(a,b){this.I=this.L=b&65280;this.G=this.C=0;return(b<<8|b>>8)&65535}function Xf(a,b){a^=b;this.Da(a);return a&65535}function Yf(a){P(this,a,Ue(this,a),cf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} function Zf(a){var b=Xe(this,a);a=a>>6&7;var c=this.g[a];c&32768&&(c|=4294901760);this.C=this.G=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.G=32768)}this.g[a]=c&65535;this.I=this.L=c;this.b-=(this.u?6:7)+b} function $f(a){var b=Xe(this,a);a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&=63;if(b&32){b=64-b;32>b-1;this.C=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.g[a|1]=d&65535;this.I=d>>16;this.L=d>>16|d;this.b-=(this.u?6:7)+b}function ag(a){Fe(this,a,!Ae(this))}function bg(a){Fe(this,a,Ae(this))} function cg(a){P(this,a,Ue(this,a),Ef);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function dg(a){Ye(this,a,Te(this,a),Ff);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function eg(a){P(this,a,Ue(this,a),Gf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function fg(a){Ye(this,a,Te(this,a),Hf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} @@ -184,7 +184,7 @@ function Rg(a){a&1&&(this.C=65536);a&2&&(this.G=32768);a&4&&(this.L=0);a&8&&(thi function Wg(){this.sa&&(this.sa.Gd(this.g[7],!0),this.sa.setData(this.g[0],!0));this.i|=8;Ee(this,-2);this.b-=3}function Xg(a){P(this,a,this.g[(a>>6&7)+this.zc],Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.F)b=this.F,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Cg(b)):b=!1;b||this.ra(8,0,-9)}function ve(a){Yg[a>>12].call(this,a)}function Zg(a){$g[a>>6&3].call(this,a)}function ah(a){bh[a>>6&3].call(this,a)}function ch(a){dh[a>>6&3].call(this,a)} function eh(a){fh[a&15].call(this,a)}function gh(a){hh[a&15].call(this,a)}function ih(a){jh[a>>6&3].call(this,a)}function kh(a){lh[a>>6&3].call(this,a)}function mh(a){nh[a>>6&3].call(this,a)} var Yg=[function(a){oh[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,Q,function(a){ph[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],oh=[function(a){qh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,Q,Q,Q],$g=[function(a){$e(this,a,0,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,If);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Mf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Kf);this.b-=this.u?9:3+(7==this.j?2:0)}],bh=[function(a){P(this,a,0,Of); -this.b-=this.u?11:6},function(a){P(this,a,Ae(this)?1:0,yf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Ae(this)?1:0,Uf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this,a);this.qb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],dh=[function(a){P(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Qf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Af);this.b-=this.u?9:3+(7==this.j?2:0)}],qh= +this.b-=this.u?11:6},function(a){P(this,a,Ae(this)?1:0,cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Ae(this)?1:0,Uf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this,a);this.qb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],dh=[function(a){P(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Qf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Af);this.b-=this.u?9:3+(7==this.j?2:0)}],qh= [function(a){rh[a&15].call(this,a)},Q,Q,Q,Fg,Fg,Fg,Fg,Pg,Q,eh,gh,Ug,Ug,Ug,Ug],rh=[Bg,Wg,Qg,sg,Dg,Og,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q],fh=[Ng,function(){this.C=0;this.b-=5},function(){this.G=0;this.b-=5},wg,function(){this.L=1;this.b-=5},wg,wg,wg,function(){this.I=0;this.b-=5},wg,wg,wg,wg,wg,wg,wg],hh=[Ng,function(){this.C=65536;this.b-=5},function(){this.G=32768;this.b-=5},Rg,function(){this.L=0;this.b-=5},Rg,Rg,Rg,function(){this.I=32768;this.b-=5},Rg,Rg,Rg,Rg,Rg,Rg,Rg],ph=[rg,pg,lg,ng,ug,vg,ag,bg,Ag,Vg,ih,kh, mh,Q,Q,Q],jh=[function(a){Ze(this,a,0,255,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Jf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Nf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,1,Lf);this.b-=this.u?9:3+(7==this.j?2:0)}],lh=[function(a){Ye(this,a,0,Pf);this.b-=this.u?11:6},function(a){Ye(this,a,Ae(this)?1:0,zf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,Ae(this)?1:0,Vf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=We(this, a);this.qb(a<<8);this.b-=this.u?4:3+(7==this.j?2:0)}],nh=[function(a){Ye(this,a,0,Tf);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Rf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ye(this,a,0,Df);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ye(this,a,0,Bf);this.b-=this.u?9:3+(7==this.j?2:0)}];function we(a){sh[a>>12].call(this,a)} @@ -292,7 +292,7 @@ case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d function zj(a,b,c){var d;if(b){b=Aj(a,b);for(var e=0,f=!1,g=b,k=[],l=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=8;d=F(c,0,!0)+" "+c+". "+E(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.v((null!=b?b+": ":"")+d);return e} -function Ej(a,b){if(b)return Dj(a,b,a.S[b]);var c=0;for(b in a.S)Dj(a,b,a.S[b]),c++;return 0=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ej(a,b){if(b)return Dj(a,b,a.S[b]);var c=0;for(b in a.S)Dj(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Cj={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Fj(a){wj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.Fa=X();this.N=X();this.B=[];this.b=this.L=this.C=[];Gj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Hj(this);this.F=this;this.ka={};this.ha=this.ke=0;this.R=null;this.M=[];Ij(this,a.messages);this.ta=a.commands;this.Ja=Jj;this.W=[];this.I=0;this.Ka=this.sa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.g=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return ke(b,a)}):void 0===global[w]&&(global[w]= function(a){return ke(b,a)})}p(Fj,wj);function Kj(a){a=a&&a.K;null==a&&(a=-1);return a}function X(a,b,c){return{K:void 0===a?null:a,Ma:void 0===b?!1:b,Ua:!1,Aa:c}}h=Fj.prototype;h.Gd=function(a,b){a.K=b;a.Ua=!1;a.Aa=void 0;return a};function Lj(a){return[a.K,a.Ma,a.Aa,a.Ua,a.Pc]}function Mj(a,b){var c=X(b[0],b[1],b[2]);c.Ua=b[3];b[4]&&(c.he=xj(a,c.Pc=b[4]));return c} h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.g=a.i;(a=fe(a,"messages"))&&Ij(this,a);1140>this.f.ka&&(this.W=this.W.concat(Nj));1145>this.f.ka&&(this.W=this.W.concat(Oj));qd(this,16,function(a){a:{var b=d.D.b,c=a[0],e=a=0,l=b.length;if(c){a=Kj(Pj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.D.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): @@ -308,7 +308,7 @@ h.Ad=function(a){var b;if(0<=a)if(8>a)b=this.f.g[a];else if(16>a)b=this.f.ta[a-8 h.message=function(a,b){b&&(a+=" @"+Sj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ba(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,qe(a),a.Ab=0,a.J&&H(a.J,void 0))}}; function Hj(a){var b;if(!af(a))a.i&&a.i.length&&a.v("instruction history buffer freed"),a.P=0,a.i=[];else if(!a.i||!a.i.length){a.i=Array(hk);for(b=0;b>8;a.v("trapped to "+K(a,c&255,1)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?lk(a):mk(a)}}function jk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.aa?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; +function ie(a,b,c){if(a.Ga){void 0===b&&(b=!0);c&&a.v(kk+c);c=a.f;if(c=c.i&128?c.Dc|c.Ac<<8:0){var d=c>>8;a.v("trapped to "+K(a,c&255,8)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?lk(a):mk(a)}}function jk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.aa?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; h.Ba=function(a,b){b&&this.v(a?"suspending":"shutting down");return a?this.save():!0};h.reset=function(a){Hj(this);this.X=0;this.R=null;this.w=0;this.G=X(this.f.g[7]);this.A.V=!1;nk(this);a||ie(this)};h.save=function(){var a=new G(this);a.set(0,Lj(this.G));a.set(1,Lj(this.N));a.set(2,[this.j,this.O,this.ha]);a.set(3,this.B);return a.data()}; h.restore=function(a){var b=0;void 0!==a[2]&&(this.G=Mj(this,a[b++]),this.N=Mj(this,a[b++]),this.j=a[b][0],"string"==typeof this.j&&(this.j=[this.j]),this.O=a[b][1],this.ha|=a[b][2]);a[3]&&(this.B=a[3]);return!0};h.start=function(a,b){this.I||this.v("running");this.A.V=!0;this.Ha=a;this.Ia=b}; h.stop=function(a,b){if(this.A.V){this.A.V=!1;this.w=b-this.Ia;if(!this.I){b="stopped";if(this.w){a-=this.Ha;var c=0>>d.g],b)):Qe(a.f,b));k.Ua||Hj(a);break}}return f}function rk(a,b){for(var c=1;c>23)&65535,A=K(r,t);else if(B==xk)t=t.K-((f&63)<<1)&65535,A=K(r,t);else if(B==yk)A=K(r,f&7,1);else if(B==zk)A=K(r,f&63,1);else if(B==Ak)A=K(r,f&255,1);else if(B=f&D,D&Bk&&(B>>=6,D>>=6),D&Z){var D=null,J=B& -Ck;switch(B&Dk){case 0:A=Uj(r,J);break;case 8:A="@"+Uj(r,J);D=Ek(r,r.f.g[J]);break;case 16:7>J?A="("+Uj(r,J)+")+":(B=r.Ra(t,2),A="#"+K(r,B,0,!0));break;case 24:7>J?A="@("+Uj(r,J)+")+":(B=r.Ra(t,2),A="@#"+K(r,B,0,!0),D=Ek(r,B));break;case 32:A="-("+Uj(r,J)+")";break;case 40:A="@-("+Uj(r,J)+")";break;case 48:B=r.Ra(t,2);A=K(r,B,0,!0)+"("+Uj(r,J)+")";7==J&&(A=K(r,B=B+t.K&65535),D=Ek(r,B));break;case 56:B=r.Ra(t,2),A="@"+K(r,B)+"("+Uj(r,J)+")",7==J&&(A="@"+K(r,B=B+t.K&65535),D=Ek(r,Cc(r.f,B)))}D&&(A= -[A,D])}r=A;if(!r||!r.length){k="INVALID";break}"string"!=typeof r&&(m=r[1],r=r[0]);0>23)&65535,A=K(r,t);else if(B==xk)t=t.K-((f&63)<<1)&65535,A=K(r,t);else if(B==yk)A=K(r,f&7,3);else if(B==zk)A=K(r,f&63,6);else if(B==Ak)A=K(r,f&255,8);else if(B=f&D,D&Bk&&(B>>=6,D>>=6),D&Z){var D=null,J=B& +Ck;switch(B&Dk){case 0:A=Uj(r,J);break;case 8:A="@"+Uj(r,J);D=Ek(r,r.f.g[J]);break;case 16:7>J?A="("+Uj(r,J)+")+":(B=r.Ra(t,2),A="#"+K(r,B,-1));break;case 24:7>J?A="@("+Uj(r,J)+")+":(B=r.Ra(t,2),A="@#"+K(r,B,-1),D=Ek(r,B));break;case 32:A="-("+Uj(r,J)+")";break;case 40:A="@-("+Uj(r,J)+")";break;case 48:B=r.Ra(t,2);A=K(r,B,-1)+"("+Uj(r,J)+")";7==J&&(A=K(r,B=B+t.K&65535),D=Ek(r,B));break;case 56:B=r.Ra(t,2),A="@"+K(r,B)+"("+Uj(r,J)+")",7==J&&(A="@"+K(r,B=B+t.K&65535),D=Ek(r,Cc(r.f,B)))}D&&(A=[A,D])}r= +A;if(!r||!r.length){k="INVALID";break}"string"!=typeof r&&(m=r[1],r=r[0]);0=a.f.ub&&b=c.B&&(b=c.Pa[b&jd])&&(a=b[4]);return a}function Fk(a,b){switch(b){case "N":a=De(a.f);break;case "Z":a=Ce(a.f);break;case "V":a=Be(a.f);break;case "C":a=Ae(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "}function Gk(a,b){var c=Uj(a,b);c&&(c+="="+K(a,a.Ad(b))+" ");return c} function Hk(a,b){var c,d="";for(c=0;6>c;c++)d+=Gk(a,c);d=d+"\n"+(Gk(a,6)+Gk(a,7));d+=Gk(a,Xj)+Gk(a,Yj)+Gk(a,ak);d+=Fk(a,"T")+Fk(a,"N")+Fk(a,"Z")+Fk(a,"V")+Fk(a,"C");b&&(b=d,c=""+(Gk(a,bk)+Gk(a,ck)),c+=Gk(a,dk)+Gk(a,ek)+Gk(a,Zj),c=c+"\n"+(Gk(a,gk)+Gk(a,Vj)+Gk(a,fk)),d=b+("\n"+c));return d}h.me=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],q=$a(n,l,a.me);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Gk:b,K:c,Lf:d,ga:e,ie:f})}function Ik(a,b,c){var d=[],e=Kj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&eUa.length&&(a.v("note: only "+Ua.length+" available"),Ca=Ua.length);Ia-=Ca;0>Ia&&(null==Ua[Ua.length-1].K?(Ca=Ia+Ca,Ia=0):Ia+=Ua.length);var ff=[];"call"==yi&&(Lc=1E5,ff=["CALL"]);for(void 0!==xi&&a.v(Ca+" instructions earlier:");0=Ua.length&&(Ia=0);a.pa=Ca;Ai++;Lc--}}Ai||(a.v("no "+zi+"history available"),a.pa=void 0)}else{var oa=Pj(a,Ta);if(oa)if("da"==jb){var gf=oa.Ma||65535O.length?(2xb&&(xb=0);65536lf?String.fromCharCode(lf):"."),Nd=Nd>>8}zb&&(zb+="\n");zb=hf?zb+(Ab+","):zb+(Ta+": "+Ab+(Md?"":" "+kf))}zb&&a.v(zb);a.Fa=oa;a.Aa=pl}}}}break;case "e":if("else"== -g[0])break;var bc,mf,nf,of,pf=g[0],qf=g[1];"eb"==pf?(bc=1,mf=255,nf=a.Od,of=a.Pd):"e"==pf||"ew"==pf?(bc=2,mf=65535,nf=a.Ra,of=a.Le):qf=null;if(null==qf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var Od=Pj(a,qf);if(Od)for(var Pd=2;Pdtf;){for(var Bb=null,tl=256;65536>Rc.K>>>0;){uf.K=a.Ra(Rc,2);if(null==Rc.K||!tl--)break;if(!(uf.K&1)){for(var ul=a,Qd=uf,Fi=null,Sc=Qd.K,Gi=Sc,vf=1;6>=vf&⪼vf++){if(2Ua.length&&(a.v("note: only "+Ua.length+" available"),Ca=Ua.length);Ia-=Ca;0>Ia&&(null==Ua[Ua.length-1].K?(Ca=Ia+Ca,Ia=0):Ia+=Ua.length);var gf=[];"call"==yi&&(Lc=1E5,gf=["CALL"]);for(void 0!==xi&&a.v(Ca+" instructions earlier:");0=Ua.length&&(Ia=0);a.pa=Ca;Ai++;Lc--}}Ai||(a.v("no "+zi+"history available"),a.pa=void 0)}else{var oa=Pj(a,Ta);if(oa)if("da"==jb){var hf=oa.Ma||65535O.length?(2xb&&(xb=0);65536mf?String.fromCharCode(mf):"."),Nd=Nd>>8}zb&&(zb+="\n");zb=jf?zb+(Ab+","):zb+(Ta+": "+Ab+(Md?"":" "+lf))}zb&&a.v(zb);a.Fa=oa;a.Aa=pl}}}}break;case "e":if("else"== +g[0])break;var bc,nf,of,pf,qf=g[0],rf=g[1];"eb"==qf?(bc=1,nf=255,of=a.Od,pf=a.Pd):"e"==qf||"ew"==qf?(bc=2,nf=65535,of=a.Ra,pf=a.Le):rf=null;if(null==rf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var Od=Pj(a,rf);if(Od)for(var Pd=2;Pduf;){for(var Bb=null,tl=256;65536>Rc.K>>>0;){vf.K=a.Ra(Rc,2);if(null==Rc.K||!tl--)break;if(!(vf.K&1)){for(var ul=a,Qd=vf,Fi=null,Sc=Qd.K,Gi=Sc,wf=1;6>=wf&⪼wf++){if(2 Date: Fri, 24 Feb 2017 13:07:38 -0800 Subject: [PATCH 06/30] Added support for parsing of values (ie, integers) greater than 32 bits, and fixed PDP-10 Bus writes (parameter order differs from other emulators) --- docs/pcx86/examples/pcx86-dbg.js | 6 +++--- docs/pcx86/examples/pcx86.js | 2 +- modules/pdp10/lib/bus.js | 12 +++++------ modules/pdp10/lib/debugger.js | 2 +- modules/pdp10/lib/memory.js | 2 +- modules/shared/lib/strlib.js | 30 ++++++++++++++++++++++++++-- versions/pc8080/1.34.0/pc8080-dbg.js | 12 +++++------ versions/pcx86/1.34.0/pcx86-dbg.js | 6 +++--- versions/pdpjs/1.34.0/pdp10-dbg.js | 17 ++++++++-------- versions/pdpjs/1.34.0/pdp10.js | 12 +++++------ versions/pdpjs/1.34.0/pdp11-dbg.js | 4 ++-- 11 files changed, 66 insertions(+), 39 deletions(-) diff --git a/docs/pcx86/examples/pcx86-dbg.js b/docs/pcx86/examples/pcx86-dbg.js index 07557823e..2396aa0ea 100644 --- a/docs/pcx86/examples/pcx86-dbg.js +++ b/docs/pcx86/examples/pcx86-dbg.js @@ -49,8 +49,8 @@ var da={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[4 y:121,z:122,"{":123,"|":124,"}":125,"~":126,Mp:127},ea={};ea[173]=n["-"];ea[186]=n[";"];ea[187]=n["="];ea[189]=n["-"];ea[188]=n[","];ea[190]=n["."];ea[191]=n["/"];ea[192]=n["`"];ea[219]=n["["];ea[220]=n["\\"];ea[221]=n["]"];ea[222]=n["'"];var fa={};fa[n["1"]]=n["!"];fa[n["2"]]=n["@"];fa[n["3"]]=n["#"];fa[n["4"]]=n.$;fa[n["5"]]=n["%"];fa[n["6"]]=n["^"];fa[n["7"]]=n["&"];fa[n["8"]]=n["*"];fa[n["9"]]=n["("];fa[n["0"]]=n[")"];fa[186]=n[":"];fa[187]=n["+"];fa[188]=n["<"];fa[189]=n._;fa[190]=n[">"]; fa[191]=n["?"];fa[192]=n["~"];fa[219]=n["{"];fa[220]=n["|"];fa[221]=n["}"];fa[222]=n['"'];fa[173]=n._;fa[61]=n["+"];fa[59]=n[":"]; function ga(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=1,f--;return d}function ia(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d} -function ja(a,b,c){var d="";b?11>=3;return(c?"0o":"")+d}function q(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function r(a){return q(a,2,!0)}function ka(a){return q(a,4,!0)} +d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return c}function ha(a,b){var c,d="";b?32>=1,f--;return d}function ia(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d} +function ja(a,b,c){var d="";b?11a&&-1>=3;return(c?"0o":"")+d}function q(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function r(a){return q(a,2,!0)}function ka(a){return q(a,4,!0)} function la(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return pa[a]})} function qa(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function ra(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var pa={"&":"&","<":"<",">":">",'"':""","'":"'"},sa={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function ta(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function Vx(a,b){if(b)return Tx(a,b,a.da[b]);var c=0;for(b in a.da)Tx(a,b,a.da[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ux(a,b){var c;c=void 0===c?0:c;switch(a.ya){case 8:a=ja(b,0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Wx(a){Nx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=Xx(this);this.Ga=Xx(this);this.Z=Xx(this);this.D=[];this.B=this.Y=this.M=[];Yx(this);this.ta=0;Zx(this);this.za={};$x(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return ay(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return ay(b,a)})}ba(Wx,Nx);l=Wx.prototype; l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Ob(a,"FDC");this.Ha=Ob(a,"HDC");this.Tc=Ob(a,"FPU");this.G=Ob(a,"Mouse");(a=qd(a,"messages"))&&$x(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Kd(this.H,7,"DBG");this.ma=by;80186<=this.H.ca&&(this.ma=by.slice(),this.ma[15]=cy,80286<=this.H.ca&&(this.ma[15]=dy,80386<=this.H.ca&&(this.oa=8)));rl(this,64,function(a){ey(d,d.H.sc,a[0])});rl(this,4,function(a){if(a=a[0]){var b=Rx(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=fy(d, b,gy),d.P("dumpSel("+ka(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=hy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ka(a.ua&65535)+" off="+ka(a.Ka):"base="+q(a.ua,d.ha)+" limit="+iy(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ka(a.ext&-65296)+ diff --git a/docs/pcx86/examples/pcx86.js b/docs/pcx86/examples/pcx86.js index e1b3619e0..5abf3c533 100644 --- a/docs/pcx86/examples/pcx86.js +++ b/docs/pcx86/examples/pcx86.js @@ -49,7 +49,7 @@ var da={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[4 y:121,z:122,"{":123,"|":124,"}":125,"~":126,po:127},ea={};ea[173]=n["-"];ea[186]=n[";"];ea[187]=n["="];ea[189]=n["-"];ea[188]=n[","];ea[190]=n["."];ea[191]=n["/"];ea[192]=n["`"];ea[219]=n["["];ea[220]=n["\\"];ea[221]=n["]"];ea[222]=n["'"];var p={};p[n["1"]]=n["!"];p[n["2"]]=n["@"];p[n["3"]]=n["#"];p[n["4"]]=n.$;p[n["5"]]=n["%"];p[n["6"]]=n["^"];p[n["7"]]=n["&"];p[n["8"]]=n["*"];p[n["9"]]=n["("];p[n["0"]]=n[")"];p[186]=n[":"];p[187]=n["+"];p[188]=n["<"];p[189]=n._;p[190]=n[">"];p[191]=n["?"]; p[192]=n["~"];p[219]=n["{"];p[220]=n["|"];p[221]=n["}"];p[222]=n['"'];p[173]=n._;p[61]=n["+"];p[59]=n[":"]; function fa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ha(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ha(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return la[a]})}function ma(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var la={"&":"&","<":"<",">":">",'"':""","'":"'"},na={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function oa(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function pa(a,b){var c=0,d=1,e;for(e in a){if(d>=arguments.length)break;var f=a[e],g=arguments[d++],c=c&~f.qg|g<>a.shift}var ra=[31,28,31,30,31,30,31,31,30,31,30,31],sa=Date.now||function(){return+new Date}; diff --git a/modules/pdp10/lib/bus.js b/modules/pdp10/lib/bus.js index 2f2b9fedb..dfb6e876c 100644 --- a/modules/pdp10/lib/bus.js +++ b/modules/pdp10/lib/bus.js @@ -478,7 +478,7 @@ class BusPDP10 extends Component { * * @this {BusPDP10} * @param {number} addr is a physical address - * @return {number} word (16-bit) value at that address + * @return {number} word (36-bit) value at that address */ getWord(addr) { @@ -492,13 +492,13 @@ class BusPDP10 extends Component { * * @this {BusPDP10} * @param {number} addr is a physical address - * @param {number} w is the word (16-bit) value to write + * @param {number} w is the word (36-bit) value to write */ setWord(addr, w) { var off = addr & this.nBlockLimit; var iBlock = (addr & this.nBusMask) >>> this.nBlockShift; - this.aBusBlocks[iBlock].writeWord(off, w, addr); + this.aBusBlocks[iBlock].writeWord(w, off, addr); } /** @@ -520,7 +520,7 @@ class BusPDP10 extends Component { * * @this {BusPDP10} * @param {number} addr is a physical address - * @return {number} word (16-bit) value at that address + * @return {number} word (36-bit) value at that address */ getWordDirect(addr) { @@ -540,14 +540,14 @@ class BusPDP10 extends Component { * * @this {BusPDP10} * @param {number} addr is a physical address - * @param {number} w is the word (16-bit) value to write (we truncate it to 16 bits to be safe) + * @param {number} w is the word (36-bit) value to write (we truncate it to 16 bits to be safe) */ setWordDirect(addr, w) { var off = addr & this.nBlockLimit; var block = this.getBlockDirect(addr); this.nDisableFaults++; - block.writeWordDirect(off, w & 0xffff, addr); + block.writeWordDirect(w, off, addr); this.nDisableFaults--; } diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index aad5c5e1a..3dfe1267c 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -2487,7 +2487,7 @@ class DebuggerPDP10 extends Debugger { sData += ' '; } for (var i = 0; size == 1 && i < 6; i++) { - var c = ((w % 64)|0) + 33; + var c = ((w % 64)|0) + 32; sChars += String.fromCharCode(c); w /= 64; } diff --git a/modules/pdp10/lib/memory.js b/modules/pdp10/lib/memory.js index 3c1fcbcd5..41afe49f7 100644 --- a/modules/pdp10/lib/memory.js +++ b/modules/pdp10/lib/memory.js @@ -216,7 +216,7 @@ class MemoryPDP10 { */ if (len === undefined) len = this.size; Component.assert(off >= 0 && off < this.size); - for (i = off; len-- && i < this.size; i++) this.writeWordDirect(off, pattern, this.addr + off); + for (i = off; len-- && i < this.size; i++) this.writeWordDirect(pattern, off, this.addr + off); } /** diff --git a/modules/shared/lib/strlib.js b/modules/shared/lib/strlib.js index feabdb7ec..771981dda 100644 --- a/modules/shared/lib/strlib.js +++ b/modules/shared/lib/strlib.js @@ -132,7 +132,12 @@ class Str { } var v; if (Str.isValidInt(s, base) && !isNaN(v = parseInt(s, base))) { - value = v | 0; + /* + * With the need to support larger (eg, 36-bit) integers, truncating to 32 bits is no longer helpful. + * + * value = v|0; + */ + value = v; } } return value; @@ -234,6 +239,13 @@ class Str { if (n == null || isNaN(n)) { while (cch-- > 0) s = '?' + s; } else { + /* + * Callers that produced an input by dividing by a power of two rather than shifting (in order + * to access more than 32 bits) may produce a fractional result, which ordinarily we would simply + * ignore, but if the integer portion is zero and the sign is negative, we should probably treat + * this value as a sign-extension. + */ + if (n < 0 && n > -1) n = -1; while (cch-- > 0) { var d = (n & 7) + 0x30; s = String.fromCharCode(d) + s; @@ -254,7 +266,7 @@ class Str { * * @param {number|null|undefined} n (interpreted as a 32-bit value) * @param {number} [cch] is the desired number of decimal digits (0 or undefined for default of either 5 or 10) - * @return {string} the octal representation of n + * @return {string} the decimal representation of n */ static toDec(n, cch) { @@ -276,6 +288,13 @@ class Str { if (n == null || isNaN(n)) { while (cch-- > 0) s = '?' + s; } else { + /* + * Callers that produced an input by dividing by a power of two rather than shifting (in order + * to access more than 32 bits) may produce a fractional result, which ordinarily we would simply + * ignore, but if the integer portion is zero and the sign is negative, we should probably treat + * this value as a sign-extension. + */ + if (n < 0 && n > -1) n = -1; while (cch-- > 0) { var d = (n % 10) + 0x30; s = String.fromCharCode(d) + s; @@ -327,6 +346,13 @@ class Str { if (n == null || isNaN(n)) { while (cch-- > 0) s = '?' + s; } else { + /* + * Callers that produced an input by dividing by a power of two rather than shifting (in order + * to access more than 32 bits) may produce a fractional result, which ordinarily we would simply + * ignore, but if the integer portion is zero and the sign is negative, we should probably treat + * this value as a sign-extension. + */ + if (n < 0 && n > -1) n = -1; while (cch-- > 0) { var d = n & 0xf; d += (d >= 0 && d <= 9? 0x30 : 0x41 - 10); diff --git a/versions/pc8080/1.34.0/pc8080-dbg.js b/versions/pc8080/1.34.0/pc8080-dbg.js index 1f1887909..36134948b 100644 --- a/versions/pc8080/1.34.0/pc8080-dbg.js +++ b/versions/pc8080/1.34.0/pc8080-dbg.js @@ -47,11 +47,11 @@ var fa=window?window.PCjs.Machines:{},da=window?window.PCjs.Components:[],sa=win Array.prototype.indexOf||(Array.prototype.indexOf=function(a,b){b=b||0;for(var c=this.length;b>=3;return(c?"0o":"")+d}function t(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} -function Ja(a){return t(a,2,!0)}function x(a){return t(a,4,!0)}function Ka(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ra[a]})}function Sa(a,b){return(a+" ").slice(0,b)} -function Ta(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ra={"&":"&","<":"<",">":">",'"':""","'":"'"},Ua={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; -function Va(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function Xa(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;ca&&-1>=3;return(c?"0o":"")+d} +function t(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Ja(a){return t(a,2,!0)}function x(a){return t(a,4,!0)}function Ka(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ra[a]})}function Sa(a,b){return(a+" ").slice(0,b)}function Ta(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Ra={"&":"&","<":"<",">":">",'"':""","'":"'"},Ua={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function Va(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function Xa(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Qa=g.load;d.Ia=g.exec;if(e=g.bytes)d.ma=e;else if(e=g.words)for(d.ma=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.ma=Array(4*e.length),f=c=0;c>=1,y--;g=v+g;d>>=8}d=t(c,0,!0)+" "+c+". "+Ia(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.i((null!=b?b+": ":"")+d);return e} -function ag(a,b){if(b)return Zf(a,b,a.S[b]);var c=0;for(b in a.S)Zf(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +function ag(a,b){if(b)return Zf(a,b,a.S[b]);var c=0;for(b in a.S)Zf(a,b,a.S[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} var Yf={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};function bg(a){Tf.call(this,a);this.style=cg;this.F=dg();this.la=dg();this.O=dg();this.A=[];this.j=this.I=this.w=[];eg(this);this.W=0;fg(this);this.Z={};gg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Fc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Fc(b,a)})}aa(bg,Tf);l=bg.prototype; l.Ea=function(a,b,c,d){this.H=b;this.u=c;this.R=a;(a=Bc(a,"messages"))&&gg(this,a);this.ga=hg;Sd(this,64,function(a){a:{var b=d.H.b,c=a[0],e=a=0,k=b.length;if(c){a=ig(jg(d,c));if(-1===a){d.i("invalid address: "+c);break a}e=a>>>d.H.g;k=1}d.i("blockid physical blockaddr used size type");d.i("-------- --------- ---------- ------ ------ ----");for(var c=-1,p=0;k--;){var u=b[e];u.type==c?p++||d.i("..."):(c=u.type,p=Ib[c],u&&d.i(t(u.id)+" %"+t(e<"]; fa[191]=n["?"];fa[192]=n["~"];fa[219]=n["{"];fa[220]=n["|"];fa[221]=n["}"];fa[222]=n['"'];fa[173]=n._;fa[61]=n["+"];fa[59]=n[":"]; function ga(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=1,f--;return d}function ia(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d} -function ja(a,b,c){var d="";b?11>=3;return(c?"0o":"")+d}function q(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function r(a){return q(a,2,!0)}function ka(a){return q(a,4,!0)} +d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return c}function ha(a,b){var c,d="";b?32>=1,f--;return d}function ia(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d} +function ja(a,b,c){var d="";b?11a&&-1>=3;return(c?"0o":"")+d}function q(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function r(a){return q(a,2,!0)}function ka(a){return q(a,4,!0)} function la(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return pa[a]})} function qa(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function ra(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var pa={"&":"&","<":"<",">":">",'"':""","'":"'"},sa={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function ta(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function Vx(a,b){if(b)return Tx(a,b,a.da[b]);var c=0;for(b in a.da)Tx(a,b,a.da[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ux(a,b){var c;c=void 0===c?0:c;switch(a.ya){case 8:a=ja(b,0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Wx(a){Nx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=Xx(this);this.Ga=Xx(this);this.Z=Xx(this);this.D=[];this.B=this.Y=this.M=[];Yx(this);this.ta=0;Zx(this);this.za={};$x(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return ay(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return ay(b,a)})}ba(Wx,Nx);l=Wx.prototype; l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Ob(a,"FDC");this.Ha=Ob(a,"HDC");this.Tc=Ob(a,"FPU");this.G=Ob(a,"Mouse");(a=qd(a,"messages"))&&$x(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Kd(this.H,7,"DBG");this.ma=by;80186<=this.H.ca&&(this.ma=by.slice(),this.ma[15]=cy,80286<=this.H.ca&&(this.ma[15]=dy,80386<=this.H.ca&&(this.oa=8)));rl(this,64,function(a){ey(d,d.H.sc,a[0])});rl(this,4,function(a){if(a=a[0]){var b=Rx(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=fy(d, b,gy),d.P("dumpSel("+ka(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=hy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ka(a.ua&65535)+" off="+ka(a.Ka):"base="+q(a.ua,d.ha)+" limit="+iy(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ka(a.ext&-65296)+ diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 3eaf02134..9962c391b 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -48,9 +48,10 @@ var ua=window?window.PCjs.Machines:{},v=window?window.PCjs.Components:[],Aa=wind Array.prototype.indexOf||(Array.prototype.indexOf=function(a,b){b=b||0;for(var c=this.length;b>=3;return(c?"0o":"")+d}function H(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} -function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)} -function fb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(g=parseInt(a,b))&&(c=g)}return c}function Qa(a,b,c){var d="";b?11a&&-1>=3;return(c?"0o":"")+d} +function H(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function fb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;cc;c++){v function Pb(){for(var a=D(document,C,"panel"),b=0;bd.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.v+m;e=k+16384;g-=m;f++;continue}}return jc(kc,e,g)}e=new V(a,e,m,16384,d);gc(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+lc[d]+" at "+Qa(b)),!0):jc(mc,b,c)} -function ec(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function dc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(b&16383,c&65535,b);a.w--}function hc(a){for(var b=0,c=[],d=0;d>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function dc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function hc(a){for(var b=0,c=[],d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(a&16383,b,a)}; +function gd(a){var b=[];for(a=a.fa;a;)b.push(a.Ob),a=a.next;return b}l.Gb=function(a){var b=this.C;a=this.ea=a;return b.g[(a&b.u)>>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(b,a&16383,a)}; l.Ja=function(a){this.i.complete=!0;var b=this.A?hd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(id(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&id(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,za=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(za)for(G(a,"loading "+I(za)+" bytes at "+I(q)+"-"+I(q+za),4096);za--;)dc(a.C,q++,b[K++]);else q&1?f=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function zd(a,b){if(b)return yd(a,b,a.Z[b]);var c=0;for(b in a.Z)yd(a,b,a.Z[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +function zd(a,b){if(b)return yd(a,b,a.Z[b]);var c=0;for(b in a.Z)yd(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} var xd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Ad(a){rd.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Bd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Cd(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Dd(this,a.messages);this.ra=a.commands;this.Ba=Ed;this.Ma=[];this.L=0;this.Da=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Wc(b,a)}):void 0===global[C]&&(global[C]= function(a){return Wc(b,a)})}r(Ad,rd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Fd(a){return[a.v,a.qb,a.ba,a.ka,a.Qa]}function Gd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=sd(a,c.Qa=b[4]));return c}l=Ad.prototype; @@ -158,7 +159,7 @@ else{var ja=za.charAt(1);if("l"==ja){var oc;oc=0+we(a,a.g);oc+=we(a,a.K);(oc+=we "w"==ja?a.va(a.G,F):a.f("unknown breakpoint command: "+ja))}}}break;case "c":a.ja&&(a.ja.value="");break;case "d":a:{var Ca,Da=f[0],R=f[1],ca=f[2],hf=f[3];if("?"==R){var Ea="";for(Ca in N)a.na[Ca]&&(Ea&&(Ea+=","),Ea+=Ca);Ea+=",state,symbols";a.f("dump memory commands:");a.f("\tdw [a] [n] dump n words at address a");a.f("\tds [a] [n] dump n words at address a as JSON");a.f("\tdh [p] [n] dump n instructions from history position p");Ea.length&&a.f("dump extension commands:\n\t"+Ea)}else if("state"== R){var pc=He(a.D,!0);"console"==ca?console.log(pc):(a.ja&&(a.ja.value=""),pc&&a.f(pc))}else if("symbols"==R)for(var qc=0;qcS.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var sc=[];"call"==Wd&&(Ya=1E5,sc=["CALL"]);for(void 0!==Vd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;Yd++;Ya--}}Yd||(a.f("no "+Xd+"history available"), -a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ae="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||hf,la=wd(a,ca);else{var be=Z(a,ca);be&&(la=be.v-ka.v)}0>la&&(la=0);65536fe;fe++)de+=String.fromCharCode((Ab%64|0)+33), +a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ae="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||hf,la=wd(a,ca);else{var be=Z(a,ca);be&&(la=be.v-ka.v)}0>la&&(la=0);65536fe;fe++)de+=String.fromCharCode((Ab%64|0)+32), Ab/=64}ma&&(ma+="\n");ma=ae?ma+(na+","):ma+(R+": "+na+(0>ee?" "+de:""))}ma&&a.f(ma);a.xa=ka;a.ba=kf}}}}break;case "e":if("else"==f[0])break;var ge,he,ie=f[0],vc=f[1];"e"==ie||"ew"==ie?(ge=a.wa,he=a.Xa):vc=null;if(null==vc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Bb=Z(a,vc);if(Bb)for(var Cb=2;Cbzc;){for(var oa=null,of=256;65536>ab.v>>>0;){Ac.v=a.wa(ab,2);if(null==ab.v||!of--)break;if(!(Ac.v&1)){for(var pf=a,Db=Ac,ke=null,bb=Db.v,le=bb,Bc=1;6>=Bc&&bb;Bc++){if(2>=3;return""+c}function F(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function xa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ba[a]})}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ba={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function wa(a,b){var c="";b?11a&&-1>=3;return""+c}function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} +function xa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ba[a]})}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ba={"&":"&","<":"<",">":">",'"':""","'":"'"}; function Da(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} @@ -65,13 +65,13 @@ b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.o k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()};k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.mb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.l)ab(a,c,null!=b?b:a.l[c])} function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])}k.Wa=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; k.pb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.f].Ca(b&16383,b)}else a=this.c.ba(this.f);N(this,this.h=a)}};k.bb=function(a){a||this.c.b.u||Q(this,this.g)};k.ab=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.cb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(0,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){a.a[(b&a.g)>>>a.f].ua(b&16383,c&65535,b)} +function ob(a,b,c,d){for(var e=b,f=c,g=e>>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(0,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){a.a[(b&a.g)>>>a.f].ua(c,b&16383,b)} function nb(a){for(var b=0,c=[],d=0;d>>b.f].ba(a&16383,a)};k.wb=function(a,b){var c=this.j;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(a&16383,b,a)}; +function Nb(a){var b=[];for(a=a.W;a;)b.push(a.rb),a=a.next;return b}k.jb=function(a){var b=this.j;a=this.V=a;return b.a[(a&b.g)>>>b.f].ba(a&16383,a)};k.wb=function(a,b){var c=this.j;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(b,a&16383,a)}; k.va=function(a){this.b.complete=!0;var b=a?this.b.Da?0:1:-1;this.b.Da=!1;this.v=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){S(this);break}if(0>b)break}this.a&=15;a=this.f;this.ba(a);this.f=(a+1)%Sa}while(0>>=f.f;0>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,n=b[l++]&255|(b[l++]&255)<<8,p=b[l++]&255|(b[l++]&255)<<8,m=m+((n&255)+(n>>8)+(p&255)+(p>>8)),M=l,qa=n-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(qa)for(;qa--;)kb(a.j,p++,b[M++]);else p&1?g=!0:null==d&&(d=p);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h>=1,f--;return d}function E(a,b,c){var d="";b?11>=3;return(c?"0o":"")+d} -function Ma(a,b){var c="";b?10=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Na(a){return F(a,4,!0)} +d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return c}function La(a,b,c){var d="";b?32>=1,f--;return d}function E(a,b,c){var d="";b?11a&&-1>=3;return(c?"0o":"")+d} +function Ma(a,b){var c="";b?10a&&-1a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Na(a){return F(a,4,!0)} function Oa(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return Sa[a]})}function Xa(a,b){return(a+" ").slice(0,b)} function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Sa={"&":"&","<":"<",">":">",'"':""","'":"'"},Za={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function $a(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,k;k=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} From da3bb4740c337188e18f26c360f647089ecf9d5a Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Fri, 24 Feb 2017 13:09:46 -0800 Subject: [PATCH 07/30] Fixed PDP-10 test panel updates --- modules/pdp10/lib/panel.js | 14 +------------- versions/c1pjs/1.34.0/c1p-dbg.js | 4 ++-- versions/c1pjs/1.34.0/c1p.js | 2 +- versions/pc8080/1.34.0/pc8080.js | 4 ++-- versions/pcx86/1.34.0/pcx86.js | 2 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 10 +++++----- versions/pdpjs/1.34.0/pdp10.js | 8 ++++---- versions/pdpjs/1.34.0/pdp11.js | 2 +- 8 files changed, 17 insertions(+), 29 deletions(-) diff --git a/modules/pdp10/lib/panel.js b/modules/pdp10/lib/panel.js index 538c70c75..212a20e14 100644 --- a/modules/pdp10/lib/panel.js +++ b/modules/pdp10/lib/panel.js @@ -323,19 +323,7 @@ class PanelPDP10 extends Component { } switch (sBinding) { - case 'R0': - case 'R1': - case 'R2': - case 'R3': - case 'R4': - case 'R5': - case 'R6': - case 'R7': - case 'NF': - case 'ZF': - case 'VF': - case 'CF': - case 'PS': + case 'PC': this.bindings[sBinding] = control; this.cLiveRegs++; return true; diff --git a/versions/c1pjs/1.34.0/c1p-dbg.js b/versions/c1pjs/1.34.0/c1p-dbg.js index 0be87e59a..4e5a9992b 100644 --- a/versions/c1pjs/1.34.0/c1p-dbg.js +++ b/versions/c1pjs/1.34.0/c1p-dbg.js @@ -19,8 +19,8 @@ http://pcjs.org/modules/c1pjs/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/c1pjs/lib/computer.js (C) Jeff Parsons 2012-2017 */ -var f;function p(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]}function q(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function t(a){return q(a,2,!0)}function u(a){return q(a,4,!0)} -function aa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return da[a]})}var da={"&":"&","<":"<",">":">",'"':""","'":"'"},ea=Date.now||function(){return+new Date}; +var f;function p(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]}function q(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function t(a){return q(a,2,!0)} +function u(a){return q(a,4,!0)}function aa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return da[a]})}var da={"&":"&","<":"<",">":">",'"':""","'":"'"},ea=Date.now||function(){return+new Date}; function v(a,b){var c=!0,c=void 0===c?!1:c,d=0,e=null;if("object"==typeof resources&&(e=resources[a]))b&&b(a,e,d);else if(c&&"function"==typeof resources)resources(a,function(c,d){b&&b(a,c,d)});else{var g=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(g.onreadystatechange=function(){4===g.readyState&&(e=g.responseText,200==g.status||!g.status&&e.length&&"file:"==(window?window.location.protocol:"file:")||(d=g.status||-1),b&&b(a,e,d))});g.open("GET", a,c);g.send();c||(e=g.responseText,200!=g.status&&(d=g.status||-1),b&&b(a,e,d))}}function w(a){if(window){var b=window?window.navigator.userAgent:"";return"iOS"==a&&!!b.match(/(iPod|iPhone|iPad)/)&&!!b.match(/AppleWebKit/)||"MSIE"==a&&!!b.match(/(MSIE|Trident)/)||0<=b.indexOf(a)}return!1}function fa(a,b,c){function d(){--a;0<=a&&(b()||(a=0));0=f?48:55),d=String.fromCharCode(f)+d;a>>=4}return(c?"0x":"")+d} +var e;function q(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var f=Object.getOwnPropertyDescriptor(b,d);f&&Object.defineProperty(a,d,f)}else a[d]=b[d]}function r(a,b,c){var d="";b?8a&&-1=f?48:55),d=String.fromCharCode(f)+d;a>>=4}return(c?"0x":"")+d} function aa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return da[a]})}var da={"&":"&","<":"<",">":">",'"':""","'":"'"},ea=Date.now||function(){return+new Date}; function t(a,b){var c=!0,c=void 0===c?!1:c,d=0,f=null;if("object"==typeof resources&&(f=resources[a]))b&&b(a,f,d);else if(c&&"function"==typeof resources)resources(a,function(c,d){b&&b(a,c,d)});else{var g=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(g.onreadystatechange=function(){4===g.readyState&&(f=g.responseText,200==g.status||!g.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(d=g.status||-1),b&&b(a,f,d))});g.open("GET", a,c);g.send();c||(f=g.responseText,200!=g.status&&(d=g.status||-1),b&&b(a,f,d))}}function u(a){if(window){var b=window?window.navigator.userAgent:"";return"iOS"==a&&!!b.match(/(iPod|iPhone|iPad)/)&&!!b.match(/AppleWebKit/)||"MSIE"==a&&!!b.match(/(MSIE|Trident)/)||0<=b.indexOf(a)}return!1}function fa(a,b){if(window){var c=window[a];window[a]="function"!==typeof c?b:function(){c&&c();b()}}}function v(a){w.init.push(a)} diff --git a/versions/pc8080/1.34.0/pc8080.js b/versions/pc8080/1.34.0/pc8080.js index 8c42ba54e..d57ffe9fb 100644 --- a/versions/pc8080/1.34.0/pc8080.js +++ b/versions/pc8080/1.34.0/pc8080.js @@ -46,8 +46,8 @@ var ca=window?window.PCjs.Machines:{},r=window?window.PCjs.Components:[],ma=wind Array.prototype.indexOf||(Array.prototype.indexOf=function(a,b){b=b||0;for(var c=this.length;b=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ta(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return za[a]})}function Aa(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +e&&d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return c}function B(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ta(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return za[a]})}function Aa(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var za={"&":"&","<":"<",">":">",'"':""","'":"'"},Ba={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function Ca(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function Da(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, diff --git a/versions/pcx86/1.34.0/pcx86.js b/versions/pcx86/1.34.0/pcx86.js index e1b3619e0..5abf3c533 100644 --- a/versions/pcx86/1.34.0/pcx86.js +++ b/versions/pcx86/1.34.0/pcx86.js @@ -49,7 +49,7 @@ var da={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[4 y:121,z:122,"{":123,"|":124,"}":125,"~":126,po:127},ea={};ea[173]=n["-"];ea[186]=n[";"];ea[187]=n["="];ea[189]=n["-"];ea[188]=n[","];ea[190]=n["."];ea[191]=n["/"];ea[192]=n["`"];ea[219]=n["["];ea[220]=n["\\"];ea[221]=n["]"];ea[222]=n["'"];var p={};p[n["1"]]=n["!"];p[n["2"]]=n["@"];p[n["3"]]=n["#"];p[n["4"]]=n.$;p[n["5"]]=n["%"];p[n["6"]]=n["^"];p[n["7"]]=n["&"];p[n["8"]]=n["*"];p[n["9"]]=n["("];p[n["0"]]=n[")"];p[186]=n[":"];p[187]=n["+"];p[188]=n["<"];p[189]=n._;p[190]=n[">"];p[191]=n["?"]; p[192]=n["~"];p[219]=n["{"];p[220]=n["|"];p[221]=n["}"];p[222]=n['"'];p[173]=n._;p[61]=n["+"];p[59]=n[":"]; function fa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ha(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function ha(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return la[a]})}function ma(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var la={"&":"&","<":"<",">":">",'"':""","'":"'"},na={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function oa(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function pa(a,b){var c=0,d=1,e;for(e in a){if(d>=arguments.length)break;var f=a[e],g=arguments[d++],c=c&~f.qg|g<>a.shift}var ra=[31,28,31,30,31,30,31,31,30,31,30,31],sa=Date.now||function(){return+new Date}; diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 9962c391b..4781865d8 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -64,11 +64,11 @@ function ub(a){if(vb)try{for(var b=0;ba;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, set:this.Mb};E(this)}r(Ib,u);l=Ib.prototype;l.reset=function(a){this.stop();a&&Kb(this,this.w=0)}; -l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, -b){return function(){Lb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Mb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Lb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Mb(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Nb(this);Ob(this)};l.la=function(a,b){if(!b)if(this.U&&Pb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()};l.restore=function(a){if(a=a[0])Qb(this,this.j=a[0]),Kb(this,this.w=a[1]),Rb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Ob(this);return!0};function Sb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Nb(a,b){for(var c in a.B)Sb(a,c,null!=b?b:a.B[c])} -function Tb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ob(a){for(var b in a.g)Tb(a,b,a.g[b][1])}l.sb=function(a,b,c){if(Lb(this,b)){if(c){var d=this;setTimeout(function(){Mb(d,b);a&&a()},+c);return!1}Mb(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Rb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Tb(this,a,c[1]),!0):!1};l.Nb=function(a){return Lb(this,a)?(Mb(this,a),!0):!1}; -function Lb(a,b){var c=a.g[b];return c?(Tb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Ub&&(a.N=b==Vb,a.O=b==Wb),!0):!1}function Mb(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Tb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Xb]&&this.g[Xb][1]&&Yb(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; +l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Lb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Mb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Lb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Mb(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Nb(this);Ob(this)};l.la=function(a,b){if(!b)if(this.U&&Pb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Qb(this,this.j=a[0]),Kb(this,this.w=a[1]),Rb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Ob(this);return!0};function Sb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Nb(a,b){for(var c in a.B)Sb(a,c,null!=b?b:a.B[c])}function Tb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ob(a){for(var b in a.g)Tb(a,b,a.g[b][1])} +l.sb=function(a,b,c){if(Lb(this,b)){if(c){var d=this;setTimeout(function(){Mb(d,b);a&&a()},+c);return!1}Mb(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Rb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Tb(this,a,c[1]),!0):!1};l.Nb=function(a){return Lb(this,a)?(Mb(this,a),!0):!1};function Lb(a,b){var c=a.g[b];return c?(Tb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Ub&&(a.N=b==Vb,a.O=b==Wb),!0):!1} +function Mb(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Tb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Xb]&&this.g[Xb][1]&&Yb(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Xb]&&this.g[Xb][1])Yb(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),Zb(a,0,null),Na(a,!1);else try{var b=this.b.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<a;a++)this.a["S"+a]=[0,0,!1,!1,this.cb,a];this.o=this.c=this.j=this.m=null;this.exports={hold:this.Wa,toggle:this.qb,reset:this.mb, set:this.pb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; -k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.l[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this, -b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0}; -k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()};k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.mb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.l)ab(a,c,null!=b?b:a.l[c])} -function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])}k.Wa=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; +k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.l[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.mb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.l)ab(a,c,null!=b?b:a.l[c])}function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])} +k.Wa=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; k.pb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=3;return""+c}function Da(a,b,c){var d="";b?8=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} +d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return c}function Ca(a,b){var c="";b?11a&&-1>=3;return""+c}function Da(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} function Ea(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return Ia[a]})}function Ja(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} var Ia={"&":"&","<":"<",">":">",'"':""","'":"'"},Ka={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; function La(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} From 3b27f45b769b006adcb35348a874bfe289892974 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Fri, 24 Feb 2017 23:15:53 -0800 Subject: [PATCH 08/30] Added disassembly of basic PDP-10 operations --- devices/pdp10/machine/ka10/test/machine.xml | 2 +- modules/pdp10/lib/bus.js | 2 +- modules/pdp10/lib/cpustate.js | 2 +- modules/pdp10/lib/debugger.js | 424 +++++++++++++------- modules/pdp10/lib/defines.js | 16 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 314 +++++++-------- versions/pdpjs/1.34.0/pdp10.js | 124 +++--- 7 files changed, 507 insertions(+), 377 deletions(-) diff --git a/devices/pdp10/machine/ka10/test/machine.xml b/devices/pdp10/machine/ka10/test/machine.xml index 2a951bf8d..e62a63d4d 100644 --- a/devices/pdp10/machine/ka10/test/machine.xml +++ b/devices/pdp10/machine/ka10/test/machine.xml @@ -7,5 +7,5 @@ - + diff --git a/modules/pdp10/lib/bus.js b/modules/pdp10/lib/bus.js index dfb6e876c..0d869f12c 100644 --- a/modules/pdp10/lib/bus.js +++ b/modules/pdp10/lib/bus.js @@ -706,8 +706,8 @@ class BusPDP10 extends Component { if (!this.nDisableFaults) { if (DEBUGGER && this.dbg && this.dbg.messageEnabled(MessagesPDP10.FAULT)) { this.dbg.printMessage("memory fault on " + this.dbg.toStrBase(addr), true, true); - this.dbg.stopCPU(); } + this.cpu.stopCPU(); } } diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index 44db31942..6ced96a13 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -324,7 +324,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ getOpcode() { - var pc = this.regPC; + var pc = this.pcLast = this.regPC; var opCode = this.readWord(pc); this.regPC = (pc + 1) % PDP10.ADDR_LIMIT; return opCode; diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 3dfe1267c..c7616e747 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -162,7 +162,6 @@ class DebuggerPDP10 extends Debugger { /* * Define remaining miscellaneous DebuggerPDP10 properties. */ - this.opTable = DebuggerPDP10.OPTABLE; this.aOpReserved = []; this.nStep = 0; this.sCmdTracePrev = null; @@ -1327,7 +1326,7 @@ class DebuggerPDP10 extends Debugger { */ if (!nState) { opCode = this.cpu.readWord(addr); - if ((opCode & PDP10.OPCODE.HALTMASK) == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { + if ((opCode / PDP10.OPCODE.FNSHIFT)|0 == PDP10.OPCODE.FNHALT && this.cpu.getLastPC() == addr) { addr = this.cpu.advancePC(1); } } @@ -1365,6 +1364,100 @@ class DebuggerPDP10 extends Debugger { return false; } + /** + * getInstruction(dbgAddr, sComment, nSequence) + * + * Get the next instruction, by decoding the opcode and any operands. + * + * @this {DebuggerPDP10} + * @param {DbgAddrPDP10} dbgAddr + * @param {string} [sComment] is an associated comment + * @param {number|null} [nSequence] is an associated sequence number, undefined if none + * @return {string} (and dbgAddr is updated to the next instruction) + */ + getInstruction(dbgAddr, sComment, nSequence) + { + var opNames = DebuggerPDP10.OPNAMES; + var dbgAddrOp = this.newAddr(dbgAddr.addr); + + var opNum, opMask, aModes, iMode = 0; + var opCode = this.getWord(dbgAddr, 1); + var op = (opCode / PDP10.OPCODE.OPSHIFT)|0; + + for (var mask in DebuggerPDP10.OPTABLE) { + var opMasks = DebuggerPDP10.OPTABLE[mask]; + opNum = opMasks[op & mask]; + if (opNum) { + opMask = +mask; + switch(opMask) { + case PDP10.OPCODE.OPMODE: + aModes = DebuggerPDP10.OPMODES; + iMode = (op & 3); + break; + case PDP10.OPCODE.OPCOMP: + aModes = DebuggerPDP10.OPCOMPS; + iMode = (op & 7); + break; + case PDP10.OPCODE.OPTEST: + aModes = DebuggerPDP10.OPTESTS; + iMode = ((op & 0o60) >> 2) | ((op & 0o6) >> 1); + break; + } + break; + } + } + + var sOperands = ""; + var sMode = aModes && aModes[iMode] || ""; + if (sMode == "S" && opNum > DebuggerPDP10.OPS.MOVM) sMode = "B"; + + var sOpName = opNames[opNum] + sMode; + if (!opNum) sOperands = this.toStrWord(opCode); + + var sOpCodes = ""; + var sLine = this.toStrAddr(dbgAddrOp) + ":"; + if (dbgAddrOp.addr !== PDP10.ADDR_INVALID && dbgAddr.addr !== PDP10.ADDR_INVALID) { + do { + var w = this.getWord(dbgAddrOp, 1); + sOpCodes += ' ' + this.toStrWord(w); + if (dbgAddrOp.addr == null) break; + } while (dbgAddrOp.addr != dbgAddr.addr); + } + + sLine += Str.pad(sOpCodes, 16); + sLine += Str.pad(sOpName, 5); + if (sOperands) sLine += ' ' + sOperands; + + if (sComment) { + sLine = Str.pad(sLine, 60) + ';' + (sComment || ""); + if (!this.cpu.flags.checksum) { + sLine += (nSequence != null? '=' + nSequence.toString() : ""); + } else { + var nCycles = this.cpu.getCycles(); + sLine += "cycles=" + nCycles.toString() + " cs=" + Str.toHex(this.cpu.nChecksum); + } + } + return sLine; + } + + /** + * parseInstruction(sOp, sOperand, addr) + * + * TODO: Unimplemented. See parseInstruction() in modules/c1pjs/lib/debugger.js for a sample implementation. + * + * @this {DebuggerPDP10} + * @param {string} sOp + * @param {string|undefined} sOperand + * @param {DbgAddrPDP10} dbgAddr of memory where this instruction is being assembled + * @return {Array.} of opcode bytes; if the instruction can't be parsed, the array will be empty + */ + parseInstruction(sOp, sOperand, dbgAddr) + { + var aOpBytes = []; + this.println("not supported yet"); + return aOpBytes; + } + /** * stopInstruction(sMessage) * @@ -1760,139 +1853,6 @@ class DebuggerPDP10 extends Debugger { return fBreak; } - /** - * getInstruction(dbgAddr, sComment, nSequence) - * - * Get the next instruction, by decoding the opcode and any operands. - * - * @this {DebuggerPDP10} - * @param {DbgAddrPDP10} dbgAddr - * @param {string} [sComment] is an associated comment - * @param {number|null} [nSequence] is an associated sequence number, undefined if none - * @return {string} (and dbgAddr is updated to the next instruction) - */ - getInstruction(dbgAddr, sComment, nSequence) - { - var opNames = DebuggerPDP10.OPNAMES; - var dbgAddrOp = this.newAddr(dbgAddr.addr); - var opCode = this.getWord(dbgAddr, 1); - - var opDesc; - for (var mask in this.opTable) { - var opMasks = this.opTable[mask]; - opDesc = opMasks[opCode & mask]; - if (opDesc) break; - } - - if (!opDesc) { - opDesc = DebuggerPDP10.OPNONE; - } - - var opNum = opDesc[0]; - if (this.aOpReserved.indexOf(opNum) >= 0) { - opDesc = DebuggerPDP10.OPNONE; - opNum = opDesc[0]; - } - - var sOperands = "", sTarget = ""; - var sOpName = opNames[opNum]; - var cOperands = opDesc.length - 1; - - if (!opNum && !cOperands) { - sOperands = this.toStrWord(opCode); - } - - for (var iOperand = 1; iOperand <= cOperands; iOperand++) { - - var opType = opDesc[iOperand]; - if (opType === undefined) continue; - - var sOperand = this.getOperand(opCode, opType, dbgAddr); - - if (!sOperand || !sOperand.length) { - sOperands = "INVALID"; - break; - } - - /* - * If getOperand() returns an Array rather than a string, then the first element is the original - * operand, and the second element contains additional information (eg, the target) of the operand. - */ - if (typeof sOperand != "string") { - sTarget = sOperand[1]; - sOperand = sOperand[0]; - } - - if (sOperands.length > 0) sOperands += ','; - sOperands += (sOperand || "???"); - } - - var sOpCodes = ""; - var sLine = this.toStrAddr(dbgAddrOp) + ":"; - if (dbgAddrOp.addr !== PDP10.ADDR_INVALID && dbgAddr.addr !== PDP10.ADDR_INVALID) { - do { - var w = this.getWord(dbgAddrOp, 1); - sOpCodes += ' ' + this.toStrWord(w); - if (dbgAddrOp.addr == null) break; - } while (dbgAddrOp.addr != dbgAddr.addr); - } - - sLine += Str.pad(sOpCodes, 16); - sLine += Str.pad(sOpName, 5); - if (sOperands) sLine += ' ' + sOperands; - - if (sComment || sTarget) { - sLine = Str.pad(sLine, 60) + ';' + (sComment || ""); - if (!this.cpu.flags.checksum) { - sLine += (nSequence != null? '=' + nSequence.toString() : ""); - } else { - var nCycles = this.cpu.getCycles(); - sLine += "cycles=" + nCycles.toString() + " cs=" + Str.toHex(this.cpu.nChecksum); - } - if (sTarget) { - if (sLine.slice(-1) != ';') sLine += ' '; - sLine += sTarget; - } - } - return sLine; - } - - /** - * getOperand(opCode, opType, dbgAddr) - * - * If getOperand() returns an Array rather than a string, then the first element is the original - * operand, and the second element is a comment containing additional information (eg, the target) - * of the operand. - * - * @this {DebuggerPDP10} - * @param {number} opCode - * @param {number} opType - * @param {DbgAddrPDP10} dbgAddr - * @return {string|Array.} - */ - getOperand(opCode, opType, dbgAddr) - { - return ""; - } - - /** - * parseInstruction(sOp, sOperand, addr) - * - * TODO: Unimplemented. See parseInstruction() in modules/c1pjs/lib/debugger.js for a sample implementation. - * - * @this {DebuggerPDP10} - * @param {string} sOp - * @param {string|undefined} sOperand - * @param {DbgAddrPDP10} dbgAddr of memory where this instruction is being assembled - * @return {Array.} of opcode bytes; if the instruction can't be parsed, the array will be empty - */ - parseInstruction(sOp, sOperand, dbgAddr) - { - var aOpBytes = []; - this.println("not supported yet"); - return aOpBytes; - } - /** * getRegOutput(iReg) * @@ -3517,7 +3477,31 @@ if (DEBUGGER) { * CPU opcode IDs */ DebuggerPDP10.OPS = { - NONE: 0 + NONE: 0, + HLL: 1, HLLZ: 2, HLLO: 3, HLLE: 4, + HRL: 5, HRLZ: 6, HRLO: 7, HRLE: 8, + HRR: 9, HRRZ: 10, HRRO: 11, HRRE: 12, + HLR: 13, HLRZ: 14, HLRO: 15, HLRE: 16, + MOV: 17, MOVS: 18, MOVN: 19, MOVM: 20, + EXCH: 21, BLT: 22, PUSH: 23, POP: 24, + LDB: 25, DPB: 26, IBP: 27, ILDB: 28, + IDPB: 29, SETZ: 30, SETO: 31, SETA: 32, + SETCA: 33, SETM: 34, SETCM: 35, AND: 36, + ANDCA: 37, ANDCM: 38, ANDCB: 39, IOR: 40, + ORCA: 41, ORCM: 42, ORCB: 43, XOR: 44, + EQV: 45, LSH: 46, LSHC: 47, ROT: 48, + ROTC: 49, ADD: 50, SUB: 51, MUL: 52, + IMUL: 53, DIV: 54, IDIV: 55, ASH: 56, + ASHC: 57, FSC: 58, FADR: 59, FSBR: 60, + FMPR: 61, FDVR: 62, DFN: 63, UFA: 64, + FAD: 65, FSB: 66, FMP: 67, FDV: 68, + AOBJP: 69, AOBJN: 70, CAI: 71, CA: 72, + JUMP: 73, SKIP: 74, AOJ: 75, AOS: 76, + SOJ: 77, SOS: 78, TR: 79, TL: 80, + TD: 81, TS: 82, XCT: 83, JFFO: 84, + JFCL: 85, JSR: 86, JSP: 87, JRST: 88, + JSA: 89, JRA: 90, PUSHJ: 91, POPJ: 92, + UUO: 93 }; /* @@ -3525,6 +3509,30 @@ if (DEBUGGER) { */ DebuggerPDP10.OPNAMES = [ ".WORD", + "HLL", "HLLZ", "HLLO", "HLLE", + "HRL", "HRLZ", "HRLO", "HRLE", + "HRR", "HRRZ", "HRRO", "HRRE", + "HLR", "HLRZ", "HLRO", "HLRE", + "MOV", "MOVS", "MOVN", "MOVM", + "EXCH", "BLT", "PUSH", "POP", + "LDB", "DPB", "IBP", "ILDB", + "IDPB", "SETZ", "SETO", "SETA", + "SETCA", "SETM", "SETCM", "AND", + "ANDCA", "ANDCM", "ANDCB", "IOR", + "ORCA", "ORCM", "ORCB", "XOR", + "EQV", "LSH", "LSHC", "ROT", + "ROTC", "ADD", "SUB", "MUL", + "IMUL", "DIV", "IDIV", "ASH", + "ASHC", "FSC", "FADR", "FSBR", + "FMPR", "FDVR", "DFN", "UFA", + "FAD", "FSB", "FMP", "FDV", + "AOBJP", "AOBJN", "CAI", "CA", + "JUMP", "SKIP", "AOJ", "AOS", + "SOJ", "SOS", "TR", "TL", + "TD", "TS", "XCT", "JFFO", + "JFCL", "JSR", "JSP", "JRST", + "JSA", "JRA", "PUSHJ", "POPJ", + "UUO" ]; DebuggerPDP10.REGS = { @@ -3536,25 +3544,141 @@ if (DEBUGGER) { ]; /* - * The OPTABLE contains opcode masks, and each mask refers to table of possible values, and each - * value refers to an array that contains: + * PDP-10 opcodes are 36-bit values: * - * [0]: {number} of the opcode name (see OP.*) - * [1]: {number} containing the first operand type bit(s), if any - * [2]: {number} containing the second operand type bit(s), if any + * 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 + * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 + * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y * - * Note that, by convention, opcodes that require two operands list the SRC operand first and DST operand - * second (ie, the OPPOSITE of the Intel convention). + * or using modern bit-numbering: * - * Also note that, for some of the newer PDP-11 opcodes (eg, MUL, DIV, ASH, ASHC), the location of the - * opcode's SRC and DST bits are reversed. This is why, for example, you'll see the MUL instruction defined - * below as having OP_DST for the first operand and OP_SRCREG for the second operand. This does NOT mean - * that the opcode's destination operand is being listed first, but rather that the bits describing the source - * operand are in the opcode's OP_DST field. + * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 + * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 + * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y + * + * where OOOOOOOMM represents the operation, with MM (if used) represents the mode: + * + * Mode Suffix Source Destination + * ---- ------ ----- ----------- + * 0: BASIC None E AC + * 1: IMMEDIATE I 0,E AC + * 2: MEMORY M AC E + * 3: SELF S E E (and AC if A is non-zero) + * + * Bits 0-21 (I,X,Y) contain what we call a "reference address" (R), which is used to + * calculate the "effective address" (E). To determine E from R, we must extract I, X, + * and Y from R, set E to Y, then add [X] to E if X is non-zero. If I is zero, then + * we're done; otherwise, we must set set R to [E] and repeat the process. */ - DebuggerPDP10.OPTABLE = {}; + DebuggerPDP10.OPTABLE = { + [PDP10.OPCODE.OPMASK]: { + 0o130: DebuggerPDP10.OPS.UFA, + 0o131: DebuggerPDP10.OPS.DFN, + 0o132: DebuggerPDP10.OPS.FSC, + 0o133: DebuggerPDP10.OPS.IBP, + 0o134: DebuggerPDP10.OPS.ILDB, + 0o135: DebuggerPDP10.OPS.LDB, + 0o136: DebuggerPDP10.OPS.IDPB, + 0o137: DebuggerPDP10.OPS.DPB, + 0o240: DebuggerPDP10.OPS.ASH, + 0o241: DebuggerPDP10.OPS.ROT, + 0o242: DebuggerPDP10.OPS.LSH, + 0o243: DebuggerPDP10.OPS.JFFO, + 0o244: DebuggerPDP10.OPS.ASHC, + 0o245: DebuggerPDP10.OPS.ROTC, + 0o246: DebuggerPDP10.OPS.LSHC, + 0o250: DebuggerPDP10.OPS.EXCH, + 0o251: DebuggerPDP10.OPS.BLT, + 0o252: DebuggerPDP10.OPS.AOBJP, + 0o253: DebuggerPDP10.OPS.AOBJN, + 0o254: DebuggerPDP10.OPS.JRST, // includes HALT, JRSTF, and JEN + 0o255: DebuggerPDP10.OPS.JFCL, // includes JOV, JCRY0, JCRY1, JCRY, and JFOV + 0o256: DebuggerPDP10.OPS.XCT, + 0o260: DebuggerPDP10.OPS.PUSHJ, + 0o261: DebuggerPDP10.OPS.PUSH, + 0o262: DebuggerPDP10.OPS.POP, + 0o263: DebuggerPDP10.OPS.POPJ, + 0o264: DebuggerPDP10.OPS.JSR, + 0o265: DebuggerPDP10.OPS.JSP, + 0o266: DebuggerPDP10.OPS.JSA, + 0o267: DebuggerPDP10.OPS.JRA, + }, + [PDP10.OPCODE.OPMODE]: { + 0o140: DebuggerPDP10.OPS.FAD, + 0o144: DebuggerPDP10.OPS.FADR, + 0o150: DebuggerPDP10.OPS.FSB, + 0o154: DebuggerPDP10.OPS.FSBR, + 0o160: DebuggerPDP10.OPS.FMP, + 0o164: DebuggerPDP10.OPS.FMPR, + 0o170: DebuggerPDP10.OPS.FDV, + 0o174: DebuggerPDP10.OPS.FDVR, + 0o200: DebuggerPDP10.OPS.MOV, + 0o204: DebuggerPDP10.OPS.MOVS, + 0o210: DebuggerPDP10.OPS.MOVN, + 0o214: DebuggerPDP10.OPS.MOVM, + 0o220: DebuggerPDP10.OPS.IMUL, + 0o224: DebuggerPDP10.OPS.MUL, + 0o230: DebuggerPDP10.OPS.IDIV, + 0o234: DebuggerPDP10.OPS.DIV, + 0o270: DebuggerPDP10.OPS.ADD, + 0o274: DebuggerPDP10.OPS.SUB, + 0o400: DebuggerPDP10.OPS.SETZ, + 0o404: DebuggerPDP10.OPS.AND, + 0o410: DebuggerPDP10.OPS.ANDCA, + 0o414: DebuggerPDP10.OPS.SETM, + 0o420: DebuggerPDP10.OPS.ANDCM, + 0o424: DebuggerPDP10.OPS.SETA, + 0o430: DebuggerPDP10.OPS.XOR, + 0o434: DebuggerPDP10.OPS.IOR, + 0o440: DebuggerPDP10.OPS.ANDCB, + 0o444: DebuggerPDP10.OPS.EQV, + 0o450: DebuggerPDP10.OPS.SETCA, + 0o454: DebuggerPDP10.OPS.ORCA, + 0o460: DebuggerPDP10.OPS.SETCM, + 0o464: DebuggerPDP10.OPS.ORCM, + 0o470: DebuggerPDP10.OPS.ORCB, + 0o474: DebuggerPDP10.OPS.SETO, + 0o500: DebuggerPDP10.OPS.HLL, + 0o504: DebuggerPDP10.OPS.HRL, + 0o510: DebuggerPDP10.OPS.HLLZ, + 0o514: DebuggerPDP10.OPS.HRLZ, + 0o520: DebuggerPDP10.OPS.HLLO, + 0o524: DebuggerPDP10.OPS.HRLO, + 0o530: DebuggerPDP10.OPS.HLLE, + 0o534: DebuggerPDP10.OPS.HRLE, + 0o540: DebuggerPDP10.OPS.HRR, + 0o544: DebuggerPDP10.OPS.HLR, + 0o550: DebuggerPDP10.OPS.HRRZ, + 0o554: DebuggerPDP10.OPS.HLRZ, + 0o560: DebuggerPDP10.OPS.HRRO, + 0o564: DebuggerPDP10.OPS.HLRO, + 0o570: DebuggerPDP10.OPS.HRRE, + 0o574: DebuggerPDP10.OPS.HLRE + }, + [PDP10.OPCODE.OPCOMP]: { + 0o300: DebuggerPDP10.OPS.CAI, + 0o310: DebuggerPDP10.OPS.CA, + 0o320: DebuggerPDP10.OPS.JUMP, + 0o330: DebuggerPDP10.OPS.SKIP, + 0o340: DebuggerPDP10.OPS.AOJ, + 0o350: DebuggerPDP10.OPS.AOS, + 0o360: DebuggerPDP10.OPS.SOJ, + 0o370: DebuggerPDP10.OPS.SOS, + }, + [PDP10.OPCODE.OPTEST]: { + 0o600: DebuggerPDP10.OPS.TR, + 0o601: DebuggerPDP10.OPS.TL, + 0o610: DebuggerPDP10.OPS.TD, + 0o611: DebuggerPDP10.OPS.TS, + }, + [PDP10.OPCODE.OPUUO]: { + 0o000: DebuggerPDP10.OPS.UUO + } + }; - DebuggerPDP10.OPNONE = [DebuggerPDP10.OPS.NONE]; + DebuggerPDP10.OPMODES = ["", "I", "M", "S"]; + DebuggerPDP10.OPCOMPS = ["", "L", "E", "LE", "A", "GE", "N", "G"]; + DebuggerPDP10.OPTESTS = ["N", "NE", "NA", "NN", "Z", "ZE", "ZA", "ZN", "C", "CE", "CA", "CN", "O", "OE", "OA", "ON"]; DebuggerPDP10.HISTORY_LIMIT = DEBUG? 100000 : 1000; diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index cf0bdcec1..2b22e54ed 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -99,16 +99,22 @@ var PDP10 = { ADDR_LIMIT: Math.pow(2, 18), DATA_INVALID: -1, DATA_LIMIT: Math.pow(2, 36), + /* - * Assorted common opcodes + * Opcode definitions */ OPCODE: { - INSMASK: 0o777000000000, - ACCMASK: 0o000740000000, - HALTMASK: 0o777740000000, - HALT: 0o254200000000, + OPMASK: 0o777, // operation mask + OPMODE: 0o774, // operation with mode + OPCOMP: 0o770, // operation with compare + OPTEST: 0o611, // operation with test + OPUUO: 0o700, // unimplemented user operation (UUO) mask + OPSHIFT: Math.pow(2, 27), // operation shift + FNSHIFT: Math.pow(2, 23), // function shift + FNHALT: 0o5304, // function code for HALT INVALID: 0o777777777777 // TODO: Resolve }, + /* * Internal operation state flags */ diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 4781865d8..126adaeb9 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -31,175 +31,175 @@ var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:functi function ha(){ea();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return pa(function(){return ba?-b:b}});qa("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ra=Math.pow(2,36),sa=-Math.pow(2,35),t={Vb:0,jb:1,Xb:2,Yb:3,Zb:4,$b:5,ac:6,bc:7,Wa:8,cc:9,kb:10,dc:11,ec:12,lb:13,fc:14,gc:15,hc:16,ic:17,jc:18,kc:19,lc:20,mc:21,nc:22,oc:23,pc:24,qc:25,rc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Va:65,Ub:66,Wb:67,sc:68,E:69,tc:70,uc:71,vc:72,wc:73,xc:74,yc:75,zc:76,Ac:77,Bc:78,Cc:79,Dc:80,Q:81, +var ra=Math.pow(2,36),sa=-Math.pow(2,35),t={Vb:0,jb:1,Xb:2,Yb:3,Zb:4,$b:5,ac:6,bc:7,Ua:8,cc:9,kb:10,dc:11,ec:12,lb:13,fc:14,gc:15,hc:16,ic:17,jc:18,kc:19,lc:20,mc:21,nc:22,oc:23,pc:24,qc:25,rc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ta:65,Ub:66,Wb:67,sc:68,E:69,tc:70,uc:71,vc:72,wc:73,xc:74,yc:75,zc:76,Ac:77,Bc:78,Cc:79,Dc:80,Q:81, Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Mc:97,Nc:98,Oc:99,d:100,e:101,Pc:102,Qc:103,Rc:104,Sc:105,Tc:106,k:107,Uc:108,Vc:109,n:110,Wc:111,p:112,q:113,r:114,Xc:115,t:116,Zc:117,$c:118,ad:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,mb:127}; -function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.i={ready:!1,Ea:!1,Sa:!1,T:!1,error:!1};this.Oa=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.i={ready:!1,Da:!1,Qa:!1,T:!1,error:!1};this.Ma=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} +function Pa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} function H(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function fb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else d.W=f;d.S=f.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function gb(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function J(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, -set:this.Mb};E(this)}r(Ib,u);l=Ib.prototype;l.reset=function(a){this.stop();a&&Kb(this,this.w=0)}; -l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Lb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Mb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Lb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Mb(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Nb(this);Ob(this)};l.la=function(a,b){if(!b)if(this.U&&Pb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Qb(this,this.j=a[0]),Kb(this,this.w=a[1]),Rb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Ob(this);return!0};function Sb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Nb(a,b){for(var c in a.B)Sb(a,c,null!=b?b:a.B[c])}function Tb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ob(a){for(var b in a.g)Tb(a,b,a.g[b][1])} -l.sb=function(a,b,c){if(Lb(this,b)){if(c){var d=this;setTimeout(function(){Mb(d,b);a&&a()},+c);return!1}Mb(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Rb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Tb(this,a,c[1]),!0):!1};l.Nb=function(a){return Lb(this,a)?(Mb(this,a),!0):!1};function Lb(a,b){var c=a.g[b];return c?(Tb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Ub&&(a.N=b==Vb,a.O=b==Wb),!0):!1} -function Mb(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Tb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Xb]&&this.g[Xb][1]&&Yb(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; -l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Xb]&&this.g[Xb][1])Yb(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),Zb(a,0,null),Na(a,!1);else try{var b=this.b.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.v+m;e=k+16384;g-=m;f++;continue}}return jc(kc,e,g)}e=new V(a,e,m,16384,d);gc(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+lc[d]+" at "+Qa(b)),!0):jc(mc,b,c)} -function ec(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function dc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function hc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Xc(a)&&(a.P=a.Z=-1,Tc(a),a.R(),c=!0);c&&a.f(Xc(a)+" cycles: checksum="+H(a.ma))}} -l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&ad(a.D)}ac(a,a.w);a.w=0;a.u=va();a.G=0;Zc(a);return d}function bd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function cd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function dd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} -l.Kb=function(){if(this.i.J){this.qa>=this.Aa&&Zc(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=bd(this,this.i.Ca?1:this.oa);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=dd(this,!0);this.aa+=b;this.w+=b;bc(this,b);$b(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=ed&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Xc(this));Ja(this,e.stack|| -e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,Yc(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.qa+=this.aa;this.G+=c;a(b,c)}}}; -function Yb(a,b){if(!Ka(a))if(a.i.J)a.f(a.toString()+" busy");else{Yc(a);a.i.J=!0;a.i.Ra=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&ad(a.D,!0),a.D.start(a.u,Xc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){dd(this);ac(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Xc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var $c=30,ed=15,Qc=["power","reset"]; -function fd(a){var b=+a.model||1001;Pc.call(this,a,1E6);this.Za=b;this.Ma=+a.addrReset||0;this.fa=null;this.Da=[];this.i.complete=!1}r(fd,Pc);l=fd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.ra=this.Ma;this.j=0;this.ta=this.Gb;this.Ia=this.Tb;this.fa=null;Sc(this);this.i.error=!1;Pc.prototype.reset.call(this)};l.gb=function(){return 0}; -l.save=function(){var a=new O(this);a.set(0,[this.g,this.ra,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,gd(this));a.set(4,cd(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.g=b.next().value;this.ra=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];Yc(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ia(b,a&16383,a)}; -l.Ja=function(a){this.i.complete=!0;var b=this.A?hd(this.A)?1:this.i.Ra?-1:0:0,c=a?this.i.Ra?0:1:-1;this.i.Ra=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(id(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&id(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>g.j;0>>= -g.j;0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,za=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(za)for(G(a,"loading "+I(za)+" bytes at "+I(q)+"-"+I(q+za),4096);za--;)dc(a.C,q++,b[K++]);else q&1?f=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Va&&c<=t.ob&&(b=c-(t.Va-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Pa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Pa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Pa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; -l.ib=function(a){if(!this.g){var b=Rc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=fb(c[0]);if(d!=this.Ka)return;c=fb(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Pa=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(fb(b.substring(c,g))),c=g+1}}return a} -function td(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; -case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function ud(a,b,c){var d;if(b){b=vd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function zd(a,b){if(b)return yd(a,b,a.Z[b]);var c=0;for(b in a.Z)yd(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var xd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Ad(a){rd.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Bd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Cd(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Dd(this,a.messages);this.ra=a.commands;this.Ba=Ed;this.Ma=[];this.L=0;this.Da=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Wc(b,a)}):void 0===global[C]&&(global[C]= -function(a){return Wc(b,a)})}r(Ad,rd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Fd(a){return[a.v,a.qb,a.ba,a.ka,a.Qa]}function Gd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=sd(a,c.Qa=b[4]));return c}l=Ad.prototype; -l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Rc(a,"messages"))&&Dd(this,a);Hd(this,function(a){a:{var b=d.C.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=lc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function Bd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0}l.va=function(a,b,c){var d=!0;c||ue(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(ve(this,a,a.length-1,"set"),Cd(this)));return d}; -function ue(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Cd(a);break}}return g}function we(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})} -function Be(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=ye(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} -function xe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Pd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var sc=[];"call"==Wd&&(Ya=1E5,sc=["CALL"]);for(void 0!==Vd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;Yd++;Ya--}}Yd||(a.f("no "+Xd+"history available"), -a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ae="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||hf,la=wd(a,ca);else{var be=Z(a,ca);be&&(la=be.v-ka.v)}0>la&&(la=0);65536fe;fe++)de+=String.fromCharCode((Ab%64|0)+32), -Ab/=64}ma&&(ma+="\n");ma=ae?ma+(na+","):ma+(R+": "+na+(0>ee?" "+de:""))}ma&&a.f(ma);a.xa=ka;a.ba=kf}}}}break;case "e":if("else"==f[0])break;var ge,he,ie=f[0],vc=f[1];"e"==ie||"ew"==ie?(ge=a.wa,he=a.Xa):vc=null;if(null==vc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Bb=Z(a,vc);if(Bb)for(var Cb=2;Cbzc;){for(var oa=null,of=256;65536>ab.v>>>0;){Ac.v=a.wa(ab,2);if(null==ab.v||!of--)break;if(!(Ac.v&1)){for(var pf=a,Db=Ac,ke=null,bb=Db.v,le=bb,Bc=1;6>=Bc&&bb;Bc++){if(2> "; -M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bMe){if(Ne(d,this.K)){this.B=new O(this,"1.34.0",We);Ne(this.B)&&(Xe(this,d),a=Ye,Ze(this.B));this.B.set(Te,hb());$e(this.B);var e=this.g&&!this.I;if(a==Ue||wa("Click OK to restore the previous "+Fb+" machine state, or CANCEL to reset the machine.")){if(c=Se(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Ne(d,f):("error"==g&&"no machine state"!= -f?(this.Y("Error: "+f),"unable to verify user"==f&&(mb(af,""),this.j=null)):this.f(g+": "+f),Ze(d),Ne(d)?(c=Se(d),e=!0):c=!1))}e&&Qe(this,c?d:null)}else a==Ye&&d.clear()}else Qe(this);delete this.K;delete this.H}e=y(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(bf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(Xe(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function Xe(a,b){if(wa("There may be a problem with your "+Fb+" machine.\n\nTo help us diagnose it, click OK to send this "+Fb+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Fb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function He(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new O(a,"1.34.0"),f=new O(a,"1.34.0",Re),h=hb();f.set(Te,h);g.set(Te,h);g.set(cf,"1.34.0");g.set(df,window?window.location.href:null);g.set(ef,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&g.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;ka;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, +set:this.Mb};E(this)}r(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; +l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Nb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Ob(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Pb(this);Qb(this)};l.la=function(a,b){if(!b)if(this.U&&Rb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Sb(this,this.j=a[0]),Mb(this,this.w=a[1]),Tb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Qb(this);return!0};function Ub(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Pb(a,b){for(var c in a.B)Ub(a,c,null!=b?b:a.B[c])}function Vb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Qb(a){for(var b in a.g)Vb(a,b,a.g[b][1])} +l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d,b);a&&a()},+c);return!1}Ob(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Tb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Vb(this,a,c[1]),!0):!1};l.Nb=function(a){return Nb(this,a)?(Ob(this,a),!0):!1};function Nb(a,b){var c=a.g[b];return c?(Vb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Wb&&(a.N=b==Xb,a.O=b==Yb),!0):!1} +function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; +l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),ac(a,0,null),Na(a,!1);else try{var b=this.b.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.j;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return lc(mc,e,f)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} +function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Zc(a)&&(a.P=a.Z=-1,Vc(a),a.R(),c=!0);c&&a.f(Zc(a)+" cycles: checksum="+H(a.ma))}} +l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&cd(a.D)}cc(a,a.w);a.w=0;a.u=va();a.G=0;ad(a);return d}function dd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ed(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function fd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} +l.Kb=function(){if(this.i.J){this.ra>=this.Aa&&ad(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=dd(this,this.i.Ca?1:this.oa);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=fd(this,!0);this.aa+=b;this.w+=b;dc(this,b);bc(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=gd&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Zc(this));Ja(this,e.stack|| +e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,$c(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.ra+=this.aa;this.G+=c;a(b,c)}}}; +function $b(a,b){if(!Ka(a))if(a.i.J)a.f(a.toString()+" busy");else{$c(a);a.i.J=!0;a.i.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&cd(a.D,!0),a.D.start(a.u,Zc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){fd(this);cc(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Zc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var bd=30,gd=15,Sc=["power","reset"]; +function hd(a){var b=+a.model||1001;Rc.call(this,a,1E6);this.Za=b;this.Xa=+a.addrReset||0;this.fa=null;this.Wa=[];this.i.complete=!1}r(hd,Rc);l=hd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.pa=this.Xa;this.j=0;this.ta=this.Gb;this.Ha=this.Tb;this.fa=null;Uc(this);this.i.error=!1;Rc.prototype.reset.call(this)};l.gb=function(){return 0}; +l.save=function(){var a=new O(this);a.set(0,[this.g,this.pa,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,id(this));a.set(4,ed(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.g=b.next().value;this.pa=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];$c(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ha(b,a&16383,a)}; +l.Ia=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Pa?-1:0:0,c=a?this.i.Pa?0:1:-1;this.i.Pa=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.pa=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>f.j;0>>= +f.j;0>>a.j;0g&&g>=sa&&(g+=ra);g=Math.trunc(Math.abs(g))%ra;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,za=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= +b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(za)for(G(a,"loading "+I(za)+" bytes at "+I(q)+"-"+I(q+za),4096);za--;)fc(a.C,q++,b[K++]);else q&1?g=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ta&&c<=t.ob&&(b=c-(t.Ta-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; +l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ya(b.substring(c,f))),c=f+1}}return a} +function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;g=p+g;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var zd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Cd(a){td.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Ed(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Fd(this,a.messages);this.ra=a.commands;this.L=0;this.Ba=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]=function(a){return Yc(b, +a)})}r(Cd,td);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Gd(a){return[a.v,a.qb,a.ba,a.ka,a.Oa]}function Hd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=ud(a,c.Oa=b[4]));return c}l=Cd.prototype; +l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Tc(a,"messages"))&&Fd(this,a);Id(this,function(a){a:{var b=d.C.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=nc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} +function ve(a,b,c,d){var e=X(b.v),f,g,h,k=0,m=a.wa(b,1),n=m/Ib|0;for(g in we)if(f=we[g][n&g]){g=+g;switch(g){case 508:h=xe;k=n&3;break;case 504:h=ye;k=n&7;break;case 393:h=ze,k=(n&48)>>2|(n&6)>>1}break}n="";h=h&&h[k]||"";"S"==h&&f>Ae&&(h="B");h=Be[f]+h;f||(n=Kd(m));f="";m=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),f+=" "+Kd(k),null==e.v)break;while(e.v!=b.v)}m+=Xa(f,16);m+=Xa(h,5);n&&(m+=" "+n);c&&(m=Xa(m,60)+";"+(c||""),m=a.b.i.Ca?m+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):m+(null!= +d?"="+d.toString():""));return m}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} +l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var f=this.C;f.g[e>>>f.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.j],b==a.G));h.ka||Ed(a);break}}return f} +function Ee(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:f})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.tb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=ve(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} +function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Yd&&(Za=1E5,tc=["CALL"]);for(void 0!==Xd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;$d++;Za--}}$d||(a.f("no "+Zd+"history available"), +a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ce="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||of,la=yd(a,ca);else{var de=Z(a,ca);de&&(la=de.v-ka.v)}0>la&&(la=0);65536he;he++)fe+=String.fromCharCode((Bb%64|0)+32), +Bb/=64}ma&&(ma+="\n");ma=ce?ma+(na+","):ma+(R+": "+na+(0>ge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==g[0])break;var ie,je,ke=g[0],wc=g[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;DbAc;){for(var oa=null,uf=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!uf--)break;if(!(Bc.v&1)){for(var vf=a,Eb=Bc,me=null,cb=Eb.v,ne=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Te(d,g):("error"==f&&"no machine state"!= +g?(this.Y("Error: "+g),"unable to verify user"==g&&(mb(gf,""),this.j=null)):this.f(f+": "+g),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(hf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(cf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function cf(a,b){if(wa("There may be a problem with your "+Ab+" machine.\n\nTo help us diagnose it, click OK to send this "+Ab+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Ab;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} +function Me(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",Xe),h=hb();g.set(Ze,h);f.set(Ze,h);f.set(jf,"1.34.0");f.set(kf,window?window.location.href:null);f.set(lf,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&f.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],f);Af(a,b,c)}})}else c(a,null)} -function Bf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--xf||wb(!0));m=!1}var h,k,m=!0;xf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?yf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--xf||wb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--xf|| -wb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?yf(c,b,a,e,!0,g,n):zf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(K){f(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Bf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Bf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Gf(a,b,c)}})}else c(a,null)} +function Hf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function g(a){f("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| +wb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,f,n):Ff(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(K){g(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),t={yb:0,Oa:1,Ab:2,Bb:3,Cb:4,Db:5,Eb:6,Fb:7,Fa:8,Gb:9,Pa:10,Hb:11,Ib:12,Qa:13,Jb:14,Kb:15,Lb:16,Mb:17,Nb:18,Ob:19,Pb:20,Qb:21,Rb:22,Sb:23,Tb:24,Ub:25,Vb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ea:65,xb:66,zb:67,Wb:68,E:69,Xb:70,Yb:71,Zb:72,$b:73,ac:74,bc:75,cc:76,dc:77,ec:78,fc:79,gc:80,Q:81, -hc:82,ic:83,jc:84,kc:85,lc:86,mc:87,nc:88,oc:89,Ua:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pc:97,qc:98,rc:99,d:100,e:101,sc:102,tc:103,uc:104,vc:105,wc:106,k:107,xc:108,yc:109,n:110,zc:111,p:112,q:113,r:114,Ac:115,t:116,Bc:117,Cc:118,Dc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ra:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ia=b.comment;this.Ta=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ia=this.id:(this.ja=this.id.substr(0,a),this.ia=this.id.substr(a+1));this.b={ready:!1,na:!1,Ba:!1,w:!1,error:!1};this.qa=null;this.b.error=!1;this.o=this.c=this.j=this.m=this.Y=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ja=-Math.pow(2,35),t={wb:0,Ma:1,yb:2,zb:3,Ab:4,Bb:5,Cb:6,Db:7,Ea:8,Eb:9,Na:10,Fb:11,Gb:12,Oa:13,Hb:14,Ib:15,Jb:16,Kb:17,Lb:18,Mb:19,Nb:20,Ob:21,Pb:22,Qb:23,Rb:24,Sb:25,Tb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Da:65,vb:66,xb:67,Ub:68,E:69,Vb:70,Wb:71,Xb:72,Yb:73,Zb:74,$b:75,ac:76,bc:77,cc:78,dc:79,ec:80,Q:81, +fc:82,gc:83,hc:84,ic:85,jc:86,kc:87,lc:88,mc:89,Sa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,nc:97,oc:98,pc:99,d:100,e:101,qc:102,rc:103,sc:104,tc:105,uc:106,k:107,vc:108,wc:109,n:110,xc:111,p:112,q:113,r:114,yc:115,t:116,zc:117,Ac:118,Bc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Pa:127}; +function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ha=b.comment;this.Ra=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ia=this.id:(this.ja=this.id.substr(0,a),this.ia=this.id.substr(a+1));this.b={ready:!1,na:!1,Ba:!1,w:!1,error:!1};this.qa=null;this.b.error=!1;this.o=this.c=this.l=this.m=this.Y=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba;a++)this.a["S"+a]=[0,0,!1,!1,this.cb,a];this.o=this.c=this.j=this.m=null;this.exports={hold:this.Wa,toggle:this.qb,reset:this.mb, -set:this.pb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; -k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.l[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.mb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.l)ab(a,c,null!=b?b:a.l[c])}function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])} -k.Wa=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; -k.pb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.f].Ca(b&16383,b)}else a=this.c.ba(this.f);N(this,this.h=a)}};k.bb=function(a){a||this.c.b.u||Q(this,this.g)};k.ab=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.cb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<a;a++)this.a["S"+a]=[0,0,!1,!1,this.ab,a];this.o=this.c=this.l=this.m=null;this.exports={hold:this.Ua,toggle:this.ob,reset:this.kb, +set:this.nb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; +k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.l=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.kb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.j)ab(a,c,null!=b?b:a.j[c])}function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])} +k.Ua=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; +k.nb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.f];a.h++;b=c.a(b&16383,b);a.h--;a=b}else a=this.c.ba(this.f);N(this,this.h=a)}};k.$a=function(a){a||this.c.b.v||Q(this,this.g)};k.Za=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.ab=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(0,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){a.a[(b&a.g)>>>a.f].ua(c,b&16383,b)} -function nb(a){for(var b=0,c=[],d=0;d>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(a,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){var d=a.a[(b&a.g)>>>a.f];a.h++;d.m(c,b&16383,b);a.h--} +function nb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.K&&(a.K+=a.ea,c=!0);0<=a.fa&&a.fa<=X(a)&&(a.ea=a.fa=-1,Fb(a),S(a),c=!0);c&&a.J(X(a)+" cycles: checksum="+F(a.ka))}} -k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.F/a.H&&(b=1);a.L=b;b=a.xa*a.L;if(a.H!=b){a.H=b;b=a.H.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.J("target speed: "+b)}c&&a.m&&(c=a.m,c.Y&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Y.focus(),window&&window.scrollTo(b,d)))}hb(a,a.h);a.h=0;a.g=w();a.s=0;Hb(a)}function Jb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Kb(a,b){var c=a.v-=a.A;a.A=0;b&&(a.v=0);return c} -k.nb=function(){if(this.b.u){this.ma>=this.za&&Hb(this,!0);this.O=0;this.ca=w();if(this.s){var a=this.ca-this.s;a>this.ya&&(this.g+=a,this.g>this.ca&&(this.g=this.ca))}try{do{for(var b,c=this.b.oa?1:this.ga,d=this.l.length-1;0<=d;d--){var e=this.l[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.va(b)}catch(f){if("number"!=typeof f)throw f;}b=Kb(this,!0);this.O+=b;this.h+=b;ib(this,b);gb(this,b);this.M-=b;if(0>=this.M){this.M+=this.ga;++this.Aa>=Lb&&(this.m&&T(this.m,void 0),this.Aa=0);break}}while(this.b.u)}catch(f){S(this); -this.m&&this.m.stop(w(),X(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.u){a=setTimeout;b=this.Ja;this.s=w();c=this.ya;this.O&&(c=Math.round(c*this.O/this.ga));c-=this.s-this.ca;if(d=this.s-this.g)this.F=Math.round(this.h/(10*d))/100,864E5<=d&&(this.B=0,Gb(this));if(0>c||this.Fc&&(this.g-=c),c=0;this.ma+=this.O;this.s+=c;a(b,c)}}}; -function R(a){var b;a.b.error?(a.J(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.u)a.J(a.toString()+" busy");else{Gb(a);a.b.u=!0;a.b.Da=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.g,X(a));a.o||a.status("Started");setTimeout(a.Ja,0)}}k.va=function(){return 0};function S(a){var b=!1;if(a.b.u){Kb(a);hb(a,a.h);a.h=0;a.b.u=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),X(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Ib=30,Lb=15,Db=["power","reset"]; -function Mb(a){var b=+a.model||1001;V.call(this,a,1E6);this.Sa=b;this.Ha=+a.addrReset||0;this.W=null;this.Ga=[];this.b.complete=!1}r(Mb,V);k=Mb.prototype;k.reset=function(){this.status("Model "+this.Sa);this.b.u&&S(this);this.V=this.f=this.Ka=this.Ha;this.a=0;this.ba=this.jb;this.ta=this.wb;this.W=null;Eb(this);this.b.error=!1;V.prototype.reset.call(this)};k.Ma=function(){return 0}; -k.save=function(){var a=new P(this);a.set(0,[this.f,this.Ka,this.V,this.a]);a.set(1,[]);a.set(2,[this.B,this.L,this.b.G]);a.set(3,Nb(this));a.set(4,Jb(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.f=b.next().value;this.Ka=b.next().value;this.V=b.next().value;this.a=b.next().value;b=a[2];this.B=b[0];Gb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.f].ba(a&16383,a)};k.wb=function(a,b){var c=this.j;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(b,a&16383,a)}; -k.va=function(a){this.b.complete=!0;var b=a?this.b.Da?0:1:-1;this.b.Da=!1;this.v=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){S(this);break}if(0>b)break}this.a&=15;a=this.f;this.ba(a);this.f=(a+1)%Sa}while(0>>f.f;0=c+d?a>>c&(1<=a.K&&(a.K+=a.ea,c=!0);0<=a.fa&&a.fa<=X(a)&&(a.ea=a.fa=-1,Fb(a),S(a),c=!0);c&&a.J(X(a)+" cycles: checksum="+F(a.ka))}} +k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.F/a.H&&(b=1);a.L=b;b=a.wa*a.L;if(a.H!=b){a.H=b;b=a.H.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.J("target speed: "+b)}c&&a.m&&(c=a.m,c.Y&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Y.focus(),window&&window.scrollTo(b,d)))}hb(a,a.h);a.h=0;a.g=w();a.s=0;Hb(a)}function Jb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Kb(a,b){var c=a.u-=a.A;a.A=0;b&&(a.u=0);return c} +k.lb=function(){if(this.b.v){this.ma>=this.ya&&Hb(this,!0);this.O=0;this.ca=w();if(this.s){var a=this.ca-this.s;a>this.xa&&(this.g+=a,this.g>this.ca&&(this.g=this.ca))}try{do{for(var b,c=this.b.oa?1:this.ga,d=this.j.length-1;0<=d;d--){var e=this.j[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.ua(b)}catch(f){if("number"!=typeof f)throw f;}b=Kb(this,!0);this.O+=b;this.h+=b;ib(this,b);gb(this,b);this.M-=b;if(0>=this.M){this.M+=this.ga;++this.za>=Lb&&(this.m&&T(this.m,void 0),this.za=0);break}}while(this.b.v)}catch(f){S(this); +this.m&&this.m.stop(w(),X(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ia;this.s=w();c=this.xa;this.O&&(c=Math.round(c*this.O/this.ga));c-=this.s-this.ca;if(d=this.s-this.g)this.F=Math.round(this.h/(10*d))/100,864E5<=d&&(this.B=0,Gb(this));if(0>c||this.Fc&&(this.g-=c),c=0;this.ma+=this.O;this.s+=c;a(b,c)}}}; +function R(a){var b;a.b.error?(a.J(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.J(a.toString()+" busy");else{Gb(a);a.b.v=!0;a.b.Ca=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.g,X(a));a.o||a.status("Started");setTimeout(a.Ia,0)}}k.ua=function(){return 0};function S(a){var b=!1;if(a.b.v){Kb(a);hb(a,a.h);a.h=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),X(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Ib=30,Lb=15,Db=["power","reset"]; +function Mb(a){var b=+a.model||1001;V.call(this,a,1E6);this.Qa=b;this.Ga=+a.addrReset||0;this.W=null;this.Fa=[];this.b.complete=!1}r(Mb,V);k=Mb.prototype;k.reset=function(){this.status("Model "+this.Qa);this.b.v&&S(this);this.V=this.f=this.Aa=this.Ga;this.a=0;this.ba=this.hb;this.ta=this.ub;this.W=null;Eb(this);this.b.error=!1;V.prototype.reset.call(this)};k.Ka=function(){return 0}; +k.save=function(){var a=new P(this);a.set(0,[this.f,this.Aa,this.V,this.a]);a.set(1,[]);a.set(2,[this.B,this.L,this.b.G]);a.set(3,Nb(this));a.set(4,Jb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.f=b.next().value;this.Aa=b.next().value;this.V=b.next().value;this.a=b.next().value;b=a[2];this.B=b[0];Gb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.f].ba(a&16383,a)};k.ub=function(a,b){var c=this.l;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(b,a&16383,a)}; +k.ua=function(a){this.b.complete=!0;var b=a?this.b.Ca?0:1:-1;this.b.Ca=!1;this.u=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){S(this);break}if(0>b)break}this.a&=15;a=this.Aa=this.f;this.ba(a);this.f=(a+1)%Sa}while(0>>f.f;0>>=f.f;0>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,n=b[l++]&255|(b[l++]&255)<<8,p=b[l++]&255|(b[l++]&255)<<8,m=m+((n&255)+(n>>8)+(p&255)+(p>>8)),M=l,qa=n-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(qa)for(;qa--;)kb(a.j,p++,b[M++]);else p&1?g=!0:null==d&&(d=p);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ea&&c<=t.Ua&&(b=c-(t.Ea-t.Oa));b&&(a.preventDefault&&a.preventDefault(),d.ra(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.Qa&&(b=t.Pa);d.ra(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ra(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.U=function(a,b,c,d){this.m=a;this.j=b;this.c=c;this.o=d;E(this)}; -k.Na=function(a){if(!this.a){var b=W(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ia)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.l=e.receiveData){this.g=a;this.status("Connected "+this.ja+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.Na(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ra=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,n=b[l++]&255|(b[l++]&255)<<8,p=b[l++]&255|(b[l++]&255)<<8,m=m+((n&255)+(n>>8)+(p&255)+(p>>8)),M=l,qa=n-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(qa)for(;qa--;)kb(a.l,p++,b[M++]);else p&1?g=!0:null==d&&(d=p);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Da&&c<=t.Sa&&(b=c-(t.Da-t.Ma));b&&(a.preventDefault&&a.preventDefault(),d.ra(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.Oa&&(b=t.Na);d.ra(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ra(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.U=function(a,b,c,d){this.m=a;this.l=b;this.c=c;this.o=d;E(this)}; +k.La=function(a){if(!this.a){var b=W(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ia)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ja+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.La(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ra=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;b\nLicense: GPL version 3 or later ");for(b=0;bXb){if(Z(d,this.B)){this.l=new P(this,"1.34.0",fc);Z(this.l)&&(gc(this,d),a=hc,ic(this.l));this.l.set(cc,Da());jc(this.l);var e=this.a&&!this.A;if(a==dc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=bc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(kc,""),this.f=null)):this.J(f+": "+g),ic(d),Z(d)?(c=bc(d),e=!0):c=!1))}e&&$b(this,c?d:null)}else a==hc&&d.clear()}else $b(this);delete this.B;delete this.v}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.c&&(lc(this,this.c,b,c,a),T(this,-2),this.c.G());this.K&&(gc(this,b),b.clear());!c&&this.l&&(this.l.clear(),delete this.l);this.h=0}; +k.Z=function(a){void 0===a&&(a=this.a||(this.B?dc:Xb));if(!this.h){this.h++;var b=!1,c=!1;this.K=!1;var d=this.u||new P(this,"1.34.0");if(a==ec)b=!0;else if(a>Xb){if(Z(d,this.B)){this.j=new P(this,"1.34.0",fc);Z(this.j)&&(gc(this,d),a=hc,ic(this.j));this.j.set(cc,Da());jc(this.j);var e=this.a&&!this.A;if(a==dc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=bc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(kc,""),this.f=null)):this.J(f+": "+g),ic(d),Z(d)?(c=bc(d),e=!0):c=!1))}e&&$b(this,c?d:null)}else a==hc&&d.clear()}else $b(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.c&&(lc(this,this.c,b,c,a),T(this,-2),this.c.G());this.K&&(gc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; function gc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.f||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function mc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new P(a,"1.34.0"),g=new P(a,"1.34.0",ac),h=Da();g.set(cc,h);f.set(cc,h);f.set(nc,"1.34.0");f.set(oc,window?window.location.href:null);f.set(pc,window?window.navigator.userAgent:"");a.c&&a.c.N&&(c&&(b&&(a.c.b.G=a.c.b.u),S(a.c)),d=a.c.N(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.wa+=d))&&(e.textContent=c.b.u?c.F.toFixed(2)+"Mhz":"Stopped",c.wa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.c.b.u;d=!!(a.c.a&8);if(0>=b||60<=(a.A+=b)){e=a.c.f;if(a.i.PC){var f=a.o&&a.o.l||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.f=a.c.f:0=d||30<=(c.va+=d))&&(e.textContent=c.b.v?c.F.toFixed(2)+"Mhz":"Stopped",c.va=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.c.b.v;d=!!(a.c.a&8);if(0>=b||60<=(a.A+=b)){e=a.c.f;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.f=a.c.f:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), From 10181fdc45fdafa8641ab4db862dc6c579dff22c Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Sat, 25 Feb 2017 10:45:25 -0800 Subject: [PATCH 09/30] Added I/O instructions to PDP-10 disassembler --- modules/pdp10/lib/debugger.js | 237 +++++++++++++++++------------ modules/pdp10/lib/defines.js | 25 +-- versions/pdpjs/1.34.0/pdp10-dbg.js | 169 ++++++++++---------- 3 files changed, 239 insertions(+), 192 deletions(-) diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index c7616e747..c4d2ba277 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -1326,7 +1326,7 @@ class DebuggerPDP10 extends Debugger { */ if (!nState) { opCode = this.cpu.readWord(addr); - if ((opCode / PDP10.OPCODE.FNSHIFT)|0 == PDP10.OPCODE.FNHALT && this.cpu.getLastPC() == addr) { + if ((opCode >> PDP10.OPCODE.FNSHIFT) == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { addr = this.cpu.advancePC(1); } } @@ -1354,7 +1354,7 @@ class DebuggerPDP10 extends Debugger { if (opCode < 0) { opCode = this.cpu.readWord(addr); } - if ((opCode & 0xffff) != PDP10.OPCODE.INVALID) { + if (opCode >= 0) { var dbgAddr = this.aInstructionHistory[this.iInstructionHistory]; this.setAddr(dbgAddr, addr); // if (DEBUG) dbgAddr.cycleCount = cpu.getCycles(); @@ -1389,6 +1389,12 @@ class DebuggerPDP10 extends Debugger { opNum = opMasks[op & mask]; if (opNum) { opMask = +mask; + /* + * When we extracted op from opCode using OPSHIFT, we included 6 additional bits + * to help distinguish OPIO instructions from non-OPIO instructions. But for the + * following tests, we don't need those bits, so we get rid of them now. + */ + op >>= 6; switch(opMask) { case PDP10.OPCODE.OPMODE: aModes = DebuggerPDP10.OPMODES; @@ -1412,7 +1418,20 @@ class DebuggerPDP10 extends Debugger { if (sMode == "S" && opNum > DebuggerPDP10.OPS.MOVM) sMode = "B"; var sOpName = opNames[opNum] + sMode; - if (!opNum) sOperands = this.toStrWord(opCode); + if (!opNum) { + sOperands = this.toStrWord(opCode); + } else { + if (opMask == PDP10.OPCODE.OPIO) { + sOperands = this.toStrBase((opCode / PDP10.OPCODE.IOSHIFT) & PDP10.OPCODE.IOMASK, -1); + } else { + sOperands = this.toStrBase((opCode >> PDP10.OPCODE.FNSHIFT) & PDP10.OPCODE.FNMASK, -1); + } + if (sOperands) sOperands += ','; + if (opCode & PDP10.OPCODE.I_BIT) sOperands += '@'; + sOperands += this.toStrBase(opCode & PDP10.OPCODE.Y_MASK, -1); + var i = (opCode >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; + if (i) sOperands += '(' + this.toStrBase(i, -1) + ')'; + } var sOpCodes = ""; var sLine = this.toStrAddr(dbgAddrOp) + ":"; @@ -3501,7 +3520,9 @@ if (DEBUGGER) { TD: 81, TS: 82, XCT: 83, JFFO: 84, JFCL: 85, JSR: 86, JSP: 87, JRST: 88, JSA: 89, JRA: 90, PUSHJ: 91, POPJ: 92, - UUO: 93 + BLKI: 93, DATAI: 94, BLKO: 95, DATAO: 96, + CONO: 97, CONI: 98, CONSZ: 99, CONSO: 100, + UUO: 101 }; /* @@ -3532,6 +3553,8 @@ if (DEBUGGER) { "TD", "TS", "XCT", "JFFO", "JFCL", "JSR", "JSP", "JRST", "JSA", "JRA", "PUSHJ", "POPJ", + "BLKI", "DATAI", "BLKO", "DATAO", + "CONO", "CONI", "CONSZ", "CONSO", "UUO" ]; @@ -3544,7 +3567,7 @@ if (DEBUGGER) { ]; /* - * PDP-10 opcodes are 36-bit values: + * PDP-10 opcodes are 36-bit values, many of which use the following layout: * * 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 @@ -3565,114 +3588,130 @@ if (DEBUGGER) { * 2: MEMORY M AC E * 3: SELF S E E (and AC if A is non-zero) * - * Bits 0-21 (I,X,Y) contain what we call a "reference address" (R), which is used to + * Input-output instructions look like: + * + * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 + * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 + * 1 1 1 D D D D D D D O O O I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y + * + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to * calculate the "effective address" (E). To determine E from R, we must extract I, X, * and Y from R, set E to Y, then add [X] to E if X is non-zero. If I is zero, then * we're done; otherwise, we must set set R to [E] and repeat the process. */ DebuggerPDP10.OPTABLE = { [PDP10.OPCODE.OPMASK]: { - 0o130: DebuggerPDP10.OPS.UFA, - 0o131: DebuggerPDP10.OPS.DFN, - 0o132: DebuggerPDP10.OPS.FSC, - 0o133: DebuggerPDP10.OPS.IBP, - 0o134: DebuggerPDP10.OPS.ILDB, - 0o135: DebuggerPDP10.OPS.LDB, - 0o136: DebuggerPDP10.OPS.IDPB, - 0o137: DebuggerPDP10.OPS.DPB, - 0o240: DebuggerPDP10.OPS.ASH, - 0o241: DebuggerPDP10.OPS.ROT, - 0o242: DebuggerPDP10.OPS.LSH, - 0o243: DebuggerPDP10.OPS.JFFO, - 0o244: DebuggerPDP10.OPS.ASHC, - 0o245: DebuggerPDP10.OPS.ROTC, - 0o246: DebuggerPDP10.OPS.LSHC, - 0o250: DebuggerPDP10.OPS.EXCH, - 0o251: DebuggerPDP10.OPS.BLT, - 0o252: DebuggerPDP10.OPS.AOBJP, - 0o253: DebuggerPDP10.OPS.AOBJN, - 0o254: DebuggerPDP10.OPS.JRST, // includes HALT, JRSTF, and JEN - 0o255: DebuggerPDP10.OPS.JFCL, // includes JOV, JCRY0, JCRY1, JCRY, and JFOV - 0o256: DebuggerPDP10.OPS.XCT, - 0o260: DebuggerPDP10.OPS.PUSHJ, - 0o261: DebuggerPDP10.OPS.PUSH, - 0o262: DebuggerPDP10.OPS.POP, - 0o263: DebuggerPDP10.OPS.POPJ, - 0o264: DebuggerPDP10.OPS.JSR, - 0o265: DebuggerPDP10.OPS.JSP, - 0o266: DebuggerPDP10.OPS.JSA, - 0o267: DebuggerPDP10.OPS.JRA, + 0o13000: DebuggerPDP10.OPS.UFA, + 0o13100: DebuggerPDP10.OPS.DFN, + 0o13200: DebuggerPDP10.OPS.FSC, + 0o13300: DebuggerPDP10.OPS.IBP, + 0o13400: DebuggerPDP10.OPS.ILDB, + 0o13500: DebuggerPDP10.OPS.LDB, + 0o13600: DebuggerPDP10.OPS.IDPB, + 0o13700: DebuggerPDP10.OPS.DPB, + 0o24000: DebuggerPDP10.OPS.ASH, + 0o24100: DebuggerPDP10.OPS.ROT, + 0o24200: DebuggerPDP10.OPS.LSH, + 0o24300: DebuggerPDP10.OPS.JFFO, + 0o24400: DebuggerPDP10.OPS.ASHC, + 0o24500: DebuggerPDP10.OPS.ROTC, + 0o24600: DebuggerPDP10.OPS.LSHC, + 0o25000: DebuggerPDP10.OPS.EXCH, + 0o25100: DebuggerPDP10.OPS.BLT, + 0o25200: DebuggerPDP10.OPS.AOBJP, + 0o25300: DebuggerPDP10.OPS.AOBJN, + 0o25400: DebuggerPDP10.OPS.JRST, // includes HALT, JRSTF, and JEN + 0o25500: DebuggerPDP10.OPS.JFCL, // includes JOV, JCRY0, JCRY1, JCRY, and JFOV + 0o25600: DebuggerPDP10.OPS.XCT, + 0o26000: DebuggerPDP10.OPS.PUSHJ, + 0o26100: DebuggerPDP10.OPS.PUSH, + 0o26200: DebuggerPDP10.OPS.POP, + 0o26300: DebuggerPDP10.OPS.POPJ, + 0o26400: DebuggerPDP10.OPS.JSR, + 0o26500: DebuggerPDP10.OPS.JSP, + 0o26600: DebuggerPDP10.OPS.JSA, + 0o26700: DebuggerPDP10.OPS.JRA, }, [PDP10.OPCODE.OPMODE]: { - 0o140: DebuggerPDP10.OPS.FAD, - 0o144: DebuggerPDP10.OPS.FADR, - 0o150: DebuggerPDP10.OPS.FSB, - 0o154: DebuggerPDP10.OPS.FSBR, - 0o160: DebuggerPDP10.OPS.FMP, - 0o164: DebuggerPDP10.OPS.FMPR, - 0o170: DebuggerPDP10.OPS.FDV, - 0o174: DebuggerPDP10.OPS.FDVR, - 0o200: DebuggerPDP10.OPS.MOV, - 0o204: DebuggerPDP10.OPS.MOVS, - 0o210: DebuggerPDP10.OPS.MOVN, - 0o214: DebuggerPDP10.OPS.MOVM, - 0o220: DebuggerPDP10.OPS.IMUL, - 0o224: DebuggerPDP10.OPS.MUL, - 0o230: DebuggerPDP10.OPS.IDIV, - 0o234: DebuggerPDP10.OPS.DIV, - 0o270: DebuggerPDP10.OPS.ADD, - 0o274: DebuggerPDP10.OPS.SUB, - 0o400: DebuggerPDP10.OPS.SETZ, - 0o404: DebuggerPDP10.OPS.AND, - 0o410: DebuggerPDP10.OPS.ANDCA, - 0o414: DebuggerPDP10.OPS.SETM, - 0o420: DebuggerPDP10.OPS.ANDCM, - 0o424: DebuggerPDP10.OPS.SETA, - 0o430: DebuggerPDP10.OPS.XOR, - 0o434: DebuggerPDP10.OPS.IOR, - 0o440: DebuggerPDP10.OPS.ANDCB, - 0o444: DebuggerPDP10.OPS.EQV, - 0o450: DebuggerPDP10.OPS.SETCA, - 0o454: DebuggerPDP10.OPS.ORCA, - 0o460: DebuggerPDP10.OPS.SETCM, - 0o464: DebuggerPDP10.OPS.ORCM, - 0o470: DebuggerPDP10.OPS.ORCB, - 0o474: DebuggerPDP10.OPS.SETO, - 0o500: DebuggerPDP10.OPS.HLL, - 0o504: DebuggerPDP10.OPS.HRL, - 0o510: DebuggerPDP10.OPS.HLLZ, - 0o514: DebuggerPDP10.OPS.HRLZ, - 0o520: DebuggerPDP10.OPS.HLLO, - 0o524: DebuggerPDP10.OPS.HRLO, - 0o530: DebuggerPDP10.OPS.HLLE, - 0o534: DebuggerPDP10.OPS.HRLE, - 0o540: DebuggerPDP10.OPS.HRR, - 0o544: DebuggerPDP10.OPS.HLR, - 0o550: DebuggerPDP10.OPS.HRRZ, - 0o554: DebuggerPDP10.OPS.HLRZ, - 0o560: DebuggerPDP10.OPS.HRRO, - 0o564: DebuggerPDP10.OPS.HLRO, - 0o570: DebuggerPDP10.OPS.HRRE, - 0o574: DebuggerPDP10.OPS.HLRE + 0o14000: DebuggerPDP10.OPS.FAD, + 0o14400: DebuggerPDP10.OPS.FADR, + 0o15000: DebuggerPDP10.OPS.FSB, + 0o15400: DebuggerPDP10.OPS.FSBR, + 0o16000: DebuggerPDP10.OPS.FMP, + 0o16400: DebuggerPDP10.OPS.FMPR, + 0o17000: DebuggerPDP10.OPS.FDV, + 0o17400: DebuggerPDP10.OPS.FDVR, + 0o20000: DebuggerPDP10.OPS.MOV, + 0o20400: DebuggerPDP10.OPS.MOVS, + 0o21000: DebuggerPDP10.OPS.MOVN, + 0o21400: DebuggerPDP10.OPS.MOVM, + 0o22000: DebuggerPDP10.OPS.IMUL, + 0o22400: DebuggerPDP10.OPS.MUL, + 0o23000: DebuggerPDP10.OPS.IDIV, + 0o23400: DebuggerPDP10.OPS.DIV, + 0o27000: DebuggerPDP10.OPS.ADD, + 0o27400: DebuggerPDP10.OPS.SUB, + 0o40000: DebuggerPDP10.OPS.SETZ, + 0o40400: DebuggerPDP10.OPS.AND, + 0o41000: DebuggerPDP10.OPS.ANDCA, + 0o41400: DebuggerPDP10.OPS.SETM, + 0o42000: DebuggerPDP10.OPS.ANDCM, + 0o42400: DebuggerPDP10.OPS.SETA, + 0o43000: DebuggerPDP10.OPS.XOR, + 0o43400: DebuggerPDP10.OPS.IOR, + 0o44000: DebuggerPDP10.OPS.ANDCB, + 0o44400: DebuggerPDP10.OPS.EQV, + 0o45000: DebuggerPDP10.OPS.SETCA, + 0o45400: DebuggerPDP10.OPS.ORCA, + 0o46000: DebuggerPDP10.OPS.SETCM, + 0o46400: DebuggerPDP10.OPS.ORCM, + 0o47000: DebuggerPDP10.OPS.ORCB, + 0o47400: DebuggerPDP10.OPS.SETO, + 0o50000: DebuggerPDP10.OPS.HLL, + 0o50400: DebuggerPDP10.OPS.HRL, + 0o51000: DebuggerPDP10.OPS.HLLZ, + 0o51400: DebuggerPDP10.OPS.HRLZ, + 0o52000: DebuggerPDP10.OPS.HLLO, + 0o52400: DebuggerPDP10.OPS.HRLO, + 0o53000: DebuggerPDP10.OPS.HLLE, + 0o53400: DebuggerPDP10.OPS.HRLE, + 0o54000: DebuggerPDP10.OPS.HRR, + 0o54400: DebuggerPDP10.OPS.HLR, + 0o55000: DebuggerPDP10.OPS.HRRZ, + 0o55400: DebuggerPDP10.OPS.HLRZ, + 0o56000: DebuggerPDP10.OPS.HRRO, + 0o56400: DebuggerPDP10.OPS.HLRO, + 0o57000: DebuggerPDP10.OPS.HRRE, + 0o57400: DebuggerPDP10.OPS.HLRE }, [PDP10.OPCODE.OPCOMP]: { - 0o300: DebuggerPDP10.OPS.CAI, - 0o310: DebuggerPDP10.OPS.CA, - 0o320: DebuggerPDP10.OPS.JUMP, - 0o330: DebuggerPDP10.OPS.SKIP, - 0o340: DebuggerPDP10.OPS.AOJ, - 0o350: DebuggerPDP10.OPS.AOS, - 0o360: DebuggerPDP10.OPS.SOJ, - 0o370: DebuggerPDP10.OPS.SOS, + 0o30000: DebuggerPDP10.OPS.CAI, + 0o31000: DebuggerPDP10.OPS.CA, + 0o32000: DebuggerPDP10.OPS.JUMP, + 0o33000: DebuggerPDP10.OPS.SKIP, + 0o34000: DebuggerPDP10.OPS.AOJ, + 0o35000: DebuggerPDP10.OPS.AOS, + 0o36000: DebuggerPDP10.OPS.SOJ, + 0o37000: DebuggerPDP10.OPS.SOS, }, [PDP10.OPCODE.OPTEST]: { - 0o600: DebuggerPDP10.OPS.TR, - 0o601: DebuggerPDP10.OPS.TL, - 0o610: DebuggerPDP10.OPS.TD, - 0o611: DebuggerPDP10.OPS.TS, + 0o60000: DebuggerPDP10.OPS.TR, + 0o60100: DebuggerPDP10.OPS.TL, + 0o61000: DebuggerPDP10.OPS.TD, + 0o61100: DebuggerPDP10.OPS.TS, + }, + [PDP10.OPCODE.OPIO]: { + 0o70000: DebuggerPDP10.OPS.BLKI, + 0o70004: DebuggerPDP10.OPS.DATAI, + 0o70010: DebuggerPDP10.OPS.BLKO, + 0o70014: DebuggerPDP10.OPS.DATAO, + 0o70020: DebuggerPDP10.OPS.CONO, + 0o70024: DebuggerPDP10.OPS.CONI, + 0o70030: DebuggerPDP10.OPS.CONSZ, + 0o70034: DebuggerPDP10.OPS.CONSO }, [PDP10.OPCODE.OPUUO]: { - 0o000: DebuggerPDP10.OPS.UUO + 0o00000: DebuggerPDP10.OPS.UUO } }; diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 2b22e54ed..dfa55c8e0 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -104,15 +104,22 @@ var PDP10 = { * Opcode definitions */ OPCODE: { - OPMASK: 0o777, // operation mask - OPMODE: 0o774, // operation with mode - OPCOMP: 0o770, // operation with compare - OPTEST: 0o611, // operation with test - OPUUO: 0o700, // unimplemented user operation (UUO) mask - OPSHIFT: Math.pow(2, 27), // operation shift - FNSHIFT: Math.pow(2, 23), // function shift - FNHALT: 0o5304, // function code for HALT - INVALID: 0o777777777777 // TODO: Resolve + OPMASK: 0o77700, // operation mask + OPMODE: 0o77400, // operation with mode + OPCOMP: 0o77000, // operation with compare + OPTEST: 0o71100, // operation with test + OPIO: 0o70034, // input-output instructions + OPUUO: 0o70000, // unimplemented user operation (UUO) mask + OPSHIFT: Math.pow(2, 21), // operation shift + FNSHIFT: 23, // accumulator/function shift + FNMASK: 0o17, // accumulator/function mask (after shift) + IOSHIFT: Math.pow(2, 26), // input-output device code shift + IOMASK: 0o177, // input-output device code mask (after shift) + Y_MASK: 0o777777, + X_SHIFT: 18, + X_MASK: 0o17, + I_BIT: 0o20000000, + HALT: 0o5304 // operation code for HALT }, /* diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 126adaeb9..ef0b7bab3 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -36,32 +36,32 @@ Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^": function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.i={ready:!1,Da:!1,Qa:!1,T:!1,error:!1};this.Ma=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} +function Pa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} function H(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function gb(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function J(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} +function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else d.W=f;d.S=f.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, set:this.Mb};E(this)}r(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart= @@ -71,17 +71,17 @@ l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d, function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),ac(a,0,null),Na(a,!1);else try{var b=this.b.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.g["S"+b][1]=a.u&1<c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.j;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return lc(mc,e,f)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} -function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;dd.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>g&&(m=g);h.Ga=e-h.v+m;e=k+16384;g-=m;f++;continue}}return lc(mc,e,g)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} +function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ha(b,a&16383,a)}; l.Ia=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Pa?-1:0:0,c=a?this.i.Pa?0:1:-1;this.i.Pa=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.pa=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>f.j;0>>= -f.j;0>>g.j;0>>= +g.j;0>>a.j;0g&&g>=sa&&(g+=ra);g=Math.trunc(Math.abs(g))%ra;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,za=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(za)for(G(a,"loading "+I(za)+" bytes at "+I(q)+"-"+I(q+za),4096);za--;)fc(a.C,q++,b[K++]);else q&1?g=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,Aa=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= +b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(Aa)for(G(a,"loading "+I(Aa)+" bytes at "+I(q)+"-"+I(q+Aa),4096);Aa--;)fc(a.C,q++,b[K++]);else q&1?f=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ta&&c<=t.ob&&(b=c-(t.Ta-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; -l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ya(b.substring(c,f))),c=f+1}}return a} -function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; -case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ea.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} +function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;g=p+g;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +function Ad(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var g=4,f="";if(!g||4>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} var zd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Cd(a){td.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Ed(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Fd(this,a.messages);this.ra=a.commands;this.L=0;this.Ba=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]=function(a){return Yc(b, a)})}r(Cd,td);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Gd(a){return[a.v,a.qb,a.ba,a.ka,a.Oa]}function Hd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=ud(a,c.Oa=b[4]));return c}l=Cd.prototype; @@ -131,75 +131,76 @@ l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Tc(a,"messages" I(n.size)+" "+m),c!=Hc&&(c=-1),m=0);a+=16384;e++}}});E(this)}; l.da=function(a,b,c){var d=this;switch(b){case "debugInput":return this.aa=this.F[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",Yc(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.wd&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d=a.b.ta(b)),68719476735!=(d&65535)&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function ve(a,b,c,d){var e=X(b.v),f,g,h,k=0,m=a.wa(b,1),n=m/Ib|0;for(g in we)if(f=we[g][n&g]){g=+g;switch(g){case 508:h=xe;k=n&3;break;case 504:h=ye;k=n&7;break;case 393:h=ze,k=(n&48)>>2|(n&6)>>1}break}n="";h=h&&h[k]||"";"S"==h&&f>Ae&&(h="B");h=Be[f]+h;f||(n=Kd(m));f="";m=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),f+=" "+Kd(k),null==e.v)break;while(e.v!=b.v)}m+=Xa(f,16);m+=Xa(h,5);n&&(m+=" "+n);c&&(m=Xa(m,60)+";"+(c||""),m=a.b.i.Ca?m+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):m+(null!= -d?"="+d.toString():""));return m}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} -l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var f=this.C;f.g[e>>>f.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.j],b==a.G));h.ka||Ed(a);break}}return f} +function kd(a,b,c){var d=-1;if(!c&&(d=a.b.ta(b),2756==d>>23&&a.b.pa==b)){b=a.b;var e=b.g;b.g=(e+1)%Gb;b=e}if(0d&&(d=a.b.ta(b)),0<=d&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} +function ve(a,b,c,d){var e=X(b.v),g,f,h,k=0,m=a.wa(b,1),n=m/Ib|0,p;for(p in we)if(g=we[p][n&p]){f=+p;n>>=6;switch(f){case 32512:h=xe;k=n&3;break;case 32256:h=ye;k=n&7;break;case 29248:h=ze,k=(n&48)>>2|(n&6)>>1}break}h=h&&h[k]||"";"S"==h&&g>Ae&&(h="B");h=Be[g]+h;g?((g=28700==f?W(a,m/Jb&127,-1):W(a,m>>23&15,-1))&&(g+=","),m&4194304&&(g+="@"),g+=W(a,m&262143,-1),(m=m>>18&15)&&(g+="("+W(a,m,-1)+")")):g=Kd(m);m="";f=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),m+=" "+Kd(k),null==e.v)break;while(e.v!= +b.v)}f+=Xa(m,16);f+=Xa(h,5);g&&(f+=" "+g);c&&(f=Xa(f,60)+";"+(c||""),f=a.b.i.Ca?f+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):f+(null!=d?"="+d.toString():""));return f}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} +l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Ed(a);break}}return g} function Ee(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:f})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.tb;if(e>=g&&eb[0]?1:a[0]>>0,f],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=ve(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} -function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=ve(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} +function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Yd&&(Za=1E5,tc=["CALL"]);for(void 0!==Xd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;$d++;Za--}}$d||(a.f("no "+Zd+"history available"), -a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ce="ds"==Da;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||of,la=yd(a,ca);else{var de=Z(a,ca);de&&(la=de.v-ka.v)}0>la&&(la=0);65536he;he++)fe+=String.fromCharCode((Bb%64|0)+32), -Bb/=64}ma&&(ma+="\n");ma=ce?ma+(na+","):ma+(R+": "+na+(0>ge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==g[0])break;var ie,je,ke=g[0],wc=g[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;Dbla&&(la=0);65536he;he++)fe+=String.fromCharCode((Bb%64|0)+32), +Bb/=64}ma&&(ma+="\n");ma=ce?ma+(na+","):ma+(R+": "+na+(0>ge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==f[0])break;var ie,je,ke=f[0],wc=f[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;DbAc;){for(var oa=null,uf=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!uf--)break;if(!(Bc.v&1)){for(var vf=a,Eb=Bc,me=null,cb=Eb.v,ne=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;b\nLicense: GPL version 3 or later ");for(b=0;bSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Te(d,g):("error"==f&&"no machine state"!= -g?(this.Y("Error: "+g),"unable to verify user"==g&&(mb(gf,""),this.j=null)):this.f(f+": "+g),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(f=0;fSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Te(d,f):("error"==g&&"no machine state"!= +f?(this.Y("Error: "+f),"unable to verify user"==f&&(mb(gf,""),this.j=null)):this.f(g+": "+f),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(hf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(cf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; function cf(a,b){if(wa("There may be a problem with your "+Ab+" machine.\n\nTo help us diagnose it, click OK to send this "+Ab+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Ab;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function Me(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",Xe),h=hb();g.set(Ze,h);f.set(Ze,h);f.set(jf,"1.34.0");f.set(kf,window?window.location.href:null);f.set(lf,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&f.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Gf(a,b,c)}})}else c(a,null)} -function Hf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function g(a){f("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| -wb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,f,n):Ff(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(K){g(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;nf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);Gf(a,b,c)}})}else c(a,null)} +function Hf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| +wb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,g,n):Ff(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(K){f(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n Date: Sat, 25 Feb 2017 13:28:47 -0800 Subject: [PATCH 10/30] Used the new PDP-10 disassembler in test mode to help generate the cpuops.js skeleton --- modules/pdp10/lib/cpuops.js | 3683 ++++++++++++++++++++++++++++ modules/pdp10/lib/debugger.js | 122 +- package.json | 1 + versions/pdpjs/1.34.0/pdp10-dbg.js | 151 +- versions/pdpjs/1.34.0/pdp10.js | 1 + 5 files changed, 3848 insertions(+), 110 deletions(-) create mode 100644 modules/pdp10/lib/cpuops.js diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js new file mode 100644 index 000000000..0a58ea825 --- /dev/null +++ b/modules/pdp10/lib/cpuops.js @@ -0,0 +1,3683 @@ +/** + * @fileoverview Implements PDP-10 opcode handlers. + * @author Jeff Parsons + * @copyright © Jeff Parsons 2012-2017 + * + * This file is part of PCjs, a computer emulation software project at . + * + * PCjs is free software: you can redistribute it and/or modify it under the terms of the + * GNU General Public License as published by the Free Software Foundation, either version 3 + * of the License, or (at your option) any later version. + * + * PCjs is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without + * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with PCjs. If not, + * see . + * + * You are required to include the above copyright notice in every modified copy of this work + * and to display that copyright notice when the software starts running; see COPYRIGHT in + * . + * + * Some PCjs files also attempt to load external resource files, such as character-image files, + * ROM files, and disk image files. Those external resource files are not considered part of PCjs + * for purposes of the GNU General Public License, and the author does not claim any copyright + * as to their contents. + */ + +"use strict"; + +if (NODE) { + var PDP10 = require("./defines"); +} + +/** + * opUUO(000000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opUUO = function(opCode) +{ +}; + +/** + * opUFA(130000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opUFA = function(opCode) +{ +}; + +/** + * opDFN(131000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDFN = function(opCode) +{ +}; + +/** + * opFSC(132000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSC = function(opCode) +{ +}; + +/** + * opIBP(133000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIBP = function(opCode) +{ +}; + +/** + * opILDB(134000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opILDB = function(opCode) +{ +}; + +/** + * opLDB(135000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opLDB = function(opCode) +{ +}; + +/** + * opIDPB(136000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIDPB = function(opCode) +{ +}; + +/** + * opDPB(137000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDPB = function(opCode) +{ +}; + +/** + * opFAD(140000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFAD = function(opCode) +{ +}; + +/** + * opFADI(141000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADI = function(opCode) +{ +}; + +/** + * opFADM(142000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADM = function(opCode) +{ +}; + +/** + * opFADB(143000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADB = function(opCode) +{ +}; + +/** + * opFADR(144000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADR = function(opCode) +{ +}; + +/** + * opFADRI(145000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADRI = function(opCode) +{ +}; + +/** + * opFADRM(146000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADRM = function(opCode) +{ +}; + +/** + * opFADRB(147000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFADRB = function(opCode) +{ +}; + +/** + * opFSB(150000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSB = function(opCode) +{ +}; + +/** + * opFSBI(151000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBI = function(opCode) +{ +}; + +/** + * opFSBM(152000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBM = function(opCode) +{ +}; + +/** + * opFSBB(153000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBB = function(opCode) +{ +}; + +/** + * opFSBR(154000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBR = function(opCode) +{ +}; + +/** + * opFSBRI(155000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBRI = function(opCode) +{ +}; + +/** + * opFSBRM(156000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBRM = function(opCode) +{ +}; + +/** + * opFSBRB(157000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFSBRB = function(opCode) +{ +}; + +/** + * opFMP(160000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMP = function(opCode) +{ +}; + +/** + * opFMPI(161000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPI = function(opCode) +{ +}; + +/** + * opFMPM(162000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPM = function(opCode) +{ +}; + +/** + * opFMPB(163000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPB = function(opCode) +{ +}; + +/** + * opFMPR(164000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPR = function(opCode) +{ +}; + +/** + * opFMPRI(165000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPRI = function(opCode) +{ +}; + +/** + * opFMPRM(166000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPRM = function(opCode) +{ +}; + +/** + * opFMPRB(167000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFMPRB = function(opCode) +{ +}; + +/** + * opFDV(170000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDV = function(opCode) +{ +}; + +/** + * opFDVI(171000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVI = function(opCode) +{ +}; + +/** + * opFDVM(172000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVM = function(opCode) +{ +}; + +/** + * opFDVB(173000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVB = function(opCode) +{ +}; + +/** + * opFDVR(174000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVR = function(opCode) +{ +}; + +/** + * opFDVRI(175000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVRI = function(opCode) +{ +}; + +/** + * opFDVRM(176000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVRM = function(opCode) +{ +}; + +/** + * opFDVRB(177000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opFDVRB = function(opCode) +{ +}; + +/** + * opMOV(200000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOV = function(opCode) +{ +}; + +/** + * opMOVI(201000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVI = function(opCode) +{ +}; + +/** + * opMOVM(200000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVM = function(opCode) +{ +}; + +/** + * opMOVS(200000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVS = function(opCode) +{ +}; + +/** + * opMOVSI(205000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVSI = function(opCode) +{ +}; + +/** + * opMOVSM(206000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVSM = function(opCode) +{ +}; + +/** + * opMOVSS(207000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVSS = function(opCode) +{ +}; + +/** + * opMOVN(210000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVN = function(opCode) +{ +}; + +/** + * opMOVNI(211000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVNI = function(opCode) +{ +}; + +/** + * opMOVNM(212000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVNM = function(opCode) +{ +}; + +/** + * opMOVNS(213000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVNS = function(opCode) +{ +}; + +/** + * opMOVMI(215000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVMI = function(opCode) +{ +}; + +/** + * opMOVMM(216000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVMM = function(opCode) +{ +}; + +/** + * opMOVMS(217000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMOVMS = function(opCode) +{ +}; + +/** + * opIMUL(220000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIMUL = function(opCode) +{ +}; + +/** + * opIMULI(221000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIMULI = function(opCode) +{ +}; + +/** + * opIMULM(222000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIMULM = function(opCode) +{ +}; + +/** + * opIMULB(223000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIMULB = function(opCode) +{ +}; + +/** + * opMUL(224000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMUL = function(opCode) +{ +}; + +/** + * opMULI(225000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMULI = function(opCode) +{ +}; + +/** + * opMULM(226000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMULM = function(opCode) +{ +}; + +/** + * opMULB(227000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opMULB = function(opCode) +{ +}; + +/** + * opIDIV(230000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIDIV = function(opCode) +{ +}; + +/** + * opIDIVI(231000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIDIVI = function(opCode) +{ +}; + +/** + * opIDIVM(232000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIDIVM = function(opCode) +{ +}; + +/** + * opIDIVB(233000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIDIVB = function(opCode) +{ +}; + +/** + * opDIV(234000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDIV = function(opCode) +{ +}; + +/** + * opDIVI(235000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDIVI = function(opCode) +{ +}; + +/** + * opDIVM(236000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDIVM = function(opCode) +{ +}; + +/** + * opDIVB(237000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDIVB = function(opCode) +{ +}; + +/** + * opASH(240000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opASH = function(opCode) +{ +}; + +/** + * opROT(241000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opROT = function(opCode) +{ +}; + +/** + * opLSH(242000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opLSH = function(opCode) +{ +}; + +/** + * opJFFO(243000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJFFO = function(opCode) +{ +}; + +/** + * opASHC(244000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opASHC = function(opCode) +{ +}; + +/** + * opROTC(245000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opROTC = function(opCode) +{ +}; + +/** + * opLSHC(246000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opLSHC = function(opCode) +{ +}; + +/** + * opEXCH(250000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opEXCH = function(opCode) +{ +}; + +/** + * opBLT(251000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opBLT = function(opCode) +{ +}; + +/** + * opAOBJP(252000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOBJP = function(opCode) +{ +}; + +/** + * opAOBJN(253000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOBJN = function(opCode) +{ +}; + +/** + * opJRST(254000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJRST = function(opCode) +{ +}; + +/** + * opJFCL(255000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJFCL = function(opCode) +{ +}; + +/** + * opXCT(256000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opXCT = function(opCode) +{ +}; + +/** + * opPUSHJ(260000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opPUSHJ = function(opCode) +{ +}; + +/** + * opPUSH(261000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opPUSH = function(opCode) +{ +}; + +/** + * opPOP(262000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opPOP = function(opCode) +{ +}; + +/** + * opPOPJ(263000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opPOPJ = function(opCode) +{ +}; + +/** + * opJSR(264000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJSR = function(opCode) +{ +}; + +/** + * opJSP(265000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJSP = function(opCode) +{ +}; + +/** + * opJSA(266000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJSA = function(opCode) +{ +}; + +/** + * opJRA(267000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJRA = function(opCode) +{ +}; + +/** + * opADD(270000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opADD = function(opCode) +{ +}; + +/** + * opADDI(271000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opADDI = function(opCode) +{ +}; + +/** + * opADDM(272000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opADDM = function(opCode) +{ +}; + +/** + * opADDB(273000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opADDB = function(opCode) +{ +}; + +/** + * opSUB(274000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSUB = function(opCode) +{ +}; + +/** + * opSUBI(275000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSUBI = function(opCode) +{ +}; + +/** + * opSUBM(276000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSUBM = function(opCode) +{ +}; + +/** + * opSUBB(277000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSUBB = function(opCode) +{ +}; + +/** + * opCAI(300000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAI = function(opCode) +{ +}; + +/** + * opCAIL(301000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIL = function(opCode) +{ +}; + +/** + * opCAIE(302000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIE = function(opCode) +{ +}; + +/** + * opCAILE(303000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAILE = function(opCode) +{ +}; + +/** + * opCAIA(304000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIA = function(opCode) +{ +}; + +/** + * opCAIGE(305000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIGE = function(opCode) +{ +}; + +/** + * opCAIN(306000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIN = function(opCode) +{ +}; + +/** + * opCAIG(307000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAIG = function(opCode) +{ +}; + +/** + * opCA(310000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCA = function(opCode) +{ +}; + +/** + * opCAL(311000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAL = function(opCode) +{ +}; + +/** + * opCAE(312000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAE = function(opCode) +{ +}; + +/** + * opCALE(313000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCALE = function(opCode) +{ +}; + +/** + * opCAA(314000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAA = function(opCode) +{ +}; + +/** + * opCAGE(315000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAGE = function(opCode) +{ +}; + +/** + * opCAN(316000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAN = function(opCode) +{ +}; + +/** + * opCAG(317000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCAG = function(opCode) +{ +}; + +/** + * opJUMP(320000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMP = function(opCode) +{ +}; + +/** + * opJUMPL(321000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPL = function(opCode) +{ +}; + +/** + * opJUMPE(322000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPE = function(opCode) +{ +}; + +/** + * opJUMPLE(323000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPLE = function(opCode) +{ +}; + +/** + * opJUMPA(324000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPA = function(opCode) +{ +}; + +/** + * opJUMPGE(325000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPGE = function(opCode) +{ +}; + +/** + * opJUMPN(326000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPN = function(opCode) +{ +}; + +/** + * opJUMPG(327000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opJUMPG = function(opCode) +{ +}; + +/** + * opSKIP(330000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIP = function(opCode) +{ +}; + +/** + * opSKIPL(331000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPL = function(opCode) +{ +}; + +/** + * opSKIPE(332000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPE = function(opCode) +{ +}; + +/** + * opSKIPLE(333000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPLE = function(opCode) +{ +}; + +/** + * opSKIPA(334000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPA = function(opCode) +{ +}; + +/** + * opSKIPGE(335000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPGE = function(opCode) +{ +}; + +/** + * opSKIPN(336000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPN = function(opCode) +{ +}; + +/** + * opSKIPG(337000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSKIPG = function(opCode) +{ +}; + +/** + * opAOJ(340000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJ = function(opCode) +{ +}; + +/** + * opAOJL(341000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJL = function(opCode) +{ +}; + +/** + * opAOJE(342000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJE = function(opCode) +{ +}; + +/** + * opAOJLE(343000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJLE = function(opCode) +{ +}; + +/** + * opAOJA(344000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJA = function(opCode) +{ +}; + +/** + * opAOJGE(345000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJGE = function(opCode) +{ +}; + +/** + * opAOJN(346000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJN = function(opCode) +{ +}; + +/** + * opAOJG(347000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOJG = function(opCode) +{ +}; + +/** + * opAOS(350000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOS = function(opCode) +{ +}; + +/** + * opAOSL(351000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSL = function(opCode) +{ +}; + +/** + * opAOSE(352000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSE = function(opCode) +{ +}; + +/** + * opAOSLE(353000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSLE = function(opCode) +{ +}; + +/** + * opAOSA(354000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSA = function(opCode) +{ +}; + +/** + * opAOSGE(355000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSGE = function(opCode) +{ +}; + +/** + * opAOSN(356000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSN = function(opCode) +{ +}; + +/** + * opAOSG(357000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAOSG = function(opCode) +{ +}; + +/** + * opSOJ(360000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJ = function(opCode) +{ +}; + +/** + * opSOJL(361000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJL = function(opCode) +{ +}; + +/** + * opSOJE(362000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJE = function(opCode) +{ +}; + +/** + * opSOJLE(363000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJLE = function(opCode) +{ +}; + +/** + * opSOJA(364000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJA = function(opCode) +{ +}; + +/** + * opSOJGE(365000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJGE = function(opCode) +{ +}; + +/** + * opSOJN(366000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJN = function(opCode) +{ +}; + +/** + * opSOJG(367000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOJG = function(opCode) +{ +}; + +/** + * opSOS(370000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOS = function(opCode) +{ +}; + +/** + * opSOSL(371000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSL = function(opCode) +{ +}; + +/** + * opSOSE(372000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSE = function(opCode) +{ +}; + +/** + * opSOSLE(373000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSLE = function(opCode) +{ +}; + +/** + * opSOSA(374000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSA = function(opCode) +{ +}; + +/** + * opSOSGE(375000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSGE = function(opCode) +{ +}; + +/** + * opSOSN(376000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSN = function(opCode) +{ +}; + +/** + * opSOSG(377000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSOSG = function(opCode) +{ +}; + +/** + * opSETZ(400000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETZ = function(opCode) +{ +}; + +/** + * opSETZI(401000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETZI = function(opCode) +{ +}; + +/** + * opSETZM(402000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETZM = function(opCode) +{ +}; + +/** + * opSETZB(403000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETZB = function(opCode) +{ +}; + +/** + * opAND(404000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opAND = function(opCode) +{ +}; + +/** + * opANDI(405000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDI = function(opCode) +{ +}; + +/** + * opANDM(406000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDM = function(opCode) +{ +}; + +/** + * opANDB(407000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDB = function(opCode) +{ +}; + +/** + * opANDCA(410000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCA = function(opCode) +{ +}; + +/** + * opANDCAI(411000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCAI = function(opCode) +{ +}; + +/** + * opANDCAM(412000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCAM = function(opCode) +{ +}; + +/** + * opANDCAB(413000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCAB = function(opCode) +{ +}; + +/** + * opSETM(414000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETM = function(opCode) +{ +}; + +/** + * opSETMI(415000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETMI = function(opCode) +{ +}; + +/** + * opSETMM(416000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETMM = function(opCode) +{ +}; + +/** + * opSETMB(417000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETMB = function(opCode) +{ +}; + +/** + * opANDCM(420000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCM = function(opCode) +{ +}; + +/** + * opANDCMI(421000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCMI = function(opCode) +{ +}; + +/** + * opANDCMM(422000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCMM = function(opCode) +{ +}; + +/** + * opANDCMB(423000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCMB = function(opCode) +{ +}; + +/** + * opSETA(424000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETA = function(opCode) +{ +}; + +/** + * opSETAI(425000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETAI = function(opCode) +{ +}; + +/** + * opSETAM(426000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETAM = function(opCode) +{ +}; + +/** + * opSETAB(427000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETAB = function(opCode) +{ +}; + +/** + * opXOR(430000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opXOR = function(opCode) +{ +}; + +/** + * opXORI(431000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opXORI = function(opCode) +{ +}; + +/** + * opXORM(432000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opXORM = function(opCode) +{ +}; + +/** + * opXORB(433000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opXORB = function(opCode) +{ +}; + +/** + * opIOR(434000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIOR = function(opCode) +{ +}; + +/** + * opIORI(435000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIORI = function(opCode) +{ +}; + +/** + * opIORM(436000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIORM = function(opCode) +{ +}; + +/** + * opIORB(437000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIORB = function(opCode) +{ +}; + +/** + * opANDCB(440000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCB = function(opCode) +{ +}; + +/** + * opANDCBI(441000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCBI = function(opCode) +{ +}; + +/** + * opANDCBM(442000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCBM = function(opCode) +{ +}; + +/** + * opANDCBB(443000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opANDCBB = function(opCode) +{ +}; + +/** + * opEQV(444000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opEQV = function(opCode) +{ +}; + +/** + * opEQVI(445000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opEQVI = function(opCode) +{ +}; + +/** + * opEQVM(446000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opEQVM = function(opCode) +{ +}; + +/** + * opEQVB(447000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opEQVB = function(opCode) +{ +}; + +/** + * opSETCA(450000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCA = function(opCode) +{ +}; + +/** + * opSETCAI(451000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCAI = function(opCode) +{ +}; + +/** + * opSETCAM(452000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCAM = function(opCode) +{ +}; + +/** + * opSETCAB(453000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCAB = function(opCode) +{ +}; + +/** + * opORCA(454000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCA = function(opCode) +{ +}; + +/** + * opORCAI(455000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCAI = function(opCode) +{ +}; + +/** + * opORCAM(456000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCAM = function(opCode) +{ +}; + +/** + * opORCAB(457000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCAB = function(opCode) +{ +}; + +/** + * opSETCM(460000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCM = function(opCode) +{ +}; + +/** + * opSETCMI(461000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCMI = function(opCode) +{ +}; + +/** + * opSETCMM(462000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCMM = function(opCode) +{ +}; + +/** + * opSETCMB(463000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETCMB = function(opCode) +{ +}; + +/** + * opORCM(464000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCM = function(opCode) +{ +}; + +/** + * opORCMI(465000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCMI = function(opCode) +{ +}; + +/** + * opORCMM(466000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCMM = function(opCode) +{ +}; + +/** + * opORCMB(467000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCMB = function(opCode) +{ +}; + +/** + * opORCB(470000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCB = function(opCode) +{ +}; + +/** + * opORCBI(471000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCBI = function(opCode) +{ +}; + +/** + * opORCBM(472000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCBM = function(opCode) +{ +}; + +/** + * opORCBB(473000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opORCBB = function(opCode) +{ +}; + +/** + * opSETO(474000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETO = function(opCode) +{ +}; + +/** + * opSETOI(475000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETOI = function(opCode) +{ +}; + +/** + * opSETOM(476000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETOM = function(opCode) +{ +}; + +/** + * opSETOB(477000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opSETOB = function(opCode) +{ +}; + +/** + * opHLL(500000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLL = function(opCode) +{ +}; + +/** + * opHLLI(501000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLI = function(opCode) +{ +}; + +/** + * opHLLM(502000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLM = function(opCode) +{ +}; + +/** + * opHLLS(503000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLS = function(opCode) +{ +}; + +/** + * opHRL(504000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRL = function(opCode) +{ +}; + +/** + * opHRLI(505000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLI = function(opCode) +{ +}; + +/** + * opHRLM(506000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLM = function(opCode) +{ +}; + +/** + * opHRLS(507000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLS = function(opCode) +{ +}; + +/** + * opHLLZ(510000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLZ = function(opCode) +{ +}; + +/** + * opHLLZI(511000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLZI = function(opCode) +{ +}; + +/** + * opHLLZM(512000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLZM = function(opCode) +{ +}; + +/** + * opHLLZS(513000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLZS = function(opCode) +{ +}; + +/** + * opHRLZ(514000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLZ = function(opCode) +{ +}; + +/** + * opHRLZI(515000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLZI = function(opCode) +{ +}; + +/** + * opHRLZM(516000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLZM = function(opCode) +{ +}; + +/** + * opHRLZS(517000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLZS = function(opCode) +{ +}; + +/** + * opHLLO(520000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLO = function(opCode) +{ +}; + +/** + * opHLLOI(521000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLOI = function(opCode) +{ +}; + +/** + * opHLLOM(522000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLOM = function(opCode) +{ +}; + +/** + * opHLLOS(523000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLOS = function(opCode) +{ +}; + +/** + * opHRLO(524000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLO = function(opCode) +{ +}; + +/** + * opHRLOI(525000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLOI = function(opCode) +{ +}; + +/** + * opHRLOM(526000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLOM = function(opCode) +{ +}; + +/** + * opHRLOS(527000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLOS = function(opCode) +{ +}; + +/** + * opHLLE(530000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLE = function(opCode) +{ +}; + +/** + * opHLLEI(531000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLEI = function(opCode) +{ +}; + +/** + * opHLLEM(532000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLEM = function(opCode) +{ +}; + +/** + * opHLLES(533000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLLES = function(opCode) +{ +}; + +/** + * opHRLE(534000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLE = function(opCode) +{ +}; + +/** + * opHRLEI(535000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLEI = function(opCode) +{ +}; + +/** + * opHRLEM(536000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLEM = function(opCode) +{ +}; + +/** + * opHRLES(537000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRLES = function(opCode) +{ +}; + +/** + * opHRR(540000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRR = function(opCode) +{ +}; + +/** + * opHRRI(541000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRI = function(opCode) +{ +}; + +/** + * opHRRM(542000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRM = function(opCode) +{ +}; + +/** + * opHRRS(543000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRS = function(opCode) +{ +}; + +/** + * opHLR(544000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLR = function(opCode) +{ +}; + +/** + * opHLRI(545000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRI = function(opCode) +{ +}; + +/** + * opHLRM(546000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRM = function(opCode) +{ +}; + +/** + * opHLRS(547000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRS = function(opCode) +{ +}; + +/** + * opHRRZ(550000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRZ = function(opCode) +{ +}; + +/** + * opHRRZI(551000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRZI = function(opCode) +{ +}; + +/** + * opHRRZM(552000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRZM = function(opCode) +{ +}; + +/** + * opHRRZS(553000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRZS = function(opCode) +{ +}; + +/** + * opHLRZ(554000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRZ = function(opCode) +{ +}; + +/** + * opHLRZI(555000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRZI = function(opCode) +{ +}; + +/** + * opHLRZM(556000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRZM = function(opCode) +{ +}; + +/** + * opHLRZS(557000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRZS = function(opCode) +{ +}; + +/** + * opHRRO(560000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRO = function(opCode) +{ +}; + +/** + * opHRROI(561000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRROI = function(opCode) +{ +}; + +/** + * opHRROM(562000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRROM = function(opCode) +{ +}; + +/** + * opHRROS(563000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRROS = function(opCode) +{ +}; + +/** + * opHLRO(564000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRO = function(opCode) +{ +}; + +/** + * opHLROI(565000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLROI = function(opCode) +{ +}; + +/** + * opHLROM(566000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLROM = function(opCode) +{ +}; + +/** + * opHLROS(567000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLROS = function(opCode) +{ +}; + +/** + * opHRRE(570000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRE = function(opCode) +{ +}; + +/** + * opHRREI(571000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRREI = function(opCode) +{ +}; + +/** + * opHRREM(572000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRREM = function(opCode) +{ +}; + +/** + * opHRRES(573000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHRRES = function(opCode) +{ +}; + +/** + * opHLRE(574000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRE = function(opCode) +{ +}; + +/** + * opHLREI(575000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLREI = function(opCode) +{ +}; + +/** + * opHLREM(576000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLREM = function(opCode) +{ +}; + +/** + * opHLRES(577000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opHLRES = function(opCode) +{ +}; + +/** + * opTRN(600000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRN = function(opCode) +{ +}; + +/** + * opTLN(601000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLN = function(opCode) +{ +}; + +/** + * opTRNE(602000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRNE = function(opCode) +{ +}; + +/** + * opTLNE(603000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLNE = function(opCode) +{ +}; + +/** + * opTRNA(604000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRNA = function(opCode) +{ +}; + +/** + * opTLNA(605000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLNA = function(opCode) +{ +}; + +/** + * opTRNN(606000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRNN = function(opCode) +{ +}; + +/** + * opTLNN(607000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLNN = function(opCode) +{ +}; + +/** + * opTDN(610000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDN = function(opCode) +{ +}; + +/** + * opTSN(611000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSN = function(opCode) +{ +}; + +/** + * opTDNE(612000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDNE = function(opCode) +{ +}; + +/** + * opTSNE(613000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSNE = function(opCode) +{ +}; + +/** + * opTDNA(614000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDNA = function(opCode) +{ +}; + +/** + * opTSNA(615000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSNA = function(opCode) +{ +}; + +/** + * opTDNN(616000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDNN = function(opCode) +{ +}; + +/** + * opTSNN(617000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSNN = function(opCode) +{ +}; + +/** + * opTRZ(620000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRZ = function(opCode) +{ +}; + +/** + * opTLZ(621000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLZ = function(opCode) +{ +}; + +/** + * opTRZE(622000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRZE = function(opCode) +{ +}; + +/** + * opTLZE(623000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLZE = function(opCode) +{ +}; + +/** + * opTRZA(624000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRZA = function(opCode) +{ +}; + +/** + * opTLZA(625000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLZA = function(opCode) +{ +}; + +/** + * opTRZN(626000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRZN = function(opCode) +{ +}; + +/** + * opTLZN(627000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLZN = function(opCode) +{ +}; + +/** + * opTDZ(630000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDZ = function(opCode) +{ +}; + +/** + * opTSZ(631000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSZ = function(opCode) +{ +}; + +/** + * opTDZE(632000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDZE = function(opCode) +{ +}; + +/** + * opTSZE(633000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSZE = function(opCode) +{ +}; + +/** + * opTDZA(634000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDZA = function(opCode) +{ +}; + +/** + * opTSZA(635000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSZA = function(opCode) +{ +}; + +/** + * opTDZN(636000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDZN = function(opCode) +{ +}; + +/** + * opTSZN(637000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSZN = function(opCode) +{ +}; + +/** + * opTRC(640000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRC = function(opCode) +{ +}; + +/** + * opTLC(641000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLC = function(opCode) +{ +}; + +/** + * opTRCE(642000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRCE = function(opCode) +{ +}; + +/** + * opTLCE(643000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLCE = function(opCode) +{ +}; + +/** + * opTRCA(644000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRCA = function(opCode) +{ +}; + +/** + * opTLCA(645000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLCA = function(opCode) +{ +}; + +/** + * opTRCN(646000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRCN = function(opCode) +{ +}; + +/** + * opTLCN(647000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLCN = function(opCode) +{ +}; + +/** + * opTDC(650000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDC = function(opCode) +{ +}; + +/** + * opTSC(651000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSC = function(opCode) +{ +}; + +/** + * opTDCE(652000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDCE = function(opCode) +{ +}; + +/** + * opTSCE(653000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSCE = function(opCode) +{ +}; + +/** + * opTDCA(654000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDCA = function(opCode) +{ +}; + +/** + * opTSCA(655000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSCA = function(opCode) +{ +}; + +/** + * opTDCN(656000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDCN = function(opCode) +{ +}; + +/** + * opTSCN(657000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSCN = function(opCode) +{ +}; + +/** + * opTRO(660000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRO = function(opCode) +{ +}; + +/** + * opTLO(661000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLO = function(opCode) +{ +}; + +/** + * opTROE(662000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTROE = function(opCode) +{ +}; + +/** + * opTLOE(663000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLOE = function(opCode) +{ +}; + +/** + * opTROA(664000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTROA = function(opCode) +{ +}; + +/** + * opTLOA(665000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLOA = function(opCode) +{ +}; + +/** + * opTRON(666000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTRON = function(opCode) +{ +}; + +/** + * opTLON(667000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTLON = function(opCode) +{ +}; + +/** + * opTDO(670000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDO = function(opCode) +{ +}; + +/** + * opTSO(671000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSO = function(opCode) +{ +}; + +/** + * opTDOE(672000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDOE = function(opCode) +{ +}; + +/** + * opTSOE(673000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSOE = function(opCode) +{ +}; + +/** + * opTDOA(674000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDOA = function(opCode) +{ +}; + +/** + * opTSOA(675000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSOA = function(opCode) +{ +}; + +/** + * opTDON(676000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTDON = function(opCode) +{ +}; + +/** + * opTSON(677000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opTSON = function(opCode) +{ +}; + +/** + * opBLKI(700000 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opBLKI = function(opCode) +{ +}; + +/** + * opDATAI(700040 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDATAI = function(opCode) +{ +}; + +/** + * opBLKO(700100 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opBLKO = function(opCode) +{ +}; + +/** + * opDATAO(700140 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opDATAO = function(opCode) +{ +}; + +/** + * opCONO(700200 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCONO = function(opCode) +{ +}; + +/** + * opCONI(700240 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCONI = function(opCode) +{ +}; + +/** + * opCONSZ(700300 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCONSZ = function(opCode) +{ +}; + +/** + * opCONSO(700340 000000) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opCONSO = function(opCode) +{ +}; diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index c4d2ba277..aba9f472a 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -1365,23 +1365,16 @@ class DebuggerPDP10 extends Debugger { } /** - * getInstruction(dbgAddr, sComment, nSequence) - * - * Get the next instruction, by decoding the opcode and any operands. + * findInstruction(opCode, fOperands) * * @this {DebuggerPDP10} - * @param {DbgAddrPDP10} dbgAddr - * @param {string} [sComment] is an associated comment - * @param {number|null} [nSequence] is an associated sequence number, undefined if none - * @return {string} (and dbgAddr is updated to the next instruction) + * @param {number} opCode + * @param {boolean} [fOperands] (optional; default is true) + * @return {string} */ - getInstruction(dbgAddr, sComment, nSequence) + findInstruction(opCode, fOperands = true) { - var opNames = DebuggerPDP10.OPNAMES; - var dbgAddrOp = this.newAddr(dbgAddr.addr); - var opNum, opMask, aModes, iMode = 0; - var opCode = this.getWord(dbgAddr, 1); var op = (opCode / PDP10.OPCODE.OPSHIFT)|0; for (var mask in DebuggerPDP10.OPTABLE) { @@ -1392,7 +1385,7 @@ class DebuggerPDP10 extends Debugger { /* * When we extracted op from opCode using OPSHIFT, we included 6 additional bits * to help distinguish OPIO instructions from non-OPIO instructions. But for the - * following tests, we don't need those bits, so we get rid of them now. + * following tests, we don't need those bits, so we get rid of them now. */ op >>= 6; switch(opMask) { @@ -1413,25 +1406,48 @@ class DebuggerPDP10 extends Debugger { } } - var sOperands = ""; var sMode = aModes && aModes[iMode] || ""; if (sMode == "S" && opNum > DebuggerPDP10.OPS.MOVM) sMode = "B"; + var sOperation = DebuggerPDP10.OPNAMES[opNum || 0] + sMode; - var sOpName = opNames[opNum] + sMode; - if (!opNum) { - sOperands = this.toStrWord(opCode); + if (!fOperands) { + if (!opNum) sOperation = ""; } else { - if (opMask == PDP10.OPCODE.OPIO) { - sOperands = this.toStrBase((opCode / PDP10.OPCODE.IOSHIFT) & PDP10.OPCODE.IOMASK, -1); + sOperation = Str.pad(sOperation, 8); + if (!opNum) { + sOperation += this.toStrWord(opCode); } else { - sOperands = this.toStrBase((opCode >> PDP10.OPCODE.FNSHIFT) & PDP10.OPCODE.FNMASK, -1); + if (opMask == PDP10.OPCODE.OPIO) { + sOperation += this.toStrBase((opCode / PDP10.OPCODE.IOSHIFT) & PDP10.OPCODE.IOMASK, -1); + } else { + sOperation += this.toStrBase((opCode >> PDP10.OPCODE.FNSHIFT) & PDP10.OPCODE.FNMASK, -1); + } + sOperation += ','; + if (opCode & PDP10.OPCODE.I_BIT) sOperation += '@'; + sOperation += this.toStrBase(opCode & PDP10.OPCODE.Y_MASK, -1); + var i = (opCode >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; + if (i) sOperation += '(' + this.toStrBase(i, -1) + ')'; } - if (sOperands) sOperands += ','; - if (opCode & PDP10.OPCODE.I_BIT) sOperands += '@'; - sOperands += this.toStrBase(opCode & PDP10.OPCODE.Y_MASK, -1); - var i = (opCode >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; - if (i) sOperands += '(' + this.toStrBase(i, -1) + ')'; } + return sOperation; + } + + /** + * getInstruction(dbgAddr, sComment, nSequence) + * + * Get the next instruction, by decoding the opcode and any operands. + * + * @this {DebuggerPDP10} + * @param {DbgAddrPDP10} dbgAddr + * @param {string} [sComment] is an associated comment + * @param {number|null} [nSequence] is an associated sequence number, undefined if none + * @return {string} (and dbgAddr is updated to the next instruction) + */ + getInstruction(dbgAddr, sComment, nSequence) + { + var dbgAddrOp = this.newAddr(dbgAddr.addr); + var opCode = this.getWord(dbgAddr, 1); + var sOperation = this.findInstruction(opCode); var sOpCodes = ""; var sLine = this.toStrAddr(dbgAddrOp) + ":"; @@ -1443,9 +1459,7 @@ class DebuggerPDP10 extends Debugger { } while (dbgAddrOp.addr != dbgAddr.addr); } - sLine += Str.pad(sOpCodes, 16); - sLine += Str.pad(sOpName, 5); - if (sOperands) sLine += ' ' + sOperands; + sLine += Str.pad(sOpCodes, 16) + sOperation; if (sComment) { sLine = Str.pad(sLine, 60) + ';' + (sComment || ""); @@ -3268,6 +3282,10 @@ class DebuggerPDP10 extends Debugger { var result = true; try { + if (DEBUG && sCmd == "test") { + this.doTest(); + return true; + } if (!sCmd.length || sCmd == "end") { if (this.fAssemble) { this.println("ended assemble at " + this.toStrAddr(this.dbgAddrAssemble)); @@ -3435,6 +3453,40 @@ class DebuggerPDP10 extends Debugger { return true; } + /** + * doTest() + * + * @this {DebuggerPDP10} + */ + doTest() + { + var aOps = {}; + var sOperation; + for (var op = 0o00000; op <= 0o77774; op += 4) { + var opCode = op * Math.pow(2, 21); + sOperation = this.findInstruction(opCode, false); + if (!sOperation) continue; + if (aOps[sOperation] === undefined) { + aOps[sOperation] = op; + } else { + aOps[sOperation] &= op; + } + } + for (sOperation in aOps) { + if (sOperation == null) continue; + this.println(sOperation + ": " + this.toStrWord(aOps[sOperation] * Math.pow(2, 21))); + // this.println("/**"); + // this.println(" * op" + sOperation + "(" + this.toStrWord(aOps[sOperation] * Math.pow(2, 21)) + ")"); + // this.println(" *"); + // this.println(" * @this {CPUStatePDP10}"); + // this.println(" * @param {number} opCode"); + // this.println(" */"); + // this.println("PDP10.op" + sOperation + " = function(opCode)"); + // this.println("{"); + // this.println("};\n"); + } + } + /** * DebuggerPDP10.init() * @@ -3579,7 +3631,7 @@ if (DEBUGGER) { * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y * - * where OOOOOOOMM represents the operation, with MM (if used) represents the mode: + * where OOOOOOOMM represents the operation, and MM (if used) represents the mode: * * Mode Suffix Source Destination * ---- ------ ----- ----------- @@ -3600,7 +3652,7 @@ if (DEBUGGER) { * we're done; otherwise, we must set set R to [E] and repeat the process. */ DebuggerPDP10.OPTABLE = { - [PDP10.OPCODE.OPMASK]: { + [PDP10.OPCODE.OPMASK]: { // 0o77700 0o13000: DebuggerPDP10.OPS.UFA, 0o13100: DebuggerPDP10.OPS.DFN, 0o13200: DebuggerPDP10.OPS.FSC, @@ -3632,7 +3684,7 @@ if (DEBUGGER) { 0o26600: DebuggerPDP10.OPS.JSA, 0o26700: DebuggerPDP10.OPS.JRA, }, - [PDP10.OPCODE.OPMODE]: { + [PDP10.OPCODE.OPMODE]: { // 0o77400 0o14000: DebuggerPDP10.OPS.FAD, 0o14400: DebuggerPDP10.OPS.FADR, 0o15000: DebuggerPDP10.OPS.FSB, @@ -3684,7 +3736,7 @@ if (DEBUGGER) { 0o57000: DebuggerPDP10.OPS.HRRE, 0o57400: DebuggerPDP10.OPS.HLRE }, - [PDP10.OPCODE.OPCOMP]: { + [PDP10.OPCODE.OPCOMP]: { // 0o77000 0o30000: DebuggerPDP10.OPS.CAI, 0o31000: DebuggerPDP10.OPS.CA, 0o32000: DebuggerPDP10.OPS.JUMP, @@ -3694,13 +3746,13 @@ if (DEBUGGER) { 0o36000: DebuggerPDP10.OPS.SOJ, 0o37000: DebuggerPDP10.OPS.SOS, }, - [PDP10.OPCODE.OPTEST]: { + [PDP10.OPCODE.OPTEST]: { // 0o71100 0o60000: DebuggerPDP10.OPS.TR, 0o60100: DebuggerPDP10.OPS.TL, 0o61000: DebuggerPDP10.OPS.TD, 0o61100: DebuggerPDP10.OPS.TS, }, - [PDP10.OPCODE.OPIO]: { + [PDP10.OPCODE.OPIO]: { // 0o70034 0o70000: DebuggerPDP10.OPS.BLKI, 0o70004: DebuggerPDP10.OPS.DATAI, 0o70010: DebuggerPDP10.OPS.BLKO, @@ -3710,7 +3762,7 @@ if (DEBUGGER) { 0o70030: DebuggerPDP10.OPS.CONSZ, 0o70034: DebuggerPDP10.OPS.CONSO }, - [PDP10.OPCODE.OPUUO]: { + [PDP10.OPCODE.OPUUO]: { // 0o70000 0o00000: DebuggerPDP10.OPS.UUO } }; diff --git a/package.json b/package.json index bb05a9ad1..3ee29dc80 100644 --- a/package.json +++ b/package.json @@ -194,6 +194,7 @@ "./modules/pdp10/lib/memory.js", "./modules/pdp10/lib/cpu.js", "./modules/pdp10/lib/cpustate.js", + "./modules/pdp10/lib/cpuops.js", "./modules/pdp10/lib/rom.js", "./modules/pdp10/lib/ram.js", "./modules/pdp10/lib/serial.js", diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index ef0b7bab3..2e508274a 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -23,6 +23,7 @@ http://pcjs.org/modules/pdp10/lib/memory.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/cpu.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/cpustate.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpuops.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/serial.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 @@ -36,9 +37,9 @@ Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^": function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.i={ready:!1,Da:!1,Qa:!1,T:!1,error:!1};this.Ma=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} +function Pa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} function H(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function J(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=f.load;d.ha=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.data)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else d.W=f;d.S=f.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function J(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, @@ -71,17 +72,17 @@ l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d, function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),ac(a,0,null),Na(a,!1);else try{var b=this.b.Ia(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.g["S"+b][1]=a.u&1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.j;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>g&&(m=g);h.Ga=e-h.v+m;e=k+16384;g-=m;f++;continue}}return lc(mc,e,g)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} -function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;dd.length){for(var e=0,f=Array(4096),g=0;g>>a.j;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return lc(mc,e,f)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} +function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ha(b,a&16383,a)}; l.Ia=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Pa?-1:0:0,c=a?this.i.Pa?0:1:-1;this.i.Pa=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.pa=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>g.j;0>>= -g.j;0>>f.j;0>>= +f.j;0>>a.j;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,Aa=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(Aa)for(G(a,"loading "+I(Aa)+" bytes at "+I(q)+"-"+I(q+Aa),4096);Aa--;)fc(a.C,q++,b[K++]);else q&1?f=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h>>a.j;0g&&g>=sa&&(g+=ra);g=Math.trunc(Math.abs(g))%ra;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,Aa=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= +b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(Aa)for(G(a,"loading "+I(Aa)+" bytes at "+I(q)+"-"+I(q+Aa),4096);Aa--;)fc(a.C,q++,b[K++]);else q&1?g=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ta&&c<=t.ob&&(b=c-(t.Ta-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; -l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var g=e.connect;g&&g.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} -function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; -case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ea.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ya(b.substring(c,f))),c=f+1}}return a} +function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;f=p+f;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Ad(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var f=4,g="";if(!f||4>=1,K--;g=p+g;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} var zd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; function Cd(a){td.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Ed(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Fd(this,a.messages);this.ra=a.commands;this.L=0;this.Ba=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]=function(a){return Yc(b, @@ -131,76 +132,76 @@ l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Tc(a,"messages" I(n.size)+" "+m),c!=Hc&&(c=-1),m=0);a+=16384;e++}}});E(this)}; l.da=function(a,b,c){var d=this;switch(b){case "debugInput":return this.aa=this.F[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",Yc(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.wd&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.b.pa==b)){b=a.b;var e=b.g;b.g=(e+1)%Gb;b=e}if(0d&&(d=a.b.ta(b)),0<=d&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function ve(a,b,c,d){var e=X(b.v),g,f,h,k=0,m=a.wa(b,1),n=m/Ib|0,p;for(p in we)if(g=we[p][n&p]){f=+p;n>>=6;switch(f){case 32512:h=xe;k=n&3;break;case 32256:h=ye;k=n&7;break;case 29248:h=ze,k=(n&48)>>2|(n&6)>>1}break}h=h&&h[k]||"";"S"==h&&g>Ae&&(h="B");h=Be[g]+h;g?((g=28700==f?W(a,m/Jb&127,-1):W(a,m>>23&15,-1))&&(g+=","),m&4194304&&(g+="@"),g+=W(a,m&262143,-1),(m=m>>18&15)&&(g+="("+W(a,m,-1)+")")):g=Kd(m);m="";f=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),m+=" "+Kd(k),null==e.v)break;while(e.v!= -b.v)}f+=Xa(m,16);f+=Xa(h,5);g&&(f+=" "+g);c&&(f=Xa(f,60)+";"+(c||""),f=a.b.i.Ca?f+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):f+(null!=d?"="+d.toString():""));return f}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} -l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var g=this.C;g.g[e>>>g.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.j],b==a.G));h.ka||Ed(a);break}}return g} +function ve(a,b,c,d){var e=X(b.v),f=a.wa(b,1),g,h,k,m=0,n=f/Ib|0,p;for(p in we)if(g=we[p][n&p]){h=+p;n>>=6;switch(h){case 32512:k=xe;m=n&3;break;case 32256:k=ye;m=n&7;break;case 29248:k=ze,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ae&&(k="B");k=Be[g||0]+k;k=Xa(k,8);g?(k=28700==h?k+W(a,f/Jb&127,-1):k+W(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=W(a,f&262143,-1),(f=f>>18&15)&&(k+="("+W(a,f,-1)+")")):k+=Kd(f);f=k;g="";h=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),g+=" "+Kd(k),null== +e.v)break;while(e.v!=b.v)}h+=Xa(g,16)+f;c&&(h=Xa(h,60)+";"+(c||""),h=a.b.i.Ca?h+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):h+(null!=d?"="+d.toString():""));return h}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} +l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var f=this.C;f.g[e>>>f.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.j],b==a.G));h.ka||Ed(a);break}}return f} function Ee(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:g})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.tb;if(e>=f&&eb[0]?1:a[0]>>0,g],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:f})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.tb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=ve(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} -function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=ve(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} +function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Yd&&(Za=1E5,tc=["CALL"]);for(void 0!==Xd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;$d++;Za--}}$d||(a.f("no "+Zd+"history available"), a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ce="ds"==Ea;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||of,la=yd(a,ca);else{var de=Z(a,ca);de&&(la=de.v-ka.v)}0>la&&(la=0);65536he;he++)fe+=String.fromCharCode((Bb%64|0)+32), -Bb/=64}ma&&(ma+="\n");ma=ce?ma+(na+","):ma+(R+": "+na+(0>ge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==f[0])break;var ie,je,ke=f[0],wc=f[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;Dbge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==g[0])break;var ie,je,ke=g[0],wc=g[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;DbAc;){for(var oa=null,uf=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!uf--)break;if(!(Bc.v&1)){for(var vf=a,Eb=Bc,me=null,cb=Eb.v,ne=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;b\nLicense: GPL version 3 or later ");for(b=0;bSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Te(d,f):("error"==g&&"no machine state"!= -f?(this.Y("Error: "+f),"unable to verify user"==f&&(mb(gf,""),this.j=null)):this.f(g+": "+f),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(g=0;gSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Te(d,g):("error"==f&&"no machine state"!= +g?(this.Y("Error: "+g),"unable to verify user"==g&&(mb(gf,""),this.j=null)):this.f(f+": "+g),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(hf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(cf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; function cf(a,b){if(wa("There may be a problem with your "+Ab+" machine.\n\nTo help us diagnose it, click OK to send this "+Ab+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Ab;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function Me(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new O(a,"1.34.0"),f=new O(a,"1.34.0",Xe),h=hb();f.set(Ze,h);g.set(Ze,h);g.set(jf,"1.34.0");g.set(kf,window?window.location.href:null);g.set(lf,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&g.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],f);Gf(a,b,c)}})}else c(a,null)} -function Hf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| -wb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,g,n):Ff(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(K){f(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;ng.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Gf(a,b,c)}})}else c(a,null)} +function Hf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function g(a){f("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| +wb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,f,n):Ff(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(K){g(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;n Date: Sat, 25 Feb 2017 16:21:21 -0800 Subject: [PATCH 11/30] Added preliminary first-order opcode dispatch table --- modules/pdp10/lib/cpuops.js | 637 ++++++++++++++++++++++++++++- modules/pdp10/lib/debugger.js | 43 +- modules/pdp10/lib/defines.js | 3 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 4 +- 4 files changed, 665 insertions(+), 22 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index 0a58ea825..cd815f4ff 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -33,7 +33,26 @@ if (NODE) { } /** - * opUUO(000000 000000) + * opUUO(0xx000 000000): Unimplemented User Operation + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-64: + * + * Store the instruction code, A and the effective address E in bits 0-8, 9-12 and 18-35 respectively of + * location 40; clear bits 13-17. Execute the instruction contained in location 41. The original contents + * of location 40 are lost. + * + * All of these codes are equivalent when they occur in the Monitor or when time sharing is not in effect. + * But when a UUO appears in a user program, a code in the range 001-037 uses relocated locations 40 and 41 + * (ie 40 and 41 in the user's block) and is thus entirely a part of and under control of the user program. + * + * A code in the range 040-077 on the other hand uses unrelocated 40 and 41, and the instruction in the latter + * location is under control of the Monitor; these codes are thus specifically for user communication with + * the Monitor, which interprets them (refer to the Monitor manual for the meanings of the various codes). + * + * The code 000 executes in the same way as 040-077 but is not a standard communication code: it is included + * so that control returns to the Monitor should a user program wipe itself out. + * + * For a second processor connected to the same memory, the UUO trap is locations 140-141 instead of 40-41. * * @this {CPUStatePDP10} * @param {number} opCode @@ -43,7 +62,22 @@ PDP10.opUUO = function(opCode) }; /** - * opUFA(130000 000000) + * opUFA(130000 000000): Unnormalized Floating Add + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: + * + * Floating add the contents of location E to AC. If the double length fraction in the sum is zero, clear + * accumulator A+1. Otherwise normalize the sum only if the magnitude of its fractional part is >= 1, and place + * the high order part of the result in AC A+1. The original contents of AC and E are unaffected. + * + * NOTE: The result is placed in accumulator A+1. T his is the only arithmetic instruction that stores the result + * in a second accumulator, leaving the original operands intact. + * + * If the exponent of the sum following the one-step normalization is > 127, set Overflow and Floating Overflow; + * the result stored has an exponent 256 less than the correct one. + * + * SIDEBAR: The exponent of the sum is equal to that of the larger summand unless addition of the fractions + * overflows, in which case it is greater by 1. Exponent overflow can occur only in the latter case. * * @this {CPUStatePDP10} * @param {number} opCode @@ -53,7 +87,15 @@ PDP10.opUFA = function(opCode) }; /** - * opDFN(131000 000000) + * opDFN(131000 000000): Double Floating Negate + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: + * + * Negate the double length floating point number composed of the contents of AC and location E with AC on the left. + * Do this by taking the twos complement of the number whose sign is AC bit 0, whose exponent is in AC bits 1-8, and + * whose fraction is the 54-bit string in bits 9-35 of AC and location E. Place the high order word of the result + * in AC; place the low order part of the fraction in bits 9-35 of location E without altering the original contents + * of bits 0-8 of that location. * * @this {CPUStatePDP10} * @param {number} opCode @@ -63,7 +105,28 @@ PDP10.opDFN = function(opCode) }; /** - * opFSC(132000 000000) + * opFSC(132000 000000): Floating Scale + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-34: + * + * If the fractional part of AC is zero, clear AC. Otherwise add the scale factor given by E to the exponent part + * of AC (thus multiplying AC by 2^E), normalize the resulting word bringing 0s into bit positions vacated at the + * right, and place the result back in AC. + * + * NOTE: A negative E is represented in standard twos complement notation, but the hardware compensates for this + * when scaling the exponent. + * + * If the exponent after normalization is > 127, set Overflow and Floating Overflow; the result stored has an + * exponent 256 less than the correct one. If < -128, set Overflow, Floating Overflow and Floating Underflow; + * the result stored has an exponent 256 greater than the correct one. + * + * SIDEBAR: This instruction can be used to float a fixed number with 27 or fewer significant bits. To float an + * integer contained within AC bits 9-35, + * + * FSC AC,233 + * + * inserts the correct exponent to move the binary point from the right end to the left of bit 9 and then normalizes + * (233(base 8) = 155(base 10) = 128 + 27). * * @this {CPUStatePDP10} * @param {number} opCode @@ -73,7 +136,23 @@ PDP10.opFSC = function(opCode) }; /** - * opIBP(133000 000000) + * opIBP(133000 000000): Increment Byte Pointer + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-16: + * + * Increment the byte pointer in location E as explained above. + * + * FROM ABOVE: To facilitate processing a series of bytes, several of the byte instructions increment the pointer, + * ie, modify it so that it points to the next byte position in a set of memory locations. Bytes are processed from + * left to right in a word, so incrementing merely replaces the current value of P by P - S, unless there is + * insufficient space in the present location for another byte of the specified size (P - S < 0). In this case Y is + * increased by one to point to the next consecutive location, and P is set to 36 - S to point to the first byte at + * the left in the new location. + * + * CAUTION: Do not allow Y to reach maximum value. The whole pointer is incremented, so if Y is 2^18 - 1 it becomes + * zero and X is also incremented. The address calculation for the pointer uses the original X, but if a priority + * interrupt should occur before the calculation is complete, the incremented X is used when the instruction is + * repeated. * * @this {CPUStatePDP10} * @param {number} opCode @@ -3681,3 +3760,551 @@ PDP10.opCONSZ = function(opCode) PDP10.opCONSO = function(opCode) { }; + +/** + * opIO(opCode) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opIO = function(opCode) +{ + PDP10.opUndefined.call(this, opCode); +}; + +/** + * opUndefined() + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opUndefined = function(opCode) +{ +}; + +/** + * opKA10(opCode) + * + * @this {CPUStatePDP10} + * @param {number} opCode + */ +PDP10.opKA10 = function(opCode) +{ + var op = (opCode / PDP10.OPCODE.SHIFT)|0; + PDP10.aOpXXX_KA10[op].call(this, opCode); +}; + +PDP10.aOpXXX_KA10 = [ + PDP10.opUUO, // 0o000xxx yyyyyy + PDP10.opUUO, // 0o001xxx yyyyyy + PDP10.opUUO, // 0o002xxx yyyyyy + PDP10.opUUO, // 0o003xxx yyyyyy + PDP10.opUUO, // 0o004xxx yyyyyy + PDP10.opUUO, // 0o005xxx yyyyyy + PDP10.opUUO, // 0o006xxx yyyyyy + PDP10.opUUO, // 0o007xxx yyyyyy + PDP10.opUUO, // 0o010xxx yyyyyy + PDP10.opUUO, // 0o011xxx yyyyyy + PDP10.opUUO, // 0o012xxx yyyyyy + PDP10.opUUO, // 0o013xxx yyyyyy + PDP10.opUUO, // 0o014xxx yyyyyy + PDP10.opUUO, // 0o015xxx yyyyyy + PDP10.opUUO, // 0o016xxx yyyyyy + PDP10.opUUO, // 0o017xxx yyyyyy + PDP10.opUUO, // 0o020xxx yyyyyy + PDP10.opUUO, // 0o021xxx yyyyyy + PDP10.opUUO, // 0o022xxx yyyyyy + PDP10.opUUO, // 0o023xxx yyyyyy + PDP10.opUUO, // 0o024xxx yyyyyy + PDP10.opUUO, // 0o025xxx yyyyyy + PDP10.opUUO, // 0o026xxx yyyyyy + PDP10.opUUO, // 0o027xxx yyyyyy + PDP10.opUUO, // 0o030xxx yyyyyy + PDP10.opUUO, // 0o031xxx yyyyyy + PDP10.opUUO, // 0o032xxx yyyyyy + PDP10.opUUO, // 0o033xxx yyyyyy + PDP10.opUUO, // 0o034xxx yyyyyy + PDP10.opUUO, // 0o035xxx yyyyyy + PDP10.opUUO, // 0o036xxx yyyyyy + PDP10.opUUO, // 0o037xxx yyyyyy + PDP10.opUUO, // 0o040xxx yyyyyy + PDP10.opUUO, // 0o041xxx yyyyyy + PDP10.opUUO, // 0o042xxx yyyyyy + PDP10.opUUO, // 0o043xxx yyyyyy + PDP10.opUUO, // 0o044xxx yyyyyy + PDP10.opUUO, // 0o045xxx yyyyyy + PDP10.opUUO, // 0o046xxx yyyyyy + PDP10.opUUO, // 0o047xxx yyyyyy + PDP10.opUUO, // 0o050xxx yyyyyy + PDP10.opUUO, // 0o051xxx yyyyyy + PDP10.opUUO, // 0o052xxx yyyyyy + PDP10.opUUO, // 0o053xxx yyyyyy + PDP10.opUUO, // 0o054xxx yyyyyy + PDP10.opUUO, // 0o055xxx yyyyyy + PDP10.opUUO, // 0o056xxx yyyyyy + PDP10.opUUO, // 0o057xxx yyyyyy + PDP10.opUUO, // 0o060xxx yyyyyy + PDP10.opUUO, // 0o061xxx yyyyyy + PDP10.opUUO, // 0o062xxx yyyyyy + PDP10.opUUO, // 0o063xxx yyyyyy + PDP10.opUUO, // 0o064xxx yyyyyy + PDP10.opUUO, // 0o065xxx yyyyyy + PDP10.opUUO, // 0o066xxx yyyyyy + PDP10.opUUO, // 0o067xxx yyyyyy + PDP10.opUUO, // 0o070xxx yyyyyy + PDP10.opUUO, // 0o071xxx yyyyyy + PDP10.opUUO, // 0o072xxx yyyyyy + PDP10.opUUO, // 0o073xxx yyyyyy + PDP10.opUUO, // 0o074xxx yyyyyy + PDP10.opUUO, // 0o075xxx yyyyyy + PDP10.opUUO, // 0o076xxx yyyyyy + PDP10.opUUO, // 0o077xxx yyyyyy + PDP10.opUndefined, // 0o100xxx yyyyyy + PDP10.opUndefined, // 0o101xxx yyyyyy + PDP10.opUndefined, // 0o102xxx yyyyyy + PDP10.opUndefined, // 0o103xxx yyyyyy + PDP10.opUndefined, // 0o104xxx yyyyyy + PDP10.opUndefined, // 0o105xxx yyyyyy + PDP10.opUndefined, // 0o106xxx yyyyyy + PDP10.opUndefined, // 0o107xxx yyyyyy + PDP10.opUndefined, // 0o110xxx yyyyyy + PDP10.opUndefined, // 0o111xxx yyyyyy + PDP10.opUndefined, // 0o112xxx yyyyyy + PDP10.opUndefined, // 0o113xxx yyyyyy + PDP10.opUndefined, // 0o114xxx yyyyyy + PDP10.opUndefined, // 0o115xxx yyyyyy + PDP10.opUndefined, // 0o116xxx yyyyyy + PDP10.opUndefined, // 0o117xxx yyyyyy + PDP10.opUndefined, // 0o120xxx yyyyyy + PDP10.opUndefined, // 0o121xxx yyyyyy + PDP10.opUndefined, // 0o122xxx yyyyyy + PDP10.opUndefined, // 0o123xxx yyyyyy + PDP10.opUndefined, // 0o124xxx yyyyyy + PDP10.opUndefined, // 0o125xxx yyyyyy + PDP10.opUndefined, // 0o126xxx yyyyyy + PDP10.opUndefined, // 0o127xxx yyyyyy + PDP10.opUFA, // 0o130xxx yyyyyy + PDP10.opDFN, // 0o131xxx yyyyyy + PDP10.opFSC, // 0o132xxx yyyyyy + PDP10.opIBP, // 0o133xxx yyyyyy + PDP10.opILDB, // 0o134xxx yyyyyy + PDP10.opLDB, // 0o135xxx yyyyyy + PDP10.opIDPB, // 0o136xxx yyyyyy + PDP10.opDPB, // 0o137xxx yyyyyy + PDP10.opFAD, // 0o140xxx yyyyyy + PDP10.opFADI, // 0o141xxx yyyyyy + PDP10.opFADM, // 0o142xxx yyyyyy + PDP10.opFADB, // 0o143xxx yyyyyy + PDP10.opFADR, // 0o144xxx yyyyyy + PDP10.opFADRI, // 0o145xxx yyyyyy + PDP10.opFADRM, // 0o146xxx yyyyyy + PDP10.opFADRB, // 0o147xxx yyyyyy + PDP10.opFSB, // 0o150xxx yyyyyy + PDP10.opFSBI, // 0o151xxx yyyyyy + PDP10.opFSBM, // 0o152xxx yyyyyy + PDP10.opFSBB, // 0o153xxx yyyyyy + PDP10.opFSBR, // 0o154xxx yyyyyy + PDP10.opFSBRI, // 0o155xxx yyyyyy + PDP10.opFSBRM, // 0o156xxx yyyyyy + PDP10.opFSBRB, // 0o157xxx yyyyyy + PDP10.opFMP, // 0o160xxx yyyyyy + PDP10.opFMPI, // 0o161xxx yyyyyy + PDP10.opFMPM, // 0o162xxx yyyyyy + PDP10.opFMPB, // 0o163xxx yyyyyy + PDP10.opFMPR, // 0o164xxx yyyyyy + PDP10.opFMPRI, // 0o165xxx yyyyyy + PDP10.opFMPRM, // 0o166xxx yyyyyy + PDP10.opFMPRB, // 0o167xxx yyyyyy + PDP10.opFDV, // 0o170xxx yyyyyy + PDP10.opFDVI, // 0o171xxx yyyyyy + PDP10.opFDVM, // 0o172xxx yyyyyy + PDP10.opFDVB, // 0o173xxx yyyyyy + PDP10.opFDVR, // 0o174xxx yyyyyy + PDP10.opFDVRI, // 0o175xxx yyyyyy + PDP10.opFDVRM, // 0o176xxx yyyyyy + PDP10.opFDVRB, // 0o177xxx yyyyyy + PDP10.opMOV, // 0o200xxx yyyyyy + PDP10.opMOVI, // 0o201xxx yyyyyy + PDP10.opMOVM, // 0o202xxx yyyyyy + PDP10.opMOVS, // 0o203xxx yyyyyy + PDP10.opMOVS, // 0o204xxx yyyyyy + PDP10.opMOVSI, // 0o205xxx yyyyyy + PDP10.opMOVSM, // 0o206xxx yyyyyy + PDP10.opMOVSS, // 0o207xxx yyyyyy + PDP10.opMOVN, // 0o210xxx yyyyyy + PDP10.opMOVNI, // 0o211xxx yyyyyy + PDP10.opMOVNM, // 0o212xxx yyyyyy + PDP10.opMOVNS, // 0o213xxx yyyyyy + PDP10.opMOVM, // 0o214xxx yyyyyy + PDP10.opMOVMI, // 0o215xxx yyyyyy + PDP10.opMOVMM, // 0o216xxx yyyyyy + PDP10.opMOVMS, // 0o217xxx yyyyyy + PDP10.opIMUL, // 0o220xxx yyyyyy + PDP10.opIMULI, // 0o221xxx yyyyyy + PDP10.opIMULM, // 0o222xxx yyyyyy + PDP10.opIMULB, // 0o223xxx yyyyyy + PDP10.opMUL, // 0o224xxx yyyyyy + PDP10.opMULI, // 0o225xxx yyyyyy + PDP10.opMULM, // 0o226xxx yyyyyy + PDP10.opMULB, // 0o227xxx yyyyyy + PDP10.opIDIV, // 0o230xxx yyyyyy + PDP10.opIDIVI, // 0o231xxx yyyyyy + PDP10.opIDIVM, // 0o232xxx yyyyyy + PDP10.opIDIVB, // 0o233xxx yyyyyy + PDP10.opDIV, // 0o234xxx yyyyyy + PDP10.opDIVI, // 0o235xxx yyyyyy + PDP10.opDIVM, // 0o236xxx yyyyyy + PDP10.opDIVB, // 0o237xxx yyyyyy + PDP10.opASH, // 0o240xxx yyyyyy + PDP10.opROT, // 0o241xxx yyyyyy + PDP10.opLSH, // 0o242xxx yyyyyy + PDP10.opJFFO, // 0o243xxx yyyyyy + PDP10.opASHC, // 0o244xxx yyyyyy + PDP10.opROTC, // 0o245xxx yyyyyy + PDP10.opLSHC, // 0o246xxx yyyyyy + PDP10.opUndefined, // 0o247xxx yyyyyy + PDP10.opEXCH, // 0o250xxx yyyyyy + PDP10.opBLT, // 0o251xxx yyyyyy + PDP10.opAOBJP, // 0o252xxx yyyyyy + PDP10.opAOBJN, // 0o253xxx yyyyyy + PDP10.opJRST, // 0o254xxx yyyyyy + PDP10.opJFCL, // 0o255xxx yyyyyy + PDP10.opXCT, // 0o256xxx yyyyyy + PDP10.opUndefined, // 0o257xxx yyyyyy + PDP10.opPUSHJ, // 0o260xxx yyyyyy + PDP10.opPUSH, // 0o261xxx yyyyyy + PDP10.opPOP, // 0o262xxx yyyyyy + PDP10.opPOPJ, // 0o263xxx yyyyyy + PDP10.opJSR, // 0o264xxx yyyyyy + PDP10.opJSP, // 0o265xxx yyyyyy + PDP10.opJSA, // 0o266xxx yyyyyy + PDP10.opJRA, // 0o267xxx yyyyyy + PDP10.opADD, // 0o270xxx yyyyyy + PDP10.opADDI, // 0o271xxx yyyyyy + PDP10.opADDM, // 0o272xxx yyyyyy + PDP10.opADDB, // 0o273xxx yyyyyy + PDP10.opSUB, // 0o274xxx yyyyyy + PDP10.opSUBI, // 0o275xxx yyyyyy + PDP10.opSUBM, // 0o276xxx yyyyyy + PDP10.opSUBB, // 0o277xxx yyyyyy + PDP10.opCAI, // 0o300xxx yyyyyy + PDP10.opCAIL, // 0o301xxx yyyyyy + PDP10.opCAIE, // 0o302xxx yyyyyy + PDP10.opCAILE, // 0o303xxx yyyyyy + PDP10.opCAIA, // 0o304xxx yyyyyy + PDP10.opCAIGE, // 0o305xxx yyyyyy + PDP10.opCAIN, // 0o306xxx yyyyyy + PDP10.opCAIG, // 0o307xxx yyyyyy + PDP10.opCA, // 0o310xxx yyyyyy + PDP10.opCAL, // 0o311xxx yyyyyy + PDP10.opCAE, // 0o312xxx yyyyyy + PDP10.opCALE, // 0o313xxx yyyyyy + PDP10.opCAA, // 0o314xxx yyyyyy + PDP10.opCAGE, // 0o315xxx yyyyyy + PDP10.opCAN, // 0o316xxx yyyyyy + PDP10.opCAG, // 0o317xxx yyyyyy + PDP10.opJUMP, // 0o320xxx yyyyyy + PDP10.opJUMPL, // 0o321xxx yyyyyy + PDP10.opJUMPE, // 0o322xxx yyyyyy + PDP10.opJUMPLE, // 0o323xxx yyyyyy + PDP10.opJUMPA, // 0o324xxx yyyyyy + PDP10.opJUMPGE, // 0o325xxx yyyyyy + PDP10.opJUMPN, // 0o326xxx yyyyyy + PDP10.opJUMPG, // 0o327xxx yyyyyy + PDP10.opSKIP, // 0o330xxx yyyyyy + PDP10.opSKIPL, // 0o331xxx yyyyyy + PDP10.opSKIPE, // 0o332xxx yyyyyy + PDP10.opSKIPLE, // 0o333xxx yyyyyy + PDP10.opSKIPA, // 0o334xxx yyyyyy + PDP10.opSKIPGE, // 0o335xxx yyyyyy + PDP10.opSKIPN, // 0o336xxx yyyyyy + PDP10.opSKIPG, // 0o337xxx yyyyyy + PDP10.opAOJ, // 0o340xxx yyyyyy + PDP10.opAOJL, // 0o341xxx yyyyyy + PDP10.opAOJE, // 0o342xxx yyyyyy + PDP10.opAOJLE, // 0o343xxx yyyyyy + PDP10.opAOJA, // 0o344xxx yyyyyy + PDP10.opAOJGE, // 0o345xxx yyyyyy + PDP10.opAOJN, // 0o346xxx yyyyyy + PDP10.opAOJG, // 0o347xxx yyyyyy + PDP10.opAOS, // 0o350xxx yyyyyy + PDP10.opAOSL, // 0o351xxx yyyyyy + PDP10.opAOSE, // 0o352xxx yyyyyy + PDP10.opAOSLE, // 0o353xxx yyyyyy + PDP10.opAOSA, // 0o354xxx yyyyyy + PDP10.opAOSGE, // 0o355xxx yyyyyy + PDP10.opAOSN, // 0o356xxx yyyyyy + PDP10.opAOSG, // 0o357xxx yyyyyy + PDP10.opSOJ, // 0o360xxx yyyyyy + PDP10.opSOJL, // 0o361xxx yyyyyy + PDP10.opSOJE, // 0o362xxx yyyyyy + PDP10.opSOJLE, // 0o363xxx yyyyyy + PDP10.opSOJA, // 0o364xxx yyyyyy + PDP10.opSOJGE, // 0o365xxx yyyyyy + PDP10.opSOJN, // 0o366xxx yyyyyy + PDP10.opSOJG, // 0o367xxx yyyyyy + PDP10.opSOS, // 0o370xxx yyyyyy + PDP10.opSOSL, // 0o371xxx yyyyyy + PDP10.opSOSE, // 0o372xxx yyyyyy + PDP10.opSOSLE, // 0o373xxx yyyyyy + PDP10.opSOSA, // 0o374xxx yyyyyy + PDP10.opSOSGE, // 0o375xxx yyyyyy + PDP10.opSOSN, // 0o376xxx yyyyyy + PDP10.opSOSG, // 0o377xxx yyyyyy + PDP10.opSETZ, // 0o400xxx yyyyyy + PDP10.opSETZI, // 0o401xxx yyyyyy + PDP10.opSETZM, // 0o402xxx yyyyyy + PDP10.opSETZB, // 0o403xxx yyyyyy + PDP10.opAND, // 0o404xxx yyyyyy + PDP10.opANDI, // 0o405xxx yyyyyy + PDP10.opANDM, // 0o406xxx yyyyyy + PDP10.opANDB, // 0o407xxx yyyyyy + PDP10.opANDCA, // 0o410xxx yyyyyy + PDP10.opANDCAI, // 0o411xxx yyyyyy + PDP10.opANDCAM, // 0o412xxx yyyyyy + PDP10.opANDCAB, // 0o413xxx yyyyyy + PDP10.opSETM, // 0o414xxx yyyyyy + PDP10.opSETMI, // 0o415xxx yyyyyy + PDP10.opSETMM, // 0o416xxx yyyyyy + PDP10.opSETMB, // 0o417xxx yyyyyy + PDP10.opANDCM, // 0o420xxx yyyyyy + PDP10.opANDCMI, // 0o421xxx yyyyyy + PDP10.opANDCMM, // 0o422xxx yyyyyy + PDP10.opANDCMB, // 0o423xxx yyyyyy + PDP10.opSETA, // 0o424xxx yyyyyy + PDP10.opSETAI, // 0o425xxx yyyyyy + PDP10.opSETAM, // 0o426xxx yyyyyy + PDP10.opSETAB, // 0o427xxx yyyyyy + PDP10.opXOR, // 0o430xxx yyyyyy + PDP10.opXORI, // 0o431xxx yyyyyy + PDP10.opXORM, // 0o432xxx yyyyyy + PDP10.opXORB, // 0o433xxx yyyyyy + PDP10.opIOR, // 0o434xxx yyyyyy + PDP10.opIORI, // 0o435xxx yyyyyy + PDP10.opIORM, // 0o436xxx yyyyyy + PDP10.opIORB, // 0o437xxx yyyyyy + PDP10.opANDCB, // 0o440xxx yyyyyy + PDP10.opANDCBI, // 0o441xxx yyyyyy + PDP10.opANDCBM, // 0o442xxx yyyyyy + PDP10.opANDCBB, // 0o443xxx yyyyyy + PDP10.opEQV, // 0o444xxx yyyyyy + PDP10.opEQVI, // 0o445xxx yyyyyy + PDP10.opEQVM, // 0o446xxx yyyyyy + PDP10.opEQVB, // 0o447xxx yyyyyy + PDP10.opSETCA, // 0o450xxx yyyyyy + PDP10.opSETCAI, // 0o451xxx yyyyyy + PDP10.opSETCAM, // 0o452xxx yyyyyy + PDP10.opSETCAB, // 0o453xxx yyyyyy + PDP10.opORCA, // 0o454xxx yyyyyy + PDP10.opORCAI, // 0o455xxx yyyyyy + PDP10.opORCAM, // 0o456xxx yyyyyy + PDP10.opORCAB, // 0o457xxx yyyyyy + PDP10.opSETCM, // 0o460xxx yyyyyy + PDP10.opSETCMI, // 0o461xxx yyyyyy + PDP10.opSETCMM, // 0o462xxx yyyyyy + PDP10.opSETCMB, // 0o463xxx yyyyyy + PDP10.opORCM, // 0o464xxx yyyyyy + PDP10.opORCMI, // 0o465xxx yyyyyy + PDP10.opORCMM, // 0o466xxx yyyyyy + PDP10.opORCMB, // 0o467xxx yyyyyy + PDP10.opORCB, // 0o470xxx yyyyyy + PDP10.opORCBI, // 0o471xxx yyyyyy + PDP10.opORCBM, // 0o472xxx yyyyyy + PDP10.opORCBB, // 0o473xxx yyyyyy + PDP10.opSETO, // 0o474xxx yyyyyy + PDP10.opSETOI, // 0o475xxx yyyyyy + PDP10.opSETOM, // 0o476xxx yyyyyy + PDP10.opSETOB, // 0o477xxx yyyyyy + PDP10.opHLL, // 0o500xxx yyyyyy + PDP10.opHLLI, // 0o501xxx yyyyyy + PDP10.opHLLM, // 0o502xxx yyyyyy + PDP10.opHLLS, // 0o503xxx yyyyyy + PDP10.opHRL, // 0o504xxx yyyyyy + PDP10.opHRLI, // 0o505xxx yyyyyy + PDP10.opHRLM, // 0o506xxx yyyyyy + PDP10.opHRLS, // 0o507xxx yyyyyy + PDP10.opHLLZ, // 0o510xxx yyyyyy + PDP10.opHLLZI, // 0o511xxx yyyyyy + PDP10.opHLLZM, // 0o512xxx yyyyyy + PDP10.opHLLZS, // 0o513xxx yyyyyy + PDP10.opHRLZ, // 0o514xxx yyyyyy + PDP10.opHRLZI, // 0o515xxx yyyyyy + PDP10.opHRLZM, // 0o516xxx yyyyyy + PDP10.opHRLZS, // 0o517xxx yyyyyy + PDP10.opHLLO, // 0o520xxx yyyyyy + PDP10.opHLLOI, // 0o521xxx yyyyyy + PDP10.opHLLOM, // 0o522xxx yyyyyy + PDP10.opHLLOS, // 0o523xxx yyyyyy + PDP10.opHRLO, // 0o524xxx yyyyyy + PDP10.opHRLOI, // 0o525xxx yyyyyy + PDP10.opHRLOM, // 0o526xxx yyyyyy + PDP10.opHRLOS, // 0o527xxx yyyyyy + PDP10.opHLLE, // 0o530xxx yyyyyy + PDP10.opHLLEI, // 0o531xxx yyyyyy + PDP10.opHLLEM, // 0o532xxx yyyyyy + PDP10.opHLLES, // 0o533xxx yyyyyy + PDP10.opHRLE, // 0o534xxx yyyyyy + PDP10.opHRLEI, // 0o535xxx yyyyyy + PDP10.opHRLEM, // 0o536xxx yyyyyy + PDP10.opHRLES, // 0o537xxx yyyyyy + PDP10.opHRR, // 0o540xxx yyyyyy + PDP10.opHRRI, // 0o541xxx yyyyyy + PDP10.opHRRM, // 0o542xxx yyyyyy + PDP10.opHRRS, // 0o543xxx yyyyyy + PDP10.opHLR, // 0o544xxx yyyyyy + PDP10.opHLRI, // 0o545xxx yyyyyy + PDP10.opHLRM, // 0o546xxx yyyyyy + PDP10.opHLRS, // 0o547xxx yyyyyy + PDP10.opHRRZ, // 0o550xxx yyyyyy + PDP10.opHRRZI, // 0o551xxx yyyyyy + PDP10.opHRRZM, // 0o552xxx yyyyyy + PDP10.opHRRZS, // 0o553xxx yyyyyy + PDP10.opHLRZ, // 0o554xxx yyyyyy + PDP10.opHLRZI, // 0o555xxx yyyyyy + PDP10.opHLRZM, // 0o556xxx yyyyyy + PDP10.opHLRZS, // 0o557xxx yyyyyy + PDP10.opHRRO, // 0o560xxx yyyyyy + PDP10.opHRROI, // 0o561xxx yyyyyy + PDP10.opHRROM, // 0o562xxx yyyyyy + PDP10.opHRROS, // 0o563xxx yyyyyy + PDP10.opHLRO, // 0o564xxx yyyyyy + PDP10.opHLROI, // 0o565xxx yyyyyy + PDP10.opHLROM, // 0o566xxx yyyyyy + PDP10.opHLROS, // 0o567xxx yyyyyy + PDP10.opHRRE, // 0o570xxx yyyyyy + PDP10.opHRREI, // 0o571xxx yyyyyy + PDP10.opHRREM, // 0o572xxx yyyyyy + PDP10.opHRRES, // 0o573xxx yyyyyy + PDP10.opHLRE, // 0o574xxx yyyyyy + PDP10.opHLREI, // 0o575xxx yyyyyy + PDP10.opHLREM, // 0o576xxx yyyyyy + PDP10.opHLRES, // 0o577xxx yyyyyy + PDP10.opTRN, // 0o600xxx yyyyyy + PDP10.opTLN, // 0o601xxx yyyyyy + PDP10.opTRNE, // 0o602xxx yyyyyy + PDP10.opTLNE, // 0o603xxx yyyyyy + PDP10.opTRNA, // 0o604xxx yyyyyy + PDP10.opTLNA, // 0o605xxx yyyyyy + PDP10.opTRNN, // 0o606xxx yyyyyy + PDP10.opTLNN, // 0o607xxx yyyyyy + PDP10.opTDN, // 0o610xxx yyyyyy + PDP10.opTSN, // 0o611xxx yyyyyy + PDP10.opTDNE, // 0o612xxx yyyyyy + PDP10.opTSNE, // 0o613xxx yyyyyy + PDP10.opTDNA, // 0o614xxx yyyyyy + PDP10.opTSNA, // 0o615xxx yyyyyy + PDP10.opTDNN, // 0o616xxx yyyyyy + PDP10.opTSNN, // 0o617xxx yyyyyy + PDP10.opTRZ, // 0o620xxx yyyyyy + PDP10.opTLZ, // 0o621xxx yyyyyy + PDP10.opTRZE, // 0o622xxx yyyyyy + PDP10.opTLZE, // 0o623xxx yyyyyy + PDP10.opTRZA, // 0o624xxx yyyyyy + PDP10.opTLZA, // 0o625xxx yyyyyy + PDP10.opTRZN, // 0o626xxx yyyyyy + PDP10.opTLZN, // 0o627xxx yyyyyy + PDP10.opTDZ, // 0o630xxx yyyyyy + PDP10.opTSZ, // 0o631xxx yyyyyy + PDP10.opTDZE, // 0o632xxx yyyyyy + PDP10.opTSZE, // 0o633xxx yyyyyy + PDP10.opTDZA, // 0o634xxx yyyyyy + PDP10.opTSZA, // 0o635xxx yyyyyy + PDP10.opTDZN, // 0o636xxx yyyyyy + PDP10.opTSZN, // 0o637xxx yyyyyy + PDP10.opTRC, // 0o640xxx yyyyyy + PDP10.opTLC, // 0o641xxx yyyyyy + PDP10.opTRCE, // 0o642xxx yyyyyy + PDP10.opTLCE, // 0o643xxx yyyyyy + PDP10.opTRCA, // 0o644xxx yyyyyy + PDP10.opTLCA, // 0o645xxx yyyyyy + PDP10.opTRCN, // 0o646xxx yyyyyy + PDP10.opTLCN, // 0o647xxx yyyyyy + PDP10.opTDC, // 0o650xxx yyyyyy + PDP10.opTSC, // 0o651xxx yyyyyy + PDP10.opTDCE, // 0o652xxx yyyyyy + PDP10.opTSCE, // 0o653xxx yyyyyy + PDP10.opTDCA, // 0o654xxx yyyyyy + PDP10.opTSCA, // 0o655xxx yyyyyy + PDP10.opTDCN, // 0o656xxx yyyyyy + PDP10.opTSCN, // 0o657xxx yyyyyy + PDP10.opTRO, // 0o660xxx yyyyyy + PDP10.opTLO, // 0o661xxx yyyyyy + PDP10.opTROE, // 0o662xxx yyyyyy + PDP10.opTLOE, // 0o663xxx yyyyyy + PDP10.opTROA, // 0o664xxx yyyyyy + PDP10.opTLOA, // 0o665xxx yyyyyy + PDP10.opTRON, // 0o666xxx yyyyyy + PDP10.opTLON, // 0o667xxx yyyyyy + PDP10.opTDO, // 0o670xxx yyyyyy + PDP10.opTSO, // 0o671xxx yyyyyy + PDP10.opTDOE, // 0o672xxx yyyyyy + PDP10.opTSOE, // 0o673xxx yyyyyy + PDP10.opTDOA, // 0o674xxx yyyyyy + PDP10.opTSOA, // 0o675xxx yyyyyy + PDP10.opTDON, // 0o676xxx yyyyyy + PDP10.opTSON, // 0o677xxx yyyyyy + PDP10.opIO, // 0o700xxx yyyyyy + PDP10.opIO, // 0o701xxx yyyyyy + PDP10.opIO, // 0o702xxx yyyyyy + PDP10.opIO, // 0o703xxx yyyyyy + PDP10.opIO, // 0o704xxx yyyyyy + PDP10.opIO, // 0o705xxx yyyyyy + PDP10.opIO, // 0o706xxx yyyyyy + PDP10.opIO, // 0o707xxx yyyyyy + PDP10.opIO, // 0o710xxx yyyyyy + PDP10.opIO, // 0o711xxx yyyyyy + PDP10.opIO, // 0o712xxx yyyyyy + PDP10.opIO, // 0o713xxx yyyyyy + PDP10.opIO, // 0o714xxx yyyyyy + PDP10.opIO, // 0o715xxx yyyyyy + PDP10.opIO, // 0o716xxx yyyyyy + PDP10.opIO, // 0o717xxx yyyyyy + PDP10.opIO, // 0o720xxx yyyyyy + PDP10.opIO, // 0o721xxx yyyyyy + PDP10.opIO, // 0o722xxx yyyyyy + PDP10.opIO, // 0o723xxx yyyyyy + PDP10.opIO, // 0o724xxx yyyyyy + PDP10.opIO, // 0o725xxx yyyyyy + PDP10.opIO, // 0o726xxx yyyyyy + PDP10.opIO, // 0o727xxx yyyyyy + PDP10.opIO, // 0o730xxx yyyyyy + PDP10.opIO, // 0o731xxx yyyyyy + PDP10.opIO, // 0o732xxx yyyyyy + PDP10.opIO, // 0o733xxx yyyyyy + PDP10.opIO, // 0o734xxx yyyyyy + PDP10.opIO, // 0o735xxx yyyyyy + PDP10.opIO, // 0o736xxx yyyyyy + PDP10.opIO, // 0o737xxx yyyyyy + PDP10.opIO, // 0o740xxx yyyyyy + PDP10.opIO, // 0o741xxx yyyyyy + PDP10.opIO, // 0o742xxx yyyyyy + PDP10.opIO, // 0o743xxx yyyyyy + PDP10.opIO, // 0o744xxx yyyyyy + PDP10.opIO, // 0o745xxx yyyyyy + PDP10.opIO, // 0o746xxx yyyyyy + PDP10.opIO, // 0o747xxx yyyyyy + PDP10.opIO, // 0o750xxx yyyyyy + PDP10.opIO, // 0o751xxx yyyyyy + PDP10.opIO, // 0o752xxx yyyyyy + PDP10.opIO, // 0o753xxx yyyyyy + PDP10.opIO, // 0o754xxx yyyyyy + PDP10.opIO, // 0o755xxx yyyyyy + PDP10.opIO, // 0o756xxx yyyyyy + PDP10.opIO, // 0o757xxx yyyyyy + PDP10.opIO, // 0o760xxx yyyyyy + PDP10.opIO, // 0o761xxx yyyyyy + PDP10.opIO, // 0o762xxx yyyyyy + PDP10.opIO, // 0o763xxx yyyyyy + PDP10.opIO, // 0o764xxx yyyyyy + PDP10.opIO, // 0o765xxx yyyyyy + PDP10.opIO, // 0o766xxx yyyyyy + PDP10.opIO, // 0o767xxx yyyyyy + PDP10.opIO, // 0o770xxx yyyyyy + PDP10.opIO, // 0o771xxx yyyyyy + PDP10.opIO, // 0o772xxx yyyyyy + PDP10.opIO, // 0o773xxx yyyyyy + PDP10.opIO, // 0o774xxx yyyyyy + PDP10.opIO, // 0o775xxx yyyyyy + PDP10.opIO, // 0o776xxx yyyyyy + PDP10.opIO // 0o777xxx yyyyyy +]; diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index aba9f472a..6f472e9f9 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -3460,23 +3460,29 @@ class DebuggerPDP10 extends Debugger { */ doTest() { - var aOps = {}; - var sOperation; - for (var op = 0o00000; op <= 0o77774; op += 4) { - var opCode = op * Math.pow(2, 21); + var ops = {}, aOpXXX = []; + var op, opXXX, opCode, sOperation; + for (op = 0o00000; op <= 0o77774; op += 4) { + opCode = op * Math.pow(2, 21); sOperation = this.findInstruction(opCode, false); if (!sOperation) continue; - if (aOps[sOperation] === undefined) { - aOps[sOperation] = op; + if (ops[sOperation] === undefined) { + ops[sOperation] = op; } else { - aOps[sOperation] &= op; + ops[sOperation] &= op; + } + opXXX = op >> 6; + if (!aOpXXX[opXXX]) { + aOpXXX[opXXX] = sOperation; + } else if (aOpXXX[opXXX] != sOperation) { + aOpXXX[opXXX] = "XXX"; } } - for (sOperation in aOps) { - if (sOperation == null) continue; - this.println(sOperation + ": " + this.toStrWord(aOps[sOperation] * Math.pow(2, 21))); + for (sOperation in ops) { + op = ops[sOperation]; + this.println(sOperation + ": " + this.toStrWord(op * Math.pow(2, 21))); // this.println("/**"); - // this.println(" * op" + sOperation + "(" + this.toStrWord(aOps[sOperation] * Math.pow(2, 21)) + ")"); + // this.println(" * op" + sOperation + "(" + this.toStrWord(op * Math.pow(2, 21)) + ")"); // this.println(" *"); // this.println(" * @this {CPUStatePDP10}"); // this.println(" * @param {number} opCode"); @@ -3485,6 +3491,15 @@ class DebuggerPDP10 extends Debugger { // this.println("{"); // this.println("};\n"); } + // this.println("PDP10.aOpXXX = ["); + // for (opXXX = 0o000; opXXX <= 0o777; opXXX++) { + // sOperation = aOpXXX[opXXX]; + // sOperation = sOperation? (" PDP10.op" + sOperation + ",") : " PDP10.opUndefined,"; + // sOperation = Str.pad(sOperation, 32); + // sOperation += "// " + Str.toOct(opXXX, 3, true) + "xxx yyyyyy"; + // this.println(sOperation); + // } + // this.println("];"); } /** @@ -3652,6 +3667,9 @@ if (DEBUGGER) { * we're done; otherwise, we must set set R to [E] and repeat the process. */ DebuggerPDP10.OPTABLE = { + [PDP10.OPCODE.OPUUO]: { // 0o70000 + 0o00000: DebuggerPDP10.OPS.UUO + }, [PDP10.OPCODE.OPMASK]: { // 0o77700 0o13000: DebuggerPDP10.OPS.UFA, 0o13100: DebuggerPDP10.OPS.DFN, @@ -3761,9 +3779,6 @@ if (DEBUGGER) { 0o70024: DebuggerPDP10.OPS.CONI, 0o70030: DebuggerPDP10.OPS.CONSZ, 0o70034: DebuggerPDP10.OPS.CONSO - }, - [PDP10.OPCODE.OPUUO]: { // 0o70000 - 0o00000: DebuggerPDP10.OPS.UUO } }; diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index dfa55c8e0..b4d1121cb 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -108,13 +108,14 @@ var PDP10 = { OPMODE: 0o77400, // operation with mode OPCOMP: 0o77000, // operation with compare OPTEST: 0o71100, // operation with test - OPIO: 0o70034, // input-output instructions + OPIO: 0o70034, // input-output operation OPUUO: 0o70000, // unimplemented user operation (UUO) mask OPSHIFT: Math.pow(2, 21), // operation shift FNSHIFT: 23, // accumulator/function shift FNMASK: 0o17, // accumulator/function mask (after shift) IOSHIFT: Math.pow(2, 26), // input-output device code shift IOMASK: 0o177, // input-output device code mask (after shift) + SHIFT: Math.pow(2, 27), // operation code shift Y_MASK: 0o777777, X_SHIFT: 18, X_MASK: 0o17, diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 2e508274a..95499a139 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -170,8 +170,8 @@ a.ba);break;case "cs":var fb;void 0!==g[3]&&(fb=+g[3]);switch(g[2]){case "int":a a.f("\tbase #\t\tset default base to #"),a.f("\tcs int #\tset checksum cycle interval to #"),a.f("\tcs start #\tset checksum cycle start count to #"),a.f("\tcs stop #\tset checksum cycle stop count to #"),a.f("\tsp #\t\tset speed multiplier to #")}break;case "t":Le(a,g[0],g[1]);break;case "u":Sd(a,g[1],g[2],8);break;case "v":if("var"==g[0]){Ie(a,b.substr(3))||(d=!1);break}if("ver"==g[0]){a.f((Ab||"PDP10")+" version 1.34.0 ("+a.b.Za+",RELEASE)");a.f(window?window.navigator.userAgent:"");break}f=!0; break;case "?":if(g[1]){Ke(a,b.substr(1));break}var Dc="commands:",Ec;for(Ec in Ne)Dc+="\n"+Xa(Ec,9)+Ne[Ec];jd(a)||(Dc+="\nnote: history disabled if no exec breakpoints");a.f(Dc);break;default:f=!0}f&&(a.f("unknown command: "+b),d=!1)}}catch(ue){a.f("debugger error: "+(ue.stack||ue.message)),d=!1}return d}function Yc(a,b,c){b=ud(a,b,c);for(var d in b)if(!Fe(a,b[+d]))return!1;return!0} var Ne={"?":"help/print","a [#]":"assemble","b [#]":"breakpoint",c:"clear output","d [#]":"dump memory","e [#]":"edit memory","g [#]":"go [to #]",h:"halt","if":"eval expression","int [#]":"request interrupt",k:"stack trace",ln:"list nearest symbol(s)",m:"messages",p:"step over",print:"print expression",r:"dump/set registers",reset:"reset machine",s:"set options","t [#]":"trace","u [#]":"unassemble","var":"assign variable",ver:"print version"},Ae=20,Be=".WORD HLL HLLZ HLLO HLLE HRL HRLZ HRLO HRLE HRR HRRZ HRRO HRRE HLR HLRZ HLRO HLRE MOV MOVS MOVN MOVM EXCH BLT PUSH POP LDB DPB IBP ILDB IDPB SETZ SETO SETA SETCA SETM SETCM AND ANDCA ANDCM ANDCB IOR ORCA ORCM ORCB XOR EQV LSH LSHC ROT ROTC ADD SUB MUL IMUL DIV IDIV ASH ASHC FSC FADR FSBR FMPR FDVR DFN UFA FAD FSB FMP FDV AOBJP AOBJN CAI CA JUMP SKIP AOJ AOS SOJ SOS TR TL TD TS XCT JFFO JFCL JSR JSP JRST JSA JRA PUSHJ POPJ BLKI DATAI BLKO DATAO CONO CONI CONSZ CONSO UUO".split(" "), -Md=0,Ld=["PC"],Oe={},we=(Oe[32704]={5632:64,5696:63,5760:58,5824:27,5888:28,5952:25,6016:29,6080:26,10240:56,10304:48,10368:46,10432:84,10496:57,10560:49,10624:47,10752:21,10816:22,10880:69,10944:70,11008:88,11072:85,11136:83,11264:91,11328:23,11392:24,11456:92,11520:86,11584:87,11648:89,11712:90},Oe[32512]={6144:65,6400:59,6656:66,6912:60,7168:67,7424:61,7680:68,7936:62,8192:17,8448:18,8704:19,8960:Ae,9216:53,9472:52,9728:55,9984:54,11776:50,12032:51,16384:30,16640:36,16896:37,17152:34,17408:38, -17664:32,17920:44,18176:40,18432:39,18688:45,18944:33,19200:41,19456:35,19712:42,19968:43,20224:31,20480:1,20736:5,20992:2,21248:6,21504:3,21760:7,22016:4,22272:8,22528:9,22784:13,23040:10,23296:14,23552:11,23808:15,24064:12,24320:16},Oe[32256]={12288:71,12800:72,13312:73,13824:74,14336:75,14848:76,15360:77,15872:78},Oe[29248]={24576:79,24640:80,25088:81,25152:82},Oe[28700]={28672:93,28676:94,28680:95,28684:96,28688:97,28692:98,28696:99,28700:100},Oe[28672]={0:101},Oe),xe=["","I","M","S"],ye=" L E LE A GE N G".split(" "), +Md=0,Ld=["PC"],Oe={},we=(Oe[28672]={0:101},Oe[32704]={5632:64,5696:63,5760:58,5824:27,5888:28,5952:25,6016:29,6080:26,10240:56,10304:48,10368:46,10432:84,10496:57,10560:49,10624:47,10752:21,10816:22,10880:69,10944:70,11008:88,11072:85,11136:83,11264:91,11328:23,11392:24,11456:92,11520:86,11584:87,11648:89,11712:90},Oe[32512]={6144:65,6400:59,6656:66,6912:60,7168:67,7424:61,7680:68,7936:62,8192:17,8448:18,8704:19,8960:Ae,9216:53,9472:52,9728:55,9984:54,11776:50,12032:51,16384:30,16640:36,16896:37, +17152:34,17408:38,17664:32,17920:44,18176:40,18432:39,18688:45,18944:33,19200:41,19456:35,19712:42,19968:43,20224:31,20480:1,20736:5,20992:2,21248:6,21504:3,21760:7,22016:4,22272:8,22528:9,22784:13,23040:10,23296:14,23552:11,23808:15,24064:12,24320:16},Oe[32256]={12288:71,12800:72,13312:73,13824:74,14336:75,14848:76,15360:77,15872:78},Oe[29248]={24576:79,24640:80,25088:81,25152:82},Oe[28700]={28672:93,28676:94,28680:95,28684:96,28688:97,28692:98,28696:99,28700:100},Oe),xe=["","I","M","S"],ye=" L E LE A GE N G".split(" "), ze="N NE NA NN Z ZE ZA ZN C CE CA CN O OE OA ON".split(" "),Nd=1E3,Qd=">> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;b Date: Sat, 25 Feb 2017 21:19:41 -0800 Subject: [PATCH 12/30] Some PDP-10 disassembler clean-up --- modules/pdp10/lib/cpuops.js | 2 +- modules/pdp10/lib/debugger.js | 121 +++++++++++++++------------------- modules/pdp10/lib/defines.js | 43 ++++++++++-- 3 files changed, 91 insertions(+), 75 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index cd815f4ff..14147d7e8 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -3790,7 +3790,7 @@ PDP10.opUndefined = function(opCode) */ PDP10.opKA10 = function(opCode) { - var op = (opCode / PDP10.OPCODE.SHIFT)|0; + var op = (opCode / PDP10.OPCODE.O_SHIFT)|0; PDP10.aOpXXX_KA10[op].call(this, opCode); }; diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 6f472e9f9..c074484d1 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -3456,50 +3456,62 @@ class DebuggerPDP10 extends Debugger { /** * doTest() * + * This function exercises the disassembler by performing look-ups for all possible operation codes + * and displaying the results. It's not intended to be included in the compiled version of the Debugger + * (DEBUG only). + * * @this {DebuggerPDP10} */ doTest() { - var ops = {}, aOpXXX = []; - var op, opXXX, opCode, sOperation; - for (op = 0o00000; op <= 0o77774; op += 4) { - opCode = op * Math.pow(2, 21); - sOperation = this.findInstruction(opCode, false); - if (!sOperation) continue; - if (ops[sOperation] === undefined) { - ops[sOperation] = op; - } else { - ops[sOperation] &= op; + if (DEBUG) { + var ops = {}, aOpXXX = []; + var op, opXXX, opCode, sOperation; + for (op = 0o00000; op <= 0o77774; op += 4) { + opCode = op * Math.pow(2, 21); + sOperation = this.findInstruction(opCode, false); + if (!sOperation) continue; + if (ops[sOperation] === undefined) { + ops[sOperation] = op; + } else { + ops[sOperation] &= op; + } + opXXX = op >> 6; + if (!aOpXXX[opXXX]) { + aOpXXX[opXXX] = sOperation; + } else if (aOpXXX[opXXX] != sOperation) { + aOpXXX[opXXX] = "XXX"; + } } - opXXX = op >> 6; - if (!aOpXXX[opXXX]) { - aOpXXX[opXXX] = sOperation; - } else if (aOpXXX[opXXX] != sOperation) { - aOpXXX[opXXX] = "XXX"; + for (sOperation in ops) { + op = ops[sOperation]; + this.println(Str.pad(sOperation + ":", 8) + this.toStrWord(op * Math.pow(2, 21))); + // + // The following code leveraged the disassembler to generate opcode handlers for all known opcodes. + // + // this.println("/**"); + // this.println(" * op" + sOperation + "(" + this.toStrWord(op * Math.pow(2, 21)) + ")"); + // this.println(" *"); + // this.println(" * @this {CPUStatePDP10}"); + // this.println(" * @param {number} opCode"); + // this.println(" */"); + // this.println("PDP10.op" + sOperation + " = function(opCode)"); + // this.println("{"); + // this.println("};\n"); } + // + // The following code leveraged the disassembler to generate an opcode dispatch table for all known opcodes. + // + // this.println("PDP10.aOpXXX = ["); + // for (opXXX = 0o000; opXXX <= 0o777; opXXX++) { + // sOperation = aOpXXX[opXXX]; + // sOperation = sOperation? (" PDP10.op" + sOperation + ",") : " PDP10.opUndefined,"; + // sOperation = Str.pad(sOperation, 32); + // sOperation += "// " + Str.toOct(opXXX, 3, true) + "xxx yyyyyy"; + // this.println(sOperation); + // } + // this.println("];"); } - for (sOperation in ops) { - op = ops[sOperation]; - this.println(sOperation + ": " + this.toStrWord(op * Math.pow(2, 21))); - // this.println("/**"); - // this.println(" * op" + sOperation + "(" + this.toStrWord(op * Math.pow(2, 21)) + ")"); - // this.println(" *"); - // this.println(" * @this {CPUStatePDP10}"); - // this.println(" * @param {number} opCode"); - // this.println(" */"); - // this.println("PDP10.op" + sOperation + " = function(opCode)"); - // this.println("{"); - // this.println("};\n"); - } - // this.println("PDP10.aOpXXX = ["); - // for (opXXX = 0o000; opXXX <= 0o777; opXXX++) { - // sOperation = aOpXXX[opXXX]; - // sOperation = sOperation? (" PDP10.op" + sOperation + ",") : " PDP10.opUndefined,"; - // sOperation = Str.pad(sOperation, 32); - // sOperation += "// " + Str.toOct(opXXX, 3, true) + "xxx yyyyyy"; - // this.println(sOperation); - // } - // this.println("];"); } /** @@ -3634,37 +3646,10 @@ if (DEBUGGER) { ]; /* - * PDP-10 opcodes are 36-bit values, many of which use the following layout: - * - * 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 - * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 - * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y - * - * or using modern bit-numbering: - * - * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 - * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 - * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y - * - * where OOOOOOOMM represents the operation, and MM (if used) represents the mode: - * - * Mode Suffix Source Destination - * ---- ------ ----- ----------- - * 0: BASIC None E AC - * 1: IMMEDIATE I 0,E AC - * 2: MEMORY M AC E - * 3: SELF S E E (and AC if A is non-zero) - * - * Input-output instructions look like: - * - * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 - * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 - * 1 1 1 D D D D D D D O O O I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y - * - * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to - * calculate the "effective address" (E). To determine E from R, we must extract I, X, - * and Y from R, set E to Y, then add [X] to E if X is non-zero. If I is zero, then - * we're done; otherwise, we must set set R to [E] and repeat the process. + * OPTABLE is a collection of masks, and each mask refers to a collection of opcode + * patterns associated with that mask; the disassembler applies each mask to the opcode, + * and when a masked opcode matches one of the associated patterns, the corresponding + * instruction is considered a match. */ DebuggerPDP10.OPTABLE = { [PDP10.OPCODE.OPUUO]: { // 0o70000 diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index b4d1121cb..58f52b949 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -101,7 +101,37 @@ var PDP10 = { DATA_LIMIT: Math.pow(2, 36), /* - * Opcode definitions + * PDP-10 opcodes are 36-bit values, most of which use the following layout: + * + * 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 + * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 + * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y + * + * or using modern bit-numbering: + * + * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 + * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 + * O O O O O O O M M A A A A I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y + * + * where OOOOOOOMM represents the operation, and MM (if used) represents the mode: + * + * Mode Suffix Source Destination + * ---- ------ ----- ----------- + * 0: BASIC None E AC + * 1: IMMEDIATE I 0,E AC + * 2: MEMORY M AC E + * 3: SELF S E E (and AC if A is non-zero) + * + * Input-output instructions look like: + * + * 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 + * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 + * 1 1 1 D D D D D D D O O O I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y + * + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to + * calculate the "effective address" (E). To determine E from R, we must extract I, X, + * and Y from R, set E to Y, then add [X] to E if X is non-zero. If I is zero, then + * we're done; otherwise, we must set set R to [E] and repeat the process. */ OPCODE: { OPMASK: 0o77700, // operation mask @@ -115,11 +145,12 @@ var PDP10 = { FNMASK: 0o17, // accumulator/function mask (after shift) IOSHIFT: Math.pow(2, 26), // input-output device code shift IOMASK: 0o177, // input-output device code mask (after shift) - SHIFT: Math.pow(2, 27), // operation code shift - Y_MASK: 0o777777, - X_SHIFT: 18, - X_MASK: 0o17, - I_BIT: 0o20000000, + O_SHIFT: Math.pow(2, 27), // operation shift + O_MASK: 0o777, // operation mask (after shift) + I_BIT: 0o20000000, // indirect bit + X_SHIFT: 18, // X shift + X_MASK: 0o17, // X mask (after shift) + Y_MASK: 0o777777, // Y mask HALT: 0o5304 // operation code for HALT }, From e3ab5b1ed53bfaf2ca2ba0c4e71b006576554cb5 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Sun, 26 Feb 2017 09:13:16 -0800 Subject: [PATCH 13/30] Added preliminary PDP-10 opcode decoding --- modules/pdp10/lib/cpuops.js | 2127 +++++++++++++++++++-------------- modules/pdp10/lib/cpustate.js | 62 +- modules/pdp10/lib/defines.js | 11 +- modules/pdp11/lib/cpustate.js | 6 +- 4 files changed, 1302 insertions(+), 904 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index 14147d7e8..f12196cb2 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -29,11 +29,12 @@ "use strict"; if (NODE) { + var Str = require("../../shared/lib/strlib"); var PDP10 = require("./defines"); } /** - * opUUO(0xx000 000000): Unimplemented User Operation + * opUUO(0o0xx000): Unimplemented User Operation * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-64: * @@ -59,10 +60,11 @@ if (NODE) { */ PDP10.opUUO = function(opCode) { + this.opUndefined(opCode); }; /** - * opUFA(130000 000000): Unnormalized Floating Add + * opUFA(0o130000): Unnormalized Floating Add * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * @@ -84,10 +86,11 @@ PDP10.opUUO = function(opCode) */ PDP10.opUFA = function(opCode) { + this.opUndefined(opCode); }; /** - * opDFN(131000 000000): Double Floating Negate + * opDFN(0o131000): Double Floating Negate * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * @@ -102,10 +105,11 @@ PDP10.opUFA = function(opCode) */ PDP10.opDFN = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSC(132000 000000): Floating Scale + * opFSC(0o132000): Floating Scale * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-34: * @@ -133,10 +137,11 @@ PDP10.opDFN = function(opCode) */ PDP10.opFSC = function(opCode) { + this.opUndefined(opCode); }; /** - * opIBP(133000 000000): Increment Byte Pointer + * opIBP(0o133000): Increment Byte Pointer * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-16: * @@ -159,3606 +164,3967 @@ PDP10.opFSC = function(opCode) */ PDP10.opIBP = function(opCode) { + this.opUndefined(opCode); }; /** - * opILDB(134000 000000) + * opILDB(0o134000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opILDB = function(opCode) { + this.opUndefined(opCode); }; /** - * opLDB(135000 000000) + * opLDB(0o135000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opLDB = function(opCode) { + this.opUndefined(opCode); }; /** - * opIDPB(136000 000000) + * opIDPB(0o136000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIDPB = function(opCode) { + this.opUndefined(opCode); }; /** - * opDPB(137000 000000) + * opDPB(0o137000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDPB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFAD(140000 000000) + * opFAD(0o140000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFAD = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADI(141000 000000) + * opFADI(0o141000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADM(142000 000000) + * opFADM(0o142000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADB(143000 000000) + * opFADB(0o143000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADR(144000 000000) + * opFADR(0o144000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADR = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADRI(145000 000000) + * opFADRI(0o145000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADRM(146000 000000) + * opFADRM(0o146000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFADRB(147000 000000) + * opFADRB(0o147000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFADRB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSB(150000 000000) + * opFSB(0o150000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBI(151000 000000) + * opFSBI(0o151000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBM(152000 000000) + * opFSBM(0o152000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBB(153000 000000) + * opFSBB(0o153000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBR(154000 000000) + * opFSBR(0o154000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBR = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBRI(155000 000000) + * opFSBRI(0o155000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBRM(156000 000000) + * opFSBRM(0o156000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFSBRB(157000 000000) + * opFSBRB(0o157000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFSBRB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMP(160000 000000) + * opFMP(0o160000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMP = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPI(161000 000000) + * opFMPI(0o161000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPM(162000 000000) + * opFMPM(0o162000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPB(163000 000000) + * opFMPB(0o163000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPR(164000 000000) + * opFMPR(0o164000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPR = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPRI(165000 000000) + * opFMPRI(0o165000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPRM(166000 000000) + * opFMPRM(0o166000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFMPRB(167000 000000) + * opFMPRB(0o167000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFMPRB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDV(170000 000000) + * opFDV(0o170000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDV = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVI(171000 000000) + * opFDVI(0o171000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVM(172000 000000) + * opFDVM(0o172000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVB(173000 000000) + * opFDVB(0o173000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVB = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVR(174000 000000) + * opFDVR(0o174000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVR = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVRI(175000 000000) + * opFDVRI(0o175000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVRM(176000 000000) + * opFDVRM(0o176000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opFDVRB(177000 000000) + * opFDVRB(0o177000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opFDVRB = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOV(200000 000000) + * opMOV(0o200000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOV = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVI(201000 000000) + * opMOVI(0o201000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVI = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVM(200000 000000) + * opMOVM(0o200000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVM = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVS(200000 000000) + * opMOVS(0o200000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVS = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVSI(205000 000000) + * opMOVSI(0o205000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVSI = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVSM(206000 000000) + * opMOVSM(0o206000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVSM = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVSS(207000 000000) + * opMOVSS(0o207000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVSS = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVN(210000 000000) + * opMOVN(0o210000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVN = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVNI(211000 000000) + * opMOVNI(0o211000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVNI = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVNM(212000 000000) + * opMOVNM(0o212000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVNM = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVNS(213000 000000) + * opMOVNS(0o213000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVNS = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVMI(215000 000000) + * opMOVMI(0o215000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVMI = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVMM(216000 000000) + * opMOVMM(0o216000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVMM = function(opCode) { + this.opUndefined(opCode); }; /** - * opMOVMS(217000 000000) + * opMOVMS(0o217000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMOVMS = function(opCode) { + this.opUndefined(opCode); }; /** - * opIMUL(220000 000000) + * opIMUL(0o220000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIMUL = function(opCode) { + this.opUndefined(opCode); }; /** - * opIMULI(221000 000000) + * opIMULI(0o221000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIMULI = function(opCode) { + this.opUndefined(opCode); }; /** - * opIMULM(222000 000000) + * opIMULM(0o222000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIMULM = function(opCode) { + this.opUndefined(opCode); }; /** - * opIMULB(223000 000000) + * opIMULB(0o223000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIMULB = function(opCode) { + this.opUndefined(opCode); }; /** - * opMUL(224000 000000) + * opMUL(0o224000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMUL = function(opCode) { + this.opUndefined(opCode); }; /** - * opMULI(225000 000000) + * opMULI(0o225000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMULI = function(opCode) { + this.opUndefined(opCode); }; /** - * opMULM(226000 000000) + * opMULM(0o226000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMULM = function(opCode) { + this.opUndefined(opCode); }; /** - * opMULB(227000 000000) + * opMULB(0o227000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opMULB = function(opCode) { + this.opUndefined(opCode); }; /** - * opIDIV(230000 000000) + * opIDIV(0o230000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIDIV = function(opCode) { + this.opUndefined(opCode); }; /** - * opIDIVI(231000 000000) + * opIDIVI(0o231000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIDIVI = function(opCode) { + this.opUndefined(opCode); }; /** - * opIDIVM(232000 000000) + * opIDIVM(0o232000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIDIVM = function(opCode) { + this.opUndefined(opCode); }; /** - * opIDIVB(233000 000000) + * opIDIVB(0o233000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIDIVB = function(opCode) { + this.opUndefined(opCode); }; /** - * opDIV(234000 000000) + * opDIV(0o234000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDIV = function(opCode) { + this.opUndefined(opCode); }; /** - * opDIVI(235000 000000) + * opDIVI(0o235000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDIVI = function(opCode) { + this.opUndefined(opCode); }; /** - * opDIVM(236000 000000) + * opDIVM(0o236000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDIVM = function(opCode) { + this.opUndefined(opCode); }; /** - * opDIVB(237000 000000) + * opDIVB(0o237000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDIVB = function(opCode) { + this.opUndefined(opCode); }; /** - * opASH(240000 000000) + * opASH(0o240000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opASH = function(opCode) { + this.opUndefined(opCode); }; /** - * opROT(241000 000000) + * opROT(0o241000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opROT = function(opCode) { + this.opUndefined(opCode); }; /** - * opLSH(242000 000000) + * opLSH(0o242000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opLSH = function(opCode) { + this.opUndefined(opCode); }; /** - * opJFFO(243000 000000) + * opJFFO(0o243000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJFFO = function(opCode) { + this.opUndefined(opCode); }; /** - * opASHC(244000 000000) + * opASHC(0o244000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opASHC = function(opCode) { + this.opUndefined(opCode); }; /** - * opROTC(245000 000000) + * opROTC(0o245000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opROTC = function(opCode) { + this.opUndefined(opCode); }; /** - * opLSHC(246000 000000) + * opLSHC(0o246000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opLSHC = function(opCode) { + this.opUndefined(opCode); }; /** - * opEXCH(250000 000000) + * opEXCH(0o250000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opEXCH = function(opCode) { + this.opUndefined(opCode); }; /** - * opBLT(251000 000000) + * opBLT(0o251000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opBLT = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOBJP(252000 000000) + * opAOBJP(0o252000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOBJP = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOBJN(253000 000000) + * opAOBJN(0o253000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOBJN = function(opCode) { + this.opUndefined(opCode); }; /** - * opJRST(254000 000000) + * opJRST(0o254000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJRST = function(opCode) { + this.opUndefined(opCode); }; /** - * opJFCL(255000 000000) + * opJFCL(0o255000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJFCL = function(opCode) { + this.opUndefined(opCode); }; /** - * opXCT(256000 000000) + * opXCT(0o256000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opXCT = function(opCode) { + this.opUndefined(opCode); }; /** - * opPUSHJ(260000 000000) + * opPUSHJ(0o260000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opPUSHJ = function(opCode) { + this.opUndefined(opCode); }; /** - * opPUSH(261000 000000) + * opPUSH(0o261000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opPUSH = function(opCode) { + this.opUndefined(opCode); }; /** - * opPOP(262000 000000) + * opPOP(0o262000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opPOP = function(opCode) { + this.opUndefined(opCode); }; /** - * opPOPJ(263000 000000) + * opPOPJ(0o263000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opPOPJ = function(opCode) { + this.opUndefined(opCode); }; /** - * opJSR(264000 000000) + * opJSR(0o264000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJSR = function(opCode) { + this.opUndefined(opCode); }; /** - * opJSP(265000 000000) + * opJSP(0o265000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJSP = function(opCode) { + this.opUndefined(opCode); }; /** - * opJSA(266000 000000) + * opJSA(0o266000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJSA = function(opCode) { + this.opUndefined(opCode); }; /** - * opJRA(267000 000000) + * opJRA(0o267000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJRA = function(opCode) { + this.opUndefined(opCode); }; /** - * opADD(270000 000000) + * opADD(0o270000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opADD = function(opCode) { + this.opUndefined(opCode); }; /** - * opADDI(271000 000000) + * opADDI(0o271000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opADDI = function(opCode) { + this.opUndefined(opCode); }; /** - * opADDM(272000 000000) + * opADDM(0o272000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opADDM = function(opCode) { + this.opUndefined(opCode); }; /** - * opADDB(273000 000000) + * opADDB(0o273000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opADDB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSUB(274000 000000) + * opSUB(0o274000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSUB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSUBI(275000 000000) + * opSUBI(0o275000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSUBI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSUBM(276000 000000) + * opSUBM(0o276000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSUBM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSUBB(277000 000000) + * opSUBB(0o277000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSUBB = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAI(300000 000000) + * opCAI(0o300000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIL(301000 000000) + * opCAIL(0o301000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIL = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIE(302000 000000) + * opCAIE(0o302000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAILE(303000 000000) + * opCAILE(0o303000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAILE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIA(304000 000000) + * opCAIA(0o304000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIA = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIGE(305000 000000) + * opCAIGE(0o305000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIN(306000 000000) + * opCAIN(0o306000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIN = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAIG(307000 000000) + * opCAIG(0o307000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAIG = function(opCode) { + this.opUndefined(opCode); }; /** - * opCA(310000 000000) + * opCA(0o310000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAL(311000 000000) + * opCAL(0o311000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAL = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAE(312000 000000) + * opCAE(0o312000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCALE(313000 000000) + * opCALE(0o313000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCALE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAA(314000 000000) + * opCAA(0o314000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAA = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAGE(315000 000000) + * opCAGE(0o315000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAN(316000 000000) + * opCAN(0o316000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAN = function(opCode) { + this.opUndefined(opCode); }; /** - * opCAG(317000 000000) + * opCAG(0o317000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCAG = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMP(320000 000000) + * opJUMP(0o320000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMP = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPL(321000 000000) + * opJUMPL(0o321000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPL = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPE(322000 000000) + * opJUMPE(0o322000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPE = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPLE(323000 000000) + * opJUMPLE(0o323000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPA(324000 000000) + * opJUMPA(0o324000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPA = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPGE(325000 000000) + * opJUMPGE(0o325000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPN(326000 000000) + * opJUMPN(0o326000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPN = function(opCode) { + this.opUndefined(opCode); }; /** - * opJUMPG(327000 000000) + * opJUMPG(0o327000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opJUMPG = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIP(330000 000000) + * opSKIP(0o330000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIP = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPL(331000 000000) + * opSKIPL(0o331000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPL = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPE(332000 000000) + * opSKIPE(0o332000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPLE(333000 000000) + * opSKIPLE(0o333000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPA(334000 000000) + * opSKIPA(0o334000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPA = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPGE(335000 000000) + * opSKIPGE(0o335000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPN(336000 000000) + * opSKIPN(0o336000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPN = function(opCode) { + this.opUndefined(opCode); }; /** - * opSKIPG(337000 000000) + * opSKIPG(0o337000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSKIPG = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJ(340000 000000) + * opAOJ(0o340000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJ = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJL(341000 000000) + * opAOJL(0o341000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJL = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJE(342000 000000) + * opAOJE(0o342000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJLE(343000 000000) + * opAOJLE(0o343000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJA(344000 000000) + * opAOJA(0o344000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJA = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJGE(345000 000000) + * opAOJGE(0o345000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJN(346000 000000) + * opAOJN(0o346000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJN = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOJG(347000 000000) + * opAOJG(0o347000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOJG = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOS(350000 000000) + * opAOS(0o350000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOS = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSL(351000 000000) + * opAOSL(0o351000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSL = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSE(352000 000000) + * opAOSE(0o352000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSLE(353000 000000) + * opAOSLE(0o353000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSA(354000 000000) + * opAOSA(0o354000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSA = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSGE(355000 000000) + * opAOSGE(0o355000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSN(356000 000000) + * opAOSN(0o356000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSN = function(opCode) { + this.opUndefined(opCode); }; /** - * opAOSG(357000 000000) + * opAOSG(0o357000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAOSG = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJ(360000 000000) + * opSOJ(0o360000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJ = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJL(361000 000000) + * opSOJL(0o361000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJL = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJE(362000 000000) + * opSOJE(0o362000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJLE(363000 000000) + * opSOJLE(0o363000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJA(364000 000000) + * opSOJA(0o364000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJA = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJGE(365000 000000) + * opSOJGE(0o365000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJN(366000 000000) + * opSOJN(0o366000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJN = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOJG(367000 000000) + * opSOJG(0o367000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOJG = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOS(370000 000000) + * opSOS(0o370000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOS = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSL(371000 000000) + * opSOSL(0o371000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSL = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSE(372000 000000) + * opSOSE(0o372000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSLE(373000 000000) + * opSOSLE(0o373000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSA(374000 000000) + * opSOSA(0o374000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSA = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSGE(375000 000000) + * opSOSGE(0o375000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSGE = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSN(376000 000000) + * opSOSN(0o376000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSN = function(opCode) { + this.opUndefined(opCode); }; /** - * opSOSG(377000 000000) + * opSOSG(0o377000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSOSG = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETZ(400000 000000) + * opSETZ(0o400000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETZI(401000 000000) + * opSETZI(0o401000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETZI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETZM(402000 000000) + * opSETZM(0o402000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETZM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETZB(403000 000000) + * opSETZB(0o403000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETZB = function(opCode) { + this.opUndefined(opCode); }; /** - * opAND(404000 000000) + * opAND(0o404000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opAND = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDI(405000 000000) + * opANDI(0o405000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDI = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDM(406000 000000) + * opANDM(0o406000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDM = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDB(407000 000000) + * opANDB(0o407000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDB = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCA(410000 000000) + * opANDCA(0o410000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCAI(411000 000000) + * opANDCAI(0o411000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCAM(412000 000000) + * opANDCAM(0o412000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCAM = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCAB(413000 000000) + * opANDCAB(0o413000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCAB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETM(414000 000000) + * opSETM(0o414000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETMI(415000 000000) + * opSETMI(0o415000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETMI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETMM(416000 000000) + * opSETMM(0o416000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETMM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETMB(417000 000000) + * opSETMB(0o417000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETMB = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCM(420000 000000) + * opANDCM(0o420000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCM = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCMI(421000 000000) + * opANDCMI(0o421000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCMI = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCMM(422000 000000) + * opANDCMM(0o422000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCMM = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCMB(423000 000000) + * opANDCMB(0o423000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCMB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETA(424000 000000) + * opSETA(0o424000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETA = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETAI(425000 000000) + * opSETAI(0o425000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETAM(426000 000000) + * opSETAM(0o426000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETAM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETAB(427000 000000) + * opSETAB(0o427000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETAB = function(opCode) { + this.opUndefined(opCode); }; /** - * opXOR(430000 000000) + * opXOR(0o430000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opXOR = function(opCode) { + this.opUndefined(opCode); }; /** - * opXORI(431000 000000) + * opXORI(0o431000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opXORI = function(opCode) { + this.opUndefined(opCode); }; /** - * opXORM(432000 000000) + * opXORM(0o432000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opXORM = function(opCode) { + this.opUndefined(opCode); }; /** - * opXORB(433000 000000) + * opXORB(0o433000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opXORB = function(opCode) { + this.opUndefined(opCode); }; /** - * opIOR(434000 000000) + * opIOR(0o434000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIOR = function(opCode) { + this.opUndefined(opCode); }; /** - * opIORI(435000 000000) + * opIORI(0o435000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIORI = function(opCode) { + this.opUndefined(opCode); }; /** - * opIORM(436000 000000) + * opIORM(0o436000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIORM = function(opCode) { + this.opUndefined(opCode); }; /** - * opIORB(437000 000000) + * opIORB(0o437000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opIORB = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCB(440000 000000) + * opANDCB(0o440000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCB = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCBI(441000 000000) + * opANDCBI(0o441000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCBI = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCBM(442000 000000) + * opANDCBM(0o442000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCBM = function(opCode) { + this.opUndefined(opCode); }; /** - * opANDCBB(443000 000000) + * opANDCBB(0o443000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opANDCBB = function(opCode) { + this.opUndefined(opCode); }; /** - * opEQV(444000 000000) + * opEQV(0o444000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opEQV = function(opCode) { + this.opUndefined(opCode); }; /** - * opEQVI(445000 000000) + * opEQVI(0o445000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opEQVI = function(opCode) { + this.opUndefined(opCode); }; /** - * opEQVM(446000 000000) + * opEQVM(0o446000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opEQVM = function(opCode) { + this.opUndefined(opCode); }; /** - * opEQVB(447000 000000) + * opEQVB(0o447000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opEQVB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCA(450000 000000) + * opSETCA(0o450000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCAI(451000 000000) + * opSETCAI(0o451000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCAM(452000 000000) + * opSETCAM(0o452000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCAM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCAB(453000 000000) + * opSETCAB(0o453000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCAB = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCA(454000 000000) + * opORCA(0o454000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCAI(455000 000000) + * opORCAI(0o455000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCAM(456000 000000) + * opORCAM(0o456000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCAM = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCAB(457000 000000) + * opORCAB(0o457000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCAB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCM(460000 000000) + * opSETCM(0o460000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCMI(461000 000000) + * opSETCMI(0o461000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCMI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCMM(462000 000000) + * opSETCMM(0o462000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCMM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETCMB(463000 000000) + * opSETCMB(0o463000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETCMB = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCM(464000 000000) + * opORCM(0o464000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCM = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCMI(465000 000000) + * opORCMI(0o465000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCMI = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCMM(466000 000000) + * opORCMM(0o466000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCMM = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCMB(467000 000000) + * opORCMB(0o467000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCMB = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCB(470000 000000) + * opORCB(0o470000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCB = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCBI(471000 000000) + * opORCBI(0o471000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCBI = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCBM(472000 000000) + * opORCBM(0o472000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCBM = function(opCode) { + this.opUndefined(opCode); }; /** - * opORCBB(473000 000000) + * opORCBB(0o473000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opORCBB = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETO(474000 000000) + * opSETO(0o474000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETO = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETOI(475000 000000) + * opSETOI(0o475000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETOI = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETOM(476000 000000) + * opSETOM(0o476000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETOM = function(opCode) { + this.opUndefined(opCode); }; /** - * opSETOB(477000 000000) + * opSETOB(0o477000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opSETOB = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLL(500000 000000) + * opHLL(0o500000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLL = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLI(501000 000000) + * opHLLI(0o501000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLM(502000 000000) + * opHLLM(0o502000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLS(503000 000000) + * opHLLS(0o503000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRL(504000 000000) + * opHRL(0o504000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRL = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLI(505000 000000) + * opHRLI(0o505000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLM(506000 000000) + * opHRLM(0o506000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLS(507000 000000) + * opHRLS(0o507000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLZ(510000 000000) + * opHLLZ(0o510000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLZI(511000 000000) + * opHLLZI(0o511000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLZI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLZM(512000 000000) + * opHLLZM(0o512000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLZM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLZS(513000 000000) + * opHLLZS(0o513000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLZS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLZ(514000 000000) + * opHRLZ(0o514000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLZI(515000 000000) + * opHRLZI(0o515000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLZI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLZM(516000 000000) + * opHRLZM(0o516000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLZM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLZS(517000 000000) + * opHRLZS(0o517000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLZS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLO(520000 000000) + * opHLLO(0o520000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLO = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLOI(521000 000000) + * opHLLOI(0o521000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLOI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLOM(522000 000000) + * opHLLOM(0o522000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLOM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLOS(523000 000000) + * opHLLOS(0o523000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLOS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLO(524000 000000) + * opHRLO(0o524000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLO = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLOI(525000 000000) + * opHRLOI(0o525000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLOI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLOM(526000 000000) + * opHRLOM(0o526000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLOM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLOS(527000 000000) + * opHRLOS(0o527000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLOS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLE(530000 000000) + * opHLLE(0o530000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLEI(531000 000000) + * opHLLEI(0o531000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLEI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLEM(532000 000000) + * opHLLEM(0o532000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLEM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLLES(533000 000000) + * opHLLES(0o533000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLLES = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLE(534000 000000) + * opHRLE(0o534000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLE = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLEI(535000 000000) + * opHRLEI(0o535000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLEI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLEM(536000 000000) + * opHRLEM(0o536000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLEM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRLES(537000 000000) + * opHRLES(0o537000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRLES = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRR(540000 000000) + * opHRR(0o540000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRR = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRI(541000 000000) + * opHRRI(0o541000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRM(542000 000000) + * opHRRM(0o542000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRS(543000 000000) + * opHRRS(0o543000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLR(544000 000000) + * opHLR(0o544000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLR = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRI(545000 000000) + * opHLRI(0o545000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRM(546000 000000) + * opHLRM(0o546000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRS(547000 000000) + * opHLRS(0o547000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRZ(550000 000000) + * opHRRZ(0o550000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRZI(551000 000000) + * opHRRZI(0o551000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRZI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRZM(552000 000000) + * opHRRZM(0o552000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRZM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRZS(553000 000000) + * opHRRZS(0o553000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRZS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRZ(554000 000000) + * opHLRZ(0o554000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRZI(555000 000000) + * opHLRZI(0o555000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRZI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRZM(556000 000000) + * opHLRZM(0o556000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRZM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRZS(557000 000000) + * opHLRZS(0o557000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRZS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRO(560000 000000) + * opHRRO(0o560000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRO = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRROI(561000 000000) + * opHRROI(0o561000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRROI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRROM(562000 000000) + * opHRROM(0o562000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRROM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRROS(563000 000000) + * opHRROS(0o563000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRROS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRO(564000 000000) + * opHLRO(0o564000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRO = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLROI(565000 000000) + * opHLROI(0o565000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLROI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLROM(566000 000000) + * opHLROM(0o566000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLROM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLROS(567000 000000) + * opHLROS(0o567000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLROS = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRE(570000 000000) + * opHRRE(0o570000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRE = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRREI(571000 000000) + * opHRREI(0o571000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRREI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRREM(572000 000000) + * opHRREM(0o572000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRREM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHRRES(573000 000000) + * opHRRES(0o573000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHRRES = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRE(574000 000000) + * opHLRE(0o574000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRE = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLREI(575000 000000) + * opHLREI(0o575000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLREI = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLREM(576000 000000) + * opHLREM(0o576000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLREM = function(opCode) { + this.opUndefined(opCode); }; /** - * opHLRES(577000 000000) + * opHLRES(0o577000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opHLRES = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRN(600000 000000) + * opTRN(0o600000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLN(601000 000000) + * opTLN(0o601000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRNE(602000 000000) + * opTRNE(0o602000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRNE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLNE(603000 000000) + * opTLNE(0o603000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLNE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRNA(604000 000000) + * opTRNA(0o604000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRNA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLNA(605000 000000) + * opTLNA(0o605000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLNA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRNN(606000 000000) + * opTRNN(0o606000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRNN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLNN(607000 000000) + * opTLNN(0o607000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLNN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDN(610000 000000) + * opTDN(0o610000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSN(611000 000000) + * opTSN(0o611000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDNE(612000 000000) + * opTDNE(0o612000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDNE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSNE(613000 000000) + * opTSNE(0o613000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSNE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDNA(614000 000000) + * opTDNA(0o614000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDNA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSNA(615000 000000) + * opTSNA(0o615000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSNA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDNN(616000 000000) + * opTDNN(0o616000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDNN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSNN(617000 000000) + * opTSNN(0o617000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSNN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRZ(620000 000000) + * opTRZ(0o620000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLZ(621000 000000) + * opTLZ(0o621000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRZE(622000 000000) + * opTRZE(0o622000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRZE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLZE(623000 000000) + * opTLZE(0o623000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLZE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRZA(624000 000000) + * opTRZA(0o624000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRZA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLZA(625000 000000) + * opTLZA(0o625000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLZA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRZN(626000 000000) + * opTRZN(0o626000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRZN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLZN(627000 000000) + * opTLZN(0o627000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLZN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDZ(630000 000000) + * opTDZ(0o630000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSZ(631000 000000) + * opTSZ(0o631000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDZE(632000 000000) + * opTDZE(0o632000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDZE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSZE(633000 000000) + * opTSZE(0o633000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSZE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDZA(634000 000000) + * opTDZA(0o634000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDZA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSZA(635000 000000) + * opTSZA(0o635000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSZA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDZN(636000 000000) + * opTDZN(0o636000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDZN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSZN(637000 000000) + * opTSZN(0o637000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSZN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRC(640000 000000) + * opTRC(0o640000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRC = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLC(641000 000000) + * opTLC(0o641000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLC = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRCE(642000 000000) + * opTRCE(0o642000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRCE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLCE(643000 000000) + * opTLCE(0o643000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLCE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRCA(644000 000000) + * opTRCA(0o644000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLCA(645000 000000) + * opTLCA(0o645000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRCN(646000 000000) + * opTRCN(0o646000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRCN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLCN(647000 000000) + * opTLCN(0o647000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLCN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDC(650000 000000) + * opTDC(0o650000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDC = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSC(651000 000000) + * opTSC(0o651000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSC = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDCE(652000 000000) + * opTDCE(0o652000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDCE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSCE(653000 000000) + * opTSCE(0o653000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSCE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDCA(654000 000000) + * opTDCA(0o654000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSCA(655000 000000) + * opTSCA(0o655000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSCA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDCN(656000 000000) + * opTDCN(0o656000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDCN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSCN(657000 000000) + * opTSCN(0o657000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSCN = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRO(660000 000000) + * opTRO(0o660000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRO = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLO(661000 000000) + * opTLO(0o661000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLO = function(opCode) { + this.opUndefined(opCode); }; /** - * opTROE(662000 000000) + * opTROE(0o662000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTROE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLOE(663000 000000) + * opTLOE(0o663000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLOE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTROA(664000 000000) + * opTROA(0o664000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTROA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLOA(665000 000000) + * opTLOA(0o665000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLOA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTRON(666000 000000) + * opTRON(0o666000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTRON = function(opCode) { + this.opUndefined(opCode); }; /** - * opTLON(667000 000000) + * opTLON(0o667000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTLON = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDO(670000 000000) + * opTDO(0o670000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDO = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSO(671000 000000) + * opTSO(0o671000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSO = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDOE(672000 000000) + * opTDOE(0o672000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDOE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSOE(673000 000000) + * opTSOE(0o673000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSOE = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDOA(674000 000000) + * opTDOA(0o674000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDOA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSOA(675000 000000) + * opTSOA(0o675000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSOA = function(opCode) { + this.opUndefined(opCode); }; /** - * opTDON(676000 000000) + * opTDON(0o676000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTDON = function(opCode) { + this.opUndefined(opCode); }; /** - * opTSON(677000 000000) + * opTSON(0o677000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opTSON = function(opCode) { + this.opUndefined(opCode); }; /** - * opBLKI(700000 000000) + * opBLKI(0o700000) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opBLKI = function(opCode) { + this.opUndefined(opCode); }; /** - * opDATAI(700040 000000) + * opDATAI(0o700040) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDATAI = function(opCode) { + this.opUndefined(opCode); }; /** - * opBLKO(700100 000000) + * opBLKO(0o700100) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opBLKO = function(opCode) { + this.opUndefined(opCode); }; /** - * opDATAO(700140 000000) + * opDATAO(0o700140) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opDATAO = function(opCode) { + this.opUndefined(opCode); }; /** - * opCONO(700200 000000) + * opCONO(0o700200) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCONO = function(opCode) { + this.opUndefined(opCode); }; /** - * opCONI(700240 000000) + * opCONI(0o700240) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCONI = function(opCode) { + this.opUndefined(opCode); }; /** - * opCONSZ(700300 000000) + * opCONSZ(0o700300) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCONSZ = function(opCode) { + this.opUndefined(opCode); }; /** - * opCONSO(700340 000000) + * opCONSO(0o700340) * * @this {CPUStatePDP10} * @param {number} opCode */ PDP10.opCONSO = function(opCode) { + this.opUndefined(opCode); }; /** @@ -3769,7 +4135,7 @@ PDP10.opCONSO = function(opCode) */ PDP10.opIO = function(opCode) { - PDP10.opUndefined.call(this, opCode); + this.opUndefined(opCode); }; /** @@ -3780,6 +4146,8 @@ PDP10.opIO = function(opCode) */ PDP10.opUndefined = function(opCode) { + this.println("undefined opcode: " + Str.toOct(opCode)); + this.stopCPU(); }; /** @@ -3790,521 +4158,520 @@ PDP10.opUndefined = function(opCode) */ PDP10.opKA10 = function(opCode) { - var op = (opCode / PDP10.OPCODE.O_SHIFT)|0; - PDP10.aOpXXX_KA10[op].call(this, opCode); + PDP10.aOpXXX_KA10[opCode >> 9].call(this, opCode); }; PDP10.aOpXXX_KA10 = [ - PDP10.opUUO, // 0o000xxx yyyyyy - PDP10.opUUO, // 0o001xxx yyyyyy - PDP10.opUUO, // 0o002xxx yyyyyy - PDP10.opUUO, // 0o003xxx yyyyyy - PDP10.opUUO, // 0o004xxx yyyyyy - PDP10.opUUO, // 0o005xxx yyyyyy - PDP10.opUUO, // 0o006xxx yyyyyy - PDP10.opUUO, // 0o007xxx yyyyyy - PDP10.opUUO, // 0o010xxx yyyyyy - PDP10.opUUO, // 0o011xxx yyyyyy - PDP10.opUUO, // 0o012xxx yyyyyy - PDP10.opUUO, // 0o013xxx yyyyyy - PDP10.opUUO, // 0o014xxx yyyyyy - PDP10.opUUO, // 0o015xxx yyyyyy - PDP10.opUUO, // 0o016xxx yyyyyy - PDP10.opUUO, // 0o017xxx yyyyyy - PDP10.opUUO, // 0o020xxx yyyyyy - PDP10.opUUO, // 0o021xxx yyyyyy - PDP10.opUUO, // 0o022xxx yyyyyy - PDP10.opUUO, // 0o023xxx yyyyyy - PDP10.opUUO, // 0o024xxx yyyyyy - PDP10.opUUO, // 0o025xxx yyyyyy - PDP10.opUUO, // 0o026xxx yyyyyy - PDP10.opUUO, // 0o027xxx yyyyyy - PDP10.opUUO, // 0o030xxx yyyyyy - PDP10.opUUO, // 0o031xxx yyyyyy - PDP10.opUUO, // 0o032xxx yyyyyy - PDP10.opUUO, // 0o033xxx yyyyyy - PDP10.opUUO, // 0o034xxx yyyyyy - PDP10.opUUO, // 0o035xxx yyyyyy - PDP10.opUUO, // 0o036xxx yyyyyy - PDP10.opUUO, // 0o037xxx yyyyyy - PDP10.opUUO, // 0o040xxx yyyyyy - PDP10.opUUO, // 0o041xxx yyyyyy - PDP10.opUUO, // 0o042xxx yyyyyy - PDP10.opUUO, // 0o043xxx yyyyyy - PDP10.opUUO, // 0o044xxx yyyyyy - PDP10.opUUO, // 0o045xxx yyyyyy - PDP10.opUUO, // 0o046xxx yyyyyy - PDP10.opUUO, // 0o047xxx yyyyyy - PDP10.opUUO, // 0o050xxx yyyyyy - PDP10.opUUO, // 0o051xxx yyyyyy - PDP10.opUUO, // 0o052xxx yyyyyy - PDP10.opUUO, // 0o053xxx yyyyyy - PDP10.opUUO, // 0o054xxx yyyyyy - PDP10.opUUO, // 0o055xxx yyyyyy - PDP10.opUUO, // 0o056xxx yyyyyy - PDP10.opUUO, // 0o057xxx yyyyyy - PDP10.opUUO, // 0o060xxx yyyyyy - PDP10.opUUO, // 0o061xxx yyyyyy - PDP10.opUUO, // 0o062xxx yyyyyy - PDP10.opUUO, // 0o063xxx yyyyyy - PDP10.opUUO, // 0o064xxx yyyyyy - PDP10.opUUO, // 0o065xxx yyyyyy - PDP10.opUUO, // 0o066xxx yyyyyy - PDP10.opUUO, // 0o067xxx yyyyyy - PDP10.opUUO, // 0o070xxx yyyyyy - PDP10.opUUO, // 0o071xxx yyyyyy - PDP10.opUUO, // 0o072xxx yyyyyy - PDP10.opUUO, // 0o073xxx yyyyyy - PDP10.opUUO, // 0o074xxx yyyyyy - PDP10.opUUO, // 0o075xxx yyyyyy - PDP10.opUUO, // 0o076xxx yyyyyy - PDP10.opUUO, // 0o077xxx yyyyyy - PDP10.opUndefined, // 0o100xxx yyyyyy - PDP10.opUndefined, // 0o101xxx yyyyyy - PDP10.opUndefined, // 0o102xxx yyyyyy - PDP10.opUndefined, // 0o103xxx yyyyyy - PDP10.opUndefined, // 0o104xxx yyyyyy - PDP10.opUndefined, // 0o105xxx yyyyyy - PDP10.opUndefined, // 0o106xxx yyyyyy - PDP10.opUndefined, // 0o107xxx yyyyyy - PDP10.opUndefined, // 0o110xxx yyyyyy - PDP10.opUndefined, // 0o111xxx yyyyyy - PDP10.opUndefined, // 0o112xxx yyyyyy - PDP10.opUndefined, // 0o113xxx yyyyyy - PDP10.opUndefined, // 0o114xxx yyyyyy - PDP10.opUndefined, // 0o115xxx yyyyyy - PDP10.opUndefined, // 0o116xxx yyyyyy - PDP10.opUndefined, // 0o117xxx yyyyyy - PDP10.opUndefined, // 0o120xxx yyyyyy - PDP10.opUndefined, // 0o121xxx yyyyyy - PDP10.opUndefined, // 0o122xxx yyyyyy - PDP10.opUndefined, // 0o123xxx yyyyyy - PDP10.opUndefined, // 0o124xxx yyyyyy - PDP10.opUndefined, // 0o125xxx yyyyyy - PDP10.opUndefined, // 0o126xxx yyyyyy - PDP10.opUndefined, // 0o127xxx yyyyyy - PDP10.opUFA, // 0o130xxx yyyyyy - PDP10.opDFN, // 0o131xxx yyyyyy - PDP10.opFSC, // 0o132xxx yyyyyy - PDP10.opIBP, // 0o133xxx yyyyyy - PDP10.opILDB, // 0o134xxx yyyyyy - PDP10.opLDB, // 0o135xxx yyyyyy - PDP10.opIDPB, // 0o136xxx yyyyyy - PDP10.opDPB, // 0o137xxx yyyyyy - PDP10.opFAD, // 0o140xxx yyyyyy - PDP10.opFADI, // 0o141xxx yyyyyy - PDP10.opFADM, // 0o142xxx yyyyyy - PDP10.opFADB, // 0o143xxx yyyyyy - PDP10.opFADR, // 0o144xxx yyyyyy - PDP10.opFADRI, // 0o145xxx yyyyyy - PDP10.opFADRM, // 0o146xxx yyyyyy - PDP10.opFADRB, // 0o147xxx yyyyyy - PDP10.opFSB, // 0o150xxx yyyyyy - PDP10.opFSBI, // 0o151xxx yyyyyy - PDP10.opFSBM, // 0o152xxx yyyyyy - PDP10.opFSBB, // 0o153xxx yyyyyy - PDP10.opFSBR, // 0o154xxx yyyyyy - PDP10.opFSBRI, // 0o155xxx yyyyyy - PDP10.opFSBRM, // 0o156xxx yyyyyy - PDP10.opFSBRB, // 0o157xxx yyyyyy - PDP10.opFMP, // 0o160xxx yyyyyy - PDP10.opFMPI, // 0o161xxx yyyyyy - PDP10.opFMPM, // 0o162xxx yyyyyy - PDP10.opFMPB, // 0o163xxx yyyyyy - PDP10.opFMPR, // 0o164xxx yyyyyy - PDP10.opFMPRI, // 0o165xxx yyyyyy - PDP10.opFMPRM, // 0o166xxx yyyyyy - PDP10.opFMPRB, // 0o167xxx yyyyyy - PDP10.opFDV, // 0o170xxx yyyyyy - PDP10.opFDVI, // 0o171xxx yyyyyy - PDP10.opFDVM, // 0o172xxx yyyyyy - PDP10.opFDVB, // 0o173xxx yyyyyy - PDP10.opFDVR, // 0o174xxx yyyyyy - PDP10.opFDVRI, // 0o175xxx yyyyyy - PDP10.opFDVRM, // 0o176xxx yyyyyy - PDP10.opFDVRB, // 0o177xxx yyyyyy - PDP10.opMOV, // 0o200xxx yyyyyy - PDP10.opMOVI, // 0o201xxx yyyyyy - PDP10.opMOVM, // 0o202xxx yyyyyy - PDP10.opMOVS, // 0o203xxx yyyyyy - PDP10.opMOVS, // 0o204xxx yyyyyy - PDP10.opMOVSI, // 0o205xxx yyyyyy - PDP10.opMOVSM, // 0o206xxx yyyyyy - PDP10.opMOVSS, // 0o207xxx yyyyyy - PDP10.opMOVN, // 0o210xxx yyyyyy - PDP10.opMOVNI, // 0o211xxx yyyyyy - PDP10.opMOVNM, // 0o212xxx yyyyyy - PDP10.opMOVNS, // 0o213xxx yyyyyy - PDP10.opMOVM, // 0o214xxx yyyyyy - PDP10.opMOVMI, // 0o215xxx yyyyyy - PDP10.opMOVMM, // 0o216xxx yyyyyy - PDP10.opMOVMS, // 0o217xxx yyyyyy - PDP10.opIMUL, // 0o220xxx yyyyyy - PDP10.opIMULI, // 0o221xxx yyyyyy - PDP10.opIMULM, // 0o222xxx yyyyyy - PDP10.opIMULB, // 0o223xxx yyyyyy - PDP10.opMUL, // 0o224xxx yyyyyy - PDP10.opMULI, // 0o225xxx yyyyyy - PDP10.opMULM, // 0o226xxx yyyyyy - PDP10.opMULB, // 0o227xxx yyyyyy - PDP10.opIDIV, // 0o230xxx yyyyyy - PDP10.opIDIVI, // 0o231xxx yyyyyy - PDP10.opIDIVM, // 0o232xxx yyyyyy - PDP10.opIDIVB, // 0o233xxx yyyyyy - PDP10.opDIV, // 0o234xxx yyyyyy - PDP10.opDIVI, // 0o235xxx yyyyyy - PDP10.opDIVM, // 0o236xxx yyyyyy - PDP10.opDIVB, // 0o237xxx yyyyyy - PDP10.opASH, // 0o240xxx yyyyyy - PDP10.opROT, // 0o241xxx yyyyyy - PDP10.opLSH, // 0o242xxx yyyyyy - PDP10.opJFFO, // 0o243xxx yyyyyy - PDP10.opASHC, // 0o244xxx yyyyyy - PDP10.opROTC, // 0o245xxx yyyyyy - PDP10.opLSHC, // 0o246xxx yyyyyy - PDP10.opUndefined, // 0o247xxx yyyyyy - PDP10.opEXCH, // 0o250xxx yyyyyy - PDP10.opBLT, // 0o251xxx yyyyyy - PDP10.opAOBJP, // 0o252xxx yyyyyy - PDP10.opAOBJN, // 0o253xxx yyyyyy - PDP10.opJRST, // 0o254xxx yyyyyy - PDP10.opJFCL, // 0o255xxx yyyyyy - PDP10.opXCT, // 0o256xxx yyyyyy - PDP10.opUndefined, // 0o257xxx yyyyyy - PDP10.opPUSHJ, // 0o260xxx yyyyyy - PDP10.opPUSH, // 0o261xxx yyyyyy - PDP10.opPOP, // 0o262xxx yyyyyy - PDP10.opPOPJ, // 0o263xxx yyyyyy - PDP10.opJSR, // 0o264xxx yyyyyy - PDP10.opJSP, // 0o265xxx yyyyyy - PDP10.opJSA, // 0o266xxx yyyyyy - PDP10.opJRA, // 0o267xxx yyyyyy - PDP10.opADD, // 0o270xxx yyyyyy - PDP10.opADDI, // 0o271xxx yyyyyy - PDP10.opADDM, // 0o272xxx yyyyyy - PDP10.opADDB, // 0o273xxx yyyyyy - PDP10.opSUB, // 0o274xxx yyyyyy - PDP10.opSUBI, // 0o275xxx yyyyyy - PDP10.opSUBM, // 0o276xxx yyyyyy - PDP10.opSUBB, // 0o277xxx yyyyyy - PDP10.opCAI, // 0o300xxx yyyyyy - PDP10.opCAIL, // 0o301xxx yyyyyy - PDP10.opCAIE, // 0o302xxx yyyyyy - PDP10.opCAILE, // 0o303xxx yyyyyy - PDP10.opCAIA, // 0o304xxx yyyyyy - PDP10.opCAIGE, // 0o305xxx yyyyyy - PDP10.opCAIN, // 0o306xxx yyyyyy - PDP10.opCAIG, // 0o307xxx yyyyyy - PDP10.opCA, // 0o310xxx yyyyyy - PDP10.opCAL, // 0o311xxx yyyyyy - PDP10.opCAE, // 0o312xxx yyyyyy - PDP10.opCALE, // 0o313xxx yyyyyy - PDP10.opCAA, // 0o314xxx yyyyyy - PDP10.opCAGE, // 0o315xxx yyyyyy - PDP10.opCAN, // 0o316xxx yyyyyy - PDP10.opCAG, // 0o317xxx yyyyyy - PDP10.opJUMP, // 0o320xxx yyyyyy - PDP10.opJUMPL, // 0o321xxx yyyyyy - PDP10.opJUMPE, // 0o322xxx yyyyyy - PDP10.opJUMPLE, // 0o323xxx yyyyyy - PDP10.opJUMPA, // 0o324xxx yyyyyy - PDP10.opJUMPGE, // 0o325xxx yyyyyy - PDP10.opJUMPN, // 0o326xxx yyyyyy - PDP10.opJUMPG, // 0o327xxx yyyyyy - PDP10.opSKIP, // 0o330xxx yyyyyy - PDP10.opSKIPL, // 0o331xxx yyyyyy - PDP10.opSKIPE, // 0o332xxx yyyyyy - PDP10.opSKIPLE, // 0o333xxx yyyyyy - PDP10.opSKIPA, // 0o334xxx yyyyyy - PDP10.opSKIPGE, // 0o335xxx yyyyyy - PDP10.opSKIPN, // 0o336xxx yyyyyy - PDP10.opSKIPG, // 0o337xxx yyyyyy - PDP10.opAOJ, // 0o340xxx yyyyyy - PDP10.opAOJL, // 0o341xxx yyyyyy - PDP10.opAOJE, // 0o342xxx yyyyyy - PDP10.opAOJLE, // 0o343xxx yyyyyy - PDP10.opAOJA, // 0o344xxx yyyyyy - PDP10.opAOJGE, // 0o345xxx yyyyyy - PDP10.opAOJN, // 0o346xxx yyyyyy - PDP10.opAOJG, // 0o347xxx yyyyyy - PDP10.opAOS, // 0o350xxx yyyyyy - PDP10.opAOSL, // 0o351xxx yyyyyy - PDP10.opAOSE, // 0o352xxx yyyyyy - PDP10.opAOSLE, // 0o353xxx yyyyyy - PDP10.opAOSA, // 0o354xxx yyyyyy - PDP10.opAOSGE, // 0o355xxx yyyyyy - PDP10.opAOSN, // 0o356xxx yyyyyy - PDP10.opAOSG, // 0o357xxx yyyyyy - PDP10.opSOJ, // 0o360xxx yyyyyy - PDP10.opSOJL, // 0o361xxx yyyyyy - PDP10.opSOJE, // 0o362xxx yyyyyy - PDP10.opSOJLE, // 0o363xxx yyyyyy - PDP10.opSOJA, // 0o364xxx yyyyyy - PDP10.opSOJGE, // 0o365xxx yyyyyy - PDP10.opSOJN, // 0o366xxx yyyyyy - PDP10.opSOJG, // 0o367xxx yyyyyy - PDP10.opSOS, // 0o370xxx yyyyyy - PDP10.opSOSL, // 0o371xxx yyyyyy - PDP10.opSOSE, // 0o372xxx yyyyyy - PDP10.opSOSLE, // 0o373xxx yyyyyy - PDP10.opSOSA, // 0o374xxx yyyyyy - PDP10.opSOSGE, // 0o375xxx yyyyyy - PDP10.opSOSN, // 0o376xxx yyyyyy - PDP10.opSOSG, // 0o377xxx yyyyyy - PDP10.opSETZ, // 0o400xxx yyyyyy - PDP10.opSETZI, // 0o401xxx yyyyyy - PDP10.opSETZM, // 0o402xxx yyyyyy - PDP10.opSETZB, // 0o403xxx yyyyyy - PDP10.opAND, // 0o404xxx yyyyyy - PDP10.opANDI, // 0o405xxx yyyyyy - PDP10.opANDM, // 0o406xxx yyyyyy - PDP10.opANDB, // 0o407xxx yyyyyy - PDP10.opANDCA, // 0o410xxx yyyyyy - PDP10.opANDCAI, // 0o411xxx yyyyyy - PDP10.opANDCAM, // 0o412xxx yyyyyy - PDP10.opANDCAB, // 0o413xxx yyyyyy - PDP10.opSETM, // 0o414xxx yyyyyy - PDP10.opSETMI, // 0o415xxx yyyyyy - PDP10.opSETMM, // 0o416xxx yyyyyy - PDP10.opSETMB, // 0o417xxx yyyyyy - PDP10.opANDCM, // 0o420xxx yyyyyy - PDP10.opANDCMI, // 0o421xxx yyyyyy - PDP10.opANDCMM, // 0o422xxx yyyyyy - PDP10.opANDCMB, // 0o423xxx yyyyyy - PDP10.opSETA, // 0o424xxx yyyyyy - PDP10.opSETAI, // 0o425xxx yyyyyy - PDP10.opSETAM, // 0o426xxx yyyyyy - PDP10.opSETAB, // 0o427xxx yyyyyy - PDP10.opXOR, // 0o430xxx yyyyyy - PDP10.opXORI, // 0o431xxx yyyyyy - PDP10.opXORM, // 0o432xxx yyyyyy - PDP10.opXORB, // 0o433xxx yyyyyy - PDP10.opIOR, // 0o434xxx yyyyyy - PDP10.opIORI, // 0o435xxx yyyyyy - PDP10.opIORM, // 0o436xxx yyyyyy - PDP10.opIORB, // 0o437xxx yyyyyy - PDP10.opANDCB, // 0o440xxx yyyyyy - PDP10.opANDCBI, // 0o441xxx yyyyyy - PDP10.opANDCBM, // 0o442xxx yyyyyy - PDP10.opANDCBB, // 0o443xxx yyyyyy - PDP10.opEQV, // 0o444xxx yyyyyy - PDP10.opEQVI, // 0o445xxx yyyyyy - PDP10.opEQVM, // 0o446xxx yyyyyy - PDP10.opEQVB, // 0o447xxx yyyyyy - PDP10.opSETCA, // 0o450xxx yyyyyy - PDP10.opSETCAI, // 0o451xxx yyyyyy - PDP10.opSETCAM, // 0o452xxx yyyyyy - PDP10.opSETCAB, // 0o453xxx yyyyyy - PDP10.opORCA, // 0o454xxx yyyyyy - PDP10.opORCAI, // 0o455xxx yyyyyy - PDP10.opORCAM, // 0o456xxx yyyyyy - PDP10.opORCAB, // 0o457xxx yyyyyy - PDP10.opSETCM, // 0o460xxx yyyyyy - PDP10.opSETCMI, // 0o461xxx yyyyyy - PDP10.opSETCMM, // 0o462xxx yyyyyy - PDP10.opSETCMB, // 0o463xxx yyyyyy - PDP10.opORCM, // 0o464xxx yyyyyy - PDP10.opORCMI, // 0o465xxx yyyyyy - PDP10.opORCMM, // 0o466xxx yyyyyy - PDP10.opORCMB, // 0o467xxx yyyyyy - PDP10.opORCB, // 0o470xxx yyyyyy - PDP10.opORCBI, // 0o471xxx yyyyyy - PDP10.opORCBM, // 0o472xxx yyyyyy - PDP10.opORCBB, // 0o473xxx yyyyyy - PDP10.opSETO, // 0o474xxx yyyyyy - PDP10.opSETOI, // 0o475xxx yyyyyy - PDP10.opSETOM, // 0o476xxx yyyyyy - PDP10.opSETOB, // 0o477xxx yyyyyy - PDP10.opHLL, // 0o500xxx yyyyyy - PDP10.opHLLI, // 0o501xxx yyyyyy - PDP10.opHLLM, // 0o502xxx yyyyyy - PDP10.opHLLS, // 0o503xxx yyyyyy - PDP10.opHRL, // 0o504xxx yyyyyy - PDP10.opHRLI, // 0o505xxx yyyyyy - PDP10.opHRLM, // 0o506xxx yyyyyy - PDP10.opHRLS, // 0o507xxx yyyyyy - PDP10.opHLLZ, // 0o510xxx yyyyyy - PDP10.opHLLZI, // 0o511xxx yyyyyy - PDP10.opHLLZM, // 0o512xxx yyyyyy - PDP10.opHLLZS, // 0o513xxx yyyyyy - PDP10.opHRLZ, // 0o514xxx yyyyyy - PDP10.opHRLZI, // 0o515xxx yyyyyy - PDP10.opHRLZM, // 0o516xxx yyyyyy - PDP10.opHRLZS, // 0o517xxx yyyyyy - PDP10.opHLLO, // 0o520xxx yyyyyy - PDP10.opHLLOI, // 0o521xxx yyyyyy - PDP10.opHLLOM, // 0o522xxx yyyyyy - PDP10.opHLLOS, // 0o523xxx yyyyyy - PDP10.opHRLO, // 0o524xxx yyyyyy - PDP10.opHRLOI, // 0o525xxx yyyyyy - PDP10.opHRLOM, // 0o526xxx yyyyyy - PDP10.opHRLOS, // 0o527xxx yyyyyy - PDP10.opHLLE, // 0o530xxx yyyyyy - PDP10.opHLLEI, // 0o531xxx yyyyyy - PDP10.opHLLEM, // 0o532xxx yyyyyy - PDP10.opHLLES, // 0o533xxx yyyyyy - PDP10.opHRLE, // 0o534xxx yyyyyy - PDP10.opHRLEI, // 0o535xxx yyyyyy - PDP10.opHRLEM, // 0o536xxx yyyyyy - PDP10.opHRLES, // 0o537xxx yyyyyy - PDP10.opHRR, // 0o540xxx yyyyyy - PDP10.opHRRI, // 0o541xxx yyyyyy - PDP10.opHRRM, // 0o542xxx yyyyyy - PDP10.opHRRS, // 0o543xxx yyyyyy - PDP10.opHLR, // 0o544xxx yyyyyy - PDP10.opHLRI, // 0o545xxx yyyyyy - PDP10.opHLRM, // 0o546xxx yyyyyy - PDP10.opHLRS, // 0o547xxx yyyyyy - PDP10.opHRRZ, // 0o550xxx yyyyyy - PDP10.opHRRZI, // 0o551xxx yyyyyy - PDP10.opHRRZM, // 0o552xxx yyyyyy - PDP10.opHRRZS, // 0o553xxx yyyyyy - PDP10.opHLRZ, // 0o554xxx yyyyyy - PDP10.opHLRZI, // 0o555xxx yyyyyy - PDP10.opHLRZM, // 0o556xxx yyyyyy - PDP10.opHLRZS, // 0o557xxx yyyyyy - PDP10.opHRRO, // 0o560xxx yyyyyy - PDP10.opHRROI, // 0o561xxx yyyyyy - PDP10.opHRROM, // 0o562xxx yyyyyy - PDP10.opHRROS, // 0o563xxx yyyyyy - PDP10.opHLRO, // 0o564xxx yyyyyy - PDP10.opHLROI, // 0o565xxx yyyyyy - PDP10.opHLROM, // 0o566xxx yyyyyy - PDP10.opHLROS, // 0o567xxx yyyyyy - PDP10.opHRRE, // 0o570xxx yyyyyy - PDP10.opHRREI, // 0o571xxx yyyyyy - PDP10.opHRREM, // 0o572xxx yyyyyy - PDP10.opHRRES, // 0o573xxx yyyyyy - PDP10.opHLRE, // 0o574xxx yyyyyy - PDP10.opHLREI, // 0o575xxx yyyyyy - PDP10.opHLREM, // 0o576xxx yyyyyy - PDP10.opHLRES, // 0o577xxx yyyyyy - PDP10.opTRN, // 0o600xxx yyyyyy - PDP10.opTLN, // 0o601xxx yyyyyy - PDP10.opTRNE, // 0o602xxx yyyyyy - PDP10.opTLNE, // 0o603xxx yyyyyy - PDP10.opTRNA, // 0o604xxx yyyyyy - PDP10.opTLNA, // 0o605xxx yyyyyy - PDP10.opTRNN, // 0o606xxx yyyyyy - PDP10.opTLNN, // 0o607xxx yyyyyy - PDP10.opTDN, // 0o610xxx yyyyyy - PDP10.opTSN, // 0o611xxx yyyyyy - PDP10.opTDNE, // 0o612xxx yyyyyy - PDP10.opTSNE, // 0o613xxx yyyyyy - PDP10.opTDNA, // 0o614xxx yyyyyy - PDP10.opTSNA, // 0o615xxx yyyyyy - PDP10.opTDNN, // 0o616xxx yyyyyy - PDP10.opTSNN, // 0o617xxx yyyyyy - PDP10.opTRZ, // 0o620xxx yyyyyy - PDP10.opTLZ, // 0o621xxx yyyyyy - PDP10.opTRZE, // 0o622xxx yyyyyy - PDP10.opTLZE, // 0o623xxx yyyyyy - PDP10.opTRZA, // 0o624xxx yyyyyy - PDP10.opTLZA, // 0o625xxx yyyyyy - PDP10.opTRZN, // 0o626xxx yyyyyy - PDP10.opTLZN, // 0o627xxx yyyyyy - PDP10.opTDZ, // 0o630xxx yyyyyy - PDP10.opTSZ, // 0o631xxx yyyyyy - PDP10.opTDZE, // 0o632xxx yyyyyy - PDP10.opTSZE, // 0o633xxx yyyyyy - PDP10.opTDZA, // 0o634xxx yyyyyy - PDP10.opTSZA, // 0o635xxx yyyyyy - PDP10.opTDZN, // 0o636xxx yyyyyy - PDP10.opTSZN, // 0o637xxx yyyyyy - PDP10.opTRC, // 0o640xxx yyyyyy - PDP10.opTLC, // 0o641xxx yyyyyy - PDP10.opTRCE, // 0o642xxx yyyyyy - PDP10.opTLCE, // 0o643xxx yyyyyy - PDP10.opTRCA, // 0o644xxx yyyyyy - PDP10.opTLCA, // 0o645xxx yyyyyy - PDP10.opTRCN, // 0o646xxx yyyyyy - PDP10.opTLCN, // 0o647xxx yyyyyy - PDP10.opTDC, // 0o650xxx yyyyyy - PDP10.opTSC, // 0o651xxx yyyyyy - PDP10.opTDCE, // 0o652xxx yyyyyy - PDP10.opTSCE, // 0o653xxx yyyyyy - PDP10.opTDCA, // 0o654xxx yyyyyy - PDP10.opTSCA, // 0o655xxx yyyyyy - PDP10.opTDCN, // 0o656xxx yyyyyy - PDP10.opTSCN, // 0o657xxx yyyyyy - PDP10.opTRO, // 0o660xxx yyyyyy - PDP10.opTLO, // 0o661xxx yyyyyy - PDP10.opTROE, // 0o662xxx yyyyyy - PDP10.opTLOE, // 0o663xxx yyyyyy - PDP10.opTROA, // 0o664xxx yyyyyy - PDP10.opTLOA, // 0o665xxx yyyyyy - PDP10.opTRON, // 0o666xxx yyyyyy - PDP10.opTLON, // 0o667xxx yyyyyy - PDP10.opTDO, // 0o670xxx yyyyyy - PDP10.opTSO, // 0o671xxx yyyyyy - PDP10.opTDOE, // 0o672xxx yyyyyy - PDP10.opTSOE, // 0o673xxx yyyyyy - PDP10.opTDOA, // 0o674xxx yyyyyy - PDP10.opTSOA, // 0o675xxx yyyyyy - PDP10.opTDON, // 0o676xxx yyyyyy - PDP10.opTSON, // 0o677xxx yyyyyy - PDP10.opIO, // 0o700xxx yyyyyy - PDP10.opIO, // 0o701xxx yyyyyy - PDP10.opIO, // 0o702xxx yyyyyy - PDP10.opIO, // 0o703xxx yyyyyy - PDP10.opIO, // 0o704xxx yyyyyy - PDP10.opIO, // 0o705xxx yyyyyy - PDP10.opIO, // 0o706xxx yyyyyy - PDP10.opIO, // 0o707xxx yyyyyy - PDP10.opIO, // 0o710xxx yyyyyy - PDP10.opIO, // 0o711xxx yyyyyy - PDP10.opIO, // 0o712xxx yyyyyy - PDP10.opIO, // 0o713xxx yyyyyy - PDP10.opIO, // 0o714xxx yyyyyy - PDP10.opIO, // 0o715xxx yyyyyy - PDP10.opIO, // 0o716xxx yyyyyy - PDP10.opIO, // 0o717xxx yyyyyy - PDP10.opIO, // 0o720xxx yyyyyy - PDP10.opIO, // 0o721xxx yyyyyy - PDP10.opIO, // 0o722xxx yyyyyy - PDP10.opIO, // 0o723xxx yyyyyy - PDP10.opIO, // 0o724xxx yyyyyy - PDP10.opIO, // 0o725xxx yyyyyy - PDP10.opIO, // 0o726xxx yyyyyy - PDP10.opIO, // 0o727xxx yyyyyy - PDP10.opIO, // 0o730xxx yyyyyy - PDP10.opIO, // 0o731xxx yyyyyy - PDP10.opIO, // 0o732xxx yyyyyy - PDP10.opIO, // 0o733xxx yyyyyy - PDP10.opIO, // 0o734xxx yyyyyy - PDP10.opIO, // 0o735xxx yyyyyy - PDP10.opIO, // 0o736xxx yyyyyy - PDP10.opIO, // 0o737xxx yyyyyy - PDP10.opIO, // 0o740xxx yyyyyy - PDP10.opIO, // 0o741xxx yyyyyy - PDP10.opIO, // 0o742xxx yyyyyy - PDP10.opIO, // 0o743xxx yyyyyy - PDP10.opIO, // 0o744xxx yyyyyy - PDP10.opIO, // 0o745xxx yyyyyy - PDP10.opIO, // 0o746xxx yyyyyy - PDP10.opIO, // 0o747xxx yyyyyy - PDP10.opIO, // 0o750xxx yyyyyy - PDP10.opIO, // 0o751xxx yyyyyy - PDP10.opIO, // 0o752xxx yyyyyy - PDP10.opIO, // 0o753xxx yyyyyy - PDP10.opIO, // 0o754xxx yyyyyy - PDP10.opIO, // 0o755xxx yyyyyy - PDP10.opIO, // 0o756xxx yyyyyy - PDP10.opIO, // 0o757xxx yyyyyy - PDP10.opIO, // 0o760xxx yyyyyy - PDP10.opIO, // 0o761xxx yyyyyy - PDP10.opIO, // 0o762xxx yyyyyy - PDP10.opIO, // 0o763xxx yyyyyy - PDP10.opIO, // 0o764xxx yyyyyy - PDP10.opIO, // 0o765xxx yyyyyy - PDP10.opIO, // 0o766xxx yyyyyy - PDP10.opIO, // 0o767xxx yyyyyy - PDP10.opIO, // 0o770xxx yyyyyy - PDP10.opIO, // 0o771xxx yyyyyy - PDP10.opIO, // 0o772xxx yyyyyy - PDP10.opIO, // 0o773xxx yyyyyy - PDP10.opIO, // 0o774xxx yyyyyy - PDP10.opIO, // 0o775xxx yyyyyy - PDP10.opIO, // 0o776xxx yyyyyy - PDP10.opIO // 0o777xxx yyyyyy + PDP10.opUUO, // 0o000xxx + PDP10.opUUO, // 0o001xxx + PDP10.opUUO, // 0o002xxx + PDP10.opUUO, // 0o003xxx + PDP10.opUUO, // 0o004xxx + PDP10.opUUO, // 0o005xxx + PDP10.opUUO, // 0o006xxx + PDP10.opUUO, // 0o007xxx + PDP10.opUUO, // 0o010xxx + PDP10.opUUO, // 0o011xxx + PDP10.opUUO, // 0o012xxx + PDP10.opUUO, // 0o013xxx + PDP10.opUUO, // 0o014xxx + PDP10.opUUO, // 0o015xxx + PDP10.opUUO, // 0o016xxx + PDP10.opUUO, // 0o017xxx + PDP10.opUUO, // 0o020xxx + PDP10.opUUO, // 0o021xxx + PDP10.opUUO, // 0o022xxx + PDP10.opUUO, // 0o023xxx + PDP10.opUUO, // 0o024xxx + PDP10.opUUO, // 0o025xxx + PDP10.opUUO, // 0o026xxx + PDP10.opUUO, // 0o027xxx + PDP10.opUUO, // 0o030xxx + PDP10.opUUO, // 0o031xxx + PDP10.opUUO, // 0o032xxx + PDP10.opUUO, // 0o033xxx + PDP10.opUUO, // 0o034xxx + PDP10.opUUO, // 0o035xxx + PDP10.opUUO, // 0o036xxx + PDP10.opUUO, // 0o037xxx + PDP10.opUUO, // 0o040xxx + PDP10.opUUO, // 0o041xxx + PDP10.opUUO, // 0o042xxx + PDP10.opUUO, // 0o043xxx + PDP10.opUUO, // 0o044xxx + PDP10.opUUO, // 0o045xxx + PDP10.opUUO, // 0o046xxx + PDP10.opUUO, // 0o047xxx + PDP10.opUUO, // 0o050xxx + PDP10.opUUO, // 0o051xxx + PDP10.opUUO, // 0o052xxx + PDP10.opUUO, // 0o053xxx + PDP10.opUUO, // 0o054xxx + PDP10.opUUO, // 0o055xxx + PDP10.opUUO, // 0o056xxx + PDP10.opUUO, // 0o057xxx + PDP10.opUUO, // 0o060xxx + PDP10.opUUO, // 0o061xxx + PDP10.opUUO, // 0o062xxx + PDP10.opUUO, // 0o063xxx + PDP10.opUUO, // 0o064xxx + PDP10.opUUO, // 0o065xxx + PDP10.opUUO, // 0o066xxx + PDP10.opUUO, // 0o067xxx + PDP10.opUUO, // 0o070xxx + PDP10.opUUO, // 0o071xxx + PDP10.opUUO, // 0o072xxx + PDP10.opUUO, // 0o073xxx + PDP10.opUUO, // 0o074xxx + PDP10.opUUO, // 0o075xxx + PDP10.opUUO, // 0o076xxx + PDP10.opUUO, // 0o077xxx + PDP10.opUndefined, // 0o100xxx + PDP10.opUndefined, // 0o101xxx + PDP10.opUndefined, // 0o102xxx + PDP10.opUndefined, // 0o103xxx + PDP10.opUndefined, // 0o104xxx + PDP10.opUndefined, // 0o105xxx + PDP10.opUndefined, // 0o106xxx + PDP10.opUndefined, // 0o107xxx + PDP10.opUndefined, // 0o110xxx + PDP10.opUndefined, // 0o111xxx + PDP10.opUndefined, // 0o112xxx + PDP10.opUndefined, // 0o113xxx + PDP10.opUndefined, // 0o114xxx + PDP10.opUndefined, // 0o115xxx + PDP10.opUndefined, // 0o116xxx + PDP10.opUndefined, // 0o117xxx + PDP10.opUndefined, // 0o120xxx + PDP10.opUndefined, // 0o121xxx + PDP10.opUndefined, // 0o122xxx + PDP10.opUndefined, // 0o123xxx + PDP10.opUndefined, // 0o124xxx + PDP10.opUndefined, // 0o125xxx + PDP10.opUndefined, // 0o126xxx + PDP10.opUndefined, // 0o127xxx + PDP10.opUFA, // 0o130xxx + PDP10.opDFN, // 0o131xxx + PDP10.opFSC, // 0o132xxx + PDP10.opIBP, // 0o133xxx + PDP10.opILDB, // 0o134xxx + PDP10.opLDB, // 0o135xxx + PDP10.opIDPB, // 0o136xxx + PDP10.opDPB, // 0o137xxx + PDP10.opFAD, // 0o140xxx + PDP10.opFADI, // 0o141xxx + PDP10.opFADM, // 0o142xxx + PDP10.opFADB, // 0o143xxx + PDP10.opFADR, // 0o144xxx + PDP10.opFADRI, // 0o145xxx + PDP10.opFADRM, // 0o146xxx + PDP10.opFADRB, // 0o147xxx + PDP10.opFSB, // 0o150xxx + PDP10.opFSBI, // 0o151xxx + PDP10.opFSBM, // 0o152xxx + PDP10.opFSBB, // 0o153xxx + PDP10.opFSBR, // 0o154xxx + PDP10.opFSBRI, // 0o155xxx + PDP10.opFSBRM, // 0o156xxx + PDP10.opFSBRB, // 0o157xxx + PDP10.opFMP, // 0o160xxx + PDP10.opFMPI, // 0o161xxx + PDP10.opFMPM, // 0o162xxx + PDP10.opFMPB, // 0o163xxx + PDP10.opFMPR, // 0o164xxx + PDP10.opFMPRI, // 0o165xxx + PDP10.opFMPRM, // 0o166xxx + PDP10.opFMPRB, // 0o167xxx + PDP10.opFDV, // 0o170xxx + PDP10.opFDVI, // 0o171xxx + PDP10.opFDVM, // 0o172xxx + PDP10.opFDVB, // 0o173xxx + PDP10.opFDVR, // 0o174xxx + PDP10.opFDVRI, // 0o175xxx + PDP10.opFDVRM, // 0o176xxx + PDP10.opFDVRB, // 0o177xxx + PDP10.opMOV, // 0o200xxx + PDP10.opMOVI, // 0o201xxx + PDP10.opMOVM, // 0o202xxx + PDP10.opMOVS, // 0o203xxx + PDP10.opMOVS, // 0o204xxx + PDP10.opMOVSI, // 0o205xxx + PDP10.opMOVSM, // 0o206xxx + PDP10.opMOVSS, // 0o207xxx + PDP10.opMOVN, // 0o210xxx + PDP10.opMOVNI, // 0o211xxx + PDP10.opMOVNM, // 0o212xxx + PDP10.opMOVNS, // 0o213xxx + PDP10.opMOVM, // 0o214xxx + PDP10.opMOVMI, // 0o215xxx + PDP10.opMOVMM, // 0o216xxx + PDP10.opMOVMS, // 0o217xxx + PDP10.opIMUL, // 0o220xxx + PDP10.opIMULI, // 0o221xxx + PDP10.opIMULM, // 0o222xxx + PDP10.opIMULB, // 0o223xxx + PDP10.opMUL, // 0o224xxx + PDP10.opMULI, // 0o225xxx + PDP10.opMULM, // 0o226xxx + PDP10.opMULB, // 0o227xxx + PDP10.opIDIV, // 0o230xxx + PDP10.opIDIVI, // 0o231xxx + PDP10.opIDIVM, // 0o232xxx + PDP10.opIDIVB, // 0o233xxx + PDP10.opDIV, // 0o234xxx + PDP10.opDIVI, // 0o235xxx + PDP10.opDIVM, // 0o236xxx + PDP10.opDIVB, // 0o237xxx + PDP10.opASH, // 0o240xxx + PDP10.opROT, // 0o241xxx + PDP10.opLSH, // 0o242xxx + PDP10.opJFFO, // 0o243xxx + PDP10.opASHC, // 0o244xxx + PDP10.opROTC, // 0o245xxx + PDP10.opLSHC, // 0o246xxx + PDP10.opUndefined, // 0o247xxx + PDP10.opEXCH, // 0o250xxx + PDP10.opBLT, // 0o251xxx + PDP10.opAOBJP, // 0o252xxx + PDP10.opAOBJN, // 0o253xxx + PDP10.opJRST, // 0o254xxx + PDP10.opJFCL, // 0o255xxx + PDP10.opXCT, // 0o256xxx + PDP10.opUndefined, // 0o257xxx + PDP10.opPUSHJ, // 0o260xxx + PDP10.opPUSH, // 0o261xxx + PDP10.opPOP, // 0o262xxx + PDP10.opPOPJ, // 0o263xxx + PDP10.opJSR, // 0o264xxx + PDP10.opJSP, // 0o265xxx + PDP10.opJSA, // 0o266xxx + PDP10.opJRA, // 0o267xxx + PDP10.opADD, // 0o270xxx + PDP10.opADDI, // 0o271xxx + PDP10.opADDM, // 0o272xxx + PDP10.opADDB, // 0o273xxx + PDP10.opSUB, // 0o274xxx + PDP10.opSUBI, // 0o275xxx + PDP10.opSUBM, // 0o276xxx + PDP10.opSUBB, // 0o277xxx + PDP10.opCAI, // 0o300xxx + PDP10.opCAIL, // 0o301xxx + PDP10.opCAIE, // 0o302xxx + PDP10.opCAILE, // 0o303xxx + PDP10.opCAIA, // 0o304xxx + PDP10.opCAIGE, // 0o305xxx + PDP10.opCAIN, // 0o306xxx + PDP10.opCAIG, // 0o307xxx + PDP10.opCA, // 0o310xxx + PDP10.opCAL, // 0o311xxx + PDP10.opCAE, // 0o312xxx + PDP10.opCALE, // 0o313xxx + PDP10.opCAA, // 0o314xxx + PDP10.opCAGE, // 0o315xxx + PDP10.opCAN, // 0o316xxx + PDP10.opCAG, // 0o317xxx + PDP10.opJUMP, // 0o320xxx + PDP10.opJUMPL, // 0o321xxx + PDP10.opJUMPE, // 0o322xxx + PDP10.opJUMPLE, // 0o323xxx + PDP10.opJUMPA, // 0o324xxx + PDP10.opJUMPGE, // 0o325xxx + PDP10.opJUMPN, // 0o326xxx + PDP10.opJUMPG, // 0o327xxx + PDP10.opSKIP, // 0o330xxx + PDP10.opSKIPL, // 0o331xxx + PDP10.opSKIPE, // 0o332xxx + PDP10.opSKIPLE, // 0o333xxx + PDP10.opSKIPA, // 0o334xxx + PDP10.opSKIPGE, // 0o335xxx + PDP10.opSKIPN, // 0o336xxx + PDP10.opSKIPG, // 0o337xxx + PDP10.opAOJ, // 0o340xxx + PDP10.opAOJL, // 0o341xxx + PDP10.opAOJE, // 0o342xxx + PDP10.opAOJLE, // 0o343xxx + PDP10.opAOJA, // 0o344xxx + PDP10.opAOJGE, // 0o345xxx + PDP10.opAOJN, // 0o346xxx + PDP10.opAOJG, // 0o347xxx + PDP10.opAOS, // 0o350xxx + PDP10.opAOSL, // 0o351xxx + PDP10.opAOSE, // 0o352xxx + PDP10.opAOSLE, // 0o353xxx + PDP10.opAOSA, // 0o354xxx + PDP10.opAOSGE, // 0o355xxx + PDP10.opAOSN, // 0o356xxx + PDP10.opAOSG, // 0o357xxx + PDP10.opSOJ, // 0o360xxx + PDP10.opSOJL, // 0o361xxx + PDP10.opSOJE, // 0o362xxx + PDP10.opSOJLE, // 0o363xxx + PDP10.opSOJA, // 0o364xxx + PDP10.opSOJGE, // 0o365xxx + PDP10.opSOJN, // 0o366xxx + PDP10.opSOJG, // 0o367xxx + PDP10.opSOS, // 0o370xxx + PDP10.opSOSL, // 0o371xxx + PDP10.opSOSE, // 0o372xxx + PDP10.opSOSLE, // 0o373xxx + PDP10.opSOSA, // 0o374xxx + PDP10.opSOSGE, // 0o375xxx + PDP10.opSOSN, // 0o376xxx + PDP10.opSOSG, // 0o377xxx + PDP10.opSETZ, // 0o400xxx + PDP10.opSETZI, // 0o401xxx + PDP10.opSETZM, // 0o402xxx + PDP10.opSETZB, // 0o403xxx + PDP10.opAND, // 0o404xxx + PDP10.opANDI, // 0o405xxx + PDP10.opANDM, // 0o406xxx + PDP10.opANDB, // 0o407xxx + PDP10.opANDCA, // 0o410xxx + PDP10.opANDCAI, // 0o411xxx + PDP10.opANDCAM, // 0o412xxx + PDP10.opANDCAB, // 0o413xxx + PDP10.opSETM, // 0o414xxx + PDP10.opSETMI, // 0o415xxx + PDP10.opSETMM, // 0o416xxx + PDP10.opSETMB, // 0o417xxx + PDP10.opANDCM, // 0o420xxx + PDP10.opANDCMI, // 0o421xxx + PDP10.opANDCMM, // 0o422xxx + PDP10.opANDCMB, // 0o423xxx + PDP10.opSETA, // 0o424xxx + PDP10.opSETAI, // 0o425xxx + PDP10.opSETAM, // 0o426xxx + PDP10.opSETAB, // 0o427xxx + PDP10.opXOR, // 0o430xxx + PDP10.opXORI, // 0o431xxx + PDP10.opXORM, // 0o432xxx + PDP10.opXORB, // 0o433xxx + PDP10.opIOR, // 0o434xxx + PDP10.opIORI, // 0o435xxx + PDP10.opIORM, // 0o436xxx + PDP10.opIORB, // 0o437xxx + PDP10.opANDCB, // 0o440xxx + PDP10.opANDCBI, // 0o441xxx + PDP10.opANDCBM, // 0o442xxx + PDP10.opANDCBB, // 0o443xxx + PDP10.opEQV, // 0o444xxx + PDP10.opEQVI, // 0o445xxx + PDP10.opEQVM, // 0o446xxx + PDP10.opEQVB, // 0o447xxx + PDP10.opSETCA, // 0o450xxx + PDP10.opSETCAI, // 0o451xxx + PDP10.opSETCAM, // 0o452xxx + PDP10.opSETCAB, // 0o453xxx + PDP10.opORCA, // 0o454xxx + PDP10.opORCAI, // 0o455xxx + PDP10.opORCAM, // 0o456xxx + PDP10.opORCAB, // 0o457xxx + PDP10.opSETCM, // 0o460xxx + PDP10.opSETCMI, // 0o461xxx + PDP10.opSETCMM, // 0o462xxx + PDP10.opSETCMB, // 0o463xxx + PDP10.opORCM, // 0o464xxx + PDP10.opORCMI, // 0o465xxx + PDP10.opORCMM, // 0o466xxx + PDP10.opORCMB, // 0o467xxx + PDP10.opORCB, // 0o470xxx + PDP10.opORCBI, // 0o471xxx + PDP10.opORCBM, // 0o472xxx + PDP10.opORCBB, // 0o473xxx + PDP10.opSETO, // 0o474xxx + PDP10.opSETOI, // 0o475xxx + PDP10.opSETOM, // 0o476xxx + PDP10.opSETOB, // 0o477xxx + PDP10.opHLL, // 0o500xxx + PDP10.opHLLI, // 0o501xxx + PDP10.opHLLM, // 0o502xxx + PDP10.opHLLS, // 0o503xxx + PDP10.opHRL, // 0o504xxx + PDP10.opHRLI, // 0o505xxx + PDP10.opHRLM, // 0o506xxx + PDP10.opHRLS, // 0o507xxx + PDP10.opHLLZ, // 0o510xxx + PDP10.opHLLZI, // 0o511xxx + PDP10.opHLLZM, // 0o512xxx + PDP10.opHLLZS, // 0o513xxx + PDP10.opHRLZ, // 0o514xxx + PDP10.opHRLZI, // 0o515xxx + PDP10.opHRLZM, // 0o516xxx + PDP10.opHRLZS, // 0o517xxx + PDP10.opHLLO, // 0o520xxx + PDP10.opHLLOI, // 0o521xxx + PDP10.opHLLOM, // 0o522xxx + PDP10.opHLLOS, // 0o523xxx + PDP10.opHRLO, // 0o524xxx + PDP10.opHRLOI, // 0o525xxx + PDP10.opHRLOM, // 0o526xxx + PDP10.opHRLOS, // 0o527xxx + PDP10.opHLLE, // 0o530xxx + PDP10.opHLLEI, // 0o531xxx + PDP10.opHLLEM, // 0o532xxx + PDP10.opHLLES, // 0o533xxx + PDP10.opHRLE, // 0o534xxx + PDP10.opHRLEI, // 0o535xxx + PDP10.opHRLEM, // 0o536xxx + PDP10.opHRLES, // 0o537xxx + PDP10.opHRR, // 0o540xxx + PDP10.opHRRI, // 0o541xxx + PDP10.opHRRM, // 0o542xxx + PDP10.opHRRS, // 0o543xxx + PDP10.opHLR, // 0o544xxx + PDP10.opHLRI, // 0o545xxx + PDP10.opHLRM, // 0o546xxx + PDP10.opHLRS, // 0o547xxx + PDP10.opHRRZ, // 0o550xxx + PDP10.opHRRZI, // 0o551xxx + PDP10.opHRRZM, // 0o552xxx + PDP10.opHRRZS, // 0o553xxx + PDP10.opHLRZ, // 0o554xxx + PDP10.opHLRZI, // 0o555xxx + PDP10.opHLRZM, // 0o556xxx + PDP10.opHLRZS, // 0o557xxx + PDP10.opHRRO, // 0o560xxx + PDP10.opHRROI, // 0o561xxx + PDP10.opHRROM, // 0o562xxx + PDP10.opHRROS, // 0o563xxx + PDP10.opHLRO, // 0o564xxx + PDP10.opHLROI, // 0o565xxx + PDP10.opHLROM, // 0o566xxx + PDP10.opHLROS, // 0o567xxx + PDP10.opHRRE, // 0o570xxx + PDP10.opHRREI, // 0o571xxx + PDP10.opHRREM, // 0o572xxx + PDP10.opHRRES, // 0o573xxx + PDP10.opHLRE, // 0o574xxx + PDP10.opHLREI, // 0o575xxx + PDP10.opHLREM, // 0o576xxx + PDP10.opHLRES, // 0o577xxx + PDP10.opTRN, // 0o600xxx + PDP10.opTLN, // 0o601xxx + PDP10.opTRNE, // 0o602xxx + PDP10.opTLNE, // 0o603xxx + PDP10.opTRNA, // 0o604xxx + PDP10.opTLNA, // 0o605xxx + PDP10.opTRNN, // 0o606xxx + PDP10.opTLNN, // 0o607xxx + PDP10.opTDN, // 0o610xxx + PDP10.opTSN, // 0o611xxx + PDP10.opTDNE, // 0o612xxx + PDP10.opTSNE, // 0o613xxx + PDP10.opTDNA, // 0o614xxx + PDP10.opTSNA, // 0o615xxx + PDP10.opTDNN, // 0o616xxx + PDP10.opTSNN, // 0o617xxx + PDP10.opTRZ, // 0o620xxx + PDP10.opTLZ, // 0o621xxx + PDP10.opTRZE, // 0o622xxx + PDP10.opTLZE, // 0o623xxx + PDP10.opTRZA, // 0o624xxx + PDP10.opTLZA, // 0o625xxx + PDP10.opTRZN, // 0o626xxx + PDP10.opTLZN, // 0o627xxx + PDP10.opTDZ, // 0o630xxx + PDP10.opTSZ, // 0o631xxx + PDP10.opTDZE, // 0o632xxx + PDP10.opTSZE, // 0o633xxx + PDP10.opTDZA, // 0o634xxx + PDP10.opTSZA, // 0o635xxx + PDP10.opTDZN, // 0o636xxx + PDP10.opTSZN, // 0o637xxx + PDP10.opTRC, // 0o640xxx + PDP10.opTLC, // 0o641xxx + PDP10.opTRCE, // 0o642xxx + PDP10.opTLCE, // 0o643xxx + PDP10.opTRCA, // 0o644xxx + PDP10.opTLCA, // 0o645xxx + PDP10.opTRCN, // 0o646xxx + PDP10.opTLCN, // 0o647xxx + PDP10.opTDC, // 0o650xxx + PDP10.opTSC, // 0o651xxx + PDP10.opTDCE, // 0o652xxx + PDP10.opTSCE, // 0o653xxx + PDP10.opTDCA, // 0o654xxx + PDP10.opTSCA, // 0o655xxx + PDP10.opTDCN, // 0o656xxx + PDP10.opTSCN, // 0o657xxx + PDP10.opTRO, // 0o660xxx + PDP10.opTLO, // 0o661xxx + PDP10.opTROE, // 0o662xxx + PDP10.opTLOE, // 0o663xxx + PDP10.opTROA, // 0o664xxx + PDP10.opTLOA, // 0o665xxx + PDP10.opTRON, // 0o666xxx + PDP10.opTLON, // 0o667xxx + PDP10.opTDO, // 0o670xxx + PDP10.opTSO, // 0o671xxx + PDP10.opTDOE, // 0o672xxx + PDP10.opTSOE, // 0o673xxx + PDP10.opTDOA, // 0o674xxx + PDP10.opTSOA, // 0o675xxx + PDP10.opTDON, // 0o676xxx + PDP10.opTSON, // 0o677xxx + PDP10.opIO, // 0o700xx + PDP10.opIO, // 0o701xxx + PDP10.opIO, // 0o702xxx + PDP10.opIO, // 0o703xxx + PDP10.opIO, // 0o704xxx + PDP10.opIO, // 0o705xxx + PDP10.opIO, // 0o706xxx + PDP10.opIO, // 0o707xxx + PDP10.opIO, // 0o710xxx + PDP10.opIO, // 0o711xxx + PDP10.opIO, // 0o712xxx + PDP10.opIO, // 0o713xxx + PDP10.opIO, // 0o714xxx + PDP10.opIO, // 0o715xxx + PDP10.opIO, // 0o716xxx + PDP10.opIO, // 0o717xxx + PDP10.opIO, // 0o720xxx + PDP10.opIO, // 0o721xxx + PDP10.opIO, // 0o722xxx + PDP10.opIO, // 0o723xxx + PDP10.opIO, // 0o724xxx + PDP10.opIO, // 0o725xxx + PDP10.opIO, // 0o726xxx + PDP10.opIO, // 0o727xxx + PDP10.opIO, // 0o730xxx + PDP10.opIO, // 0o731xxx + PDP10.opIO, // 0o732xxx + PDP10.opIO, // 0o733xxx + PDP10.opIO, // 0o734xxx + PDP10.opIO, // 0o735xxx + PDP10.opIO, // 0o736xxx + PDP10.opIO, // 0o737xxx + PDP10.opIO, // 0o740xxx + PDP10.opIO, // 0o741xxx + PDP10.opIO, // 0o742xxx + PDP10.opIO, // 0o743xxx + PDP10.opIO, // 0o744xxx + PDP10.opIO, // 0o745xxx + PDP10.opIO, // 0o746xxx + PDP10.opIO, // 0o747xxx + PDP10.opIO, // 0o750xxx + PDP10.opIO, // 0o751xxx + PDP10.opIO, // 0o752xxx + PDP10.opIO, // 0o753xxx + PDP10.opIO, // 0o754xxx + PDP10.opIO, // 0o755xxx + PDP10.opIO, // 0o756xxx + PDP10.opIO, // 0o757xxx + PDP10.opIO, // 0o760xxx + PDP10.opIO, // 0o761xxx + PDP10.opIO, // 0o762xxx + PDP10.opIO, // 0o763xxx + PDP10.opIO, // 0o764xxx + PDP10.opIO, // 0o765xxx + PDP10.opIO, // 0o766xxx + PDP10.opIO, // 0o767xxx + PDP10.opIO, // 0o770xxx + PDP10.opIO, // 0o771xxx + PDP10.opIO, // 0o772xxx + PDP10.opIO, // 0o773xxx + PDP10.opIO, // 0o774xxx + PDP10.opIO, // 0o775xxx + PDP10.opIO, // 0o776xxx + PDP10.opIO // 0o777xxx ]; diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index 6ced96a13..5cbba2e77 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -124,6 +124,9 @@ class CPUStatePDP10 extends CPUPDP10 { this.model = model; this.addrReset = +parmsCPU['addrReset'] || 0; + this.opDecode = PDP10.opKA10.bind(this); + this.opUndefined = PDP10.opUndefined.bind(this); + /** @type {IRQ|null} */ this.irqNext = null; // the head of the active IRQ list, in priority order @@ -171,7 +174,8 @@ class CPUStatePDP10 extends CPUPDP10 { */ initCPU() { - this.regPC = this.pcLast = this.addrReset; + this.regEA = 0; + this.regPC = this.lastPC = this.addrReset; /* * This is queried and displayed by the Panel when it's not displaying its own ADDRESS register @@ -180,7 +184,7 @@ class CPUStatePDP10 extends CPUPDP10 { * * We initialize it to the current PC. */ - this.addrLast = this.regPC; + this.lastAddr = this.regPC; /* * opFlags contains various conditions that stepCPU() needs to be aware of. @@ -272,9 +276,10 @@ class CPUStatePDP10 extends CPUPDP10 { { var state = new State(this); state.set(0, [ + this.regEA, this.regPC, - this.pcLast, - this.addrLast, + this.lastPC, + this.lastAddr, this.opFlags ]); state.set(1, []); @@ -298,9 +303,10 @@ class CPUStatePDP10 extends CPUPDP10 { * of what save() does when it collects a bunch of object properties into an array. */ [ + this.regEA, this.regPC, - this.pcLast, - this.addrLast, + this.lastPC, + this.lastAddr, this.opFlags ] = data[0]; @@ -317,17 +323,44 @@ class CPUStatePDP10 extends CPUPDP10 { /** * getOpcode() * - * NOTE: This function is nothing more than a convenience, and we fully expect it to be inlined at runtime. + * This fetches the next opcode, decodes the low 23 bits (I,X,Y), sets regEA, and returns the + * the high 18 bits for further decoding. While it's true that, in general, only the high 13 bits + * are relevant to the operation, it's cleaner to treat the original opcode as two half-words. * * @this {CPUStatePDP10} * @return {number} */ getOpcode() { - var pc = this.pcLast = this.regPC; + var pc = this.lastPC = this.regPC; var opCode = this.readWord(pc); this.regPC = (pc + 1) % PDP10.ADDR_LIMIT; - return opCode; + var e, x, r = opCode, nMaxIndirect = 4; + while (true) { + /* + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the + * "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E to Y, + * then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R to [E] + * and repeat the process. + */ + e = r & PDP10.OPCODE.Y_MASK; + x = (r >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; + if (x) e = (e + this.readWord(x)) & PDP10.ADDR_MASK; + if (!(r & PDP10.OPCODE.I_BIT)) break; + /* + * We allow this process to repeat only a few times, because more than that suggests we're executing + * garbage. Also, allowing this to loop endlessly would hang the simulation; if it turns out there is + * real-world PDP-10 code that requires a long series of indirections, we should factor this logic out + * as a separate operation. Note that would mean passing the full opcode on to the next level of decoding. + */ + if (--nMaxIndirect < 0) { + this.bus.fault(r); + break; + } + r = this.readWord(e); + } + this.regEA = e; + return (opCode / PDP10.ADDR_LIMIT)|0; } /** @@ -367,7 +400,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ getLastAddr() { - return this.addrLast; + return this.lastAddr; } /** @@ -378,7 +411,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ getLastPC() { - return this.pcLast; + return this.lastPC; } /** @@ -659,7 +692,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ readWordFromPhysical(addr) { - return this.bus.getWord(this.addrLast = addr); + return this.bus.getWord(this.lastAddr = addr); } /** @@ -673,7 +706,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ writeWordToPhysical(addr, data) { - this.bus.setWord(this.addrLast = addr, data); + this.bus.setWord(this.lastAddr = addr, data); } /** @@ -775,8 +808,7 @@ class CPUStatePDP10 extends CPUPDP10 { this.opFlags &= PDP10.OPFLAG.PRESERVE; var opCode = this.getOpcode(); - - // this.decode(opCode); + this.opDecode(opCode); } while (this.nStepCycles > 0); diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 58f52b949..0e7d0d300 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -97,6 +97,7 @@ var PDP10 = { */ ADDR_INVALID: -1, ADDR_LIMIT: Math.pow(2, 18), + ADDR_MASK: Math.pow(2, 18) - 1, DATA_INVALID: -1, DATA_LIMIT: Math.pow(2, 36), @@ -128,10 +129,10 @@ var PDP10 = { * 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 * 1 1 1 D D D D D D D O O O I X X X X Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y Y * - * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to - * calculate the "effective address" (E). To determine E from R, we must extract I, X, - * and Y from R, set E to Y, then add [X] to E if X is non-zero. If I is zero, then - * we're done; otherwise, we must set set R to [E] and repeat the process. + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the + * "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E to Y, + * then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R to [E] + * and repeat the process. */ OPCODE: { OPMASK: 0o77700, // operation mask @@ -145,8 +146,6 @@ var PDP10 = { FNMASK: 0o17, // accumulator/function mask (after shift) IOSHIFT: Math.pow(2, 26), // input-output device code shift IOMASK: 0o177, // input-output device code mask (after shift) - O_SHIFT: Math.pow(2, 27), // operation shift - O_MASK: 0o777, // operation mask (after shift) I_BIT: 0o20000000, // indirect bit X_SHIFT: 18, // X shift X_MASK: 0o17, // X mask (after shift) diff --git a/modules/pdp11/lib/cpustate.js b/modules/pdp11/lib/cpustate.js index c85c84953..bed89badc 100644 --- a/modules/pdp11/lib/cpustate.js +++ b/modules/pdp11/lib/cpustate.js @@ -167,14 +167,14 @@ class CPUStatePDP11 extends CPUPDP11 { this.maskRegSrcByte = 0xff; if (this.model <= PDP11.MODEL_1120) { - this.decode = PDP11.op1120.bind(this); + this.opDecode = PDP11.op1120.bind(this); this.checkStackLimit = this.checkStackLimit1120; this.offRegSrc = 8; this.maskRegSrcByte = -1; this.pswUsed = ~(PDP11.PSW.UNUSED | PDP11.PSW.REGSET | PDP11.PSW.PMODE | PDP11.PSW.CMODE) & 0xffff; this.pswRegSet = 0; } else { - this.decode = PDP11.op1140.bind(this); + this.opDecode = PDP11.op1140.bind(this); this.checkStackLimit = this.checkStackLimit1140; /* * The alternate register set (REGSET) doesn't exist on the 11/20 or 11/40; it's available on the 11/45 and 11/70. @@ -3058,7 +3058,7 @@ class CPUStatePDP11 extends CPUPDP11 { this.opFlags = (this.opFlags & PDP11.OPFLAG.PRESERVE) | (this.regPSW & PDP11.PSW.TF); var opCode = this.getOpcode(); - this.decode(opCode); + this.opDecode(opCode); } while (this.nStepCycles > 0); From 0451774bc6c05a060cee283b4ac110fddea09753 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Sun, 26 Feb 2017 09:25:44 -0800 Subject: [PATCH 14/30] Added preliminary PDP-10 opcode decoding --- modules/pdp10/lib/cpuops.js | 100 ++++---- versions/pdpjs/1.34.0/pdp10-dbg.js | 357 +++++++++++++++-------------- versions/pdpjs/1.34.0/pdp10.js | 214 +++++++++-------- versions/pdpjs/1.34.0/pdp11-dbg.js | 26 +-- versions/pdpjs/1.34.0/pdp11.js | 28 +-- 5 files changed, 380 insertions(+), 345 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index f12196cb2..a446a766f 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -38,22 +38,22 @@ if (NODE) { * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-64: * - * Store the instruction code, A and the effective address E in bits 0-8, 9-12 and 18-35 respectively of - * location 40; clear bits 13-17. Execute the instruction contained in location 41. The original contents - * of location 40 are lost. + * Store the instruction code, A and the effective address E in bits 0-8, 9-12 and 18-35 respectively of + * location 40; clear bits 13-17. Execute the instruction contained in location 41. The original contents + * of location 40 are lost. * - * All of these codes are equivalent when they occur in the Monitor or when time sharing is not in effect. - * But when a UUO appears in a user program, a code in the range 001-037 uses relocated locations 40 and 41 - * (ie 40 and 41 in the user's block) and is thus entirely a part of and under control of the user program. + * All of these codes are equivalent when they occur in the Monitor or when time sharing is not in effect. + * But when a UUO appears in a user program, a code in the range 001-037 uses relocated locations 40 and 41 + * (ie 40 and 41 in the user's block) and is thus entirely a part of and under control of the user program. * - * A code in the range 040-077 on the other hand uses unrelocated 40 and 41, and the instruction in the latter - * location is under control of the Monitor; these codes are thus specifically for user communication with - * the Monitor, which interprets them (refer to the Monitor manual for the meanings of the various codes). + * A code in the range 040-077 on the other hand uses unrelocated 40 and 41, and the instruction in the latter + * location is under control of the Monitor; these codes are thus specifically for user communication with + * the Monitor, which interprets them (refer to the Monitor manual for the meanings of the various codes). * - * The code 000 executes in the same way as 040-077 but is not a standard communication code: it is included - * so that control returns to the Monitor should a user program wipe itself out. + * The code 000 executes in the same way as 040-077 but is not a standard communication code: it is included + * so that control returns to the Monitor should a user program wipe itself out. * - * For a second processor connected to the same memory, the UUO trap is locations 140-141 instead of 40-41. + * For a second processor connected to the same memory, the UUO trap is locations 140-141 instead of 40-41. * * @this {CPUStatePDP10} * @param {number} opCode @@ -68,18 +68,18 @@ PDP10.opUUO = function(opCode) * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * - * Floating add the contents of location E to AC. If the double length fraction in the sum is zero, clear - * accumulator A+1. Otherwise normalize the sum only if the magnitude of its fractional part is >= 1, and place - * the high order part of the result in AC A+1. The original contents of AC and E are unaffected. + * Floating add the contents of location E to AC. If the double length fraction in the sum is zero, clear + * accumulator A+1. Otherwise normalize the sum only if the magnitude of its fractional part is >= 1, and place + * the high order part of the result in AC A+1. The original contents of AC and E are unaffected. * - * NOTE: The result is placed in accumulator A+1. T his is the only arithmetic instruction that stores the result - * in a second accumulator, leaving the original operands intact. + * NOTE: The result is placed in accumulator A+1. T his is the only arithmetic instruction that stores the result + * in a second accumulator, leaving the original operands intact. * - * If the exponent of the sum following the one-step normalization is > 127, set Overflow and Floating Overflow; - * the result stored has an exponent 256 less than the correct one. + * If the exponent of the sum following the one-step normalization is > 127, set Overflow and Floating Overflow; + * the result stored has an exponent 256 less than the correct one. * - * SIDEBAR: The exponent of the sum is equal to that of the larger summand unless addition of the fractions - * overflows, in which case it is greater by 1. Exponent overflow can occur only in the latter case. + * SIDEBAR: The exponent of the sum is equal to that of the larger summand unless addition of the fractions + * overflows, in which case it is greater by 1. Exponent overflow can occur only in the latter case. * * @this {CPUStatePDP10} * @param {number} opCode @@ -94,11 +94,11 @@ PDP10.opUFA = function(opCode) * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * - * Negate the double length floating point number composed of the contents of AC and location E with AC on the left. - * Do this by taking the twos complement of the number whose sign is AC bit 0, whose exponent is in AC bits 1-8, and - * whose fraction is the 54-bit string in bits 9-35 of AC and location E. Place the high order word of the result - * in AC; place the low order part of the fraction in bits 9-35 of location E without altering the original contents - * of bits 0-8 of that location. + * Negate the double length floating point number composed of the contents of AC and location E with AC on the left. + * Do this by taking the twos complement of the number whose sign is AC bit 0, whose exponent is in AC bits 1-8, and + * whose fraction is the 54-bit string in bits 9-35 of AC and location E. Place the high order word of the result + * in AC; place the low order part of the fraction in bits 9-35 of location E without altering the original contents + * of bits 0-8 of that location. * * @this {CPUStatePDP10} * @param {number} opCode @@ -113,24 +113,24 @@ PDP10.opDFN = function(opCode) * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-34: * - * If the fractional part of AC is zero, clear AC. Otherwise add the scale factor given by E to the exponent part - * of AC (thus multiplying AC by 2^E), normalize the resulting word bringing 0s into bit positions vacated at the - * right, and place the result back in AC. + * If the fractional part of AC is zero, clear AC. Otherwise add the scale factor given by E to the exponent part + * of AC (thus multiplying AC by 2^E), normalize the resulting word bringing 0s into bit positions vacated at the + * right, and place the result back in AC. * - * NOTE: A negative E is represented in standard twos complement notation, but the hardware compensates for this - * when scaling the exponent. + * NOTE: A negative E is represented in standard twos complement notation, but the hardware compensates for this + * when scaling the exponent. * - * If the exponent after normalization is > 127, set Overflow and Floating Overflow; the result stored has an - * exponent 256 less than the correct one. If < -128, set Overflow, Floating Overflow and Floating Underflow; - * the result stored has an exponent 256 greater than the correct one. + * If the exponent after normalization is > 127, set Overflow and Floating Overflow; the result stored has an + * exponent 256 less than the correct one. If < -128, set Overflow, Floating Overflow and Floating Underflow; + * the result stored has an exponent 256 greater than the correct one. * - * SIDEBAR: This instruction can be used to float a fixed number with 27 or fewer significant bits. To float an - * integer contained within AC bits 9-35, + * SIDEBAR: This instruction can be used to float a fixed number with 27 or fewer significant bits. To float an + * integer contained within AC bits 9-35, * - * FSC AC,233 + * FSC AC,233 * - * inserts the correct exponent to move the binary point from the right end to the left of bit 9 and then normalizes - * (233(base 8) = 155(base 10) = 128 + 27). + * inserts the correct exponent to move the binary point from the right end to the left of bit 9 and then normalizes + * (233(base 8) = 155(base 10) = 128 + 27). * * @this {CPUStatePDP10} * @param {number} opCode @@ -145,19 +145,19 @@ PDP10.opFSC = function(opCode) * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-16: * - * Increment the byte pointer in location E as explained above. + * Increment the byte pointer in location E as explained above. * - * FROM ABOVE: To facilitate processing a series of bytes, several of the byte instructions increment the pointer, - * ie, modify it so that it points to the next byte position in a set of memory locations. Bytes are processed from - * left to right in a word, so incrementing merely replaces the current value of P by P - S, unless there is - * insufficient space in the present location for another byte of the specified size (P - S < 0). In this case Y is - * increased by one to point to the next consecutive location, and P is set to 36 - S to point to the first byte at - * the left in the new location. + * FROM ABOVE: To facilitate processing a series of bytes, several of the byte instructions increment the pointer, + * ie, modify it so that it points to the next byte position in a set of memory locations. Bytes are processed from + * left to right in a word, so incrementing merely replaces the current value of P by P - S, unless there is + * insufficient space in the present location for another byte of the specified size (P - S < 0). In this case Y is + * increased by one to point to the next consecutive location, and P is set to 36 - S to point to the first byte at + * the left in the new location. * - * CAUTION: Do not allow Y to reach maximum value. The whole pointer is incremented, so if Y is 2^18 - 1 it becomes - * zero and X is also incremented. The address calculation for the pointer uses the original X, but if a priority - * interrupt should occur before the calculation is complete, the incremented X is used when the instruction is - * repeated. + * CAUTION: Do not allow Y to reach maximum value. The whole pointer is incremented, so if Y is 2^18 - 1 it becomes + * zero and X is also incremented. The address calculation for the pointer uses the original X, but if a priority + * interrupt should occur before the calculation is complete, the incremented X is used when the instruction is + * repeated. * * @this {CPUStatePDP10} * @param {number} opCode diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 95499a139..b5c1437c4 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -28,180 +28,197 @@ http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ -var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ea(){ea=function(){};ba.Symbol||(ba.Symbol=fa)}var ga=0;function fa(a){return"jscomp_symbol_"+(a||"")+ga++} -function ha(){ea();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return pa(function(){return ba?-b:b}});qa("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ra=Math.pow(2,36),sa=-Math.pow(2,35),t={Vb:0,jb:1,Xb:2,Yb:3,Zb:4,$b:5,ac:6,bc:7,Ua:8,cc:9,kb:10,dc:11,ec:12,lb:13,fc:14,gc:15,hc:16,ic:17,jc:18,kc:19,lc:20,mc:21,nc:22,oc:23,pc:24,qc:25,rc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ta:65,Ub:66,Wb:67,sc:68,E:69,tc:70,uc:71,vc:72,wc:73,xc:74,yc:75,zc:76,Ac:77,Bc:78,Cc:79,Dc:80,Q:81, -Ec:82,Fc:83,Gc:84,Hc:85,Ic:86,Jc:87,Kc:88,Lc:89,ob:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Mc:97,Nc:98,Oc:99,d:100,e:101,Pc:102,Qc:103,Rc:104,Sc:105,Tc:106,k:107,Uc:108,Vc:109,n:110,Wc:111,p:112,q:113,r:114,Xc:115,t:116,Zc:117,$c:118,ad:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,mb:127}; -function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ya=b.comment;this.nb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.i={ready:!1,Da:!1,Qa:!1,T:!1,error:!1};this.Ma=null;this.i.error=!1;this.V=c||0;this.A=this.b=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} -function x(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var la=Math.pow(2,36),ma=-Math.pow(2,35),q={Yb:0,mb:1,$b:2,ac:3,bc:4,cc:5,dc:6,ec:7,Wa:8,fc:9,nb:10,gc:11,hc:12,ob:13,ic:14,jc:15,kc:16,lc:17,mc:18,nc:19,oc:20,pc:21,qc:22,rc:23,sc:24,tc:25,uc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Va:65,Xb:66,Zb:67,vc:68,E:69,wc:70,xc:71,yc:72,zc:73,Ac:74,Bc:75,Cc:76,Dc:77,Ec:78,Fc:79,Gc:80,Q:81, +Hc:82,Ic:83,Jc:84,Kc:85,Lc:86,Mc:87,Nc:88,Oc:89,sb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Pc:97,Qc:98,Rc:99,d:100,e:101,Sc:102,Tc:103,Uc:104,Vc:105,Wc:106,k:107,Xc:108,Yc:109,n:110,Zc:111,p:112,q:113,r:114,$c:115,t:116,bd:117,cd:118,dd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,pb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.$a=b.comment;this.rb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Da:!1,Sa:!1,T:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +function w(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function x(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} -function H(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function I(a){return H(a,4,!0)}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function gb(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function J(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +function Qa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} +function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function G(a){return F(a,4,!0)}function Sa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Xa[a]})}function Ya(a,b){return(a+" ").slice(0,b)}function Za(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Xa={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function $a(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function jb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function ib(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(x(d.W[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.g["S"+a]=[0,0,!1,!1,this.Ab,a];this.A=this.b=this.C=this.D=null;this.exports={hold:this.sb,toggle:this.Nb,reset:this.Jb, -set:this.Mb};E(this)}r(Kb,u);l=Kb.prototype;l.reset=function(a){this.stop();a&&Mb(this,this.w=0)}; -l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.b&&this.b.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.g[b]&&(this.g[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Nb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Ob(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Nb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Ob(a,b)}}(this,b),!0):u.prototype.da.call(this,a,b,c,d)}};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;Pb(this);Qb(this)};l.la=function(a,b){if(!b)if(this.U&&Rb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new O(this);a.set(0,[this.j,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Sb(this,this.j=a[0]),Mb(this,this.w=a[1]),Tb(this,a[2]);return!0};l.Jb=function(){for(var a in this.g){var b=this.g[a];b[1]=b[0]}Qb(this);return!0};function Ub(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Pb(a,b){for(var c in a.B)Ub(a,c,null!=b?b:a.B[c])}function Vb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Qb(a){for(var b in a.g)Vb(a,b,a.g[b][1])} -l.sb=function(a,b,c){if(Nb(this,b)){if(c){var d=this;setTimeout(function(){Ob(d,b);a&&a()},+c);return!1}Ob(this,b)}return!0};l.Mb=function(a,b){if("SR"==a)return Tb(this,Pa(b,8));var c=this.g[a];return c?(c[1]=+b?1:0,Vb(this,a,c[1]),!0):!1};l.Nb=function(a){return Nb(this,a)?(Ob(this,a),!0):!1};function Nb(a,b){var c=a.g[b];return c?(Vb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Wb&&(a.N=b==Xb,a.O=b==Yb),!0):!1} -function Ob(a,b){var c=a.g[b];c&&(c[2]&&c[3]&&(Vb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Bb=function(a){a||this.b.i.J||(this.b.g=this.j%Gb,this.g[Zb]&&this.g[Zb][1]&&$b(this.b))};l.Cb=function(){};l.wb=function(a){a||this.b.R()}; -l.ub=function(a){if(!a&&!this.b.i.J)if(this.g[Zb]&&this.g[Zb][1])$b(this.b);else{if((a=this.A)&&!Ma(a,!0))Na(a,!0),ac(a,0,null),Na(a,!1);else try{var b=this.b.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.g["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.j;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return lc(mc,e,f)}e=new V(a,e,m,16384,d);ic(e,a.A,h);a.g[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+nc[d]+" at "+Qa(b)),!0):lc(oc,b,c)} -function gc(a,b){var c=a.g[(b&a.u)>>>a.j];a.w++;b=c.j(b&16383,b);a.w--;return b}function fc(a,b,c){var d=a.g[(b&a.u)>>>a.j];a.w++;d.F(c,b&16383,b);a.w--}function jc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.U&&(a.U+=a.P,c=!0);0<=a.Z&&a.Z<=Zc(a)&&(a.P=a.Z=-1,Vc(a),a.R(),c=!0);c&&a.f(Zc(a)+" cycles: checksum="+H(a.ma))}} -l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.i.T)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.M?b=1:d=!0;a.N=b;b=a.ya*a.N;if(a.M!=b){a.M=b;b=a.M.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&cd(a.D)}cc(a,a.w);a.w=0;a.u=va();a.G=0;ad(a);return d}function dd(a,b){for(var c=a.B.length-1;0<=c;c--){var d=a.B[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ed(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function fd(a,b){var c=a.H-=a.I;a.I=0;b&&(a.H=0);return c} -l.Kb=function(){if(this.i.J){this.ra>=this.Aa&&ad(this,!0);this.aa=0;this.ga=va();if(this.G){var a=this.ga-this.G;a>this.za&&(this.u+=a,this.u>this.ga&&(this.u=this.ga))}try{do{var b=dd(this,this.i.Ca?1:this.oa);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=fd(this,!0);this.aa+=b;this.w+=b;dc(this,b);bc(this,b);this.O-=b;if(0>=this.O){this.O+=this.oa;++this.Ba>=gd&&(this.D&&Q(this.D,void 0),this.Ba=0);break}}while(this.i.J)}catch(e){this.R();this.D&&this.D.stop(va(),Zc(this));Ja(this,e.stack|| -e.message);return}if(this.i.J){a=setTimeout;b=this.$a;this.G=va();var c=this.za;this.aa&&(c=Math.round(c*this.aa/this.oa));var c=c-(this.G-this.ga),d=this.G-this.u;d&&(this.L=Math.round(this.w/(10*d))/100,864E5<=d&&(this.K=0,$c(this)));if(0>c||this.Lc&&(this.u-=c),c=0;this.ra+=this.aa;this.G+=c;a(b,c)}}}; -function $b(a,b){if(!Ka(a))if(a.i.J)a.f(a.toString()+" busy");else{$c(a);a.i.J=!0;a.i.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&cd(a.D,!0),a.D.start(a.u,Zc(a)));a.A||a.status("Started");setTimeout(a.$a,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.i.J){fd(this);cc(this,this.w);this.w=0;this.i.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),Zc(this));b=!0;this.A||this.status("Stopped")}this.i.complete=a;return b};var bd=30,gd=15,Sc=["power","reset"]; -function hd(a){var b=+a.model||1001;Rc.call(this,a,1E6);this.Za=b;this.Xa=+a.addrReset||0;this.fa=null;this.Wa=[];this.i.complete=!1}r(hd,Rc);l=hd.prototype;l.reset=function(){this.status("Model "+this.Za);this.i.J&&this.R();this.ea=this.g=this.pa=this.Xa;this.j=0;this.ta=this.Gb;this.Ha=this.Tb;this.fa=null;Uc(this);this.i.error=!1;Rc.prototype.reset.call(this)};l.gb=function(){return 0}; -l.save=function(){var a=new O(this);a.set(0,[this.g,this.pa,this.ea,this.j]);a.set(1,[]);a.set(2,[this.K,this.N,this.i.X]);a.set(3,id(this));a.set(4,ed(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ea();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.g=b.next().value;this.pa=b.next().value;this.ea=b.next().value;this.j=b.next().value;b=a[2];this.K=b[0];$c(this,b[1]);this.i.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.j].ta(a&16383,a)};l.Tb=function(a,b){var c=this.C;a=this.ea=a;c.g[(a&c.u)>>>c.j].Ha(b,a&16383,a)}; -l.Ia=function(a){this.i.complete=!0;var b=this.A?jd(this.A)?1:this.i.Pa?-1:0:0,c=a?this.i.Pa?0:1:-1;this.i.Pa=!1;this.H=this.I=a;this.j=this.j&-5|(b?4:0);do{if(this.j){if(this.j&4){if(kd(this.A,this.g,c)){this.R();break}++b||(this.j&=-5);c||c++}if(a=this.j&11)this.j&2?this.fa||(this.j&=-3):this.j&1&&this.j++,a=!1;if(a){if(this.j&4&&kd(this.A,this.g,c)){this.R();break}if(0>c)break}}this.j&=15;a=this.pa=this.g;this.ta(a);this.g=(a+1)%Gb}while(0>>f.j;0>>= -f.j;0>>a.j;0g&&g>=sa&&(g+=ra);g=Math.trunc(Math.abs(g))%ra;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){G(a,"invalid block at offset "+I(n),4096);break}for(var k=k+2,p=b[k++]&255|(b[k++]&255)<<8,q=b[k++]&255|(b[k++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),K=k,Aa=p-=6;0=b.length){G(a,"insufficient data for block at offset "+I(n),4096);break}m+= -b[k++]&255;if(m&255){G(a,"invalid checksum ("+H(m,2,!0)+") for block at offset "+I(n),4096);break}if(Aa)for(G(a,"loading "+I(Aa)+" bytes at "+I(q)+"-"+I(q+Aa),4096);Aa--;)fc(a.C,q++,b[K++]);else q&1?g=!0:null==d&&(d=q),null!=d&&G(a,"starting address: "+I(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Ta&&c<=t.ob&&(b=c-(t.Ta-t.jb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.lb&&(b=t.kb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.sa=function(a,b,c,d){this.D=a;this.C=b;this.b=c;this.A=d;E(this)}; -l.ib=function(a){if(!this.g){var b=Tc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.g=xa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.ib(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new O(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.j.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ya(b.substring(c,f))),c=f+1}}return a} -function vd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +function kb(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(w(d.W[0]),d=null):(w("Empty resource: "+a),d=null)}catch(h){w("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Db,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.vb,toggle:this.Qb,reset:this.Mb, +set:this.Pb};D(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.w=0)}; +l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.g&&this.g.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Rb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Sb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.da.call(this,a,b,c,d)}};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.la=function(a,b){if(!b)if(this.U&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.w=a[1]),Xb(this,a[2]);return!0};l.Mb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} +l.vb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Pb=function(a,b){if("SR"==a)return Xb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Qb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.N=b==ac,a.O=b==bc),!0):!1} +function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Eb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Fb=function(){};l.zb=function(a){a||this.g.R()}; +l.xb=function(a){if(!a&&!this.g.j.J)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),ec(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return pc(qc,e,f)}e=new L(a,e,m,16384,d);mc(e,a.A,h);a.b[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rc[d]+" at "+Ra(b)),!0):pc(Ic,b,c)} +function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function nc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.Z&&(a.Z+=a.U,c=!0);0<=a.aa&&a.aa<=cd(a)&&(a.U=a.aa=-1,Zc(a),a.R(),c=!0);c&&a.f(cd(a)+" cycles: checksum="+F(a.pa))}} +l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.T)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.M/a.N?b=1:d=!0;a.O=b;b=a.za*a.O;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&gd(a.D)}gc(a,a.B);a.B=0;a.w=va();a.H=0;ed(a);return d}function hd(a,b){for(var c=a.G.length-1;0<=c;c--){var d=a.G[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function id(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function jd(a,b){var c=a.I-=a.K;a.K=0;b&&(a.I=0);return c} +l.Nb=function(){if(this.j.J){this.va>=this.Ba&&ed(this,!0);this.ea=0;this.oa=va();if(this.H){var a=this.oa-this.H;a>this.Aa&&(this.w+=a,this.w>this.oa&&(this.w=this.oa))}try{do{var b=hd(this,this.j.Ca?1:this.ra);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=jd(this,!0);this.ea+=b;this.B+=b;hc(this,b);fc(this,b);this.P-=b;if(0>=this.P){this.P+=this.ra;++this.Qa>=kd&&(this.D&&K(this.D,void 0),this.Qa=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),cd(this));Ka(this,e.stack|| +e.message);return}if(this.j.J){a=setTimeout;b=this.bb;this.H=va();var c=this.Aa;this.ea&&(c=Math.round(c*this.ea/this.ra));var c=c-(this.H-this.oa),d=this.H-this.w;d&&(this.M=Math.round(this.B/(10*d))/100,864E5<=d&&(this.L=0,dd(this)));if(0>c||this.Mc&&(this.w-=c),c=0;this.va+=this.ea;this.H+=c;a(b,c)}}}; +function dc(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{dd(a);a.j.J=!0;a.j.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&gd(a.D,!0),a.D.start(a.w,cd(a)));a.A||a.status("Started");setTimeout(a.bb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){jd(this);gc(this,this.B);this.B=0;this.j.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),cd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var fd=30,kd=15,Wc=["power","reset"]; +function ld(a){var b=+a.model||1001;Vc.call(this,a,1E6);this.ab=b;this.Za=+a.addrReset||0;this.qb=md.bind(this);this.b=P.bind(this);this.fa=null;this.Ya=[];this.j.complete=!1}p(ld,Vc);l=ld.prototype;l.reset=function(){this.status("Model "+this.ab);this.j.J&&this.R();this.Ra=0;this.ga=this.i=this.na=this.Za;this.u=0;this.ma=this.Jb;this.Ha=this.Wb;this.fa=null;Yc(this);this.j.error=!1;Vc.prototype.reset.call(this)};l.jb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.Ra,this.i,this.na,this.ga,this.u]);a.set(1,[]);a.set(2,[this.L,this.O,this.j.X]);a.set(3,nd(this));a.set(4,id(this));return a.data()}; +l.restore=function(a){var b;b=a[0];fa();ca();fa();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.Ra=b.next().value;this.i=b.next().value;this.na=b.next().value;this.ga=b.next().value;this.u=b.next().value;b=a[2];this.L=b[0];dd(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].ma(a&16383,a)};l.Wb=function(a,b){var c=this.C;a=this.ga=a;c.b[(a&c.u)>>>c.i].Ha(b,a&16383,a)}; +l.Ia=function(a){this.j.complete=!0;var b=this.A?od(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.I=this.K=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(pd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.fa||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&pd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;var d=this.na=this.i;a=this.ma(d);this.i=(d+1)%Jb;for(var e,f=a,g=4;;){d=f&262143;(e=f>>18&15)&&(d=d+this.ma(e)& +Kb);if(!(f&4194304))break;if(0>--g){this.C.ib(f);break}f=this.ma(d)}this.Ra=d;this.qb(a/Jb|0)}while(0>9].call(this,a)} +var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},qd,rd,rd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},qd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; +function td(a){t.call(this,"ROM",a,128);this.S=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.G=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.G);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Y("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.S=a.S):c.w=null);ud(c)})}}p(td,t); +td.prototype.ta=function(a,b,c,d){this.C=b;this.g=c;this.A=d;ud(this)};td.prototype.la=function(){this.S&&(this.A&&vd(this.A,this.id,this.B,this.u,this.S),delete this.S);return!0};td.prototype.ca=function(){return!0}; +function ud(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(oc(a.C,b,a.u,Mc)){var c;for(c=0;c>>f.i;0>>= +f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= +b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)jc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Va&&c<=q.sb&&(b=c-(q.Va-q.mb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.ob&&(b=q.nb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;D(this)}; +l.lb=function(a){if(!this.b){var b=Xc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Ja)return;c=Za(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.lb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} +function Dd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function wd(a,b,c){var d;if(b){b=xd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,K--;g=p+g;d>>=8}d=H(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Bd(a,b){if(b)return Ad(a,b,a.Z[b]);var c=0;for(b in a.Z)Ad(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var zd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Cd(a){td.call(this,a);this.ya=!1;this.ma=!0;this.I=X();this.xa=X();this.N=X();this.H=[];this.g=this.K=this.G=[];Dd(this);this.P=this.ga=0;this.j=[];this.pa=void 0;Ed(this);this.A=this;this.na={};this.V=this.cb=0;this.U=null;this.M=[];Fd(this,a.messages);this.ra=a.commands;this.L=0;this.Ba=this.qa=null;this.B=this.Aa=this.za=this.fa=this.oa=0;this.ea=this.aa=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return Yc(b,a)}):void 0===global[C]&&(global[C]=function(a){return Yc(b, -a)})}r(Cd,td);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,qb:void 0===b?!1:b,ka:!1,ba:c}}function Gd(a){return[a.v,a.qb,a.ba,a.ka,a.Oa]}function Hd(a,b){var c=X(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.ab=ud(a,c.Oa=b[4]));return c}l=Cd.prototype; -l.sa=function(a,b,c,d){this.C=b;this.D=a;this.b=c;this.ea=a.u;(a=Tc(a,"messages"))&&Fd(this,a);Id(this,function(a){a:{var b=d.C.g,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.j;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=nc[c],n&&d.f(H(n.id,8)+" %"+H(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.b.pa==b)){b=a.b;var e=b.g;b.g=(e+1)%Gb;b=e}if(0d&&(d=a.b.ta(b)),0<=d&&(c=a.j[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.j.length&&(a.P=0)));return!1} -function ve(a,b,c,d){var e=X(b.v),f=a.wa(b,1),g,h,k,m=0,n=f/Ib|0,p;for(p in we)if(g=we[p][n&p]){h=+p;n>>=6;switch(h){case 32512:k=xe;m=n&3;break;case 32256:k=ye;m=n&7;break;case 29248:k=ze,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ae&&(k="B");k=Be[g||0]+k;k=Xa(k,8);g?(k=28700==h?k+W(a,f/Jb&127,-1):k+W(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=W(a,f&262143,-1),(f=f>>18&15)&&(k+="("+W(a,f,-1)+")")):k+=Kd(f);f=k;g="";h=W(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.wa(e,1),g+=" "+Kd(k),null== -e.v)break;while(e.v!=b.v)}h+=Xa(g,16)+f;c&&(h=Xa(h,60)+";"+(c||""),h=a.b.i.Ca?h+("cycles="+Zc(a.b).toString()+" cs="+H(a.b.ma)):h+(null!=d?"="+d.toString():""));return h}function Dd(a){var b,c;a.g=["bp"];if(a.K)for(b=1;b>>d.j],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.j],!0);a.G=["bw"];a.oa=0;a.ga=0} -l.va=function(a,b,c){var d=!0;c||Ce(this,a,b,!1,!0);if(a!=this.g){var e=Y(b);if(-1===e)this.f("invalid address: "+W(this,b.v)),d=!1;else{var f=this.C;f.g[e>>>f.j].va(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(De(this,a,a.length-1,"set"),Ed(this)));return d};function Ce(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.j],b==a.G));h.ka||Ed(a);break}}return f} -function Ee(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],p=gb(n,k,a.eb);0>p&&n.splice(-(p+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({Yc:b,v:c,tb:d,S:e,bb:f})}function Ge(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.tb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=ve(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} -function Fe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Qd+b):(a.O&&(a.f("ended assemble at "+W(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(La(a)&&0n||"z"S.length&&(a.f("note: only "+S.length+" available"),L=S.length);P-=L;0>P&&(null==S[S.length-1].v?(L=P+L,P=0):P+=S.length);var tc=[];"call"==Yd&&(Za=1E5,tc=["CALL"]);for(void 0!==Xd&&a.f(L+" instructions earlier:");0=S.length&&(P=0);a.pa=L;$d++;Za--}}$d||(a.f("no "+Zd+"history available"), -a.pa=void 0)}else{var ka=Z(a,R);if(ka){var la=0,ce="ds"==Ea;if(ca){if("l"==ca.charAt(0))ca=ca.substr(1)||of,la=yd(a,ca);else{var de=Z(a,ca);de&&(la=de.v-ka.v)}0>la&&(la=0);65536he;he++)fe+=String.fromCharCode((Bb%64|0)+32), -Bb/=64}ma&&(ma+="\n");ma=ce?ma+(na+","):ma+(R+": "+na+(0>ge?" "+fe:""))}ma&&a.f(ma);a.xa=ka;a.ba=qf}}}}break;case "e":if("else"==g[0])break;var ie,je,ke=g[0],wc=g[1];"e"==ke||"ew"==ke?(ie=a.wa,je=a.Va):wc=null;if(null==wc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Cb=Z(a,wc);if(Cb)for(var Db=2;DbAc;){for(var oa=null,uf=256;65536>bb.v>>>0;){Bc.v=a.wa(bb,2);if(null==bb.v||!uf--)break;if(!(Bc.v&1)){for(var vf=a,Eb=Bc,me=null,cb=Eb.v,ne=cb,Cc=1;6>=Cc&&cb;Cc++){if(2> ";M(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bSe){if(Te(d,this.K)){this.B=new O(this,"1.34.0",bf);Te(this.B)&&(cf(this,d),a=df,ef(this.B));this.B.set(Ze,hb());ff(this.B);var e=this.g&&!this.I;if(a==$e||wa("Click OK to restore the previous "+Ab+" machine state, or CANCEL to reset the machine.")){if(c=Ye(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Te(d,g):("error"==f&&"no machine state"!= -g?(this.Y("Error: "+g),"unable to verify user"==g&&(mb(gf,""),this.j=null)):this.f(f+": "+g),ef(d),Te(d)?(c=Ye(d),e=!0):c=!1))}e&&We(this,c?d:null)}else a==df&&d.clear()}else We(this);delete this.K;delete this.H}e=y(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.b&&(hf(this,this.b,b,c,a),Q(this,-2),this.b.X());this.N&&(cf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function cf(a,b){if(wa("There may be a problem with your "+Ab+" machine.\n\nTo help us diagnose it, click OK to send this "+Ab+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.j||"";b=b.toString();var d={};d.app=Ab;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;J("http://www.pcjs.org/api/v1/report",d,!0)}} -function Me(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",Xe),h=hb();g.set(Ze,h);f.set(Ze,h);f.set(jf,"1.34.0");f.set(kf,window?window.location.href:null);f.set(lf,window?window.navigator.userAgent:"");a.b&&a.b.ca&&(c&&(b&&(a.b.i.X=a.b.i.J),a.b.R()),d=a.b.ca(b,c),"object"===typeof d&&f.set(a.b.id,d),c&&(a.b.i.T=!1,!1===d&&(e=null)));for(var h=y(a.id),k=0;k=d||30<=(c.xa+=d))&&(e.textContent=c.i.J?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.b.i.J;d=!!(a.b.j&8);if(0>=b||60<=(a.I+=b)){e=a.b.g;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Qa(e,void 0):H(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.j=a.b.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");J(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Gf(a,b,c)}})}else c(a,null)} -function Hf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function g(a){f("Error: "+a);m&&(--Df||wb(!0));m=!1}var h,k,m=!0;Df++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],q=document.createElement("style");q.type="text/css";q.styleSheet?q.styleSheet.cssText=n:q.appendChild(document.createTextNode(n));p.appendChild(q)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Ef(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Df||wb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Df|| -wb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ef(c,b,a,e,!0,f,n):Ff(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(K){g(K.message)}return m}window.embedPDP10=function(a,b,c,d){wb(!1);return Hf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){wb(!1);return Hf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;n=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Jd(a,b){if(b)return Id(a,b,a.Z[b]);var c=0;for(b in a.Z)Id(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Hd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Kd(a){Bd.call(this,a);this.ya=!1;this.na=!0;this.I=T();this.va=T();this.N=T();this.H=[];this.b=this.K=this.G=[];Ld(this);this.P=this.ga=0;this.i=[];this.qa=void 0;Md(this);this.A=this;this.oa={};this.V=this.fb=0;this.U=null;this.M=[];Nd(this,a.messages);this.sa=a.commands;this.L=0;this.Ba=this.ra=null;this.B=this.Aa=this.za=this.fa=this.pa=0;this.ea=this.aa=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return bd(b,a)}):void 0===global[B]&&(global[B]=function(a){return bd(b, +a)})}p(Kd,Bd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,ub:void 0===b?!1:b,ka:!1,ba:c}}function Od(a){return[a.v,a.ub,a.ba,a.ka,a.Oa]}function Pd(a,b){var c=T(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.cb=Cd(a,c.Oa=b[4]));return c}l=Kd.prototype; +l.ta=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.ea=a.u;(a=Xc(a,"messages"))&&Nd(this,a);Qd(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=rc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.na==b)){b=a.g;var e=b.i;b.i=(e+1)%Jb;b=e}if(0d&&(d=a.g.ma(b)),0<=d&&(c=a.i[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.i.length&&(a.P=0)));return!1} +function De(a,b,c,d){var e=T(b.v),f=a.xa(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Ee)if(g=Ee[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Fe;m=n&3;break;case 32256:k=Ge;m=n&7;break;case 29248:k=He,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ie&&(k="B");k=Je[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Sd(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.xa(e,1),g+=" "+Sd(k),null== +e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Ca?h+("cycles="+cd(a.g).toString()+" cs="+F(a.g.pa)):h+(null!=d?"="+d.toString():""));return h}function Ld(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.i],!0);a.G=["bw"];a.pa=0;a.ga=0} +l.wa=function(a,b,c){var d=!0;c||Ke(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].wa(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(Le(this,a,a.length-1,"set"),Md(this)));return d};function Ke(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.G));h.ka||Md(a);break}}return f} +function Me(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.gb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({ad:b,v:c,wb:d,S:e,eb:f})}function Oe(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.wb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=De(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} +function Ne(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(ye+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==ce&&(bb=1E5,wc=["CALL"]);for(void 0!==be&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;ee++;bb--}}ee||(a.f("no "+de+"history available"), +a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,he="ds"==Ha;if(ga){if("l"==ga.charAt(0))ga=ga.substr(1)||wf,pa=Gd(a,ga);else{var ie=Z(a,ga);ie&&(pa=ie.v-oa.v)}0>pa&&(pa=0);65536me;me++)ke+=String.fromCharCode((Eb%64|0)+32), +Eb/=64}qa&&(qa+="\n");qa=he?qa+(ra+","):qa+(U+": "+ra+(0>le?" "+ke:""))}qa&&a.f(qa);a.va=oa;a.ba=yf}}}}break;case "e":if("else"==g[0])break;var ne,oe,pe=g[0],zc=g[1];"e"==pe||"ew"==pe?(ne=a.xa,oe=a.Xa):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,Cf=256;65536>eb.v>>>0;){Ec.v=a.xa(eb,2);if(null==eb.v||!Cf--)break;if(!(Ec.v&1)){for(var Df=a,Hb=Ec,re=null,fb=Hb.v,se=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;b$e){if(af(d,this.K)){this.B=new J(this,"1.34.0",kf);af(this.B)&&(lf(this,d),a=mf,nf(this.B));this.B.set(gf,ab());of(this.B);var e=this.b&&!this.I;if(a==hf||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=ff(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?af(d,g):("error"==f&&"no machine state"!= +g?(this.Y("Error: "+g),"unable to verify user"==g&&(ob(pf,""),this.i=null)):this.f(f+": "+g),nf(d),af(d)?(c=ff(d),e=!0):c=!1))}e&&df(this,c?d:null)}else a==mf&&d.clear()}else df(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.g&&(qf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(lf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function lf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} +function Ue(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",ef),h=ab();g.set(gf,h);f.set(gf,h);f.set(rf,"1.34.0");f.set(sf,window?window.location.href:null);f.set(tf,window?window.navigator.userAgent:"");a.g&&a.g.ca&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.ca(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.T=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;k=d||30<=(c.ya+=d))&&(e.textContent=c.j.J?c.M.toFixed(2)+"Mhz":"Stopped",c.ya=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Of(a,b,c)}})}else c(a,null)} +function Pf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Lf||zb(!0));m=!1}var h,k,m=!0;Lf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Mf(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Lf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Lf|| +zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Mf(c,b,a,e,!0,f,n):Nf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Pf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Pf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),t={wb:0,Ma:1,yb:2,zb:3,Ab:4,Bb:5,Cb:6,Db:7,Ea:8,Eb:9,Na:10,Fb:11,Gb:12,Oa:13,Hb:14,Ib:15,Jb:16,Kb:17,Lb:18,Mb:19,Nb:20,Ob:21,Pb:22,Qb:23,Rb:24,Sb:25,Tb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Da:65,vb:66,xb:67,Ub:68,E:69,Vb:70,Wb:71,Xb:72,Yb:73,Zb:74,$b:75,ac:76,bc:77,cc:78,dc:79,ec:80,Q:81, -fc:82,gc:83,hc:84,ic:85,jc:86,kc:87,lc:88,mc:89,Sa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,nc:97,oc:98,pc:99,d:100,e:101,qc:102,rc:103,sc:104,tc:105,uc:106,k:107,vc:108,wc:109,n:110,xc:111,p:112,q:113,r:114,yc:115,t:116,zc:117,Ac:118,Bc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Pa:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ha=b.comment;this.Ra=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ia=this.id:(this.ja=this.id.substr(0,a),this.ia=this.id.substr(a+1));this.b={ready:!1,na:!1,Ba:!1,w:!1,error:!1};this.qa=null;this.b.error=!1;this.o=this.c=this.l=this.m=this.Y=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={zb:0,Oa:1,Bb:2,Cb:3,Db:4,Eb:5,Fb:6,Gb:7,Ga:8,Hb:9,Pa:10,Ib:11,Jb:12,Qa:13,Kb:14,Lb:15,Mb:16,Nb:17,Ob:18,Pb:19,Qb:20,Rb:21,Sb:22,Tb:23,Ub:24,Vb:25,Wb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Fa:65,yb:66,Ab:67,Xb:68,E:69,Yb:70,Zb:71,$b:72,ac:73,bc:74,cc:75,dc:76,ec:77,fc:78,gc:79,hc:80,Q:81, +ic:82,jc:83,kc:84,lc:85,mc:86,nc:87,oc:88,pc:89,Va:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,qc:97,rc:98,sc:99,d:100,e:101,tc:102,uc:103,vc:104,wc:105,xc:106,k:107,yc:108,zc:109,n:110,Ac:111,p:112,q:113,r:114,Bc:115,t:116,Cc:117,Dc:118,Ec:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ra:127}; +function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ja=b.comment;this.Ua=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ja=this.id:(this.ka=this.id.substr(0,a),this.ja=this.id.substr(a+1));this.b={ready:!1,oa:!1,Da:!1,w:!1,error:!1};this.ra=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.Z=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return""+c}function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} function xa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ba[a]})}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ba={"&":"&","<":"<",">":">",'"':""","'":"'"}; function Da(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={D:null,I:null,R:null,P:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.R=g.load;d.P=g.exec;if(e=g.bytes)d.D=e;else if(e=g.words)for(d.D=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.D=Array(4*e.length),f=c=0;c>8&255,d.D[f++]=e[c]>>16&255,d.D[f++]=e[c]>>24&255;else d.D=g;d.I=g.symbols;d.D.length?1==d.D.length&&(x(d.D[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.R=g.load;d.P=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else d.F=g;d.J=g.symbols;d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.ab,a];this.o=this.c=this.l=this.m=null;this.exports={hold:this.Ua,toggle:this.ob,reset:this.kb, -set:this.nb};E(this)}r(Ua,u);k=Ua.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; -k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.c&&this.c.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Wa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wa(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.U=function(a,b,c,d){this.m=a;this.l=b;this.c=c;this.o=d;Xa(this);Ya(this)};k.T=function(a,b){if(!b)if(this.O&&Za(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.f,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.f=a[0]),N(this,this.h=a[1]),$a(this,a[2]);return!0};k.kb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Ya(this);return!0};function ab(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xa(a,b){for(var c in a.j)ab(a,c,null!=b?b:a.j[c])}function bb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ya(a){for(var b in a.a)bb(a,b,a.a[b][1])} -k.Ua=function(a,b,c){if(Wa(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; -k.nb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.f];a.h++;b=c.a(b&16383,b);a.h--;a=b}else a=this.c.ba(this.f);N(this,this.h=a)}};k.$a=function(a){a||this.c.b.v||Q(this,this.g)};k.Za=function(a){a?(this.s=!0,Xa(this,!0)):(this.s=!1,Xa(this),$a(this,0))};k.ab=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.f;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.X)return h.sa+=h.X-e,h.X=e,!0;if(e>=h.X+h.sa){m=h.size-(e-l);m>f&&(m=f);h.sa=e-h.X+m;e=l+16384;f-=m;g++;continue}}return pb(qb,e,f)}e=new U(a,e,m,16384,d);mb(e,h);a.a[g++]=e;e=l+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rb[d]+" at "+wa(b)),!0):pb(sb,b,c)}function kb(a,b,c){var d=a.a[(b&a.g)>>>a.f];a.h++;d.m(c,b&16383,b);a.h--} -function nb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.K&&(a.K+=a.ea,c=!0);0<=a.fa&&a.fa<=X(a)&&(a.ea=a.fa=-1,Fb(a),S(a),c=!0);c&&a.J(X(a)+" cycles: checksum="+F(a.ka))}} -k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.F/a.H&&(b=1);a.L=b;b=a.wa*a.L;if(a.H!=b){a.H=b;b=a.H.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.J("target speed: "+b)}c&&a.m&&(c=a.m,c.Y&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Y.focus(),window&&window.scrollTo(b,d)))}hb(a,a.h);a.h=0;a.g=w();a.s=0;Hb(a)}function Jb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Kb(a,b){var c=a.u-=a.A;a.A=0;b&&(a.u=0);return c} -k.lb=function(){if(this.b.v){this.ma>=this.ya&&Hb(this,!0);this.O=0;this.ca=w();if(this.s){var a=this.ca-this.s;a>this.xa&&(this.g+=a,this.g>this.ca&&(this.g=this.ca))}try{do{for(var b,c=this.b.oa?1:this.ga,d=this.j.length-1;0<=d;d--){var e=this.j[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.ua(b)}catch(f){if("number"!=typeof f)throw f;}b=Kb(this,!0);this.O+=b;this.h+=b;ib(this,b);gb(this,b);this.M-=b;if(0>=this.M){this.M+=this.ga;++this.za>=Lb&&(this.m&&T(this.m,void 0),this.za=0);break}}while(this.b.v)}catch(f){S(this); -this.m&&this.m.stop(w(),X(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ia;this.s=w();c=this.xa;this.O&&(c=Math.round(c*this.O/this.ga));c-=this.s-this.ca;if(d=this.s-this.g)this.F=Math.round(this.h/(10*d))/100,864E5<=d&&(this.B=0,Gb(this));if(0>c||this.Fc&&(this.g-=c),c=0;this.ma+=this.O;this.s+=c;a(b,c)}}}; -function R(a){var b;a.b.error?(a.J(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.J(a.toString()+" busy");else{Gb(a);a.b.v=!0;a.b.Ca=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.g,X(a));a.o||a.status("Started");setTimeout(a.Ia,0)}}k.ua=function(){return 0};function S(a){var b=!1;if(a.b.v){Kb(a);hb(a,a.h);a.h=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),X(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Ib=30,Lb=15,Db=["power","reset"]; -function Mb(a){var b=+a.model||1001;V.call(this,a,1E6);this.Qa=b;this.Ga=+a.addrReset||0;this.W=null;this.Fa=[];this.b.complete=!1}r(Mb,V);k=Mb.prototype;k.reset=function(){this.status("Model "+this.Qa);this.b.v&&S(this);this.V=this.f=this.Aa=this.Ga;this.a=0;this.ba=this.hb;this.ta=this.ub;this.W=null;Eb(this);this.b.error=!1;V.prototype.reset.call(this)};k.Ka=function(){return 0}; -k.save=function(){var a=new P(this);a.set(0,[this.f,this.Aa,this.V,this.a]);a.set(1,[]);a.set(2,[this.B,this.L,this.b.G]);a.set(3,Nb(this));a.set(4,Jb(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.f=b.next().value;this.Aa=b.next().value;this.V=b.next().value;this.a=b.next().value;b=a[2];this.B=b[0];Gb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.f].ba(a&16383,a)};k.ub=function(a,b){var c=this.l;a=this.V=a;c.a[(a&c.g)>>>c.f].ta(b,a&16383,a)}; -k.ua=function(a){this.b.complete=!0;var b=a?this.b.Ca?0:1:-1;this.b.Ca=!1;this.u=this.A=a;this.a=this.a&-5|0;do{if(a=this.a)if(a=this.a&11)this.a&2?this.W||(this.a&=-3):this.a&1&&this.a++,a=!1;if(a){if(this.a&4&&this.o.h(this.f,b)){S(this);break}if(0>b)break}this.a&=15;a=this.Aa=this.f;this.ba(a);this.f=(a+1)%Sa}while(0>>f.f;0>>=f.f;0>>a.f;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,n=b[l++]&255|(b[l++]&255)<<8,p=b[l++]&255|(b[l++]&255)<<8,m=m+((n&255)+(n>>8)+(p&255)+(p>>8)),M=l,qa=n-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(qa)for(;qa--;)kb(a.l,p++,b[M++]);else p&1?g=!0:null==d&&(d=p);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=t.Da&&c<=t.Sa&&(b=c-(t.Da-t.Ma));b&&(a.preventDefault&&a.preventDefault(),d.ra(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==t.Oa&&(b=t.Na);d.ra(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ra(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.U=function(a,b,c,d){this.m=a;this.l=b;this.c=c;this.o=d;E(this)}; -k.La=function(a){if(!this.a){var b=W(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ia)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ja+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.La(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ra=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bXb){if(Z(d,this.B)){this.j=new P(this,"1.34.0",fc);Z(this.j)&&(gc(this,d),a=hc,ic(this.j));this.j.set(cc,Da());jc(this.j);var e=this.a&&!this.A;if(a==dc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=bc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(kc,""),this.f=null)):this.J(f+": "+g),ic(d),Z(d)?(c=bc(d),e=!0):c=!1))}e&&$b(this,c?d:null)}else a==hc&&d.clear()}else $b(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.c&&(lc(this,this.c,b,c,a),T(this,-2),this.c.G());this.K&&(gc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; -function gc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.f||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function mc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new P(a,"1.34.0"),g=new P(a,"1.34.0",ac),h=Da();g.set(cc,h);f.set(cc,h);f.set(nc,"1.34.0");f.set(oc,window?window.location.href:null);f.set(pc,window?window.navigator.userAgent:"");a.c&&a.c.N&&(c&&(b&&(a.c.b.G=a.c.b.v),S(a.c)),d=a.c.N(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.va+=d))&&(e.textContent=c.b.v?c.F.toFixed(2)+"Mhz":"Stopped",c.va=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.c.b.v;d=!!(a.c.a&8);if(0>=b||60<=(a.A+=b)){e=a.c.f;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.f=a.c.f:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){g=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);xc(a,b,c)}})}else c(a,null)} -function yc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);m&&(--uc||K(!0));m=!1}var h,l,m=!0;uc++;la[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],M=document.createElement("style");M.type="text/css";M.styleSheet?M.styleSheet.cssText=n:M.appendChild(document.createTextNode(n));p.appendChild(M)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,l){l?vc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--uc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--uc|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?vc(c,b,a,e,!0,f,n):wc(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(qa){g(qa.message)}return m}window.embedPDP10=function(a,b,c,d){K(!1);return yc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return yc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",m=null,n=0;na;a++)this.a["S"+a]=[0,0,!1,!1,this.eb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Xa,toggle:this.rb,reset:this.nb, +set:this.qb};E(this)}n(Va,u);k=Va.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; +k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.f&&this.f.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Xa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Xa(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.V=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Ya(this);Za(this)};k.T=function(a,b){if(!b)if(this.O&&$a(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),M(this,this.h=a[1]),ab(this,a[2]);return!0};k.nb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Za(this);return!0};function bb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ya(a,b){for(var c in a.j)bb(a,c,null!=b?b:a.j[c])}function cb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Za(a){for(var b in a.a)cb(a,b,a.a[b][1])} +k.Xa=function(a,b,c){if(Xa(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; +k.qb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.W(this.c);M(this,this.h=a)}};k.cb=function(a){a||this.f.b.v||Q(this,this.g)};k.bb=function(a){a?(this.s=!0,Ya(this,!0)):(this.s=!1,Ya(this),ab(this,0))};k.eb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Y)return h.ta+=h.Y-e,h.Y=e,!0;if(e>=h.Y+h.ta){p=h.size-(e-l);p>f&&(p=f);h.ta=e-h.Y+p;e=l+16384;f-=p;g++;continue}}return rb(sb,e,f)}e=new T(a,e,p,16384,d);ob(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+tb[d]+" at "+wa(b)),!0):rb(ub,b,c)}function mb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function pb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.L&&(a.L+=a.ga,c=!0);0<=a.ha&&a.ha<=Jb(a)&&(a.ga=a.ha=-1,Ib(a),R(a),c=!0);c&&a.I(Jb(a)+" cycles: checksum="+F(a.la))}} +k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.H/a.K&&(b=1);a.M=b;b=a.ya*a.M;if(a.K!=b){a.K=b;b=a.K.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.Z&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Z.focus(),window&&window.scrollTo(b,d)))}jb(a,a.j);a.j=0;a.h=w();a.u=0;Lb(a)}function Nb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Ob(a,b){var c=a.A-=a.B;a.B=0;b&&(a.A=0);return c} +k.ob=function(){if(this.b.v){this.na>=this.Aa&&Lb(this,!0);this.U=0;this.fa=w();if(this.u){var a=this.fa-this.u;a>this.za&&(this.h+=a,this.h>this.fa&&(this.h=this.fa))}try{do{for(var b,c=this.b.pa?1:this.aa,d=this.s.length-1;0<=d;d--){var e=this.s[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.va(b)}catch(f){if("number"!=typeof f)throw f;}b=Ob(this,!0);this.U+=b;this.j+=b;kb(this,b);ib(this,b);this.O-=b;if(0>=this.O){this.O+=this.aa;++this.Ba>=Pb&&(this.m&&S(this.m,void 0),this.Ba=0);break}}while(this.b.v)}catch(f){R(this); +this.m&&this.m.stop(w(),Jb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ka;this.u=w();c=this.za;this.U&&(c=Math.round(c*this.U/this.aa));c-=this.u-this.fa;if(d=this.u-this.h)this.H=Math.round(this.j/(10*d))/100,864E5<=d&&(this.D=0,Kb(this));if(0>c||this.Hc&&(this.h-=c),c=0;this.na+=this.U;this.u+=c;a(b,c)}}}; +function hb(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Kb(a);a.b.v=!0;a.b.Ea=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Jb(a));a.o||a.status("Started");setTimeout(a.Ka,0)}}k.va=function(){return 0};function R(a){var b=!1;if(a.b.v){Ob(a);jb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Jb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Mb=30,Pb=15,Gb=["power","reset"]; +function Qb(a){var b=+a.model||1001;Fb.call(this,a,1E6);this.Sa=b;this.Ia=+a.addrReset||0;this.Ta=Rb.bind(this);this.a=V.bind(this);this.X=null;this.Ha=[];this.b.complete=!1}n(Qb,Fb);k=Qb.prototype;k.reset=function(){this.status("Model "+this.Sa);this.b.v&&R(this);this.Ca=0;this.da=this.g=this.xa=this.Ia;this.c=0;this.W=this.kb;this.ua=this.xb;this.X=null;Hb(this);this.b.error=!1;Fb.prototype.reset.call(this)};k.Ma=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[this.Ca,this.g,this.xa,this.da,this.c]);a.set(1,[]);a.set(2,[this.D,this.M,this.b.G]);a.set(3,Sb(this));a.set(4,Nb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.Ca=b.next().value;this.g=b.next().value;this.xa=b.next().value;this.da=b.next().value;this.c=b.next().value;b=a[2];this.D=b[0];Kb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].W(a&16383,a)};k.xb=function(a,b){var c=this.l;a=this.da=a;c.a[(a&c.g)>>>c.c].ua(b,a&16383,a)}; +k.va=function(a){this.b.complete=!0;var b=a?this.b.Ea?0:1:-1;this.b.Ea=!1;this.A=this.B=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.X||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;var c=this.xa=this.g;a=this.W(c);this.g=(c+1)%Sa;for(var d,e=a,f=4;;){c=e&262143;(d=e>>18&15)&&(c=c+this.W(d)&Ta);if(!(e&4194304))break;if(0>--f){d=this.l;d.h||R(d.f);break}e=this.W(c)}this.Ca=c;this.Ta(a/Sa|0)}while(0>9].call(this,a)} +var Vb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Tb,Ub,Ub,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Tb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; +function Wb(a){u.call(this,"ROM",a);this.J=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.s=xa(this.h);if(this.h){a=this.h;var b=ya(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.C("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(ka(c.ka,a,b),(a=Ea(a,b))?(c.a=a.F,c.J=a.J):c.h=null);Xb(c)})}}n(Wb,u); +Wb.prototype.V=function(a,b,c,d){this.l=b;this.f=c;this.o=d;Xb(this)};Wb.prototype.T=function(){this.J&&(this.o&&this.o.a(this.id,this.j,this.g,this.J),delete this.J);return!0};Wb.prototype.N=function(){return!0}; +function Xb(a){if(!ta(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.C(b)}else{b=a.j;if(qb(a.l,b,a.g,yb)){var c;for(c=0;c>>f.c;0>>=f.c;0>>a.c;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ua=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ua)for(;ua--;)mb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Fa&&c<=r.Va&&(b=c-(r.Fa-r.Oa));b&&(a.preventDefault&&a.preventDefault(),d.sa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Qa&&(b=r.Pa);d.sa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.sa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.V=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; +k.Na=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ja)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.Na(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.sa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bec){if(Z(d,this.B)){this.j=new O(this,"1.34.0",nc);Z(this.j)&&(oc(this,d),a=pc,qc(this.j));this.j.set(kc,Da());rc(this.j);var e=this.a&&!this.A;if(a==lc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=jc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(sc,""),this.c=null)):this.I(f+": "+g),qc(d),Z(d)?(c=jc(d),e=!0):c=!1))}e&&hc(this,c?d:null)}else a==pc&&d.clear()}else hc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(tc(this,this.f,b,c,a),S(this,-2),this.f.G());this.K&&(oc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function oc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function uc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",ic),h=Da();g.set(kc,h);f.set(kc,h);f.set(vc,"1.34.0");f.set(wc,window?window.location.href:null);f.set(xc,window?window.navigator.userAgent:"");a.f&&a.f.N&&(c&&(b&&(a.f.b.G=a.f.b.v),R(a.f)),d=a.f.N(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.wa+=d))&&(e.textContent=c.b.v?c.H.toFixed(2)+"Mhz":"Stopped",c.wa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(t){g=null,a=t.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,q=/( [a-z]+=)(['"])(.*?)\2/g;p=q.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Fc(a,b,c)}})}else c(a,null)} +function Gc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Cc||K(!0));p=!1}var h,l,p=!0;Cc++;la[b]={};try{if(h=document.getElementById(b)){var q;if("object"==typeof resources&&(q=resources.css)){var t=document.head||document.getElementsByTagName("head")[0],P=document.createElement("style");P.type="text/css";P.styleSheet?P.styleSheet.cssText=q:P.appendChild(document.createTextNode(q));t.appendChild(P)}d|| +(q=a,"pdp"==a.substr(0,3)&&(q="pdpjs"),d="/versions/"+q+"/1.34.0/components.xsl");q=function(e,l){l?Dc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Cc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Cc|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Dc(c,b,a,e,!0,f,q):Ec(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ua){g(ua.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Gc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Gc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",p=null,q=0;qc&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,Jd:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,qk:98,tk:99,d:100,e:101,uk:102,vk:103,wk:104,xk:105,Bk:106,k:107,Ck:108,Dk:109,n:110,Ek:111,p:112,q:113,r:114,Fk:115,t:116,Ik:117,Jk:118,Kk:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Wd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,aa:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.F=this.f=this.D=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} +y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Vd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,aa:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.F=this.f=this.D=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} function qa(){return Date.now()||+new Date}function v(a){window&&window.alert(a)}function ra(a){var b=!1;window&&(b=window.confirm(a));return b}function ta(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>1];this.f&&z(this.f,32)&&C(this.f,"Memory.readWord("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.nh=function(a,b){this.g[a]=b;this.fb=!0};h.ph=function(a,b,c){this.g[a]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0)};h.ni=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);this.w.setUint16(a,b,!0);this.fb=!0}; h.pi=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);!Kb&&a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.G[a>>1]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0)};var Gd=0,hd=1,Hd=2,Yc=4,cd=["NONE","RAM","ROM","VID","H/W"],Fd=0,Vd=[],Ud=[I.prototype.Yf,I.prototype.qh,I.prototype.bh,I.prototype.ri],Yd=[I.prototype.Wf,I.prototype.oh,I.prototype.Yg,I.prototype.oi]; if(Fb)var Td=[I.prototype.Vf,I.prototype.nh,I.prototype.Xg,I.prototype.ni],Kd=[I.prototype.Xf,I.prototype.ph,I.prototype.ah,I.prototype.pi];var be;if(Fb){var ce=new ArrayBuffer(2);(new DataView(ce)).setUint16(0,256,!0);be=256===(new Uint16Array(ce))[0]}else be=!1;var Jd=be; -function de(a,b){u.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.mb=c;this.ld=Math.round(this.Xc/1E4)/100;this.xb=this.ld*this.mb;this.md=this.qc=this.Ab=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.qa=a.autoStart;"string"==typeof this.A.qa&&(this.A.qa="true"==this.A.qa);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.be=this.hh.bind(this);this.nb=this.Ka=this.lb=this.b=this.la=this.Ja=this.nc=this.kb=this.Sb= +function de(a,b){u.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.mb=c;this.ld=Math.round(this.Xc/1E4)/100;this.xb=this.ld*this.mb;this.md=this.qc=this.Ab=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.qa=a.autoStart;"string"==typeof this.A.qa&&(this.A.qa="true"==this.A.qa);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.Zd=this.hh.bind(this);this.nb=this.Ka=this.lb=this.b=this.la=this.Ja=this.nc=this.kb=this.Sb= this.nd=this.wb=0;this.sa=null;y(this)}p(de,u);h=de.prototype;h.za=function(a,b,c,d){this.J=a;this.D=b;this.F=d;this.sa=a.i;for(a=0;a=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=le(a)&&(a.Ob=a.Rb=-1,he(a),a.ba(),c=!0);c&&a.v(le(a)+" cycles: checksum="+F(a.oc))}} @@ -134,16 +134,16 @@ case "speed":return this.H[b]=c,!0;case "setSpeed":return this.H[b]=c,c.onclick= function me(a,b,c){var d=!1;if(void 0!==b){.8>a.wb/a.xb?b=1:d=!0;a.mb=b;b=a.ld*a.mb;if(a.xb!=b){a.xb=b;b=a.xb.toFixed(2)+"Mhz";var e=a.H.setSpeed;e&&(e.textContent=b);a.v("target speed: "+b)}c&&a.J&&pe(a.J)}wc(a,a.Ka);a.Ka=0;a.Ja=qa();a.kb=0;ne(a);return d}function ld(a,b){var c=a.ia.length;a.ia.push([-1,b]);return c}function nd(a,b,c,d){0<=b&&ba.ia[b][0])&&(c=a.Xc*a.mb/1E3*c|0,a.A.V&&(c+=qe(a)),a.ia[b][0]=c)} function re(a,b){for(var c=a.ia.length-1;0<=c;c--){var d=a.ia[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function se(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function qe(a,b){var c=a.lb-=a.b;a.b=a.la=0;b&&(a.lb=0);return c} h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&ne(this,!0);this.Sb=0;this.nc=qa();if(this.kb){var a=this.nc-this.kb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=re(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=qe(this,!0);this.Sb+=b;this.Ka+=b;xc(this,b);vc(this,b);this.Ab-=b;if(0>=this.Ab){this.Ab+=this.qc;++this.nd>=te&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ba();this.J&&this.J.stop(qa(),le(this)); -Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.be;this.kb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.kb-this.nc),d=this.kb-this.Ja;d&&(this.wb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.nb=0,me(this)));if(0>c||this.wbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.kb+=c;a(b,c)}}}; -function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.F||a.status("Started");setTimeout(a.be,0)}}h.Cc=function(){return 0};h.ba=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.F||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,ee=["power","reset"]; -function ue(a){var b=+a.model||1170;de.call(this,a,6666667);this.ka=b;this.Vd=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.ta=this.X=[];this.M=this.B=this.Ha=this.xc=[];this.ib=this.O=this.Td=this.yb=this.zb=this.rb=this.jb=this.P=this.uc=this.ob=this.Ga=this.S=this.vc=this.wc=this.W=this.i=0;this.Yd=[4,2,0,1];this.zc=0;this.Zd=255;1120>=this.ka?(this.Sd=ve.bind(this),this.Lb=this.Cf,this.zc=8,this.Zd=-1,this.fe=255,this.ee=0):(this.Sd=we.bind(this),this.Lb=this.Df, +Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.Zd;this.kb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.kb-this.nc),d=this.kb-this.Ja;d&&(this.wb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.nb=0,me(this)));if(0>c||this.wbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.kb+=c;a(b,c)}}}; +function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.F||a.status("Started");setTimeout(a.Zd,0)}}h.Cc=function(){return 0};h.ba=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.F||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,ee=["power","reset"]; +function ue(a){var b=+a.model||1170;de.call(this,a,6666667);this.ka=b;this.Td=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.ta=this.X=[];this.M=this.B=this.Ha=this.xc=[];this.ib=this.O=this.Sd=this.yb=this.zb=this.rb=this.jb=this.P=this.uc=this.ob=this.Ga=this.S=this.vc=this.wc=this.W=this.i=0;this.Wd=[4,2,0,1];this.zc=0;this.Yd=255;1120>=this.ka?(this.be=ve.bind(this),this.Lb=this.Cf,this.zc=8,this.Yd=-1,this.fe=255,this.ee=0):(this.be=we.bind(this),this.Lb=this.Df, this.fe=~(1792|(1140>=this.ka?2048:0))&65535,this.ee=1140e.Fb&&(e.Fb=c,c+=4)}return de.prototype.Ca.call(this,a,b)}; -h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ba();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Vd,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, -65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;de.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.D&&(xe(a),a.Td=gd(a.D))} +h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ba();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Td,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;de.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.D&&(xe(a),a.Sd=gd(a.D))} function xe(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.pe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.yb?(a.Ia=65536,a.ub=a.W&16?4186112:253952,a.Fa=a.se,a.oa=a.sc?a.$g:a.Ed,a.Hb=a.tc?a.ti:a.Id,Zc(a.D,a.W&16?22:18)):(a.Ia=0,a.ub=57344,a.Fa=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,Zc(a.D,16))}function td(a){var b=a.S;b&57344||(b=b&-3199|a.zb<<5|a.rb<<1);return b} function ud(a,b){b&=-3073;if(a.S!=b){b&57344&&!(a.S&57344)&&(a.vc=a.O>>16&65535,a.wc=a.O&65535);a.S=b;a.zb=(b&96)>>5;a.rb=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.yb!=c&&(a.yb=c,xe(a))}}function vd(a){a.S&57344||(a.vc=a.O>>16&65535);a=a.vc;a&65280&&(a=(a<<8|a>>8)&65535);return a}function wd(a){a.S&57344||(a.wc=a.O&65535);return a.wc}function xd(a,b){1170>a.ka&&(b&=-49);a.W!=b&&(a.W=b,a.jb=b&16?4194303:262143,xe(a))} -function ye(a,b,c,d){a.Vd=b;qc(a,b);Ad(a,0);a.D.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.aa?a.A.V||tc(a):a.A.qa=!0}else a.F&&a.A.aa?a.ba()||a.J.A.reset||(ie(a.F),H(a.J,-1)):!1===c&&a.ba();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; +function ye(a,b,c,d){a.Td=b;qc(a,b);Ad(a,0);a.D.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.aa?a.A.V||tc(a):a.A.qa=!0}else a.F&&a.A.aa?a.ba()||a.J.A.reset||(ie(a.F),H(a.J,-1)):!1===c&&a.ba();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; h.save=function(){var a=new G(this);a.set(0,[this.g,this.ta,this.X,this.M,this.B,this.Ha,this.xc,this.P,this.uc,this.ob,this.Ga,this.zb,this.rb,this.ib,this.i,this.O,this.bb,this.Ac,this.Dc]);a.set(1,[zd(this),td(this),vd(this),wd(this),this.W]);a.set(2,[this.nb,this.mb,this.A.qa]);a.set(3,ze(this));a.set(4,se(this));return a.data()}; h.restore=function(a){var b=ia(a[0]);this.g=b.next().value;this.ta=b.next().value;this.X=b.next().value;this.M=b.next().value;this.B=b.next().value;this.Ha=b.next().value;this.xc=b.next().value;this.P=b.next().value;this.uc=b.next().value;this.ob=b.next().value;this.Ga=b.next().value;this.zb=b.next().value;this.rb=b.next().value;this.ib=b.next().value;this.i=b.next().value;this.O=b.next().value;this.bb=b.next().value;this.Ac=b.next().value;this.Dc=b.next().value;b=a[1];Ad(this,b[0]);ud(this,b[1]); this.vc=b[2];this.wc=b[3];xd(this,b[4]);b=a[2];this.nb=b[0];me(this,b[1]);this.A.qa=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>1}function Je(a,b,c,d){a.I=a.L=a.C=b;a.G=(c^d)&(d^b)} h.ra=function(a,b,c){if(!this.pa){0>this.bb?this.bb=zd(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Ad(this,e&-12289|this.bb>>2&12288);Ke(this,this.bb);Ke(this,this.g[7]);qc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ba();if(-4<=c)throw a;}}; function Le(a){var b=Me(a),c=Me(a);a.w&49152&&(c=c&-225|a.w&63712);qc(a,b);Ad(a,c);a.i&=-17}function Ne(a,b){var c=b>>13&31;31>c&&(b=a.W&32?a.Ha[c]+(b&8191)&4194303:b&-3932161);return b} -function Oe(a,b,c){var d=[];if(c){c=Ne(a,b);var e=b>>13&31;d.push(c);d.push(e);a.W&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.yb){var e=a.N<<1,f=b>>13;7>13;a.W&a.Yd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.jb;3932160<=f&&(f=Ne(a,f));if(a.pa)return f;f>=a.Td&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& +function Oe(a,b,c){var d=[];if(c){c=Ne(a,b);var e=b>>13&31;d.push(c);d.push(e);a.W&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.yb){var e=a.N<<1,f=b>>13;7>13;a.W&a.Wd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.jb;3932160<=f&&(f=Ne(a,f));if(a.pa)return f;f>=a.Sd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& (g|=16384));a.B[a.N][d]=e;if(f!=(4194170&a.jb)||a.N)a.zb=a.N,a.rb=d;g&&(g&57344&&(0<=a.bb&&(g|=128),a.S&57344||(g|=a.S&4096|a.zb<<5|a.rb<<1,ud(a,a.S&-61695|g&61694)),a.ra(168,64,-2)),a.S&61440||!(f<(4191360&a.jb)||f>(4194239&a.jb))||(a.S|=4096,a.S&512&&(a.i|=64)));return f}function Me(a){var b=a.oa(a.g[6]|a.Ia);a.g[6]=a.g[6]+2&65535;return b}function Ke(a,b){var c=a.g[6]-2&65535;a.g[6]=c;a.O=a.O&65535|(a.O&-65536)<<8|16121856;a.i&256||a.Lb(4,-2,c);a.Hb(c,b)} function Pe(a,b,c,d){var e,f,g=d&8?0:a.Ia;switch(b){case 0:return a.ra(4,0,-3),0;case 1:return 6==c&&a.Lb(d,0,a.g[6]),a.b-=3,7==c?a.g[c]:a.g[c]|g;case 2:f=2;e=a.g[c];6==c&&a.Lb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.g[c];7!=c&&(e|=g);e=a.oa(e);e|=g;a.b-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.g[c]+f&65535;6==c&&a.Lb(d,f,e);7!=c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.g[c]-2&65535;7!=c&&(e|=g);e=a.oa(e)|g;a.b-=8;break;case 6:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,6==c&&a.Lb(d, 0,e),a.b-=6,e|g;case 7:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.Ga&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.Ga&&(c<=this.Ga-32?this.ra(4,0,-4):(this.P|=8,this.i|=32)))};h.pe=function(a){this.F&&$d(this.F,a,1);return this.ad(a)};h.te=function(a){this.F&&$d(this.F,a,2);return this.cd(a)}; h.ze=function(a,b){this.F&&ae(this.F,a,1);this.dd(a,b)};h.Ae=function(a,b){this.F&&ae(this.F,a,2);this.jd(a,b)};function Cc(a,b){a.pa++;b=a.D.Bc(Ac(a,b,2));a.pa--;return b}function Qe(a,b){(b?--a.tc:--a.sc)||xe(a)}h.Gf=function(a,b,c){return Pe(this,a,b,c)};h.se=function(a,b,c){return Ac(this,Pe(this,a,b,c),c)};h.ye=function(a){return this.D.Bc(this.ib=a)};h.Zg=function(a){this.F&&$d(this.F,a,2);return this.ye(a)};h.Ed=function(a){return this.D.Bc(this.ib=Ac(this,a,2))}; h.$g=function(a){this.F&&$d(this.F,a,2);return this.Ed(a)};h.De=function(a,b){this.D.ac(this.ib=a,b)};h.si=function(a,b){this.F&&ae(this.F,a,2);this.De(a,b)};h.Id=function(a,b){this.D.ac(this.ib=Ac(this,a,4),b)};h.ti=function(a,b){this.F&&ae(this.F,a,2);this.Id(a,b)};function Re(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Pe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.X[a.w>>12&3];return c} -function Se(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Pe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Ac(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.X[a.w>>12&3]=d}function Te(a,b){b>>=6;var c=a.Y=b&7;return(b=a.U=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c+a.zc]&a.Zd}function Ue(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.U=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d+a.zc];return c}function Ve(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Pe(a,b,c,8)} +function Se(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Pe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Ac(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.X[a.w>>12&3]=d}function Te(a,b){b>>=6;var c=a.Y=b&7;return(b=a.U=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c+a.zc]&a.Yd}function Ue(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.U=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d+a.zc];return c}function Ve(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Pe(a,b,c,8)} function We(a,b){var c=a.j=b&7;return(b=a.u=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c]&255}function Xe(a,b){var c,d=a.j=b&7;(b=a.u=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d];return c}function Ye(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Wc=a.Fa(b,e,7),c=0>c?a.g[-c-1]&255:c,a.Tc(e,d.call(a,c,a.jc(e))),e&1&&a.b--):(b=a.g[e],c=0>c?a.g[-c-1]&255:c,a.g[e]=b&65280|d.call(a,c,b&255))} function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,6),a.lc(e,d.call(a,0>c?a.g[-c-1]:c,a.kc(e)))):a.g[e]=d.call(a,0>c?a.g[-c-1]:c,a.g[e])}function Ze(a,b,c,d,e){var f=a.j=b&7;(b=a.u=(b&56)>>3)?(d=a.Fa(b,f,5),e.call(a,(c=0>c?a.g[-c-1]&255:c)<<8),a.Tc(d,c),d&1&&a.b--):(c?(c=0>c?a.g[-c-1]&255:c,a.g[f]=a.g[f]&~d|c<<24>>24&d):a.g[f]&=~d,e.call(a,c<<8))} function $e(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} h.Cc=function(a){this.A.complete=!0;var b=this.F?af(this.F)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.lb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(bf(this.F,this.g[7],c)){this.ba();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.ob&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& -1&&this.i++;if(a){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.Sd(f)}while(0c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.be(f)}while(0>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Da(a);return a}function Ff(a,b){a=b&~a;this.Da(a<<8);return a} function Gf(a,b){a|=b;this.Da(a);return a}function Hf(a,b){a|=b;this.Da(a<<8);return a}function If(a,b){a=~b|65536;this.qb(a);return a&65535}function Jf(a,b){a=~b|256;this.qb(a<<8);return a&255}function Kf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Lf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Mf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Nf(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} function Of(a,b){a=-b;this.qb(a,a&b&32768);return a&65535}function Pf(a,b){a=-b;this.qb(a<<8,(a&b&128)<<8);return a&255}function Qf(a,b){a=b<<1|this.C>>16&1;Ie(this,a);return a&65535}function Rf(a,b){a=b<<1|this.C>>16&1;Ie(this,a<<8);return a&255}function Sf(a,b){a=(this.C&65536|b)>>1|b<<16;Ie(this,a);return a&65535}function Tf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Ie(this,a<<8);return a&255}function Uf(a,b){var c=b-a;Je(this,c,a,b);return c&65535} @@ -362,7 +362,7 @@ function Sk(a,b){if(!b){var c;if("object"==typeof resources&&(c=resources.parms) h.yc=function(a,b){for(var c=this,d=ta(this.id),e=0;e<=d.length;e++){var f=eUk){if(Vk(d,this.G)){this.u=new G(this,"1.34.0",cl);Vk(this.u)&&(dl(this,d),a=el,fl(this.u));this.u.set($k,ab());gl(this.u);var e=this.b&&!this.C;if(a==al||ra("Click OK to restore the previous "+Gb+" machine state, or CANCEL to reset the machine.")){if(c=Zk(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Vk(d,g):("error"==f&&"no machine state"!= g?(this.T("Error: "+g),"unable to verify user"==g&&(hb(hl,""),this.g=null)):this.v(f+": "+g),fl(d),Vk(d)?(c=Zk(d),e=!0):c=!1))}e&&Xk(this,c?d:null)}else a==el&&d.clear()}else Xk(this);delete this.G;delete this.B}e=ta(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.A.aa=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(il(this,this.f,b,c,a),H(this,-2),this.f.qa());this.N&&(dl(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; function dl(a,b){if(ra("There may be a problem with your "+Gb+" machine.\n\nTo help us diagnose it, click OK to send this "+Gb+" machine state to http://www.pcjs.org.")){var c=a.U;a=a.g||"";b=b.toString();var d={};d.app=Gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;bb("http://www.pcjs.org/api/v1/report",d,!0)}} function Ok(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new G(a,"1.34.0"),g=new G(a,"1.34.0",Yk),k=ab();g.set($k,k);f.set($k,k);f.set(jl,"1.34.0");f.set(kl,window?window.location.href:null);f.set(ll,window?window.navigator.userAgent:"");a.f&&a.f.Ba&&(c&&(b&&(a.f.A.qa=a.f.A.V),a.f.ba()),d=a.f.Ba(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.A.aa=!1,!1===d&&(e=null)));for(var k=ta(a.id),l=0;lc&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,hd:65,Lh:66,Rh:67,si:68,E:69,yi:70,Bi:71,Ni:72,Pi:73,Qi:74,Ri:75,Si:76,Vi:77,Xi:78,cj:79,fj:80,Q:81,hj:82,kj:83,tj:84,vj:85,xj:86,yj:87,Cj:88,Dj:89,Ke:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Ej:97,Fj:98,Ij:99,d:100,e:101,Jj:102,Kj:103,Lj:104,Mj:105,Qj:106,k:107,Rj:108,Sj:109,n:110,Tj:111,p:112,q:113,r:114,Uj:115,t:116,Wj:117,Xj:118,Yj:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.sd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.qd=c||0;this.D=this.c=this.u=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} +y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.qd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.pd=c||0;this.D=this.c=this.u=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} function pa(){return Date.now()||+new Date}function u(a){window&&window.alert(a)}function qa(a){var b=!1;window&&(b=window.confirm(a));return b}function ra(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>>this.h;return ib||b!=this.f?this. function Ob(a,b){var c;a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?c=e.D(d,b):c=e.i(d,b)|fc(a,b+1).i(0,b+1)<<8;a.m--;return c}function gc(a,b,c){a.l=!1;a.m++;fc(a,b).o(b&a.f,c&255,b);a.m--}function Mb(a,b,c){a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?e.m(d,c&65535,b):(e.o(d,c&255,b),fc(a,b+1).o(0,c>>8&255,b+1));a.m--} function ac(a){for(var b=0,c=[],d=0;da.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],v=g[5]||1,y=0;ya.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],v=g[5]||1,y=0;y>8:e[2](f)&255):f&1&&(e=d.Qa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return c;I(d,b,16);return 255} function Ub(a,b,c){var d=!1,e=this.controller,f=e.Qa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Qa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d||I(e,c,16)}function Vb(a,b){var c=-1,d=this.controller;a=d.Qa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return c;I(d,b,16);return 65535} function Wb(a,b,c){var d=!1,e=this.controller;a=e.Qa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d||I(e,c,16)}function K(a){r.call(this,"Device",a,256);this.a={Ia:128,dd:-1}}n(K,r);h=K.prototype;h.ja=function(a,b,c,d){this.u=b;this.A=a;this.c=c;this.D=d;var e=this;this.a.dd=mc(c,function(){e.a.Ia|=128;e.a.Ia&64&&nc(e.c,e.a.qa);e.A&&Kb(e.A,1);oc(e.c,e.a.dd,1E3/60)});this.a.qa=pc(c,64,6,2097152);qb(b,this,qc);sb(b,this.reset.bind(this));B(this)}; @@ -116,7 +116,7 @@ function Xb(a,b){a.g=a.h=0;b&&((a.g=b.g)&&Lc(a,Nc,!1),(a.h=b.h)&&Mc(a,Nc,!1))}h. h.Gg=function(a,b){var c=a>>2;a=(a&3)<<3;this.c[c]=this.c[c]&~(255<>2;a=(a&3)<<3;24>a?this.c[c]=this.c[c]&~(65535<>8);this.Ha=!0};h.kf=function(a,b){return this.i(a,b)};h.ng=function(a,b){return this.D(a,b)};h.Eg=function(a,b,c){this.A?this.Wb(0,0,c):this.o(a,b,c)};h.Fh=function(a,b,c){this.A?this.Wb(0,0,c):this.m(a,b,c)};h.jf=function(a){return this.a[a]}; h.lf=function(a){return this.a[a]};h.mg=function(a,b){hb&&a&1&&I(this.b,b,64);return this.u.getUint16(a,!0)};h.pg=function(a,b){hb&&a&1&&I(this.b,b,64);return!ib&&a&1?this.a[a]|this.a[a+1]<<8:this.l[a>>1]};h.Dg=function(a,b){this.a[a]=b;this.Ha=!0};h.Fg=function(a,b){this.a[a]=b;this.Ha=!0};h.Eh=function(a,b,c){hb&&a&1&&I(this.b,c,64);this.u.setUint16(a,b,!0);this.Ha=!0};h.Gh=function(a,b,c){hb&&a&1&&I(this.b,c,64);!ib&&a&1?(this.a[a]=b,this.a[a+1]=b>>8):this.l[a>>1]=b;this.Ha=!0}; var Dc=0,ic=1,Ec=2,Zb=4,dc=["NONE","RAM","ROM","VID","H/W"],Cc=0,Kc=[],Jc=[H.prototype.mf,H.prototype.Gg,H.prototype.qg,H.prototype.Hh],Nc=[H.prototype.kf,H.prototype.Eg,H.prototype.ng,H.prototype.Fh];if(fb)var Ic=[H.prototype.jf,H.prototype.Dg,H.prototype.mg,H.prototype.Eh],Hc=[H.prototype.lf,H.prototype.Fg,H.prototype.pg,H.prototype.Gh];var Oc;if(fb){var Qc=new ArrayBuffer(2);(new DataView(Qc)).setUint16(0,256,!0);Oc=256===(new Uint16Array(Qc))[0]}else Oc=!1;var Gc=Oc; -function Rc(a,b){r.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.fd=0;this.tc=b;this.Za=c;this.Dc=Math.round(this.tc/1E4)/100;this.jb=this.Dc*this.Za;this.Fc=this.Nb=this.mb=this.uc=0;this.j.M=this.j.cd=!1;this.j.Y=a.autoStart;"string"==typeof this.j.Y&&(this.j.Y="true"==this.j.Y);this.j.gc=!1;this.rc=this.lb=0;this.sc=+a.csStart;this.Lb=+a.csInterval;this.Mb=+a.csStop;this.X=[];this.vd=this.vg.bind(this);this.Na=this.Da=this.Ma=this.a=this.ba=this.Ca=this.Kb=this.La=this.nb=this.Gc= +function Rc(a,b){r.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.fd=0;this.tc=b;this.Za=c;this.Dc=Math.round(this.tc/1E4)/100;this.jb=this.Dc*this.Za;this.Fc=this.Nb=this.mb=this.uc=0;this.j.M=this.j.cd=!1;this.j.Y=a.autoStart;"string"==typeof this.j.Y&&(this.j.Y="true"==this.j.Y);this.j.gc=!1;this.rc=this.lb=0;this.sc=+a.csStart;this.Lb=+a.csInterval;this.Mb=+a.csStop;this.X=[];this.td=this.vg.bind(this);this.Na=this.Da=this.Ma=this.a=this.ba=this.Ca=this.Kb=this.La=this.nb=this.Gc= this.Wa=0;this.pa=null;B(this)}n(Rc,r);h=Rc.prototype;h.ja=function(a,b,c,d){this.A=a;this.u=b;this.D=d;this.pa=a.f;for(a=0;a=a.lb&&(a.lb+=a.Lb,c=!0);0<=a.Mb&&a.Mb<=Wc(a)&&(a.Lb=a.Mb=-1,Vc(a),G(a),c=!0);c&&a.aa(Wc(a)+" cycles: checksum="+Da(a.rc))}} @@ -125,15 +125,15 @@ c,!0;case "setSpeed":return this.o[b]=c,c.onclick=function(){Xc(d,d.Za<<1,!0)},c function Xc(a,b,c){if(void 0!==b){.8>a.Wa/a.jb&&(b=1);a.Za=b;b=a.Dc*a.Za;if(a.jb!=b){a.jb=b;b=a.jb.toFixed(2)+"Mhz";var d=a.o.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.A&&$c(a.A)}Ib(a,a.Da);a.Da=0;a.Ca=pa();a.La=0;Yc(a)}function mc(a,b){var c=a.X.length;a.X.push([-1,b]);return c}function oc(a,b,c,d){0<=b&&ba.X[b][0])&&(c=a.tc*a.Za/1E3*c|0,a.j.M&&(c+=ad(a)),a.X[b][0]=c)}function bd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function ad(a,b){var c=a.Ma-=a.a;a.a=a.ba=0;b&&(a.Ma=0);return c} h.vg=function(){if(this.j.M){this.uc>=this.tc&&Yc(this,!0);this.nb=0;this.Kb=pa();if(this.La){var a=this.Kb-this.La;a>this.Fc&&(this.Ca+=a,this.Ca>this.Kb&&(this.Ca=this.Kb))}try{do{for(var b,c=this.j.gc?1:this.Nb,d=this.X.length-1;0<=d;d--){var e=this.X[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.zc(b)}catch(f){if("number"!=typeof f)throw f;}b=ad(this,!0);this.nb+=b;this.Da+=b;Jb(this,b);Hb(this,b);this.mb-=b;if(0>=this.mb){this.mb+=this.Nb;++this.Gc>=cd&&(this.A&&Kb(this.A,void 0),this.Gc=0);break}}while(this.j.M)}catch(f){G(this); -this.A&&this.A.stop(pa(),Wc(this));a=f.stack||f.message;this.j.error=!0;this.G(a);return}if(this.j.M){a=setTimeout;b=this.vd;this.La=pa();c=this.Fc;this.nb&&(c=Math.round(c*this.nb/this.Nb));c-=this.La-this.Kb;if(d=this.La-this.Ca)this.Wa=Math.round(this.Da/(10*d))/100,864E5<=d&&(this.Na=0,Xc(this));if(0>c||this.Wac&&(this.Ca-=c),c=0;this.uc+=this.nb;this.La+=c;a(b,c)}}}; -function Gb(a){var b;a.j.error?(a.aa(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.j.M)a.aa(a.toString()+" busy");else{Xc(a);a.j.M=!0;a.j.cd=!0;if(b=a.o.run)b.textContent="Halt";a.A&&a.A.start(a.Ca,Wc(a));a.D||a.status("Started");setTimeout(a.vd,0)}}h.zc=function(){return 0};function G(a){var b=!1;if(a.j.M){ad(a);Ib(a,a.Da);a.Da=0;a.j.M=!1;if(b=a.o.run)b.textContent="Run";a.A&&a.A.stop(pa(),Wc(a));b=!0;a.D||a.status("Stopped")}a.j.complete=void 0;return b}var Zc=30,cd=15,Sc=["power","reset"]; -function dd(a){var b=+a.model||1170;Rc.call(this,a,6666667);this.sa=b;this.pd=+a.addrReset||0;this.Ea=this.i=this.B=this.v=this.m=this.l=this.w=0;this.b=this.ua=this.ga=[];this.H=this.s=this.Pa=this.Rb=[];this.Ka=this.C=this.od=this.kb=this.Xa=this.Ya=this.cb=this.F=this.Ob=this.$a=this.Oa=this.J=this.Pb=this.Qb=this.ta=this.g=0;this.He=[4,2,0,1];this.wc=0;this.td=255;1120>=this.sa?(this.nd=ed.bind(this),this.hb=this.Pe,this.wc=8,this.td=-1,this.zd=255,this.wd=0):(this.nd=fd.bind(this),this.hb=this.Qe, +this.A&&this.A.stop(pa(),Wc(this));a=f.stack||f.message;this.j.error=!0;this.G(a);return}if(this.j.M){a=setTimeout;b=this.td;this.La=pa();c=this.Fc;this.nb&&(c=Math.round(c*this.nb/this.Nb));c-=this.La-this.Kb;if(d=this.La-this.Ca)this.Wa=Math.round(this.Da/(10*d))/100,864E5<=d&&(this.Na=0,Xc(this));if(0>c||this.Wac&&(this.Ca-=c),c=0;this.uc+=this.nb;this.La+=c;a(b,c)}}}; +function Gb(a){var b;a.j.error?(a.aa(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.j.M)a.aa(a.toString()+" busy");else{Xc(a);a.j.M=!0;a.j.cd=!0;if(b=a.o.run)b.textContent="Halt";a.A&&a.A.start(a.Ca,Wc(a));a.D||a.status("Started");setTimeout(a.td,0)}}h.zc=function(){return 0};function G(a){var b=!1;if(a.j.M){ad(a);Ib(a,a.Da);a.Da=0;a.j.M=!1;if(b=a.o.run)b.textContent="Run";a.A&&a.A.stop(pa(),Wc(a));b=!0;a.D||a.status("Stopped")}a.j.complete=void 0;return b}var Zc=30,cd=15,Sc=["power","reset"]; +function dd(a){var b=+a.model||1170;Rc.call(this,a,6666667);this.sa=b;this.od=+a.addrReset||0;this.Ea=this.i=this.B=this.v=this.m=this.l=this.w=0;this.b=this.ua=this.ga=[];this.H=this.s=this.Pa=this.Rb=[];this.Ka=this.C=this.nd=this.kb=this.Xa=this.Ya=this.cb=this.F=this.Ob=this.$a=this.Oa=this.J=this.Pb=this.Qb=this.ta=this.g=0;this.He=[4,2,0,1];this.wc=0;this.sd=255;1120>=this.sa?(this.vd=ed.bind(this),this.hb=this.Pe,this.wc=8,this.sd=-1,this.zd=255,this.wd=0):(this.vd=fd.bind(this),this.hb=this.Qe, this.zd=~(1792|(1140>=this.sa?2048:0))&65535,this.wd=1140e.Ub&&(e.Ub=c,c+=4)}return Rc.prototype.la.call(this,a,b)}; -h.reset=function(){this.status("Model "+this.sa);this.j.M&&G(this);this.v=65536;this.m=32768;this.l=65535;this.w=32768;this.i=15;this.b=[0,0,0,0,0,0,0,this.pd,-1,-2,-3,-4,-5,-6,-7,-8];this.ua=[0,0,0,0,0,0];this.ga=[0,0,0,0];this.H=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.s=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535,65535, -65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Pa=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.Rb=[0,0,0,0,0,0,0,0];this.B=0;this.Ea=-1;this.h=this.f=this.qc=this.K=this.S=this.g=this.Ob=0;Eb(this);Uc(this);this.j.error=!1;Rc.prototype.reset.call(this)};function Eb(a){a.J=0;a.Pb=0;a.Qb=0;a.ta=0;a.F=0;a.$a=0;a.Oa=255;a.kb=0;a.Xa=0;a.Ya=0;a.cb=262143;a.Ka=a.b[7];a.C=0;a.I=null;a.u&&(gd(a),a.od=hc(a.u))} +h.reset=function(){this.status("Model "+this.sa);this.j.M&&G(this);this.v=65536;this.m=32768;this.l=65535;this.w=32768;this.i=15;this.b=[0,0,0,0,0,0,0,this.od,-1,-2,-3,-4,-5,-6,-7,-8];this.ua=[0,0,0,0,0,0];this.ga=[0,0,0,0];this.H=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.s=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Pa=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.Rb=[0,0,0,0,0,0,0,0];this.B=0;this.Ea=-1;this.h=this.f=this.qc=this.K=this.S=this.g=this.Ob=0;Eb(this);Uc(this);this.j.error=!1;Rc.prototype.reset.call(this)};function Eb(a){a.J=0;a.Pb=0;a.Qb=0;a.ta=0;a.F=0;a.$a=0;a.Oa=255;a.kb=0;a.Xa=0;a.Ya=0;a.cb=262143;a.Ka=a.b[7];a.C=0;a.I=null;a.u&&(gd(a),a.nd=hc(a.u))} function gd(a){a.kc=a.gd;a.lc=a.xc;a.yc=a.Ac;a.mc=a.Cc;a.kb?(a.Aa=65536,a.jc=a.ta&16?4186112:253952,a.ra=a.Id,a.W=a.Nd,a.Ab=a.Qd,$b(a.u,a.ta&16?22:18)):(a.Aa=0,a.jc=57344,a.ra=a.Ue,a.W=a.og,a.Ab=a.Ih,$b(a.u,16))}function sc(a){var b=a.J;b&57344||(b=b&-3199|a.Xa<<5|a.Ya<<1);return b}function tc(a,b){b&=-3073;if(a.J!=b){b&57344&&!(a.J&57344)&&(a.Pb=a.C>>16&65535,a.Qb=a.C&65535);a.J=b;a.Xa=(b&96)>>5;a.Ya=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.kb!=c&&(a.kb=c,gd(a))}} -function uc(a){a.J&57344||(a.Pb=a.C>>16&65535);a=a.Pb;a&65280&&(a=(a<<8|a>>8)&65535);return a}function vc(a){a.J&57344||(a.Qb=a.C&65535);return a.Qb}function wc(a,b){1170>a.sa&&(b&=-49);a.ta!=b&&(a.ta=b,a.cb=b&16?4194303:262143,gd(a))}function hd(a,b,c,d){a.pd=b;F(a,b);zc(a,0);a.u.reset();Eb(a);if(c){a.b[0]=d||0;for(b=1;5>=b;b++)a.b[b]=0;a.b[6]=1024;a.j.R?a.j.M||Gb(a):a.j.Y=!0}else a.D&&a.j.R?G(a)||a.A.j.reset||(a.D.g(),Kb(a.A,-1)):!1===c&&G(a);!a.j.M&&a.pa&&a.pa.stop()}h.Hd=function(){return 0}; +function uc(a){a.J&57344||(a.Pb=a.C>>16&65535);a=a.Pb;a&65280&&(a=(a<<8|a>>8)&65535);return a}function vc(a){a.J&57344||(a.Qb=a.C&65535);return a.Qb}function wc(a,b){1170>a.sa&&(b&=-49);a.ta!=b&&(a.ta=b,a.cb=b&16?4194303:262143,gd(a))}function hd(a,b,c,d){a.od=b;F(a,b);zc(a,0);a.u.reset();Eb(a);if(c){a.b[0]=d||0;for(b=1;5>=b;b++)a.b[b]=0;a.b[6]=1024;a.j.R?a.j.M||Gb(a):a.j.Y=!0}else a.D&&a.j.R?G(a)||a.A.j.reset||(a.D.g(),Kb(a.A,-1)):!1===c&&G(a);!a.j.M&&a.pa&&a.pa.stop()}h.Hd=function(){return 0}; h.save=function(){var a=new E(this);a.set(0,[this.b,this.ua,this.ga,this.H,this.s,this.Pa,this.Rb,this.F,this.Ob,this.$a,this.Oa,this.Xa,this.Ya,this.Ka,this.g,this.C,this.Ea,this.Lc,this.Nc]);a.set(1,[xc(this),sc(this),uc(this),vc(this),this.ta]);a.set(2,[this.Na,this.Za,this.j.Y]);a.set(3,id(this));a.set(4,bd(this));return a.data()}; h.restore=function(a){var b=ia(a[0]);this.b=b.next().value;this.ua=b.next().value;this.ga=b.next().value;this.H=b.next().value;this.s=b.next().value;this.Pa=b.next().value;this.Rb=b.next().value;this.F=b.next().value;this.Ob=b.next().value;this.$a=b.next().value;this.Oa=b.next().value;this.Xa=b.next().value;this.Ya=b.next().value;this.Ka=b.next().value;this.g=b.next().value;this.C=b.next().value;this.Ea=b.next().value;this.Lc=b.next().value;this.Nc=b.next().value;b=a[1];zc(this,b[0]);tc(this,b[1]); this.Pb=b[2];this.Qb=b[3];wc(this,b[4]);b=a[2];this.Na=b[0];Xc(this,b[1]);this.j.Y=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>1}function od(a,b,c,d){a.w=a.l=a.v=b;a.m=(c^d)&(d^b)} function J(a,b,c,d){if(!a.pb){0>a.Ea?a.Ea=xc(a):a.B||(d=-4);-4==d&&(a.g&256&&(d=-1),a.g|=256,a.F|=4,a.b[6]=b=4);if(-1!=d){a.C=b|4143316992;a.B=0;var e=a.W(b|a.Aa),f=a.W(b+2&65535|a.Aa);zc(a,f&-12289|a.Ea>>2&12288);pd(a,a.Ea);pd(a,a.b[7]);F(a,e)}a.a-=5;a.g&=~(c|19);a.g|=129;a.Ea=-1;a.Lc=d;a.Nc=b;-1==d&&G(a);if(-4<=d)throw b;}}function qd(a){var b=rd(a),c=rd(a);a.i&49152&&(c=c&-225|a.i&63712);F(a,b);zc(a,c);a.g&=-17} function sd(a,b){var c=b>>13&31;31>c&&(b=a.ta&32?a.Pa[c]+(b&8191)&4194303:b&-3932161);return b} -function Nb(a,b,c){var d,e,f;if(!(c&a.kb))return f=b&65535,57344<=f&&(f|=a.jc),f;d=b>>13;a.ta&a.He[a.B]||(d&=7);e=a.s[a.B][d];f=(a.H[a.B][d]<<6)+(b&8191)&a.cb;3932160<=f&&(f=sd(a,f));if(a.pb)return f;f>=a.od&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& +function Nb(a,b,c){var d,e,f;if(!(c&a.kb))return f=b&65535,57344<=f&&(f|=a.jc),f;d=b>>13;a.ta&a.He[a.B]||(d&=7);e=a.s[a.B][d];f=(a.H[a.B][d]<<6)+(b&8191)&a.cb;3932160<=f&&(f=sd(a,f));if(a.pb)return f;f>=a.nd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& (g|=16384));a.s[a.B][d]=e;if(f!=(4194170&a.cb)||a.B)a.Xa=a.B,a.Ya=d;g&&(g&57344&&(0<=a.Ea&&(g|=128),a.J&57344||(g|=a.J&4096|a.Xa<<5|a.Ya<<1,tc(a,a.J&-61695|g&61694)),J(a,168,64,-2)),a.J&61440||!(f<(4191360&a.cb)||f>(4194239&a.cb))||(a.J|=4096,a.J&512&&(a.g|=64)));return f}function rd(a){var b=a.W(a.b[6]|a.Aa);a.b[6]=a.b[6]+2&65535;return b}function pd(a,b){var c=a.b[6]-2&65535;a.b[6]=c;a.C=a.C&65535|(a.C&-65536)<<8|16121856;a.g&256||a.hb(4,-2,c);a.Ab(c,b)} function td(a,b,c,d){var e,f,g=d&8?0:a.Aa;switch(b){case 0:return J(a,4,0,-3),0;case 1:return 6==c&&a.hb(d,0,a.b[6]),a.a-=3,7==c?a.b[c]:a.b[c]|g;case 2:f=2;e=a.b[c];6==c&&a.hb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.a-=3;break;case 3:f=2;e=a.b[c];7!=c&&(e|=g);e=a.W(e);e|=g;a.a-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.b[c]+f&65535;6==c&&a.hb(d,f,e);7!=c&&(e|=g);a.a-=4;break;case 5:f=-2;e=a.b[c]-2&65535;7!=c&&(e|=g);e=a.W(e)|g;a.a-=8;break;case 6:return e=a.W(ld(a,2)),e=e+a.b[c]&65535,6==c&&a.hb(d,0, e),a.a-=6,e|g;case 7:return e=a.W(ld(a,2)),e=e+a.b[c]&65535,e=a.W(e|a.Aa),a.a-=10,e|g}a.b[c]=a.b[c]+f&65535;a.C=a.C&65535|(a.C&-65536)<<8|(f<<3&248|c)<<16;return e}h.Pe=function(a,b,c){!this.B&&0>=b&&c<=this.Oa&&(this.g|=32)};h.Qe=function(a,b,c){this.B||(65534<=c&&(c|=-65536),a&4&&c<=this.Oa&&(c<=this.Oa-32?J(this,4,0,-4):(this.F|=8,this.g|=32)))};h.Te=function(a){return this.gd(a)};h.Ve=function(a){return this.xc(a)};h.xg=function(a,b){this.Ac(a,b)};h.Ag=function(a,b){this.Cc(a,b)}; h.Ue=function(a,b,c){return td(this,a,b,c)};h.Id=function(a,b,c){return Nb(this,td(this,a,b,c),c)};h.og=function(a){return this.u.Xb(this.Ka=a)};h.Nd=function(a){return this.u.Xb(this.Ka=Nb(this,a,2))};h.Ih=function(a,b){this.u.Yb(this.Ka=a,b)};h.Qd=function(a,b){this.u.Yb(this.Ka=Nb(this,a,4),b)}; function ud(a,b,c){var d=a.f=b&7;(b=a.h=(b&56)>>3)?(d=td(a,b,d,2),c&65536||61440!==(a.i&61440)&&(d&=65535),a.B=a.i>>12&3,c=a.W(d|c&a.Aa),a.B=a.i>>14&3):c=6!=d||(a.i>>2&12288)===(a.i&12288)?a.b[d]:a.ga[a.i>>12&3];return c}function vd(a,b,c,d){a.C=a.C&65535|1441792;var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=td(a,b,e,4),c&65536||(e&=65535),a.B=a.i>>12&3,e=Nb(a,e|c&65536,4),a.B=a.i>>14&3,a.mc(e,d)):6!=e||(a.i>>2&12288)===(a.i&12288)?a.b[e]=d:a.ga[a.i>>12&3]=d} -function wd(a,b){b>>=6;var c=a.S=b&7;return(b=a.K=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c+a.wc]&a.td}function xd(a,b){var c;b>>=6;var d=a.S=b&7;(b=a.K=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d+a.wc];return c}function yd(a,b){var c=a.f=b&7;b=a.h=(b&56)>>3;return td(a,b,c,8)}function zd(a,b){var c=a.f=b&7;return(b=a.h=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c]&255}function Ad(a,b){var c,d=a.f=b&7;(b=a.h=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d];return c} +function wd(a,b){b>>=6;var c=a.S=b&7;return(b=a.K=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c+a.wc]&a.sd}function xd(a,b){var c;b>>=6;var d=a.S=b&7;(b=a.K=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d+a.wc];return c}function yd(a,b){var c=a.f=b&7;b=a.h=(b&56)>>3;return td(a,b,c,8)}function zd(a,b){var c=a.f=b&7;return(b=a.h=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c]&255}function Ad(a,b){var c,d=a.f=b&7;(b=a.h=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d];return c} function P(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.qc=a.ra(b,e,7),c=0>c?a.b[-c-1]&255:c,a.yc(e,d.call(a,c,a.kc(e))),e&1&&a.a--):(b=a.b[e],c=0>c?a.b[-c-1]&255:c,a.b[e]=b&65280|d.call(a,c,b&255))}function Q(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,6),a.mc(e,d.call(a,0>c?a.b[-c-1]:c,a.lc(e)))):a.b[e]=d.call(a,0>c?a.b[-c-1]:c,a.b[e])} function Bd(a,b,c,d,e){var f=a.f=b&7;(b=a.h=(b&56)>>3)?(d=a.ra(b,f,5),e.call(a,(c=0>c?a.b[-c-1]&255:c)<<8),a.yc(d,c),d&1&&a.a--):(c?(c=0>c?a.b[-c-1]&255:c,a.b[f]=a.b[f]&~d|c<<24>>24&d):a.b[f]&=~d,e.call(a,c<<8))}function Cd(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,4),d.call(a,c=0>c?a.b[-c-1]:c),a.mc(e,c)):(a.b[e]=c=0>c?a.b[-c-1]:c,d.call(a,c))} h.zc=function(a){this.j.complete=!0;var b=a?this.j.cd?0:1:-1;this.j.cd=!1;this.Ma=this.a=a;this.g=this.g&-5|0;do{if(this.g){if(a=this.g&11)if(a=!1,this.g&2){var c=160,d=(this.$a&224)>>5,e=this.I&&this.I.sb>d?this.I:null;e&&(c=e.Ub,d=e.sb);d>(this.i&224)>>5?(this.g&8&&(ld(this,2),this.g&=-9),J(this,c,0,-10),d=!0):d=!1;d&&(e&&rc(this,e),a=!0);this.I||this.$a||(this.g&=-3)}else this.g&1&&this.g++;if(a){if(this.g&4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}if(this.g&112&&md(this)){if(this.g& -4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.nd(e)}while(0b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.vd(e)}while(0>1|b<<16;nd(this,a);return a&65535}function Id(a,b){a=b&128|b>>1|b<<8;nd(this,a<<8);return a&255}function Jd(a,b){a=b&~a;this.fa(a);return a}function Kd(a,b){a=b&~a;this.fa(a<<8);return a}function Ld(a,b){a|=b;this.fa(a);return a}function Md(a,b){a|=b;this.fa(a<<8);return a} function Nd(a,b){a=~b|65536;this.Sa(a);return a&65535}function Od(a,b){a=~b|256;this.Sa(a<<8);return a&255}function Pd(a,b){this.w=this.l=a=b-a;this.m=b&(b^a);return a&65535}function Qd(a,b){a=b-a;var c=a<<8;b<<=8;this.w=this.l=c;this.m=b&(b^c);return a&255}function Rd(a,b){this.w=this.l=a=b+a;this.m=a&(b^a);return a&65535}function Sd(a,b){a=b+a;var c=a<<8;this.w=this.l=c;this.m=c&(b<<8^c);return a&255}function Td(a,b){a=-b;this.Sa(a,a&b&32768);return a&65535} function Ud(a,b){a=-b;this.Sa(a<<8,(a&b&128)<<8);return a&255}function Vd(a,b){a=b<<1|this.v>>16&1;nd(this,a);return a&65535}function Wd(a,b){a=b<<1|this.v>>16&1;nd(this,a<<8);return a&255}function Xd(a,b){a=(this.v&65536|b)>>1|b<<16;nd(this,a);return a&65535}function Yd(a,b){a=((this.v&65536)>>8|b)>>1|b<<8;nd(this,a<<8);return a&255}function Zd(a,b){var c=b-a;od(this,c,a,b);return c&65535}function $d(a,b){var c=b-a;od(this,c<<8,a<<8,b<<8);return c&255} @@ -231,7 +231,7 @@ function vg(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){u(a.typ h.ma=function(a,b,c){var d=this;switch(b){case "listDisks":return this.o[b]=c,c.onchange=function(){wg(d)},!0;case "descDisk":case "listDrives":return this.o[b]=c,c.onchange=function(){var a=Ba(c.value,10);null!=a&&xg(d,a)},!0;case "loadDisk":return this.o[b]=c,c.onclick=function(){d.Zc()},!0;case "bootDisk":return this.o[b]=c,c.onclick=function(){d.Ed()},!0;case "saveDisk":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.onclick=function(){var a=d.o.listDrives;if(a&&a.options&&d.b)if(a= d.b[Ba(a.value,10)||0])if(a=a.O){var b;b="";for(var c=0,k;k=rg(a,c++);)for(var l=0,m=k.length;lfh){if(gh(d,this.s)){this.h=new E(this,"1.34.0",qh);gh(this.h)&&(rh(this,d),a=sh,th(this.h));this.h.set(lh,La());uh(this.h);var e=this.a&&!this.l;if(a==mh||qa("Click OK to restore the previous "+gb+" machine state, or CANCEL to reset the machine.")){if(c=kh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gh(d,g):("error"==f&&"no machine state"!= g?(this.G("Error: "+g),"unable to verify user"==g&&(Sa(vh,""),this.b=null)):this.aa(f+": "+g),th(d),gh(d)?(c=kh(d),e=!0):c=!1))}e&&ih(this,c?d:null)}else a==sh&&d.clear()}else ih(this);delete this.s;delete this.m}e=ra(this.id);for(f=0;fa[1];a=a[2];this.H=!0;this.j.R=!0;var d=this.o.power;d&&(d.textContent="Shutdown");this.c&&(wh(this,this.c,b,c,a),Kb(this,-2),this.c.Y());this.C&&(rh(this,b),b.clear());!c&&this.h&&(this.h.clear(),delete this.h);this.g=0}; function rh(a,b){if(qa("There may be a problem with your "+gb+" machine.\n\nTo help us diagnose it, click OK to send this "+gb+" machine state to http://www.pcjs.org.")){var c=a.K;a=a.b||"";b=b.toString();var d={};d.app=gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}} function xh(a,b,c){var d,e="none";if(a.g)return null;a.g--;var f=new E(a,"1.34.0"),g=new E(a,"1.34.0",jh),k=La();g.set(lh,k);f.set(lh,k);f.set(yh,"1.34.0");f.set(zh,window?window.location.href:null);f.set(Ah,window?window.navigator.userAgent:"");a.c&&a.c.ka&&(c&&(b&&(a.c.j.Y=a.c.j.M),G(a.c)),d=a.c.ka(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.j.R=!1,!1===d&&(e=null)));for(var k=ra(a.id),l=0;l Date: Sun, 26 Feb 2017 10:51:49 -0800 Subject: [PATCH 15/30] Implemented my first 4 PDP-10 opcodes (HLL, HLLI, HLLM, HLLS) --- modules/pdp10/lib/cpuops.js | 2280 ++++++++++++++-------------- modules/pdp10/lib/cpustate.js | 16 +- modules/pdp10/lib/debugger.js | 4 +- modules/pdp10/lib/defines.js | 6 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 305 ++-- versions/pdpjs/1.34.0/pdp10.js | 188 +-- 6 files changed, 1428 insertions(+), 1371 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index a446a766f..22f15ce4e 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -33,6 +33,25 @@ if (NODE) { var PDP10 = require("./defines"); } +/** + * opKA10(op) + * + * Originally, we received the full opcode (36 bits), then only the upper half-word (18 bits), + * and now we receive only the upper 13 bits. However, the octal values shown in the table and + * function comments below still include all 18 bits of the original upper half-word, so that + * you don't have to mentally un-shift them 5 bits. + * + * @this {CPUStatePDP10} + * @param {number} op (the top 13 bits of the original opcode, shifted right to bit 0) + */ +PDP10.opKA10 = function(op) +{ + /* + * We shift op right 4 more bits, leaving only the 9 bits required for the table index. + */ + PDP10.aOpXXX_KA10[op >> 4].call(this, op); +}; + /** * opUUO(0o0xx000): Unimplemented User Operation * @@ -56,11 +75,11 @@ if (NODE) { * For a second processor connected to the same memory, the UUO trap is locations 140-141 instead of 40-41. * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opUUO = function(opCode) +PDP10.opUUO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** @@ -82,11 +101,11 @@ PDP10.opUUO = function(opCode) * overflows, in which case it is greater by 1. Exponent overflow can occur only in the latter case. * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opUFA = function(opCode) +PDP10.opUFA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** @@ -101,11 +120,11 @@ PDP10.opUFA = function(opCode) * of bits 0-8 of that location. * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDFN = function(opCode) +PDP10.opDFN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** @@ -133,11 +152,11 @@ PDP10.opDFN = function(opCode) * (233(base 8) = 155(base 10) = 128 + 27). * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSC = function(opCode) +PDP10.opFSC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** @@ -160,4007 +179,4040 @@ PDP10.opFSC = function(opCode) * repeated. * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIBP = function(opCode) +PDP10.opIBP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opILDB(0o134000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opILDB = function(opCode) +PDP10.opILDB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opLDB(0o135000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opLDB = function(opCode) +PDP10.opLDB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIDPB(0o136000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIDPB = function(opCode) +PDP10.opIDPB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDPB(0o137000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDPB = function(opCode) +PDP10.opDPB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFAD(0o140000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFAD = function(opCode) +PDP10.opFAD = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADI(0o141000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADI = function(opCode) +PDP10.opFADI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADM(0o142000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADM = function(opCode) +PDP10.opFADM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADB(0o143000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADB = function(opCode) +PDP10.opFADB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADR(0o144000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADR = function(opCode) +PDP10.opFADR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADRI(0o145000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADRI = function(opCode) +PDP10.opFADRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADRM(0o146000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADRM = function(opCode) +PDP10.opFADRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFADRB(0o147000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFADRB = function(opCode) +PDP10.opFADRB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSB(0o150000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSB = function(opCode) +PDP10.opFSB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBI(0o151000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBI = function(opCode) +PDP10.opFSBI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBM(0o152000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBM = function(opCode) +PDP10.opFSBM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBB(0o153000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBB = function(opCode) +PDP10.opFSBB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBR(0o154000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBR = function(opCode) +PDP10.opFSBR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBRI(0o155000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBRI = function(opCode) +PDP10.opFSBRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBRM(0o156000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBRM = function(opCode) +PDP10.opFSBRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFSBRB(0o157000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFSBRB = function(opCode) +PDP10.opFSBRB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMP(0o160000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMP = function(opCode) +PDP10.opFMP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPI(0o161000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPI = function(opCode) +PDP10.opFMPI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPM(0o162000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPM = function(opCode) +PDP10.opFMPM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPB(0o163000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPB = function(opCode) +PDP10.opFMPB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPR(0o164000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPR = function(opCode) +PDP10.opFMPR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPRI(0o165000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPRI = function(opCode) +PDP10.opFMPRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPRM(0o166000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPRM = function(opCode) +PDP10.opFMPRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFMPRB(0o167000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFMPRB = function(opCode) +PDP10.opFMPRB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDV(0o170000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDV = function(opCode) +PDP10.opFDV = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVI(0o171000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVI = function(opCode) +PDP10.opFDVI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVM(0o172000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVM = function(opCode) +PDP10.opFDVM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVB(0o173000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVB = function(opCode) +PDP10.opFDVB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVR(0o174000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVR = function(opCode) +PDP10.opFDVR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVRI(0o175000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVRI = function(opCode) +PDP10.opFDVRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVRM(0o176000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVRM = function(opCode) +PDP10.opFDVRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opFDVRB(0o177000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opFDVRB = function(opCode) +PDP10.opFDVRB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOV(0o200000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOV = function(opCode) +PDP10.opMOV = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVI(0o201000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVI = function(opCode) +PDP10.opMOVI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVM(0o200000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVM = function(opCode) +PDP10.opMOVM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVS(0o200000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVS = function(opCode) +PDP10.opMOVS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVSI(0o205000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVSI = function(opCode) +PDP10.opMOVSI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVSM(0o206000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVSM = function(opCode) +PDP10.opMOVSM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVSS(0o207000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVSS = function(opCode) +PDP10.opMOVSS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVN(0o210000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVN = function(opCode) +PDP10.opMOVN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVNI(0o211000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVNI = function(opCode) +PDP10.opMOVNI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVNM(0o212000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVNM = function(opCode) +PDP10.opMOVNM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVNS(0o213000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVNS = function(opCode) +PDP10.opMOVNS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVMI(0o215000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVMI = function(opCode) +PDP10.opMOVMI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVMM(0o216000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVMM = function(opCode) +PDP10.opMOVMM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMOVMS(0o217000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMOVMS = function(opCode) +PDP10.opMOVMS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIMUL(0o220000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIMUL = function(opCode) +PDP10.opIMUL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIMULI(0o221000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIMULI = function(opCode) +PDP10.opIMULI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIMULM(0o222000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIMULM = function(opCode) +PDP10.opIMULM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIMULB(0o223000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIMULB = function(opCode) +PDP10.opIMULB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMUL(0o224000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMUL = function(opCode) +PDP10.opMUL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMULI(0o225000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMULI = function(opCode) +PDP10.opMULI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMULM(0o226000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMULM = function(opCode) +PDP10.opMULM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opMULB(0o227000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opMULB = function(opCode) +PDP10.opMULB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIDIV(0o230000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIDIV = function(opCode) +PDP10.opIDIV = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIDIVI(0o231000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIDIVI = function(opCode) +PDP10.opIDIVI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIDIVM(0o232000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIDIVM = function(opCode) +PDP10.opIDIVM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIDIVB(0o233000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIDIVB = function(opCode) +PDP10.opIDIVB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDIV(0o234000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDIV = function(opCode) +PDP10.opDIV = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDIVI(0o235000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDIVI = function(opCode) +PDP10.opDIVI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDIVM(0o236000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDIVM = function(opCode) +PDP10.opDIVM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDIVB(0o237000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDIVB = function(opCode) +PDP10.opDIVB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opASH(0o240000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opASH = function(opCode) +PDP10.opASH = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opROT(0o241000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opROT = function(opCode) +PDP10.opROT = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opLSH(0o242000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opLSH = function(opCode) +PDP10.opLSH = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJFFO(0o243000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJFFO = function(opCode) +PDP10.opJFFO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opASHC(0o244000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opASHC = function(opCode) +PDP10.opASHC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opROTC(0o245000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opROTC = function(opCode) +PDP10.opROTC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opLSHC(0o246000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opLSHC = function(opCode) +PDP10.opLSHC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opEXCH(0o250000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opEXCH = function(opCode) +PDP10.opEXCH = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opBLT(0o251000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opBLT = function(opCode) +PDP10.opBLT = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOBJP(0o252000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOBJP = function(opCode) +PDP10.opAOBJP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOBJN(0o253000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOBJN = function(opCode) +PDP10.opAOBJN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJRST(0o254000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJRST = function(opCode) +PDP10.opJRST = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJFCL(0o255000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJFCL = function(opCode) +PDP10.opJFCL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opXCT(0o256000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opXCT = function(opCode) +PDP10.opXCT = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opPUSHJ(0o260000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opPUSHJ = function(opCode) +PDP10.opPUSHJ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opPUSH(0o261000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opPUSH = function(opCode) +PDP10.opPUSH = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opPOP(0o262000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opPOP = function(opCode) +PDP10.opPOP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opPOPJ(0o263000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opPOPJ = function(opCode) +PDP10.opPOPJ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJSR(0o264000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJSR = function(opCode) +PDP10.opJSR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJSP(0o265000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJSP = function(opCode) +PDP10.opJSP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJSA(0o266000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJSA = function(opCode) +PDP10.opJSA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJRA(0o267000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJRA = function(opCode) +PDP10.opJRA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opADD(0o270000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opADD = function(opCode) +PDP10.opADD = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opADDI(0o271000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opADDI = function(opCode) +PDP10.opADDI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opADDM(0o272000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opADDM = function(opCode) +PDP10.opADDM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opADDB(0o273000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opADDB = function(opCode) +PDP10.opADDB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSUB(0o274000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSUB = function(opCode) +PDP10.opSUB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSUBI(0o275000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSUBI = function(opCode) +PDP10.opSUBI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSUBM(0o276000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSUBM = function(opCode) +PDP10.opSUBM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSUBB(0o277000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSUBB = function(opCode) +PDP10.opSUBB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAI(0o300000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAI = function(opCode) +PDP10.opCAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIL(0o301000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIL = function(opCode) +PDP10.opCAIL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIE(0o302000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIE = function(opCode) +PDP10.opCAIE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAILE(0o303000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAILE = function(opCode) +PDP10.opCAILE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIA(0o304000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIA = function(opCode) +PDP10.opCAIA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIGE(0o305000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIGE = function(opCode) +PDP10.opCAIGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIN(0o306000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIN = function(opCode) +PDP10.opCAIN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAIG(0o307000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAIG = function(opCode) +PDP10.opCAIG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCA(0o310000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCA = function(opCode) +PDP10.opCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAL(0o311000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAL = function(opCode) +PDP10.opCAL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAE(0o312000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAE = function(opCode) +PDP10.opCAE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCALE(0o313000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCALE = function(opCode) +PDP10.opCALE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAA(0o314000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAA = function(opCode) +PDP10.opCAA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAGE(0o315000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAGE = function(opCode) +PDP10.opCAGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAN(0o316000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAN = function(opCode) +PDP10.opCAN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCAG(0o317000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCAG = function(opCode) +PDP10.opCAG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMP(0o320000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMP = function(opCode) +PDP10.opJUMP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPL(0o321000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPL = function(opCode) +PDP10.opJUMPL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPE(0o322000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPE = function(opCode) +PDP10.opJUMPE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPLE(0o323000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPLE = function(opCode) +PDP10.opJUMPLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPA(0o324000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPA = function(opCode) +PDP10.opJUMPA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPGE(0o325000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPGE = function(opCode) +PDP10.opJUMPGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPN(0o326000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPN = function(opCode) +PDP10.opJUMPN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opJUMPG(0o327000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opJUMPG = function(opCode) +PDP10.opJUMPG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIP(0o330000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIP = function(opCode) +PDP10.opSKIP = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPL(0o331000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPL = function(opCode) +PDP10.opSKIPL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPE(0o332000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPE = function(opCode) +PDP10.opSKIPE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPLE(0o333000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPLE = function(opCode) +PDP10.opSKIPLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPA(0o334000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPA = function(opCode) +PDP10.opSKIPA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPGE(0o335000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPGE = function(opCode) +PDP10.opSKIPGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPN(0o336000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPN = function(opCode) +PDP10.opSKIPN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSKIPG(0o337000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSKIPG = function(opCode) +PDP10.opSKIPG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJ(0o340000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJ = function(opCode) +PDP10.opAOJ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJL(0o341000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJL = function(opCode) +PDP10.opAOJL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJE(0o342000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJE = function(opCode) +PDP10.opAOJE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJLE(0o343000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJLE = function(opCode) +PDP10.opAOJLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJA(0o344000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJA = function(opCode) +PDP10.opAOJA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJGE(0o345000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJGE = function(opCode) +PDP10.opAOJGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJN(0o346000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJN = function(opCode) +PDP10.opAOJN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOJG(0o347000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOJG = function(opCode) +PDP10.opAOJG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOS(0o350000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOS = function(opCode) +PDP10.opAOS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSL(0o351000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSL = function(opCode) +PDP10.opAOSL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSE(0o352000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSE = function(opCode) +PDP10.opAOSE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSLE(0o353000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSLE = function(opCode) +PDP10.opAOSLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSA(0o354000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSA = function(opCode) +PDP10.opAOSA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSGE(0o355000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSGE = function(opCode) +PDP10.opAOSGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSN(0o356000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSN = function(opCode) +PDP10.opAOSN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAOSG(0o357000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAOSG = function(opCode) +PDP10.opAOSG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJ(0o360000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJ = function(opCode) +PDP10.opSOJ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJL(0o361000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJL = function(opCode) +PDP10.opSOJL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJE(0o362000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJE = function(opCode) +PDP10.opSOJE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJLE(0o363000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJLE = function(opCode) +PDP10.opSOJLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJA(0o364000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJA = function(opCode) +PDP10.opSOJA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJGE(0o365000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJGE = function(opCode) +PDP10.opSOJGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJN(0o366000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJN = function(opCode) +PDP10.opSOJN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOJG(0o367000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOJG = function(opCode) +PDP10.opSOJG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOS(0o370000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOS = function(opCode) +PDP10.opSOS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSL(0o371000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSL = function(opCode) +PDP10.opSOSL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSE(0o372000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSE = function(opCode) +PDP10.opSOSE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSLE(0o373000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSLE = function(opCode) +PDP10.opSOSLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSA(0o374000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSA = function(opCode) +PDP10.opSOSA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSGE(0o375000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSGE = function(opCode) +PDP10.opSOSGE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSN(0o376000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSN = function(opCode) +PDP10.opSOSN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSOSG(0o377000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSOSG = function(opCode) +PDP10.opSOSG = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETZ(0o400000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETZ = function(opCode) +PDP10.opSETZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETZI(0o401000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETZI = function(opCode) +PDP10.opSETZI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETZM(0o402000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETZM = function(opCode) +PDP10.opSETZM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETZB(0o403000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETZB = function(opCode) +PDP10.opSETZB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opAND(0o404000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opAND = function(opCode) +PDP10.opAND = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDI(0o405000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDI = function(opCode) +PDP10.opANDI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDM(0o406000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDM = function(opCode) +PDP10.opANDM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDB(0o407000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDB = function(opCode) +PDP10.opANDB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCA(0o410000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCA = function(opCode) +PDP10.opANDCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCAI(0o411000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCAI = function(opCode) +PDP10.opANDCAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCAM(0o412000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCAM = function(opCode) +PDP10.opANDCAM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCAB(0o413000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCAB = function(opCode) +PDP10.opANDCAB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETM(0o414000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETM = function(opCode) +PDP10.opSETM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETMI(0o415000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETMI = function(opCode) +PDP10.opSETMI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETMM(0o416000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETMM = function(opCode) +PDP10.opSETMM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETMB(0o417000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETMB = function(opCode) +PDP10.opSETMB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCM(0o420000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCM = function(opCode) +PDP10.opANDCM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCMI(0o421000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCMI = function(opCode) +PDP10.opANDCMI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCMM(0o422000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCMM = function(opCode) +PDP10.opANDCMM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCMB(0o423000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCMB = function(opCode) +PDP10.opANDCMB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETA(0o424000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETA = function(opCode) +PDP10.opSETA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETAI(0o425000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETAI = function(opCode) +PDP10.opSETAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETAM(0o426000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETAM = function(opCode) +PDP10.opSETAM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETAB(0o427000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETAB = function(opCode) +PDP10.opSETAB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opXOR(0o430000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opXOR = function(opCode) +PDP10.opXOR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opXORI(0o431000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opXORI = function(opCode) +PDP10.opXORI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opXORM(0o432000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opXORM = function(opCode) +PDP10.opXORM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opXORB(0o433000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opXORB = function(opCode) +PDP10.opXORB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIOR(0o434000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIOR = function(opCode) +PDP10.opIOR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIORI(0o435000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIORI = function(opCode) +PDP10.opIORI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIORM(0o436000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIORM = function(opCode) +PDP10.opIORM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opIORB(0o437000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIORB = function(opCode) +PDP10.opIORB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCB(0o440000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCB = function(opCode) +PDP10.opANDCB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCBI(0o441000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCBI = function(opCode) +PDP10.opANDCBI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCBM(0o442000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCBM = function(opCode) +PDP10.opANDCBM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opANDCBB(0o443000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opANDCBB = function(opCode) +PDP10.opANDCBB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opEQV(0o444000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opEQV = function(opCode) +PDP10.opEQV = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opEQVI(0o445000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opEQVI = function(opCode) +PDP10.opEQVI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opEQVM(0o446000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opEQVM = function(opCode) +PDP10.opEQVM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opEQVB(0o447000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opEQVB = function(opCode) +PDP10.opEQVB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCA(0o450000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCA = function(opCode) +PDP10.opSETCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCAI(0o451000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCAI = function(opCode) +PDP10.opSETCAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCAM(0o452000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCAM = function(opCode) +PDP10.opSETCAM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCAB(0o453000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCAB = function(opCode) +PDP10.opSETCAB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCA(0o454000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCA = function(opCode) +PDP10.opORCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCAI(0o455000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCAI = function(opCode) +PDP10.opORCAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCAM(0o456000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCAM = function(opCode) +PDP10.opORCAM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCAB(0o457000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCAB = function(opCode) +PDP10.opORCAB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCM(0o460000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCM = function(opCode) +PDP10.opSETCM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCMI(0o461000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCMI = function(opCode) +PDP10.opSETCMI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCMM(0o462000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCMM = function(opCode) +PDP10.opSETCMM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETCMB(0o463000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETCMB = function(opCode) +PDP10.opSETCMB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCM(0o464000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCM = function(opCode) +PDP10.opORCM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCMI(0o465000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCMI = function(opCode) +PDP10.opORCMI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCMM(0o466000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCMM = function(opCode) +PDP10.opORCMM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCMB(0o467000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCMB = function(opCode) +PDP10.opORCMB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCB(0o470000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCB = function(opCode) +PDP10.opORCB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCBI(0o471000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCBI = function(opCode) +PDP10.opORCBI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCBM(0o472000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCBM = function(opCode) +PDP10.opORCBM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opORCBB(0o473000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opORCBB = function(opCode) +PDP10.opORCBB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETO(0o474000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETO = function(opCode) +PDP10.opSETO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETOI(0o475000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETOI = function(opCode) +PDP10.opSETOI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETOM(0o476000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETOM = function(opCode) +PDP10.opSETOM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opSETOB(0o477000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opSETOB = function(opCode) +PDP10.opSETOB = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** - * opHLL(0o500000) + * opHLL(0o500000): Half Word Left to Left + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * + * Move the left half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination are lost. + * + * For HLL, the source is [E] and the destination is [A]. * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLL = function(opCode) +PDP10.opHLL = function(op) { - this.opUndefined(opCode); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(this.regEA); + var dst = this.readWord(a); + dst = (dst & PDP10.RHWORD_MASK) + (src - (src & PDP10.RHWORD_MASK)); + this.writeWord(a, dst); }; /** * opHLLI(0o501000) * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * + * Move the left half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination are lost. + * + * For HLLI, the source is 0,E and the destination is [A]. But since this is a left-half-only operation, src is + * effectively 0. + * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLI = function(opCode) +PDP10.opHLLI = function(op) { - this.opUndefined(opCode); + var a = op & PDP10.OPCODE.A_MASK; + var dst = this.readWord(a); + dst = (dst & PDP10.RHWORD_MASK); + this.writeWord(a, dst); }; /** * opHLLM(0o502000) * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * + * Move the left half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination are lost. + * + * For HLLM, the source is [A] and the destination is [E]. + * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLM = function(opCode) +PDP10.opHLLM = function(op) { - this.opUndefined(opCode); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(a); + var dst = this.readWord(this.regEA); + dst = (dst & PDP10.RHWORD_MASK) + (src - (src & PDP10.RHWORD_MASK)); + this.writeWord(this.regEA, dst); }; /** * opHLLS(0o503000) * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * + * Move the left half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination are lost. + * + * If A is zero, HLLS is a no-op, otherwise it is equivalent to HLL. + * + * For HLLS, the source is [E] and the destination is [E] (and also [A] if A is non-zero). + * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLS = function(opCode) +PDP10.opHLLS = function(op) { - this.opUndefined(opCode); + if (op & PDP10.OPCODE.A_MASK) { + PDP10.opHLL.call(this, op); + } }; /** * opHRL(0o504000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRL = function(opCode) +PDP10.opHRL = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLI(0o505000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLI = function(opCode) +PDP10.opHRLI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLM(0o506000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLM = function(opCode) +PDP10.opHRLM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLS(0o507000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLS = function(opCode) +PDP10.opHRLS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLZ(0o510000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLZ = function(opCode) +PDP10.opHLLZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLZI(0o511000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLZI = function(opCode) +PDP10.opHLLZI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLZM(0o512000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLZM = function(opCode) +PDP10.opHLLZM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLZS(0o513000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLZS = function(opCode) +PDP10.opHLLZS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLZ(0o514000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLZ = function(opCode) +PDP10.opHRLZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLZI(0o515000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLZI = function(opCode) +PDP10.opHRLZI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLZM(0o516000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLZM = function(opCode) +PDP10.opHRLZM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLZS(0o517000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLZS = function(opCode) +PDP10.opHRLZS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLO(0o520000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLO = function(opCode) +PDP10.opHLLO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLOI(0o521000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLOI = function(opCode) +PDP10.opHLLOI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLOM(0o522000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLOM = function(opCode) +PDP10.opHLLOM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLOS(0o523000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLOS = function(opCode) +PDP10.opHLLOS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLO(0o524000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLO = function(opCode) +PDP10.opHRLO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLOI(0o525000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLOI = function(opCode) +PDP10.opHRLOI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLOM(0o526000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLOM = function(opCode) +PDP10.opHRLOM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLOS(0o527000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLOS = function(opCode) +PDP10.opHRLOS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLE(0o530000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLE = function(opCode) +PDP10.opHLLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLEI(0o531000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLEI = function(opCode) +PDP10.opHLLEI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLEM(0o532000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLEM = function(opCode) +PDP10.opHLLEM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLLES(0o533000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLLES = function(opCode) +PDP10.opHLLES = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLE(0o534000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLE = function(opCode) +PDP10.opHRLE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLEI(0o535000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLEI = function(opCode) +PDP10.opHRLEI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLEM(0o536000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLEM = function(opCode) +PDP10.opHRLEM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRLES(0o537000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRLES = function(opCode) +PDP10.opHRLES = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRR(0o540000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRR = function(opCode) +PDP10.opHRR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRI(0o541000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRI = function(opCode) +PDP10.opHRRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRM(0o542000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRM = function(opCode) +PDP10.opHRRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRS(0o543000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRS = function(opCode) +PDP10.opHRRS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLR(0o544000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLR = function(opCode) +PDP10.opHLR = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRI(0o545000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRI = function(opCode) +PDP10.opHLRI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRM(0o546000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRM = function(opCode) +PDP10.opHLRM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRS(0o547000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRS = function(opCode) +PDP10.opHLRS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRZ(0o550000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRZ = function(opCode) +PDP10.opHRRZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRZI(0o551000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRZI = function(opCode) +PDP10.opHRRZI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRZM(0o552000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRZM = function(opCode) +PDP10.opHRRZM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRZS(0o553000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRZS = function(opCode) +PDP10.opHRRZS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRZ(0o554000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRZ = function(opCode) +PDP10.opHLRZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRZI(0o555000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRZI = function(opCode) +PDP10.opHLRZI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRZM(0o556000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRZM = function(opCode) +PDP10.opHLRZM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRZS(0o557000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRZS = function(opCode) +PDP10.opHLRZS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRO(0o560000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRO = function(opCode) +PDP10.opHRRO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRROI(0o561000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRROI = function(opCode) +PDP10.opHRROI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRROM(0o562000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRROM = function(opCode) +PDP10.opHRROM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRROS(0o563000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRROS = function(opCode) +PDP10.opHRROS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRO(0o564000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRO = function(opCode) +PDP10.opHLRO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLROI(0o565000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLROI = function(opCode) +PDP10.opHLROI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLROM(0o566000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLROM = function(opCode) +PDP10.opHLROM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLROS(0o567000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLROS = function(opCode) +PDP10.opHLROS = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRE(0o570000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRE = function(opCode) +PDP10.opHRRE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRREI(0o571000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRREI = function(opCode) +PDP10.opHRREI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRREM(0o572000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRREM = function(opCode) +PDP10.opHRREM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHRRES(0o573000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHRRES = function(opCode) +PDP10.opHRRES = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRE(0o574000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRE = function(opCode) +PDP10.opHLRE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLREI(0o575000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLREI = function(opCode) +PDP10.opHLREI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLREM(0o576000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLREM = function(opCode) +PDP10.opHLREM = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opHLRES(0o577000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opHLRES = function(opCode) +PDP10.opHLRES = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRN(0o600000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRN = function(opCode) +PDP10.opTRN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLN(0o601000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLN = function(opCode) +PDP10.opTLN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRNE(0o602000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRNE = function(opCode) +PDP10.opTRNE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLNE(0o603000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLNE = function(opCode) +PDP10.opTLNE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRNA(0o604000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRNA = function(opCode) +PDP10.opTRNA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLNA(0o605000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLNA = function(opCode) +PDP10.opTLNA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRNN(0o606000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRNN = function(opCode) +PDP10.opTRNN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLNN(0o607000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLNN = function(opCode) +PDP10.opTLNN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDN(0o610000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDN = function(opCode) +PDP10.opTDN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSN(0o611000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSN = function(opCode) +PDP10.opTSN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDNE(0o612000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDNE = function(opCode) +PDP10.opTDNE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSNE(0o613000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSNE = function(opCode) +PDP10.opTSNE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDNA(0o614000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDNA = function(opCode) +PDP10.opTDNA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSNA(0o615000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSNA = function(opCode) +PDP10.opTSNA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDNN(0o616000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDNN = function(opCode) +PDP10.opTDNN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSNN(0o617000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSNN = function(opCode) +PDP10.opTSNN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRZ(0o620000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRZ = function(opCode) +PDP10.opTRZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLZ(0o621000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLZ = function(opCode) +PDP10.opTLZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRZE(0o622000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRZE = function(opCode) +PDP10.opTRZE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLZE(0o623000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLZE = function(opCode) +PDP10.opTLZE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRZA(0o624000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRZA = function(opCode) +PDP10.opTRZA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLZA(0o625000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLZA = function(opCode) +PDP10.opTLZA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRZN(0o626000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRZN = function(opCode) +PDP10.opTRZN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLZN(0o627000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLZN = function(opCode) +PDP10.opTLZN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDZ(0o630000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDZ = function(opCode) +PDP10.opTDZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSZ(0o631000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSZ = function(opCode) +PDP10.opTSZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDZE(0o632000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDZE = function(opCode) +PDP10.opTDZE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSZE(0o633000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSZE = function(opCode) +PDP10.opTSZE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDZA(0o634000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDZA = function(opCode) +PDP10.opTDZA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSZA(0o635000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSZA = function(opCode) +PDP10.opTSZA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDZN(0o636000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDZN = function(opCode) +PDP10.opTDZN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSZN(0o637000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSZN = function(opCode) +PDP10.opTSZN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRC(0o640000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRC = function(opCode) +PDP10.opTRC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLC(0o641000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLC = function(opCode) +PDP10.opTLC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRCE(0o642000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRCE = function(opCode) +PDP10.opTRCE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLCE(0o643000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLCE = function(opCode) +PDP10.opTLCE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRCA(0o644000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRCA = function(opCode) +PDP10.opTRCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLCA(0o645000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLCA = function(opCode) +PDP10.opTLCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRCN(0o646000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRCN = function(opCode) +PDP10.opTRCN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLCN(0o647000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLCN = function(opCode) +PDP10.opTLCN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDC(0o650000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDC = function(opCode) +PDP10.opTDC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSC(0o651000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSC = function(opCode) +PDP10.opTSC = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDCE(0o652000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDCE = function(opCode) +PDP10.opTDCE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSCE(0o653000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSCE = function(opCode) +PDP10.opTSCE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDCA(0o654000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDCA = function(opCode) +PDP10.opTDCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSCA(0o655000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSCA = function(opCode) +PDP10.opTSCA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDCN(0o656000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDCN = function(opCode) +PDP10.opTDCN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSCN(0o657000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSCN = function(opCode) +PDP10.opTSCN = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRO(0o660000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRO = function(opCode) +PDP10.opTRO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLO(0o661000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLO = function(opCode) +PDP10.opTLO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTROE(0o662000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTROE = function(opCode) +PDP10.opTROE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLOE(0o663000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLOE = function(opCode) +PDP10.opTLOE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTROA(0o664000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTROA = function(opCode) +PDP10.opTROA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLOA(0o665000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLOA = function(opCode) +PDP10.opTLOA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTRON(0o666000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTRON = function(opCode) +PDP10.opTRON = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTLON(0o667000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTLON = function(opCode) +PDP10.opTLON = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDO(0o670000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDO = function(opCode) +PDP10.opTDO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSO(0o671000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSO = function(opCode) +PDP10.opTSO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDOE(0o672000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDOE = function(opCode) +PDP10.opTDOE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSOE(0o673000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSOE = function(opCode) +PDP10.opTSOE = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDOA(0o674000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDOA = function(opCode) +PDP10.opTDOA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSOA(0o675000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSOA = function(opCode) +PDP10.opTSOA = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTDON(0o676000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTDON = function(opCode) +PDP10.opTDON = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opTSON(0o677000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opTSON = function(opCode) +PDP10.opTSON = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opBLKI(0o700000) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opBLKI = function(opCode) +PDP10.opBLKI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDATAI(0o700040) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDATAI = function(opCode) +PDP10.opDATAI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opBLKO(0o700100) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opBLKO = function(opCode) +PDP10.opBLKO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opDATAO(0o700140) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opDATAO = function(opCode) +PDP10.opDATAO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCONO(0o700200) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCONO = function(opCode) +PDP10.opCONO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCONI(0o700240) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCONI = function(opCode) +PDP10.opCONI = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCONSZ(0o700300) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCONSZ = function(opCode) +PDP10.opCONSZ = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opCONSO(0o700340) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opCONSO = function(opCode) +PDP10.opCONSO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** - * opIO(opCode) + * opIO(op) * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opIO = function(opCode) +PDP10.opIO = function(op) { - this.opUndefined(opCode); + this.opUndefined(op); }; /** * opUndefined() * * @this {CPUStatePDP10} - * @param {number} opCode + * @param {number} op */ -PDP10.opUndefined = function(opCode) +PDP10.opUndefined = function(op) { - this.println("undefined opcode: " + Str.toOct(opCode)); + this.println("undefined opcode: " + Str.toOct(op)); this.stopCPU(); }; -/** - * opKA10(opCode) - * - * @this {CPUStatePDP10} - * @param {number} opCode - */ -PDP10.opKA10 = function(opCode) -{ - PDP10.aOpXXX_KA10[opCode >> 9].call(this, opCode); -}; - PDP10.aOpXXX_KA10 = [ PDP10.opUUO, // 0o000xxx PDP10.opUUO, // 0o001xxx diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index 5cbba2e77..5ea763f2d 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -174,6 +174,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ initCPU() { + this.regOP = 0; this.regEA = 0; this.regPC = this.lastPC = this.addrReset; @@ -276,6 +277,7 @@ class CPUStatePDP10 extends CPUPDP10 { { var state = new State(this); state.set(0, [ + this.regOP, this.regEA, this.regPC, this.lastPC, @@ -303,6 +305,7 @@ class CPUStatePDP10 extends CPUPDP10 { * of what save() does when it collects a bunch of object properties into an array. */ [ + this.regOP, this.regEA, this.regPC, this.lastPC, @@ -324,8 +327,7 @@ class CPUStatePDP10 extends CPUPDP10 { * getOpcode() * * This fetches the next opcode, decodes the low 23 bits (I,X,Y), sets regEA, and returns the - * the high 18 bits for further decoding. While it's true that, in general, only the high 13 bits - * are relevant to the operation, it's cleaner to treat the original opcode as two half-words. + * the high 13 bits for further decoding. * * @this {CPUStatePDP10} * @return {number} @@ -333,9 +335,9 @@ class CPUStatePDP10 extends CPUPDP10 { getOpcode() { var pc = this.lastPC = this.regPC; - var opCode = this.readWord(pc); + var r = this.regOP = this.readWord(pc); this.regPC = (pc + 1) % PDP10.ADDR_LIMIT; - var e, x, r = opCode, nMaxIndirect = 4; + var e, x, nMaxIndirect = 4; while (true) { /* * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the @@ -360,7 +362,7 @@ class CPUStatePDP10 extends CPUPDP10 { r = this.readWord(e); } this.regEA = e; - return (opCode / PDP10.ADDR_LIMIT)|0; + return (this.regOP / PDP10.OPCODE.ACSHIFT)|0; } /** @@ -807,8 +809,8 @@ class CPUStatePDP10 extends CPUPDP10 { this.opFlags &= PDP10.OPFLAG.PRESERVE; - var opCode = this.getOpcode(); - this.opDecode(opCode); + var op = this.getOpcode(); + this.opDecode(op); } while (this.nStepCycles > 0); diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index c074484d1..e1f9b24be 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -1326,7 +1326,7 @@ class DebuggerPDP10 extends Debugger { */ if (!nState) { opCode = this.cpu.readWord(addr); - if ((opCode >> PDP10.OPCODE.FNSHIFT) == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { + if ((opCode >> PDP10.OPCODE.A_SHIFT) == PDP10.OPCODE.HALT && this.cpu.getLastPC() == addr) { addr = this.cpu.advancePC(1); } } @@ -1420,7 +1420,7 @@ class DebuggerPDP10 extends Debugger { if (opMask == PDP10.OPCODE.OPIO) { sOperation += this.toStrBase((opCode / PDP10.OPCODE.IOSHIFT) & PDP10.OPCODE.IOMASK, -1); } else { - sOperation += this.toStrBase((opCode >> PDP10.OPCODE.FNSHIFT) & PDP10.OPCODE.FNMASK, -1); + sOperation += this.toStrBase((opCode >> PDP10.OPCODE.A_SHIFT) & PDP10.OPCODE.A_MASK, -1); } sOperation += ','; if (opCode & PDP10.OPCODE.I_BIT) sOperation += '@'; diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 0e7d0d300..bd1d08340 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -100,6 +100,7 @@ var PDP10 = { ADDR_MASK: Math.pow(2, 18) - 1, DATA_INVALID: -1, DATA_LIMIT: Math.pow(2, 36), + RHWORD_MASK: 0o777777, /* * PDP-10 opcodes are 36-bit values, most of which use the following layout: @@ -142,10 +143,11 @@ var PDP10 = { OPIO: 0o70034, // input-output operation OPUUO: 0o70000, // unimplemented user operation (UUO) mask OPSHIFT: Math.pow(2, 21), // operation shift - FNSHIFT: 23, // accumulator/function shift - FNMASK: 0o17, // accumulator/function mask (after shift) IOSHIFT: Math.pow(2, 26), // input-output device code shift IOMASK: 0o177, // input-output device code mask (after shift) + ACSHIFT: Math.pow(2, 23), // used to isolate the high 13 bits, with A starting at bit 0 + A_SHIFT: 23, // A shift + A_MASK: 0o17, // A mask (after shift) I_BIT: 0o20000000, // indirect bit X_SHIFT: 18, // X shift X_MASK: 0o17, // X mask (after shift) diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index b5c1437c4..7a4bdaf91 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -29,21 +29,21 @@ http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var ea=0;function da(a){return"jscomp_symbol_"+(a||"")+ea++} -function fa(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});fa=function(){}}function ia(a){var b=0;return ja(function(){return ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var la=Math.pow(2,36),ma=-Math.pow(2,35),q={Yb:0,mb:1,$b:2,ac:3,bc:4,cc:5,dc:6,ec:7,Wa:8,fc:9,nb:10,gc:11,hc:12,ob:13,ic:14,jc:15,kc:16,lc:17,mc:18,nc:19,oc:20,pc:21,qc:22,rc:23,sc:24,tc:25,uc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Va:65,Xb:66,Zb:67,vc:68,E:69,wc:70,xc:71,yc:72,zc:73,Ac:74,Bc:75,Cc:76,Dc:77,Ec:78,Fc:79,Gc:80,Q:81, -Hc:82,Ic:83,Jc:84,Kc:85,Lc:86,Mc:87,Nc:88,Oc:89,sb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Pc:97,Qc:98,Rc:99,d:100,e:101,Sc:102,Tc:103,Uc:104,Vc:105,Wc:106,k:107,Xc:108,Yc:109,n:110,Zc:111,p:112,q:113,r:114,$c:115,t:116,bd:117,cd:118,dd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,pb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.$a=b.comment;this.rb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Da:!1,Sa:!1,T:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ja=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +var la=Math.pow(2,36),ma=-Math.pow(2,35),q={Zb:0,nb:1,ac:2,bc:3,cc:4,dc:5,ec:6,fc:7,Xa:8,gc:9,ob:10,hc:11,ic:12,pb:13,jc:14,kc:15,lc:16,mc:17,nc:18,oc:19,pc:20,qc:21,rc:22,sc:23,tc:24,uc:25,vc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Wa:65,Yb:66,$b:67,wc:68,E:69,xc:70,yc:71,zc:72,Ac:73,Bc:74,Cc:75,Dc:76,Ec:77,Fc:78,Gc:79,Hc:80,Q:81, +Ic:82,Jc:83,Kc:84,Lc:85,Mc:86,Nc:87,Oc:88,Pc:89,tb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Qc:97,Rc:98,Sc:99,d:100,e:101,Tc:102,Uc:103,Vc:104,Wc:105,Xc:106,k:107,Yc:108,Zc:109,n:110,$c:111,p:112,q:113,r:114,ad:115,t:116,cd:117,dd:118,ed:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,qb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.ab=b.comment;this.sb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ta:!1,T:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ka=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function w(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function x(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;bb?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function jb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function kb(a,b){var c,d={W:null,S:null,ia:null,ha:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ia=g.load;d.ha=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=g.load;d.ia=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(w(d.W[0]),d=null):(w("Empty resource: "+a),d=null)}catch(h){w("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Db,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.vb,toggle:this.Qb,reset:this.Mb, -set:this.Pb};D(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.w=0)}; -l.da=function(a,b,c,d){if(this.D&&this.D.da(a,b,c,d)||this.g&&this.g.da(a,b,c,d)||this.A&&this.A.da(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Rb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Sb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.da.call(this,a,b,c,d)}};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.la=function(a,b){if(!b)if(this.U&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ca=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.w=a[1]),Xb(this,a[2]);return!0};l.Mb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} -l.vb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Pb=function(a,b){if("SR"==a)return Xb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Qb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.N=b==ac,a.O=b==bc),!0):!1} -function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Eb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Fb=function(){};l.zb=function(a){a||this.g.R()}; -l.xb=function(a){if(!a&&!this.g.j.J)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),ec(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ga+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ga){m=h.size-(e-k);m>f&&(m=f);h.Ga=e-h.v+m;e=k+16384;f-=m;g++;continue}}return pc(qc,e,f)}e=new L(a,e,m,16384,d);mc(e,a.A,h);a.b[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+rc[d]+" at "+Ra(b)),!0):pc(Ic,b,c)} -function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function nc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.Z&&(a.Z+=a.U,c=!0);0<=a.aa&&a.aa<=cd(a)&&(a.U=a.aa=-1,Zc(a),a.R(),c=!0);c&&a.f(cd(a)+" cycles: checksum="+F(a.pa))}} -l.da=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.T)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.M/a.N?b=1:d=!0;a.O=b;b=a.za*a.O;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&gd(a.D)}gc(a,a.B);a.B=0;a.w=va();a.H=0;ed(a);return d}function hd(a,b){for(var c=a.G.length-1;0<=c;c--){var d=a.G[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function id(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function jd(a,b){var c=a.I-=a.K;a.K=0;b&&(a.I=0);return c} -l.Nb=function(){if(this.j.J){this.va>=this.Ba&&ed(this,!0);this.ea=0;this.oa=va();if(this.H){var a=this.oa-this.H;a>this.Aa&&(this.w+=a,this.w>this.oa&&(this.w=this.oa))}try{do{var b=hd(this,this.j.Ca?1:this.ra);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=jd(this,!0);this.ea+=b;this.B+=b;hc(this,b);fc(this,b);this.P-=b;if(0>=this.P){this.P+=this.ra;++this.Qa>=kd&&(this.D&&K(this.D,void 0),this.Qa=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),cd(this));Ka(this,e.stack|| -e.message);return}if(this.j.J){a=setTimeout;b=this.bb;this.H=va();var c=this.Aa;this.ea&&(c=Math.round(c*this.ea/this.ra));var c=c-(this.H-this.oa),d=this.H-this.w;d&&(this.M=Math.round(this.B/(10*d))/100,864E5<=d&&(this.L=0,dd(this)));if(0>c||this.Mc&&(this.w-=c),c=0;this.va+=this.ea;this.H+=c;a(b,c)}}}; -function dc(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{dd(a);a.j.J=!0;a.j.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&gd(a.D,!0),a.D.start(a.w,cd(a)));a.A||a.status("Started");setTimeout(a.bb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){jd(this);gc(this,this.B);this.B=0;this.j.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),cd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var fd=30,kd=15,Wc=["power","reset"]; -function ld(a){var b=+a.model||1001;Vc.call(this,a,1E6);this.ab=b;this.Za=+a.addrReset||0;this.qb=md.bind(this);this.b=P.bind(this);this.fa=null;this.Ya=[];this.j.complete=!1}p(ld,Vc);l=ld.prototype;l.reset=function(){this.status("Model "+this.ab);this.j.J&&this.R();this.Ra=0;this.ga=this.i=this.na=this.Za;this.u=0;this.ma=this.Jb;this.Ha=this.Wb;this.fa=null;Yc(this);this.j.error=!1;Vc.prototype.reset.call(this)};l.jb=function(){return 0}; -l.save=function(){var a=new J(this);a.set(0,[this.Ra,this.i,this.na,this.ga,this.u]);a.set(1,[]);a.set(2,[this.L,this.O,this.j.X]);a.set(3,nd(this));a.set(4,id(this));return a.data()}; -l.restore=function(a){var b;b=a[0];fa();ca();fa();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.Ra=b.next().value;this.i=b.next().value;this.na=b.next().value;this.ga=b.next().value;this.u=b.next().value;b=a[2];this.L=b[0];dd(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].ma(a&16383,a)};l.Wb=function(a,b){var c=this.C;a=this.ga=a;c.b[(a&c.u)>>>c.i].Ha(b,a&16383,a)}; -l.Ia=function(a){this.j.complete=!0;var b=this.A?od(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.I=this.K=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(pd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.fa||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&pd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;var d=this.na=this.i;a=this.ma(d);this.i=(d+1)%Jb;for(var e,f=a,g=4;;){d=f&262143;(e=f>>18&15)&&(d=d+this.ma(e)& -Kb);if(!(f&4194304))break;if(0>--g){this.C.ib(f);break}f=this.ma(d)}this.Ra=d;this.qb(a/Jb|0)}while(0>9].call(this,a)} -var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +var B="pdp10",Db="PDPjs",Jb=Math.pow(2,18),Kb=Math.pow(2,18)-1,Lb=Math.pow(2,36),Mb=Math.pow(2,21),Nb=Math.pow(2,26),Ob=Math.pow(2,23),B="pdp10",Db="PDPjs",H={cpu:1,trap:2,fault:4,"int":8,bus:16,memory:32,mmu:64,rom:128,device:256,panel:512,keyboard:1024,key:2048,paper:4096,read:16384,write:32768,serial:1048576,timer:2097152,speaker:16777216,computer:33554432,log:268435456,warn:536870912,buffer:1073741824,halt:-2147483648}; +function Pb(a,b){t.call(this,"Panel",a,512);this.I=this.K=0;this.U=b;this.i=this.H=this.u=this.w=0;this.L=this.M=-1;this.N=this.O=this.G=!1;this.P=Qb;this.B={};this.b={START:[1,1,!0,!1,this.Fb],STEP:[1,1,!1,!1,this.Gb],ENABLE:[1,1,!1,!1,this.Ab],CONT:[1,1,!0,!1,this.yb],DEP:[0,0,!0,!1,this.zb],EXAM:[1,1,!0,!1,this.Bb],LOAD:[1,1,!0,!1,this.Db],TEST:[0,0,!0,!1,this.Cb]};for(a=0;22>a;a++)this.b["S"+a]=[0,0,!1,!1,this.Eb,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.wb,toggle:this.Rb,reset:this.Nb, +set:this.Qb};D(this)}p(Pb,t);l=Pb.prototype;l.reset=function(a){this.stop();a&&Rb(this,this.w=0)}; +l.ea=function(a,b,c,d){if(this.D&&this.D.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Sb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Tb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Sb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Tb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Ub(this);Vb(this)};l.ma=function(a,b){if(!b)if(this.U&&Wb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Xb(this,this.i=a[0]),Rb(this,this.w=a[1]),Yb(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Vb(this);return!0};function Zb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ub(a,b){for(var c in a.B)Zb(a,c,null!=b?b:a.B[c])}function $b(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Vb(a){for(var b in a.b)$b(a,b,a.b[b][1])} +l.wb=function(a,b,c){if(Sb(this,b)){if(c){var d=this;setTimeout(function(){Tb(d,b);a&&a()},+c);return!1}Tb(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return Yb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,$b(this,a,c[1]),!0):!1};l.Rb=function(a){return Sb(this,a)?(Tb(this,a),!0):!1};function Sb(a,b){var c=a.b[b];return c?($b(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=ac&&(a.N=b==bc,a.O=b==cc),!0):!1} +function Tb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&($b(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Fb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[dc]&&this.b[dc][1]&&ec(this.g))};l.Gb=function(){};l.Ab=function(a){a||this.g.R()}; +l.yb=function(a){if(!a&&!this.g.j.J)if(this.b[dc]&&this.b[dc][1])ec(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),fc(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>f&&(m=f);h.Ha=e-h.v+m;e=k+16384;f-=m;g++;continue}}return qc(rc,e,f)}e=new L(a,e,m,16384,d);nc(e,a.A,h);a.b[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+Ic[d]+" at "+Ra(b)),!0):qc(Jc,b,c)} +function lc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function kc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function oc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.aa&&(a.aa+=a.U,c=!0);0<=a.ba&&a.ba<=dd(a)&&(a.U=a.ba=-1,$c(a),a.R(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.qa))}} +l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.T)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.M/a.N?b=1:d=!0;a.O=b;b=a.Ca*a.O;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&hd(a.D)}hc(a,a.B);a.B=0;a.w=va();a.H=0;fd(a);return d}function id(a,b){for(var c=a.G.length-1;0<=c;c--){var d=a.G[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.I-=a.K;a.K=0;b&&(a.I=0);return c} +l.Ob=function(){if(this.j.J){this.xa>=this.Ra&&fd(this,!0);this.fa=0;this.pa=va();if(this.H){var a=this.pa-this.H;a>this.Qa&&(this.w+=a,this.w>this.pa&&(this.w=this.pa))}try{do{var b=id(this,this.j.Da?1:this.sa);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.fa+=b;this.B+=b;ic(this,b);gc(this,b);this.P-=b;if(0>=this.P){this.P+=this.sa;++this.Sa>=ld&&(this.D&&K(this.D,void 0),this.Sa=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),dd(this));Ka(this,e.stack|| +e.message);return}if(this.j.J){a=setTimeout;b=this.cb;this.H=va();var c=this.Qa;this.fa&&(c=Math.round(c*this.fa/this.sa));var c=c-(this.H-this.pa),d=this.H-this.w;d&&(this.M=Math.round(this.B/(10*d))/100,864E5<=d&&(this.L=0,ed(this)));if(0>c||this.Mc&&(this.w-=c),c=0;this.xa+=this.fa;this.H+=c;a(b,c)}}}; +function ec(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{ed(a);a.j.J=!0;a.j.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&hd(a.D,!0),a.D.start(a.w,dd(a)));a.A||a.status("Started");setTimeout(a.cb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){kd(this);hc(this,this.B);this.B=0;this.j.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; +function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.bb=b;this.$a=+a.addrReset||0;this.rb=nd.bind(this);this.b=P.bind(this);this.ha=null;this.Za=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.bb);this.j.J&&this.R();this.ga=this.ya=0;this.na=this.i=this.oa=this.$a;this.u=0;this.Z=this.Kb;this.va=this.Xb;this.ha=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.kb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.ya,this.ga,this.i,this.oa,this.na,this.u]);a.set(1,[]);a.set(2,[this.L,this.O,this.j.X]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.ya=b.next().value;this.ga=b.next().value;this.i=b.next().value;this.oa=b.next().value;this.na=b.next().value;this.u=b.next().value;b=a[2];this.L=b[0];ed(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].Z(a&16383,a)};l.Xb=function(a,b){var c=this.C;a=this.na=a;c.b[(a&c.u)>>>c.i].va(b,a&16383,a)}; +l.Ia=function(a){this.j.complete=!0;var b=this.A?pd(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.I=this.K=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(qd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.ha||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&qd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;var d=this.oa=this.i;a=this.ya=this.Z(d);this.i=(d+1)%Jb;for(var e,f=4;;){d=a&262143;(e=a>>18&15)&&(d=d+this.Z(e)& +Kb);if(!(a&4194304))break;if(0>--f){this.C.jb(a);break}a=this.Z(d)}this.ga=d;this.rb(this.ya/Ob|0)}while(0>4].call(this,a)}function Q(a){this.b(a)}function sd(a){this.b(a)}function td(a){this.b(a)}function ud(a){a&=15;var b=this.Z(this.ga),c=this.Z(a);this.va(a,(c&262143)+(b-(b&262143)))} +function R(a){this.b(a)}function P(a){this.f("undefined opcode: "+Ra(a));this.R()} +var rd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},qd,rd,rd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},qd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,td,td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, @@ -110,115 +111,115 @@ function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a) function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},ud,function(a){a&=15;var b=this.Z(a);this.va(a,b&262143)},function(a){a=this.Z(a&15);var b=this.Z(this.ga);this.va(this.ga,(b&262143)+(a-(a&262143)))},function(a){a&15&&ud.call(this, +a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; -function td(a){t.call(this,"ROM",a,128);this.S=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.G=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.G);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Y("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.S=a.S):c.w=null);ud(c)})}}p(td,t); -td.prototype.ta=function(a,b,c,d){this.C=b;this.g=c;this.A=d;ud(this)};td.prototype.la=function(){this.S&&(this.A&&vd(this.A,this.id,this.B,this.u,this.S),delete this.S);return!0};td.prototype.ca=function(){return!0}; -function ud(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(oc(a.C,b,a.u,Mc)){var c;for(c=0;c>>f.i;0>>= -f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= -b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)jc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Va&&c<=q.sb&&(b=c-(q.Va-q.mb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.ob&&(b=q.nb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; +function vd(a){t.call(this,"ROM",a,128);this.S=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.G=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.G);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Y("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.S=a.S):c.w=null);wd(c)})}}p(vd,t); +vd.prototype.ta=function(a,b,c,d){this.C=b;this.g=c;this.A=d;wd(this)};vd.prototype.ma=function(){this.S&&(this.A&&xd(this.A,this.id,this.B,this.u,this.S),delete this.S);return!0};vd.prototype.da=function(){return!0}; +function wd(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.C,b,a.u,Nc)){var c;for(c=0;c>>f.i;0>>= +f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= +b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)kc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Wa&&c<=q.tb&&(b=c-(q.Wa-q.nb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.pb&&(b=q.ob);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;D(this)}; -l.lb=function(a){if(!this.b){var b=Xc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Ja)return;c=Za(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.la=function(a,b){if(!b)if(this.lb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ca=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} -function Dd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +l.mb=function(a){if(!this.b){var b=Yc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Ja)return;c=Za(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.ma=function(a,b){if(!b)if(this.mb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} +function Fd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Ed(a,b,c){var d;if(b){b=Fd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Jd(a,b){if(b)return Id(a,b,a.Z[b]);var c=0;for(b in a.Z)Id(a,b,a.Z[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Hd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Kd(a){Bd.call(this,a);this.ya=!1;this.na=!0;this.I=T();this.va=T();this.N=T();this.H=[];this.b=this.K=this.G=[];Ld(this);this.P=this.ga=0;this.i=[];this.qa=void 0;Md(this);this.A=this;this.oa={};this.V=this.fb=0;this.U=null;this.M=[];Nd(this,a.messages);this.sa=a.commands;this.L=0;this.Ba=this.ra=null;this.B=this.Aa=this.za=this.fa=this.pa=0;this.ea=this.aa=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return bd(b,a)}):void 0===global[B]&&(global[B]=function(a){return bd(b, -a)})}p(Kd,Bd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,ub:void 0===b?!1:b,ka:!1,ba:c}}function Od(a){return[a.v,a.ub,a.ba,a.ka,a.Oa]}function Pd(a,b){var c=T(b[0],b[1],b[2]);c.ka=b[3];b[4]&&(c.cb=Cd(a,c.Oa=b[4]));return c}l=Kd.prototype; -l.ta=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.ea=a.u;(a=Xc(a,"messages"))&&Nd(this,a);Qd(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=rc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.na==b)){b=a.g;var e=b.i;b.i=(e+1)%Jb;b=e}if(0d&&(d=a.g.ma(b)),0<=d&&(c=a.i[a.P],c.v=b,c.ka=!1,c.ba=void 0,++a.P==a.i.length&&(a.P=0)));return!1} -function De(a,b,c,d){var e=T(b.v),f=a.xa(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Ee)if(g=Ee[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Fe;m=n&3;break;case 32256:k=Ge;m=n&7;break;case 29248:k=He,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ie&&(k="B");k=Je[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Sd(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.xa(e,1),g+=" "+Sd(k),null== -e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Ca?h+("cycles="+cd(a.g).toString()+" cs="+F(a.g.pa)):h+(null!=d?"="+d.toString():""));return h}function Ld(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.i],!0);a.G=["bw"];a.pa=0;a.ga=0} -l.wa=function(a,b,c){var d=!0;c||Ke(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].wa(e&16383,a==this.G)}}d&&(a.push(b),c?b.ka=!0:(Le(this,a,a.length-1,"set"),Md(this)));return d};function Ke(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.G));h.ka||Md(a);break}}return f} -function Me(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.gb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({ad:b,v:c,wb:d,S:e,eb:f})}function Oe(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.wb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=De(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} -function Ne(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(ye+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==ce&&(bb=1E5,wc=["CALL"]);for(void 0!==be&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;ee++;bb--}}ee||(a.f("no "+de+"history available"), -a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,he="ds"==Ha;if(ga){if("l"==ga.charAt(0))ga=ga.substr(1)||wf,pa=Gd(a,ga);else{var ie=Z(a,ga);ie&&(pa=ie.v-oa.v)}0>pa&&(pa=0);65536me;me++)ke+=String.fromCharCode((Eb%64|0)+32), -Eb/=64}qa&&(qa+="\n");qa=he?qa+(ra+","):qa+(U+": "+ra+(0>le?" "+ke:""))}qa&&a.f(qa);a.va=oa;a.ba=yf}}}}break;case "e":if("else"==g[0])break;var ne,oe,pe=g[0],zc=g[1];"e"==pe||"ew"==pe?(ne=a.xa,oe=a.Xa):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,Cf=256;65536>eb.v>>>0;){Ec.v=a.xa(eb,2);if(null==eb.v||!Cf--)break;if(!(Ec.v&1)){for(var Df=a,Hb=Ec,re=null,fb=Hb.v,se=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;b$e){if(af(d,this.K)){this.B=new J(this,"1.34.0",kf);af(this.B)&&(lf(this,d),a=mf,nf(this.B));this.B.set(gf,ab());of(this.B);var e=this.b&&!this.I;if(a==hf||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=ff(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?af(d,g):("error"==f&&"no machine state"!= -g?(this.Y("Error: "+g),"unable to verify user"==g&&(ob(pf,""),this.i=null)):this.f(f+": "+g),nf(d),af(d)?(c=ff(d),e=!0):c=!1))}e&&df(this,c?d:null)}else a==mf&&d.clear()}else df(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.g&&(qf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(lf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function lf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.aa;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} -function Ue(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",ef),h=ab();g.set(gf,h);f.set(gf,h);f.set(rf,"1.34.0");f.set(sf,window?window.location.href:null);f.set(tf,window?window.navigator.userAgent:"");a.g&&a.g.ca&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.ca(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.T=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;k=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Ld(a,b){if(b)return Kd(a,b,a.aa[b]);var c=0;for(b in a.aa)Kd(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Jd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Md(a){Dd.call(this,a);this.xa=!1;this.na=!0;this.I=T();this.wa=T();this.N=T();this.H=[];this.b=this.K=this.G=[];Nd(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Od(this);this.A=this;this.oa={};this.V=this.gb=0;this.U=null;this.M=[];Pd(this,a.messages);this.sa=a.commands;this.L=0;this.Ca=this.ra=null;this.B=this.Ba=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return cd(b,a)}):void 0===global[B]&&(global[B]=function(a){return cd(b, +a)})}p(Md,Dd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,vb:void 0===b?!1:b,la:!1,ca:c}}function Qd(a){return[a.v,a.vb,a.ca,a.la,a.Oa]}function Rd(a,b){var c=T(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.eb=Ed(a,c.Oa=b[4]));return c}l=Md.prototype; +l.ta=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.fa=a.u;(a=Yc(a,"messages"))&&Pd(this,a);Sd(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Ic[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.oa==b)){b=a.g;var e=b.i;b.i=(e+1)%Jb;b=e}if(0d&&(d=a.g.Z(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} +function Fe(a,b,c,d){var e=T(b.v),f=a.Aa(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Ge)if(g=Ge[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=He;m=n&3;break;case 32256:k=Ie;m=n&7;break;case 29248:k=Je,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ke&&(k="B");k=Le[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Ud(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Aa(e,1),g+=" "+Ud(k),null== +e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.qa)):h+(null!=d?"="+d.toString():""));return h}function Nd(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.i],!0);a.G=["bw"];a.pa=0;a.ha=0} +l.za=function(a,b,c){var d=!0;c||Me(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].za(e&16383,a==this.G)}}d&&(a.push(b),c?b.la=!0:(Ne(this,a,a.length-1,"set"),Od(this)));return d};function Me(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.G));h.la||Od(a);break}}return f} +function Oe(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.hb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({bd:b,v:c,xb:d,S:e,fb:f})}function Qe(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.xb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=Fe(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} +function Pe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Be+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==de&&(bb=1E5,wc=["CALL"]);for(void 0!==ce&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;fe++;bb--}}fe||(a.f("no "+ee+"history available"), +a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,ie="ds"==Ha;if(fa){if("l"==fa.charAt(0))fa=fa.substr(1)||yf,pa=Id(a,fa);else{var je=Z(a,fa);je&&(pa=je.v-oa.v)}0>pa&&(pa=0);65536ne;ne++)le+=String.fromCharCode((Eb%64|0)+32), +Eb/=64}qa&&(qa+="\n");qa=ie?qa+(ra+","):qa+(U+": "+ra+(0>me?" "+le:""))}qa&&a.f(qa);a.wa=oa;a.ca=Af}}}}break;case "e":if("else"==g[0])break;var oe,pe,qe=g[0],zc=g[1];"e"==qe||"ew"==qe?(oe=a.Aa,pe=a.Ya):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,Ef=256;65536>eb.v>>>0;){Ec.v=a.Aa(eb,2);if(null==eb.v||!Ef--)break;if(!(Ec.v&1)){for(var Ff=a,Hb=Ec,se=null,fb=Hb.v,te=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bbf){if(cf(d,this.K)){this.B=new J(this,"1.34.0",mf);cf(this.B)&&(nf(this,d),a=of,pf(this.B));this.B.set(jf,ab());qf(this.B);var e=this.b&&!this.I;if(a==kf||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=hf(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?cf(d,g):("error"==f&&"no machine state"!= +g?(this.Y("Error: "+g),"unable to verify user"==g&&(ob(rf,""),this.i=null)):this.f(f+": "+g),pf(d),cf(d)?(c=hf(d),e=!0):c=!1))}e&&ff(this,c?d:null)}else a==of&&d.clear()}else ff(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.g&&(sf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(nf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function nf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} +function We(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",gf),h=ab();g.set(jf,h);f.set(jf,h);f.set(tf,"1.34.0");f.set(uf,window?window.location.href:null);f.set(vf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.T=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;k=d||30<=(c.ya+=d))&&(e.textContent=c.j.J?c.M.toFixed(2)+"Mhz":"Stopped",c.ya=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.F.PC){var f=a.A&&a.A.ba||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Of(a,b,c)}})}else c(a,null)} -function Pf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Lf||zb(!0));m=!1}var h,k,m=!0;Lf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Mf(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Lf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Lf|| -zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Mf(c,b,a,e,!0,f,n):Nf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Pf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Pf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +function K(a,b){if(a.g){var c=a.g,d=b||0,e=c.F.speed;e&&(0>=d||30<=(c.Ba+=d))&&(e.textContent=c.j.J?c.M.toFixed(2)+"Mhz":"Stopped",c.Ba=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.F.PC){var f=a.A&&a.A.ca||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Qf(a,b,c)}})}else c(a,null)} +function Rf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Nf||zb(!0));m=!1}var h,k,m=!0;Nf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Of(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Nf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Nf|| +zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Of(c,b,a,e,!0,f,n):Pf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Rf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Rf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={zb:0,Oa:1,Bb:2,Cb:3,Db:4,Eb:5,Fb:6,Gb:7,Ga:8,Hb:9,Pa:10,Ib:11,Jb:12,Qa:13,Kb:14,Lb:15,Mb:16,Nb:17,Ob:18,Pb:19,Qb:20,Rb:21,Sb:22,Tb:23,Ub:24,Vb:25,Wb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Fa:65,yb:66,Ab:67,Xb:68,E:69,Yb:70,Zb:71,$b:72,ac:73,bc:74,cc:75,dc:76,ec:77,fc:78,gc:79,hc:80,Q:81, -ic:82,jc:83,kc:84,lc:85,mc:86,nc:87,oc:88,pc:89,Va:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,qc:97,rc:98,sc:99,d:100,e:101,tc:102,uc:103,vc:104,wc:105,xc:106,k:107,yc:108,zc:109,n:110,Ac:111,p:112,q:113,r:114,Bc:115,t:116,Cc:117,Dc:118,Ec:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ra:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ja=b.comment;this.Ua=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ja=this.id:(this.ka=this.id.substr(0,a),this.ja=this.id.substr(a+1));this.b={ready:!1,oa:!1,Da:!1,w:!1,error:!1};this.ra=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.Z=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={Ab:0,Pa:1,Cb:2,Db:3,Eb:4,Fb:5,Gb:6,Hb:7,Ha:8,Ib:9,Qa:10,Jb:11,Kb:12,Ra:13,Lb:14,Mb:15,Nb:16,Ob:17,Pb:18,Qb:19,Rb:20,Sb:21,Tb:22,Ub:23,Vb:24,Wb:25,Xb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ga:65,zb:66,Bb:67,Yb:68,E:69,Zb:70,$b:71,ac:72,bc:73,cc:74,dc:75,ec:76,fc:77,gc:78,hc:79,ic:80,Q:81, +jc:82,kc:83,lc:84,mc:85,nc:86,oc:87,pc:88,qc:89,Wa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,rc:97,sc:98,tc:99,d:100,e:101,uc:102,vc:103,wc:104,xc:105,yc:106,k:107,zc:108,Ac:109,n:110,Bc:111,p:112,q:113,r:114,Cc:115,t:116,Dc:117,Ec:118,Fc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Sa:127}; +function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ka=b.comment;this.Va=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.la=this.id:(this.ma=this.id.substr(0,a),this.la=this.id.substr(a+1));this.b={ready:!1,ra:!1,Ea:!1,w:!1,error:!1};this.ua=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.aa=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",p;for(p in b)b.hasOwnProperty(p)&&(l&&(l+="&"),l+=p+"="+encodeURIComponent(b[p]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={F:null,J:null,R:null,P:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.R=g.load;d.P=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else d.F=g;d.J=g.symbols;d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.eb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Xa,toggle:this.rb,reset:this.nb, -set:this.qb};E(this)}n(Va,u);k=Va.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; -k.S=function(a,b,c,d){if(this.m&&this.m.S(a,b,c,d)||this.f&&this.f.S(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Xa(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Xa(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.S.call(this,a,b,c,d)}};k.V=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Ya(this);Za(this)};k.T=function(a,b){if(!b)if(this.O&&$a(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.N=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),M(this,this.h=a[1]),ab(this,a[2]);return!0};k.nb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}Za(this);return!0};function bb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ya(a,b){for(var c in a.j)bb(a,c,null!=b?b:a.j[c])}function cb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Za(a){for(var b in a.a)cb(a,b,a.a[b][1])} -k.Xa=function(a,b,c){if(Xa(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; -k.qb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.W(this.c);M(this,this.h=a)}};k.cb=function(a){a||this.f.b.v||Q(this,this.g)};k.bb=function(a){a?(this.s=!0,Ya(this,!0)):(this.s=!1,Ya(this),ab(this,0))};k.eb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Y)return h.ta+=h.Y-e,h.Y=e,!0;if(e>=h.Y+h.ta){p=h.size-(e-l);p>f&&(p=f);h.ta=e-h.Y+p;e=l+16384;f-=p;g++;continue}}return rb(sb,e,f)}e=new T(a,e,p,16384,d);ob(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+tb[d]+" at "+wa(b)),!0):rb(ub,b,c)}function mb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} -function pb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.L&&(a.L+=a.ga,c=!0);0<=a.ha&&a.ha<=Jb(a)&&(a.ga=a.ha=-1,Ib(a),R(a),c=!0);c&&a.I(Jb(a)+" cycles: checksum="+F(a.la))}} -k.S=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.H/a.K&&(b=1);a.M=b;b=a.ya*a.M;if(a.K!=b){a.K=b;b=a.K.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.Z&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.Z.focus(),window&&window.scrollTo(b,d)))}jb(a,a.j);a.j=0;a.h=w();a.u=0;Lb(a)}function Nb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Ob(a,b){var c=a.A-=a.B;a.B=0;b&&(a.A=0);return c} -k.ob=function(){if(this.b.v){this.na>=this.Aa&&Lb(this,!0);this.U=0;this.fa=w();if(this.u){var a=this.fa-this.u;a>this.za&&(this.h+=a,this.h>this.fa&&(this.h=this.fa))}try{do{for(var b,c=this.b.pa?1:this.aa,d=this.s.length-1;0<=d;d--){var e=this.s[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.va(b)}catch(f){if("number"!=typeof f)throw f;}b=Ob(this,!0);this.U+=b;this.j+=b;kb(this,b);ib(this,b);this.O-=b;if(0>=this.O){this.O+=this.aa;++this.Ba>=Pb&&(this.m&&S(this.m,void 0),this.Ba=0);break}}while(this.b.v)}catch(f){R(this); -this.m&&this.m.stop(w(),Jb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ka;this.u=w();c=this.za;this.U&&(c=Math.round(c*this.U/this.aa));c-=this.u-this.fa;if(d=this.u-this.h)this.H=Math.round(this.j/(10*d))/100,864E5<=d&&(this.D=0,Kb(this));if(0>c||this.Hc&&(this.h-=c),c=0;this.na+=this.U;this.u+=c;a(b,c)}}}; -function hb(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Kb(a);a.b.v=!0;a.b.Ea=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Jb(a));a.o||a.status("Started");setTimeout(a.Ka,0)}}k.va=function(){return 0};function R(a){var b=!1;if(a.b.v){Ob(a);jb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Jb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Mb=30,Pb=15,Gb=["power","reset"]; -function Qb(a){var b=+a.model||1001;Fb.call(this,a,1E6);this.Sa=b;this.Ia=+a.addrReset||0;this.Ta=Rb.bind(this);this.a=V.bind(this);this.X=null;this.Ha=[];this.b.complete=!1}n(Qb,Fb);k=Qb.prototype;k.reset=function(){this.status("Model "+this.Sa);this.b.v&&R(this);this.Ca=0;this.da=this.g=this.xa=this.Ia;this.c=0;this.W=this.kb;this.ua=this.xb;this.X=null;Hb(this);this.b.error=!1;Fb.prototype.reset.call(this)};k.Ma=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[this.Ca,this.g,this.xa,this.da,this.c]);a.set(1,[]);a.set(2,[this.D,this.M,this.b.G]);a.set(3,Sb(this));a.set(4,Nb(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.Ca=b.next().value;this.g=b.next().value;this.xa=b.next().value;this.da=b.next().value;this.c=b.next().value;b=a[2];this.D=b[0];Kb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].W(a&16383,a)};k.xb=function(a,b){var c=this.l;a=this.da=a;c.a[(a&c.g)>>>c.c].ua(b,a&16383,a)}; -k.va=function(a){this.b.complete=!0;var b=a?this.b.Ea?0:1:-1;this.b.Ea=!1;this.A=this.B=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.X||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;var c=this.xa=this.g;a=this.W(c);this.g=(c+1)%Sa;for(var d,e=a,f=4;;){c=e&262143;(d=e>>18&15)&&(c=c+this.W(d)&Ta);if(!(e&4194304))break;if(0>--f){d=this.l;d.h||R(d.f);break}e=this.W(c)}this.Ca=c;this.Ta(a/Sa|0)}while(0>9].call(this,a)} -var Vb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +var C="pdp10",L="PDPjs",Sa=Math.pow(2,18),Ta=Math.pow(2,18)-1,Ua=Math.pow(2,36),Va=Math.pow(2,23),C="pdp10",L="PDPjs"; +function Wa(a,b){u.call(this,"Panel",a);this.A=this.B=0;this.P=b;this.c=this.u=this.g=this.h=0;this.D=this.H=-1;this.K=this.L=this.s=!1;this.N=Xa;this.j={};this.a={START:[1,1,!0,!1,this.gb],STEP:[1,1,!1,!1,this.hb],ENABLE:[1,1,!1,!1,this.ab],CONT:[1,1,!0,!1,this.Za],DEP:[0,0,!0,!1,this.$a],EXAM:[1,1,!0,!1,this.bb],LOAD:[1,1,!0,!1,this.eb],TEST:[0,0,!0,!1,this.cb]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.fb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Ya,toggle:this.sb,reset:this.ob, +set:this.rb};E(this)}n(Wa,u);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; +k.T=function(a,b,c,d){if(this.m&&this.m.T(a,b,c,d)||this.f&&this.f.T(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.T.call(this,a,b,c,d)}};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Za(this);$a(this)};k.U=function(a,b){if(!b)if(this.P&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.O=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),M(this,this.h=a[1]),bb(this,a[2]);return!0};k.ob=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} +k.Ya=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; +k.rb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.eb=function(a){a||this.f.b.v||Q(this,this.g)};k.cb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.fb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Z)return h.wa+=h.Z-e,h.Z=e,!0;if(e>=h.Z+h.wa){p=h.size-(e-l);p>f&&(p=f);h.wa=e-h.Z+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function qb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.L&&(a.L+=a.ja,c=!0);0<=a.ba&&a.ba<=Kb(a)&&(a.ja=a.ba=-1,Jb(a),R(a),c=!0);c&&a.I(Kb(a)+" cycles: checksum="+F(a.na))}} +k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.H/a.K&&(b=1);a.N=b;b=a.Aa*a.N;if(a.K!=b){a.K=b;b=a.K.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.aa&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.aa.focus(),window&&window.scrollTo(b,d)))}kb(a,a.j);a.j=0;a.h=w();a.u=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.A-=a.B;a.B=0;b&&(a.A=0);return c} +k.pb=function(){if(this.b.v){this.pa>=this.Ca&&Mb(this,!0);this.V=0;this.ia=w();if(this.u){var a=this.ia-this.u;a>this.Ba&&(this.h+=a,this.h>this.ia&&(this.h=this.ia))}try{do{for(var b,c=this.b.sa?1:this.ca,d=this.s.length-1;0<=d;d--){var e=this.s[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.xa(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.V+=b;this.j+=b;lb(this,b);jb(this,b);this.P-=b;if(0>=this.P){this.P+=this.ca;++this.Da>=Qb&&(this.m&&S(this.m,void 0),this.Da=0);break}}while(this.b.v)}catch(f){R(this); +this.m&&this.m.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.La;this.u=w();c=this.Ba;this.V&&(c=Math.round(c*this.V/this.ca));c-=this.u-this.ia;if(d=this.u-this.h)this.H=Math.round(this.j/(10*d))/100,864E5<=d&&(this.D=0,Lb(this));if(0>c||this.Hc&&(this.h-=c),c=0;this.pa+=this.V;this.u+=c;a(b,c)}}}; +function ib(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Lb(a);a.b.v=!0;a.b.Fa=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Kb(a));a.o||a.status("Started");setTimeout(a.La,0)}}k.xa=function(){return 0};function R(a){var b=!1;if(a.b.v){Pb(a);kb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Kb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; +function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Ta=b;this.Ja=+a.addrReset||0;this.Ua=Sb.bind(this);this.a=V.bind(this);this.fa=null;this.Ia=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Ta);this.b.v&&R(this);this.W=this.qa=0;this.ha=this.g=this.za=this.Ja;this.c=0;this.M=this.lb;this.Y=this.yb;this.fa=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Na=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[this.qa,this.W,this.g,this.za,this.ha,this.c]);a.set(1,[]);a.set(2,[this.D,this.N,this.b.G]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.qa=b.next().value;this.W=b.next().value;this.g=b.next().value;this.za=b.next().value;this.ha=b.next().value;this.c=b.next().value;b=a[2];this.D=b[0];Lb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.yb=function(a,b){var c=this.l;a=this.ha=a;c.a[(a&c.g)>>>c.c].Y(b,a&16383,a)}; +k.xa=function(a){this.b.complete=!0;var b=a?this.b.Fa?0:1:-1;this.b.Fa=!1;this.A=this.B=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.fa||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;var c=this.za=this.g;a=this.qa=this.M(c);this.g=(c+1)%Sa;for(var d,e=4;;){c=a&262143;(d=a>>18&15)&&(c=c+this.M(d)&Ta);if(!(a&4194304))break;if(0>--e){a=this.l;a.h||R(a.f);break}a=this.M(c)}this.W=c;this.Ua(this.qa/Va|0)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.M(this.W),c=this.M(a);this.Y(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));R(this)} +var Ub=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Tb,Ub,Ub,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Tb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,Wb,Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, @@ -106,57 +106,57 @@ function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a) function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.M(a);this.Y(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.W);this.Y(this.W,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; -function Wb(a){u.call(this,"ROM",a);this.J=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.s=xa(this.h);if(this.h){a=this.h;var b=ya(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.C("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(ka(c.ka,a,b),(a=Ea(a,b))?(c.a=a.F,c.J=a.J):c.h=null);Xb(c)})}}n(Wb,u); -Wb.prototype.V=function(a,b,c,d){this.l=b;this.f=c;this.o=d;Xb(this)};Wb.prototype.T=function(){this.J&&(this.o&&this.o.a(this.id,this.j,this.g,this.J),delete this.J);return!0};Wb.prototype.N=function(){return!0}; -function Xb(a){if(!ta(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.C(b)}else{b=a.j;if(qb(a.l,b,a.g,yb)){var c;for(c=0;c>>f.c;0>>=f.c;0>>a.c;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ua=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ua)for(;ua--;)mb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Fa&&c<=r.Va&&(b=c-(r.Fa-r.Oa));b&&(a.preventDefault&&a.preventDefault(),d.sa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Qa&&(b=r.Pa);d.sa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.sa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.V=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; -k.Na=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ja)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.T=function(a,b){if(!b)if(this.Na(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.N=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.sa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bec){if(Z(d,this.B)){this.j=new O(this,"1.34.0",nc);Z(this.j)&&(oc(this,d),a=pc,qc(this.j));this.j.set(kc,Da());rc(this.j);var e=this.a&&!this.A;if(a==lc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=jc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(sc,""),this.c=null)):this.I(f+": "+g),qc(d),Z(d)?(c=jc(d),e=!0):c=!1))}e&&hc(this,c?d:null)}else a==pc&&d.clear()}else hc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.M=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(tc(this,this.f,b,c,a),S(this,-2),this.f.G());this.K&&(oc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; -function oc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function uc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",ic),h=Da();g.set(kc,h);f.set(kc,h);f.set(vc,"1.34.0");f.set(wc,window?window.location.href:null);f.set(xc,window?window.navigator.userAgent:"");a.f&&a.f.N&&(c&&(b&&(a.f.b.G=a.f.b.v),R(a.f)),d=a.f.N(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l>>f.c;0>>=f.c;0>>a.c;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ta=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ta)for(;ta--;)nb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Ga&&c<=r.Wa&&(b=c-(r.Ga-r.Pa));b&&(a.preventDefault&&a.preventDefault(),d.va(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Ra&&(b=r.Qa);d.va(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.va(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; +k.Oa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.la)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ma+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Oa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.va=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bgc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",pc);Z(this.j)&&(qc(this,d),a=rc,sc(this.j));this.j.set(mc,Da());tc(this.j);var e=this.a&&!this.A;if(a==nc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=lc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(uc,""),this.c=null)):this.I(f+": "+g),sc(d),Z(d)?(c=lc(d),e=!0):c=!1))}e&&jc(this,c?d:null)}else a==rc&&d.clear()}else jc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(vc(this,this.f,b,c,a),S(this,-2),this.f.G());this.K&&(qc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function qc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function wc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",kc),h=Da();g.set(mc,h);f.set(mc,h);f.set(xc,"1.34.0");f.set(yc,window?window.location.href:null);f.set(zc,window?window.navigator.userAgent:"");a.f&&a.f.O&&(c&&(b&&(a.f.b.G=a.f.b.v),R(a.f)),d=a.f.O(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.wa+=d))&&(e.textContent=c.b.v?c.H.toFixed(2)+"Mhz":"Stopped",c.wa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(t){g=null,a=t.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,q=/( [a-z]+=)(['"])(.*?)\2/g;p=q.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Fc(a,b,c)}})}else c(a,null)} -function Gc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Cc||K(!0));p=!1}var h,l,p=!0;Cc++;la[b]={};try{if(h=document.getElementById(b)){var q;if("object"==typeof resources&&(q=resources.css)){var t=document.head||document.getElementsByTagName("head")[0],P=document.createElement("style");P.type="text/css";P.styleSheet?P.styleSheet.cssText=q:P.appendChild(document.createTextNode(q));t.appendChild(P)}d|| -(q=a,"pdp"==a.substr(0,3)&&(q="pdpjs"),d="/versions/"+q+"/1.34.0/components.xsl");q=function(e,l){l?Dc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Cc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Cc|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Dc(c,b,a,e,!0,f,q):Ec(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ua){g(ua.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Gc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Gc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +function S(a,b){if(a.f){var c=a.f,d=b||0,e=c.i.speed;e&&(0>=d||30<=(c.ya+=d))&&(e.textContent=c.b.v?c.H.toFixed(2)+"Mhz":"Stopped",c.ya=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(t){g=null,a=t.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,q=/( [a-z]+=)(['"])(.*?)\2/g;p=q.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Hc(a,b,c)}})}else c(a,null)} +function Ic(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Ec||K(!0));p=!1}var h,l,p=!0;Ec++;la[b]={};try{if(h=document.getElementById(b)){var q;if("object"==typeof resources&&(q=resources.css)){var t=document.head||document.getElementsByTagName("head")[0],P=document.createElement("style");P.type="text/css";P.styleSheet?P.styleSheet.cssText=q:P.appendChild(document.createTextNode(q));t.appendChild(P)}d|| +(q=a,"pdp"==a.substr(0,3)&&(q="pdpjs"),d="/versions/"+q+"/1.34.0/components.xsl");q=function(e,l){l?Fc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Ec||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Ec|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Fc(c,b,a,e,!0,f,q):Gc(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ta){g(ta.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Ic("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Ic("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",p=null,q=0;q Date: Sun, 26 Feb 2017 12:17:21 -0800 Subject: [PATCH 16/30] getOpcode() can now handle infinite indirections without starving the emulator --- modules/pdp10/lib/cpuops.js | 1 + modules/pdp10/lib/cpustate.js | 70 +++---- modules/pdp10/lib/debugger.js | 14 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 291 +++++++++++++++-------------- versions/pdpjs/1.34.0/pdp10.js | 132 ++++++------- 5 files changed, 259 insertions(+), 249 deletions(-) diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index 22f15ce4e..d314e14e7 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -4210,6 +4210,7 @@ PDP10.opIO = function(op) PDP10.opUndefined = function(op) { this.println("undefined opcode: " + Str.toOct(op)); + this.advancePC(-1); this.stopCPU(); }; diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index 5ea763f2d..b34e2db87 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -174,8 +174,7 @@ class CPUStatePDP10 extends CPUPDP10 { */ initCPU() { - this.regOP = 0; - this.regEA = 0; + this.regEA = this.regRA = this.regOP = 0; this.regPC = this.lastPC = this.addrReset; /* @@ -277,8 +276,9 @@ class CPUStatePDP10 extends CPUPDP10 { { var state = new State(this); state.set(0, [ - this.regOP, this.regEA, + this.regRA, + this.regOP, this.regPC, this.lastPC, this.lastAddr, @@ -305,8 +305,9 @@ class CPUStatePDP10 extends CPUPDP10 { * of what save() does when it collects a bunch of object properties into an array. */ [ - this.regOP, this.regEA, + this.regRA, + this.regOP, this.regPC, this.lastPC, this.lastAddr, @@ -326,42 +327,39 @@ class CPUStatePDP10 extends CPUPDP10 { /** * getOpcode() * - * This fetches the next opcode, decodes the low 23 bits (I,X,Y), sets regEA, and returns the - * the high 13 bits for further decoding. + * Normally, this fetches the next opcode in regOP, decodes the low 23 bits (I,X,Y), records the effective + * address (E) in regEA, updates regPC, and returns the high 13 bits of the opcode for further decoding. + * + * However, if a reference address still needs to be decoded (due to indirection), we take care of that first. * * @this {CPUStatePDP10} - * @return {number} + * @return {number} (-1 if the reference address in regRA has not yet been fully decoded) */ getOpcode() { - var pc = this.lastPC = this.regPC; - var r = this.regOP = this.readWord(pc); - this.regPC = (pc + 1) % PDP10.ADDR_LIMIT; - var e, x, nMaxIndirect = 4; - while (true) { - /* - * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the - * "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E to Y, - * then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R to [E] - * and repeat the process. - */ - e = r & PDP10.OPCODE.Y_MASK; - x = (r >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; - if (x) e = (e + this.readWord(x)) & PDP10.ADDR_MASK; - if (!(r & PDP10.OPCODE.I_BIT)) break; - /* - * We allow this process to repeat only a few times, because more than that suggests we're executing - * garbage. Also, allowing this to loop endlessly would hang the simulation; if it turns out there is - * real-world PDP-10 code that requires a long series of indirections, we should factor this logic out - * as a separate operation. Note that would mean passing the full opcode on to the next level of decoding. - */ - if (--nMaxIndirect < 0) { - this.bus.fault(r); - break; - } - r = this.readWord(e); + if ((this.regRA & PDP10.OPCODE.I_BIT)) { + this.regRA = this.readWord(this.regEA); + } else { + this.regRA = this.regOP = this.readWord(this.lastPC = this.regPC); } - this.regEA = e; + + /* + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the + * "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E to Y, + * then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R to [E] + * and repeat the process. + * + * However, we don't actually repeat the process immediately; we need to treat each indirection as a + * separate decoding step, to ensure that the emulator can "breathe" periodically. So instead, we + * return -1, indicating that the opcode is not fully decoded, and then on the next call, instead of + * fetching another opcode, we fetch [E], update R, and decode R again. + */ + this.regEA = this.regRA & PDP10.OPCODE.Y_MASK; + var x = (this.regRA >> PDP10.OPCODE.X_SHIFT) & PDP10.OPCODE.X_MASK; + if (x) this.regEA = (this.regEA + this.readWord(x)) & PDP10.ADDR_MASK; + if (this.regRA & PDP10.OPCODE.I_BIT) return -1; + + this.regPC = (this.regPC + 1) % PDP10.ADDR_LIMIT; return (this.regOP / PDP10.OPCODE.ACSHIFT)|0; } @@ -810,7 +808,9 @@ class CPUStatePDP10 extends CPUPDP10 { this.opFlags &= PDP10.OPFLAG.PRESERVE; var op = this.getOpcode(); - this.opDecode(op); + if (op >= 0) { + this.opDecode(op); + } } while (this.nStepCycles > 0); diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index e1f9b24be..736a72a3b 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -848,6 +848,12 @@ class DebuggerPDP10 extends Debugger { case DebuggerPDP10.REGS.PC: value = this.cpu.getPC(); break; + case DebuggerPDP10.REGS.RA: + value = this.cpu.regRA; + break; + case DebuggerPDP10.REGS.EA: + value = this.cpu.regEA; + break; } return value; } @@ -1924,7 +1930,7 @@ class DebuggerPDP10 extends Debugger { { var i; var sDump = ""; - sDump += this.getRegOutput(DebuggerPDP10.REGS.PC); + sDump += this.getRegOutput(DebuggerPDP10.REGS.RA) + this.getRegOutput(DebuggerPDP10.REGS.EA); if (fMisc) sDump += '\n' + this.getMiscDump(); return sDump; } @@ -3638,11 +3644,13 @@ if (DEBUGGER) { ]; DebuggerPDP10.REGS = { - PC: 0 + PC: 0, + RA: 1, + EA: 2 }; DebuggerPDP10.REGNAMES = [ - "PC" + "PC", "RA", "EA" ]; /* diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 7a4bdaf91..6e3093cec 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -32,18 +32,18 @@ var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:functi function ha(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return ja(function(){return ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var la=Math.pow(2,36),ma=-Math.pow(2,35),q={Zb:0,nb:1,ac:2,bc:3,cc:4,dc:5,ec:6,fc:7,Xa:8,gc:9,ob:10,hc:11,ic:12,pb:13,jc:14,kc:15,lc:16,mc:17,nc:18,oc:19,pc:20,qc:21,rc:22,sc:23,tc:24,uc:25,vc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Wa:65,Yb:66,$b:67,wc:68,E:69,xc:70,yc:71,zc:72,Ac:73,Bc:74,Cc:75,Dc:76,Ec:77,Fc:78,Gc:79,Hc:80,Q:81, -Ic:82,Jc:83,Kc:84,Lc:85,Mc:86,Nc:87,Oc:88,Pc:89,tb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Qc:97,Rc:98,Sc:99,d:100,e:101,Tc:102,Uc:103,Vc:104,Wc:105,Xc:106,k:107,Yc:108,Zc:109,n:110,$c:111,p:112,q:113,r:114,ad:115,t:116,cd:117,dd:118,ed:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,qb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.ab=b.comment;this.sb=b;this.exports={};this.F=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ta:!1,T:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ka=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +var la=Math.pow(2,36),ma=-Math.pow(2,35),q={$b:0,nb:1,bc:2,cc:3,dc:4,ec:5,fc:6,gc:7,Ya:8,hc:9,ob:10,ic:11,jc:12,pb:13,kc:14,lc:15,mc:16,nc:17,oc:18,pc:19,qc:20,rc:21,sc:22,tc:23,uc:24,vc:25,wc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Xa:65,Zb:66,ac:67,xc:68,E:69,yc:70,zc:71,Ac:72,Bc:73,Cc:74,Dc:75,Ec:76,Fc:77,Gc:78,Hc:79,Ic:80,Q:81, +Jc:82,Kc:83,Lc:84,Mc:85,Nc:86,Oc:87,Pc:88,Qc:89,tb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Rc:97,Sc:98,Tc:99,d:100,e:101,Uc:102,Vc:103,Wc:104,Xc:105,Yc:106,k:107,Zc:108,$c:109,n:110,ad:111,p:112,q:113,r:114,bd:115,t:116,dd:117,ed:118,fd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,qb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.bb=b.comment;this.sb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ua:!1,U:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ka=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function w(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function x(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;bb?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function jb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function kb(a,b){var c,d={W:null,S:null,ja:null,ia:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=g.load;d.ia=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.S=g.symbols;d.W.length?1==d.W.length&&(w(d.W[0]),d=null):(w("Empty resource: "+a),d=null)}catch(h){w("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=g.load;d.ia=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.T=g.symbols;d.W.length?1==d.W.length&&(w(d.W[0]),d=null):(w("Empty resource: "+a),d=null)}catch(h){w("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Eb,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.wb,toggle:this.Rb,reset:this.Nb, -set:this.Qb};D(this)}p(Pb,t);l=Pb.prototype;l.reset=function(a){this.stop();a&&Rb(this,this.w=0)}; -l.ea=function(a,b,c,d){if(this.D&&this.D.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.F[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.F[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.F[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Sb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Tb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Sb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Tb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Ub(this);Vb(this)};l.ma=function(a,b){if(!b)if(this.U&&Wb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Xb(this,this.i=a[0]),Rb(this,this.w=a[1]),Yb(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Vb(this);return!0};function Zb(a,b,c){if(a=a.F[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ub(a,b){for(var c in a.B)Zb(a,c,null!=b?b:a.B[c])}function $b(a,b,c){if(a=a.F[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Vb(a){for(var b in a.b)$b(a,b,a.b[b][1])} -l.wb=function(a,b,c){if(Sb(this,b)){if(c){var d=this;setTimeout(function(){Tb(d,b);a&&a()},+c);return!1}Tb(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return Yb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,$b(this,a,c[1]),!0):!1};l.Rb=function(a){return Sb(this,a)?(Tb(this,a),!0):!1};function Sb(a,b){var c=a.b[b];return c?($b(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=ac&&(a.N=b==bc,a.O=b==cc),!0):!1} -function Tb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&($b(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Fb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[dc]&&this.b[dc][1]&&ec(this.g))};l.Gb=function(){};l.Ab=function(a){a||this.g.R()}; -l.yb=function(a){if(!a&&!this.g.j.J)if(this.b[dc]&&this.b[dc][1])ec(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),fc(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<a;a++)this.b["S"+a]=[0,0,!1,!1,this.Fb,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.xb,toggle:this.Sb,reset:this.Ob, +set:this.Rb};D(this)}p(Pb,t);l=Pb.prototype;l.reset=function(a){this.stop();a&&Rb(this,this.w=0)}; +l.ea=function(a,b,c,d){if(this.D&&this.D.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Sb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Tb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Sb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Tb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ua=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Ub(this);Vb(this)};l.ma=function(a,b){if(!b)if(this.S&&Wb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Xb(this,this.i=a[0]),Rb(this,this.w=a[1]),Yb(this,a[2]);return!0};l.Ob=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Vb(this);return!0};function Zb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ub(a,b){for(var c in a.B)Zb(a,c,null!=b?b:a.B[c])}function $b(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Vb(a){for(var b in a.b)$b(a,b,a.b[b][1])} +l.xb=function(a,b,c){if(Sb(this,b)){if(c){var d=this;setTimeout(function(){Tb(d,b);a&&a()},+c);return!1}Tb(this,b)}return!0};l.Rb=function(a,b){if("SR"==a)return Yb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,$b(this,a,c[1]),!0):!1};l.Sb=function(a){return Sb(this,a)?(Tb(this,a),!0):!1};function Sb(a,b){var c=a.b[b];return c?($b(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=ac&&(a.N=b==bc,a.O=b==cc),!0):!1} +function Tb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&($b(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Gb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[dc]&&this.b[dc][1]&&ec(this.g))};l.Hb=function(){};l.Bb=function(a){a||this.g.R()}; +l.zb=function(a){if(!a&&!this.g.j.J)if(this.b[dc]&&this.b[dc][1])ec(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),fc(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>f&&(m=f);h.Ha=e-h.v+m;e=k+16384;f-=m;g++;continue}}return qc(rc,e,f)}e=new L(a,e,m,16384,d);nc(e,a.A,h);a.b[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+Ic[d]+" at "+Ra(b)),!0):qc(Jc,b,c)} function lc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function kc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function oc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.aa&&(a.aa+=a.U,c=!0);0<=a.ba&&a.ba<=dd(a)&&(a.U=a.ba=-1,$c(a),a.R(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.qa))}} -l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.F[b]=c,!0;case "run":return this.F[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.T)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.M/a.N?b=1:d=!0;a.O=b;b=a.Ca*a.O;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var e=a.F.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&hd(a.D)}hc(a,a.B);a.B=0;a.w=va();a.H=0;fd(a);return d}function id(a,b){for(var c=a.G.length-1;0<=c;c--){var d=a.G[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.I-=a.K;a.K=0;b&&(a.I=0);return c} -l.Ob=function(){if(this.j.J){this.xa>=this.Ra&&fd(this,!0);this.fa=0;this.pa=va();if(this.H){var a=this.pa-this.H;a>this.Qa&&(this.w+=a,this.w>this.pa&&(this.w=this.pa))}try{do{var b=id(this,this.j.Da?1:this.sa);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.fa+=b;this.B+=b;ic(this,b);gc(this,b);this.P-=b;if(0>=this.P){this.P+=this.sa;++this.Sa>=ld&&(this.D&&K(this.D,void 0),this.Sa=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),dd(this));Ka(this,e.stack|| -e.message);return}if(this.j.J){a=setTimeout;b=this.cb;this.H=va();var c=this.Qa;this.fa&&(c=Math.round(c*this.fa/this.sa));var c=c-(this.H-this.pa),d=this.H-this.w;d&&(this.M=Math.round(this.B/(10*d))/100,864E5<=d&&(this.L=0,ed(this)));if(0>c||this.Mc&&(this.w-=c),c=0;this.xa+=this.fa;this.H+=c;a(b,c)}}}; -function ec(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{ed(a);a.j.J=!0;a.j.Pa=!0;var c=a.F.run;c&&(c.textContent="Halt");a.D&&(b&&hd(a.D,!0),a.D.start(a.w,dd(a)));a.A||a.status("Started");setTimeout(a.cb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){kd(this);hc(this,this.B);this.B=0;this.j.J=!1;if(b=this.F.run)b.textContent="Run";this.D&&this.D.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; -function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.bb=b;this.$a=+a.addrReset||0;this.rb=nd.bind(this);this.b=P.bind(this);this.ha=null;this.Za=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.bb);this.j.J&&this.R();this.ga=this.ya=0;this.na=this.i=this.oa=this.$a;this.u=0;this.Z=this.Kb;this.va=this.Xb;this.ha=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.kb=function(){return 0}; -l.save=function(){var a=new J(this);a.set(0,[this.ya,this.ga,this.i,this.oa,this.na,this.u]);a.set(1,[]);a.set(2,[this.L,this.O,this.j.X]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.ya=b.next().value;this.ga=b.next().value;this.i=b.next().value;this.oa=b.next().value;this.na=b.next().value;this.u=b.next().value;b=a[2];this.L=b[0];ed(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].Z(a&16383,a)};l.Xb=function(a,b){var c=this.C;a=this.na=a;c.b[(a&c.u)>>>c.i].va(b,a&16383,a)}; -l.Ia=function(a){this.j.complete=!0;var b=this.A?pd(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.I=this.K=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(qd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.ha||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&qd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;var d=this.oa=this.i;a=this.ya=this.Z(d);this.i=(d+1)%Jb;for(var e,f=4;;){d=a&262143;(e=a>>18&15)&&(d=d+this.Z(e)& -Kb);if(!(a&4194304))break;if(0>--f){this.C.jb(a);break}a=this.Z(d)}this.ga=d;this.rb(this.ya/Ob|0)}while(0>4].call(this,a)}function Q(a){this.b(a)}function sd(a){this.b(a)}function td(a){this.b(a)}function ud(a){a&=15;var b=this.Z(this.ga),c=this.Z(a);this.va(a,(c&262143)+(b-(b&262143)))} -function R(a){this.b(a)}function P(a){this.f("undefined opcode: "+Ra(a));this.R()} -var rd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +l.wb=function(a){this.w||(this.A&&Pa(this.A,4)&&E(this.A,"memory fault on "+M(this.A,a),!0,!0),this.g.R())};function qc(a,b,c){w("Memory block error ("+a+": "+F(b)+","+F(c)+")");return!1}var rc=1,Jc=2;function Kc(a){t.call(this,"Device",a,256)}p(Kc,t);l=Kc.prototype;l.ua=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.A=d;D(this)};l.ma=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){return(new J(this)).data()}; +l.restore=function(){return!0};vb(function(){for(var a=C(document,B,"device"),b=0;b=c+d?a>>c&(1<=a.fa&&(a.fa+=a.ba,c=!0);0<=a.ga&&a.ga<=dd(a)&&(a.ba=a.ga=-1,$c(a),a.R(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.ra))}} +l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.U)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.O/a.P?b=1:d=!0;a.S=b;b=a.Qa*a.S;if(a.P!=b){a.P=b;b=a.P.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&hd(a.D)}hc(a,a.F);a.F=0;a.B=va();a.I=0;fd(a);return d}function id(a,b){for(var c=a.H.length-1;0<=c;c--){var d=a.H[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.K-=a.L;a.L=0;b&&(a.K=0);return c} +l.Pb=function(){if(this.j.J){this.ya>=this.Sa&&fd(this,!0);this.ha=0;this.qa=va();if(this.I){var a=this.qa-this.I;a>this.Ra&&(this.B+=a,this.B>this.qa&&(this.B=this.qa))}try{do{var b=id(this,this.j.Da?1:this.ta);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.ha+=b;this.F+=b;ic(this,b);gc(this,b);this.Y-=b;if(0>=this.Y){this.Y+=this.ta;++this.Ta>=ld&&(this.D&&K(this.D,void 0),this.Ta=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),dd(this));Ka(this,e.stack|| +e.message);return}if(this.j.J){a=setTimeout;b=this.eb;this.I=va();var c=this.Ra;this.ha&&(c=Math.round(c*this.ha/this.ta));var c=c-(this.I-this.qa),d=this.I-this.B;d&&(this.O=Math.round(this.F/(10*d))/100,864E5<=d&&(this.M=0,ed(this)));if(0>c||this.Oc&&(this.B-=c),c=0;this.ya+=this.ha;this.I+=c;a(b,c)}}}; +function ec(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{ed(a);a.j.J=!0;a.j.Pa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.D&&(b&&hd(a.D,!0),a.D.start(a.B,dd(a)));a.A||a.status("Started");setTimeout(a.eb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){kd(this);hc(this,this.F);this.F=0;this.j.J=!1;if(b=this.G.run)b.textContent="Run";this.D&&this.D.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; +function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.cb=b;this.ab=+a.addrReset||0;this.rb=nd.bind(this);this.b=P.bind(this);this.na=null;this.$a=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.cb);this.j.J&&this.R();this.w=this.N=this.za=0;this.oa=this.i=this.pa=this.ab;this.u=0;this.aa=this.Lb;this.wa=this.Yb;this.na=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.kb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.w,this.N,this.za,this.i,this.pa,this.oa,this.u]);a.set(1,[]);a.set(2,[this.M,this.S,this.j.X]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.w=b.next().value;this.N=b.next().value;this.za=b.next().value;this.i=b.next().value;this.pa=b.next().value;this.oa=b.next().value;this.u=b.next().value;b=a[2];this.M=b[0];ed(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].aa(a&16383,a)};l.Yb=function(a,b){var c=this.C;a=this.oa=a;c.b[(a&c.u)>>>c.i].wa(b,a&16383,a)}; +l.Ia=function(a){this.j.complete=!0;var b=this.A?qd(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.K=this.L=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(rd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.na||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&rd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;this.N=this.N&4194304?this.aa(this.w):this.za=this.aa(this.pa=this.i);this.w=this.N&262143;if(a=this.N>>18& +15)this.w=this.w+this.aa(a)&Kb;this.N&4194304?a=-1:(this.i=(this.i+1)%Jb,a=this.za/Ob|0);0<=a&&this.rb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function td(a){this.b(a)}function ud(a){this.b(a)}function vd(a){a&=15;var b=this.aa(this.w),c=this.aa(a);this.wa(a,(c&262143)+(b-(b&262143)))} +function R(a){this.b(a)}function P(a){this.f("undefined opcode: "+Ra(a));pd(this,-1);this.R()} +var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,td,td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,ud,ud,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, @@ -111,115 +111,116 @@ function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a) function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},ud,function(a){a&=15;var b=this.Z(a);this.va(a,b&262143)},function(a){a=this.Z(a&15);var b=this.Z(this.ga);this.va(this.ga,(b&262143)+(a-(a&262143)))},function(a){a&15&&ud.call(this, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,function(a){a&=15;var b=this.aa(a);this.wa(a,b&262143)},function(a){a=this.aa(a&15);var b=this.aa(this.w);this.wa(this.w,(b&262143)+(a-(a&262143)))},function(a){a&15&&vd.call(this, a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; -function vd(a){t.call(this,"ROM",a,128);this.S=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.G=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.G);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Y("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.S=a.S):c.w=null);wd(c)})}}p(vd,t); -vd.prototype.ta=function(a,b,c,d){this.C=b;this.g=c;this.A=d;wd(this)};vd.prototype.ma=function(){this.S&&(this.A&&xd(this.A,this.id,this.B,this.u,this.S),delete this.S);return!0};vd.prototype.da=function(){return!0}; -function wd(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.C,b,a.u,Nc)){var c;for(c=0;c>>f.i;0>>= -f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= -b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)kc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Wa&&c<=q.tb&&(b=c-(q.Wa-q.nb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.pb&&(b=q.ob);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ta=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;D(this)}; +function wd(a){t.call(this,"ROM",a,128);this.T=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.F=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.F);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Z("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.T=a.T):c.w=null);xd(c)})}}p(wd,t); +wd.prototype.ua=function(a,b,c,d){this.C=b;this.g=c;this.A=d;xd(this)};wd.prototype.ma=function(){this.T&&(this.A&&yd(this.A,this.id,this.B,this.u,this.T),delete this.T);return!0};wd.prototype.da=function(){return!0}; +function xd(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.C,b,a.u,Nc)){var c;for(c=0;c>>f.i;0>>= +f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= +b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)kc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Xa&&c<=q.tb&&(b=c-(q.Xa-q.nb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.pb&&(b=q.ob);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ua=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;D(this)}; l.mb=function(a){if(!this.b){var b=Yc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Ja)return;c=Za(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.ma=function(a,b){if(!b)if(this.mb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} -function Fd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} +function Gd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Gd(a,b,c){var d;if(b){b=Hd(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Ld(a,b){if(b)return Kd(a,b,a.aa[b]);var c=0;for(b in a.aa)Kd(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Jd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Md(a){Dd.call(this,a);this.xa=!1;this.na=!0;this.I=T();this.wa=T();this.N=T();this.H=[];this.b=this.K=this.G=[];Nd(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Od(this);this.A=this;this.oa={};this.V=this.gb=0;this.U=null;this.M=[];Pd(this,a.messages);this.sa=a.commands;this.L=0;this.Ca=this.ra=null;this.B=this.Ba=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return cd(b,a)}):void 0===global[B]&&(global[B]=function(a){return cd(b, -a)})}p(Md,Dd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,vb:void 0===b?!1:b,la:!1,ca:c}}function Qd(a){return[a.v,a.vb,a.ca,a.la,a.Oa]}function Rd(a,b){var c=T(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.eb=Ed(a,c.Oa=b[4]));return c}l=Md.prototype; -l.ta=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.fa=a.u;(a=Yc(a,"messages"))&&Pd(this,a);Sd(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Ic[c],n&&d.f(F(n.id,8)+" %"+F(e<=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Md(a,b){if(b)return Ld(a,b,a.Y[b]);var c=0;for(b in a.Y)Ld(a,b,a.Y[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Kd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Nd(a){Ed.call(this,a);this.xa=!1;this.na=!0;this.I=T();this.ta=T();this.N=T();this.H=[];this.b=this.K=this.F=[];Od(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Pd(this);this.A=this;this.oa={};this.V=this.hb=0;this.S=null;this.M=[];Qd(this,a.messages);this.sa=a.commands;this.L=0;this.Ca=this.ra=null;this.B=this.za=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return cd(b,a)}):void 0===global[B]&&(global[B]=function(a){return cd(b, +a)})}p(Nd,Ed);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,vb:void 0===b?!1:b,la:!1,ca:c}}function Rd(a){return[a.v,a.vb,a.ca,a.la,a.Oa]}function Sd(a,b){var c=T(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.fb=Fd(a,c.Oa=b[4]));return c}l=Nd.prototype; +l.ua=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.fa=a.u;(a=Yc(a,"messages"))&&Qd(this,a);Td(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Ic[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.oa==b)){b=a.g;var e=b.i;b.i=(e+1)%Jb;b=e}if(0d&&(d=a.g.Z(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} -function Fe(a,b,c,d){var e=T(b.v),f=a.Aa(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Ge)if(g=Ge[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=He;m=n&3;break;case 32256:k=Ie;m=n&7;break;case 29248:k=Je,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ke&&(k="B");k=Le[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Ud(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Aa(e,1),g+=" "+Ud(k),null== -e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.qa)):h+(null!=d?"="+d.toString():""));return h}function Nd(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.G)for(b=1;b>>d.i],!0);a.G=["bw"];a.pa=0;a.ha=0} -l.za=function(a,b,c){var d=!0;c||Me(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].za(e&16383,a==this.G)}}d&&(a.push(b),c?b.la=!0:(Ne(this,a,a.length-1,"set"),Od(this)));return d};function Me(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.G));h.la||Od(a);break}}return f} -function Oe(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.hb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({bd:b,v:c,xb:d,S:e,fb:f})}function Qe(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.xb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=Fe(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} -function Pe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Be+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==de&&(bb=1E5,wc=["CALL"]);for(void 0!==ce&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;fe++;bb--}}fe||(a.f("no "+ee+"history available"), -a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,ie="ds"==Ha;if(fa){if("l"==fa.charAt(0))fa=fa.substr(1)||yf,pa=Id(a,fa);else{var je=Z(a,fa);je&&(pa=je.v-oa.v)}0>pa&&(pa=0);65536ne;ne++)le+=String.fromCharCode((Eb%64|0)+32), -Eb/=64}qa&&(qa+="\n");qa=ie?qa+(ra+","):qa+(U+": "+ra+(0>me?" "+le:""))}qa&&a.f(qa);a.wa=oa;a.ca=Af}}}}break;case "e":if("else"==g[0])break;var oe,pe,qe=g[0],zc=g[1];"e"==qe||"ew"==qe?(oe=a.Aa,pe=a.Ya):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,Ef=256;65536>eb.v>>>0;){Ec.v=a.Aa(eb,2);if(null==eb.v||!Ef--)break;if(!(Ec.v&1)){for(var Ff=a,Hb=Ec,se=null,fb=Hb.v,te=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bbf){if(cf(d,this.K)){this.B=new J(this,"1.34.0",mf);cf(this.B)&&(nf(this,d),a=of,pf(this.B));this.B.set(jf,ab());qf(this.B);var e=this.b&&!this.I;if(a==kf||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=hf(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?cf(d,g):("error"==f&&"no machine state"!= -g?(this.Y("Error: "+g),"unable to verify user"==g&&(ob(rf,""),this.i=null)):this.f(f+": "+g),pf(d),cf(d)?(c=hf(d),e=!0):c=!1))}e&&ff(this,c?d:null)}else a==of&&d.clear()}else ff(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.T=!0;var d=this.F.power;d&&(d.textContent="Shutdown");this.g&&(sf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(nf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function nf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} -function We(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",gf),h=ab();g.set(jf,h);f.set(jf,h);f.set(tf,"1.34.0");f.set(uf,window?window.location.href:null);f.set(vf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.T=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;kd&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.pa==b&&(b=pd(a.g,1)));if(0d&&(d=a.g.aa(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} +function Ie(a,b,c,d){var e=T(b.v),f=a.Ba(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Je)if(g=Je[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ke;m=n&3;break;case 32256:k=Le;m=n&7;break;case 29248:k=Me,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ne&&(k="B");k=Oe[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Vd(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Ba(e,1),g+=" "+Vd(k),null== +e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.ra)):h+(null!=d?"="+d.toString():""));return h}function Od(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.pa=0;a.ha=0} +l.Aa=function(a,b,c){var d=!0;c||Pe(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].Aa(e&16383,a==this.F)}}d&&(a.push(b),c?b.la=!0:(Qe(this,a,a.length-1,"set"),Pd(this)));return d};function Pe(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.F));h.la||Pd(a);break}}return f} +function Re(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.ib);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({cd:b,v:c,yb:d,T:e,gb:f})} +function Ue(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.yb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=Ie(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} +function Se(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ee+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.S=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==ge&&(bb=1E5,wc=["CALL"]);for(void 0!==fe&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;ie++;bb--}}ie||(a.f("no "+he+"history available"), +a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,le="ds"==Ha;if(fa){if("l"==fa.charAt(0))fa=fa.substr(1)||Cf,pa=Jd(a,fa);else{var me=Z(a,fa);me&&(pa=me.v-oa.v)}0>pa&&(pa=0);65536qe;qe++)oe+=String.fromCharCode((Eb%64|0)+32), +Eb/=64}qa&&(qa+="\n");qa=le?qa+(ra+","):qa+(U+": "+ra+(0>pe?" "+oe:""))}qa&&a.f(qa);a.ta=oa;a.ca=Ef}}}}break;case "e":if("else"==g[0])break;var re,se,te=g[0],zc=g[1];"e"==te||"ew"==te?(re=a.Ba,se=a.Za):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,If=256;65536>eb.v>>>0;){Ec.v=a.Ba(eb,2);if(null==eb.v||!If--)break;if(!(Ec.v&1)){for(var Jf=a,Hb=Ec,ve=null,fb=Hb.v,we=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bff){if(gf(d,this.K)){this.B=new J(this,"1.34.0",qf);gf(this.B)&&(rf(this,d),a=sf,tf(this.B));this.B.set(nf,ab());uf(this.B);var e=this.b&&!this.I;if(a==of||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=mf(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gf(d,g):("error"==f&&"no machine state"!= +g?(this.Z("Error: "+g),"unable to verify user"==g&&(ob(vf,""),this.i=null)):this.f(f+": "+g),tf(d),gf(d)?(c=mf(d),e=!0):c=!1))}e&&kf(this,c?d:null)}else a==sf&&d.clear()}else kf(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.U=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(wf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(rf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function rf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} +function $e(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",lf),h=ab();g.set(nf,h);f.set(nf,h);f.set(xf,"1.34.0");f.set(yf,window?window.location.href:null);f.set(zf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.U=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;k=d||30<=(c.Ba+=d))&&(e.textContent=c.j.J?c.M.toFixed(2)+"Mhz":"Stopped",c.Ba=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.F.PC){var f=a.A&&a.A.ca||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.F.PC.textContent!=e&&(a.F.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Qf(a,b,c)}})}else c(a,null)} -function Rf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Nf||zb(!0));m=!1}var h,k,m=!0;Nf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Of(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Nf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Nf|| -zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Of(c,b,a,e,!0,f,n):Pf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Rf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Rf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +function K(a,b){if(a.g){var c=a.g,d=b||0,e=c.G.speed;e&&(0>=d||30<=(c.Ca+=d))&&(e.textContent=c.j.J?c.O.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.G.PC){var f=a.A&&a.A.ca||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Uf(a,b,c)}})}else c(a,null)} +function Vf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Rf||zb(!0));m=!1}var h,k,m=!0;Rf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Sf(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Rf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Rf|| +zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Sf(c,b,a,e,!0,f,n):Tf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Vf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Vf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={Ab:0,Pa:1,Cb:2,Db:3,Eb:4,Fb:5,Gb:6,Hb:7,Ha:8,Ib:9,Qa:10,Jb:11,Kb:12,Ra:13,Lb:14,Mb:15,Nb:16,Ob:17,Pb:18,Qb:19,Rb:20,Sb:21,Tb:22,Ub:23,Vb:24,Wb:25,Xb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ga:65,zb:66,Bb:67,Yb:68,E:69,Zb:70,$b:71,ac:72,bc:73,cc:74,dc:75,ec:76,fc:77,gc:78,hc:79,ic:80,Q:81, -jc:82,kc:83,lc:84,mc:85,nc:86,oc:87,pc:88,qc:89,Wa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,rc:97,sc:98,tc:99,d:100,e:101,uc:102,vc:103,wc:104,xc:105,yc:106,k:107,zc:108,Ac:109,n:110,Bc:111,p:112,q:113,r:114,Cc:115,t:116,Dc:117,Ec:118,Fc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Sa:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ka=b.comment;this.Va=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.la=this.id:(this.ma=this.id.substr(0,a),this.la=this.id.substr(a+1));this.b={ready:!1,ra:!1,Ea:!1,w:!1,error:!1};this.ua=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.aa=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={Bb:0,Qa:1,Db:2,Eb:3,Fb:4,Gb:5,Hb:6,Ib:7,Ia:8,Jb:9,Ra:10,Kb:11,Lb:12,Sa:13,Mb:14,Nb:15,Ob:16,Pb:17,Qb:18,Rb:19,Sb:20,Tb:21,Ub:22,Vb:23,Wb:24,Xb:25,Yb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ha:65,Ab:66,Cb:67,Zb:68,E:69,$b:70,ac:71,bc:72,cc:73,dc:74,ec:75,fc:76,gc:77,hc:78,ic:79,jc:80,Q:81, +kc:82,lc:83,mc:84,nc:85,oc:86,pc:87,qc:88,rc:89,Xa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,sc:97,tc:98,uc:99,d:100,e:101,vc:102,wc:103,xc:104,yc:105,zc:106,k:107,Ac:108,Bc:109,n:110,Cc:111,p:112,q:113,r:114,Dc:115,t:116,Ec:117,Fc:118,Gc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ta:127}; +function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.La=b.comment;this.Wa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ma=this.id:(this.na=this.id.substr(0,a),this.ma=this.id.substr(a+1));this.b={ready:!1,sa:!1,Fa:!1,w:!1,error:!1};this.va=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.aa=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",p;for(p in b)b.hasOwnProperty(p)&&(l&&(l+="&"),l+=p+"="+encodeURIComponent(b[p]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={F:null,J:null,S:null,R:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else d.F=g;d.J=g.symbols;d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else d.F=g;d.L=g.symbols;d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.fb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Ya,toggle:this.sb,reset:this.ob, -set:this.rb};E(this)}n(Wa,u);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; +function Wa(a,b){u.call(this,"Panel",a);this.A=this.B=0;this.P=b;this.c=this.u=this.g=this.h=0;this.D=this.G=-1;this.J=this.K=this.s=!1;this.N=Xa;this.j={};this.a={START:[1,1,!0,!1,this.hb],STEP:[1,1,!1,!1,this.ib],ENABLE:[1,1,!1,!1,this.bb],CONT:[1,1,!0,!1,this.$a],DEP:[0,0,!0,!1,this.ab],EXAM:[1,1,!0,!1,this.cb],LOAD:[1,1,!0,!1,this.fb],TEST:[0,0,!0,!1,this.eb]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.gb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Za,toggle:this.tb,reset:this.pb, +set:this.sb};E(this)}n(Wa,u);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; k.T=function(a,b,c,d){if(this.m&&this.m.T(a,b,c,d)||this.f&&this.f.T(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.T.call(this,a,b,c,d)}};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Za(this);$a(this)};k.U=function(a,b){if(!b)if(this.P&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.O=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),M(this,this.h=a[1]),bb(this,a[2]);return!0};k.ob=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} -k.Ya=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; -k.rb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.eb=function(a){a||this.f.b.v||Q(this,this.g)};k.cb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.fb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.fb=function(a){a||this.f.b.v||Q(this,this.g)};k.eb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.gb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Z)return h.wa+=h.Z-e,h.Z=e,!0;if(e>=h.Z+h.wa){p=h.size-(e-l);p>f&&(p=f);h.wa=e-h.Z+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} -function qb(a){for(var b=0,c=[],d=0;d>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Z)return h.xa+=h.Z-e,h.Z=e,!0;if(e>=h.Z+h.xa){p=h.size-(e-l);p>f&&(p=f);h.xa=e-h.Z+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function qb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.L&&(a.L+=a.ja,c=!0);0<=a.ba&&a.ba<=Kb(a)&&(a.ja=a.ba=-1,Jb(a),R(a),c=!0);c&&a.I(Kb(a)+" cycles: checksum="+F(a.na))}} -k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.H/a.K&&(b=1);a.N=b;b=a.Aa*a.N;if(a.K!=b){a.K=b;b=a.K.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.aa&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.aa.focus(),window&&window.scrollTo(b,d)))}kb(a,a.j);a.j=0;a.h=w();a.u=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.A-=a.B;a.B=0;b&&(a.A=0);return c} -k.pb=function(){if(this.b.v){this.pa>=this.Ca&&Mb(this,!0);this.V=0;this.ia=w();if(this.u){var a=this.ia-this.u;a>this.Ba&&(this.h+=a,this.h>this.ia&&(this.h=this.ia))}try{do{for(var b,c=this.b.sa?1:this.ca,d=this.s.length-1;0<=d;d--){var e=this.s[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.xa(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.V+=b;this.j+=b;lb(this,b);jb(this,b);this.P-=b;if(0>=this.P){this.P+=this.ca;++this.Da>=Qb&&(this.m&&S(this.m,void 0),this.Da=0);break}}while(this.b.v)}catch(f){R(this); -this.m&&this.m.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.La;this.u=w();c=this.Ba;this.V&&(c=Math.round(c*this.V/this.ca));c-=this.u-this.ia;if(d=this.u-this.h)this.H=Math.round(this.j/(10*d))/100,864E5<=d&&(this.D=0,Lb(this));if(0>c||this.Hc&&(this.h-=c),c=0;this.pa+=this.V;this.u+=c;a(b,c)}}}; -function ib(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Lb(a);a.b.v=!0;a.b.Fa=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Kb(a));a.o||a.status("Started");setTimeout(a.La,0)}}k.xa=function(){return 0};function R(a){var b=!1;if(a.b.v){Pb(a);kb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Kb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; -function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Ta=b;this.Ja=+a.addrReset||0;this.Ua=Sb.bind(this);this.a=V.bind(this);this.fa=null;this.Ia=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Ta);this.b.v&&R(this);this.W=this.qa=0;this.ha=this.g=this.za=this.Ja;this.c=0;this.M=this.lb;this.Y=this.yb;this.fa=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Na=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[this.qa,this.W,this.g,this.za,this.ha,this.c]);a.set(1,[]);a.set(2,[this.D,this.N,this.b.G]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.qa=b.next().value;this.W=b.next().value;this.g=b.next().value;this.za=b.next().value;this.ha=b.next().value;this.c=b.next().value;b=a[2];this.D=b[0];Lb(this,b[1]);this.b.G=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.yb=function(a,b){var c=this.l;a=this.ha=a;c.a[(a&c.g)>>>c.c].Y(b,a&16383,a)}; -k.xa=function(a){this.b.complete=!0;var b=a?this.b.Fa?0:1:-1;this.b.Fa=!1;this.A=this.B=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.fa||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;var c=this.za=this.g;a=this.qa=this.M(c);this.g=(c+1)%Sa;for(var d,e=4;;){c=a&262143;(d=a>>18&15)&&(c=c+this.M(d)&Ta);if(!(a&4194304))break;if(0>--e){a=this.l;a.h||R(a.f);break}a=this.M(c)}this.W=c;this.Ua(this.qa/Va|0)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.M(this.W),c=this.M(a);this.Y(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));R(this)} +function T(a,b,c,d,e){this.h=a;this.id=xb+=2;this.Z=b;this.xa=c;this.size=d||0;this.type=e||yb;this.m=e==zb;this.M=this.o=this.c=this.ga;this.Y=this.l=this.g=this.ha;this.f=this.i=0;pb(this);this.ua=this.Ya=!1;if(this.size){a=this.a=Array(this.size);for(b=0;b=c+d?a>>c&(1<=a.P&&(a.P+=a.ca,c=!0);0<=a.da&&a.da<=Kb(a)&&(a.ca=a.da=-1,Jb(a),R(a),c=!0);c&&a.I(Kb(a)+" cycles: checksum="+F(a.oa))}} +k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.J/a.N&&(b=1);a.V=b;b=a.Ba*a.V;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.aa&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.aa.focus(),window&&window.scrollTo(b,d)))}kb(a,a.j);a.j=0;a.h=w();a.A=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.B-=a.D;a.D=0;b&&(a.B=0);return c} +k.qb=function(){if(this.b.v){this.qa>=this.Da&&Mb(this,!0);this.ba=0;this.ka=w();if(this.A){var a=this.ka-this.A;a>this.Ca&&(this.h+=a,this.h>this.ka&&(this.h=this.ka))}try{do{for(var b,c=this.b.ta?1:this.ea,d=this.u.length-1;0<=d;d--){var e=this.u[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.ya(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.ba+=b;this.j+=b;lb(this,b);jb(this,b);this.W-=b;if(0>=this.W){this.W+=this.ea;++this.Ea>=Qb&&(this.m&&S(this.m,void 0),this.Ea=0);break}}while(this.b.v)}catch(f){R(this); +this.m&&this.m.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ma;this.A=w();c=this.Ca;this.ba&&(c=Math.round(c*this.ba/this.ea));c-=this.A-this.ka;if(d=this.A-this.h)this.J=Math.round(this.j/(10*d))/100,864E5<=d&&(this.G=0,Lb(this));if(0>c||this.Jc&&(this.h-=c),c=0;this.qa+=this.ba;this.A+=c;a(b,c)}}}; +function ib(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Lb(a);a.b.v=!0;a.b.Ga=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Kb(a));a.o||a.status("Started");setTimeout(a.Ma,0)}}k.ya=function(){return 0};function R(a){var b=!1;if(a.b.v){Pb(a);kb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Kb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; +function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Ua=b;this.Ka=+a.addrReset||0;this.Va=Sb.bind(this);this.a=V.bind(this);this.ia=null;this.Ja=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Ua);this.b.v&&R(this);this.s=this.K=this.ra=0;this.ja=this.g=this.Aa=this.Ka;this.c=0;this.M=this.mb;this.Y=this.zb;this.ia=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Oa=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[this.s,this.K,this.ra,this.g,this.Aa,this.ja,this.c]);a.set(1,[]);a.set(2,[this.G,this.V,this.b.H]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.s=b.next().value;this.K=b.next().value;this.ra=b.next().value;this.g=b.next().value;this.Aa=b.next().value;this.ja=b.next().value;this.c=b.next().value;b=a[2];this.G=b[0];Lb(this,b[1]);this.b.H=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.zb=function(a,b){var c=this.l;a=this.ja=a;c.a[(a&c.g)>>>c.c].Y(b,a&16383,a)}; +k.ya=function(a){this.b.complete=!0;var b=a?this.b.Ga?0:1:-1;this.b.Ga=!1;this.B=this.D=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.ia||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;this.K=this.K&4194304?this.M(this.s):this.ra=this.M(this.Aa=this.g);this.s=this.K&262143;if(a=this.K>>18&15)this.s=this.s+this.M(a)&Ta;this.K&4194304?a=-1:(this.g=(this.g+1)%Sa,a=this.ra/Va|0);0<=a&&this.Va(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.M(this.s),c=this.M(a);this.Y(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));this.g=(this.g+-1)%Sa;R(this)} var Ub=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,Wb,Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, @@ -106,49 +106,49 @@ function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a) function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.M(a);this.Y(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.W);this.Y(this.W,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.M(a);this.Y(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.s);this.Y(this.s,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; -function Yb(a){u.call(this,"ROM",a);this.J=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.s=xa(this.h);if(this.h){a=this.h;var b=ya(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.C("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(ka(c.ma,a,b),(a=Ea(a,b))?(c.a=a.F,c.J=a.J):c.h=null);Zb(c)})}}n(Yb,u); -Yb.prototype.X=function(a,b,c,d){this.l=b;this.f=c;this.o=d;Zb(this)};Yb.prototype.U=function(){this.J&&(this.o&&this.o.a(this.id,this.j,this.g,this.J),delete this.J);return!0};Yb.prototype.O=function(){return!0}; -function Zb(a){if(!ua(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.C(b)}else{b=a.j;if(rb(a.l,b,a.g,zb)){var c;for(c=0;c>>f.c;0>>f.c;0>>=f.c;0>>a.c;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ta=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ta)for(;ta--;)nb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Ga&&c<=r.Wa&&(b=c-(r.Ga-r.Pa));b&&(a.preventDefault&&a.preventDefault(),d.va(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Ra&&(b=r.Qa);d.va(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.va(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; -k.Oa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.la)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ma+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Oa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.va=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ua=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ua)for(;ua--;)nb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Ha&&c<=r.Xa&&(b=c-(r.Ha-r.Qa));b&&(a.preventDefault&&a.preventDefault(),d.wa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Sa&&(b=r.Ra);d.wa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.wa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; +k.Pa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ma)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.na+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Pa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.wa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bgc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",pc);Z(this.j)&&(qc(this,d),a=rc,sc(this.j));this.j.set(mc,Da());tc(this.j);var e=this.a&&!this.A;if(a==nc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=lc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(uc,""),this.c=null)):this.I(f+": "+g),sc(d),Z(d)?(c=lc(d),e=!0):c=!1))}e&&jc(this,c?d:null)}else a==rc&&d.clear()}else jc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(vc(this,this.f,b,c,a),S(this,-2),this.f.G());this.K&&(qc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +k.fa=function(a){void 0===a&&(a=this.a||(this.B?nc:gc));if(!this.h){this.h++;var b=!1,c=!1;this.J=!1;var d=this.u||new O(this,"1.34.0");if(a==oc)b=!0;else if(a>gc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",pc);Z(this.j)&&(qc(this,d),a=rc,sc(this.j));this.j.set(mc,Da());tc(this.j);var e=this.a&&!this.A;if(a==nc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=lc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(uc,""),this.c=null)):this.I(f+": "+g),sc(d),Z(d)?(c=lc(d),e=!0):c=!1))}e&&jc(this,c?d:null)}else a==rc&&d.clear()}else jc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(vc(this,this.f,b,c,a),S(this,-2),this.f.H());this.J&&(qc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; function qc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function wc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",kc),h=Da();g.set(mc,h);f.set(mc,h);f.set(xc,"1.34.0");f.set(yc,window?window.location.href:null);f.set(zc,window?window.navigator.userAgent:"");a.f&&a.f.O&&(c&&(b&&(a.f.b.G=a.f.b.v),R(a.f)),d=a.f.O(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.ya+=d))&&(e.textContent=c.b.v?c.H.toFixed(2)+"Mhz":"Stopped",c.ya=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0=d||30<=(c.za+=d))&&(e.textContent=c.b.v?c.J.toFixed(2)+"Mhz":"Stopped",c.za=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0/g.exec(a)){var e= "");a=a.replace(d[0],g);Hc(a,b,c)}})}else c(a,null)} function Ic(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Ec||K(!0));p=!1}var h,l,p=!0;Ec++;la[b]={};try{if(h=document.getElementById(b)){var q;if("object"==typeof resources&&(q=resources.css)){var t=document.head||document.getElementsByTagName("head")[0],P=document.createElement("style");P.type="text/css";P.styleSheet?P.styleSheet.cssText=q:P.appendChild(document.createTextNode(q));t.appendChild(P)}d|| (q=a,"pdp"==a.substr(0,3)&&(q="pdpjs"),d="/versions/"+q+"/1.34.0/components.xsl");q=function(e,l){l?Fc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Ec||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Ec|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Fc(c,b,a,e,!0,f,q):Gc(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ta){g(ta.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Ic("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Ic("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Fc(c,b,a,e,!0,f,q):Gc(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ua){g(ua.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Ic("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Ic("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",p=null,q=0;q Date: Sun, 26 Feb 2017 20:37:16 -0800 Subject: [PATCH 17/30] Added support for PDP-10 RAM images --- apps/pdp10/tests/optest.json | 7 + .../deskpro386/1988-01-28/1988-01-28.json | 2 +- .../deskpro386/1988-05-10/1988-05-10.json | 2 +- .../deskpro386/1989-04-14/1989-04-14.json | 2 +- .../rom/compaq/portable/100666-001-REVC.json | 2 +- .../rom/compaq/portable3/1987-01-29.json | 2 +- .../compaq/ega/000412-001B/compaq-ega.json | 2 +- .../compaq/vga/109360-001/1987-10-27.json | 2 +- .../compaq/vga/109360-001/1988-05-18.json | 2 +- .../pcx86/video/paradise/vga/1988-05-23.json | 2 +- .../machine/ka10/test/debugger/machine.xml | 2 +- devices/pdp10/machine/ka10/test/machine.xml | 2 +- modules/filedump/lib/filedump.js | 10 +- modules/pdp10/lib/cpustate.js | 8 +- modules/pdp10/lib/ram.js | 121 ++---- modules/pdp11/lib/ram.js | 8 +- modules/shared/lib/dumpapi.js | 1 + modules/shared/lib/weblib.js | 44 ++- tests/pcx86/80386/test386.json | 4 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 354 +++++++++--------- versions/pdpjs/1.34.0/pdp10.js | 195 +++++----- versions/pdpjs/1.34.0/pdp11-dbg.js | 197 +++++----- versions/pdpjs/1.34.0/pdp11.js | 244 ++++++------ 23 files changed, 583 insertions(+), 632 deletions(-) create mode 100644 apps/pdp10/tests/optest.json diff --git a/apps/pdp10/tests/optest.json b/apps/pdp10/tests/optest.json new file mode 100644 index 000000000..bcae5b502 --- /dev/null +++ b/apps/pdp10/tests/optest.json @@ -0,0 +1,7 @@ +{ + "load": 0o100, + "exec": 0o100, + "data": [ + 0o500000000000 + ] +} diff --git a/devices/pcx86/rom/compaq/deskpro386/1988-01-28/1988-01-28.json b/devices/pcx86/rom/compaq/deskpro386/1988-01-28/1988-01-28.json index bd3348617..40b56acbe 100644 --- a/devices/pcx86/rom/compaq/deskpro386/1988-01-28/1988-01-28.json +++ b/devices/pcx86/rom/compaq/deskpro386/1988-01-28/1988-01-28.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -13436026,-1752439855,1451819088,1611565826,72255744,18119,246465280,-1964227858,263211744,-1007926546,105993040,-1912584008,-1258114624,-402542583,-2147155945,8168192, -38465359,149422512,8299264,1482381575,1431458755,-980627318,4984456,12305806,130491904,-953810944,-64953,-1960379140,-50529249,-75236100,113649152,1946157056, 5021704,350994730,1278097552,422912,-352302058,5021895,-1057046230,-524164046,1532648710,1381061571,180049750,375040,855640255,-2131494958,129380546,9672073, diff --git a/devices/pcx86/rom/compaq/deskpro386/1988-05-10/1988-05-10.json b/devices/pcx86/rom/compaq/deskpro386/1988-05-10/1988-05-10.json index 035837453..a3fab96da 100644 --- a/devices/pcx86/rom/compaq/deskpro386/1988-05-10/1988-05-10.json +++ b/devices/pcx86/rom/compaq/deskpro386/1988-05-10/1988-05-10.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -1100993236,-1959854112,76230196,1947140265,-1876497661,-2145246021,-58670876,-401967808,1480327193,867898229,1921771570,4098094,512241152,1692925953,-1664917134,209500754, -1973295878,-2133526816,1642336484,-533065692,-5179275,-131797778,-2034000550,-771804421,1352109027,39225600,6295179,-956019063,70,-301027133,-527766462,-300961718, 1355017282,-1207545517,-1064435640,162857649,401080752,8389888,-1325368157,-1325550320,583681,117472931,-1017619623,-1974119853,-2000319280,-1912583154,48069,509734, diff --git a/devices/pcx86/rom/compaq/deskpro386/1989-04-14/1989-04-14.json b/devices/pcx86/rom/compaq/deskpro386/1989-04-14/1989-04-14.json index ad09957aa..c26eacce8 100644 --- a/devices/pcx86/rom/compaq/deskpro386/1989-04-14/1989-04-14.json +++ b/devices/pcx86/rom/compaq/deskpro386/1989-04-14/1989-04-14.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -215511036,-1446729497,-970077091,-889074117,-1059597233,0,0,0,4793994,-1023318392,1996700702,2122974813,-402410489,-1957560157,45351510,-1962894616, 920847438,-1962117493,-661778362,1586212092,8290310,1007908353,1007645703,1007383560,1007121418,-1828490227,508662700,4241488,-396830578,1495203869,123392994,-167281014, 1962999878,-402476027,-1977679793,-2013247194,1019412838,1010529287,1010267144,1010005002,-1188072435,162791425,-1275056408,2746371,372949758,343212106,-956378574,1964637824, diff --git a/devices/pcx86/rom/compaq/portable/100666-001-REVC.json b/devices/pcx86/rom/compaq/portable/100666-001-REVC.json index 0f0cd14a9..9fbe9df0b 100644 --- a/devices/pcx86/rom/compaq/portable/100666-001-REVC.json +++ b/devices/pcx86/rom/compaq/portable/100666-001-REVC.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ 1126701261,1866670121,1769109872,544499815,1347243843,1126191425,1970302319,544367988,1886547779,1952543343,745434985,943272224,1092627507,1914727532,1952999273,1701978227, 1987208563,539911269,1179863594,1095651370,1279804202,1246905130,-98557910,1676057008,1642483120,-222688080,-930288125,-1141057394,45998350,-1979600896,11857431,-1979484277, -997588649,-297620242,-2134573494,-227208964,-92268662,1107654104,1257124016,-1912135496,-13433529,-217624693,38242987,163808238,-1329433267,-1337727372,-1337858541,-431888896, diff --git a/devices/pcx86/rom/compaq/portable3/1987-01-29.json b/devices/pcx86/rom/compaq/portable3/1987-01-29.json index 7341df931..264ad5a09 100644 --- a/devices/pcx86/rom/compaq/portable3/1987-01-29.json +++ b/devices/pcx86/rom/compaq/portable3/1987-01-29.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -2065284944,-1912586056,7512536,876380390,-436272523,1102112139,1642366182,270848246,-4595574,610395391,1959016976,-1141448176,414823662,-2143568640,-347608855,-431836967, 536919684,-768348877,855638456,-2147436091,-13385074,-1412378210,-964625438,1926642448,-431771412,207742084,-352261364,610395648,-352261133,-1335761408,-2021333436,-1143852034, -583860223,-628177525,12187187,-741237120,843492511,1979113923,-431640529,-1469979516,1962979520,1189007651,-1314987917,-2133601528,-683994938,-142094222,-1333036467,-1199249850, diff --git a/devices/pcx86/video/compaq/ega/000412-001B/compaq-ega.json b/devices/pcx86/video/compaq/ega/000412-001B/compaq-ega.json index c6c9492b8..001e88bc3 100644 --- a/devices/pcx86/video/compaq/ega/000412-001B/compaq-ega.json +++ b/devices/pcx86/video/compaq/ega/000412-001B/compaq-ega.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -400512427,-1070398658,-990193522,637550622,1976516480,-268387576,1706804110,1112117488,168201293,136218881,1108249601,1074185984,-1945315584,-956269042,1610644486,235834421, 201770753,-1154392063,-611450816,11144844,11011783,113639692,-77594489,-402537752,-1070450007,-398905880,28311742,-805250328,-1327494432,13756418,-536155952,8922760, 254067846,-774337640,-1752486173,-628424485,1947256566,-2029092859,145818112,1963509494,-402345718,-355270472,-754928664,11462890,-1962882072,-754142765,10676458,-1962878488, diff --git a/devices/pcx86/video/compaq/vga/109360-001/1987-10-27.json b/devices/pcx86/video/compaq/vga/109360-001/1987-10-27.json index 7940ba406..17e062609 100644 --- a/devices/pcx86/video/compaq/vga/109360-001/1987-10-27.json +++ b/devices/pcx86/video/compaq/vga/109360-001/1987-10-27.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -399463851,-303561389,46589952,-622263437,-393504768,-661733325,1075758330,1112117248,-2144975539,141938495,-1896873800,-261768256,17434252,17309321,-1912586056,199504600, -2147256851,-726007348,-2147241981,1622347980,-973604425,175374338,-1341934406,46891015,1235418039,-1993963520,-2028042240,-2009167872,1662421248,9168896,1912887528,53471342, -402479640,378143218,-85458871,60418049,8988288,-259286791,-1976640117,-805222980,201815023,72607984,-317997005,-1976695436,-1962848834,436320488,-2048335994,133922902, diff --git a/devices/pcx86/video/compaq/vga/109360-001/1988-05-18.json b/devices/pcx86/video/compaq/vga/109360-001/1988-05-18.json index a150e7f8d..4069208a2 100644 --- a/devices/pcx86/video/compaq/vga/109360-001/1988-05-18.json +++ b/devices/pcx86/video/compaq/vga/109360-001/1988-05-18.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ 820532650,-386632187,-637402904,-371231997,-399310709,-655834994,-388371968,1229063324,-1653387963,-939523095,507574980,-2143354842,146329461,-1900019472,-259212443,25757194, 28843528,-1898430464,200094436,-2134084349,-738000454,-2134069245,1622610099,-989660681,179961972,-1341672445,45580491,1224801186,-1996453850,-2030008290,-2013231042,1660979478, 65595469,-402409726,373883530,184680680,58779831,16328329,-259286901,-1967334098,-789620479,-1949928695,-395244304,-167050189,86961524,1627491006,-1207858194,-538436986, diff --git a/devices/pcx86/video/paradise/vga/1988-05-23.json b/devices/pcx86/video/paradise/vga/1988-05-23.json index 49a0e2d64..0b056b2b1 100644 --- a/devices/pcx86/video/paradise/vga/1988-05-23.json +++ b/devices/pcx86/video/paradise/vga/1988-05-23.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -349132203,808728341,792014896,942617394,942746936,976236602,-1461112784,1112080384,1329799245,1413566541,1162625601,0,0,858796032,758527280,1127559216, 1381584975,1414022985,1380012064,1397310529,1498619973,1296389203,1313415251,824192579,741816377,943208753,1279336492,1230118988,1398032455,1397051936,1163285061,1095194180, 22845,757610496,419831562,101122588,7,1515221248,419831562,101122588,7,757610496,1678147338,66160,0,1380999424,419830031,185401881, diff --git a/devices/pdp10/machine/ka10/test/debugger/machine.xml b/devices/pdp10/machine/ka10/test/debugger/machine.xml index 470a11fec..64045e743 100644 --- a/devices/pdp10/machine/ka10/test/debugger/machine.xml +++ b/devices/pdp10/machine/ka10/test/debugger/machine.xml @@ -4,7 +4,7 @@ PDP-10 Test Machine with Debugger - + diff --git a/devices/pdp10/machine/ka10/test/machine.xml b/devices/pdp10/machine/ka10/test/machine.xml index e62a63d4d..e8a6fe7a0 100644 --- a/devices/pdp10/machine/ka10/test/machine.xml +++ b/devices/pdp10/machine/ka10/test/machine.xml @@ -4,7 +4,7 @@ PDP-10 Test Machine - + diff --git a/modules/filedump/lib/filedump.js b/modules/filedump/lib/filedump.js index c2b0243d7..bcd6a8d15 100644 --- a/modules/filedump/lib/filedump.js +++ b/modules/filedump/lib/filedump.js @@ -46,7 +46,7 @@ var DumpAPI = require("../../shared/lib/dumpapi"); * what the loadFile() function already does. * * @constructor - * @param {string|undefined} sFormat should be one of "json"|"data"|"hex"|"bytes"|"rom" (see the FORMAT constants) + * @param {string|undefined} sFormat should be one of "json"|"longs"|"hex"|"bytes"|"rom" (see the FORMAT constants) * @param {boolean|string|undefined} fComments enables comments and other readability enhancements in the JSON output * @param {boolean|string|undefined} fDecimal forces decimal output if not undefined * @param {number|string|undefined} offDump @@ -82,7 +82,7 @@ function FileDump(sFormat, fComments, fDecimal, offDump, nWidthDump, sServerRoot FileDump.sAPIURL = "http://www.pcjs.org" + DumpAPI.ENDPOINT; FileDump.sCopyright = COPYRIGHT; FileDump.sNotice = FileDump.sAPIURL + " " + FileDump.sCopyright; -FileDump.sUsage = "Usage: " + FileDump.sAPIURL + "?" + DumpAPI.QUERY.FILE + "=({path}|{URL})&" + DumpAPI.QUERY.FORMAT + "=(json|data|hex|octal|bytes|words|rom)"; +FileDump.sUsage = "Usage: " + FileDump.sAPIURL + "?" + DumpAPI.QUERY.FILE + "=({path}|{URL})&" + DumpAPI.QUERY.FORMAT + "=(json|longs|hex|octal|bytes|words|rom)"; FileDump.asBadExts = [ "js", "log" @@ -99,7 +99,7 @@ FileDump.asBadExts = [ * * Usage * --- - * filedump --file=({path}|{URL}) [--merge=({path}|{url})] [--format=(json|data|hex|octal|bytes|words|rom)] + * filedump --file=({path}|{URL}) [--merge=({path}|{url})] [--format=(json|longs|hex|octal|bytes|words|rom)] * [--comments] [--decimal] [--offset={number}] [--width={number}] [--load={number}] [--exec={number}] * [--output={path}] [--overwrite] * @@ -146,7 +146,7 @@ FileDump.CLI = function() var args = proc.getArgs(); if (!args.argc) { - console.log("usage: filedump --file=({path}|{URL}) [--merge=({path}|{url})] [--format=(json|data|hex|octal|bytes|words|rom)] [--comments] [--decimal] [--offset={number}] [--width={number}] [--output={path}] [--overwrite]"); + console.log("usage: filedump --file=({path}|{URL}) [--merge=({path}|{url})] [--format=(json|longs|hex|octal|bytes|words|rom)] [--comments] [--decimal] [--offset={number}] [--width={number}] [--output={path}] [--overwrite]"); return; } @@ -752,7 +752,7 @@ FileDump.prototype.buildJSON = function() else if (this.sFormat == DumpAPI.FORMAT.OCTAL || this.sFormat == DumpAPI.FORMAT.WORDS) { this.json += this.dumpBuffer(this.sFormat, this.buf, this.buf.length, 2); } else { - this.json += this.dumpBuffer("data", this.buf, this.buf.length, 4); + this.json += this.dumpBuffer(DumpAPI.FORMAT.LONGS, this.buf, this.buf.length, 4); } } }; diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index b34e2db87..f94addad5 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -344,10 +344,10 @@ class CPUStatePDP10 extends CPUPDP10 { } /* - * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate the - * "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E to Y, - * then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R to [E] - * and repeat the process. + * Bits 0-22 (I,X,Y) contain what we call a "reference address" (R), which is used to calculate an + * 18-bit "effective address" (E). To determine E from R, we must extract I, X, and Y from R, set E + * to Y, then add [X] to E if X is non-zero. If I is zero, then we're done; otherwise, we must set R + * to [E] and repeat the process. * * However, we don't actually repeat the process immediately; we need to treat each indirection as a * separate decoding step, to ensure that the emulator can "breathe" periodically. So instead, we diff --git a/modules/pdp10/lib/ram.js b/modules/pdp10/lib/ram.js index 226e9e0a3..1bd8efbd3 100644 --- a/modules/pdp10/lib/ram.js +++ b/modules/pdp10/lib/ram.js @@ -59,7 +59,7 @@ class RAMPDP10 extends Component { { super("RAM", parmsRAM); - this.abInit = null; + this.aData = null; this.aSymbols = null; this.addrRAM = +parmsRAM['addr']; @@ -71,7 +71,7 @@ class RAMPDP10 extends Component { if (this.addrExec != null) this.addrExec = +this.addrExec; this.fInstalled = (!!this.sizeRAM); // 0 is the default value for 'size' when none is specified - this.fAllocated = false; + this.fAllocated = this.fReset = false; this.sFilePath = parmsRAM['file']; this.sFileName = Str.getBaseName(this.sFilePath); @@ -180,7 +180,7 @@ class RAMPDP10 extends Component { Component.addMachineResource(this.idMachine, sURL, sData); var resource = Web.parseMemoryResource(sURL, sData); if (resource) { - this.abInit = resource.aBytes; + this.aData = resource.aData; this.aSymbols = resource.aSymbols; if (this.addrLoad == null) this.addrLoad = resource.addrLoad; if (this.addrExec == null) this.addrExec = resource.addrExec; @@ -219,9 +219,9 @@ class RAMPDP10 extends Component { /* * Too early... */ - if (!this.abInit || !this.bus) return; + if (!this.aData) return; - if (this.loadImage(this.abInit, this.addrLoad, this.addrExec, this.addrRAM)) { + if (this.loadImage(this.aData, this.addrLoad, this.addrExec, this.addrRAM)) { this.status('Loaded image "' + this.sFileName + '"'); } else { this.notice('Error loading image "' + this.sFileName + '"'); @@ -230,9 +230,10 @@ class RAMPDP10 extends Component { /* * NOTE: We now retain this data, so that reset() can return the RAM to its predefined state. * - * delete this.abInit; + * delete this.aData; */ } + this.fReset = true; this.setReady(); } } @@ -244,126 +245,46 @@ class RAMPDP10 extends Component { */ reset() { - if (this.fAllocated) { + if (this.fAllocated && !this.fReset) { /* * TODO: Add a configuration parameter for selecting the byte pattern on reset? * Note that when memory blocks are originally created, they are currently always * zero-initialized, so this would only affect resets. */ this.bus.zeroMemory(this.addrRAM, this.sizeRAM, 0); - if (this.abInit) { - this.loadImage(this.abInit, this.addrLoad, this.addrExec, this.addrRAM, !this.dbg); + if (this.aData) { + this.loadImage(this.aData, this.addrLoad, this.addrExec, this.addrRAM, !this.dbg); } } + this.fReset = false; } /** - * loadImage(aBytes, addrLoad, addrExec, addrInit, fStart) + * loadImage(aData, addrLoad, addrExec, addrInit, fStart) * * If the array contains a PAPER tape image in the "Absolute Format," load it as specified * by the format; otherwise, load it as-is using the address(es) supplied. * * @this {RAMPDP10} - * @param {Array|Uint8Array} aBytes + * @param {Array} aData * @param {number|null} [addrLoad] * @param {number|null} [addrExec] (this CAN override any starting address INSIDE the image) * @param {number|null} [addrInit] * @param {boolean} [fStart] * @return {boolean} (true if loaded, false if not) */ - loadImage(aBytes, addrLoad, addrExec, addrInit, fStart) + loadImage(aData, addrLoad, addrExec, addrInit, fStart) { - var fStop = false; var fLoaded = false; - /* - * Data on tapes in the "Absolute Format" is organized into blocks; each block begins with - * a 6-byte header: - * - * 2-byte signature (0x0001) - * 2-byte block length (N + 6, because it includes the 6-byte header) - * 2-byte load address - * - * followed by N data bytes. If N is zero, then the 2-byte load address is the exec address, - * unless the address is odd (usually 1). DEC's Absolute Loader jumps to the exec address - * in former case, halts in the latter. - * - * All values are stored "little endian" (low byte followed by high byte), just like the - * PDP-11's memory architecture. - * - * After the data bytes, there is a single checksum byte. The 8-bit sum of all the bytes in - * the block (including the header bytes and checksum byte) should be zero. - * - * ANOMALIES: Tape files don't always begin with a signature word, so I allow any number of - * leading zeros before the first signature. Tape files don't always end cleanly either, so as - * soon as I see an invalid signature, I break out of the loop without signalling an error, as - * long as at least ONE block was successfully processed. In fact, it's possible that as - * soon as a block with ZERO data bytes is encountered, processing is supposed to stop, but - * I haven't examined enough tapes (or the Absolute Loader code) to know for sure. - */ + if (addrLoad == null) { - var off = 0, fError = false; - while (off < aBytes.length - 1) { - var w = (aBytes[off] & 0xff) | ((aBytes[off+1] & 0xff) << 8); - if (!w) { // ignore pairs of leading zeros - off += 2; - continue; - } - if (!(w & 0xff)) { // as well as single bytes of zero - off++; - continue; - } - var offBlock = off; - if (w != 0x0001) { - this.printMessage("invalid signature (" + Str.toHexWord(w) + ") at offset " + Str.toHexWord(offBlock), MessagesPDP10.PAPER); - break; - } - if (off + 6 >= aBytes.length) { - this.printMessage("invalid block at offset " + Str.toHexWord(offBlock), MessagesPDP10.PAPER); - break; - } - off += 2; - var checksum = w; - var len = (aBytes[off++] & 0xff) | ((aBytes[off++] & 0xff) << 8); - var addr = (aBytes[off++] & 0xff) | ((aBytes[off++] & 0xff) << 8); - checksum += (len & 0xff) + (len >> 8) + (addr & 0xff) + (addr >> 8); - var offData = off, cbData = len -= 6; - while (len > 0 && off < aBytes.length) { - checksum += aBytes[off++] & 0xff; - len--; - } - if (len != 0 || off >= aBytes.length) { - this.printMessage("insufficient data for block at offset " + Str.toHexWord(offBlock), MessagesPDP10.PAPER); - break; - } - checksum += aBytes[off++] & 0xff; - if (checksum & 0xff) { - this.printMessage("invalid checksum (" + Str.toHexByte(checksum) + ") for block at offset " + Str.toHexWord(offBlock), MessagesPDP10.PAPER); - break; - } - if (!cbData) { - if (addr & 0x1) { - fStop = true; - } else { - if (addrExec == null) addrExec = addr; - } - if (addrExec != null) this.printMessage("starting address: " + Str.toHexWord(addrExec), MessagesPDP10.PAPER); - } else { - this.printMessage("loading " + Str.toHexWord(cbData) + " bytes at " + Str.toHexWord(addr) + "-" + Str.toHexWord(addr + cbData), MessagesPDP10.PAPER); - while (cbData--) { - this.bus.setWordDirect(addr++, aBytes[offData++]); - } - } - fLoaded = true; - } + addrLoad = addrInit; } - if (!fLoaded) { - if (addrLoad == null) addrLoad = addrInit; - if (addrLoad != null) { - for (var i = 0; i < aBytes.length; i++) { - this.bus.setWordDirect(addrLoad + i, aBytes[i]); - } - fLoaded = true; + if (addrLoad != null) { + for (var i = 0; i < aData.length; i++) { + this.bus.setWordDirect(addrLoad + i, aData[i]); } + fLoaded = true; } if (fLoaded) { /* @@ -374,7 +295,7 @@ class RAMPDP10 extends Component { * image, but we know that the directions for that diagnostic say to "Start and Restart at 200", * so we have manually inserted an "exec":128 in the JSON containing the image. */ - if (addrExec == null || fStop) { + if (addrExec == null) { this.cpu.stopCPU(); fStart = false; } diff --git a/modules/pdp11/lib/ram.js b/modules/pdp11/lib/ram.js index 4178c4794..327232681 100644 --- a/modules/pdp11/lib/ram.js +++ b/modules/pdp11/lib/ram.js @@ -76,7 +76,7 @@ class RAMPDP11 extends Component { if (this.addrExec != null) this.addrExec = +this.addrExec; this.fInstalled = (!!this.sizeRAM); // 0 is the default value for 'size' when none is specified - this.fAllocated = false; + this.fAllocated = this.fReset = false; this.sFilePath = parmsRAM['file']; this.sFileName = Str.getBaseName(this.sFilePath); @@ -224,7 +224,7 @@ class RAMPDP11 extends Component { /* * Too early... */ - if (!this.abInit || !this.bus) return; + if (!this.abInit) return; if (this.loadImage(this.abInit, this.addrLoad, this.addrExec, this.addrRAM)) { this.status('Loaded image "' + this.sFileName + '"'); @@ -238,6 +238,7 @@ class RAMPDP11 extends Component { * delete this.abInit; */ } + this.fReset = true; this.setReady(); } } @@ -249,7 +250,7 @@ class RAMPDP11 extends Component { */ reset() { - if (this.fAllocated) { + if (this.fAllocated && !this.fReset) { /* * TODO: Add a configuration parameter for selecting the byte pattern on reset? * Note that when memory blocks are originally created, they are currently always @@ -260,6 +261,7 @@ class RAMPDP11 extends Component { this.loadImage(this.abInit, this.addrLoad, this.addrExec, this.addrRAM, !this.dbg); } } + this.fReset = false; } /** diff --git a/modules/shared/lib/dumpapi.js b/modules/shared/lib/dumpapi.js index 1a64ae6eb..67cfbb69c 100644 --- a/modules/shared/lib/dumpapi.js +++ b/modules/shared/lib/dumpapi.js @@ -70,6 +70,7 @@ var DumpAPI = { OCTAL: "octal", // displays data as octal words BYTES: "bytes", // displays data as hex bytes; normally used only when comments are enabled WORDS: "words", // displays data as hex words; normally used only when comments are enabled + LONGS: "longs", // displays data as dwords IMG: "img", // returns the raw disk data (ie, using a Buffer object) (DiskDump only) ROM: "rom" // returns the raw file data (ie, using a Buffer object) (FileDump only) } diff --git a/modules/shared/lib/weblib.js b/modules/shared/lib/weblib.js index 54be9e08d..66c1cb18a 100644 --- a/modules/shared/lib/weblib.js +++ b/modules/shared/lib/weblib.js @@ -268,6 +268,23 @@ class Web { /** * parseMemoryResource(sURL, sData) * + * This converts a variety of JSON-style data streams into an Object with the following properties: + * + * aBytes + * aSymbols + * addrLoad + * addrExec + * + * If the source data contains a 'bytes' array, it's passed through to 'aBytes'; alternatively, if + * it contains a 'words' array, the values are converted from 16-bit to 8-bit and stored in 'aBytes', + * and if it contains a 'longs' array, the values are converted from 32-bit longs into bytes and + * stored in 'aBytes'. + * + * Alternatively, if the source data contains a 'data' array, we simply pass that through to the output + * object as: + * + * aData + * * @param {string} sURL * @param {string} sData * @return {Object|null} (resource) @@ -315,8 +332,8 @@ class Web { * * ["unrecognized disk path: test.img"] */ - if (sData.indexOf("0x") < 0 && sData.substr(0, 2) != "[\"") { - data = JSON.parse(sData.replace(/([a-z]+):/gm, "\"$1\":").replace(/\/\/[^\n]*/gm, "")); + if (sData.indexOf("0x") < 0 && sData.indexOf("0o") < 0 && sData.substr(0, 2) != '["') { + data = JSON.parse(sData.replace(/([a-z]+):/gm, '"$1":').replace(/\/\/[^\n]*/gm, "")); } else { data = eval("(" + sData + ")"); } @@ -338,7 +355,7 @@ class Web { Component.assert(!(a[i] & ~0xffff)); } } - else if (a = data['data']) { + else if (a = data['longs']) { /* * Convert all dwords (longs) into bytes */ @@ -350,20 +367,25 @@ class Web { resource.aBytes[ib++] = (a[i] >> 24) & 0xff; } } + else if (a = data['data']) { + resource.aData = a; + } else { resource.aBytes = data; } + if (resource.aBytes) { + if (!resource.aBytes.length) { + Component.error("Empty resource: " + sURL); + resource = null; + } + else if (resource.aBytes.length == 1) { + Component.error(resource.aBytes[0]); + resource = null; + } + } resource.aSymbols = data['symbols']; - if (!resource.aBytes.length) { - Component.error("Empty resource: " + sURL); - resource = null; - } - else if (resource.aBytes.length == 1) { - Component.error(resource.aBytes[0]); - resource = null; - } } catch (e) { Component.error("Resource data error (" + sURL + "): " + e.message); resource = null; diff --git a/tests/pcx86/80386/test386.json b/tests/pcx86/80386/test386.json index fb4a086d5..5d6d0defa 100644 --- a/tests/pcx86/80386/test386.json +++ b/tests/pcx86/80386/test386.json @@ -1,4 +1,4 @@ -{"data":[ +{"longs":[ -2126857072,112742,-144277504,297297640,1715745570,-1184447607,-2005440939,1726084966,963047927,1602555864,-1898827382,-661887270,264275302,-376811131,-1869578132,-1869574000, -1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000, -1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000, @@ -1019,4 +1019,4 @@ -1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000, -1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000, -1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,-1869574000,65770,1350598896,5458499] -} \ No newline at end of file +} diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 6e3093cec..c319140c4 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -28,199 +28,197 @@ http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ -var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var ea=0;function da(a){return"jscomp_symbol_"+(a||"")+ea++} +var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=fa)}var ga=0;function fa(a){return"jscomp_symbol_"+(a||"")+ga++} function ha(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return ja(function(){return ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var la=Math.pow(2,36),ma=-Math.pow(2,35),q={$b:0,nb:1,bc:2,cc:3,dc:4,ec:5,fc:6,gc:7,Ya:8,hc:9,ob:10,ic:11,jc:12,pb:13,kc:14,lc:15,mc:16,nc:17,oc:18,pc:19,qc:20,rc:21,sc:22,tc:23,uc:24,vc:25,wc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Xa:65,Zb:66,ac:67,xc:68,E:69,yc:70,zc:71,Ac:72,Bc:73,Cc:74,Dc:75,Ec:76,Fc:77,Gc:78,Hc:79,Ic:80,Q:81, -Jc:82,Kc:83,Lc:84,Mc:85,Nc:86,Oc:87,Pc:88,Qc:89,tb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Rc:97,Sc:98,Tc:99,d:100,e:101,Uc:102,Vc:103,Wc:104,Xc:105,Yc:106,k:107,Zc:108,$c:109,n:110,ad:111,p:112,q:113,r:114,bd:115,t:116,dd:117,ed:118,fd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,qb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.bb=b.comment;this.sb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ua:!1,U:!1,error:!1};this.Ma=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.C=this.D=this.ka=null;v.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} -function w(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function x(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b":62,"?":63,"@":64,Ya:65,$b:66,bc:67,yc:68,E:69,zc:70,Ac:71,Bc:72,Cc:73,Dc:74,Ec:75,Fc:76,Gc:77,Hc:78,Ic:79,Jc:80,Q:81, +Kc:82,Lc:83,Mc:84,Nc:85,Oc:86,Pc:87,Qc:88,Rc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Sc:97,Tc:98,Uc:99,d:100,e:101,Vc:102,Wc:103,Xc:104,Yc:105,Zc:106,k:107,$c:108,ad:109,n:110,bd:111,p:112,q:113,r:114,cd:115,t:116,ed:117,fd:118,gd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.j={ready:!1,Fa:!1,Va:!1,U:!1,error:!1};this.Na=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.D=this.C=this.ka=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +function v(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function w(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} -function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function G(a){return F(a,4,!0)}function Sa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Xa[a]})}function Ya(a,b){return(a+" ").slice(0,b)}function Za(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Xa={"&":"&","<":"<",">":">",'"':""","'":"'"}; -function $a(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function jb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, -f,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function kb(a,b){var c,d={W:null,T:null,ja:null,ia:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=g.load;d.ia=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.T=g.symbols;d.W.length?1==d.W.length&&(w(d.W[0]),d=null):(w("Empty resource: "+a),d=null)}catch(h){w("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Fb,a];this.A=this.g=this.C=this.D=null;this.exports={hold:this.xb,toggle:this.Sb,reset:this.Ob, -set:this.Rb};D(this)}p(Pb,t);l=Pb.prototype;l.reset=function(a){this.stop();a&&Rb(this,this.w=0)}; -l.ea=function(a,b,c,d){if(this.D&&this.D.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Sb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Tb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Sb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Tb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ua=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;Ub(this);Vb(this)};l.ma=function(a,b){if(!b)if(this.S&&Wb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Xb(this,this.i=a[0]),Rb(this,this.w=a[1]),Yb(this,a[2]);return!0};l.Ob=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Vb(this);return!0};function Zb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Ub(a,b){for(var c in a.B)Zb(a,c,null!=b?b:a.B[c])}function $b(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Vb(a){for(var b in a.b)$b(a,b,a.b[b][1])} -l.xb=function(a,b,c){if(Sb(this,b)){if(c){var d=this;setTimeout(function(){Tb(d,b);a&&a()},+c);return!1}Tb(this,b)}return!0};l.Rb=function(a,b){if("SR"==a)return Yb(this,Qa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,$b(this,a,c[1]),!0):!1};l.Sb=function(a){return Sb(this,a)?(Tb(this,a),!0):!1};function Sb(a,b){var c=a.b[b];return c?($b(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=ac&&(a.N=b==bc,a.O=b==cc),!0):!1} -function Tb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&($b(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Gb=function(a){a||this.g.j.J||(this.g.i=this.i%Jb,this.b[dc]&&this.b[dc][1]&&ec(this.g))};l.Hb=function(){};l.Bb=function(a){a||this.g.R()}; -l.zb=function(a){if(!a&&!this.g.j.J)if(this.b[dc]&&this.b[dc][1])ec(this.g);else{if((a=this.A)&&!Na(a,!0))Oa(a,!0),fc(a,0,null),Oa(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(m=f);if(h&&h.size){if(h.type==d){if(e+f<=h.v)return h.Ha+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ha){m=h.size-(e-k);m>f&&(m=f);h.Ha=e-h.v+m;e=k+16384;f-=m;g++;continue}}return qc(rc,e,f)}e=new L(a,e,m,16384,d);nc(e,a.A,h);a.b[g++]=e;e=k+16384;f-=m}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+Ic[d]+" at "+Ra(b)),!0):qc(Jc,b,c)} -function lc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function kc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function oc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.fa&&(a.fa+=a.ba,c=!0);0<=a.ga&&a.ga<=dd(a)&&(a.ba=a.ga=-1,$c(a),a.R(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.ra))}} -l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.D)if(a=d.D,a.j.U)a=!0;else{var b=null,c,h=x(a.id);for(c=0;ca.O/a.P?b=1:d=!0;a.S=b;b=a.Qa*a.S;if(a.P!=b){a.P=b;b=a.P.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.D&&hd(a.D)}hc(a,a.F);a.F=0;a.B=va();a.I=0;fd(a);return d}function id(a,b){for(var c=a.H.length-1;0<=c;c--){var d=a.H[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.K-=a.L;a.L=0;b&&(a.K=0);return c} -l.Pb=function(){if(this.j.J){this.ya>=this.Sa&&fd(this,!0);this.ha=0;this.qa=va();if(this.I){var a=this.qa-this.I;a>this.Ra&&(this.B+=a,this.B>this.qa&&(this.B=this.qa))}try{do{var b=id(this,this.j.Da?1:this.ta);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.ha+=b;this.F+=b;ic(this,b);gc(this,b);this.Y-=b;if(0>=this.Y){this.Y+=this.ta;++this.Ta>=ld&&(this.D&&K(this.D,void 0),this.Ta=0);break}}while(this.j.J)}catch(e){this.R();this.D&&this.D.stop(va(),dd(this));Ka(this,e.stack|| -e.message);return}if(this.j.J){a=setTimeout;b=this.eb;this.I=va();var c=this.Ra;this.ha&&(c=Math.round(c*this.ha/this.ta));var c=c-(this.I-this.qa),d=this.I-this.B;d&&(this.O=Math.round(this.F/(10*d))/100,864E5<=d&&(this.M=0,ed(this)));if(0>c||this.Oc&&(this.B-=c),c=0;this.ya+=this.ha;this.I+=c;a(b,c)}}}; -function ec(a,b){if(!La(a))if(a.j.J)a.f(a.toString()+" busy");else{ed(a);a.j.J=!0;a.j.Pa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.D&&(b&&hd(a.D,!0),a.D.start(a.B,dd(a)));a.A||a.status("Started");setTimeout(a.eb,0)}}l.Ia=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){kd(this);hc(this,this.F);this.F=0;this.j.J=!1;if(b=this.G.run)b.textContent="Run";this.D&&this.D.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; -function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.cb=b;this.ab=+a.addrReset||0;this.rb=nd.bind(this);this.b=P.bind(this);this.na=null;this.$a=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.cb);this.j.J&&this.R();this.w=this.N=this.za=0;this.oa=this.i=this.pa=this.ab;this.u=0;this.aa=this.Lb;this.wa=this.Yb;this.na=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.kb=function(){return 0}; -l.save=function(){var a=new J(this);a.set(0,[this.w,this.N,this.za,this.i,this.pa,this.oa,this.u]);a.set(1,[]);a.set(2,[this.M,this.S,this.j.X]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.w=b.next().value;this.N=b.next().value;this.za=b.next().value;this.i=b.next().value;this.pa=b.next().value;this.oa=b.next().value;this.u=b.next().value;b=a[2];this.M=b[0];ed(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].aa(a&16383,a)};l.Yb=function(a,b){var c=this.C;a=this.oa=a;c.b[(a&c.u)>>>c.i].wa(b,a&16383,a)}; -l.Ia=function(a){this.j.complete=!0;var b=this.A?qd(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.K=this.L=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(rd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.na||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&rd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;this.N=this.N&4194304?this.aa(this.w):this.za=this.aa(this.pa=this.i);this.w=this.N&262143;if(a=this.N>>18& -15)this.w=this.w+this.aa(a)&Kb;this.N&4194304?a=-1:(this.i=(this.i+1)%Jb,a=this.za/Ob|0);0<=a&&this.rb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function td(a){this.b(a)}function ud(a){this.b(a)}function vd(a){a&=15;var b=this.aa(this.w),c=this.aa(a);this.wa(a,(c&262143)+(b-(b&262143)))} -function R(a){this.b(a)}function P(a){this.f("undefined opcode: "+Ra(a));pd(this,-1);this.R()} -var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function Pa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} +function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function H(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} +function ib(a,b){var c,d={W:null,T:null,ja:null,ia:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=f.load;d.ia=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else(e=f.data)?d.Aa=e:d.W=f;d.W&&(d.W.length?1==d.W.length&&(v(d.W[0]),d=null):(v("Empty resource: "+a),d=null));d.T=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Tb,reset:this.Pb, +set:this.Sb};E(this)}p(Nb,t);l=Nb.prototype;l.reset=function(a){this.stop();a&&Pb(this,this.w=0)}; +l.ea=function(a,b,c,d){if(this.C&&this.C.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Qb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Rb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Qb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Rb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ua=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Sb(this);Tb(this)};l.ma=function(a,b){if(!b)if(this.S&&Ub(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Vb(this,this.i=a[0]),Pb(this,this.w=a[1]),Wb(this,a[2]);return!0};l.Pb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Tb(this);return!0};function Xb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Sb(a,b){for(var c in a.B)Xb(a,c,null!=b?b:a.B[c])}function Yb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Tb(a){for(var b in a.b)Yb(a,b,a.b[b][1])} +l.yb=function(a,b,c){if(Qb(this,b)){if(c){var d=this;setTimeout(function(){Rb(d,b);a&&a()},+c);return!1}Rb(this,b)}return!0};l.Sb=function(a,b){if("SR"==a)return Wb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Yb(this,a,c[1]),!0):!1};l.Tb=function(a){return Qb(this,a)?(Rb(this,a),!0):!1};function Qb(a,b){var c=a.b[b];return c?(Yb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Zb&&(a.N=b==$b,a.O=b==ac),!0):!1} +function Rb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Yb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.J||(this.g.i=this.i%Hb,this.b[bc]&&this.b[bc][1]&&cc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.R()}; +l.Ab=function(a){if(!a&&!this.g.j.J)if(this.b[bc]&&this.b[bc][1])cc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),dc(a,0,null),Ma(a,!1);else try{var b=this.g.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ia+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ia){m=h.size-(e-k);m>g&&(m=g);h.Ia=e-h.v+m;e=k+16384;g-=m;f++;continue}}return oc(pc,e,g)}e=new M(a,e,m,16384,d);lc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Gc[d]+" at "+Qa(b)),!0):oc(Hc,b,c)} +function jc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function ic(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function mc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.fa&&(a.fa+=a.ba,c=!0);0<=a.ga&&a.ga<=bd(a)&&(a.ba=a.ga=-1,Yc(a),a.R(),c=!0);c&&a.f(bd(a)+" cycles: checksum="+F(a.ra))}} +l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.U)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.O/a.P?b=1:d=!0;a.S=b;b=a.Ra*a.S;if(a.P!=b){a.P=b;b=a.P.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&fd(a.C)}fc(a,a.F);a.F=0;a.B=va();a.I=0;dd(a);return d}function gd(a,b){for(var c=a.H.length-1;0<=c;c--){var d=a.H[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function hd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function id(a,b){var c=a.K-=a.L;a.L=0;b&&(a.K=0);return c} +l.Qb=function(){if(this.j.J){this.ya>=this.Ta&&dd(this,!0);this.ha=0;this.qa=va();if(this.I){var a=this.qa-this.I;a>this.Sa&&(this.B+=a,this.B>this.qa&&(this.B=this.qa))}try{do{var b=gd(this,this.j.Ea?1:this.ta);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=id(this,!0);this.ha+=b;this.F+=b;gc(this,b);ec(this,b);this.Y-=b;if(0>=this.Y){this.Y+=this.ta;++this.Ua>=jd&&(this.C&&K(this.C,void 0),this.Ua=0);break}}while(this.j.J)}catch(e){this.R();this.C&&this.C.stop(va(),bd(this));Ia(this,e.stack|| +e.message);return}if(this.j.J){a=setTimeout;b=this.fb;this.I=va();var c=this.Sa;this.ha&&(c=Math.round(c*this.ha/this.ta));var c=c-(this.I-this.qa),d=this.I-this.B;d&&(this.O=Math.round(this.F/(10*d))/100,864E5<=d&&(this.M=0,cd(this)));if(0>c||this.Oc&&(this.B-=c),c=0;this.ya+=this.ha;this.I+=c;a(b,c)}}}; +function cc(a,b){if(!Ja(a))if(a.j.J)a.f(a.toString()+" busy");else{cd(a);a.j.J=!0;a.j.Qa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&fd(a.C,!0),a.C.start(a.B,bd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){id(this);fc(this,this.F);this.F=0;this.j.J=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),bd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var ed=30,jd=15,Vc=["power","reset"]; +function kd(a){var b=+a.model||1001;Uc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=ld.bind(this);this.b=O.bind(this);this.na=null;this.ab=[];this.j.complete=!1}p(kd,Uc);l=kd.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.J&&this.R();this.w=this.N=this.za=0;this.oa=this.i=this.pa=this.bb;this.u=0;this.aa=this.Mb;this.wa=this.Zb;this.na=null;Xc(this);this.j.error=!1;Uc.prototype.reset.call(this)};l.lb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.w,this.N,this.za,this.i,this.pa,this.oa,this.u]);a.set(1,[]);a.set(2,[this.M,this.S,this.j.X]);a.set(3,md(this));a.set(4,hd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.w=b.next().value;this.N=b.next().value;this.za=b.next().value;this.i=b.next().value;this.pa=b.next().value;this.oa=b.next().value;this.u=b.next().value;b=a[2];this.M=b[0];cd(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].aa(a&16383,a)};l.Zb=function(a,b){var c=this.D;a=this.oa=a;c.b[(a&c.u)>>>c.i].wa(b,a&16383,a)}; +l.Ja=function(a){this.j.complete=!0;var b=this.A?od(this.A)?1:this.j.Qa?-1:0:0,c=a?this.j.Qa?0:1:-1;this.j.Qa=!1;this.K=this.L=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(pd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.na||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&pd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;this.N=this.N&4194304?this.aa(this.w):this.za=this.aa(this.pa=this.i);this.w=this.N&262143;if(a=this.N>>18& +15)this.w=this.w+this.aa(a)&Ib;this.N&4194304?a=-1:(this.i=(this.i+1)%Hb,a=this.za/Mb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function rd(a){this.b(a)}function sd(a){this.b(a)}function td(a){a&=15;var b=this.aa(this.w),c=this.aa(a);this.wa(a,(c&262143)+(b-(b&262143)))} +function W(a){this.b(a)}function O(a){this.f("undefined opcode: "+Qa(a));nd(this,-1);this.R()} +var qd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,ud,ud,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},rd,sd,sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},rd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,function(a){a&=15;var b=this.aa(a);this.wa(a,b&262143)},function(a){a=this.aa(a&15);var b=this.aa(this.w);this.wa(this.w,(b&262143)+(a-(a&262143)))},function(a){a&15&&vd.call(this, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){a&=15;var b=this.aa(a);this.wa(a,b&262143)},function(a){a=this.aa(a&15);var b=this.aa(this.w);this.wa(this.w,(b&262143)+(a-(a&262143)))},function(a){a&15&&td.call(this, a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; -function wd(a){t.call(this,"ROM",a,128);this.T=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.F=Sa(this.w);if(this.w){a=this.w;var b=Ta(this.F);"json"!=b&&"hex"!=b&&(a=Va()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;jb(a,null,!0,function(a,b,f){f?(c.Z("Unable to load ROM resource (error "+f+": "+a+")"),c.w=null):(ta(c.Ka,a,b),(a=kb(a,b))?(c.b=a.W,c.T=a.T):c.w=null);xd(c)})}}p(wd,t); -wd.prototype.ua=function(a,b,c,d){this.C=b;this.g=c;this.A=d;xd(this)};wd.prototype.ma=function(){this.T&&(this.A&&yd(this.A,this.id,this.B,this.u,this.T),delete this.T);return!0};wd.prototype.da=function(){return!0}; -function xd(a){if(!Ma(a)){if(a.w){if(!a.b||!a.C)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ka(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.C,b,a.u,Nc)){var c;for(c=0;c>>f.i;0>>= -f.i;0>>a.i;0g&&g>=ma&&(g+=la);g=Math.trunc(Math.abs(g))%la;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length){E(a,"invalid block at offset "+G(n),4096);break}for(var k=k+2,r=b[k++]&255|(b[k++]&255)<<8,u=b[k++]&255|(b[k++]&255)<<8,m=m+((r&255)+(r>>8)+(u&255)+(u>>8)),N=k,Da=r-=6;0=b.length){E(a,"insufficient data for block at offset "+G(n),4096);break}m+= -b[k++]&255;if(m&255){E(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+G(n),4096);break}if(Da)for(E(a,"loading "+G(Da)+" bytes at "+G(u)+"-"+G(u+Da),4096);Da--;)kc(a.C,u++,b[N++]);else u&1?g=!0:null==d&&(d=u),null!=d&&E(a,"starting address: "+G(d),4096);h=!0}else k++;else k+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=q.Xa&&c<=q.tb&&(b=c-(q.Xa-q.nb));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.pb&&(b=q.ob);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ua=function(a,b,c,d){this.D=a;this.C=b;this.g=c;this.A=d;D(this)}; -l.mb=function(a){if(!this.b){var b=Yc(this.D,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Ja)return;c=Za(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.ma=function(a,b){if(!b)if(this.mb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} -function Gd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; -case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Hd(a,b,c){var d;if(b){b=Id(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,N--;g=r+g;d>>=8}d=F(c,0,!0)+" "+c+". "+Ra(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Md(a,b){if(b)return Ld(a,b,a.Y[b]);var c=0;for(b in a.Y)Ld(a,b,a.Y[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Kd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Nd(a){Ed.call(this,a);this.xa=!1;this.na=!0;this.I=T();this.ta=T();this.N=T();this.H=[];this.b=this.K=this.F=[];Od(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Pd(this);this.A=this;this.oa={};this.V=this.hb=0;this.S=null;this.M=[];Qd(this,a.messages);this.sa=a.commands;this.L=0;this.Ca=this.ra=null;this.B=this.za=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return cd(b,a)}):void 0===global[B]&&(global[B]=function(a){return cd(b, -a)})}p(Nd,Ed);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function T(a,b,c){return{v:void 0===a?null:a,vb:void 0===b?!1:b,la:!1,ca:c}}function Rd(a){return[a.v,a.vb,a.ca,a.la,a.Oa]}function Sd(a,b){var c=T(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.fb=Fd(a,c.Oa=b[4]));return c}l=Nd.prototype; -l.ua=function(a,b,c,d){this.C=b;this.D=a;this.g=c;this.fa=a.u;(a=Yc(a,"messages"))&&Qd(this,a);Td(this,function(a){a:{var b=d.C.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.C.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Ic[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.pa==b&&(b=pd(a.g,1)));if(0d&&(d=a.g.aa(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} -function Ie(a,b,c,d){var e=T(b.v),f=a.Ba(b,1),g,h,k,m=0,n=f/Mb|0,r;for(r in Je)if(g=Je[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ke;m=n&3;break;case 32256:k=Le;m=n&7;break;case 29248:k=Me,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&g>Ne&&(k="B");k=Oe[g||0]+k;k=Ya(k,8);g?(k=28700==h?k+M(a,f/Nb&127,-1):k+M(a,f>>23&15,-1),k+=",",f&4194304&&(k+="@"),k+=M(a,f&262143,-1),(f=f>>18&15)&&(k+="("+M(a,f,-1)+")")):k+=Vd(f);f=k;g="";h=M(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Ba(e,1),g+=" "+Vd(k),null== -e.v)break;while(e.v!=b.v)}h+=Ya(g,16)+f;c&&(h=Ya(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.ra)):h+(null!=d?"="+d.toString():""));return h}function Od(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.pa=0;a.ha=0} -l.Aa=function(a,b,c){var d=!0;c||Pe(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+M(this,b.v)),d=!1;else{var f=this.C;f.b[e>>>f.i].Aa(e&16383,a==this.F)}}d&&(a.push(b),c?b.la=!0:(Qe(this,a,a.length-1,"set"),Pd(this)));return d};function Pe(a,b,c,d,e){var f=!1;c=Y(c);for(var g=1;g>>d.i],b==a.F));h.la||Pd(a);break}}return f} -function Re(a,b){for(var c=1;cb[0]?1:a[0]>>0,g],r=$a(n,k,a.ib);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({cd:b,v:c,yb:d,T:e,gb:f})} -function Ue(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=f.yb;if(e>=g&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(g=h[3],f=null);f=Ie(a,b,g,f);a.f(f);a.I=b;e-=b.v-k;c++}}} -function Se(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ee+b):(a.O&&(a.f("ended assemble at "+M(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.S=null;if(Ma(a)&&0n||"z"V.length&&(a.f("note: only "+V.length+" available"),O=V.length);S-=O;0>S&&(null==V[V.length-1].v?(O=S+O,S=0):S+=V.length);var wc=[];"call"==ge&&(bb=1E5,wc=["CALL"]);for(void 0!==fe&&a.f(O+" instructions earlier:");0=V.length&&(S=0);a.qa=O;ie++;bb--}}ie||(a.f("no "+he+"history available"), -a.qa=void 0)}else{var oa=Z(a,U);if(oa){var pa=0,le="ds"==Ha;if(fa){if("l"==fa.charAt(0))fa=fa.substr(1)||Cf,pa=Jd(a,fa);else{var me=Z(a,fa);me&&(pa=me.v-oa.v)}0>pa&&(pa=0);65536qe;qe++)oe+=String.fromCharCode((Eb%64|0)+32), -Eb/=64}qa&&(qa+="\n");qa=le?qa+(ra+","):qa+(U+": "+ra+(0>pe?" "+oe:""))}qa&&a.f(qa);a.ta=oa;a.ca=Ef}}}}break;case "e":if("else"==g[0])break;var re,se,te=g[0],zc=g[1];"e"==te||"ew"==te?(re=a.Ba,se=a.Za):zc=null;if(null==zc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Fb=Z(a,zc);if(Fb)for(var Gb=2;GbDc;){for(var sa=null,If=256;65536>eb.v>>>0;){Ec.v=a.Ba(eb,2);if(null==eb.v||!If--)break;if(!(Ec.v&1)){for(var Jf=a,Hb=Ec,ve=null,fb=Hb.v,we=fb,Fc=1;6>=Fc&&fb;Fc++){if(2> ";vb(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bff){if(gf(d,this.K)){this.B=new J(this,"1.34.0",qf);gf(this.B)&&(rf(this,d),a=sf,tf(this.B));this.B.set(nf,ab());uf(this.B);var e=this.b&&!this.I;if(a==of||wa("Click OK to restore the previous "+Db+" machine state, or CANCEL to reset the machine.")){if(c=mf(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gf(d,g):("error"==f&&"no machine state"!= -g?(this.Z("Error: "+g),"unable to verify user"==g&&(ob(vf,""),this.i=null)):this.f(f+": "+g),tf(d),gf(d)?(c=mf(d),e=!0):c=!1))}e&&kf(this,c?d:null)}else a==sf&&d.clear()}else kf(this);delete this.K;delete this.H}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.j.U=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(wf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(rf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function rf(a,b){if(wa("There may be a problem with your "+Db+" machine.\n\nTo help us diagnose it, click OK to send this "+Db+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Db;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} -function $e(a,b,c){var d,e="none";if(a.w)return null;a.w--;var f=new J(a,"1.34.0"),g=new J(a,"1.34.0",lf),h=ab();g.set(nf,h);f.set(nf,h);f.set(xf,"1.34.0");f.set(yf,window?window.location.href:null);f.set(zf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&f.set(a.g.id,d),c&&(a.g.j.U=!1,!1===d&&(e=null)));for(var h=x(a.id),k=0;k=d||30<=(c.Ca+=d))&&(e.textContent=c.j.J?c.O.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.G.PC){var f=a.A&&a.A.ca||8,e=e||0,e=8==f?Ra(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){g=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Uf(a,b,c)}})}else c(a,null)} -function Vf(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Wa(a))}function g(a){f("Error: "+a);m&&(--Rf||zb(!0));m=!1}var h,k,m=!0;Rf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css";u.styleSheet?u.styleSheet.cssText=n:u.appendChild(document.createTextNode(n));r.appendChild(u)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Sf(d,null,a,null,!1,f,function(a,e){e?(ta(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Rf||zb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Rf|| -zb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Sf(c,b,a,e,!0,f,n):Tf(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(N){g(N.message)}return m}window.embedPDP10=function(a,b,c,d){zb(!1);return Vf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){zb(!1);return Vf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Aa[a]){for(var c=!0,d=Aa,e=a,f=b.length,g=[],h=[],k="",m=null,n=0;n>>g.i;0>>= +g.i;0>>a.i;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Oa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Oa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ua=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; +l.nb=function(a){if(!this.b){var b=Wc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ka)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.ma=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Oa=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} +function Ed(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function Fd(a,b,c){var d;if(b){b=Gd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,R--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Kd(a,b){if(b)return Jd(a,b,a.Y[b]);var c=0;for(b in a.Y)Jd(a,b,a.Y[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Id={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Ld(a){Cd.call(this,a);this.xa=!1;this.na=!0;this.I=X();this.ta=X();this.N=X();this.H=[];this.b=this.K=this.F=[];Md(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Nd(this);this.A=this;this.oa={};this.V=this.ib=0;this.S=null;this.M=[];Od(this,a.messages);this.sa=a.commands;this.L=0;this.Da=this.ra=null;this.B=this.za=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return ad(b,a)}):void 0===global[C]&&(global[C]=function(a){return ad(b, +a)})}p(Ld,Cd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,wb:void 0===b?!1:b,la:!1,ca:c}}function Pd(a){return[a.v,a.wb,a.ca,a.la,a.Pa]}function Qd(a,b){var c=X(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.gb=Dd(a,c.Pa=b[4]));return c}l=Ld.prototype; +l.ua=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.fa=a.u;(a=Wc(a,"messages"))&&Od(this,a);Rd(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Gc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.pa==b&&(b=nd(a.g,1)));if(0d&&(d=a.g.aa(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} +function Ge(a,b,c,d){var e=X(b.v),g=a.Ca(b,1),f,h,k,m=0,n=g/Kb|0,r;for(r in He)if(f=He[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ie;m=n&3;break;case 32256:k=Je;m=n&7;break;case 29248:k=Ke,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Le&&(k="B");k=Me[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Lb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=Td(g);g=k;f="";h=N(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Ca(e,1),f+=" "+Td(k),null== +e.v)break;while(e.v!=b.v)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Ea?h+("cycles="+bd(a.g).toString()+" cs="+F(a.g.ra)):h+(null!=d?"="+d.toString():""));return h}function Md(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.pa=0;a.ha=0} +l.Ba=function(a,b,c){var d=!0;c||Ne(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.v)),d=!1;else{var g=this.D;g.b[e>>>g.i].Ba(e&16383,a==this.F)}}d&&(a.push(b),c?b.la=!0:(Oe(this,a,a.length-1,"set"),Nd(this)));return d};function Ne(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.F));h.la||Nd(a);break}}return g} +function Pe(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=gb(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({dd:b,v:c,zb:d,T:e,hb:g})} +function Se(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ge(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} +function Qe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ce+b):(a.O&&(a.f("ended assemble at "+N(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.S=null;if(Ka(a)&&0n||"z"T.length&&(a.f("note: only "+T.length+" available"),L=T.length);P-=L;0>P&&(null==T[T.length-1].v?(L=P+L,P=0):P+=T.length);var uc=[];"call"==ee&&(Za=1E5,uc=["CALL"]);for(void 0!==de&&a.f(L+" instructions earlier:");0=T.length&&(P=0);a.qa=L;ge++;Za--}}ge||(a.f("no "+fe+"history available"), +a.qa=void 0)}else{var ma=Z(a,S);if(ma){var na=0,je="ds"==Fa;if(da){if("l"==da.charAt(0))da=da.substr(1)||Bf,na=Hd(a,da);else{var ke=Z(a,da);ke&&(na=ke.v-ma.v)}0>na&&(na=0);65536oe;oe++)me+=String.fromCharCode((Cb%64|0)+32), +Cb/=64}oa&&(oa+="\n");oa=je?oa+(pa+","):oa+(S+": "+pa+(0>ne?" "+me:""))}oa&&a.f(oa);a.ta=ma;a.ca=Df}}}}break;case "e":if("else"==f[0])break;var pe,qe,re=f[0],xc=f[1];"e"==re||"ew"==re?(pe=a.Ca,qe=a.$a):xc=null;if(null==xc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Db=Z(a,xc);if(Db)for(var Eb=2;EbBc;){for(var qa=null,Hf=256;65536>bb.v>>>0;){Cc.v=a.Ca(bb,2);if(null==bb.v||!Hf--)break;if(!(Cc.v&1)){for(var If=a,Fb=Cc,te=null,cb=Fb.v,ue=cb,Dc=1;6>=Dc&&cb;Dc++){if(2> ";tb(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bdf){if(ef(d,this.K)){this.B=new J(this,"1.34.0",of);ef(this.B)&&(pf(this,d),a=qf,rf(this.B));this.B.set(lf,hb());sf(this.B);var e=this.b&&!this.I;if(a==mf||wa("Click OK to restore the previous "+Bb+" machine state, or CANCEL to reset the machine.")){if(c=kf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?ef(d,f):("error"==g&&"no machine state"!= +f?(this.Z("Error: "+f),"unable to verify user"==f&&(mb(tf,""),this.i=null)):this.f(g+": "+f),rf(d),ef(d)?(c=kf(d),e=!0):c=!1))}e&&hf(this,c?d:null)}else a==qf&&d.clear()}else hf(this);delete this.K;delete this.H}e=w(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.j.U=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(uf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(pf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; +function pf(a,b){if(wa("There may be a problem with your "+Bb+" machine.\n\nTo help us diagnose it, click OK to send this "+Bb+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Bb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function Ye(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new J(a,"1.34.0"),f=new J(a,"1.34.0",jf),h=hb();f.set(lf,h);g.set(lf,h);g.set(vf,"1.34.0");g.set(wf,window?window.location.href:null);g.set(xf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.U=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Da+=d))&&(e.textContent=c.j.J?c.O.toFixed(2)+"Mhz":"Stopped",c.Da=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.G.PC){var g=a.A&&a.A.ca||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);Tf(a,b,c)}})}else c(a,null)} +function Uf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Qf||xb(!0));m=!1}var h,k,m=!0;Qf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Rf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Qf||xb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Qf|| +xb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Rf(c,b,a,e,!0,g,n):Sf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(R){f(R.message)}return m}window.embedPDP10=function(a,b,c,d){xb(!1);return Uf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){xb(!1);return Uf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ia=Math.pow(2,36),ja=-Math.pow(2,35),r={Bb:0,Qa:1,Db:2,Eb:3,Fb:4,Gb:5,Hb:6,Ib:7,Ia:8,Jb:9,Ra:10,Kb:11,Lb:12,Sa:13,Mb:14,Nb:15,Ob:16,Pb:17,Qb:18,Rb:19,Sb:20,Tb:21,Ub:22,Vb:23,Wb:24,Xb:25,Yb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ha:65,Ab:66,Cb:67,Zb:68,E:69,$b:70,ac:71,bc:72,cc:73,dc:74,ec:75,fc:76,gc:77,hc:78,ic:79,jc:80,Q:81, -kc:82,lc:83,mc:84,nc:85,oc:86,pc:87,qc:88,rc:89,Xa:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,sc:97,tc:98,uc:99,d:100,e:101,vc:102,wc:103,xc:104,yc:105,zc:106,k:107,Ac:108,Bc:109,n:110,Cc:111,p:112,q:113,r:114,Dc:115,t:116,Ec:117,Fc:118,Gc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ta:127}; -function u(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.La=b.comment;this.Wa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.ma=this.id:(this.na=this.id.substr(0,a),this.ma=this.id.substr(a+1));this.b={ready:!1,sa:!1,Fa:!1,w:!1,error:!1};this.va=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.aa=null;v.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function w(){return Date.now()||+new Date} -function x(a){window&&window.alert(a)}function ma(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?-b:b}});ia("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var ja=Math.pow(2,36),ka=-Math.pow(2,35),q={Cb:0,Ra:1,Eb:2,Fb:3,Gb:4,Hb:5,Ib:6,Jb:7,Ja:8,Kb:9,Sa:10,Lb:11,Mb:12,Ta:13,Nb:14,Ob:15,Pb:16,Qb:17,Rb:18,Sb:19,Tb:20,Ub:21,Vb:22,Wb:23,Xb:24,Yb:25,Zb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,Bb:66,Db:67,$b:68,E:69,ac:70,bc:71,cc:72,dc:73,ec:74,fc:75,gc:76,hc:77,ic:78,jc:79,kc:80,Q:81, +lc:82,mc:83,nc:84,oc:85,pc:86,qc:87,rc:88,sc:89,Ya:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,tc:97,uc:98,vc:99,d:100,e:101,wc:102,xc:103,yc:104,zc:105,Ac:106,k:107,Bc:108,Cc:109,n:110,Dc:111,p:112,q:113,r:114,Ec:115,t:116,Fc:117,Gc:118,Hc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ua:127}; +function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.na=this.id:(this.oa=this.id.substr(0,a),this.na=this.id.substr(a+1));this.b={ready:!1,ta:!1,Ga:!1,w:!1,error:!1};this.wa=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} +function x(a){window&&window.alert(a)}function na(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return""+c}function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d} @@ -52,53 +52,53 @@ function xa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf( function Da(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",p;for(p in b)b.hasOwnProperty(p)&&(l&&(l+="&"),l+=p+"="+encodeURIComponent(b[p]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={F:null,L:null,S:null,R:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else d.F=g;d.L=g.symbols;d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null)}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else(e=g.data)?d.X=e:d.F=g;d.F&&(d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null));d.L=g.symbols}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.gb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.Za,toggle:this.tb,reset:this.pb, -set:this.sb};E(this)}n(Wa,u);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; +function Wa(a,b){t.call(this,"Panel",a);this.A=this.B=0;this.P=b;this.c=this.u=this.g=this.h=0;this.D=this.G=-1;this.J=this.K=this.s=!1;this.N=Xa;this.j={};this.a={START:[1,1,!0,!1,this.ib],STEP:[1,1,!1,!1,this.jb],ENABLE:[1,1,!1,!1,this.cb],CONT:[1,1,!0,!1,this.ab],DEP:[0,0,!0,!1,this.bb],EXAM:[1,1,!0,!1,this.eb],LOAD:[1,1,!0,!1,this.gb],TEST:[0,0,!0,!1,this.fb]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.$a,toggle:this.ub,reset:this.qb, +set:this.tb};E(this)}n(Wa,t);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; k.T=function(a,b,c,d){if(this.m&&this.m.T(a,b,c,d)||this.f&&this.f.T(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):u.prototype.T.call(this,a,b,c,d)}};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Za(this);$a(this)};k.U=function(a,b){if(!b)if(this.P&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.O=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),M(this,this.h=a[1]),bb(this,a[2]);return!0};k.pb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} -k.Za=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; -k.sb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.fb=function(a){a||this.f.b.v||Q(this,this.g)};k.eb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.gb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Z)return h.xa+=h.Z-e,h.Z=e,!0;if(e>=h.Z+h.xa){p=h.size-(e-l);p>f&&(p=f);h.xa=e-h.Z+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} -function qb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.P&&(a.P+=a.ca,c=!0);0<=a.da&&a.da<=Kb(a)&&(a.ca=a.da=-1,Jb(a),R(a),c=!0);c&&a.I(Kb(a)+" cycles: checksum="+F(a.oa))}} -k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.J/a.N&&(b=1);a.V=b;b=a.Ba*a.V;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.aa&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.aa.focus(),window&&window.scrollTo(b,d)))}kb(a,a.j);a.j=0;a.h=w();a.A=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.B-=a.D;a.D=0;b&&(a.B=0);return c} -k.qb=function(){if(this.b.v){this.qa>=this.Da&&Mb(this,!0);this.ba=0;this.ka=w();if(this.A){var a=this.ka-this.A;a>this.Ca&&(this.h+=a,this.h>this.ka&&(this.h=this.ka))}try{do{for(var b,c=this.b.ta?1:this.ea,d=this.u.length-1;0<=d;d--){var e=this.u[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.ya(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.ba+=b;this.j+=b;lb(this,b);jb(this,b);this.W-=b;if(0>=this.W){this.W+=this.ea;++this.Ea>=Qb&&(this.m&&S(this.m,void 0),this.Ea=0);break}}while(this.b.v)}catch(f){R(this); -this.m&&this.m.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Ma;this.A=w();c=this.Ca;this.ba&&(c=Math.round(c*this.ba/this.ea));c-=this.A-this.ka;if(d=this.A-this.h)this.J=Math.round(this.j/(10*d))/100,864E5<=d&&(this.G=0,Lb(this));if(0>c||this.Jc&&(this.h-=c),c=0;this.qa+=this.ba;this.A+=c;a(b,c)}}}; -function ib(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Lb(a);a.b.v=!0;a.b.Ga=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Kb(a));a.o||a.status("Started");setTimeout(a.Ma,0)}}k.ya=function(){return 0};function R(a){var b=!1;if(a.b.v){Pb(a);kb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Kb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; -function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Ua=b;this.Ka=+a.addrReset||0;this.Va=Sb.bind(this);this.a=V.bind(this);this.ia=null;this.Ja=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Ua);this.b.v&&R(this);this.s=this.K=this.ra=0;this.ja=this.g=this.Aa=this.Ka;this.c=0;this.M=this.mb;this.Y=this.zb;this.ia=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Oa=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[this.s,this.K,this.ra,this.g,this.Aa,this.ja,this.c]);a.set(1,[]);a.set(2,[this.G,this.V,this.b.H]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.s=b.next().value;this.K=b.next().value;this.ra=b.next().value;this.g=b.next().value;this.Aa=b.next().value;this.ja=b.next().value;this.c=b.next().value;b=a[2];this.G=b[0];Lb(this,b[1]);this.b.H=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.zb=function(a,b){var c=this.l;a=this.ja=a;c.a[(a&c.g)>>>c.c].Y(b,a&16383,a)}; -k.ya=function(a){this.b.complete=!0;var b=a?this.b.Ga?0:1:-1;this.b.Ga=!1;this.B=this.D=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.ia||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;this.K=this.K&4194304?this.M(this.s):this.ra=this.M(this.Aa=this.g);this.s=this.K&262143;if(a=this.K>>18&15)this.s=this.s+this.M(a)&Ta;this.K&4194304?a=-1:(this.g=(this.g+1)%Sa,a=this.ra/Va|0);0<=a&&this.Va(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.M(this.s),c=this.M(a);this.Y(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));this.g=(this.g+-1)%Sa;R(this)} -var Ub=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):t.prototype.T.call(this,a,b,c,d)}};k.Y=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Za(this);$a(this)};k.U=function(a,b){if(!b)if(this.P&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.O=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])P(this,this.c=a[0]),M(this,this.h=a[1]),bb(this,a[2]);return!0};k.qb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} +k.$a=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; +k.tb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.gb=function(a){a||this.f.b.v||P(this,this.g)};k.fb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.ya+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.ya){p=h.size-(e-l);p>f&&(p=f);h.ya=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return rb(sb,e,f)}e=new T(a,e,p,16384,d);ob(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+tb[d]+" at "+wa(b)),!0):rb(ub,b,c)}function mb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function pb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.P&&(a.P+=a.da,c=!0);0<=a.ea&&a.ea<=Jb(a)&&(a.da=a.ea=-1,Ib(a),R(a),c=!0);c&&a.I(Jb(a)+" cycles: checksum="+F(a.pa))}} +k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.J/a.N&&(b=1);a.V=b;b=a.Ca*a.V;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}jb(a,a.j);a.j=0;a.h=w();a.A=0;Lb(a)}function Nb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Ob(a,b){var c=a.B-=a.D;a.D=0;b&&(a.B=0);return c} +k.rb=function(){if(this.b.v){this.ra>=this.Ea&&Lb(this,!0);this.ca=0;this.la=w();if(this.A){var a=this.la-this.A;a>this.Da&&(this.h+=a,this.h>this.la&&(this.h=this.la))}try{do{for(var b,c=this.b.ua?1:this.fa,d=this.u.length-1;0<=d;d--){var e=this.u[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.za(b)}catch(f){if("number"!=typeof f)throw f;}b=Ob(this,!0);this.ca+=b;this.j+=b;kb(this,b);ib(this,b);this.W-=b;if(0>=this.W){this.W+=this.fa;++this.Fa>=Pb&&(this.m&&S(this.m,void 0),this.Fa=0);break}}while(this.b.v)}catch(f){R(this); +this.m&&this.m.stop(w(),Jb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Na;this.A=w();c=this.Da;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.A-this.la;if(d=this.A-this.h)this.J=Math.round(this.j/(10*d))/100,864E5<=d&&(this.G=0,Kb(this));if(0>c||this.Jc&&(this.h-=c),c=0;this.ra+=this.ca;this.A+=c;a(b,c)}}}; +function Q(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Kb(a);a.b.v=!0;a.b.Ha=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Jb(a));a.o||a.status("Started");setTimeout(a.Na,0)}}k.za=function(){return 0};function R(a){var b=!1;if(a.b.v){Ob(a);jb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Jb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Mb=30,Pb=15,Gb=["power","reset"]; +function Qb(a){var b=+a.model||1001;Fb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Rb.bind(this);this.a=V.bind(this);this.ja=null;this.Ka=[];this.b.complete=!1}n(Qb,Fb);k=Qb.prototype;k.reset=function(){this.status("Model "+this.Va);this.b.v&&R(this);this.s=this.K=this.sa=0;this.ka=this.g=this.Ba=this.La;this.c=0;this.M=this.nb;this.Z=this.Ab;this.ja=null;Hb(this);this.b.error=!1;Fb.prototype.reset.call(this)};k.Pa=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[this.s,this.K,this.sa,this.g,this.Ba,this.ka,this.c]);a.set(1,[]);a.set(2,[this.G,this.V,this.b.H]);a.set(3,Sb(this));a.set(4,Nb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.s=b.next().value;this.K=b.next().value;this.sa=b.next().value;this.g=b.next().value;this.Ba=b.next().value;this.ka=b.next().value;this.c=b.next().value;b=a[2];this.G=b[0];Kb(this,b[1]);this.b.H=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.Ab=function(a,b){var c=this.l;a=this.ka=a;c.a[(a&c.g)>>>c.c].Z(b,a&16383,a)}; +k.za=function(a){this.b.complete=!0;var b=a?this.b.Ha?0:1:-1;this.b.Ha=!1;this.B=this.D=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.ja||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;this.K=this.K&4194304?this.M(this.s):this.sa=this.M(this.Ba=this.g);this.s=this.K&262143;if(a=this.K>>18&15)this.s=this.s+this.M(a)&Ta;this.K&4194304?a=-1:(this.g=(this.g+1)%Sa,a=this.sa/Va|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Ub(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){a&=15;var b=this.M(this.s),c=this.M(a);this.Z(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));this.g=(this.g+-1)%Sa;R(this)} +var Tb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,Wb,Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Ub,Vb,Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Ub,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, @@ -106,57 +106,56 @@ function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a) function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.M(a);this.Y(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.s);this.Y(this.s,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Wb,function(a){a&=15;var b=this.M(a);this.Z(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.s);this.Z(this.s,(b&262143)+(a-(a&262143)))},function(a){a&15&&Wb.call(this,a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; -function Yb(a){u.call(this,"ROM",a);this.L=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.s=xa(this.h);if(this.h){a=this.h;var b=ya(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.C("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(ka(c.na,a,b),(a=Ea(a,b))?(c.a=a.F,c.L=a.L):c.h=null);Zb(c)})}}n(Yb,u); -Yb.prototype.X=function(a,b,c,d){this.l=b;this.f=c;this.o=d;Zb(this)};Yb.prototype.U=function(){this.L&&(this.o&&this.o.a(this.id,this.j,this.g,this.L),delete this.L);return!0};Yb.prototype.O=function(){return!0}; -function Zb(a){if(!ta(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.C(b)}else{b=a.j;if(rb(a.l,b,a.g,zb)){var c;for(c=0;c>>f.c;0>>=f.c;0>>a.c;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,p=p+((q&255)+(q>>8)+(t&255)+(t>>8)),P=l,ua=q-=6;0=b.length)break;p+=b[l++]&255;if(p&255)break;if(ua)for(;ua--;)nb(a.l,t++,b[P++]);else t&1?g=!0:null==d&&(d=t);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(h=0;h=r.Ha&&c<=r.Xa&&(b=c-(r.Ha-r.Qa));b&&(a.preventDefault&&a.preventDefault(),d.wa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==r.Sa&&(b=r.Ra);d.wa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.wa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.X=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; -k.Pa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.ma)return;c=Ca(c[1]);if(this.a=na(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.na+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Pa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.wa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bgc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",pc);Z(this.j)&&(qc(this,d),a=rc,sc(this.j));this.j.set(mc,Da());tc(this.j);var e=this.a&&!this.A;if(a==nc||ma("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=lc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(uc,""),this.c=null)):this.I(f+": "+g),sc(d),Z(d)?(c=lc(d),e=!0):c=!1))}e&&jc(this,c?d:null)}else a==rc&&d.clear()}else jc(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(vc(this,this.f,b,c,a),S(this,-2),this.f.H());this.J&&(qc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; -function qc(a,b){if(ma("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function wc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",kc),h=Da();g.set(mc,h);f.set(mc,h);f.set(xc,"1.34.0");f.set(yc,window?window.location.href:null);f.set(zc,window?window.navigator.userAgent:"");a.f&&a.f.O&&(c&&(b&&(a.f.b.H=a.f.b.v),R(a.f)),d=a.f.O(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l>>f.c;0>>=f.c;0>>a.c;0g&&g>=ka&&(g+=ja);g=Math.trunc(Math.abs(g))%ja;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.xa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.xa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.xa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Y=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; +k.Qa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.na)return;c=Ca(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.oa+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.xa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bfc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",oc);Z(this.j)&&(pc(this,d),a=qc,rc(this.j));this.j.set(lc,Da());sc(this.j);var e=this.a&&!this.A;if(a==mc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=kc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(tc,""),this.c=null)):this.I(f+": "+g),rc(d),Z(d)?(c=kc(d),e=!0):c=!1))}e&&ic(this,c?d:null)}else a==qc&&d.clear()}else ic(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(uc(this,this.f,b,c,a),S(this,-2),this.f.H());this.J&&(pc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function pc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function vc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",jc),h=Da();g.set(lc,h);f.set(lc,h);f.set(wc,"1.34.0");f.set(xc,window?window.location.href:null);f.set(yc,window?window.navigator.userAgent:"");a.f&&a.f.O&&(c&&(b&&(a.f.b.H=a.f.b.v),R(a.f)),d=a.f.O(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.za+=d))&&(e.textContent=c.b.v?c.J.toFixed(2)+"Mhz":"Stopped",c.za=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(t){g=null,a=t.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,q=/( [a-z]+=)(['"])(.*?)\2/g;p=q.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Hc(a,b,c)}})}else c(a,null)} -function Ic(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Ec||K(!0));p=!1}var h,l,p=!0;Ec++;la[b]={};try{if(h=document.getElementById(b)){var q;if("object"==typeof resources&&(q=resources.css)){var t=document.head||document.getElementsByTagName("head")[0],P=document.createElement("style");P.type="text/css";P.styleSheet?P.styleSheet.cssText=q:P.appendChild(document.createTextNode(q));t.appendChild(P)}d|| -(q=a,"pdp"==a.substr(0,3)&&(q="pdpjs"),d="/versions/"+q+"/1.34.0/components.xsl");q=function(e,l){l?Fc(d,null,a,null,!1,f,function(a,e){e?(ka(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Ec||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Ec|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Fc(c,b,a,e,!0,f,q):Gc(c,null,b,a,e,!1,f,q)}else g("missing machine element: "+b)}catch(ua){g(ua.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Ic("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Ic("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!pa[a]){for(var c=!0,d=pa,e=a,f=b.length,g=[],h=[],l="",p=null,q=0;q=d||30<=(c.Aa+=d))&&(e.textContent=c.b.v?c.J.toFixed(2)+"Mhz":"Stopped",c.Aa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Gc(a,b,c)}})}else c(a,null)} +function Hc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Dc||K(!0));p=!1}var h,l,p=!0;Dc++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ha=document.createElement("style");ha.type="text/css";ha.styleSheet?ha.styleSheet.cssText=r:ha.appendChild(document.createTextNode(r));v.appendChild(ha)}d|| +(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.0/components.xsl");r=function(e,l){l?Ec(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Dc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Dc|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ec(c,b,a,e,!0,f,r):Fc(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(Ic){g(Ic.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Hc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Hc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!qa[a]){for(var c=!0,d=qa,e=a,f=b.length,g=[],h=[],l="",p=null,r=0;rc&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,Jd:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,qk:98,tk:99,d:100,e:101,uk:102,vk:103,wk:104,xk:105,Bk:106,k:107,Ck:108,Dk:109,n:110,Ek:111,p:112,q:113,r:114,Fk:115,t:116,Ik:117,Jk:118,Kk:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Vd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,aa:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.F=this.f=this.D=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} +"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Jd:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,rk:98,uk:99,d:100,e:101,vk:102,wk:103,xk:104,yk:105,Ck:106,k:107,Dk:108,Ek:109,n:110,Fk:111,p:112,q:113,r:114,Gk:115,t:116,Jk:117,Kk:118,Lk:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Vd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,ba:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.D=this.f=this.F=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} function qa(){return Date.now()||+new Date}function v(a){window&&window.alert(a)}function ra(a){var b=!1;window&&(b=window.confirm(a));return b}function ta(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;bb?1:a>1,k;k=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function bb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var k=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(k.onreadystatechange=function(){4===k.readyState&&(f=k.responseText,200==k.status||!k.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=k.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");k.open("POST",a,c);k.setRequestHeader("Content-type","application/x-www-form-urlencoded");k.send(l)}else k.open("GET",a,c),"bytes"==b&&k.overrideMimeType("text/plain; charset=x-user-defined"),k.send();c||(f=k.responseText,200!=k.status&&(e=k.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function cb(a,b){var c,d={ca:null,ga:null,ya:null,xa:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ya=g.load;d.xa=g.exec;if(e=g.bytes)d.ca=e;else if(e=g.words)for(d.ca=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.ca=Array(4*e.length),f=c=0;c>8&255,d.ca[f++]=e[c]>>16&255,d.ca[f++]=e[c]>>24&255;else d.ca=g;d.ga=g.symbols;d.ca.length?1==d.ca.length&&(v(d.ca[0]),d=null):(v("Empty resource: "+a),d=null)}catch(k){v("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ya=g.load;d.xa=g.exec;if(e=g.bytes)d.Z=e;else if(e=g.words)for(d.Z=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.Z=Array(4*e.length),f=c=0;c>8&255,d.Z[f++]=e[c]>>16&255,d.Z[f++]=e[c]>>24&255;else(e=g.data)?d.qk=e:d.Z=g;d.Z&&(d.Z.length?1==d.Z.length&&(v(d.Z[0]),d=null):(v("Empty resource: "+a),d=null));d.ga=g.symbols}catch(k){v("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Sf,a];this.F=this.f=this.D=this.J=null;this.exports={hold:this.Hf,toggle:this.lh, +function Rb(a,b){u.call(this,"Panel",a,512);this.j=this.u=0;this.M=b;this.fa=this.g=this.Wa=this.Eb=0;this.B=this.C=-1;this.G=this.I=this.w=!1;this.L=Sb;this.i={};this.b={START:[1,1,!0,!1,this.Tf],STEP:[1,1,!1,!1,this.Uf],ENABLE:[1,1,!1,!1,this.Of],CONT:[1,1,!0,!1,this.Mf],DEP:[0,0,!0,!1,this.Nf],EXAM:[1,1,!0,!1,this.Pf],LOAD:[1,1,!0,!1,this.Rf],TEST:[0,0,!0,!1,this.Qf]};for(a=0;22>a;a++)this.b["S"+a]=[0,0,!1,!1,this.Sf,a];this.D=this.f=this.F=this.J=null;this.exports={hold:this.Hf,toggle:this.lh, reset:this.gh,set:this.kh};y(this)}p(Rb,u);function Tb(a,b){return Ub(a,a.Eb=b)}h=Rb.prototype;h.reset=function(a){this.stop();a&&Tb(this,0)}; -h.va=function(a,b,c,d){if(this.J&&this.J.va(a,b,c,d)||this.f&&this.f.va(a,b,c,d)||this.F&&this.F.va(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.H[b]=c,this.u++,!0;default:return"led"==a||"rled"==a?(this.H[b]=c,this.i[b]=d?1:0,this.u++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.H[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, -b){return function(){Vb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Wb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Vb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Wb(a,b)}}(this,b),!0):u.prototype.va.call(this,a,b,c,d)}};h.za=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;Xb(b,this,dc);ec(b,this.reset.bind(this));fc(this);gc(this)}; +h.va=function(a,b,c,d){if(this.J&&this.J.va(a,b,c,d)||this.f&&this.f.va(a,b,c,d)||this.D&&this.D.va(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.H[b]=c,this.u++,!0;default:return"led"==a||"rled"==a?(this.H[b]=c,this.i[b]=d?1:0,this.u++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.H[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, +b){return function(){Vb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Wb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Vb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Wb(a,b)}}(this,b),!0):u.prototype.va.call(this,a,b,c,d)}};h.za=function(a,b,c,d){this.J=a;this.F=b;this.f=c;this.D=d;Xb(b,this,dc);ec(b,this.reset.bind(this));fc(this);gc(this)}; h.Ca=function(a,b){if(!b)if(this.M&&hc(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.save=function(){var a=new G(this);a.set(0,[this.fa,this.Eb,this.Wa]);return a.data()};h.restore=function(a){if(a=a[0])ic(this,this.fa=a[0]),Tb(this,a[1]),jc(this,a[2]);return!0};h.gh=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}gc(this);return!0};function kc(a,b,c){if(a=a.H[b])a.style.backgroundColor=c?"#ff0000":"#000000"} -function fc(a,b){for(var c in a.i)kc(a,c,null!=b?b:a.i[c])}function lc(a,b,c){if(a=a.H[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function gc(a){for(var b in a.b)lc(a,b,a.b[b][1])}function mc(a,b,c,d){if(a.H[b]){var e=a.F&&a.F.Aa||8;c=c||0;c=8==e?E(c,d):F(c,d);a.H[b].textContent!=c&&(a.H[b].textContent=c)}}h.Hf=function(a,b,c){if(Vb(this,b)){if(c){var d=this;setTimeout(function(){Wb(d,b);a&&a()},+c);return!1}Wb(this,b)}return!0}; +function fc(a,b){for(var c in a.i)kc(a,c,null!=b?b:a.i[c])}function lc(a,b,c){if(a=a.H[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function gc(a){for(var b in a.b)lc(a,b,a.b[b][1])}function mc(a,b,c,d){if(a.H[b]){var e=a.D&&a.D.Aa||8;c=c||0;c=8==e?E(c,d):F(c,d);a.H[b].textContent!=c&&(a.H[b].textContent=c)}}h.Hf=function(a,b,c){if(Vb(this,b)){if(c){var d=this;setTimeout(function(){Wb(d,b);a&&a()},+c);return!1}Wb(this,b)}return!0}; h.kh=function(a,b){if("SR"==a)return jc(this,Ka(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,lc(this,a,c[1]),!0):!1};h.lh=function(a){return Vb(this,a)?(Wb(this,a),!0):!1};function Vb(a,b){var c=a.b[b];return c?(lc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=nc&&(a.G=b==oc,a.I=b==pc),!0):!1}function Wb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(lc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} -h.Tf=function(a){a||this.f.A.V||(qc(this.f,this.fa),a=this.f,a.D.reset(),rc(a),this.b[sc]&&this.b[sc][1]&&tc(this.f))};h.Uf=function(){};h.Of=function(a){a||this.f.ba()};h.Mf=function(a){if(!a&&!this.f.A.V)if(this.b[sc]&&this.b[sc][1])tc(this.f);else{if((a=this.F)&&!Ha(a,!0))Ja(a,!0),uc(a,0,null),Ja(a,!1);else try{var b=this.f.Cc(1);0=a.f.ka?8:16,c=65472<=a.fa&&a.fa<65472+b,b=c?1:2,c=c?15:a.D.I;a.b[nc]&&a.b[nc][1]||(b=-b);ic(a,a.fa&~c|a.fa+b&c)}function ic(a,b){a.fa=b&a.D.I;if(a.B!==a.fa){a.B=a.fa;b=a.B;for(var c=0;22>c;c++)Dc(a,"A"+c,b&1<c;c++)Dc(a,"D"+c,b&1<b;b++)a.b["S"+b][1]=a.Wa&1<=a.f.ka?8:16,c=65472<=a.fa&&a.fa<65472+b,b=c?1:2,c=c?15:a.F.I;a.b[nc]&&a.b[nc][1]||(b=-b);ic(a,a.fa&~c|a.fa+b&c)}function ic(a,b){a.fa=b&a.F.I;if(a.B!==a.fa){a.B=a.fa;b=a.B;for(var c=0;22>c;c++)Dc(a,"A"+c,b&1<c;c++)Dc(a,"D"+c,b&1<b;b++)a.b["S"+b][1]=a.Wa&1<>2;this.i=this.j-1;this.G=this.M/this.j|0;this.S=this.G-1;this.Pa=[];this.na=0;this.C=!1;this.N=[];this.yf=[Hc,Ic,Jc,Kc];this.b=this.u=[];this.B=this.L=this.w=this.O=this.P=0;a=new I(this);Wc(a,this.F);this.b=Array(this.G);this.u=Array(this.G);for(b=0;b>2;this.i=this.j-1;this.G=this.M/this.j|0;this.S=this.G-1;this.Pa=[];this.na=0;this.C=!1;this.N=[];this.yf=[Hc,Ic,Jc,Kc];this.b=this.u=[];this.B=this.L=this.w=this.O=this.P=0;a=new I(this);Wc(a,this.D);this.b=Array(this.G);this.u=Array(this.G);for(b=0;b>>this.g;this.L=0;this.w=this.I;y(this)}p(Fc,u);function Zc(a,b){if(b!=a.L){for(var c=0;c>>a.g,a.u[a.P]=a.b[a.O])}}h=Fc.prototype;h.reset=function(){for(var a=0;a>>a.g;0g&&(n=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.K)return l.Xb+=l.K-f,l.K=f,!0;if(f>=l.K+l.Xb){n=l.size-(f-m);n>g&&(n=g);l.Xb=f-l.K+n;f=m+a.j;g-=n;k++;continue}}return ad(bd,f,g)}f=new I(a,f,n,a.j,d,e);Wc(f,a.F,l);a.b[k++]=f;f=m+a.j;g-=n}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+cd[d]+" at "+E(b)),!0):ad(dd,b,c)}h.Kd=function(a){return this.u[(a&this.w)>>>this.g].Db(a&this.i,a)}; +function Xc(a,b,c,d,e){for(var f=b,g=c,k=f>>>a.g;0g&&(n=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.K)return l.Xb+=l.K-f,l.K=f,!0;if(f>=l.K+l.Xb){n=l.size-(f-m);n>g&&(n=g);l.Xb=f-l.K+n;f=m+a.j;g-=n;k++;continue}}return ad(bd,f,g)}f=new I(a,f,n,a.j,d,e);Wc(f,a.D,l);a.b[k++]=f;f=m+a.j;g-=n}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+cd[d]+" at "+E(b)),!0):ad(dd,b,c)}h.Kd=function(a){return this.u[(a&this.w)>>>this.g].Db(a&this.i,a)}; h.Bc=function(a){var b=a&this.i,c=(a&this.w)>>>this.g;return Kb||b!=this.i?this.u[c].oa(b,a):this.u[c++].Db(b,a)|this.u[c&this.S].Db(0,a+1)<<8};h.Ld=function(a,b){this.u[(a&this.w)>>>this.g].Gb(a&this.i,b,a)};h.ac=function(a,b){var c=a&this.i,d=(a&this.w)>>>this.g;Kb||c!=this.i?this.u[d].Hb(c,b,a):(this.u[d++].Gb(c,b&255,a),this.u[d&this.S].Gb(0,b>>8&255,a+1))};function ed(a,b){return a.b[(b&a.I)>>>a.g]} function Bc(a,b){var c;a.C=!1;a.na++;var d=b&a.i,e=ed(a,b);Kb||d!=a.i?c=e.B(d,b):c=e.J(d,b)|ed(a,b+1).J(0,b+1)<<8;a.na--;return c}function fd(a,b,c){a.C=!1;a.na++;ed(a,b).F(b&a.i,c&255,b);a.na--}function zc(a,b,c){a.C=!1;a.na++;var d=b&a.i,e=ed(a,b);Kb||d!=a.i?e.C(d,c&65535,b):(e.F(d,c&255,b),ed(a,b+1).F(0,c>>8&255,b+1));a.na--} function $c(a){for(var b=0,c=[],d=0;da.f.ka)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,n=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&n&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(n)));for(var q=g[4],t=g[5]||1,r=0;r>8:e[2](f)&255):f&1&&(e=d.Pa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return this.f&&z(this.f,16|e[5])&&C(this.f,e[4]+".readByte("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,3);c=255;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to byte @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} function Ic(a,b,c){var d=!1,e=this.controller,f=e.Pa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Pa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d?this.f&&z(this.f,16|f[5])&&C(this.f,f[4]+".writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,5),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to byte @"+K(this.f,c)+": "+K(this.f, b),!0,!e.na))}function Jc(a,b){var c=-1,d=this.controller;a=d.Pa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".readWord("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,2);c=65535;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to word @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} function Kc(a,b,c){var d=!1,e=this.controller;a=e.Pa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d?this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,4),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to word @"+K(this.f,c)+": "+K(this.f,b),!0,!e.na))}function L(a){u.call(this,"Device",a,256);this.b={gb:128,Hd:-1}}p(L,u);h=L.prototype; -h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.F=d;var e=this;this.b.Hd=ld(c,function(){e.b.gb|=128;e.b.gb&64&&md(e.f,e.b.Qa);e.J&&H(e.J,1);nd(e.f,e.b.Hd,1E3/60)});this.b.Qa=od(c,64,6,2097152);Xb(b,this,pd);ec(b,this.reset.bind(this));d&&qd(d,64,function(a){var b=e.f;rd(e,"KIPDR",b.B[0],0,a[0]);rd(e,"KDPDR",b.B[0],8,a[0]);rd(e,"KIPAR",b.M[0],0,a[0]);rd(e,"KDPAR",b.M[0],8,a[0],!0);rd(e,"SIPDR",b.B[1],0,a[0]);rd(e,"SDPDR",b.B[1],8,a[0]);rd(e,"SIPAR",b.M[1],0,a[0]);rd(e,"SDPAR",b.M[1],8,a[0], -!0);rd(e,"UIPDR",b.B[3],0,a[0]);rd(e,"UDPDR",b.B[3],8,a[0]);rd(e,"UIPAR",b.M[3],0,a[0]);rd(e,"UDPAR",b.M[3],8,a[0],!0);b.W&32&&rd(e,"UNIMAP",b.Ha,-1,a[0])});y(this)};function rd(a,b,c,d,e,f){a=a.F;if(!(e&&0>b.indexOf(e.toUpperCase()))){e=0;var g=8,k="",l=!1,m=8;0>d&&(e=22,g=c.length,d=0,l=!0,m=4);for(var n=0;nb.indexOf(e.toUpperCase()))){e=0;var g=8,k="",l=!1,m=8;0>d&&(e=22,g=c.length,d=0,l=!0,m=4);for(var n=0;n>1&63;var b=this.f.Ha[a>>1];return a&1?b>>16:b&65535};h.mi=function(a,b){b=b>>1&63;var c=b>>1;this.f.Ha[c]=b&1?this.f.Ha[c]&65535|(a&63)<<16:this.f.Ha[c]&-65536|a&65534};h.Pg=function(a){return this.f.B[1][a>>1&7]};h.fi=function(a,b){this.f.B[1][b>>1&7]=a&65295};h.Ng=function(a){return this.f.B[1][(a>>1&7)+8]};h.di=function(a,b){this.f.B[1][(b>>1&7)+8]=a&65295};h.Og=function(a){return this.f.M[1][a>>1&7]}; h.ei=function(a,b){b=b>>1&7;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.Mg=function(a){return this.f.M[1][(a>>1&7)+8]};h.ci=function(a,b){b=(b>>1&7)+8;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.eg=function(a){return this.f.B[0][a>>1&7]};h.xh=function(a,b){this.f.B[0][b>>1&7]=a&65295};h.cg=function(a){return this.f.B[0][(a>>1&7)+8]};h.vh=function(a,b){this.f.B[0][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.f.M[0][a>>1&7]};h.wh=function(a,b){b=b>>1&7;this.f.M[0][b]=a;this.f.B[0][b]&=65295}; h.bg=function(a){return this.f.M[0][(a>>1&7)+8]};h.uh=function(a,b){b=(b>>1&7)+8;this.f.M[0][b]=a;this.f.B[0][b]&=65295};h.Vg=function(a){return this.f.B[3][a>>1&7]};h.li=function(a,b){this.f.B[3][b>>1&7]=a&65295};h.Tg=function(a){return this.f.B[3][(a>>1&7)+8]};h.ji=function(a,b){this.f.B[3][(b>>1&7)+8]=a&65295};h.Ug=function(a){return this.f.M[3][a>>1&7]};h.ki=function(a,b){b=b>>1&7;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Sg=function(a){return this.f.M[3][(a>>1&7)+8]}; h.ii=function(a,b){b=(b>>1&7)+8;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Vb=function(a){a&=7;return this.f.w&2048?this.f.ta[a]:this.f.g[a]};h.Zb=function(a,b){b&=7;this.f.w&2048?this.f.ta[b]=a:this.f.g[b]=a};h.rg=function(){return this.f.w&49152?this.f.X[0]:this.f.g[6]};h.Ih=function(a){this.f.w&49152?this.f.X[0]=a:this.f.g[6]=a};h.ug=function(){return this.f.g[7]};h.Lh=function(a){this.f.g[7]=a};h.Wb=function(a){a&=7;return this.f.w&2048?this.f.g[a]:this.f.ta[a]}; -h.$b=function(a,b){b&=7;this.f.w&2048?this.f.g[b]=a:this.f.ta[b]=a};h.sg=function(){return 1==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[1]};h.Jh=function(a){1==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[1]=a};h.tg=function(){return 3==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[3]};h.Kh=function(a){3==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[3]=a};h.ag=function(a){return this.f.xc[a-65504>>1]};h.th=function(a,b){this.f.xc[b-65504>>1]=a};h.xe=function(a){return 65520==a?(gd(this.D)>>6)-1:0}; +h.$b=function(a,b){b&=7;this.f.w&2048?this.f.g[b]=a:this.f.ta[b]=a};h.sg=function(){return 1==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[1]};h.Jh=function(a){1==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[1]=a};h.tg=function(){return 3==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[3]};h.Kh=function(a){3==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[3]=a};h.ag=function(a){return this.f.xc[a-65504>>1]};h.th=function(a,b){this.f.xc[b-65504>>1]=a};h.xe=function(a){return 65520==a?(gd(this.F)>>6)-1:0}; h.Ce=function(){};h.Rg=function(){return 1};h.hi=function(){};h.$f=function(){return this.f.P};h.sh=function(){this.f.P=0};h.gg=function(){return this.f.uc};h.zh=function(a,b){b&1||(a&=255);this.f.uc=a};h.lg=function(a,b){return b?0:this.f.ob};h.Ch=function(a){yd(this.f,a)};h.Qg=function(a,b){return b?0:this.f.Ga&65280};h.gi=function(a){this.f.Ga=a|255};h.qg=function(){return zd(this.f)};h.Hh=function(a){Ad(this.f,a)};h.Be=function(a,b){z(this)&&C(this,"writeIgnored("+E(b)+"): "+E(a),!0,!0)}; var M={},pd=(M[61568]=[null,null,L.prototype.Wg,L.prototype.mi,"UNIMAP",64,1170],M[62592]=[null,null,L.prototype.Pg,L.prototype.fi,"SIPDR",8,1145,64],M[62608]=[null,null,L.prototype.Ng,L.prototype.di,"SDPDR",8,1145,64],M[62624]=[null,null,L.prototype.Og,L.prototype.ei,"SIPAR",8,1145,64],M[62640]=[null,null,L.prototype.Mg,L.prototype.ci,"SDPAR",8,1145,64],M[62656]=[null,null,L.prototype.eg,L.prototype.xh,"KIPDR",8,1140,64],M[62672]=[null,null,L.prototype.cg,L.prototype.vh,"KDPDR",8,1145,64],M[62688]= [null,null,L.prototype.dg,L.prototype.wh,"KIPAR",8,1140,64],M[62704]=[null,null,L.prototype.bg,L.prototype.uh,"KDPAR",8,1145,64],M[62798]=[null,null,L.prototype.kg,L.prototype.Bh,"MMR3",1,1145,64],M[65382]=[null,null,L.prototype.fg,L.prototype.yh,"LKS"],M[65402]=[null,null,L.prototype.hg,L.prototype.Ah,"MMR0",1,1140,64],M[65404]=[null,null,L.prototype.ig,L.prototype.Be,"MMR1",1,1145,64],M[65406]=[null,null,L.prototype.jg,L.prototype.Be,"MMR2",1,1140,64],M[65408]=[null,null,L.prototype.Vg,L.prototype.li, @@ -126,24 +126,24 @@ h.ah=function(a,b){Jb&&a&1&&this.D.Na(b,64,2);a=!Kb&&a&1?this.g[a]|this.g[a+1]<< h.pi=function(a,b,c){Jb&&a&1&&this.D.Na(c,64,4);!Kb&&a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.G[a>>1]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0)};var Gd=0,hd=1,Hd=2,Yc=4,cd=["NONE","RAM","ROM","VID","H/W"],Fd=0,Vd=[],Ud=[I.prototype.Yf,I.prototype.qh,I.prototype.bh,I.prototype.ri],Yd=[I.prototype.Wf,I.prototype.oh,I.prototype.Yg,I.prototype.oi]; if(Fb)var Td=[I.prototype.Vf,I.prototype.nh,I.prototype.Xg,I.prototype.ni],Kd=[I.prototype.Xf,I.prototype.ph,I.prototype.ah,I.prototype.pi];var be;if(Fb){var ce=new ArrayBuffer(2);(new DataView(ce)).setUint16(0,256,!0);be=256===(new Uint16Array(ce))[0]}else be=!1;var Jd=be; function de(a,b){u.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.mb=c;this.ld=Math.round(this.Xc/1E4)/100;this.xb=this.ld*this.mb;this.md=this.qc=this.Ab=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.qa=a.autoStart;"string"==typeof this.A.qa&&(this.A.qa="true"==this.A.qa);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.Zd=this.hh.bind(this);this.nb=this.Ka=this.lb=this.b=this.la=this.Ja=this.nc=this.kb=this.Sb= -this.nd=this.wb=0;this.sa=null;y(this)}p(de,u);h=de.prototype;h.za=function(a,b,c,d){this.J=a;this.D=b;this.F=d;this.sa=a.i;for(a=0;a=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=le(a)&&(a.Ob=a.Rb=-1,he(a),a.ba(),c=!0);c&&a.v(le(a)+" cycles: checksum="+F(a.oc))}} -h.va=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.H[b]=c,!0;case "run":return this.H[b]=c,c.onclick=function(){var a;if(a=d.J)if(a=d.J,a.A.aa)a=!0;else{var b=null,c,k=ta(a.id);for(c=0;c=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=le(a)&&(a.Ob=a.Rb=-1,he(a),a.ca(),c=!0);c&&a.v(le(a)+" cycles: checksum="+F(a.oc))}} +h.va=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.H[b]=c,!0;case "run":return this.H[b]=c,c.onclick=function(){var a;if(a=d.J)if(a=d.J,a.A.ba)a=!0;else{var b=null,c,k=ta(a.id);for(c=0;ca.wb/a.xb?b=1:d=!0;a.mb=b;b=a.ld*a.mb;if(a.xb!=b){a.xb=b;b=a.xb.toFixed(2)+"Mhz";var e=a.H.setSpeed;e&&(e.textContent=b);a.v("target speed: "+b)}c&&a.J&&pe(a.J)}wc(a,a.Ka);a.Ka=0;a.Ja=qa();a.kb=0;ne(a);return d}function ld(a,b){var c=a.ia.length;a.ia.push([-1,b]);return c}function nd(a,b,c,d){0<=b&&ba.ia[b][0])&&(c=a.Xc*a.mb/1E3*c|0,a.A.V&&(c+=qe(a)),a.ia[b][0]=c)} function re(a,b){for(var c=a.ia.length-1;0<=c;c--){var d=a.ia[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function se(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function qe(a,b){var c=a.lb-=a.b;a.b=a.la=0;b&&(a.lb=0);return c} -h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&ne(this,!0);this.Sb=0;this.nc=qa();if(this.kb){var a=this.nc-this.kb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=re(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=qe(this,!0);this.Sb+=b;this.Ka+=b;xc(this,b);vc(this,b);this.Ab-=b;if(0>=this.Ab){this.Ab+=this.qc;++this.nd>=te&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ba();this.J&&this.J.stop(qa(),le(this)); +h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&ne(this,!0);this.Sb=0;this.nc=qa();if(this.kb){var a=this.nc-this.kb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=re(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=qe(this,!0);this.Sb+=b;this.Ka+=b;xc(this,b);vc(this,b);this.Ab-=b;if(0>=this.Ab){this.Ab+=this.qc;++this.nd>=te&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ca();this.J&&this.J.stop(qa(),le(this)); Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.Zd;this.kb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.kb-this.nc),d=this.kb-this.Ja;d&&(this.wb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.nb=0,me(this)));if(0>c||this.wbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.kb+=c;a(b,c)}}}; -function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.F||a.status("Started");setTimeout(a.Zd,0)}}h.Cc=function(){return 0};h.ba=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.F||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,ee=["power","reset"]; +function tc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{me(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&pe(a.J,!0),a.J.start(a.Ja,le(a)));a.D||a.status("Started");setTimeout(a.Zd,0)}}h.Cc=function(){return 0};h.ca=function(a){var b=!1;if(this.A.V){qe(this);wc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),le(this));b=!0;this.D||this.status("Stopped")}this.A.complete=a;return b};var oe=30,te=15,ee=["power","reset"]; function ue(a){var b=+a.model||1170;de.call(this,a,6666667);this.ka=b;this.Td=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.ta=this.X=[];this.M=this.B=this.Ha=this.xc=[];this.ib=this.O=this.Sd=this.yb=this.zb=this.rb=this.jb=this.P=this.uc=this.ob=this.Ga=this.S=this.vc=this.wc=this.W=this.i=0;this.Wd=[4,2,0,1];this.zc=0;this.Yd=255;1120>=this.ka?(this.be=ve.bind(this),this.Lb=this.Cf,this.zc=8,this.Yd=-1,this.fe=255,this.ee=0):(this.be=we.bind(this),this.Lb=this.Df, this.fe=~(1792|(1140>=this.ka?2048:0))&65535,this.ee=1140e.Fb&&(e.Fb=c,c+=4)}return de.prototype.Ca.call(this,a,b)}; -h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ba();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Td,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, -65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;de.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.D&&(xe(a),a.Sd=gd(a.D))} -function xe(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.pe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.yb?(a.Ia=65536,a.ub=a.W&16?4186112:253952,a.Fa=a.se,a.oa=a.sc?a.$g:a.Ed,a.Hb=a.tc?a.ti:a.Id,Zc(a.D,a.W&16?22:18)):(a.Ia=0,a.ub=57344,a.Fa=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,Zc(a.D,16))}function td(a){var b=a.S;b&57344||(b=b&-3199|a.zb<<5|a.rb<<1);return b} +h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ca();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Td,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;rc(this);ge(this);this.A.error=!1;de.prototype.reset.call(this)};function rc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.F&&(xe(a),a.Sd=gd(a.F))} +function xe(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.pe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.yb?(a.Ia=65536,a.ub=a.W&16?4186112:253952,a.Fa=a.se,a.oa=a.sc?a.$g:a.Ed,a.Hb=a.tc?a.ti:a.Id,Zc(a.F,a.W&16?22:18)):(a.Ia=0,a.ub=57344,a.Fa=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,Zc(a.F,16))}function td(a){var b=a.S;b&57344||(b=b&-3199|a.zb<<5|a.rb<<1);return b} function ud(a,b){b&=-3073;if(a.S!=b){b&57344&&!(a.S&57344)&&(a.vc=a.O>>16&65535,a.wc=a.O&65535);a.S=b;a.zb=(b&96)>>5;a.rb=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.yb!=c&&(a.yb=c,xe(a))}}function vd(a){a.S&57344||(a.vc=a.O>>16&65535);a=a.vc;a&65280&&(a=(a<<8|a>>8)&65535);return a}function wd(a){a.S&57344||(a.wc=a.O&65535);return a.wc}function xd(a,b){1170>a.ka&&(b&=-49);a.W!=b&&(a.W=b,a.jb=b&16?4194303:262143,xe(a))} -function ye(a,b,c,d){a.Td=b;qc(a,b);Ad(a,0);a.D.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.aa?a.A.V||tc(a):a.A.qa=!0}else a.F&&a.A.aa?a.ba()||a.J.A.reset||(ie(a.F),H(a.J,-1)):!1===c&&a.ba();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; +function ye(a,b,c,d){a.Td=b;qc(a,b);Ad(a,0);a.F.reset();rc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.ba?a.A.V||tc(a):a.A.qa=!0}else a.D&&a.A.ba?a.ca()||a.J.A.reset||(ie(a.D),H(a.J,-1)):!1===c&&a.ca();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; h.save=function(){var a=new G(this);a.set(0,[this.g,this.ta,this.X,this.M,this.B,this.Ha,this.xc,this.P,this.uc,this.ob,this.Ga,this.zb,this.rb,this.ib,this.i,this.O,this.bb,this.Ac,this.Dc]);a.set(1,[zd(this),td(this),vd(this),wd(this),this.W]);a.set(2,[this.nb,this.mb,this.A.qa]);a.set(3,ze(this));a.set(4,se(this));return a.data()}; h.restore=function(a){var b=ia(a[0]);this.g=b.next().value;this.ta=b.next().value;this.X=b.next().value;this.M=b.next().value;this.B=b.next().value;this.Ha=b.next().value;this.xc=b.next().value;this.P=b.next().value;this.uc=b.next().value;this.ob=b.next().value;this.Ga=b.next().value;this.zb=b.next().value;this.rb=b.next().value;this.ib=b.next().value;this.i=b.next().value;this.O=b.next().value;this.bb=b.next().value;this.Ac=b.next().value;this.Dc=b.next().value;b=a[1];Ad(this,b[0]);ud(this,b[1]); this.vc=b[2];this.wc=b[3];xd(this,b[4]);b=a[2];this.nb=b[0];me(this,b[1]);this.A.qa=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>14&3;c=a.w>>14&3;a.N!=c&&(a.X[c]=a.g[6],a.g[6]=a.X[a.N]);a.w=b;a.i&=-3;a.i|=a.R?2:1}function yd(a,b){if(b&=65024){var c=b>>9;do b+=34;while(c>>=1);a.i|=1}a.ob=b} h.Da=function(a){this.I=this.L=a;this.G=0};h.qb=function(a,b){this.I=this.L=this.C=a;this.G=b||0};function Ie(a,b){a.I=a.L=a.C=b;a.G=a.I^a.C>>1}function Je(a,b,c,d){a.I=a.L=a.C=b;a.G=(c^d)&(d^b)} -h.ra=function(a,b,c){if(!this.pa){0>this.bb?this.bb=zd(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Ad(this,e&-12289|this.bb>>2&12288);Ke(this,this.bb);Ke(this,this.g[7]);qc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ba();if(-4<=c)throw a;}}; +h.ra=function(a,b,c){if(!this.pa){0>this.bb?this.bb=zd(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Ad(this,e&-12289|this.bb>>2&12288);Ke(this,this.bb);Ke(this,this.g[7]);qc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ca();if(-4<=c)throw a;}}; function Le(a){var b=Me(a),c=Me(a);a.w&49152&&(c=c&-225|a.w&63712);qc(a,b);Ad(a,c);a.i&=-17}function Ne(a,b){var c=b>>13&31;31>c&&(b=a.W&32?a.Ha[c]+(b&8191)&4194303:b&-3932161);return b} function Oe(a,b,c){var d=[];if(c){c=Ne(a,b);var e=b>>13&31;d.push(c);d.push(e);a.W&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.yb){var e=a.N<<1,f=b>>13;7>13;a.W&a.Wd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.jb;3932160<=f&&(f=Ne(a,f));if(a.pa)return f;f>=a.Sd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& (g|=16384));a.B[a.N][d]=e;if(f!=(4194170&a.jb)||a.N)a.zb=a.N,a.rb=d;g&&(g&57344&&(0<=a.bb&&(g|=128),a.S&57344||(g|=a.S&4096|a.zb<<5|a.rb<<1,ud(a,a.S&-61695|g&61694)),a.ra(168,64,-2)),a.S&61440||!(f<(4191360&a.jb)||f>(4194239&a.jb))||(a.S|=4096,a.S&512&&(a.i|=64)));return f}function Me(a){var b=a.oa(a.g[6]|a.Ia);a.g[6]=a.g[6]+2&65535;return b}function Ke(a,b){var c=a.g[6]-2&65535;a.g[6]=c;a.O=a.O&65535|(a.O&-65536)<<8|16121856;a.i&256||a.Lb(4,-2,c);a.Hb(c,b)} function Pe(a,b,c,d){var e,f,g=d&8?0:a.Ia;switch(b){case 0:return a.ra(4,0,-3),0;case 1:return 6==c&&a.Lb(d,0,a.g[6]),a.b-=3,7==c?a.g[c]:a.g[c]|g;case 2:f=2;e=a.g[c];6==c&&a.Lb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.g[c];7!=c&&(e|=g);e=a.oa(e);e|=g;a.b-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.g[c]+f&65535;6==c&&a.Lb(d,f,e);7!=c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.g[c]-2&65535;7!=c&&(e|=g);e=a.oa(e)|g;a.b-=8;break;case 6:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,6==c&&a.Lb(d, -0,e),a.b-=6,e|g;case 7:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.Ga&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.Ga&&(c<=this.Ga-32?this.ra(4,0,-4):(this.P|=8,this.i|=32)))};h.pe=function(a){this.F&&$d(this.F,a,1);return this.ad(a)};h.te=function(a){this.F&&$d(this.F,a,2);return this.cd(a)}; -h.ze=function(a,b){this.F&&ae(this.F,a,1);this.dd(a,b)};h.Ae=function(a,b){this.F&&ae(this.F,a,2);this.jd(a,b)};function Cc(a,b){a.pa++;b=a.D.Bc(Ac(a,b,2));a.pa--;return b}function Qe(a,b){(b?--a.tc:--a.sc)||xe(a)}h.Gf=function(a,b,c){return Pe(this,a,b,c)};h.se=function(a,b,c){return Ac(this,Pe(this,a,b,c),c)};h.ye=function(a){return this.D.Bc(this.ib=a)};h.Zg=function(a){this.F&&$d(this.F,a,2);return this.ye(a)};h.Ed=function(a){return this.D.Bc(this.ib=Ac(this,a,2))}; -h.$g=function(a){this.F&&$d(this.F,a,2);return this.Ed(a)};h.De=function(a,b){this.D.ac(this.ib=a,b)};h.si=function(a,b){this.F&&ae(this.F,a,2);this.De(a,b)};h.Id=function(a,b){this.D.ac(this.ib=Ac(this,a,4),b)};h.ti=function(a,b){this.F&&ae(this.F,a,2);this.Id(a,b)};function Re(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Pe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.X[a.w>>12&3];return c} +0,e),a.b-=6,e|g;case 7:return e=a.oa(Ee(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.Ga&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.Ga&&(c<=this.Ga-32?this.ra(4,0,-4):(this.P|=8,this.i|=32)))};h.pe=function(a){this.D&&$d(this.D,a,1);return this.ad(a)};h.te=function(a){this.D&&$d(this.D,a,2);return this.cd(a)}; +h.ze=function(a,b){this.D&&ae(this.D,a,1);this.dd(a,b)};h.Ae=function(a,b){this.D&&ae(this.D,a,2);this.jd(a,b)};function Cc(a,b){a.pa++;b=a.F.Bc(Ac(a,b,2));a.pa--;return b}function Qe(a,b){(b?--a.tc:--a.sc)||xe(a)}h.Gf=function(a,b,c){return Pe(this,a,b,c)};h.se=function(a,b,c){return Ac(this,Pe(this,a,b,c),c)};h.ye=function(a){return this.F.Bc(this.ib=a)};h.Zg=function(a){this.D&&$d(this.D,a,2);return this.ye(a)};h.Ed=function(a){return this.F.Bc(this.ib=Ac(this,a,2))}; +h.$g=function(a){this.D&&$d(this.D,a,2);return this.Ed(a)};h.De=function(a,b){this.F.ac(this.ib=a,b)};h.si=function(a,b){this.D&&ae(this.D,a,2);this.De(a,b)};h.Id=function(a,b){this.F.ac(this.ib=Ac(this,a,4),b)};h.ti=function(a,b){this.D&&ae(this.D,a,2);this.Id(a,b)};function Re(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Pe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.X[a.w>>12&3];return c} function Se(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Pe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Ac(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.X[a.w>>12&3]=d}function Te(a,b){b>>=6;var c=a.Y=b&7;return(b=a.U=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c+a.zc]&a.Yd}function Ue(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.U=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d+a.zc];return c}function Ve(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Pe(a,b,c,8)} function We(a,b){var c=a.j=b&7;return(b=a.u=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c]&255}function Xe(a,b){var c,d=a.j=b&7;(b=a.u=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d];return c}function Ye(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Wc=a.Fa(b,e,7),c=0>c?a.g[-c-1]&255:c,a.Tc(e,d.call(a,c,a.jc(e))),e&1&&a.b--):(b=a.g[e],c=0>c?a.g[-c-1]&255:c,a.g[e]=b&65280|d.call(a,c,b&255))} function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,6),a.lc(e,d.call(a,0>c?a.g[-c-1]:c,a.kc(e)))):a.g[e]=d.call(a,0>c?a.g[-c-1]:c,a.g[e])}function Ze(a,b,c,d,e){var f=a.j=b&7;(b=a.u=(b&56)>>3)?(d=a.Fa(b,f,5),e.call(a,(c=0>c?a.g[-c-1]&255:c)<<8),a.Tc(d,c),d&1&&a.b--):(c?(c=0>c?a.g[-c-1]&255:c,a.g[f]=a.g[f]&~d|c<<24>>24&d):a.g[f]&=~d,e.call(a,c<<8))} function $e(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} -h.Cc=function(a){this.A.complete=!0;var b=this.F?af(this.F)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.lb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(bf(this.F,this.g[7],c)){this.ba();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.ob&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& -1&&this.i++;if(a){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.F,this.g[7],c)){this.ba();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.be(f)}while(0>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Ee(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&Ge(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& +1&&this.i++;if(a){if(this.i&4&&bf(this.D,this.g[7],c)){this.ca();break}if(0>c)break}if(this.i&112&&He(this)){if(this.i&4&&bf(this.D,this.g[7],c)){this.ca();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.be(f)}while(0>1|b<<16;Ie(this,a);return a&65535}function Df(a,b){a=b&128|b>>1|b<<8;Ie(this,a<<8);return a&255}function Ef(a,b){a=b&~a;this.Da(a);return a}function Ff(a,b){a=b&~a;this.Da(a<<8);return a} function Gf(a,b){a|=b;this.Da(a);return a}function Hf(a,b){a|=b;this.Da(a<<8);return a}function If(a,b){a=~b|65536;this.qb(a);return a&65535}function Jf(a,b){a=~b|256;this.qb(a<<8);return a&255}function Kf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Lf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Mf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Nf(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} function Of(a,b){a=-b;this.qb(a,a&b&32768);return a&65535}function Pf(a,b){a=-b;this.qb(a<<8,(a&b&128)<<8);return a&255}function Qf(a,b){a=b<<1|this.C>>16&1;Ie(this,a);return a&65535}function Rf(a,b){a=b<<1|this.C>>16&1;Ie(this,a<<8);return a&255}function Sf(a,b){a=(this.C&65536|b)>>1|b<<16;Ie(this,a);return a&65535}function Tf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Ie(this,a<<8);return a&255}function Uf(a,b){var c=b-a;Je(this,c,a,b);return c&65535} @@ -177,11 +177,11 @@ function gg(a){var b=Ue(this,a);a=Xe(this,a);this.Da((0>b?this.g[-b-1]:b)&a);thi function mg(a){Fe(this,a,Ce(this)||!De(this)!=!Be(this))}function ng(a){Fe(this,a,Ae(this)||Ce(this))}function og(a){Fe(this,a,!De(this)!=!Be(this))}function pg(a){Fe(this,a,De(this))}function qg(a){Fe(this,a,!Ce(this))}function rg(a){Fe(this,a,!De(this))}function sg(){this.ra(12,0,-9)}function tg(a){Fe(this,a,!0)}function ug(a){Fe(this,a,!Be(this))}function vg(a){Fe(this,a,Be(this))}function wg(a){a&1&&(this.C=0);a&2&&(this.G=0);a&4&&(this.L=1);a&8&&(this.I=0);this.b-=5} function xg(a){var b=Ue(this,a);a=Xe(this,a);var c=(b=0>b?this.g[-b-1]:b)-a;Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function yg(a){var b=Te(this,a);a=We(this,a);var c=(b=(0>b?this.g[-b-1]&255:b)<<8)-(a<<=8);Je(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)} function zg(a){var b=Xe(this,a);if(b){a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.g[a]=d&65535,this.g[a|1]=c-d*b&65535,this.L=d>>16|d,this.I=d>>16):(this.G=32768,this.L=d>>15|d,this.I=c>>16,-1===b&&65534===this.g[a]&&(this.g[a]=this.g[a|1]=1));this.b-=53}else this.L=this.I=0,this.G=32768,this.C=65536,this.b-=7}function Ag(){this.ra(24,0,-9);this.b-=20} -function Bg(){this.w&49152?(this.P|=128,this.ra(4,0,-8)):(this.sa&&1120==this.ka&&this.sa.setData(this.g[0],!0),this.F?Cg(this.F):this.ba());this.b-=7}function Dg(){this.ra(16,0,-9);this.b-=20}var Eg=[0,7,7,10,7,11,9,13];function Fg(a){this.la=this.b;qc(this,Ve(this,a));this.b=this.la-Eg[this.u]}var Gg=[0,14,14,17,14,18,16,20];function Hg(a){this.la=this.b;var b=Ve(this,a);a=a>>6&7;Ke(this,this.g[a]);this.g[a]=this.g[7];qc(this,b);this.b=this.la-Gg[this.u]} +function Bg(){this.w&49152?(this.P|=128,this.ra(4,0,-8)):(this.sa&&1120==this.ka&&this.sa.setData(this.g[0],!0),this.D?Cg(this.D):this.ca());this.b-=7}function Dg(){this.ra(16,0,-9);this.b-=20}var Eg=[0,7,7,10,7,11,9,13];function Fg(a){this.la=this.b;qc(this,Ve(this,a));this.b=this.la-Eg[this.u]}var Gg=[0,14,14,17,14,18,16,20];function Hg(a){this.la=this.b;var b=Ve(this,a);a=a>>6&7;Ke(this,this.g[a]);this.g[a]=this.g[7];qc(this,b);this.b=this.la-Gg[this.u]} var Ig=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Jg(a){var b=Ue(this,a);this.la=this.b;$e(this,a,b,this.Da);this.b=this.la-Ig[(this.U?8:0)+this.u]+(7!=this.j||this.u?0:2)}function Kg(a){var b=Te(this,a);Ze(this,a,b,65535,this.Da);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}var Lg=[7,13,13,17,14,18,17,21]; -function Mg(a){var b=Xe(this,a);a=a>>6&7;b=(b<<16>>16)*(this.g[a]<<16>>16);this.g[a]=b>>16&65535;this.g[a|1]=b&65535;b|=0;this.I=b>>16;this.L=this.I|b;this.G=0;this.C=-32768>b||32767>6&7;b=(b<<16>>16)*(this.g[a]<<16>>16);this.g[a]=b>>16&65535;this.g[a|1]=b&65535;b|=0;this.I=b>>16;this.L=this.I|b;this.G=0;this.C=-32768>b||32767>6;if(this.g[b]=this.g[b]-1&65535)qc(this,this.g[7]-((a&63)<<1)),this.b+=1;this.b-=6}function Tg(a){P(this,a,Ue(this,a),Uf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function Ug(a){P(this,a,0,Wf);this.b-=this.u?9:3+(7==this.j?2:0)}function Vg(){this.ra(28,0,-9)} -function Wg(){this.sa&&(this.sa.Gd(this.g[7],!0),this.sa.setData(this.g[0],!0));this.i|=8;Ee(this,-2);this.b-=3}function Xg(a){P(this,a,this.g[(a>>6&7)+this.zc],Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.F)b=this.F,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Cg(b)):b=!1;b||this.ra(8,0,-9)}function ve(a){Yg[a>>12].call(this,a)}function Zg(a){$g[a>>6&3].call(this,a)}function ah(a){bh[a>>6&3].call(this,a)}function ch(a){dh[a>>6&3].call(this,a)} +function Wg(){this.sa&&(this.sa.Gd(this.g[7],!0),this.sa.setData(this.g[0],!0));this.i|=8;Ee(this,-2);this.b-=3}function Xg(a){P(this,a,this.g[(a>>6&7)+this.zc],Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.D)b=this.D,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Cg(b)):b=!1;b||this.ra(8,0,-9)}function ve(a){Yg[a>>12].call(this,a)}function Zg(a){$g[a>>6&3].call(this,a)}function ah(a){bh[a>>6&3].call(this,a)}function ch(a){dh[a>>6&3].call(this,a)} function eh(a){fh[a&15].call(this,a)}function gh(a){hh[a&15].call(this,a)}function ih(a){jh[a>>6&3].call(this,a)}function kh(a){lh[a>>6&3].call(this,a)}function mh(a){nh[a>>6&3].call(this,a)} var Yg=[function(a){oh[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,Q,function(a){ph[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],oh=[function(a){qh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,Q,Q,Q],$g=[function(a){$e(this,a,0,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,If);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Mf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Kf);this.b-=this.u?9:3+(7==this.j?2:0)}],bh=[function(a){P(this,a,0,Of); this.b-=this.u?11:6},function(a){P(this,a,Ae(this)?1:0,cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Ae(this)?1:0,Uf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this,a);this.qb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],dh=[function(a){P(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Qf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Af);this.b-=this.u?9:3+(7==this.j?2:0)}],qh= @@ -191,52 +191,53 @@ a);this.qb(a<<8);this.b-=this.u?4:3+(7==this.j?2:0)}],nh=[function(a){Ye(this,a, var sh=[function(a){th[a>>8&15].call(this,a)},Jg,xg,gg,cg,eg,Yf,function(a){uh[a>>8&15].call(this,a)},function(a){vh[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Tg,Q],th=[function(a){wh[a>>4&15].call(this,a)},tg,qg,ig,jg,og,kg,mg,Hg,Hg,Zg,ah,ch,function(a){xh[a>>6&3].call(this,a)},Q,Q],xh=[function(a){a=this.g[7]+((a&63)<<1)&65535;var b=this.oa(a|this.Ia);qc(this,this.g[5]);this.g[6]=a+2&65535;this.g[5]=b;this.b-=8},function(a){a=Re(this,a,0);this.Da(a);Ke(this,a);this.b-=11},function(a){var b=Me(this); this.la=this.b;this.Da(b);Se(this,a,0,b);this.b=this.la-Lg[this.u]},function(a){$e(this,a,De(this)?65535:0,this.Da);this.b-=this.u?9:3+(7==this.j?2:0)}],wh=[function(a){yh[a&15].call(this,a)},Q,Q,Q,Fg,Fg,Fg,Fg,Pg,function(a){!(a&8)||1145>this.ka?Q.call(this,a):(this.w&49152||(this.w=this.w&-225|(a&7)<<5,this.i|=1,this.i&=-3),this.b-=5)},eh,gh,Ug,Ug,Ug,Ug],yh=[Bg,Wg,function(){Le(this);this.i|=this.w&16;this.b-=13},sg,Dg,Og,Qg,function(a){Q.call(this,a)},Q,Q,Q,Q,Q,Q,Q,Q],uh=[Mg,Mg,zg,zg,Zf,Zf,$f,$f, Xg,Xg,Q,Q,Q,Q,Sg,Sg],vh=[rg,pg,lg,ng,ug,vg,ag,bg,Ag,Vg,ih,kh,mh,function(a){1145>this.ka?Q.call(this,a):zh[a>>6&3].call(this,a)},Q,Q],zh=[function(a){Q.call(this,a)},function(a){a=Re(this,a,65536);this.Da(a);Ke(this,a);this.b-=11},function(a){var b=Me(this);this.la=this.b;this.Da(b);Se(this,a,65536,b);this.b=this.la-Lg[this.u]},function(a){Q.call(this,a)}]; -function Ah(a){u.call(this,"ROM",a,128);this.ga=this.g=null;this.u=+a.addr;this.b=+a.size;this.w=!1;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.j=a.file;this.B=Oa(this.j);if(this.j){a=this.j;var b=Pa(this.B);"json"!=b&&"hex"!=b&&(a=db()+"/api/v1/dump?file="+this.j+"&format=bytes&decimal=true");var c=this;bb(a,null,!0,function(a,b,f){f?(c.T("Unable to load ROM resource (error "+f+": "+a+")"),c.j=null):(na(c.vb,a,b),(a=cb(a,b))?(c.g=a.ca,c.ga=a.ga):c.j=null);Bh(c)})}}p(Ah,u); -h=Ah.prototype;h.za=function(a,b,c,d){this.D=b;this.f=c;this.F=d;Bh(this)};h.Ca=function(){this.ga&&(this.F&&Ch(this.F,this.id,this.u,this.b,this.ga),delete this.ga);return!0};h.Ba=function(){return!0}; -function Bh(a){if(!Ga(a)){if(a.j){if(!a.g||!a.D)return;a.b||(a.b=a.g.length);if(a.g.length!=a.b)Ea(a,"ROM size ("+F(a.g.length,8,!0)+") does not match specified size ("+F(a.b,8,!0)+")");else{var b;a:{b=a.u;if(57344<=b&&b<57344+Gc){var c={},c=(c[b]=[Ah.prototype.Jg,Ah.prototype.$h,null,null,null,a.b>>1],c);if(Xb(a.D,a,c)){a.status("Added "+a.b+"-byte ROM at "+E(b));b=a.w=!0;break a}}else if(Xc(a.D,b,a.b,Hd)){for(c=0;c>>f.g;0>>=f.g;0>>a.g;0>1],c);if(Xb(a.F,a,c)){a.status("Added "+a.b+"-byte ROM at "+E(b));b=a.w=!0;break a}}else if(Xc(a.F,b,a.b,Hd)){for(c=0;c>>f.g;0>>=f.g;0>>a.g;0=b.length){C(a,"invalid block at offset "+Na(n),4096);break}for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,m=m+((q&255)+(q>>8)+(t&255)+(t>>8)),r=l,D=q-=6;0=b.length){C(a,"insufficient data for block at offset "+Na(n),4096); -break}m+=b[l++]&255;if(m&255){C(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+Na(n),4096);break}if(D)for(C(a,"loading "+Na(D)+" bytes at "+Na(t)+"-"+Na(t+D),4096);D--;)fd(a.D,t++,b[r++]&255);else t&1?g=!0:null==d&&(d=t),null!=d&&C(a,"starting address: "+Na(d),4096);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e=la.Jd&&c<=la.xf&&(b=c-(la.Jd-la.Fe));b&&(a.preventDefault&&a.preventDefault(),d.Oc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.He&&(b=la.Ge);d.Oc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oc(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1}; -h.za=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;var e=this;this.P=od(this.f,this.M?-1:48,4,1048576);this.R=ld(this.f,function(){var a;a=-1;e.i.length&&(a=e.i.shift()&255,C(e,"receiveByte("+F(a,2,!0)+")"),e.L&&97<=a&&122>a&&(a-=32),nd(e.f,e.R,1E3/Math.round(e.S/10)));0<=a&&(e.C=a,e.b&128?e.C|=49152:e.b|=128,e.b&64&&md(c,e.P))});this.N=od(this.f,this.M?-1:52,4,1048576);this.X=ld(this.f,function(){e.g|=128;e.g&64&&md(c,e.N)});Xb(b,this,Jh,this.M?64832+8*(this.M-1)-65392:0);ec(b,this.reset.bind(this)); +h.za=function(a,b,c,d){this.J=a;this.F=b;this.f=c;this.D=d;var e=this;this.P=od(this.f,this.M?-1:48,4,1048576);this.R=ld(this.f,function(){var a;a=-1;e.i.length&&(a=e.i.shift()&255,C(e,"receiveByte("+F(a,2,!0)+")"),e.L&&97<=a&&122>a&&(a-=32),nd(e.f,e.R,1E3/Math.round(e.S/10)));0<=a&&(e.C=a,e.b&128?e.C|=49152:e.b|=128,e.b&64&&md(c,e.P))});this.N=od(this.f,this.M?-1:52,4,1048576);this.X=ld(this.f,function(){e.g|=128;e.g&64&&md(c,e.N)});Xb(b,this,Jh,this.M?64832+8*(this.M-1)-65392:0);ec(b,this.reset.bind(this)); y(this)};h.ue=function(a){if(!this.j){var b=fe(this.J,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Mb)return;c=Ya(c[1]);if(this.j=ua(c)){var e=this.j.exports;if(e){var f=e.connect;f&&f.call(this.j,this.I);if(this.G=e.receiveData){this.I=a;this.O=e.receiveStatus;this.status("Connected "+this.vb+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; h.Ca=function(a,b){if(!b)if(this.ue(this.I),!a)this.reset();else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.reset=function(){Kh(this)};h.save=function(){var a=new G(this);a.set(0,[this.C,this.b,this.g,this.i]);return a.data()};h.restore=function(a){return Kh(this,a[0])};function Kh(a,b){b||(b=[0,8192,128,a.i]);b=ia(b);a.C=b.next().value;a.b=b.next().value;a.g=b.next().value;a.i=b.next().value;return!0} h.Oc=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.W||8,c=a-this.B%a,this.W&&(b=Xa("",c)));this.U&&!this.B&&c&&(b=String.fromCharCode(this.U)+b);this.u.value+=b;this.u.scrollTop=this.u.scrollHeight;this.B+=c}}else if(null!=this.w){if(10==a||1024<=this.w.length)this.v(this.w), this.w="";10!=a&&(this.w+=String.fromCharCode(a))}nd(this.f,this.X,1E3/Math.round(this.Y/10));this.g&=-129};var Ih="buffer",Lh={},Jh=(Lh[65392]=[null,null,Hh.prototype.wg,Hh.prototype.Nh,"RCSR"],Lh[65394]=[null,null,Hh.prototype.vg,Hh.prototype.Mh,"RBUF"],Lh[65396]=[null,null,Hh.prototype.eh,Hh.prototype.vi,"XCSR"],Lh[65398]=[null,null,Hh.prototype.dh,Hh.prototype.ui,"XBUF"],Lh);rb(function(){for(var a=x(document,w,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.H[b]=c,!0;case "readTape":e=Ph;case "loadTape":return e||(e=Qh),this.H[b]=c,c.onclick= function(){var a=d.H.listTapes;a&&Rh(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Rh(d,Oa(b,!0),b,Qh,a)}return!1};return!0;case Sh:return this.H[b]=c,!0}return!1}; -h.za=function(a,b,c,d){this.J=a;this.D=b;this.f=c;this.F=d;this.I=Th(a);var e=this;if(a=Mh(this,fe(this.J,"autoMount")))for(var f in a)"PTR"==f&&(this.N[f]=a[f]);this.G=od(this.f,56,4,4096);this.S=ld(this.f,function(){1!=(e.b&32769)||e.b&128||(e.ic.indexOf("/api/v1/dump")&&(e=Pa(c),f="json"==e||"gz"==e?encodeURI(c):db()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!bb(f,null,!0,function(e,f,g){var k=0>g&&!!a.J&&!a.J.A.aa;g?a.T('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.vb,e,f),(e=cb(e,f))&&di(a,b,c,d, -e.ca,e.ya,e.xa));a.A.eb=!1;a.g&&(a.g--,a.g||y(a));ai(a)})}function Wh(a,b,c,d){if((a=a.H.listTapes)&&a.options){for(var e=0;ec.indexOf("/api/v1/dump")&&(e=Pa(c),f="json"==e||"gz"==e?encodeURI(c):db()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!bb(f,null,!0,function(e,f,g){var k=0>g&&!!a.J&&!a.J.A.ba;g?a.T('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.vb,e,f),(e=cb(e,f))&&di(a,b,c,d, +e.Z,e.ya,e.xa));a.A.eb=!1;a.g&&(a.g--,a.g||y(a));ai(a)})}function Wh(a,b,c,d){if((a=a.H.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.b=Array(a.Z);for(d=0;d>2;var f=e=0,b=new DataView(b,0,d);a.b=Array(a.aa);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Pa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Qa(c,"/")&&(d="dir"),f=db()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.zd?"":e)+"&format=json"));return!!bb(f, null,!0,function(b,c,d){li(a,b,c,d)})} -function li(a,b,c,d){var e=null,f=0>d&&!!a.J&&!a.J.A.aa;a.j=!1;if(d)a.controller.T('Unable to load disk "'+a.Xa+'" (error '+d+": "+b+")",f);else{na(a.controller.vb,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ -c+")");if(k.length)if(1==k.length)v(k[0]);else{a.Z=k.length;a.ja=k[0].length;a.ea=k[0][0].length;var l=k[0][0][0];a.ua=l&&l.length||512;for(d=c=0;d>2,n=l.pattern;void 0===n&&(n=l.pattern=0);var q=l.data;if(void 0===q){var t=l.bytes;if(void 0!==t&&t.length){for(var r=m<<2,D=t.length;Dd&&!!a.J&&!a.J.A.ba;a.j=!1;if(d)a.controller.T('Unable to load disk "'+a.Xa+'" (error '+d+": "+b+")",f);else{na(a.controller.vb,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ +c+")");if(k.length)if(1==k.length)v(k[0]);else{a.aa=k.length;a.ja=k[0].length;a.ea=k[0][0].length;var l=k[0][0][0];a.ua=l&&l.length||512;for(d=c=0;d>2,n=l.pattern;void 0===n&&(n=l.pattern=0);var q=l.data;if(void 0===q){var t=l.bytes;if(void 0!==t&&t.length){for(var r=m<<2,D=t.length;D>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.j)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.La?f=a.Va+a.La&&(a.La+=f-(a.Va+a.La)+1):(a.Va=f,a.La=1);d[f]=d[f]&~(255<g)break;e|=g<g)break;e|=g<=this.b.length||l>=this.b[k].length||m>=this.b[k][l].length){c="sector (CHS="+k+":"+l+":"+m+") out of range ("+ b+" changes applied)";b=-1;break}if(this.j){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.b[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.T("Unable to restore disk '"+this.Xa+": "+c);return b}; h.toJSON=function(){var a;a=0;for(var b;b=ni(this,a++);)pi(b);a=JSON.stringify(this.b,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; @@ -245,40 +246,40 @@ function ri(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){v(a.typ h.va=function(a,b,c){var d=this;switch(b){case "listDisks":return this.H[b]=c,c.onchange=function(){si(d)},!0;case "descDisk":case "listDrives":return this.H[b]=c,c.onchange=function(){var a=Ka(c.value,10);null!=a&&ti(d,a)},!0;case "loadDisk":return this.H[b]=c,c.onclick=function(){d.Bd()},!0;case "bootDisk":return this.H[b]=c,c.onclick=function(){d.le()},!0;case "saveDisk":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.onclick=function(){var a=d.H.listDrives;if(a&&a.options&&d.g)if(a= d.g[Ka(a.value,10)||0])if(a=a.da){var b;b="";for(var c=0,k;k=ni(a,c++);)for(var l=0,m=k.length;lg||9d||d>=this.g.length)return this.T("Unable to load the selected drive"),!1;if(!b)return Ti(this,d),!0;if(b==Qi)return this.T('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Ri){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Oa(b);this.status("Attempting to load "+b+' as "'+ a+'"')}Xi(this,d,a,b,!1,c);return!0};h.le=function(){var a,b=this.H.listDrives,b=b&&Ka(b.value,10);if(null==b||0>b||b>=this.g.length||!(a=this.g[b]))return this.T("Unable to boot the selected drive"),!1;if(!a.da)return this.T("Load a disk into the drive first"),!1;ye(this.f,0,!0,b);return(a=this.Ub(a,a.If,a.Jf,a.Kf,a.Bf,0,2))?(this.T("Unable to read the boot sector ("+a+")"),!1):!0}; function Xi(a,b,c,d,e,f){var g=-1,k=a.g[b];k.Oa.toLowerCase()!=d.toLowerCase()&&(g++,Ti(a,b,!0),k.Mc?a.T(a.type+" busy"):(k.Mc=!0,e&&(k.yd=!0,a.M++,z(a)&&C(a,"auto-loading disk: "+c)),k.Pb=!!f,ki(new gi(a,k,"preload"),c,d,f,a.oe)&&g++));return g} -h.oe=function(a,b,c,d,e){a.Mc=!1;b&&(b.Z>a.Z||b.ja>a.ja)&&(this.T('Disk "'+c+'" too large for drive '+(this.g[a.Tb].Qc||"---")),b=null);b?(a.da=b,a.Xa=c,a.Oa=d,this.we(a.Tb),Yi(this,c,d,b),this.T('Loaded disk "'+c+'" in drive '+(this.g[a.Tb].Qc||"---"),a.yd||e),this.J&&pe(this.J)):a.Pb=!1;a.yd&&(a.yd=!1,--this.M||y(this));ti(this,a.Tb);a.ic&&(a.ic(),a.ic=null)}; +h.oe=function(a,b,c,d,e){a.Mc=!1;b&&(b.aa>a.aa||b.ja>a.ja)&&(this.T('Disk "'+c+'" too large for drive '+(this.g[a.Tb].Qc||"---")),b=null);b?(a.da=b,a.Xa=c,a.Oa=d,this.we(a.Tb),Yi(this,c,d,b),this.T('Loaded disk "'+c+'" in drive '+(this.g[a.Tb].Qc||"---"),a.yd||e),this.J&&pe(this.J)):a.Pb=!1;a.yd&&(a.yd=!1,--this.M||y(this));ti(this,a.Tb);a.ic&&(a.ic(),a.ic=null)}; function Ni(a,b,c,d){if((a=a.H.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}h.mh=function(a){for(var b=0;b=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}var t,r;if(0>(t=a.read(n,q++))||0>(r=a.read(n,q++))){m=S.Fc;break}if(!k&&(zc(this.D,Ne(this.f,f),t|r<<8),kd(this.D))){m=S.ec;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; -h.Uc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.da;var n=null,q;a||(m=S.Ud,e=0);for(;e;){var t=Bc(this.D,Ne(this.f,f));if(kd(this.D)){m=S.ec;break}if(!n){if(b>=a.Z){m=S.Ec;break}n=a.seek(b,c,d+1,!0);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}if(k){var r,D;if(0>(r=a.read(n,q++))||0>(D=a.read(n,q++))){m=S.Fc;break}if(t!=(r|D<<8)){m=S.ge;break}}else if(!a.write(n,q++,t&255)||!a.write(n,q++,t>>8)){m=S.Fc;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Ub=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.da;var n=null,q;a||(m=S.Ud,e=0);for(;e;){if(!n){if(b>=a.aa){m=S.Ec;break}n=a.seek(b,c,d+1);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}var t,r;if(0>(t=a.read(n,q++))||0>(r=a.read(n,q++))){m=S.Fc;break}if(!k&&(zc(this.F,Ne(this.f,f),t|r<<8),kd(this.F))){m=S.ec;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Uc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.da;var n=null,q;a||(m=S.Ud,e=0);for(;e;){var t=Bc(this.F,Ne(this.f,f));if(kd(this.F)){m=S.ec;break}if(!n){if(b>=a.aa){m=S.Ec;break}n=a.seek(b,c,d+1,!0);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}if(k){var r,D;if(0>(r=a.read(n,q++))||0>(D=a.read(n,q++))){m=S.Fc;break}if(t!=(r|D<<8)){m=S.ge;break}}else if(!a.write(n,q++,t&255)||!a.write(n,q++,t>>8)){m=S.Fc;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; h.Ze=function(a,b,c,d,e,f){this.u=f&65535;this.b=this.b&~R.Jb|f>>16-R.ma.Jb&R.Jb;this.w=65536-e&65535;this.j=this.j&~bj.rd|d&bj.rd;this.i|=a;cj(this);return!0};function cj(a){a.b&=~R.hb;a.i&&(a.i|=S.Je,a.b|=R.hb,a.i&S.ed&&(a.b|=R.ed),z(a)&&C(a,a.type+": ERROR: "+E(a.i)))}h.Bg=function(){return this.G};h.Sh=function(){};h.Cg=function(){return this.i};h.Th=function(){};h.yg=function(){return this.b&R.fc}; h.Ph=function(a){this.b=this.b&~R.Sa|a&R.Sa;if(this.b&R.dc){a=!0;var b,c,d="",e=(this.j&bj.sb)>>bj.ma.sb,f=this.g[e],g,k,l,m,n,q;this.b&=~(R.Za|R.sd);this.i&=~S.qf;switch(c=this.b&R.wa){case dj.Ee:z(this)&&C(this,this.type+": CRESET("+e+")",!0);this.i=this.j=0;this.b=R.Za;break;case dj.Ue:d="RCHK";case dj.tb:d||(d="READ"),b=this.Ub;case dj.vd:d||(d="WCHK");case dj.hc:d||(d="WRITE");b||(b=this.Uc);g=(this.j&bj.bc)>>bj.ma.bc;k=(this.j&bj.hd)>>bj.ma.hd;l=this.j&bj.rd;m=65536-this.w&65535;n=(this.b&R.Jb)<< -16-R.ma.Jb|this.u;q=this.b&R.Qe?0:2;z(this)&&C(this,this.type+": "+d+"("+g+":"+k+":"+l+") "+E(n)+"--"+E(n+(m<<1)),!0,!0);if(g>=f.Z){this.i|=S.Ec;break}if(l>=f.ea){this.i|=S.Fc;break}a=b.call(this,f,g,k,l,m,n,q,c>=dj.vd,this.Ze.bind(this));break;case dj.Kc:g=(this.j&bj.bc)>>bj.ma.bc;z(this)&&C(this,this.type+": SEEK("+g+")",!0);g=f.aa){this.i|=S.Ec;break}if(l>=f.ea){this.i|=S.Fc;break}a=b.call(this,f,g,k,l,m,n,q,c>=dj.vd,this.Ze.bind(this));break;case dj.Kc:g=(this.j&bj.bc)>>bj.ma.bc;z(this)&&C(this,this.type+": SEEK("+g+")",!0);g(n=a.read(k,m++))||0>(q=a.read(k,m++))){g=gj.$a;break}zc(this.D,Ne(this.f,f),n|q<<8);if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; -h.Uc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=gj.$a,e=0);for(;e;){var n=Bc(this.D,Ne(this.f,f));if(kd(this.D)){g=gj.ec;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=gj.$a;break}m=0}if(!a.write(k,m++,n&255)||!a.write(k,m++,n>>8)){g=gj.$a;break}if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.Z)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.Ub=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=gj.$a,e=0);for(;e;){if(!k){k=a.seek(b,c,d+1);if(!k){g=gj.$a;break}m=0}var n,q;if(0>(n=a.read(k,m++))||0>(q=a.read(k,m++))){g=gj.$a;break}zc(this.F,Ne(this.f,f),n|q<<8);if(kd(this.F)){g=gj.ec;break}f+=2;e--;if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.aa)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.Uc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=gj.$a,e=0);for(;e;){var n=Bc(this.F,Ne(this.f,f));if(kd(this.F)){g=gj.ec;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=gj.$a;break}m=0}if(!a.write(k,m++,n&255)||!a.write(k,m++,n>>8)){g=gj.$a;break}if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.aa)))){g=gj.$a;break}}return l?l(g,b,c,d,e,f):g}; h.df=function(a,b,c,d,e,f){this.C=f&65535;this.b=this.b&~U.Ya|f>>16-U.ma.Ya&U.Ya;this.u=f>>16&hj.ab;this.j=this.i=b<>U.ma.Ya;if(!(this.b&U.Za)){a=!0;var b,c="",d=this.g[(this.b&U.sb)>>U.ma.sb],e=d.da,f,g,k;this.b&=~U.Ea;switch(this.b&U.wa){case jj.uf:this.w&kj.Rd&&(this.b&=U.Ea|U.wa|U.Ya);this.w=d.status|this.j&ij.Jc|(e&&512==e.Z?kj.Ne:0);break;case jj.Kc:(this.i&ij.Me)==ij.rf&&(b=this.i&ij.gc,c=(this.i&ij.tf)<<2,this.j=this.i&ij.sf?this.j+b:this.j-b,this.i=this.j=this.j&ij.gc|c);break;case jj.Ye:this.w=this.j;break;case jj.Ve:c="READ",b=this.Ub; -case jj.wf:c||(c="WRITE"),b||(b=this.Uc),f=this.i>>ij.ma.gc,g=this.i&ij.Jc?1:0,k=this.i&ij.ae,!e||f>=e.Z||k>=e.ea?this.b=this.b|gj.$a|U.hb:(a=65536-this.w&65535,e=(this.u&hj.ab)<<16|this.C,z(this)&&C(this,this.type+": "+c+"("+f+":"+g+":"+k+") "+E(e)+"--"+E(e+(a<<1)),!0,!0),a=b.call(this,d,f,g,k,a,e,2,!1,this.df.bind(this)))}a&&(this.b=this.b|U.Ea|U.Za,this.b&U.Ib&&md(this.f,this.Qa))}};h.Eg=function(){return this.C};h.Vh=function(a){this.C=a&lj.Sa};h.Hg=function(){return this.i}; +h.Xh=function(a){this.b=this.b&~U.Sa|a&U.Sa;this.u=this.u&60|(a&U.Ya)>>U.ma.Ya;if(!(this.b&U.Za)){a=!0;var b,c="",d=this.g[(this.b&U.sb)>>U.ma.sb],e=d.da,f,g,k;this.b&=~U.Ea;switch(this.b&U.wa){case jj.uf:this.w&kj.Rd&&(this.b&=U.Ea|U.wa|U.Ya);this.w=d.status|this.j&ij.Jc|(e&&512==e.aa?kj.Ne:0);break;case jj.Kc:(this.i&ij.Me)==ij.rf&&(b=this.i&ij.gc,c=(this.i&ij.tf)<<2,this.j=this.i&ij.sf?this.j+b:this.j-b,this.i=this.j=this.j&ij.gc|c);break;case jj.Ye:this.w=this.j;break;case jj.Ve:c="READ",b=this.Ub; +case jj.wf:c||(c="WRITE"),b||(b=this.Uc),f=this.i>>ij.ma.gc,g=this.i&ij.Jc?1:0,k=this.i&ij.ae,!e||f>=e.aa||k>=e.ea?this.b=this.b|gj.$a|U.hb:(a=65536-this.w&65535,e=(this.u&hj.ab)<<16|this.C,z(this)&&C(this,this.type+": "+c+"("+f+":"+g+":"+k+") "+E(e)+"--"+E(e+(a<<1)),!0,!0),a=b.call(this,d,f,g,k,a,e,2,!1,this.df.bind(this)))}a&&(this.b=this.b|U.Ea|U.Za,this.b&U.Ib&&md(this.f,this.Qa))}};h.Eg=function(){return this.C};h.Vh=function(a){this.C=a&lj.Sa};h.Hg=function(){return this.i}; h.Yh=function(a){this.i=a};h.Ig=function(){return this.w};h.Zh=function(a){this.w=a};h.Fg=function(){return this.u};h.Wh=function(a){this.u=a&hj.ab;this.b=this.b&~U.Ya|(this.u&3)<=m.Z){k=qj.Se;break}n=m.seek(b,c,d+1);if(!n){k=qj.pd;break}q=0;++d>=m.ea&&(d=0,++c>=m.ja&&(c=0,++b))}var t;if(0>(a=m.read(n,q++))||0>(t=m.read(n,q++))){k=qj.od;break}zc(this.D,Ne(this.f,f),a|t<<8);q>=m.ua&&(n=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +h.Ub=function(a,b,c,d,e,f,g,k,l){k=0;var m=a.da,n=null,q;z(this)&&C(this,this.type+".readData("+b+":"+c+":"+d+") "+E(f)+"--"+E(f+(e<<1)),!0,!0);m||(k=a.Tb?qj.gd:qj.fd,e=0);for(;e;){if(!n){if(b>=m.aa){k=qj.Se;break}n=m.seek(b,c,d+1);if(!n){k=qj.pd;break}q=0;++d>=m.ea&&(d=0,++c>=m.ja&&(c=0,++b))}var t;if(0>(a=m.read(n,q++))||0>(t=m.read(n,q++))){k=qj.od;break}zc(this.F,Ne(this.f,f),a|t<<8);q>=m.ua&&(n=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; function oj(a){var b=0,c=a.b&W.td?1:0,d=a.g[c],d=d&&d.da,e=a.I&rj.ab,f=a.G&sj.ab;a.i&=~(tj.Md|tj.Xd|tj.cc|tj.Ea);if(d)if(a.i|=tj.Ea,z(a)&&C(a,a.type+".readSector("+e+":0:"+f+")",!0,!0),c=d.seek(e,0,f,!0)){e=0;for(f=a.w.length;eg){b=qj.od;break}a.w[e++]=g}c.Ef&&(a.i|=tj.cc)}else b=qj.pd;else b=c?qj.gd:qj.fd;pj(a,b)} h.Kg=function(a,b){a=this.b;if(!b)switch(a&=W.fc,this.j){case V.bd:case V.EMPTY:this.uthis.u&&(this.b|=W.cb)}return a}; h.ai=function(a){this.b=this.b&~W.Sa|a&W.Sa;if(this.b&W.INIT)this.Cb();else if(this.b&W.dc&&this.j==V.Kb)switch(this.j=this.b&W.wa,this.b&=~(W.dc|W.cb|W.DONE|W.hb),sd(this.f,this.Qa),z(this)&&C(this,this.type+".processCommand("+uj[this.j>>1]+")",!0,!0),this.j){case V.bd:case V.EMPTY:case V.tb:case V.hc:case V.Lc:this.u=0;break;case V.Xe:a=this.g[this.b&W.td?1:0];this.i&=~tj.Ea;a&&a.da&&(this.i|=tj.Ea);this.C=this.i;pj(this);break;case V.We:this.C=this.L,pj(this)}else this.b&W.Ib?this.b&W.DONE&&md(this.f, @@ -293,37 +294,37 @@ function zj(a,b,c){var d;if(b){b=Aj(a,b);for(var e=0,f=!1,g=b,k=[],l=[],m=b.spli d))}return d}function Aj(a,b){for(var c,d=a.ia?"(":"{",e=a.ia?")":"}",f=new RegExp(a.ia?"\\((.*?)\\)":"\\{(.*?)\\}");(c=b.match(f))&&!(0<=c[1].indexOf(d));){var g=zj(a,c[1]);b=b.replace(d+c[1]+e,null!=g?K(a,g):"undefined")}for(;(c=b.match(/\[(.*?)]/))&&!(0<=c[1].indexOf("["));)b=b.replace("["+c[1]+"]","unimplemented");for(a=b;b=a.match(/\$([a-z]+)/i);){c=null;switch(b[1].toLowerCase()){case "ops":c=0}if(null==c)break;a=a.replace(b[0],c.toString())}return a} function Bj(a,b,c,d){var e;null!=b?(e=a.re(b),0<=e?e=a.Ad(e):(e=a.S[b],null==e&&(e=Ka(b,a.Aa))),null!=e||d||a.v("invalid "+(c?c:"value")+": "+b)):d||a.v("missing "+(c||"value"));return e}function Dj(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var f=4,g="";if(!f||4>=8;d=F(c,0,!0)+" "+c+". "+E(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.v((null!=b?b+": ":"")+d);return e} function Ej(a,b){if(b)return Dj(a,b,a.S[b]);var c=0;for(b in a.S)Dj(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Cj={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Fj(a){wj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.Fa=X();this.N=X();this.B=[];this.b=this.L=this.C=[];Gj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Hj(this);this.F=this;this.ka={};this.ha=this.ke=0;this.R=null;this.M=[];Ij(this,a.messages);this.ta=a.commands;this.Ja=Jj;this.W=[];this.I=0;this.Ka=this.sa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.g=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return ke(b,a)}):void 0===global[w]&&(global[w]= +function Fj(a){wj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.Fa=X();this.N=X();this.B=[];this.b=this.L=this.C=[];Gj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Hj(this);this.D=this;this.ka={};this.ha=this.ke=0;this.R=null;this.M=[];Ij(this,a.messages);this.ta=a.commands;this.Ja=Jj;this.W=[];this.I=0;this.Ka=this.sa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.g=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return ke(b,a)}):void 0===global[w]&&(global[w]= function(a){return ke(b,a)})}p(Fj,wj);function Kj(a){a=a&&a.K;null==a&&(a=-1);return a}function X(a,b,c){return{K:void 0===a?null:a,Ma:void 0===b?!1:b,Ua:!1,Aa:c}}h=Fj.prototype;h.Gd=function(a,b){a.K=b;a.Ua=!1;a.Aa=void 0;return a};function Lj(a){return[a.K,a.Ma,a.Aa,a.Ua,a.Pc]}function Mj(a,b){var c=X(b[0],b[1],b[2]);c.Ua=b[3];b[4]&&(c.he=xj(a,c.Pc=b[4]));return c} -h.za=function(a,b,c,d){this.D=b;this.J=a;this.f=c;this.g=a.i;(a=fe(a,"messages"))&&Ij(this,a);1140>this.f.ka&&(this.W=this.W.concat(Nj));1145>this.f.ka&&(this.W=this.W.concat(Oj));qd(this,16,function(a){a:{var b=d.D.b,c=a[0],e=a=0,l=b.length;if(c){a=Kj(Pj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.D.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): -(c=n.type,m=cd[c],n&&d.v(F(n.id,8)+" %"+F(e<this.f.ka&&(this.W=this.W.concat(Nj));1145>this.f.ka&&(this.W=this.W.concat(Oj));qd(this,16,function(a){a:{var b=d.F.b,c=a[0],e=a=0,l=b.length;if(c){a=Kj(Pj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.F.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): +(c=n.type,m=cd[c],n&&d.v(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;dd&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a)b=this.f.g[a];else if(16>a)b=this.f.ta[a-8];else if(20>a)b=this.f.X[a-16];else{var c=this.f,d=this.g;switch(a){case Xj:b=zd(this.f);break;case Yj:b=c.ob;break;case Zj:b=c.P;break;case ak:b=c.Ga&65280;break;case bk:b=td(c);break;case ck:b=vd(c);break;case dk:b=wd(c);break;case ek:b=c.W;break;case Vj:d&&(b=d.fa);break;case fk:d&&(b=d.Eb);break;case gk:d&&(b=d.Wa)}}return b}; -h.message=function(a,b){b&&(a+=" @"+Sj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ba(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,qe(a),a.Ab=0,a.J&&H(a.J,void 0))}}; +h.message=function(a,b){b&&(a+=" @"+Sj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ca(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,qe(a),a.Ab=0,a.J&&H(a.J,void 0))}}; function Hj(a){var b;if(!af(a))a.i&&a.i.length&&a.v("instruction history buffer freed"),a.P=0,a.i=[];else if(!a.i||!a.i.length){a.i=Array(hk);for(b=0;b>8;a.v("trapped to "+K(a,c&255,8)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?lk(a):mk(a)}}function jk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.aa?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; +function uc(a,b,c,d){if(!jk(a))return!1;var e="";null===c&&(e=(c=!a.sa||"tr"==a.sa)?"tr":"t");a.w=0;b||af(a)&&bf(a,a.f.g[7],0);try{b=re(a.f,b);var f=a.f.Cc(b);0>8;a.v("trapped to "+K(a,c&255,8)+" ("+(0>d?Lb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?lk(a):mk(a)}}function jk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.ba?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; h.Ba=function(a,b){b&&this.v(a?"suspending":"shutting down");return a?this.save():!0};h.reset=function(a){Hj(this);this.X=0;this.R=null;this.w=0;this.G=X(this.f.g[7]);this.A.V=!1;nk(this);a||ie(this)};h.save=function(){var a=new G(this);a.set(0,Lj(this.G));a.set(1,Lj(this.N));a.set(2,[this.j,this.O,this.ha]);a.set(3,this.B);return a.data()}; h.restore=function(a){var b=0;void 0!==a[2]&&(this.G=Mj(this,a[b++]),this.N=Mj(this,a[b++]),this.j=a[b][0],"string"==typeof this.j&&(this.j=[this.j]),this.O=a[b][1],this.ha|=a[b][2]);a[3]&&(this.B=a[3]);return!0};h.start=function(a,b){this.I||this.v("running");this.A.V=!0;this.Ha=a;this.Ia=b}; h.stop=function(a,b){if(this.A.V){this.A.V=!1;this.w=b-this.Ia;if(!this.I){b="stopped";if(this.w){a-=this.Ha;var c=0d&&(d=Cc(a.f,b)),65535!=(d&65535)&&(a.Gd(a.i[a.P],b),++a.P==a.i.length&&(a.P=0)));return!1}function Cg(a){var b=a.f;if(b.A.V)throw qc(b,a.f.O&65535),a.ba(),-1;return!1}function $d(a,b,c){ok(a,b,c||1,a.L)&&a.ba(!1)}function ae(a,b,c){ok(a,b,c||1,a.C)&&a.ba(!1)} -function Gj(a){var b,c,d;a.b=["bp"];if(a.L)for(b=1;b>>c.g],!1)):Qe(a.f,!1);a.L=["br"];if(a.C)for(b=1;b>>c.g],!0)):Qe(a.f,!0);a.C=["bw"];a.la=0;a.Y=0} -h.Bb=function(a,b,c){var d=!0;c||pk(this,a,b,!1,!0);if(a!=this.b){var e=Kj(b);if(-1===e)this.v("invalid address: "+Sj(this,b)),d=!1;else{var f=a==this.C;65535>>g.g].Bb(e&g.i,f)}else e=this.f,(f?e.tc++:e.sc++)||xe(e)}}d&&(a.push(b),c?b.Ua=!0:(qk(this,a,a.length-1,"set"),Hj(this)));return d}; -function pk(a,b,c,d,e){var f=!1;c=Kj(c);for(var g=1;g>>d.g],b)):Qe(a.f,b));k.Ua||Hj(a);break}}return f}function rk(a,b){for(var c=1;cd&&(d=Cc(a.f,b)),65535!=(d&65535)&&(a.Gd(a.i[a.P],b),++a.P==a.i.length&&(a.P=0)));return!1}function Cg(a){var b=a.f;if(b.A.V)throw qc(b,a.f.O&65535),a.ca(),-1;return!1}function $d(a,b,c){ok(a,b,c||1,a.L)&&a.ca(!1)}function ae(a,b,c){ok(a,b,c||1,a.C)&&a.ca(!1)} +function Gj(a){var b,c,d;a.b=["bp"];if(a.L)for(b=1;b>>c.g],!1)):Qe(a.f,!1);a.L=["br"];if(a.C)for(b=1;b>>c.g],!0)):Qe(a.f,!0);a.C=["bw"];a.la=0;a.Y=0} +h.Bb=function(a,b,c){var d=!0;c||pk(this,a,b,!1,!0);if(a!=this.b){var e=Kj(b);if(-1===e)this.v("invalid address: "+Sj(this,b)),d=!1;else{var f=a==this.C;65535>>g.g].Bb(e&g.i,f)}else e=this.f,(f?e.tc++:e.sc++)||xe(e)}}d&&(a.push(b),c?b.Ua=!0:(qk(this,a,a.length-1,"set"),Hj(this)));return d}; +function pk(a,b,c,d,e){var f=!1;c=Kj(c);for(var g=1;g>>d.g],b)):Qe(a.f,b));k.Ua||Hj(a);break}}return f}function rk(a,b){for(var c=1;c>23)&65535,A=K(r,t);else if(B==xk)t=t.K-((f&63)<<1)&65535,A=K(r,t);else if(B==yk)A=K(r,f&7,3);else if(B==zk)A=K(r,f&63,6);else if(B==Ak)A=K(r,f&255,8);else if(B=f&D,D&Bk&&(B>>=6,D>>=6),D&Z){var D=null,J=B& Ck;switch(B&Dk){case 0:A=Uj(r,J);break;case 8:A="@"+Uj(r,J);D=Ek(r,r.f.g[J]);break;case 16:7>J?A="("+Uj(r,J)+")+":(B=r.Ra(t,2),A="#"+K(r,B,-1));break;case 24:7>J?A="@("+Uj(r,J)+")+":(B=r.Ra(t,2),A="@#"+K(r,B,-1),D=Ek(r,B));break;case 32:A="-("+Uj(r,J)+")";break;case 40:A="@-("+Uj(r,J)+")";break;case 48:B=r.Ra(t,2);A=K(r,B,-1)+"("+Uj(r,J)+")";7==J&&(A=K(r,B=B+t.K&65535),D=Ek(r,B));break;case 56:B=r.Ra(t,2),A="@"+K(r,B)+"("+Uj(r,J)+")",7==J&&(A="@"+K(r,B=B+t.K&65535),D=Ek(r,Cc(r.f,B)))}D&&(A=[A,D])}r= A;if(!r||!r.length){k="INVALID";break}"string"!=typeof r&&(m=r[1],r=r[0]);0=a.f.ub&&b=c.B&&(b=c.Pa[b&jd])&&(a=b[4]);return a}function Fk(a,b){switch(b){case "N":a=De(a.f);break;case "Z":a=Ce(a.f);break;case "V":a=Be(a.f);break;case "C":a=Ae(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "}function Gk(a,b){var c=Uj(a,b);c&&(c+="="+K(a,a.Ad(b))+" ");return c} +function Ek(a,b){b=Oe(a.f,b)[0];b>=a.f.ub&&b=c.B&&(b=c.Pa[b&jd])&&(a=b[4]);return a}function Fk(a,b){switch(b){case "N":a=De(a.f);break;case "Z":a=Ce(a.f);break;case "V":a=Be(a.f);break;case "C":a=Ae(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "}function Gk(a,b){var c=Uj(a,b);c&&(c+="="+K(a,a.Ad(b))+" ");return c} function Hk(a,b){var c,d="";for(c=0;6>c;c++)d+=Gk(a,c);d=d+"\n"+(Gk(a,6)+Gk(a,7));d+=Gk(a,Xj)+Gk(a,Yj)+Gk(a,ak);d+=Fk(a,"T")+Fk(a,"N")+Fk(a,"Z")+Fk(a,"V")+Fk(a,"C");b&&(b=d,c=""+(Gk(a,bk)+Gk(a,ck)),c+=Gk(a,dk)+Gk(a,ek)+Gk(a,Zj),c=c+"\n"+(Gk(a,gk)+Gk(a,Vj)+Gk(a,fk)),d=b+("\n"+c));return d}h.me=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],q=$a(n,l,a.me);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Gk:b,K:c,Lf:d,ga:e,ie:f})}function Ik(a,b,c){var d=[],e=Kj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&e>>0,g],q=$a(n,l,a.me);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Hk:b,K:c,Lf:d,ga:e,ie:f})}function Ik(a,b,c){var d=[],e=Kj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&exb&&(xb=0);65536mf?String.fromCharCode(mf):"."),Nd=Nd>>8}zb&&(zb+="\n");zb=jf?zb+(Ab+","):zb+(Ta+": "+Ab+(Md?"":" "+lf))}zb&&a.v(zb);a.Fa=oa;a.Aa=pl}}}}break;case "e":if("else"== g[0])break;var bc,nf,of,pf,qf=g[0],rf=g[1];"eb"==qf?(bc=1,nf=255,of=a.Od,pf=a.Pd):"e"==qf||"ew"==qf?(bc=2,nf=65535,of=a.Ra,pf=a.Le):rf=null;if(null==rf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var Od=Pj(a,rf);if(Od)for(var Pd=2;Pduf;){for(var Bb=null,tl=256;65536>Rc.K>>>0;){vf.K=a.Ra(Rc,2);if(null==Rc.K||!tl--)break;if(!(vf.K&1)){for(var ul=a,Qd=vf,Fi=null,Sc=Qd.K,Gi=Sc,wf=1;6>=wf&⪼wf++){if(2> ";rb(function(){for(var a=x(document,w,"debugger"),b=0;b\nLicense: GPL version 3 or later ");this.v("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;b\nLicense: GPL version 3 or later ");this.v("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bUk){if(Vk(d,this.G)){this.u=new G(this,"1.34.0",cl);Vk(this.u)&&(dl(this,d),a=el,fl(this.u));this.u.set($k,ab());gl(this.u);var e=this.b&&!this.C;if(a==al||ra("Click OK to restore the previous "+Gb+" machine state, or CANCEL to reset the machine.")){if(c=Zk(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Vk(d,g):("error"==f&&"no machine state"!= g?(this.T("Error: "+g),"unable to verify user"==g&&(hb(hl,""),this.g=null)):this.v(f+": "+g),fl(d),Vk(d)?(c=Zk(d),e=!0):c=!1))}e&&Xk(this,c?d:null)}else a==el&&d.clear()}else Xk(this);delete this.G;delete this.B}e=ta(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.A.aa=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(il(this,this.f,b,c,a),H(this,-2),this.f.qa());this.N&&(dl(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; +function il(a,b,c,d,e){if(!b.A.ba){b.A.ba=!0;var f=null;try{if(e&&((f=c.get(b.id))||(f=c.get(b.id.replace(/[a-z0-9]\./i,".")))),"string"===typeof f&&(f=null),!b.Ca(f,d)&&f&&(v("Unable to restore state for "+b.type),a.I&&!a.R?(c.clear(),a.b=Uk,window&&window.location.reload()):a.N=!0,b.Ca(null),e=!1),!d&&b.Vd){var g=b.Vd.split("|");for(a=0;aa[1];a=a[2];this.P=!0;this.A.ba=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(il(this,this.f,b,c,a),H(this,-2),this.f.qa());this.N&&(dl(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; function dl(a,b){if(ra("There may be a problem with your "+Gb+" machine.\n\nTo help us diagnose it, click OK to send this "+Gb+" machine state to http://www.pcjs.org.")){var c=a.U;a=a.g||"";b=b.toString();var d={};d.app=Gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;bb("http://www.pcjs.org/api/v1/report",d,!0)}} -function Ok(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new G(a,"1.34.0"),g=new G(a,"1.34.0",Yk),k=ab();g.set($k,k);f.set($k,k);f.set(jl,"1.34.0");f.set(kl,window?window.location.href:null);f.set(ll,window?window.navigator.userAgent:"");a.f&&a.f.Ba&&(c&&(b&&(a.f.A.qa=a.f.A.V),a.f.ba()),d=a.f.Ba(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.A.aa=!1,!1===d&&(e=null)));for(var k=ta(a.id),l=0;l=d||30<=(c.$c+=d))&&(e.textContent=c.A.V?c.wb.toFixed(2)+"Mhz":"Stopped",c.$c=0)}if(a.i&&(a=a.i,b=b||0,a.u)){c=a.f.A.V;d=!!(a.f.i&8);if(0>=b||60<=(a.j+=b)){for(e=0;eb?a.fa=a.f.g[7]:0c&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,hd:65,Lh:66,Rh:67,si:68,E:69,yi:70,Bi:71,Ni:72,Pi:73,Qi:74,Ri:75,Si:76,Vi:77,Xi:78,cj:79,fj:80,Q:81,hj:82,kj:83,tj:84,vj:85,xj:86,yj:87,Cj:88,Dj:89,Ke:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Ej:97,Fj:98,Ij:99,d:100,e:101,Jj:102,Kj:103,Lj:104,Mj:105,Qj:106,k:107,Rj:108,Sj:109,n:110,Tj:111,p:112,q:113,r:114,Uj:115,t:116,Wj:117,Xj:118,Yj:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.qd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.pd=c||0;this.D=this.c=this.u=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} +"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,hd:65,Lh:66,Rh:67,si:68,E:69,yi:70,Bi:71,Ni:72,Pi:73,Qi:74,Ri:75,Si:76,Vi:77,Xi:78,cj:79,fj:80,Q:81,hj:82,kj:83,tj:84,vj:85,xj:86,yj:87,Cj:88,Dj:89,Ke:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Ej:97,Gj:98,Jj:99,d:100,e:101,Kj:102,Lj:103,Mj:104,Nj:105,Rj:106,k:107,Sj:108,Tj:109,n:110,Uj:111,p:112,q:113,r:114,Vj:115,t:116,Xj:117,Yj:118,Zj:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.qd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.pd=c||0;this.D=this.c=this.v=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} function pa(){return Date.now()||+new Date}function u(a){window&&window.alert(a)}function qa(a){var b=!1;window&&(b=window.confirm(a));return b}function ra(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b":">",'"':""","'":"'"},Ka={0:"NUL" function La(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function Ma(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var k=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(k.onreadystatechange=function(){4===k.readyState&&(f=k.responseText,200==k.status||!k.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=k.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");k.open("POST",a,c);k.setRequestHeader("Content-type","application/x-www-form-urlencoded");k.send(l)}else k.open("GET",a,c),"bytes"==b&&k.overrideMimeType("text/plain; charset=x-user-defined"),k.send();c||(f=k.responseText,200!=k.status&&(e=k.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Na(a,b){var c,d={N:null,ia:null,ea:null,da:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ea=g.load;d.da=g.exec;if(e=g.bytes)d.N=e;else if(e=g.words)for(d.N=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.N=Array(4*e.length),f=c=0;c>8&255,d.N[f++]=e[c]>>16&255,d.N[f++]=e[c]>>24&255;else d.N=g;d.ia=g.symbols;d.N.length?1==d.N.length&&(u(d.N[0]),d=null):(u("Empty resource: "+a),d=null)}catch(k){u("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ea=g.load;d.da=g.exec;if(e=g.bytes)d.L=e;else if(e=g.words)for(d.L=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.L=Array(4*e.length),f=c=0;c>8&255,d.L[f++]=e[c]>>16&255,d.L[f++]=e[c]>>24&255;else(e=g.data)?d.Fj=e:d.L=g;d.L&&(d.L.length?1==d.L.length&&(u(d.L[0]),d=null):(u("Empty resource: "+a),d=null));d.ia=g.symbols}catch(k){u("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.ff,a];this.D=this.c=this.u=this.A=null;this.exports={hold:this.We,toggle:this.Bg,reset:this.ug, +function lb(a,b){r.call(this,"Panel",a,512);this.i=this.l=0;this.F=b;this.U=this.g=this.f=this.b=0;this.s=this.u=-1;this.w=this.B=this.m=!1;this.C=mb;this.h={};this.a={START:[1,1,!0,!1,this.gf],STEP:[1,1,!1,!1,this.hf],ENABLE:[1,1,!1,!1,this.bf],CONT:[1,1,!0,!1,this.$e],DEP:[0,0,!0,!1,this.af],EXAM:[1,1,!0,!1,this.cf],LOAD:[1,1,!0,!1,this.ef],TEST:[0,0,!0,!1,this.df]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.ff,a];this.D=this.c=this.v=this.A=null;this.exports={hold:this.We,toggle:this.Bg,reset:this.ug, set:this.zg};B(this)}n(lb,r);h=lb.prototype;h.reset=function(a){this.stop();a&&nb(this,this.b=0)}; -h.ma=function(a,b,c,d){if(this.A&&this.A.ma(a,b,c,d)||this.c&&this.c.ma(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.o[b]=c,this.m++,!0;default:return"led"==a||"rled"==a?(this.o[b]=c,this.h[b]=d?1:0,this.m++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.o[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){ob(a, -b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){pb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){ob(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){pb(a,b)}}(this,b),!0):r.prototype.ma.call(this,a,b,c,d)}};h.ja=function(a,b,c,d){this.A=a;this.u=b;this.c=c;this.D=d;qb(b,this,rb);sb(b,this.reset.bind(this));tb(this);ub(this)};h.la=function(a,b){if(!b)if(this.F&&vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; +h.ma=function(a,b,c,d){if(this.A&&this.A.ma(a,b,c,d)||this.c&&this.c.ma(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.o[b]=c,this.l++,!0;default:return"led"==a||"rled"==a?(this.o[b]=c,this.h[b]=d?1:0,this.l++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.o[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){ob(a, +b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){pb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){ob(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){pb(a,b)}}(this,b),!0):r.prototype.ma.call(this,a,b,c,d)}};h.ja=function(a,b,c,d){this.A=a;this.v=b;this.c=c;this.D=d;qb(b,this,rb);sb(b,this.reset.bind(this));tb(this);ub(this)};h.la=function(a,b){if(!b)if(this.F&&vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; h.ka=function(a){return a?this.save():!0};h.save=function(){var a=new E(this);a.set(0,[this.U,this.b,this.f]);return a.data()};h.restore=function(a){if(a=a[0])wb(this,this.U=a[0]),nb(this,this.b=a[1]),xb(this,a[2]);return!0};h.ug=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}ub(this);return!0};function yb(a,b,c){if(a=a.o[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function tb(a,b){for(var c in a.h)yb(a,c,null!=b?b:a.h[c])} function zb(a,b,c){if(a=a.o[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function ub(a){for(var b in a.a)zb(a,b,a.a[b][1])}function Ab(a,b,c,d){if(a.o[b]){var e=a.D&&a.D.h||8;c=c||0;c=8==e?Ca(c,d):Da(c,d);a.o[b].textContent!=c&&(a.o[b].textContent=c)}}h.We=function(a,b,c){if(ob(this,b)){if(c){var d=this;setTimeout(function(){pb(d,b);a&&a()},+c);return!1}pb(this,b)}return!0}; h.zg=function(a,b){if("SR"==a)return xb(this,Ba(b,8));var c=this.a[a];return c?(c[1]=+b?1:0,zb(this,a,c[1]),!0):!1};h.Bg=function(a){return ob(this,a)?(pb(this,a),!0):!1};function ob(a,b){var c=a.a[b];return c?(zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Bb&&(a.w=b==Cb,a.B=b==Db),!0):!1}function pb(a,b){var c=a.a[b];c&&(c[2]&&c[3]&&(zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} -h.gf=function(a){a||this.c.j.M||(F(this.c,this.U),a=this.c,a.u.reset(),Eb(a),this.a[Fb]&&this.a[Fb][1]&&Gb(this.c))};h.hf=function(){};h.bf=function(a){a||G(this.c)}; -h.$e=function(a){if(!a&&!this.c.j.M)if(this.a[Fb]&&this.a[Fb][1])Gb(this.c);else{a=this.D;var b;if(b=a)a.j.Ra&&(a.j.Wc=!0),b=!a.j.Ra;if(b)Aa(a,!0),a.f(0,null),Aa(a,!1);else try{var c=this.c.zc(1);0=a.c.sa?8:16,c=65472<=a.U&&a.U<65472+b,b=c?1:2,c=c?15:a.u.v;a.a[Bb]&&a.a[Bb][1]||(b=-b);wb(a,a.U&~c|a.U+b&c)}function wb(a,b){a.U=b&a.u.v;if(a.s!==a.U){a.s=a.U;b=a.s;for(var c=0;22>c;c++)Pb(a,"A"+c,b&1<c;c++)Pb(a,"D"+c,b&1<=a.c.sa?8:16,c=65472<=a.U&&a.U<65472+b,b=c?1:2,c=c?15:a.v.u;a.a[Bb]&&a.a[Bb][1]||(b=-b);wb(a,a.U&~c|a.U+b&c)}function wb(a,b){a.U=b&a.v.u;if(a.s!==a.U){a.s=a.U;b=a.s;for(var c=0;22>c;c++)Pb(a,"A"+c,b&1<c;c++)Pb(a,"D"+c,b&1<b;b++)a.a["S"+b][1]=a.f&1<>2;this.f=this.g-1;this.s=this.C/this.g|0;this.K=this.s-1;this.Qa=[];this.m=0;this.l=!1;this.F=[];this.Le=[Tb,Ub,Vb,Wb];this.a=this.b=[];this.B=this.w=this.i=this.H=this.I=0;a=new H(this);Xb(a);this.a=Array(this.s);this.b=Array(this.s);for(b=0;b>>this.h;this.w=0;this.i=this.v;B(this)}n(Rb,r);function $b(a,b){if(b!=a.w){for(var c=0;c>>a.h,a.b[a.I]=a.a[a.H])}}h=Rb.prototype;h.reset=function(){for(var a=0;a>2;this.f=this.g-1;this.s=this.C/this.g|0;this.K=this.s-1;this.Qa=[];this.l=0;this.m=!1;this.F=[];this.Le=[Tb,Ub,Vb,Wb];this.a=this.b=[];this.B=this.w=this.i=this.H=this.I=0;a=new H(this);Xb(a);this.a=Array(this.s);this.b=Array(this.s);for(b=0;b>>this.h;this.w=0;this.i=this.u;B(this)}n(Rb,r);function $b(a,b){if(b!=a.w){for(var c=0;c>>a.h,a.b[a.I]=a.a[a.H])}}h=Rb.prototype;h.reset=function(){for(var a=0;a>>a.h;0g&&(p=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.ab)return l.Tb+=l.ab-f,l.ab=f,!0;if(f>=l.ab+l.Tb){p=l.size-(f-m);p>g&&(p=g);l.Tb=f-l.ab+p;f=m+a.g;g-=p;k++;continue}}return bc(cc,f,g)}f=new H(a,f,p,a.g,d,e);Xb(f,l);a.a[k++]=f;f=m+a.g;g-=p}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+dc[d]+" at "+Ca(b)),!0):bc(ec,b,c)}h.Rd=function(a){return this.b[(a&this.i)>>>this.h].tb(a&this.f,a)}; -h.Xb=function(a){var b=a&this.f,c=(a&this.i)>>>this.h;return ib||b!=this.f?this.b[c].W(b,a):this.b[c++].tb(b,a)|this.b[c&this.K].tb(0,a+1)<<8};h.Sd=function(a,b){this.b[(a&this.i)>>>this.h].xb(a&this.f,b,a)};h.Yb=function(a,b){var c=a&this.f,d=(a&this.i)>>>this.h;ib||c!=this.f?this.b[d].Ab(c,b,a):(this.b[d++].xb(c,b&255,a),this.b[d&this.K].xb(0,b>>8&255,a+1))};function fc(a,b){return a.a[(b&a.v)>>>a.h]} -function Ob(a,b){var c;a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?c=e.D(d,b):c=e.i(d,b)|fc(a,b+1).i(0,b+1)<<8;a.m--;return c}function gc(a,b,c){a.l=!1;a.m++;fc(a,b).o(b&a.f,c&255,b);a.m--}function Mb(a,b,c){a.l=!1;a.m++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?e.m(d,c&65535,b):(e.o(d,c&255,b),fc(a,b+1).o(0,c>>8&255,b+1));a.m--} +h.Xb=function(a){var b=a&this.f,c=(a&this.i)>>>this.h;return ib||b!=this.f?this.b[c].W(b,a):this.b[c++].tb(b,a)|this.b[c&this.K].tb(0,a+1)<<8};h.Sd=function(a,b){this.b[(a&this.i)>>>this.h].xb(a&this.f,b,a)};h.Yb=function(a,b){var c=a&this.f,d=(a&this.i)>>>this.h;ib||c!=this.f?this.b[d].Ab(c,b,a):(this.b[d++].xb(c,b&255,a),this.b[d&this.K].xb(0,b>>8&255,a+1))};function fc(a,b){return a.a[(b&a.u)>>>a.h]} +function Ob(a,b){var c;a.m=!1;a.l++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?c=e.D(d,b):c=e.i(d,b)|fc(a,b+1).i(0,b+1)<<8;a.l--;return c}function gc(a,b,c){a.m=!1;a.l++;fc(a,b).o(b&a.f,c&255,b);a.l--}function Mb(a,b,c){a.m=!1;a.l++;var d=b&a.f,e=fc(a,b);ib||d!=a.f?e.l(d,c&65535,b):(e.o(d,c&255,b),fc(a,b+1).o(0,c>>8&255,b+1));a.l--} function ac(a){for(var b=0,c=[],d=0;da.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],v=g[5]||1,y=0;y>8:e[2](f)&255):f&1&&(e=d.Qa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return c;I(d,b,16);return 255} +function sb(a,b){a.F.push(b)}function I(a,b,c){a.m=!0;a.l||(c&&(a.c.F|=c),J(a.c,4,0,b))}function lc(a){var b=a.m;a.m=!1;return b}function bc(a,b,c){u("Memory block error ("+a+": "+Da(b)+","+Da(c)+")");return!1}var Sb=8192,kc=Sb-1,cc=1,ec=2;function Tb(a,b){var c=-1,d=this.controller,e=d.Qa[a],f=b&65535;e?e[0]?c=e[0](f):e[2]&&(c=f&1?e[2](f&-2)>>8:e[2](f)&255):f&1&&(e=d.Qa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return c;I(d,b,16);return 255} function Ub(a,b,c){var d=!1,e=this.controller,f=e.Qa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Qa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d||I(e,c,16)}function Vb(a,b){var c=-1,d=this.controller;a=d.Qa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return c;I(d,b,16);return 65535} -function Wb(a,b,c){var d=!1,e=this.controller;a=e.Qa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d||I(e,c,16)}function K(a){r.call(this,"Device",a,256);this.a={Ia:128,dd:-1}}n(K,r);h=K.prototype;h.ja=function(a,b,c,d){this.u=b;this.A=a;this.c=c;this.D=d;var e=this;this.a.dd=mc(c,function(){e.a.Ia|=128;e.a.Ia&64&&nc(e.c,e.a.qa);e.A&&Kb(e.A,1);oc(e.c,e.a.dd,1E3/60)});this.a.qa=pc(c,64,6,2097152);qb(b,this,qc);sb(b,this.reset.bind(this));B(this)}; +function Wb(a,b,c){var d=!1,e=this.controller;a=e.Qa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d||I(e,c,16)}function K(a){r.call(this,"Device",a,256);this.a={Ia:128,dd:-1}}n(K,r);h=K.prototype;h.ja=function(a,b,c,d){this.v=b;this.A=a;this.c=c;this.D=d;var e=this;this.a.dd=mc(c,function(){e.a.Ia|=128;e.a.Ia&64&&nc(e.c,e.a.qa);e.A&&Kb(e.A,1);oc(e.c,e.a.dd,1E3/60)});this.a.qa=pc(c,64,6,2097152);qb(b,this,qc);sb(b,this.reset.bind(this));B(this)}; h.la=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};h.ka=function(a){return a?this.save():!0};h.reset=function(){this.a.Ia=128;oc(this.c,this.a.dd,1E3/60,!0)};h.save=function(){var a=new E(this);a.set(0,[this.a.Ia]);return a.data()};h.restore=function(a){a=ia(a[0]);this.a.Ia=a.next().value;return!0};h.vf=function(){return this.a.Ia};h.Og=function(a){this.a.Ia=a&192;this.a.Ia&64||(a=this.a.qa)&&rc(this.c,a)};h.xf=function(){return sc(this.c)}; h.Qg=function(a){tc(this.c,a&-129|this.c.J&128)};h.yf=function(){return uc(this.c)};h.zf=function(){return vc(this.c)};h.Af=function(){return this.c.ta};h.Rg=function(a){wc(this.c,a)};h.lg=function(a){a=a>>1&63;var b=this.c.Pa[a>>1];return a&1?b>>16:b&65535};h.Dh=function(a,b){b=b>>1&63;var c=b>>1;this.c.Pa[c]=b&1?this.c.Pa[c]&65535|(a&63)<<16:this.c.Pa[c]&-65536|a&65534};h.eg=function(a){return this.c.s[1][a>>1&7]};h.wh=function(a,b){this.c.s[1][b>>1&7]=a&65295}; h.cg=function(a){return this.c.s[1][(a>>1&7)+8]};h.uh=function(a,b){this.c.s[1][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.c.H[1][a>>1&7]};h.vh=function(a,b){b=b>>1&7;this.c.H[1][b]=a;this.c.s[1][b]&=65295};h.bg=function(a){return this.c.H[1][(a>>1&7)+8]};h.th=function(a,b){b=(b>>1&7)+8;this.c.H[1][b]=a;this.c.s[1][b]&=65295};h.uf=function(a){return this.c.s[0][a>>1&7]};h.Ng=function(a,b){this.c.s[0][b>>1&7]=a&65295};h.sf=function(a){return this.c.s[0][(a>>1&7)+8]}; h.Lg=function(a,b){this.c.s[0][(b>>1&7)+8]=a&65295};h.tf=function(a){return this.c.H[0][a>>1&7]};h.Mg=function(a,b){b=b>>1&7;this.c.H[0][b]=a;this.c.s[0][b]&=65295};h.rf=function(a){return this.c.H[0][(a>>1&7)+8]};h.Kg=function(a,b){b=(b>>1&7)+8;this.c.H[0][b]=a;this.c.s[0][b]&=65295};h.kg=function(a){return this.c.s[3][a>>1&7]};h.Ch=function(a,b){this.c.s[3][b>>1&7]=a&65295};h.ig=function(a){return this.c.s[3][(a>>1&7)+8]};h.Ah=function(a,b){this.c.s[3][(b>>1&7)+8]=a&65295}; h.jg=function(a){return this.c.H[3][a>>1&7]};h.Bh=function(a,b){b=b>>1&7;this.c.H[3][b]=a;this.c.s[3][b]&=65295};h.hg=function(a){return this.c.H[3][(a>>1&7)+8]};h.zh=function(a,b){b=(b>>1&7)+8;this.c.H[3][b]=a;this.c.s[3][b]&=65295};h.vb=function(a){a&=7;return this.c.i&2048?this.c.ua[a]:this.c.b[a]};h.yb=function(a,b){b&=7;this.c.i&2048?this.c.ua[b]=a:this.c.b[b]=a};h.Hf=function(){return this.c.i&49152?this.c.ga[0]:this.c.b[6]};h.Yg=function(a){this.c.i&49152?this.c.ga[0]=a:this.c.b[6]=a}; h.Kf=function(){return this.c.b[7]};h.ah=function(a){this.c.b[7]=a};h.wb=function(a){a&=7;return this.c.i&2048?this.c.b[a]:this.c.ua[a]};h.zb=function(a,b){b&=7;this.c.i&2048?this.c.b[b]=a:this.c.ua[b]=a};h.If=function(){return 1==(this.c.i&49152)>>14?this.c.b[6]:this.c.ga[1]};h.Zg=function(a){1==(this.c.i&49152)>>14?this.c.b[6]=a:this.c.ga[1]=a};h.Jf=function(){return 3==(this.c.i&49152)>>14?this.c.b[6]:this.c.ga[3]};h.$g=function(a){3==(this.c.i&49152)>>14?this.c.b[6]=a:this.c.ga[3]=a}; -h.qf=function(a){return this.c.Rb[a-65504>>1]};h.Jg=function(a,b){this.c.Rb[b-65504>>1]=a};h.Md=function(a){return 65520==a?(hc(this.u)>>6)-1:0};h.Pd=function(){};h.gg=function(){return 1};h.yh=function(){};h.pf=function(){return this.c.F};h.Ig=function(){this.c.F=0};h.wf=function(){return this.c.Ob};h.Pg=function(a,b){b&1||(a&=255);this.c.Ob=a};h.Bf=function(a,b){return b?0:this.c.$a};h.Sg=function(a){var b=this.c;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1);b.g|=1}b.$a=a}; +h.qf=function(a){return this.c.Rb[a-65504>>1]};h.Jg=function(a,b){this.c.Rb[b-65504>>1]=a};h.Md=function(a){return 65520==a?(hc(this.v)>>6)-1:0};h.Pd=function(){};h.gg=function(){return 1};h.yh=function(){};h.pf=function(){return this.c.F};h.Ig=function(){this.c.F=0};h.wf=function(){return this.c.Ob};h.Pg=function(a,b){b&1||(a&=255);this.c.Ob=a};h.Bf=function(a,b){return b?0:this.c.$a};h.Sg=function(a){var b=this.c;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1);b.g|=1}b.$a=a}; h.fg=function(a,b){return b?0:this.c.Oa&65280};h.xh=function(a){this.c.Oa=a|255};h.Gf=function(){return xc(this.c)};h.Xg=function(a){zc(this.c,a)};h.Od=function(){}; var L={},qc=(L[61568]=[null,null,K.prototype.lg,K.prototype.Dh,"UNIMAP",64,1170],L[62592]=[null,null,K.prototype.eg,K.prototype.wh,"SIPDR",8,1145,64],L[62608]=[null,null,K.prototype.cg,K.prototype.uh,"SDPDR",8,1145,64],L[62624]=[null,null,K.prototype.dg,K.prototype.vh,"SIPAR",8,1145,64],L[62640]=[null,null,K.prototype.bg,K.prototype.th,"SDPAR",8,1145,64],L[62656]=[null,null,K.prototype.uf,K.prototype.Ng,"KIPDR",8,1140,64],L[62672]=[null,null,K.prototype.sf,K.prototype.Lg,"KDPDR",8,1145,64],L[62688]= [null,null,K.prototype.tf,K.prototype.Mg,"KIPAR",8,1140,64],L[62704]=[null,null,K.prototype.rf,K.prototype.Kg,"KDPAR",8,1145,64],L[62798]=[null,null,K.prototype.Af,K.prototype.Rg,"MMR3",1,1145,64],L[65382]=[null,null,K.prototype.vf,K.prototype.Og,"LKS"],L[65402]=[null,null,K.prototype.xf,K.prototype.Qg,"MMR0",1,1140,64],L[65404]=[null,null,K.prototype.yf,K.prototype.Od,"MMR1",1,1145,64],L[65406]=[null,null,K.prototype.zf,K.prototype.Od,"MMR2",1,1140,64],L[65408]=[null,null,K.prototype.kg,K.prototype.Ch, @@ -109,182 +109,182 @@ K.prototype.yb,"R4SET0"],L[65477]=[null,null,K.prototype.vb,K.prototype.yb,"R5SE K.prototype.zb,"R4SET1",1,1145],L[65485]=[null,null,K.prototype.wb,K.prototype.zb,"R5SET1",1,1145],L[65486]=[null,null,K.prototype.If,K.prototype.Zg,"R6SUPER",1,1145],L[65487]=[null,null,K.prototype.Jf,K.prototype.$g,"R6USER",1,1145],L[65504]=[null,null,K.prototype.qf,K.prototype.Jg,"CTRL",8,1170],L[65520]=[null,null,K.prototype.Md,K.prototype.Pd,"LSIZE",1,1170],L[65522]=[null,null,K.prototype.Md,K.prototype.Pd,"HSIZE",1,1170],L[65524]=[null,null,K.prototype.gg,K.prototype.yh,"SYSID",1,1170],L[65526]= [null,null,K.prototype.pf,K.prototype.Ig,"ERR",1,1170],L[65528]=[null,null,K.prototype.wf,K.prototype.Pg,"MBR",1,1170],L[65530]=[null,null,K.prototype.Bf,K.prototype.Sg,"PIR"],L[65532]=[null,null,K.prototype.fg,K.prototype.xh,"SLR"],L[65534]=[null,null,K.prototype.Gf,K.prototype.Xg,"PSW"],L); Ya(function(){for(var a=A(document,z,"device"),b=0;b>1),this.c=new Int32Array(this.f,0,this.size>>2),Fc(this,Gc?Hc:Ic);else{a=this.c=Array(this.size>>2);for(f=0;f>2),b=0;b>1),this.c=new Int32Array(this.f,0,this.size>>2),Fc(this,Gc?Hc:Ic);else{a=this.c=Array(this.size>>2);for(f=0;f>2),b=0;b>8,c)};h.mf=function(a){return this.c[a>>2]>>>((a&3)<<3)&255};h.qg=function(a,b){hb&&a&1&&I(this.b,b,64);b=a>>2;a=(a&3)<<3;var c=this.c[b]>>a;return 24>a?c&65535:c&255|(this.c[b+1]&255)<<8}; -h.Gg=function(a,b){var c=a>>2;a=(a&3)<<3;this.c[c]=this.c[c]&~(255<>2;a=(a&3)<<3;24>a?this.c[c]=this.c[c]&~(65535<>8);this.Ha=!0};h.kf=function(a,b){return this.i(a,b)};h.ng=function(a,b){return this.D(a,b)};h.Eg=function(a,b,c){this.A?this.Wb(0,0,c):this.o(a,b,c)};h.Fh=function(a,b,c){this.A?this.Wb(0,0,c):this.m(a,b,c)};h.jf=function(a){return this.a[a]}; -h.lf=function(a){return this.a[a]};h.mg=function(a,b){hb&&a&1&&I(this.b,b,64);return this.u.getUint16(a,!0)};h.pg=function(a,b){hb&&a&1&&I(this.b,b,64);return!ib&&a&1?this.a[a]|this.a[a+1]<<8:this.l[a>>1]};h.Dg=function(a,b){this.a[a]=b;this.Ha=!0};h.Fg=function(a,b){this.a[a]=b;this.Ha=!0};h.Eh=function(a,b,c){hb&&a&1&&I(this.b,c,64);this.u.setUint16(a,b,!0);this.Ha=!0};h.Gh=function(a,b,c){hb&&a&1&&I(this.b,c,64);!ib&&a&1?(this.a[a]=b,this.a[a+1]=b>>8):this.l[a>>1]=b;this.Ha=!0}; +h.Gg=function(a,b){var c=a>>2;a=(a&3)<<3;this.c[c]=this.c[c]&~(255<>2;a=(a&3)<<3;24>a?this.c[c]=this.c[c]&~(65535<>8);this.Ha=!0};h.kf=function(a,b){return this.i(a,b)};h.ng=function(a,b){return this.D(a,b)};h.Eg=function(a,b,c){this.A?this.Wb(0,0,c):this.o(a,b,c)};h.Fh=function(a,b,c){this.A?this.Wb(0,0,c):this.l(a,b,c)};h.jf=function(a){return this.a[a]}; +h.lf=function(a){return this.a[a]};h.mg=function(a,b){hb&&a&1&&I(this.b,b,64);return this.v.getUint16(a,!0)};h.pg=function(a,b){hb&&a&1&&I(this.b,b,64);return!ib&&a&1?this.a[a]|this.a[a+1]<<8:this.m[a>>1]};h.Dg=function(a,b){this.a[a]=b;this.Ha=!0};h.Fg=function(a,b){this.a[a]=b;this.Ha=!0};h.Eh=function(a,b,c){hb&&a&1&&I(this.b,c,64);this.v.setUint16(a,b,!0);this.Ha=!0};h.Gh=function(a,b,c){hb&&a&1&&I(this.b,c,64);!ib&&a&1?(this.a[a]=b,this.a[a+1]=b>>8):this.m[a>>1]=b;this.Ha=!0}; var Dc=0,ic=1,Ec=2,Zb=4,dc=["NONE","RAM","ROM","VID","H/W"],Cc=0,Kc=[],Jc=[H.prototype.mf,H.prototype.Gg,H.prototype.qg,H.prototype.Hh],Nc=[H.prototype.kf,H.prototype.Eg,H.prototype.ng,H.prototype.Fh];if(fb)var Ic=[H.prototype.jf,H.prototype.Dg,H.prototype.mg,H.prototype.Eh],Hc=[H.prototype.lf,H.prototype.Fg,H.prototype.pg,H.prototype.Gh];var Oc;if(fb){var Qc=new ArrayBuffer(2);(new DataView(Qc)).setUint16(0,256,!0);Oc=256===(new Uint16Array(Qc))[0]}else Oc=!1;var Gc=Oc; -function Rc(a,b){r.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.fd=0;this.tc=b;this.Za=c;this.Dc=Math.round(this.tc/1E4)/100;this.jb=this.Dc*this.Za;this.Fc=this.Nb=this.mb=this.uc=0;this.j.M=this.j.cd=!1;this.j.Y=a.autoStart;"string"==typeof this.j.Y&&(this.j.Y="true"==this.j.Y);this.j.gc=!1;this.rc=this.lb=0;this.sc=+a.csStart;this.Lb=+a.csInterval;this.Mb=+a.csStop;this.X=[];this.td=this.vg.bind(this);this.Na=this.Da=this.Ma=this.a=this.ba=this.Ca=this.Kb=this.La=this.nb=this.Gc= -this.Wa=0;this.pa=null;B(this)}n(Rc,r);h=Rc.prototype;h.ja=function(a,b,c,d){this.A=a;this.u=b;this.D=d;this.pa=a.f;for(a=0;a=a.lb&&(a.lb+=a.Lb,c=!0);0<=a.Mb&&a.Mb<=Wc(a)&&(a.Lb=a.Mb=-1,Vc(a),G(a),c=!0);c&&a.aa(Wc(a)+" cycles: checksum="+Da(a.rc))}} -h.ma=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.o[b]=c,!0;case "run":return this.o[b]=c,c.onclick=function(){var a;if(a=d.A)if(a=d.A,a.j.R)a=!0;else{var b=null,c,k=ra(a.id);for(c=0;ca.Wa/a.jb&&(b=1);a.Za=b;b=a.Dc*a.Za;if(a.jb!=b){a.jb=b;b=a.jb.toFixed(2)+"Mhz";var d=a.o.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.A&&$c(a.A)}Ib(a,a.Da);a.Da=0;a.Ca=pa();a.La=0;Yc(a)}function mc(a,b){var c=a.X.length;a.X.push([-1,b]);return c}function oc(a,b,c,d){0<=b&&ba.X[b][0])&&(c=a.tc*a.Za/1E3*c|0,a.j.M&&(c+=ad(a)),a.X[b][0]=c)}function bd(a){for(var b=[],c=0;ca.Wa/a.jb&&(b=1);a.Za=b;b=a.Dc*a.Za;if(a.jb!=b){a.jb=b;b=a.jb.toFixed(2)+"Mhz";var d=a.o.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.A&&$c(a.A)}Ib(a,a.Da);a.Da=0;a.Ca=pa();a.La=0;Yc(a)}function mc(a,b){var c=a.X.length;a.X.push([-1,b]);return c}function oc(a,b,c,d){0<=b&&ba.X[b][0])&&(c=a.tc*a.Za/1E3*c|0,a.j.N&&(c+=ad(a)),a.X[b][0]=c)}function bd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function ad(a,b){var c=a.Ma-=a.a;a.a=a.ba=0;b&&(a.Ma=0);return c} -h.vg=function(){if(this.j.M){this.uc>=this.tc&&Yc(this,!0);this.nb=0;this.Kb=pa();if(this.La){var a=this.Kb-this.La;a>this.Fc&&(this.Ca+=a,this.Ca>this.Kb&&(this.Ca=this.Kb))}try{do{for(var b,c=this.j.gc?1:this.Nb,d=this.X.length-1;0<=d;d--){var e=this.X[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.zc(b)}catch(f){if("number"!=typeof f)throw f;}b=ad(this,!0);this.nb+=b;this.Da+=b;Jb(this,b);Hb(this,b);this.mb-=b;if(0>=this.mb){this.mb+=this.Nb;++this.Gc>=cd&&(this.A&&Kb(this.A,void 0),this.Gc=0);break}}while(this.j.M)}catch(f){G(this); -this.A&&this.A.stop(pa(),Wc(this));a=f.stack||f.message;this.j.error=!0;this.G(a);return}if(this.j.M){a=setTimeout;b=this.td;this.La=pa();c=this.Fc;this.nb&&(c=Math.round(c*this.nb/this.Nb));c-=this.La-this.Kb;if(d=this.La-this.Ca)this.Wa=Math.round(this.Da/(10*d))/100,864E5<=d&&(this.Na=0,Xc(this));if(0>c||this.Wac&&(this.Ca-=c),c=0;this.uc+=this.nb;this.La+=c;a(b,c)}}}; -function Gb(a){var b;a.j.error?(a.aa(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.j.M)a.aa(a.toString()+" busy");else{Xc(a);a.j.M=!0;a.j.cd=!0;if(b=a.o.run)b.textContent="Halt";a.A&&a.A.start(a.Ca,Wc(a));a.D||a.status("Started");setTimeout(a.td,0)}}h.zc=function(){return 0};function G(a){var b=!1;if(a.j.M){ad(a);Ib(a,a.Da);a.Da=0;a.j.M=!1;if(b=a.o.run)b.textContent="Run";a.A&&a.A.stop(pa(),Wc(a));b=!0;a.D||a.status("Stopped")}a.j.complete=void 0;return b}var Zc=30,cd=15,Sc=["power","reset"]; -function dd(a){var b=+a.model||1170;Rc.call(this,a,6666667);this.sa=b;this.od=+a.addrReset||0;this.Ea=this.i=this.B=this.v=this.m=this.l=this.w=0;this.b=this.ua=this.ga=[];this.H=this.s=this.Pa=this.Rb=[];this.Ka=this.C=this.nd=this.kb=this.Xa=this.Ya=this.cb=this.F=this.Ob=this.$a=this.Oa=this.J=this.Pb=this.Qb=this.ta=this.g=0;this.He=[4,2,0,1];this.wc=0;this.sd=255;1120>=this.sa?(this.vd=ed.bind(this),this.hb=this.Pe,this.wc=8,this.sd=-1,this.zd=255,this.wd=0):(this.vd=fd.bind(this),this.hb=this.Qe, +h.vg=function(){if(this.j.N){this.uc>=this.tc&&Yc(this,!0);this.nb=0;this.Kb=pa();if(this.La){var a=this.Kb-this.La;a>this.Fc&&(this.Ca+=a,this.Ca>this.Kb&&(this.Ca=this.Kb))}try{do{for(var b,c=this.j.gc?1:this.Nb,d=this.X.length-1;0<=d;d--){var e=this.X[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.zc(b)}catch(f){if("number"!=typeof f)throw f;}b=ad(this,!0);this.nb+=b;this.Da+=b;Jb(this,b);Hb(this,b);this.mb-=b;if(0>=this.mb){this.mb+=this.Nb;++this.Gc>=cd&&(this.A&&Kb(this.A,void 0),this.Gc=0);break}}while(this.j.N)}catch(f){G(this); +this.A&&this.A.stop(pa(),Wc(this));a=f.stack||f.message;this.j.error=!0;this.G(a);return}if(this.j.N){a=setTimeout;b=this.td;this.La=pa();c=this.Fc;this.nb&&(c=Math.round(c*this.nb/this.Nb));c-=this.La-this.Kb;if(d=this.La-this.Ca)this.Wa=Math.round(this.Da/(10*d))/100,864E5<=d&&(this.Na=0,Xc(this));if(0>c||this.Wac&&(this.Ca-=c),c=0;this.uc+=this.nb;this.La+=c;a(b,c)}}}; +function Gb(a){var b;a.j.error?(a.aa(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.j.N)a.aa(a.toString()+" busy");else{Xc(a);a.j.N=!0;a.j.cd=!0;if(b=a.o.run)b.textContent="Halt";a.A&&a.A.start(a.Ca,Wc(a));a.D||a.status("Started");setTimeout(a.td,0)}}h.zc=function(){return 0};function G(a){var b=!1;if(a.j.N){ad(a);Ib(a,a.Da);a.Da=0;a.j.N=!1;if(b=a.o.run)b.textContent="Run";a.A&&a.A.stop(pa(),Wc(a));b=!0;a.D||a.status("Stopped")}a.j.complete=void 0;return b}var Zc=30,cd=15,Sc=["power","reset"]; +function dd(a){var b=+a.model||1170;Rc.call(this,a,6666667);this.sa=b;this.od=+a.addrReset||0;this.Ea=this.i=this.B=this.u=this.l=this.m=this.w=0;this.b=this.ua=this.ga=[];this.H=this.s=this.Pa=this.Rb=[];this.Ka=this.C=this.nd=this.kb=this.Xa=this.Ya=this.cb=this.F=this.Ob=this.$a=this.Oa=this.J=this.Pb=this.Qb=this.ta=this.g=0;this.He=[4,2,0,1];this.wc=0;this.sd=255;1120>=this.sa?(this.vd=ed.bind(this),this.hb=this.Pe,this.wc=8,this.sd=-1,this.zd=255,this.wd=0):(this.vd=fd.bind(this),this.hb=this.Qe, this.zd=~(1792|(1140>=this.sa?2048:0))&65535,this.wd=1140e.Ub&&(e.Ub=c,c+=4)}return Rc.prototype.la.call(this,a,b)}; -h.reset=function(){this.status("Model "+this.sa);this.j.M&&G(this);this.v=65536;this.m=32768;this.l=65535;this.w=32768;this.i=15;this.b=[0,0,0,0,0,0,0,this.od,-1,-2,-3,-4,-5,-6,-7,-8];this.ua=[0,0,0,0,0,0];this.ga=[0,0,0,0];this.H=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.s=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535,65535, -65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Pa=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.Rb=[0,0,0,0,0,0,0,0];this.B=0;this.Ea=-1;this.h=this.f=this.qc=this.K=this.S=this.g=this.Ob=0;Eb(this);Uc(this);this.j.error=!1;Rc.prototype.reset.call(this)};function Eb(a){a.J=0;a.Pb=0;a.Qb=0;a.ta=0;a.F=0;a.$a=0;a.Oa=255;a.kb=0;a.Xa=0;a.Ya=0;a.cb=262143;a.Ka=a.b[7];a.C=0;a.I=null;a.u&&(gd(a),a.nd=hc(a.u))} -function gd(a){a.kc=a.gd;a.lc=a.xc;a.yc=a.Ac;a.mc=a.Cc;a.kb?(a.Aa=65536,a.jc=a.ta&16?4186112:253952,a.ra=a.Id,a.W=a.Nd,a.Ab=a.Qd,$b(a.u,a.ta&16?22:18)):(a.Aa=0,a.jc=57344,a.ra=a.Ue,a.W=a.og,a.Ab=a.Ih,$b(a.u,16))}function sc(a){var b=a.J;b&57344||(b=b&-3199|a.Xa<<5|a.Ya<<1);return b}function tc(a,b){b&=-3073;if(a.J!=b){b&57344&&!(a.J&57344)&&(a.Pb=a.C>>16&65535,a.Qb=a.C&65535);a.J=b;a.Xa=(b&96)>>5;a.Ya=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.kb!=c&&(a.kb=c,gd(a))}} -function uc(a){a.J&57344||(a.Pb=a.C>>16&65535);a=a.Pb;a&65280&&(a=(a<<8|a>>8)&65535);return a}function vc(a){a.J&57344||(a.Qb=a.C&65535);return a.Qb}function wc(a,b){1170>a.sa&&(b&=-49);a.ta!=b&&(a.ta=b,a.cb=b&16?4194303:262143,gd(a))}function hd(a,b,c,d){a.od=b;F(a,b);zc(a,0);a.u.reset();Eb(a);if(c){a.b[0]=d||0;for(b=1;5>=b;b++)a.b[b]=0;a.b[6]=1024;a.j.R?a.j.M||Gb(a):a.j.Y=!0}else a.D&&a.j.R?G(a)||a.A.j.reset||(a.D.g(),Kb(a.A,-1)):!1===c&&G(a);!a.j.M&&a.pa&&a.pa.stop()}h.Hd=function(){return 0}; +h.reset=function(){this.status("Model "+this.sa);this.j.N&&G(this);this.u=65536;this.l=32768;this.m=65535;this.w=32768;this.i=15;this.b=[0,0,0,0,0,0,0,this.od,-1,-2,-3,-4,-5,-6,-7,-8];this.ua=[0,0,0,0,0,0];this.ga=[0,0,0,0];this.H=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.s=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Pa=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.Rb=[0,0,0,0,0,0,0,0];this.B=0;this.Ea=-1;this.h=this.f=this.qc=this.K=this.S=this.g=this.Ob=0;Eb(this);Uc(this);this.j.error=!1;Rc.prototype.reset.call(this)};function Eb(a){a.J=0;a.Pb=0;a.Qb=0;a.ta=0;a.F=0;a.$a=0;a.Oa=255;a.kb=0;a.Xa=0;a.Ya=0;a.cb=262143;a.Ka=a.b[7];a.C=0;a.I=null;a.v&&(gd(a),a.nd=hc(a.v))} +function gd(a){a.kc=a.gd;a.lc=a.xc;a.yc=a.Ac;a.mc=a.Cc;a.kb?(a.Aa=65536,a.jc=a.ta&16?4186112:253952,a.ra=a.Id,a.W=a.Nd,a.Ab=a.Qd,$b(a.v,a.ta&16?22:18)):(a.Aa=0,a.jc=57344,a.ra=a.Ue,a.W=a.og,a.Ab=a.Ih,$b(a.v,16))}function sc(a){var b=a.J;b&57344||(b=b&-3199|a.Xa<<5|a.Ya<<1);return b}function tc(a,b){b&=-3073;if(a.J!=b){b&57344&&!(a.J&57344)&&(a.Pb=a.C>>16&65535,a.Qb=a.C&65535);a.J=b;a.Xa=(b&96)>>5;a.Ya=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.kb!=c&&(a.kb=c,gd(a))}} +function uc(a){a.J&57344||(a.Pb=a.C>>16&65535);a=a.Pb;a&65280&&(a=(a<<8|a>>8)&65535);return a}function vc(a){a.J&57344||(a.Qb=a.C&65535);return a.Qb}function wc(a,b){1170>a.sa&&(b&=-49);a.ta!=b&&(a.ta=b,a.cb=b&16?4194303:262143,gd(a))}function hd(a,b,c,d){a.od=b;F(a,b);zc(a,0);a.v.reset();Eb(a);if(c){a.b[0]=d||0;for(b=1;5>=b;b++)a.b[b]=0;a.b[6]=1024;a.j.R?a.j.N||Gb(a):a.j.Y=!0}else a.D&&a.j.R?G(a)||a.A.j.reset||(a.D.g(),Kb(a.A,-1)):!1===c&&G(a);!a.j.N&&a.pa&&a.pa.stop()}h.Hd=function(){return 0}; h.save=function(){var a=new E(this);a.set(0,[this.b,this.ua,this.ga,this.H,this.s,this.Pa,this.Rb,this.F,this.Ob,this.$a,this.Oa,this.Xa,this.Ya,this.Ka,this.g,this.C,this.Ea,this.Lc,this.Nc]);a.set(1,[xc(this),sc(this),uc(this),vc(this),this.ta]);a.set(2,[this.Na,this.Za,this.j.Y]);a.set(3,id(this));a.set(4,bd(this));return a.data()}; h.restore=function(a){var b=ia(a[0]);this.b=b.next().value;this.ua=b.next().value;this.ga=b.next().value;this.H=b.next().value;this.s=b.next().value;this.Pa=b.next().value;this.Rb=b.next().value;this.F=b.next().value;this.Ob=b.next().value;this.$a=b.next().value;this.Oa=b.next().value;this.Xa=b.next().value;this.Ya=b.next().value;this.Ka=b.next().value;this.g=b.next().value;this.C=b.next().value;this.Ea=b.next().value;this.Lc=b.next().value;this.Nc=b.next().value;b=a[1];zc(this,b[0]);tc(this,b[1]); -this.Pb=b[2];this.Qb=b[3];wc(this,b[4]);b=a[2];this.Na=b[0];Xc(this,b[1]);this.j.Y=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>23)),a.a-=2);a.a-=3}function F(a,b){a.b[7]=b&65535}function pc(a,b,c,d){b={Ub:b,sb:c,message:d||0,name:kb[b],next:null};a.Ib.push(b);return b}function rc(a,b){var c=a.I;if(c==b)a.I=b.next;else for(;c;){var d=c.next;if(d==b){c.next=d.next;break}c=d}a.I&&(a.g|=1)}function nc(a,b){if(b){if(b!=a.I){var c=a.I;if(!c||c.sb<=b.sb)b.next=c,a.I=b;else{do{var d=c.next;if(!d||d.sb<=b.sb){b.next=d;c.next=b;break}c=d}while(c)}}a.g|=1}} -function id(a){var b=[];for(a=a.I;a;)b.push(a.Ub),a=a.next;return b}function md(a){return a.g&64?(J(a,168,64,-6),!0):a.g&32?(J(a,4,32,-5),!0):a.g&16?(J(a,12,16,-7),!0):!1}function xc(a){return a.i=a.i&63728|kd(a)|(a.l&65535?0:4)|(a.m&32768?2:0)|jd(a)}function zc(a,b){b&=a.zd;a.w=b<<12;a.l=~b&4;a.m=b<<14;a.v=b<<16;if((b^a.i)&a.wd)for(var c=a.ua.length;0<=--c;){var d=a.b[c];a.b[c]=a.ua[c];a.ua[c]=d}a.B=b>>14&3;c=a.i>>14&3;a.B!=c&&(a.ga[c]=a.b[6],a.b[6]=a.ga[a.B]);a.i=b;a.g&=-3;a.g|=a.I?2:1} -h.fa=function(a){this.w=this.l=a;this.m=0};h.Sa=function(a,b){this.w=this.l=this.v=a;this.m=b||0};function nd(a,b){a.w=a.l=a.v=b;a.m=a.w^a.v>>1}function od(a,b,c,d){a.w=a.l=a.v=b;a.m=(c^d)&(d^b)} +function id(a){var b=[];for(a=a.I;a;)b.push(a.Ub),a=a.next;return b}function md(a){return a.g&64?(J(a,168,64,-6),!0):a.g&32?(J(a,4,32,-5),!0):a.g&16?(J(a,12,16,-7),!0):!1}function xc(a){return a.i=a.i&63728|kd(a)|(a.m&65535?0:4)|(a.l&32768?2:0)|jd(a)}function zc(a,b){b&=a.zd;a.w=b<<12;a.m=~b&4;a.l=b<<14;a.u=b<<16;if((b^a.i)&a.wd)for(var c=a.ua.length;0<=--c;){var d=a.b[c];a.b[c]=a.ua[c];a.ua[c]=d}a.B=b>>14&3;c=a.i>>14&3;a.B!=c&&(a.ga[c]=a.b[6],a.b[6]=a.ga[a.B]);a.i=b;a.g&=-3;a.g|=a.I?2:1} +h.fa=function(a){this.w=this.m=a;this.l=0};h.Sa=function(a,b){this.w=this.m=this.u=a;this.l=b||0};function nd(a,b){a.w=a.m=a.u=b;a.l=a.w^a.u>>1}function od(a,b,c,d){a.w=a.m=a.u=b;a.l=(c^d)&(d^b)} function J(a,b,c,d){if(!a.pb){0>a.Ea?a.Ea=xc(a):a.B||(d=-4);-4==d&&(a.g&256&&(d=-1),a.g|=256,a.F|=4,a.b[6]=b=4);if(-1!=d){a.C=b|4143316992;a.B=0;var e=a.W(b|a.Aa),f=a.W(b+2&65535|a.Aa);zc(a,f&-12289|a.Ea>>2&12288);pd(a,a.Ea);pd(a,a.b[7]);F(a,e)}a.a-=5;a.g&=~(c|19);a.g|=129;a.Ea=-1;a.Lc=d;a.Nc=b;-1==d&&G(a);if(-4<=d)throw b;}}function qd(a){var b=rd(a),c=rd(a);a.i&49152&&(c=c&-225|a.i&63712);F(a,b);zc(a,c);a.g&=-17} function sd(a,b){var c=b>>13&31;31>c&&(b=a.ta&32?a.Pa[c]+(b&8191)&4194303:b&-3932161);return b} function Nb(a,b,c){var d,e,f;if(!(c&a.kb))return f=b&65535,57344<=f&&(f|=a.jc),f;d=b>>13;a.ta&a.He[a.B]||(d&=7);e=a.s[a.B][d];f=(a.H[a.B][d]<<6)+(b&8191)&a.cb;3932160<=f&&(f=sd(a,f));if(a.pb)return f;f>=a.nd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& (g|=16384));a.s[a.B][d]=e;if(f!=(4194170&a.cb)||a.B)a.Xa=a.B,a.Ya=d;g&&(g&57344&&(0<=a.Ea&&(g|=128),a.J&57344||(g|=a.J&4096|a.Xa<<5|a.Ya<<1,tc(a,a.J&-61695|g&61694)),J(a,168,64,-2)),a.J&61440||!(f<(4191360&a.cb)||f>(4194239&a.cb))||(a.J|=4096,a.J&512&&(a.g|=64)));return f}function rd(a){var b=a.W(a.b[6]|a.Aa);a.b[6]=a.b[6]+2&65535;return b}function pd(a,b){var c=a.b[6]-2&65535;a.b[6]=c;a.C=a.C&65535|(a.C&-65536)<<8|16121856;a.g&256||a.hb(4,-2,c);a.Ab(c,b)} function td(a,b,c,d){var e,f,g=d&8?0:a.Aa;switch(b){case 0:return J(a,4,0,-3),0;case 1:return 6==c&&a.hb(d,0,a.b[6]),a.a-=3,7==c?a.b[c]:a.b[c]|g;case 2:f=2;e=a.b[c];6==c&&a.hb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.a-=3;break;case 3:f=2;e=a.b[c];7!=c&&(e|=g);e=a.W(e);e|=g;a.a-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.b[c]+f&65535;6==c&&a.hb(d,f,e);7!=c&&(e|=g);a.a-=4;break;case 5:f=-2;e=a.b[c]-2&65535;7!=c&&(e|=g);e=a.W(e)|g;a.a-=8;break;case 6:return e=a.W(ld(a,2)),e=e+a.b[c]&65535,6==c&&a.hb(d,0, e),a.a-=6,e|g;case 7:return e=a.W(ld(a,2)),e=e+a.b[c]&65535,e=a.W(e|a.Aa),a.a-=10,e|g}a.b[c]=a.b[c]+f&65535;a.C=a.C&65535|(a.C&-65536)<<8|(f<<3&248|c)<<16;return e}h.Pe=function(a,b,c){!this.B&&0>=b&&c<=this.Oa&&(this.g|=32)};h.Qe=function(a,b,c){this.B||(65534<=c&&(c|=-65536),a&4&&c<=this.Oa&&(c<=this.Oa-32?J(this,4,0,-4):(this.F|=8,this.g|=32)))};h.Te=function(a){return this.gd(a)};h.Ve=function(a){return this.xc(a)};h.xg=function(a,b){this.Ac(a,b)};h.Ag=function(a,b){this.Cc(a,b)}; -h.Ue=function(a,b,c){return td(this,a,b,c)};h.Id=function(a,b,c){return Nb(this,td(this,a,b,c),c)};h.og=function(a){return this.u.Xb(this.Ka=a)};h.Nd=function(a){return this.u.Xb(this.Ka=Nb(this,a,2))};h.Ih=function(a,b){this.u.Yb(this.Ka=a,b)};h.Qd=function(a,b){this.u.Yb(this.Ka=Nb(this,a,4),b)}; +h.Ue=function(a,b,c){return td(this,a,b,c)};h.Id=function(a,b,c){return Nb(this,td(this,a,b,c),c)};h.og=function(a){return this.v.Xb(this.Ka=a)};h.Nd=function(a){return this.v.Xb(this.Ka=Nb(this,a,2))};h.Ih=function(a,b){this.v.Yb(this.Ka=a,b)};h.Qd=function(a,b){this.v.Yb(this.Ka=Nb(this,a,4),b)}; function ud(a,b,c){var d=a.f=b&7;(b=a.h=(b&56)>>3)?(d=td(a,b,d,2),c&65536||61440!==(a.i&61440)&&(d&=65535),a.B=a.i>>12&3,c=a.W(d|c&a.Aa),a.B=a.i>>14&3):c=6!=d||(a.i>>2&12288)===(a.i&12288)?a.b[d]:a.ga[a.i>>12&3];return c}function vd(a,b,c,d){a.C=a.C&65535|1441792;var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=td(a,b,e,4),c&65536||(e&=65535),a.B=a.i>>12&3,e=Nb(a,e|c&65536,4),a.B=a.i>>14&3,a.mc(e,d)):6!=e||(a.i>>2&12288)===(a.i&12288)?a.b[e]=d:a.ga[a.i>>12&3]=d} function wd(a,b){b>>=6;var c=a.S=b&7;return(b=a.K=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c+a.wc]&a.sd}function xd(a,b){var c;b>>=6;var d=a.S=b&7;(b=a.K=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d+a.wc];return c}function yd(a,b){var c=a.f=b&7;b=a.h=(b&56)>>3;return td(a,b,c,8)}function zd(a,b){var c=a.f=b&7;return(b=a.h=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c]&255}function Ad(a,b){var c,d=a.f=b&7;(b=a.h=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d];return c} function P(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.qc=a.ra(b,e,7),c=0>c?a.b[-c-1]&255:c,a.yc(e,d.call(a,c,a.kc(e))),e&1&&a.a--):(b=a.b[e],c=0>c?a.b[-c-1]&255:c,a.b[e]=b&65280|d.call(a,c,b&255))}function Q(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,6),a.mc(e,d.call(a,0>c?a.b[-c-1]:c,a.lc(e)))):a.b[e]=d.call(a,0>c?a.b[-c-1]:c,a.b[e])} function Bd(a,b,c,d,e){var f=a.f=b&7;(b=a.h=(b&56)>>3)?(d=a.ra(b,f,5),e.call(a,(c=0>c?a.b[-c-1]&255:c)<<8),a.yc(d,c),d&1&&a.a--):(c?(c=0>c?a.b[-c-1]&255:c,a.b[f]=a.b[f]&~d|c<<24>>24&d):a.b[f]&=~d,e.call(a,c<<8))}function Cd(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,4),d.call(a,c=0>c?a.b[-c-1]:c),a.mc(e,c)):(a.b[e]=c=0>c?a.b[-c-1]:c,d.call(a,c))} h.zc=function(a){this.j.complete=!0;var b=a?this.j.cd?0:1:-1;this.j.cd=!1;this.Ma=this.a=a;this.g=this.g&-5|0;do{if(this.g){if(a=this.g&11)if(a=!1,this.g&2){var c=160,d=(this.$a&224)>>5,e=this.I&&this.I.sb>d?this.I:null;e&&(c=e.Ub,d=e.sb);d>(this.i&224)>>5?(this.g&8&&(ld(this,2),this.g&=-9),J(this,c,0,-10),d=!0):d=!1;d&&(e&&rc(this,e),a=!0);this.I||this.$a||(this.g&=-3)}else this.g&1&&this.g++;if(a){if(this.g&4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}if(this.g&112&&md(this)){if(this.g& -4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.vd(e)}while(0>1|b<<16;nd(this,a);return a&65535}function Id(a,b){a=b&128|b>>1|b<<8;nd(this,a<<8);return a&255}function Jd(a,b){a=b&~a;this.fa(a);return a}function Kd(a,b){a=b&~a;this.fa(a<<8);return a}function Ld(a,b){a|=b;this.fa(a);return a}function Md(a,b){a|=b;this.fa(a<<8);return a} -function Nd(a,b){a=~b|65536;this.Sa(a);return a&65535}function Od(a,b){a=~b|256;this.Sa(a<<8);return a&255}function Pd(a,b){this.w=this.l=a=b-a;this.m=b&(b^a);return a&65535}function Qd(a,b){a=b-a;var c=a<<8;b<<=8;this.w=this.l=c;this.m=b&(b^c);return a&255}function Rd(a,b){this.w=this.l=a=b+a;this.m=a&(b^a);return a&65535}function Sd(a,b){a=b+a;var c=a<<8;this.w=this.l=c;this.m=c&(b<<8^c);return a&255}function Td(a,b){a=-b;this.Sa(a,a&b&32768);return a&65535} -function Ud(a,b){a=-b;this.Sa(a<<8,(a&b&128)<<8);return a&255}function Vd(a,b){a=b<<1|this.v>>16&1;nd(this,a);return a&65535}function Wd(a,b){a=b<<1|this.v>>16&1;nd(this,a<<8);return a&255}function Xd(a,b){a=(this.v&65536|b)>>1|b<<16;nd(this,a);return a&65535}function Yd(a,b){a=((this.v&65536)>>8|b)>>1|b<<8;nd(this,a<<8);return a&255}function Zd(a,b){var c=b-a;od(this,c,a,b);return c&65535}function $d(a,b){var c=b-a;od(this,c<<8,a<<8,b<<8);return c&255} -function ae(a,b){this.w=this.l=b&65280;this.m=this.v=0;return(b<<8|b>>8)&65535}function be(a,b){a^=b;this.fa(a);return a&65535}function ce(a){Q(this,a,xd(this,a),Dd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)} -function de(a){var b=Ad(this,a);a=a>>6&7;var c=this.b[a];c&32768&&(c|=4294901760);this.v=this.m=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.m=32768)}this.b[a]=c&65535;this.w=this.l=c;this.a-=(this.h?6:7)+b} -function ee(a){var b=Ad(this,a);a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.v=this.m=0;b&=63;if(b&32){b=64-b;32>b-1;this.v=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.b[a|1]=d&65535;this.w=d>>16;this.l=d>>16|d;this.a-=(this.h?6:7)+b}function fe(a){O(this,a,!jd(this))}function ge(a){O(this,a,jd(this))} +4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.vd(e)}while(0>1|b<<16;nd(this,a);return a&65535}function Id(a,b){a=b&128|b>>1|b<<8;nd(this,a<<8);return a&255}function Jd(a,b){a=b&~a;this.fa(a);return a}function Kd(a,b){a=b&~a;this.fa(a<<8);return a}function Ld(a,b){a|=b;this.fa(a);return a}function Md(a,b){a|=b;this.fa(a<<8);return a} +function Nd(a,b){a=~b|65536;this.Sa(a);return a&65535}function Od(a,b){a=~b|256;this.Sa(a<<8);return a&255}function Pd(a,b){this.w=this.m=a=b-a;this.l=b&(b^a);return a&65535}function Qd(a,b){a=b-a;var c=a<<8;b<<=8;this.w=this.m=c;this.l=b&(b^c);return a&255}function Rd(a,b){this.w=this.m=a=b+a;this.l=a&(b^a);return a&65535}function Sd(a,b){a=b+a;var c=a<<8;this.w=this.m=c;this.l=c&(b<<8^c);return a&255}function Td(a,b){a=-b;this.Sa(a,a&b&32768);return a&65535} +function Ud(a,b){a=-b;this.Sa(a<<8,(a&b&128)<<8);return a&255}function Vd(a,b){a=b<<1|this.u>>16&1;nd(this,a);return a&65535}function Wd(a,b){a=b<<1|this.u>>16&1;nd(this,a<<8);return a&255}function Xd(a,b){a=(this.u&65536|b)>>1|b<<16;nd(this,a);return a&65535}function Yd(a,b){a=((this.u&65536)>>8|b)>>1|b<<8;nd(this,a<<8);return a&255}function Zd(a,b){var c=b-a;od(this,c,a,b);return c&65535}function $d(a,b){var c=b-a;od(this,c<<8,a<<8,b<<8);return c&255} +function ae(a,b){this.w=this.m=b&65280;this.l=this.u=0;return(b<<8|b>>8)&65535}function be(a,b){a^=b;this.fa(a);return a&65535}function ce(a){Q(this,a,xd(this,a),Dd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)} +function de(a){var b=Ad(this,a);a=a>>6&7;var c=this.b[a];c&32768&&(c|=4294901760);this.u=this.l=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.l=32768)}this.b[a]=c&65535;this.w=this.m=c;this.a-=(this.h?6:7)+b} +function ee(a){var b=Ad(this,a);a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.u=this.l=0;b&=63;if(b&32){b=64-b;32>b-1;this.u=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.b[a|1]=d&65535;this.w=d>>16;this.m=d>>16|d;this.a-=(this.h?6:7)+b}function fe(a){O(this,a,!jd(this))}function ge(a){O(this,a,jd(this))} function he(a){Q(this,a,xd(this,a),Jd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function ie(a){P(this,a,wd(this,a),Kd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function je(a){Q(this,a,xd(this,a),Ld);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function ke(a){P(this,a,wd(this,a),Md);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)} -function le(a){var b=xd(this,a);a=Ad(this,a);this.fa((0>b?this.b[-b-1]:b)&a);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function me(a){var b=wd(this,a);a=zd(this,a);this.fa(((0>b?this.b[-b-1]&255:b)&a)<<8);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function ne(a){O(this,a,this.l&65535?0:4)}function oe(a){O(this,a,!kd(this)==!(this.m&32768))}function pe(a){O(this,a,!!(this.l&65535)&&!kd(this)==!(this.m&32768))} -function qe(a){O(this,a,!jd(this)&&!!(this.l&65535))}function re(a){O(this,a,(this.l&65535?0:4)||!kd(this)!=!(this.m&32768))}function se(a){O(this,a,jd(this)||(this.l&65535?0:4))}function te(a){O(this,a,!kd(this)!=!(this.m&32768))}function ue(a){O(this,a,kd(this))}function ve(a){O(this,a,!!(this.l&65535))}function we(a){O(this,a,!kd(this))}function xe(){J(this,12,0,-9)}function ye(a){O(this,a,!0)}function ze(a){O(this,a,!(this.m&32768))}function Ae(a){O(this,a,this.m&32768?2:0)} -function Be(a){a&1&&(this.v=0);a&2&&(this.m=0);a&4&&(this.l=1);a&8&&(this.w=0);this.a-=5}function Ce(a){var b=xd(this,a);a=Ad(this,a);var c=(b=0>b?this.b[-b-1]:b)-a;od(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function De(a){var b=wd(this,a);a=zd(this,a);var c=(b=(0>b?this.b[-b-1]&255:b)<<8)-(a<<=8);od(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)} -function Ee(a){var b=Ad(this,a);if(b){a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.v=this.m=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.b[a]=d&65535,this.b[a|1]=c-d*b&65535,this.l=d>>16|d,this.w=d>>16):(this.m=32768,this.l=d>>15|d,this.w=c>>16,-1===b&&65534===this.b[a]&&(this.b[a]=this.b[a|1]=1));this.a-=53}else this.l=this.w=0,this.m=32768,this.v=65536,this.a-=7}function Fe(){J(this,24,0,-9);this.a-=20} +function le(a){var b=xd(this,a);a=Ad(this,a);this.fa((0>b?this.b[-b-1]:b)&a);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function me(a){var b=wd(this,a);a=zd(this,a);this.fa(((0>b?this.b[-b-1]&255:b)&a)<<8);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function ne(a){O(this,a,this.m&65535?0:4)}function oe(a){O(this,a,!kd(this)==!(this.l&32768))}function pe(a){O(this,a,!!(this.m&65535)&&!kd(this)==!(this.l&32768))} +function qe(a){O(this,a,!jd(this)&&!!(this.m&65535))}function re(a){O(this,a,(this.m&65535?0:4)||!kd(this)!=!(this.l&32768))}function se(a){O(this,a,jd(this)||(this.m&65535?0:4))}function te(a){O(this,a,!kd(this)!=!(this.l&32768))}function ue(a){O(this,a,kd(this))}function ve(a){O(this,a,!!(this.m&65535))}function we(a){O(this,a,!kd(this))}function xe(){J(this,12,0,-9)}function ye(a){O(this,a,!0)}function ze(a){O(this,a,!(this.l&32768))}function Ae(a){O(this,a,this.l&32768?2:0)} +function Be(a){a&1&&(this.u=0);a&2&&(this.l=0);a&4&&(this.m=1);a&8&&(this.w=0);this.a-=5}function Ce(a){var b=xd(this,a);a=Ad(this,a);var c=(b=0>b?this.b[-b-1]:b)-a;od(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function De(a){var b=wd(this,a);a=zd(this,a);var c=(b=(0>b?this.b[-b-1]&255:b)<<8)-(a<<=8);od(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)} +function Ee(a){var b=Ad(this,a);if(b){a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.u=this.l=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.b[a]=d&65535,this.b[a|1]=c-d*b&65535,this.m=d>>16|d,this.w=d>>16):(this.l=32768,this.m=d>>15|d,this.w=c>>16,-1===b&&65534===this.b[a]&&(this.b[a]=this.b[a|1]=1));this.a-=53}else this.m=this.w=0,this.l=32768,this.u=65536,this.a-=7}function Fe(){J(this,24,0,-9);this.a-=20} function Ge(){this.i&49152?(this.F|=128,J(this,4,0,-8)):(this.pa&&1120==this.sa&&this.pa.setData(this.b[0],!0),this.D?this.D.i():G(this));this.a-=7}function He(){J(this,16,0,-9);this.a-=20}var Ie=[0,7,7,10,7,11,9,13];function Je(a){this.ba=this.a;F(this,yd(this,a));this.a=this.ba-Ie[this.h]}var Ke=[0,14,14,17,14,18,16,20];function Le(a){this.ba=this.a;var b=yd(this,a);a=a>>6&7;pd(this,this.b[a]);this.b[a]=this.b[7];F(this,b);this.a=this.ba-Ke[this.h]} var Me=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Ne(a){var b=xd(this,a);this.ba=this.a;Cd(this,a,b,this.fa);this.a=this.ba-Me[(this.K?8:0)+this.h]+(7!=this.f||this.h?0:2)}function Oe(a){var b=wd(this,a);Bd(this,a,b,65535,this.fa);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}var Pe=[7,13,13,17,14,18,17,21]; -function Qe(a){var b=Ad(this,a);a=a>>6&7;b=(b<<16>>16)*(this.b[a]<<16>>16);this.b[a]=b>>16&65535;this.b[a|1]=b&65535;b|=0;this.w=b>>16;this.l=this.w|b;this.m=0;this.v=-32768>b||32767>6;if(this.b[b]=this.b[b]-1&65535)F(this,this.b[7]-((a&63)<<1)),this.a+=1;this.a-=6}function Xe(a){Q(this,a,xd(this,a),Zd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function Ye(a){Q(this,a,0,ae);this.a-=this.h?9:3+(7==this.f?2:0)}function Ze(){J(this,28,0,-9)} +function Qe(a){var b=Ad(this,a);a=a>>6&7;b=(b<<16>>16)*(this.b[a]<<16>>16);this.b[a]=b>>16&65535;this.b[a|1]=b&65535;b|=0;this.w=b>>16;this.m=this.w|b;this.l=0;this.u=-32768>b||32767>6;if(this.b[b]=this.b[b]-1&65535)F(this,this.b[7]-((a&63)<<1)),this.a+=1;this.a-=6}function Xe(a){Q(this,a,xd(this,a),Zd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function Ye(a){Q(this,a,0,ae);this.a-=this.h?9:3+(7==this.f?2:0)}function Ze(){J(this,28,0,-9)} function $e(){this.pa&&(this.pa.U=this.b[7],this.pa.setData(this.b[0],!0));this.g|=8;ld(this,-2);this.a-=3}function af(a){Q(this,a,this.b[(a>>6&7)+this.wc],be);this.a-=this.h?9:3+(7==this.f?2:0)}function R(){J(this,8,0,-9)}function ed(a){bf[a>>12].call(this,a)}function cf(a){df[a>>6&3].call(this,a)}function ef(a){ff[a>>6&3].call(this,a)}function gf(a){hf[a>>6&3].call(this,a)}function jf(a){kf[a&15].call(this,a)}function lf(a){mf[a&15].call(this,a)}function nf(a){of[a>>6&3].call(this,a)} function pf(a){qf[a>>6&3].call(this,a)}function rf(a){sf[a>>6&3].call(this,a)} var bf=[function(a){tf[a>>8&15].call(this,a)},Ne,Ce,le,he,je,ce,R,function(a){uf[a>>8&15].call(this,a)},Oe,De,me,ie,ke,Xe,R],tf=[function(a){vf[a>>4&15].call(this,a)},ye,ve,ne,oe,te,pe,re,Le,Le,cf,ef,gf,R,R,R],df=[function(a){Cd(this,a,0,this.Sa);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Nd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,Rd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,Pd);this.a-=this.h?9:3+(7==this.f?2:0)}],ff=[function(a){Q(this,a,0,Td); this.a-=this.h?11:6},function(a){Q(this,a,jd(this)?1:0,Dd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,jd(this)?1:0,Zd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){a=Ad(this,a);this.Sa(a);this.a-=this.h?4:3+(7==this.f?2:0)}],hf=[function(a){Q(this,a,0,Xd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Vd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Hd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Fd);this.a-=this.h?9:3+(7==this.f?2:0)}],vf= -[function(a){wf[a&15].call(this,a)},R,R,R,Je,Je,Je,Je,Te,R,jf,lf,Ye,Ye,Ye,Ye],wf=[Ge,$e,Ue,xe,He,Se,R,R,R,R,R,R,R,R,R,R],kf=[Re,function(){this.v=0;this.a-=5},function(){this.m=0;this.a-=5},Be,function(){this.l=1;this.a-=5},Be,Be,Be,function(){this.w=0;this.a-=5},Be,Be,Be,Be,Be,Be,Be],mf=[Re,function(){this.v=65536;this.a-=5},function(){this.m=32768;this.a-=5},Ve,function(){this.l=0;this.a-=5},Ve,Ve,Ve,function(){this.w=32768;this.a-=5},Ve,Ve,Ve,Ve,Ve,Ve,Ve],uf=[we,ue,qe,se,ze,Ae,fe,ge,Fe,Ze,nf,pf, +[function(a){wf[a&15].call(this,a)},R,R,R,Je,Je,Je,Je,Te,R,jf,lf,Ye,Ye,Ye,Ye],wf=[Ge,$e,Ue,xe,He,Se,R,R,R,R,R,R,R,R,R,R],kf=[Re,function(){this.u=0;this.a-=5},function(){this.l=0;this.a-=5},Be,function(){this.m=1;this.a-=5},Be,Be,Be,function(){this.w=0;this.a-=5},Be,Be,Be,Be,Be,Be,Be],mf=[Re,function(){this.u=65536;this.a-=5},function(){this.l=32768;this.a-=5},Ve,function(){this.m=0;this.a-=5},Ve,Ve,Ve,function(){this.w=32768;this.a-=5},Ve,Ve,Ve,Ve,Ve,Ve,Ve],uf=[we,ue,qe,se,ze,Ae,fe,ge,Fe,Ze,nf,pf, rf,R,R,R],of=[function(a){Bd(this,a,0,255,this.Sa);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,0,Od);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,1,Sd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,1,Qd);this.a-=this.h?9:3+(7==this.f?2:0)}],qf=[function(a){P(this,a,0,Ud);this.a-=this.h?11:6},function(a){P(this,a,jd(this)?1:0,Ed);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,jd(this)?1:0,$d);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){a=zd(this,a); this.Sa(a<<8);this.a-=this.h?4:3+(7==this.f?2:0)}],sf=[function(a){P(this,a,0,Yd);this.a-=this.h?9+(this.qc&1):3+(7==this.f?2:0)},function(a){P(this,a,0,Wd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,0,Id);this.a-=this.h?9+(this.qc&1):3+(7==this.f?2:0)},function(a){P(this,a,0,Gd);this.a-=this.h?9:3+(7==this.f?2:0)}];function fd(a){xf[a>>12].call(this,a)} var xf=[function(a){yf[a>>8&15].call(this,a)},Ne,Ce,le,he,je,ce,function(a){zf[a>>8&15].call(this,a)},function(a){Af[a>>8&15].call(this,a)},Oe,De,me,ie,ke,Xe,R],yf=[function(a){Bf[a>>4&15].call(this,a)},ye,ve,ne,oe,te,pe,re,Le,Le,cf,ef,gf,function(a){Cf[a>>6&3].call(this,a)},R,R],Cf=[function(a){a=this.b[7]+((a&63)<<1)&65535;var b=this.W(a|this.Aa);F(this,this.b[5]);this.b[6]=a+2&65535;this.b[5]=b;this.a-=8},function(a){a=ud(this,a,0);this.fa(a);pd(this,a);this.a-=11},function(a){var b=rd(this);this.ba= this.a;this.fa(b);vd(this,a,0,b);this.a=this.ba-Pe[this.h]},function(a){Cd(this,a,kd(this)?65535:0,this.fa);this.a-=this.h?9:3+(7==this.f?2:0)}],Bf=[function(a){Df[a&15].call(this,a)},R,R,R,Je,Je,Je,Je,Te,function(a){!(a&8)||1145>this.sa?J(this,8,0,-9):(this.i&49152||(this.i=this.i&-225|(a&7)<<5,this.g|=1,this.g&=-3),this.a-=5)},jf,lf,Ye,Ye,Ye,Ye],Df=[Ge,$e,function(){qd(this);this.g|=this.i&16;this.a-=13},xe,He,Se,Ue,function(){J(this,8,0,-9)},R,R,R,R,R,R,R,R],zf=[Qe,Qe,Ee,Ee,de,de,ee,ee,af,af,R, R,R,R,We,We],Af=[we,ue,qe,se,ze,Ae,fe,ge,Fe,Ze,nf,pf,rf,function(a){1145>this.sa?J(this,8,0,-9):Ef[a>>6&3].call(this,a)},R,R],Ef=[function(){J(this,8,0,-9)},function(a){a=ud(this,a,65536);this.fa(a);pd(this,a);this.a-=11},function(a){var b=rd(this);this.ba=this.a;this.fa(b);vd(this,a,65536,b);this.a=this.ba-Pe[this.h]},function(){J(this,8,0,-9)}]; -function Ff(a){r.call(this,"ROM",a,128);this.ia=this.b=null;this.h=+a.addr;this.a=+a.size;this.i=!1;this.f=a.alias;"string"==typeof this.f&&(this.f=eval(this.f));this.g=a.file;this.m=Ea(this.g);if(this.g){a=this.g;var b=Fa(this.m);"json"!=b&&"hex"!=b&&(a=Oa()+"/api/v1/dump?file="+this.g+"&format=bytes&decimal=true");var c=this;Ma(a,null,!0,function(a,b,f){f?(c.G("Unable to load ROM resource (error "+f+": "+a+")"),c.g=null):(na(c.Ua,a,b),(a=Na(a,b))?(c.b=a.N,c.ia=a.ia):c.g=null);Gf(c)})}}n(Ff,r); -h=Ff.prototype;h.ja=function(a,b,c,d){this.u=b;this.c=c;this.D=d;Gf(this)};h.la=function(){this.ia&&(this.D&&this.D.a(this.id,this.h,this.a,this.ia),delete this.ia);return!0};h.ka=function(){return!0}; -function Gf(a){if(!za(a)){if(a.g){if(!a.b||!a.u)return;a.a||(a.a=a.b.length);if(a.b.length!=a.a){var b="ROM size ("+Da(a.b.length,8,!0)+") does not match specified size ("+Da(a.a,8,!0)+")";a.j.error=!0;a.G(b)}else{a:{b=a.h;if(57344<=b&&b<57344+Sb){var c={},c=(c[b]=[Ff.prototype.Zf,Ff.prototype.qh,null,null,null,a.a>>1],c);if(qb(a.u,a,c)){a.status("Added "+a.a+"-byte ROM at "+Ca(b));b=a.i=!0;break a}}else if(Yb(a.u,b,a.a,Ec)){for(c=0;c>>f.h;0>>=f.h;0>>a.h;0=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,q=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=l,y=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(y)for(;y--;)gc(a.u,q++,b[v++]&255);else q&1?g=!0:null==d&&(d=q);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e< -b.length;e++)gc(a.u,c+e,b[e]);k=!0}if(k){if(null==d||g)G(a.c),f=!1;null!=d&&hd(a.c,d,f)}return k}Ya(function(){for(var a=A(document,z,"ram"),b=0;b>1],c);if(qb(a.v,a,c)){a.status("Added "+a.a+"-byte ROM at "+Ca(b));b=a.i=!0;break a}}else if(Yb(a.v,b,a.a,Ec)){for(c=0;c>>f.h;0>>=f.h;0>>a.h;0=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,q=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=l,y=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(y)for(;y--;)gc(a.v,q++,b[v++]&255);else q&1?g=!0:null==d&&(d=q);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e< +b.length;e++)gc(a.v,c+e,b[e]);k=!0}if(k){if(null==d||g)G(a.c),f=!1;null!=d&&hd(a.c,d,f)}return k}Ya(function(){for(var a=A(document,z,"ram"),b=0;b=la.hd&&c<=la.Ke&&(b=c-(la.hd-la.Ud));b&&(a.preventDefault&&a.preventDefault(),d.nc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.Wd&&(b=la.Vd);d.nc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.nc(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1}; -h.ja=function(a,b,c,d){this.A=a;this.u=b;this.c=c;this.D=d;var e=this;this.H=pc(this.c,this.B?-1:48,4,1048576);this.I=mc(this.c,function(){var a;a=-1;e.f.length&&(a=e.f.shift()&255,e.w&&97<=a&&122>a&&(a-=32),oc(e.c,e.I,1E3/Math.round(e.J/10)));0<=a&&(e.l=a,e.a&128?e.l|=49152:e.a|=128,e.a&64&&nc(c,e.H))});this.C=pc(this.c,this.B?-1:52,4,1048576);this.X=mc(this.c,function(){e.b|=128;e.b&64&&nc(c,e.C)});qb(b,this,Nf,this.B?64832+8*(this.B-1)-65392:0);sb(b,this.reset.bind(this));B(this)}; -h.Jd=function(a){if(!this.g){var b=Tc(this.A,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ja(c[0]);if(d!=this.ib)return;c=Ja(c[1]);if(this.g=sa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.v);if(this.s=e.receiveData){this.v=a;this.F=e.receiveStatus;this.status("Connected "+this.Ua+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};h.la=function(a,b){if(!b)if(this.Jd(this.v),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -h.ka=function(a){return a?this.save():!0};h.reset=function(){Of(this)};h.save=function(){var a=new E(this);a.set(0,[this.l,this.a,this.b,this.f]);return a.data()};h.restore=function(a){return Of(this,a[0])};function Of(a,b){b||(b=[0,8192,128,a.f]);b=ia(b);a.l=b.next().value;a.a=b.next().value;a.b=b.next().value;a.f=b.next().value;return!0} +h.ja=function(a,b,c,d){this.A=a;this.v=b;this.c=c;this.D=d;var e=this;this.H=pc(this.c,this.B?-1:48,4,1048576);this.I=mc(this.c,function(){var a;a=-1;e.f.length&&(a=e.f.shift()&255,e.w&&97<=a&&122>a&&(a-=32),oc(e.c,e.I,1E3/Math.round(e.J/10)));0<=a&&(e.m=a,e.a&128?e.m|=49152:e.a|=128,e.a&64&&nc(c,e.H))});this.C=pc(this.c,this.B?-1:52,4,1048576);this.X=mc(this.c,function(){e.b|=128;e.b&64&&nc(c,e.C)});qb(b,this,Nf,this.B?64832+8*(this.B-1)-65392:0);sb(b,this.reset.bind(this));B(this)}; +h.Jd=function(a){if(!this.g){var b=Tc(this.A,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ja(c[0]);if(d!=this.ib)return;c=Ja(c[1]);if(this.g=sa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.s=e.receiveData){this.u=a;this.F=e.receiveStatus;this.status("Connected "+this.Ua+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};h.la=function(a,b){if(!b)if(this.Jd(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +h.ka=function(a){return a?this.save():!0};h.reset=function(){Of(this)};h.save=function(){var a=new E(this);a.set(0,[this.m,this.a,this.b,this.f]);return a.data()};h.restore=function(a){return Of(this,a[0])};function Of(a,b){b||(b=[0,8192,128,a.f]);b=ia(b);a.m=b.next().value;a.a=b.next().value;a.b=b.next().value;a.f=b.next().value;return!0} h.nc=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.S||8,c=a-this.m%a,this.S&&(b=" ".slice(0,c)));this.K&&!this.m&&c&&(b=String.fromCharCode(this.K)+b);this.h.value+=b;this.h.scrollTop=this.h.scrollHeight;this.m+=c}}else if(null!= +h.Mf=function(){var a=this.a&65534;this.a&=-32769;return a};h.dh=function(a){var b=a^this.a;this.a=this.a&-112|a&111;this.F&&b&6&&(b=0,b=this.u?b|(a&4?32:0)|(a&2?320:0):b|(a&4?16:0)|(a&2?1048576:0),this.F.call(this.g,b))};h.Lf=function(){this.a&=-129;return this.m};h.bh=function(){};h.sg=function(){return this.b};h.Kh=function(a){if(this.b&128)if(a&64)nc(this.c,this.C);else{var b=this.C;b&&rc(this.c,b)}this.b=this.b&-70|a&69};h.rg=function(){return 0}; +h.Jh=function(a){a&=255;this.s&&this.s.call(this.g,a);a&=127;if(this.h)if(13==a)this.l=0;else if(8==a)this.h.value=this.h.value.slice(0,-1),0":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.S||8,c=a-this.l%a,this.S&&(b=" ".slice(0,c)));this.K&&!this.l&&c&&(b=String.fromCharCode(this.K)+b);this.h.value+=b;this.h.scrollTop=this.h.scrollHeight;this.l+=c}}else if(null!= this.i){if(10==a||1024<=this.i.length)this.aa(this.i),this.i="";10!=a&&(this.i+=String.fromCharCode(a))}oc(this.c,this.X,1E3/Math.round(this.ba/10));this.b&=-129};var Mf="buffer",Pf={},Nf=(Pf[65392]=[null,null,Lf.prototype.Mf,Lf.prototype.dh,"RCSR"],Pf[65394]=[null,null,Lf.prototype.Lf,Lf.prototype.bh,"RBUF"],Pf[65396]=[null,null,Lf.prototype.sg,Lf.prototype.Kh,"XCSR"],Pf[65398]=[null,null,Lf.prototype.rg,Lf.prototype.Jh,"XBUF"],Pf); -Ya(function(){for(var a=A(document,z,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.o[b]=c,!0;case "readTape":e=Tf;case "loadTape":return e||(e=Uf),this.o[b]=c,c.onclick= function(){var a=d.o.listTapes;a&&Vf(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Vf(d,Ea(b,!0),b,Uf,a)}return!1};return!0;case Wf:return this.o[b]=c,!0}return!1}; -h.ja=function(a,b,c,d){this.A=a;this.u=b;this.c=c;this.D=d;this.v=Xf(a);var e=this;if(a=Qf(this,Tc(this.A,"autoMount")))for(var f in a)"PTR"==f&&(this.C[f]=a[f]);this.s=pc(this.c,56,4,4096);this.J=mc(this.c,function(){1!=(e.a&32769)||e.a&128||(e.hc.indexOf("/api/v1/dump")&&(e=Fa(c),f="json"==e||"gz"==e?encodeURI(c):Oa()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!Ma(f,null,!0,function(e,f,g){var k=0>g&&!!a.A&&!a.A.j.R;g?a.G('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.Ua,e,f),(e=Na(e,f))&&hg(a,b,c,d, -e.N,e.ea,e.da));a.j.Ra=!1;a.b&&(a.b--,a.b||B(a));eg(a)})}function $f(a,b,c,d){if((a=a.o.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.a=Array(a.L);for(d=0;d>2;var f=e=0,b=new DataView(b,0,d);a.a=Array(a.M);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Fa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Ga(c,"/")&&(d="dir"),f=Oa()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.Yc?"":e)+"&format=json"));return!!Ma(f, null,!0,function(b,c,d){pg(a,b,c,d)})} function pg(a,b,c,d){var e=null,f=0>d&&!!a.A&&!a.A.j.R;a.g=!1;if(d)a.controller.G('Unable to load disk "'+a.xa+'" (error '+d+": "+b+")",f);else{na(a.controller.Ua,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ -c+")");if(k.length)if(1==k.length)u(k[0]);else{a.L=k.length;a.T=k[0].length;a.P=k[0][0].length;var l=k[0][0][0];a.Z=l&&l.length||512;for(d=c=0;d>2,p=l.pattern;void 0===p&&(p=l.pattern=0);var q=l.data;if(void 0===q){var v=l.bytes;if(void 0!==v&&v.length){for(var y=m<<2,ma=v.length;ma>2,p=l.pattern;void 0===p&&(p=l.pattern=0);var q=l.data;if(void 0===q){var v=l.bytes;if(void 0!==v&&v.length){for(var y=m<<2,ma=v.length;ma>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.g)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.na?f=a.wa+a.na&&(a.na+=f-(a.wa+a.na)+1):(a.wa=f,a.na=1);d[f]=d[f]&~(255<g)break;e|=g<g)break;e|=g<=this.a.length||l>=this.a[k].length||m>=this.a[k][l].length){c="sector (CHS="+k+":"+l+":"+m+") out of range ("+ b+" changes applied)";b=-1;break}if(this.g){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.a[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.G("Unable to restore disk '"+this.xa+": "+c);return b}; h.toJSON=function(){var a;a=0;for(var b;b=rg(this,a++);)tg(b);a=JSON.stringify(this.a,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; -function tg(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var lg=0;function ug(a,b,c,d,e,f){r.call(this,a,b,c);this.C=vg(this,b.autoMount);this.B=0;this.I=d;this.J=e;this.K=f;this.H=d.Bc;this.b=Array(this.H);this.F=!Ua("Mobi")&&window&&"FileReader"in window;this.m=[];this.qa=null;this.exports={bootDisk:this.Ed,loadDisk:this.Zc,selectDrive:this.wg,wait:this.Cg}}n(ug,r); +function tg(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var lg=0;function ug(a,b,c,d,e,f){r.call(this,a,b,c);this.C=vg(this,b.autoMount);this.B=0;this.I=d;this.J=e;this.K=f;this.H=d.Bc;this.b=Array(this.H);this.F=!Ua("Mobi")&&window&&"FileReader"in window;this.l=[];this.qa=null;this.exports={bootDisk:this.Ed,loadDisk:this.Zc,selectDrive:this.wg,wait:this.Cg}}n(ug,r); function vg(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){u(a.type+" auto-mount error: "+c.message+" ("+b+")"),b=null}return b||{}}h=ug.prototype; h.ma=function(a,b,c){var d=this;switch(b){case "listDisks":return this.o[b]=c,c.onchange=function(){wg(d)},!0;case "descDisk":case "listDrives":return this.o[b]=c,c.onchange=function(){var a=Ba(c.value,10);null!=a&&xg(d,a)},!0;case "loadDisk":return this.o[b]=c,c.onclick=function(){d.Zc()},!0;case "bootDisk":return this.o[b]=c,c.onclick=function(){d.Ed()},!0;case "saveDisk":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.onclick=function(){var a=d.o.listDrives;if(a&&a.options&&d.b)if(a= d.b[Ba(a.value,10)||0])if(a=a.O){var b;b="";for(var c=0,k;k=rg(a,c++);)for(var l=0,m=k.length;lg||9d||d>=this.b.length)return this.G("Unable to load the selected drive"),!1;if(!b)return Dg(this,d),!0;if(b==Ag)return this.G('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Bg){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Ea(b);this.status("Attempting to load "+b+' as "'+ a+'"')}Hg(this,d,a,b,!1,c);return!0};h.Ed=function(){var a,b=this.o.listDrives,b=b&&Ba(b.value,10);if(null==b||0>b||b>=this.b.length||!(a=this.b[b]))return this.G("Unable to boot the selected drive"),!1;if(!a.O)return this.G("Load a disk into the drive first"),!1;hd(this.c,0,!0,b);return(a=this.ub(a,a.Xe,a.Ye,a.Ze,a.Oe,0,2))?(this.G("Unable to read the boot sector ("+a+")"),!1):!0}; function Hg(a,b,c,d,e,f){var g=-1,k=a.b[b];k.oa.toLowerCase()!=d.toLowerCase()&&(g++,Dg(a,b,!0),k.hc?a.G(a.type+" busy"):(k.hc=!0,e&&(k.Xc=!0,a.B++),k.qb=!!f,og(new kg(a,k,"preload"),c,d,f,a.Gd)&&g++));return g} -h.Gd=function(a,b,c,d,e){a.hc=!1;b&&(b.L>a.L||b.T>a.T)&&(this.G('Disk "'+c+'" too large for drive '+(this.b[a.rb].oc||"---")),b=null);b?(a.O=b,a.xa=c,a.oa=d,this.Ld(a.rb),Ig(this,c,d,b),this.G('Loaded disk "'+c+'" in drive '+(this.b[a.rb].oc||"---"),a.Xc||e),this.A&&$c(this.A)):a.qb=!1;a.Xc&&(a.Xc=!1,--this.B||B(this));xg(this,a.rb);a.Jb&&(a.Jb(),a.Jb=null)}; +h.Gd=function(a,b,c,d,e){a.hc=!1;b&&(b.M>a.M||b.T>a.T)&&(this.G('Disk "'+c+'" too large for drive '+(this.b[a.rb].oc||"---")),b=null);b?(a.O=b,a.xa=c,a.oa=d,this.Ld(a.rb),Ig(this,c,d,b),this.G('Loaded disk "'+c+'" in drive '+(this.b[a.rb].oc||"---"),a.Xc||e),this.A&&$c(this.A)):a.qb=!1;a.Xc&&(a.Xc=!1,--this.B||B(this));xg(this,a.rb);a.Jb&&(a.Jb(),a.Jb=null)}; function yg(a,b,c,d){if((a=a.o.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}h.Cg=function(a){for(var b=0;b=a.L){m=T.Zb;break}p=a.seek(b,c,d+1);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}var v,y;if(0>(v=a.read(p,q++))||0>(y=a.read(p,q++))){m=T.$b;break}if(!k&&(Mb(this.u,sd(this.c,f),v|y<<8),lc(this.u))){m=T.Eb;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; -h.vc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){var v=Ob(this.u,sd(this.c,f));if(lc(this.u)){m=T.Eb;break}if(!p){if(b>=a.L){m=T.Zb;break}p=a.seek(b,c,d+1,!0);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}if(k){var y,ma;if(0>(y=a.read(p,q++))||0>(ma=a.read(p,q++))){m=T.$b;break}if(v!=(y|ma<<8)){m=T.Cd;break}}else if(!a.write(p,q++,v&255)||!a.write(p,q++,v>>8)){m=T.$b;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +function Dg(a,b,c){var d=a.b[b];if(d.O||!1===c)Jg(a,d.oa,d.O),d.xa="",d.oa="",d.O=null,d.qb=!1,c||(a.G("Drive "+(a.b[b].oc||"---")+" unloaded",c),xg(a,b))}function Ig(a,b,c,d){var e;for(e=0;e=a.M){m=T.Zb;break}p=a.seek(b,c,d+1);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}var v,y;if(0>(v=a.read(p,q++))||0>(y=a.read(p,q++))){m=T.$b;break}if(!k&&(Mb(this.v,sd(this.c,f),v|y<<8),lc(this.v))){m=T.Eb;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.vc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){var v=Ob(this.v,sd(this.c,f));if(lc(this.v)){m=T.Eb;break}if(!p){if(b>=a.M){m=T.Zb;break}p=a.seek(b,c,d+1,!0);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}if(k){var y,ma;if(0>(y=a.read(p,q++))||0>(ma=a.read(p,q++))){m=T.$b;break}if(v!=(y|ma<<8)){m=T.Cd;break}}else if(!a.write(p,q++,v&255)||!a.write(p,q++,v>>8)){m=T.$b;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; h.me=function(a,b,c,d,e,f){this.h=f&65535;this.a=this.a&~S.fb|f>>16-S.V.fb&S.fb;this.i=65536-e&65535;this.g=this.g&~Mg.Rc|d&Mg.Rc;this.f|=a;Ng(this);return!0};function Ng(a){a.a&=~S.Ja;a.f&&(a.f|=T.Yd,a.a|=S.Ja,a.f&T.Hc&&(a.a|=S.Hc))}h.Rf=function(){return this.s};h.ih=function(){};h.Sf=function(){return this.f};h.jh=function(){};h.Of=function(){return this.a&S.Fb}; -h.fh=function(a){this.a=this.a&~S.va|a&S.va;if(this.a&S.Db){a=!0;var b,c,d=(this.g&Mg.Ta)>>Mg.V.Ta,e=this.b[d],f,g,k,l,m,p;this.a&=~(S.za|S.Sc);this.f&=~T.Ce;switch(c=this.a&S.ca){case Og.Td:this.f=this.g=0;this.a=S.za;break;case Og.he:case Og.Va:b=this.ub;case Og.Vc:case Og.Hb:b||(b=this.vc);f=(this.g&Mg.Bb)>>Mg.V.Bb;g=(this.g&Mg.Kc)>>Mg.V.Kc;k=this.g&Mg.Rc;l=65536-this.i&65535;m=(this.a&S.fb)<<16-S.V.fb|this.h;p=this.a&S.de?0:2;if(f>=e.L){this.f|=T.Zb;break}if(k>=e.P){this.f|=T.$b;break}a=b.call(this, -e,f,g,k,l,m,p,c>=Og.Vc,this.me.bind(this));break;case Og.ec:f=(this.g&Mg.Bb)>>Mg.V.Bb;f(p=a.read(k,m++))||0>(q=a.read(k,m++))){g=Rg.Ba;break}Mb(this.u,sd(this.c,f),p|q<<8);if(lc(this.u)){g=Rg.Eb;break}f+=2;e--;if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.L)))){g=Rg.Ba;break}}return l?l(g,b,c,d,e,f):g}; -h.vc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.O;k=null;var m;a||(g=Rg.Ba,e=0);for(;e;){var p=Ob(this.u,sd(this.c,f));if(lc(this.u)){g=Rg.Eb;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=Rg.Ba;break}m=0}if(!a.write(k,m++,p&255)||!a.write(k,m++,p>>8)){g=Rg.Ba;break}if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.L)))){g=Rg.Ba;break}}return l?l(g,b,c,d,e,f):g}; -h.re=function(a,b,c,d,e,f){this.l=f&65535;this.a=this.a&~U.ya|f>>16-U.V.ya&U.ya;this.h=f>>16&Sg.Fa;this.g=this.f=b<>U.V.ya;if(!(this.a&U.za)){a=!0;var b,c=this.b[(this.a&U.Ta)>>U.V.Ta],d=c.O,e,f,g;this.a&=~U.ha;switch(this.a&U.ca){case Tg.Ge:this.i&Ug.md&&(this.a&=U.ha|U.ca|U.ya);this.i=c.status|this.g&V.dc|(d&&512==d.L?Ug.ae:0);break;case Tg.ec:(this.f&V.$d)==V.De&&(b=this.f&V.Gb,c=(this.f&V.Fe)<<2,this.g=this.f&V.Ee?this.g+b:this.g-b,this.f=this.g=this.g&V.Gb|c);break;case Tg.le:this.i=this.g;break;case Tg.ie:b=this.ub;case Tg.Je:b||(b=this.vc), -e=this.f>>V.V.Gb,f=this.f&V.dc?1:0,g=this.f&V.yd,!d||e>=d.L||g>=d.P?this.a=this.a|Rg.Ba|U.Ja:(a=65536-this.i&65535,d=(this.h&Sg.Fa)<<16|this.l,a=b.call(this,c,e,f,g,a,d,2,!1,this.re.bind(this)))}a&&(this.a=this.a|U.ha|U.za,this.a&U.eb&&nc(this.c,this.qa))}};h.Uf=function(){return this.l};h.lh=function(a){this.l=a&Vg.va};h.Xf=function(){return this.f};h.oh=function(a){this.f=a};h.Yf=function(){return this.i};h.ph=function(a){this.i=a};h.Vf=function(){return this.h}; +h.fh=function(a){this.a=this.a&~S.va|a&S.va;if(this.a&S.Db){a=!0;var b,c,d=(this.g&Mg.Ta)>>Mg.V.Ta,e=this.b[d],f,g,k,l,m,p;this.a&=~(S.za|S.Sc);this.f&=~T.Ce;switch(c=this.a&S.ca){case Og.Td:this.f=this.g=0;this.a=S.za;break;case Og.he:case Og.Va:b=this.ub;case Og.Vc:case Og.Hb:b||(b=this.vc);f=(this.g&Mg.Bb)>>Mg.V.Bb;g=(this.g&Mg.Kc)>>Mg.V.Kc;k=this.g&Mg.Rc;l=65536-this.i&65535;m=(this.a&S.fb)<<16-S.V.fb|this.h;p=this.a&S.de?0:2;if(f>=e.M){this.f|=T.Zb;break}if(k>=e.P){this.f|=T.$b;break}a=b.call(this, +e,f,g,k,l,m,p,c>=Og.Vc,this.me.bind(this));break;case Og.ec:f=(this.g&Mg.Bb)>>Mg.V.Bb;f(p=a.read(k,m++))||0>(q=a.read(k,m++))){g=Rg.Ba;break}Mb(this.v,sd(this.c,f),p|q<<8);if(lc(this.v)){g=Rg.Eb;break}f+=2;e--;if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.M)))){g=Rg.Ba;break}}return l?l(g,b,c,d,e,f):g}; +h.vc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.O;k=null;var m;a||(g=Rg.Ba,e=0);for(;e;){var p=Ob(this.v,sd(this.c,f));if(lc(this.v)){g=Rg.Eb;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=Rg.Ba;break}m=0}if(!a.write(k,m++,p&255)||!a.write(k,m++,p>>8)){g=Rg.Ba;break}if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.M)))){g=Rg.Ba;break}}return l?l(g,b,c,d,e,f):g}; +h.re=function(a,b,c,d,e,f){this.m=f&65535;this.a=this.a&~U.ya|f>>16-U.V.ya&U.ya;this.h=f>>16&Sg.Fa;this.g=this.f=b<>U.V.ya;if(!(this.a&U.za)){a=!0;var b,c=this.b[(this.a&U.Ta)>>U.V.Ta],d=c.O,e,f,g;this.a&=~U.ha;switch(this.a&U.ca){case Tg.Ge:this.i&Ug.md&&(this.a&=U.ha|U.ca|U.ya);this.i=c.status|this.g&V.dc|(d&&512==d.M?Ug.ae:0);break;case Tg.ec:(this.f&V.$d)==V.De&&(b=this.f&V.Gb,c=(this.f&V.Fe)<<2,this.g=this.f&V.Ee?this.g+b:this.g-b,this.f=this.g=this.g&V.Gb|c);break;case Tg.le:this.i=this.g;break;case Tg.ie:b=this.ub;case Tg.Je:b||(b=this.vc), +e=this.f>>V.V.Gb,f=this.f&V.dc?1:0,g=this.f&V.yd,!d||e>=d.M||g>=d.P?this.a=this.a|Rg.Ba|U.Ja:(a=65536-this.i&65535,d=(this.h&Sg.Fa)<<16|this.m,a=b.call(this,c,e,f,g,a,d,2,!1,this.re.bind(this)))}a&&(this.a=this.a|U.ha|U.za,this.a&U.eb&&nc(this.c,this.qa))}};h.Uf=function(){return this.m};h.lh=function(a){this.m=a&Vg.va};h.Xf=function(){return this.f};h.oh=function(a){this.f=a};h.Yf=function(){return this.i};h.ph=function(a){this.i=a};h.Vf=function(){return this.h}; h.mh=function(a){this.h=a&Sg.Fa;this.a=this.a&~U.ya|(this.h&3)<=m.L){k=Y.fe;break}p=m.seek(b,c,d+1);if(!p){k=Y.Pc;break}q=0;++d>=m.P&&(d=0,++c>=m.T&&(c=0,++b))}var v;if(0>(a=m.read(p,q++))||0>(v=m.read(p,q++))){k=Y.Oc;break}Mb(this.u,sd(this.c,f),a|v<<8);q>=m.Z&&(p=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; -function Yg(a){var b=0,c=a.a&X.Tc?1:0,d=a.b[c],d=d&&d.O,e=a.v&$g.Fa,f=a.s&ah.Fa;a.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(d)if(a.f|=Z.ha,c=d.seek(e,0,f,!0)){e=0;for(f=a.h.length;eg){b=Y.Oc;break}a.h[e++]=g}c.Re&&(a.f|=Z.Cb)}else b=Y.Pc;else b=c?Y.Jc:Y.Ic;Zg(a,b)}h.$f=function(a,b){a=this.a;if(!b)switch(a&=X.Fb,this.g){case W.Ec:case W.EMPTY:this.ithis.i&&(this.a|=X.Ga)}return a}; -h.rh=function(a){this.a=this.a&~X.va|a&X.va;if(this.a&X.INIT)this.bb();else if(this.a&X.Db&&this.g==W.gb)switch(this.g=this.a&X.ca,this.a&=~(X.Db|X.Ga|X.DONE|X.Ja),(a=this.qa)&&rc(this.c,a),this.g){case W.Ec:case W.EMPTY:case W.Va:case W.Hb:case W.fc:this.i=0;break;case W.ke:a=this.b[this.a&X.Tc?1:0];this.f&=~Z.ha;a&&a.O&&(this.f|=Z.ha);this.l=this.f;Zg(this);break;case W.je:this.l=this.w,Zg(this)}else this.a&X.eb?this.a&X.DONE&&nc(this.c,this.qa):(a=this.qa)&&rc(this.c,a)}; -h.ag=function(a,b){if(!b)switch(this.g){case W.EMPTY:this.a&X.Ga&&(this.a&=~X.Ga,this.l=this.h[this.i]&255,++this.i>=this.h.length&&Zg(this))}return this.l}; -h.sh=function(a){switch(this.g){case W.Ec:this.a&X.Ga&&(this.a&=~X.Ga,this.h[this.i]=a&255,++this.i>=this.h.length&&Zg(this));break;case W.Va:case W.Hb:case W.fc:if(this.a&X.Ga)switch(this.a&=~X.Ga,this.i++){case 0:this.s=a;break;case 1:if(this.v=a,this.g==W.Va)Yg(this);else{var b=this.g==W.fc,c=0,d=this.a&X.Tc?1:0,e=this.b[d],e=e&&e.O,f=this.v&$g.Fa,g=this.s&ah.Fa;this.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(e)if(this.f|=Z.ha,d=e.seek(f,0,g,!0))for(b&&(d.Re=!0),b=0,f=this.h.length;b\nLicense: GPL version 3 or later ");this.aa("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;b=m.M){k=Y.fe;break}p=m.seek(b,c,d+1);if(!p){k=Y.Pc;break}q=0;++d>=m.P&&(d=0,++c>=m.T&&(c=0,++b))}var v;if(0>(a=m.read(p,q++))||0>(v=m.read(p,q++))){k=Y.Oc;break}Mb(this.v,sd(this.c,f),a|v<<8);q>=m.Z&&(p=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +function Yg(a){var b=0,c=a.a&X.Tc?1:0,d=a.b[c],d=d&&d.O,e=a.u&$g.Fa,f=a.s&ah.Fa;a.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(d)if(a.f|=Z.ha,c=d.seek(e,0,f,!0)){e=0;for(f=a.h.length;eg){b=Y.Oc;break}a.h[e++]=g}c.Re&&(a.f|=Z.Cb)}else b=Y.Pc;else b=c?Y.Jc:Y.Ic;Zg(a,b)}h.$f=function(a,b){a=this.a;if(!b)switch(a&=X.Fb,this.g){case W.Ec:case W.EMPTY:this.ithis.i&&(this.a|=X.Ga)}return a}; +h.rh=function(a){this.a=this.a&~X.va|a&X.va;if(this.a&X.INIT)this.bb();else if(this.a&X.Db&&this.g==W.gb)switch(this.g=this.a&X.ca,this.a&=~(X.Db|X.Ga|X.DONE|X.Ja),(a=this.qa)&&rc(this.c,a),this.g){case W.Ec:case W.EMPTY:case W.Va:case W.Hb:case W.fc:this.i=0;break;case W.ke:a=this.b[this.a&X.Tc?1:0];this.f&=~Z.ha;a&&a.O&&(this.f|=Z.ha);this.m=this.f;Zg(this);break;case W.je:this.m=this.w,Zg(this)}else this.a&X.eb?this.a&X.DONE&&nc(this.c,this.qa):(a=this.qa)&&rc(this.c,a)}; +h.ag=function(a,b){if(!b)switch(this.g){case W.EMPTY:this.a&X.Ga&&(this.a&=~X.Ga,this.m=this.h[this.i]&255,++this.i>=this.h.length&&Zg(this))}return this.m}; +h.sh=function(a){switch(this.g){case W.Ec:this.a&X.Ga&&(this.a&=~X.Ga,this.h[this.i]=a&255,++this.i>=this.h.length&&Zg(this));break;case W.Va:case W.Hb:case W.fc:if(this.a&X.Ga)switch(this.a&=~X.Ga,this.i++){case 0:this.s=a;break;case 1:if(this.u=a,this.g==W.Va)Yg(this);else{var b=this.g==W.fc,c=0,d=this.a&X.Tc?1:0,e=this.b[d],e=e&&e.O,f=this.u&$g.Fa,g=this.s&ah.Fa;this.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(e)if(this.f|=Z.ha,d=e.seek(f,0,g,!0))for(b&&(d.Re=!0),b=0,f=this.h.length;b\nLicense: GPL version 3 or later ");this.aa("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bfh){if(gh(d,this.s)){this.h=new E(this,"1.34.0",qh);gh(this.h)&&(rh(this,d),a=sh,th(this.h));this.h.set(lh,La());uh(this.h);var e=this.a&&!this.l;if(a==mh||qa("Click OK to restore the previous "+gb+" machine state, or CANCEL to reset the machine.")){if(c=kh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gh(d,g):("error"==f&&"no machine state"!= -g?(this.G("Error: "+g),"unable to verify user"==g&&(Sa(vh,""),this.b=null)):this.aa(f+": "+g),th(d),gh(d)?(c=kh(d),e=!0):c=!1))}e&&ih(this,c?d:null)}else a==sh&&d.clear()}else ih(this);delete this.s;delete this.m}e=ra(this.id);for(f=0;ffh){if(gh(d,this.s)){this.h=new E(this,"1.34.0",qh);gh(this.h)&&(rh(this,d),a=sh,th(this.h));this.h.set(lh,La());uh(this.h);var e=this.a&&!this.m;if(a==mh||qa("Click OK to restore the previous "+gb+" machine state, or CANCEL to reset the machine.")){if(c=kh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?gh(d,g):("error"==f&&"no machine state"!= +g?(this.G("Error: "+g),"unable to verify user"==g&&(Sa(vh,""),this.b=null)):this.aa(f+": "+g),th(d),gh(d)?(c=kh(d),e=!0):c=!1))}e&&ih(this,c?d:null)}else a==sh&&d.clear()}else ih(this);delete this.s;delete this.l}e=ra(this.id);for(f=0;fa[1];a=a[2];this.H=!0;this.j.R=!0;var d=this.o.power;d&&(d.textContent="Shutdown");this.c&&(wh(this,this.c,b,c,a),Kb(this,-2),this.c.Y());this.C&&(rh(this,b),b.clear());!c&&this.h&&(this.h.clear(),delete this.h);this.g=0}; function rh(a,b){if(qa("There may be a problem with your "+gb+" machine.\n\nTo help us diagnose it, click OK to send this "+gb+" machine state to http://www.pcjs.org.")){var c=a.K;a=a.b||"";b=b.toString();var d={};d.app=gb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}} -function xh(a,b,c){var d,e="none";if(a.g)return null;a.g--;var f=new E(a,"1.34.0"),g=new E(a,"1.34.0",jh),k=La();g.set(lh,k);f.set(lh,k);f.set(yh,"1.34.0");f.set(zh,window?window.location.href:null);f.set(Ah,window?window.navigator.userAgent:"");a.c&&a.c.ka&&(c&&(b&&(a.c.j.Y=a.c.j.M),G(a.c)),d=a.c.ka(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.j.R=!1,!1===d&&(e=null)));for(var k=ra(a.id),l=0;l=d||30<=(c.fd+=d))&&(e.textContent=c.j.M?c.Wa.toFixed(2)+"Mhz":"Stopped",c.fd=0)}if(a.f&&(a=a.f,b=b||0,a.m)){c=a.c.j.M;d=!!(a.c.g&8);if(0>=b||60<=(a.i+=b)){for(e=0;eb?a.U=a.c.b[7]:0=d||30<=(c.fd+=d))&&(e.textContent=c.j.N?c.Wa.toFixed(2)+"Mhz":"Stopped",c.fd=0)}if(a.f&&(a=a.f,b=b||0,a.l)){c=a.c.j.N;d=!!(a.c.g&8);if(0>=b||60<=(a.i+=b)){for(e=0;eb?a.U=a.c.b[7]:0 Date: Mon, 27 Feb 2017 09:50:28 -0800 Subject: [PATCH 18/30] Implemented all four primary half-word moves (HLL, HLR, HRL, HRR) but none of the flavors (Z, O, E); need to test the primary instructions first --- apps/pdp10/tests/optest.json | 2 +- modules/pdp10/lib/cpuops.js | 229 +++++++++++++++---- modules/pdp10/lib/defines.js | 3 +- versions/pc8080/1.34.0/pc8080-dbg.js | 56 ++--- versions/pc8080/1.34.0/pc8080.js | 56 ++--- versions/pdpjs/1.34.0/pdp10-dbg.js | 327 ++++++++++++++------------- versions/pdpjs/1.34.0/pdp10.js | 193 ++++++++-------- 7 files changed, 507 insertions(+), 359 deletions(-) diff --git a/apps/pdp10/tests/optest.json b/apps/pdp10/tests/optest.json index bcae5b502..506aef7c2 100644 --- a/apps/pdp10/tests/optest.json +++ b/apps/pdp10/tests/optest.json @@ -2,6 +2,6 @@ "load": 0o100, "exec": 0o100, "data": [ - 0o500000000000 + 0o505040111111, // HRLI 1,111111 ] } diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index d314e14e7..e53e7c491 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -53,9 +53,9 @@ PDP10.opKA10 = function(op) }; /** - * opUUO(0o0xx000): Unimplemented User Operation + * opUUO(0o0NN000): Unimplemented User Operation * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-64: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-64: * * Store the instruction code, A and the effective address E in bits 0-8, 9-12 and 18-35 respectively of * location 40; clear bits 13-17. Execute the instruction contained in location 41. The original contents @@ -85,7 +85,7 @@ PDP10.opUUO = function(op) /** * opUFA(0o130000): Unnormalized Floating Add * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * * Floating add the contents of location E to AC. If the double length fraction in the sum is zero, clear * accumulator A+1. Otherwise normalize the sum only if the magnitude of its fractional part is >= 1, and place @@ -111,7 +111,7 @@ PDP10.opUFA = function(op) /** * opDFN(0o131000): Double Floating Negate * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-37: * * Negate the double length floating point number composed of the contents of AC and location E with AC on the left. * Do this by taking the twos complement of the number whose sign is AC bit 0, whose exponent is in AC bits 1-8, and @@ -130,7 +130,7 @@ PDP10.opDFN = function(op) /** * opFSC(0o132000): Floating Scale * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-34: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-34: * * If the fractional part of AC is zero, clear AC. Otherwise add the scale factor given by E to the exponent part * of AC (thus multiplying AC by 2^E), normalize the resulting word bringing 0s into bit positions vacated at the @@ -162,7 +162,7 @@ PDP10.opFSC = function(op) /** * opIBP(0o133000): Increment Byte Pointer * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-16: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-16: * * Increment the byte pointer in location E as explained above. * @@ -2653,7 +2653,7 @@ PDP10.opSETOB = function(op) /** * opHLL(0o500000): Half Word Left to Left * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * * Move the left half of the source word specified by M to the left half of the specified destination. * The source and the destination right half are unaffected; the original contents of the destination are lost. @@ -2668,18 +2668,20 @@ PDP10.opHLL = function(op) var a = op & PDP10.OPCODE.A_MASK; var src = this.readWord(this.regEA); var dst = this.readWord(a); - dst = (dst & PDP10.RHWORD_MASK) + (src - (src & PDP10.RHWORD_MASK)); + dst = (dst & PDP10.WORD_MASK) + (src - (src & PDP10.WORD_MASK)); this.writeWord(a, dst); }; /** - * opHLLI(0o501000) + * opHLLI(0o501000): Half Word Left to Left, Immediate * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * * Move the left half of the source word specified by M to the left half of the specified destination. * The source and the destination right half are unaffected; the original contents of the destination are lost. * + * SIDEBAR: HLLI merely clears AC left. + * * For HLLI, the source is 0,E and the destination is [A]. But since this is a left-half-only operation, src is * effectively 0. * @@ -2690,14 +2692,14 @@ PDP10.opHLLI = function(op) { var a = op & PDP10.OPCODE.A_MASK; var dst = this.readWord(a); - dst = (dst & PDP10.RHWORD_MASK); + dst = (dst & PDP10.WORD_MASK); this.writeWord(a, dst); }; /** - * opHLLM(0o502000) + * opHLLM(0o502000): Half Word Left to Left, Memory * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * * Move the left half of the source word specified by M to the left half of the specified destination. * The source and the destination right half are unaffected; the original contents of the destination are lost. @@ -2712,19 +2714,19 @@ PDP10.opHLLM = function(op) var a = op & PDP10.OPCODE.A_MASK; var src = this.readWord(a); var dst = this.readWord(this.regEA); - dst = (dst & PDP10.RHWORD_MASK) + (src - (src & PDP10.RHWORD_MASK)); + dst = (dst & PDP10.WORD_MASK) + (src - (src & PDP10.WORD_MASK)); this.writeWord(this.regEA, dst); }; /** - * opHLLS(0o503000) + * opHLLS(0o503000): Half Word Left to Left, Self * - * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * * Move the left half of the source word specified by M to the left half of the specified destination. * The source and the destination right half are unaffected; the original contents of the destination are lost. * - * If A is zero, HLLS is a no-op, otherwise it is equivalent to HLL. + * SIDEBAR: If A is zero, HLLS is a no-op, otherwise it is equivalent to HLL. * * For HLLS, the source is [E] and the destination is [E] (and also [A] if A is non-zero). * @@ -2733,53 +2735,100 @@ PDP10.opHLLM = function(op) */ PDP10.opHLLS = function(op) { - if (op & PDP10.OPCODE.A_MASK) { - PDP10.opHLL.call(this, op); - } + if (op & PDP10.OPCODE.A_MASK) PDP10.opHLL.call(this, op); }; /** - * opHRL(0o504000) + * opHRL(0o504000): Half Word Right to Left + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-4: + * + * Move the right half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination left + * half are lost. + * + * For HRL, the source is [E] and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRL = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(this.regEA) & PDP10.WORD_MASK; + var dst = this.readWord(a); + dst = (dst & PDP10.WORD_MASK) + src * PDP10.WORD_SHIFT; + this.writeWord(a, dst); }; /** - * opHRLI(0o505000) + * opHRLI(0o505000): Half Word Right to Left, Immediate + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-4: + * + * Move the right half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination left + * half are lost. + * + * For HRLI, the source is 0,E and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRLI = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var dst = this.readWord(a); + dst = (dst & PDP10.WORD_MASK) + this.regEA * PDP10.WORD_SHIFT; + this.writeWord(a, dst); }; /** - * opHRLM(0o506000) + * opHRLM(0o506000): Half Word Right to Left, Memory + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-4: + * + * Move the right half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination left + * half are lost. + * + * For HRLM, the source is [A] and the destination is [E]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRLM = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(a) & PDP10.WORD_MASK; + var dst = this.readWord(this.regEA); + dst = (dst & PDP10.WORD_MASK) + src * PDP10.WORD_SHIFT; + this.writeWord(this.regEA, dst); }; /** - * opHRLS(0o507000) + * opHRLS(0o507000): Half Word Right to Left, Self + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-4: + * + * Move the right half of the source word specified by M to the left half of the specified destination. + * The source and the destination right half are unaffected; the original contents of the destination left + * half are lost. + * + * For HRLS, the source is [E] and the destination is [E] (and also [A] if A is non-zero). * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRLS = function(op) { - this.opUndefined(op); + var dst = this.readWord(this.regEA) & PDP10.WORD_MASK; + this.writeWord(this.regEA, dst + dst * PDP10.WORD_SHIFT); + var a = op & PDP10.OPCODE.A_MASK; + if (a) { + dst = this.readWord(a) & PDP10.WORD_MASK; + this.writeWord(a, dst + dst * PDP10.WORD_SHIFT); + } }; /** @@ -3047,91 +3096,183 @@ PDP10.opHRLES = function(op) }; /** - * opHRR(0o540000) + * opHRR(0o540000): Half Word Right to Right + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-6: + * + * Move the right half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right + * half are lost. + * + * For HRR, the source is [E] and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRR = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(this.regEA) & PDP10.WORD_MASK; + var dst = this.readWord(a); + dst = (dst - (dst & PDP10.WORD_MASK)) + src; + this.writeWord(a, dst); }; /** - * opHRRI(0o541000) + * opHRRI(0o541000): Half Word Right to Right, Immediate + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-6: + * + * Move the right half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right + * half are lost. + * + * For HRRI, the source is 0,E and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRRI = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var dst = this.readWord(a); + dst = (dst - (dst & PDP10.WORD_MASK)) + this.regEA; + this.writeWord(a, dst); }; /** - * opHRRM(0o542000) + * opHRRM(0o542000): Half Word Right to Right, Memory + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-6: + * + * Move the right half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right + * half are lost. + * + * For HRRM, the source is [A] and the destination is [E]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRRM = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = this.readWord(a) & PDP10.WORD_MASK; + var dst = this.readWord(this.regEA); + dst = (dst - (dst & PDP10.WORD_MASK)) + src; + this.writeWord(this.regEA, dst); }; /** - * opHRRS(0o543000) + * opHRRS(0o543000): Half Word Right to Right, Self + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-6: + * + * Move the right half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right + * half are lost. + * + * SIDEBAR: If A is zero, HRRS is a no-op; otherwise it is equivalent to HRR. + * + * For HRRS, the source is [E] and the destination is [E] (and also [A] if A is non-zero). * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHRRS = function(op) { - this.opUndefined(op); + if (op & PDP10.OPCODE.A_MASK) PDP10.opHRR.call(this, op); }; /** - * opHLR(0o544000) + * opHLR(0o544000): Half Word Left to Right + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-7: + * + * Move the left half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right half are lost. + * + * For HLR, the source is [E] and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHLR = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = (this.readWord(this.regEA) / PDP10.WORD_SHIFT)|0; + var dst = this.readWord(a); + dst = (dst - (dst & PDP10.WORD_MASK)) + src; + this.writeWord(a, dst); }; /** - * opHLRI(0o545000) + * opHLRI(0o545000): Half Word Left to Right, Immediate + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-7: + * + * Move the left half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right half are lost. + * + * SIDEBAR: HLRI merely clears AC right. + * + * For HLRI, the source is 0,E and the destination is [A]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHLRI = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var dst = this.readWord(a); + dst = (dst - (dst & PDP10.WORD_MASK)); + this.writeWord(a, dst); }; /** - * opHLRM(0o546000) + * opHLRM(0o546000): Half Word Left to Right, Memory + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-7: + * + * Move the left half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right half are lost. + * + * For HLRM, the source is [A] and the destination is [E]. * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHLRM = function(op) { - this.opUndefined(op); + var a = op & PDP10.OPCODE.A_MASK; + var src = (this.readWord(a) / PDP10.WORD_SHIFT)|0; + var dst = this.readWord(this.regEA); + dst = (dst - (dst & PDP10.WORD_MASK)) + src; + this.writeWord(this.regEA, dst); }; /** - * opHLRS(0o547000) + * opHLRS(0o547000): Half Word Left to Right, Self + * + * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-7: + * + * Move the left half of the source word specified by M to the right half of the specified destination. + * The source and the destination left half are unaffected; the original contents of the destination right half are lost. + * + * For HLRS, the source is [E] and the destination is [E] (and also [A] if A is non-zero). * * @this {CPUStatePDP10} * @param {number} op */ PDP10.opHLRS = function(op) { - this.opUndefined(op); + var dst = this.readWord(this.regEA); + this.writeWord(this.regEA, (dst & PDP10.WORD_MASK) + ((dst / PDP10.WORD_SHIFT)|0)); + var a = op & PDP10.OPCODE.A_MASK; + if (a) { + dst = this.readWord(a); + this.writeWord(a, (dst & PDP10.WORD_MASK) + ((dst / PDP10.WORD_SHIFT)|0)); + } }; /** diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index bd1d08340..924573c43 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -100,7 +100,8 @@ var PDP10 = { ADDR_MASK: Math.pow(2, 18) - 1, DATA_INVALID: -1, DATA_LIMIT: Math.pow(2, 36), - RHWORD_MASK: 0o777777, + WORD_SHIFT: Math.pow(2, 18), + WORD_MASK: 0o777777, /* * PDP-10 opcodes are 36-bit values, most of which use the following layout: diff --git a/versions/pc8080/1.34.0/pc8080-dbg.js b/versions/pc8080/1.34.0/pc8080-dbg.js index 36134948b..745196ed1 100644 --- a/versions/pc8080/1.34.0/pc8080-dbg.js +++ b/versions/pc8080/1.34.0/pc8080-dbg.js @@ -54,8 +54,8 @@ var Ra={"&":"&","<":"<",">":">",'"':""","'":"'"},Ua={0:"NUL" function Wa(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function Xa(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;cb.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Qa=g.load;d.Ia=g.exec;if(e=g.bytes)d.ma=e;else if(e=g.words)for(d.ma=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.ma=Array(4*e.length),f=c=0;c>8&255,d.ma[f++]=e[c]>>16&255,d.ma[f++]=e[c]>>24&255;else d.ma=g;d.ra=g.symbols;d.ma.length?1==d.ma.length&&(q(d.ma[0]),d=null):(q("Empty resource: "+a),d=null)}catch(h){q("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Qa=g.load;d.Ia=g.exec;if(e=g.bytes)d.ka=e;else if(e=g.words)for(d.ka=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.ka=Array(4*e.length),f=c=0;c>8&255,d.ka[f++]=e[c]>>16&255,d.ka[f++]=e[c]>>24&255;else(e=g.data)?d.Mf=e:d.ka=g;d.ka&&(d.ka.length?1==d.ka.length&&(q(d.ka[0]),d=null):(q("Empty resource: "+a),d=null));d.ra=g.symbols}catch(h){q("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.Ca=!0};l.ge=function(a,b){if(this.K&&null!=this.J){var c=this.K;yc(c,this.J+a,1,c.I)&&c.da(!0)}return this.ob(a,b)};l.ke=function(a,b){if(this.K&&null!=this.J){var c=this.K;yc(c,this.J+a,2,c.I)&&c.da(!0)}return this.Nb(a,b)}; l.te=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;yc(d,this.J+a,1,d.w)&&d.da(!0)}this.u?this.rb(0,b):this.qb(a,b,c)};l.xe=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;yc(d,this.J+a,2,d.w)&&d.da(!0)}this.u?this.rb(0,b):this.Sb(a,b,c)};l.fe=function(a){return this.g[a]};l.he=function(a){return this.g[a]};l.je=function(a){return this.R.getUint16(a,!0)};l.le=function(a){return a&1?this.g[a]|this.g[a+1]<<8:this.w[a>>1]};l.se=function(a,b){this.g[a]=b;this.Ca=!0}; l.ue=function(a,b){this.g[a]=b;this.Ca=!0};l.we=function(a,b){this.R.setUint16(a,b,!0);this.Ca=!0};l.ye=function(a,b){a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.w[a>>1]=b;this.Ca=!0};var dc=0,fc=2,Ib=["NONE","RAM","ROM","VID","H/W"],cc=0,tc=[],sc=[z.prototype.ie,z.prototype.ve,z.prototype.me,z.prototype.ze],wc=[z.prototype.ge,z.prototype.te,z.prototype.ke,z.prototype.xe];if(xb)var ic=[z.prototype.fe,z.prototype.se,z.prototype.je,z.prototype.we],hc=[z.prototype.he,z.prototype.ue,z.prototype.le,z.prototype.ye]; -function zc(a,b){n.call(this,"CPU",a,1);var c=a.multiplier||1;this.Fa=a.cycles||b;this.U=c;this.Ta=Math.round(this.Fa/1E4)/100;this.Z=this.Ta*this.U;this.G.ka=!1;this.G.Qb=!1;this.G.lb=a.autoStart;this.G.Bc=!1;this.G.Wa=!1;this.ya=this.oa=0;this.za=a.csStart;this.na=a.csInterval;this.sa=a.csStop;this.T=[];this.Db=this.tb.bind(this);Aa(this)}aa(zc,n);l=zc.prototype; +function zc(a,b){n.call(this,"CPU",a,1);var c=a.multiplier||1;this.Fa=a.cycles||b;this.U=c;this.Ta=Math.round(this.Fa/1E4)/100;this.Z=this.Ta*this.U;this.G.la=!1;this.G.Qb=!1;this.G.lb=a.autoStart;this.G.Bc=!1;this.G.Wa=!1;this.ya=this.oa=0;this.za=a.csStart;this.na=a.csInterval;this.sa=a.csStop;this.T=[];this.Db=this.tb.bind(this);Aa(this)}aa(zc,n);l=zc.prototype; l.Ea=function(a,b,c,d){this.R=a;this.H=b;this.K=d;for(b=0;b=a.oa&&(a.oa+=a.na,c=!0);0<=a.sa&&a.sa<=Ic(a)&&(a.na=a.sa=-1,Dc(a),a.da(),c=!0);c&&a.i(Ic(a)+" cycles: checksum="+t(a.ya))}} -l.ca=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.P[b]=c;a=!0;break;case "run":this.P[b]=c;c.onclick=function(){var a;if(a=d.R)if(a=d.R,a.G.ja)a=!0;else{var b=null,c,h=ka(a.id);for(c=0;c=a.oa&&(a.oa+=a.na,c=!0);0<=a.sa&&a.sa<=Ic(a)&&(a.na=a.sa=-1,Dc(a),a.da(),c=!0);c&&a.i(Ic(a)+" cycles: checksum="+t(a.ya))}} +l.ca=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.P[b]=c;a=!0;break;case "run":this.P[b]=c;c.onclick=function(){var a;if(a=d.R)if(a=d.R,a.G.ja)a=!0;else{var b=null,c,h=ka(a.id);for(c=0;ca.Y/a.Z?b=1:d=!0;a.U=b;b=a.Ta*a.U;if(a.Z!=b){a.Z=b;b=a.Z.toFixed(2)+"Mhz";var e=a.P.setSpeed;e&&(e.textContent=b);a.i("target speed: "+b)}c&&a.R&&a.R.Za()}Kc(a,a.X);a.X=0;a.V=ga();a.ea=0;Lc(a);return d}function Nc(a,b){var c=a.T.length;a.T.push([-1,b]);return c}function Oc(a,b,c){0<=b&&ba.T[b][0]&&(c*=a.Fa*a.U/1E3,a.T[b][0]=c+Pc(a))}function Pc(a,b){var c=a.ga-=a.b;a.b=0;b&&(a.ga=0);return c} -l.tb=function(a){if(Da(this,!0)){if(!this.G.ka){Jc(this);this.R&&this.R.start(this.V,Ic(this));this.G.ka=!0;this.G.Qb=!0;this.W&&this.W.start();var b=this.P.run;b&&(b.textContent="Halt");this.R&&(Qc(this.R,!0),a&&this.R.Za(!0))}this.Va>=this.Fa&&Lc(this,!0);this.Ha=0;this.Ma=ga();this.ea&&(a=this.Ma-this.ea,a>this.jb&&(this.V+=a,this.V>this.Ma&&(this.V=this.Ma)));try{do{for(var c,d=this.G.Wa?1:this.Na,e=this.T.length-1;0<=e;e--){var f=this.T[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.Eb(c);c=Pc(this,!0); -this.Ha+=c;this.X+=c;Hc(this,c);a=c;for(var g=this.T.length-1;0<=g;g--){var h=this.T[g];0>h[0]||(h[0]-=a,0>=h[0]&&(h[0]=-1,h[1]()))}this.wa-=c;if(0>=this.wa){this.wa+=this.Na;++this.kb>=Rc&&(this.R&&Qc(this.R),this.kb=0);break}}while(this.G.ka)}catch(k){this.da();Gc(this);this.R&&this.R.stop(ga(),Ic(this));Da(this,!1);xa(this,k.stack||k.message);return}c=setTimeout;d=this.Db;this.ea=ga();e=this.jb;this.Ha&&(e=Math.round(e*this.Ha/this.Na));e-=this.ea-this.Ma;if(f=this.ea-this.V)this.Y=Math.round(this.X/ -(10*f))/100,864E5<=f&&(this.la=0,Jc(this));if(0>e||this.Ye&&(this.V-=e),e=0;this.Va+=this.Ha;this.ea+=e;c(d,e)}else Gc(this),this.R&&this.R.stop(ga(),Ic(this))};l.Eb=function(){return 0};l.da=function(a){Ca(this,!0);Pc(this);Kc(this,this.X);this.X=0;if(this.G.ka){this.G.ka=!1;this.W&&this.W.stop();var b=this.P.run;b&&(b.textContent="Run")}this.G.complete=a};function Gc(a,b){if(a.R){for(var c=a.R,d=0;d=this.Fa&&Lc(this,!0);this.Ha=0;this.Ma=ga();this.ea&&(a=this.Ma-this.ea,a>this.jb&&(this.V+=a,this.V>this.Ma&&(this.V=this.Ma)));try{do{for(var c,d=this.G.Wa?1:this.Na,e=this.T.length-1;0<=e;e--){var f=this.T[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.Eb(c);c=Pc(this,!0); +this.Ha+=c;this.X+=c;Hc(this,c);a=c;for(var g=this.T.length-1;0<=g;g--){var h=this.T[g];0>h[0]||(h[0]-=a,0>=h[0]&&(h[0]=-1,h[1]()))}this.wa-=c;if(0>=this.wa){this.wa+=this.Na;++this.kb>=Rc&&(this.R&&Qc(this.R),this.kb=0);break}}while(this.G.la)}catch(k){this.da();Gc(this);this.R&&this.R.stop(ga(),Ic(this));Da(this,!1);xa(this,k.stack||k.message);return}c=setTimeout;d=this.Db;this.ea=ga();e=this.jb;this.Ha&&(e=Math.round(e*this.Ha/this.Na));e-=this.ea-this.Ma;if(f=this.ea-this.V)this.Y=Math.round(this.X/ +(10*f))/100,864E5<=f&&(this.ma=0,Jc(this));if(0>e||this.Ye&&(this.V-=e),e=0;this.Va+=this.Ha;this.ea+=e;c(d,e)}else Gc(this),this.R&&this.R.stop(ga(),Ic(this))};l.Eb=function(){return 0};l.da=function(a){Ca(this,!0);Pc(this);Kc(this,this.X);this.X=0;if(this.G.la){this.G.la=!1;this.W&&this.W.stop();var b=this.P.run;b&&(b.textContent="Run")}this.G.complete=a};function Gc(a,b){if(a.R){for(var c=a.R,d=0;d>8&255;a.A=b&255}function od(a){return a.B<<8|a.C}function pd(a,b){a.B=b>>8&255;a.C=b&255}function D(a){return a.D<<8|a.F} function qd(a,b){a.D=b>>8&255;a.F=b&255}function A(a,b){a.j=b&65535}function rd(a){return a.I&256?1:0}function sd(a,b){a.I=a.I&255|b}function td(a){return yb[a.L&255]?4:0}function ud(a){return(a.L^a.O)&16?16:0}function vd(a){return a.I&255?0:64}function wd(a){return a.L&128?128:0}function kd(a){return a.N&-214|wd(a)|vd(a)|ud(a)|td(a)|rd(a)}function Xc(a,b){a.I=a.L=a.O=0;b&1&&(a.I|=256);b&4||(a.L|=1);b&16&&(a.O|=16);b&64||(a.I|=255);b&128&&(a.L^=192);a.N=a.N&-726|b&512|2} function xd(a,b){a.O=a.g^b;return a.L=(a.I=a.g+b)&255}function yd(a,b){a.O=a.g^b;return a.L=(a.I=a.g+b+(a.I&256?1:0))&255}function zd(a,b){a.I=a.L=a.O=a.g&b;(a.g|b)&8&&(a.O^=16);return a.I}function Ad(a,b){a.O=b^255;b=a.L=b+255&255;a.I=a.I&-256|b;return b}function Bd(a,b){a.O=b;b=a.L=b+1&255;a.I=a.I&-256|b;return b}function Cd(a,b){return a.L=a.I=a.O=a.g|b}function Dd(a,b){b^=255;a.O=a.g^b;return a.L=(a.I=a.g+b+1^256)&255} function Ed(a,b){b^=255;a.O=a.g^b;return a.L=(a.I=a.g+b+(a.I&256?0:1)^256)&255}function Fd(a,b){return a.L=a.I=a.O=a.g^b}function E(a,b){a=a.H;return a.b[(b&a.C)>>>a.g].Ya(b&a.j,b)}function Gd(a,b,c){a=a.H;a.b[(b&a.C)>>>a.g].$a(b&a.j,c&255,b)}function F(a){var b=E(a,a.j);A(a,a.j+1);return b}function G(a){var b=Lb(a.H,a.j);A(a,a.j+2);return b}function Hd(a){var b=Lb(a.H,a.M);a.M=a.M+2&65535;return b}function H(a,b){a.M=a.M-2&65535;Qb(a.H,a.M,b)} -function Id(a){if(a.b&&a.S&255&&a.N&512){for(var b=0;8>b&&!(a.S&1<b?255:1<b&&!(a.S&1<b?255:1<>8;sd(this,a&256);this.b-=4},Md,function(){var a;qd(this,a=D(this)+md(this));sd(this,a>>8&256);this.b-=10},function(){this.g=E(this,md(this));this.b-=7},function(){nd(this,md(this)-1);this.b-= @@ -138,12 +138,12 @@ J.INIT=[[J.Oc.INIT,J.xa.ic|J.xa.dd],[J.Ka.Uc,J.Ka.Vc],[J.ub.Xc,J.ub.Tc,J.ub.Wc,J [11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11904,11776,11784,11918,11808,11984,11856,11776,11808,11776,12E3,12E3,11881,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]]];Td.Bb={0:Qd.prototype.Jd,1:Qd.prototype.Kd,2:Qd.prototype.Ld,3:Qd.prototype.Id}; Td.Cb={2:Qd.prototype.Wd,3:Qd.prototype.Yd,4:Qd.prototype.Xd,5:Qd.prototype.Zd,6:Qd.prototype.$d};J.Bb={66:Qd.prototype.Md};J.Cb={66:Qd.prototype.ae,98:Qd.prototype.de,162:Qd.prototype.ce,194:Qd.prototype.be};ob(function(){for(var a=qa(document,"pc8080","chipset"),b=0;b>>0,g],v=Va(u,k,a.Ac);0>v&&u.splice(-(v+1),0,k)}p&&(h.a=p.replace(/''/g,'"'))}a.A.push({Mf:b,J:c,Qd:d,ra:e,zc:f})}delete this.ra}return!0};Yd.prototype.ua=function(){return!0}; +Yd.prototype.va=function(){if(this.ra){if(this.K){var a=this.K,b=this.id,c=this.A,d=this.g,e=this.ra,f=[],g;for(g in e){var h=e[g];"number"==typeof h&&(e[g]=h={o:h});var k=h.o,p=h.a;if(void 0!==k){var u=f,k=[k>>>0,g],v=Va(u,k,a.Ac);0>v&&u.splice(-(v+1),0,k)}p&&(h.a=p.replace(/''/g,'"'))}a.A.push({Nf:b,J:c,Qd:d,ra:e,zc:f})}delete this.ra}return!0};Yd.prototype.ua=function(){return!0}; function Zd(a,b,c,d){if(d)a.aa("Unable to load system ROM (error "+d+": "+b+")");else{ea(a.eb,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.data;if(f)a.b=f;else if(g)for(a.b=Array(4*g.length),d=c=0;c>8&255,a.b[d++]=g[c]>>16&255,a.b[d++]=g[c]>>24&255;else a.b=e;a.ra=e.symbols;if(!a.b.length){q("Empty ROM: "+b);return}if(1==a.b.length){q(a.b[0]);return}}catch(h){a.aa("ROM data error: "+h.message);return}else for(b=c.replace(/\n/gm, " ").replace(/ +$/,"").split(" "),a.b=Array(b.length),e=0;e>>f.g;0>>= f.g;0"]]= 229,N[m["<"]]=230,N[m.hc]=231,N[m.Ub]=232,N[m.wc]=233,N[m["?"]]=245,N[m.gc]=246,N[m.tc]=248,N[m.Vb]=249,N[m.wb]=250,N),Tb:{},fb:{},Ua:{"caps-lock":20,ctrl:17,esc:27,tab:9,"num-comma":116,"break":117,"line-feed":118,"no-scroll":119,setup:120},Nc:{qa:130,INIT:127},Ba:{qa:130,bd:1,ad:2,$c:4,Zc:8,cd:16,fc:32,ec:63,od:64,Ce:128,INIT:0},Yc:127};K.fb={l4:K.Ba.bd,l3:K.Ba.ad,l2:K.Ba.$c,l1:K.Ba.Zc,locked:K.Ba.cd,local:K.Ba.fc,online:~K.Ba.fc,"caps-lock":Je};var Ee={SI1978:Pe,VT100:K}; K.INIT=[[K.Ba.INIT,K.Nc.INIT,!1,0,-1]];K.Bb={130:ie.prototype.Nd};K.Cb={130:ie.prototype.ee};ob(function(){for(var a=qa(document,"pc8080","keyboard"),b=0;b>3)*a.N,!Fb(a.H,a.la,a.L,3)))return!1;a.L?(a.Va=a.j.createImageData(b,c),a.hb=16/a.na|0,gf(a,a.L>>1)):gf(a,(a.O+1)*a.Z);a.D=document.createElement("canvas");a.D.width=b;a.D.height=c;a.wa=a.D.getContext("2d");a.T={};a.X=1<>3)*a.N,!Fb(a.H,a.ma,a.L,3)))return!1;a.L?(a.Va=a.j.createImageData(b,c),a.hb=16/a.na|0,gf(a,a.L>>1)):gf(a,(a.O+1)*a.Z);a.D=document.createElement("canvas");a.D.width=b;a.D.height=c;a.wa=a.D.getContext("2d");a.T={};a.X=1<=a.Ha?8:16,f=8>4)*c)}return k}l.va=function(a,b){return b||!a||this.restore(a)?!0:!1};l.ua=function(a){return!a||this.save()};l.save=function(){var a=new ld(this);a.set(0,[]);return a.data()};l.restore=function(){return!0}; l.Xa=function(){var a=!1;if(this.b){if(this.b.Xa){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.M/this.I;b>c&&(a=Math.round(c/b*100)+"%")}this.Ta?(this.F.style.width=a,this.F.style.width=a,this.F.style.display="block",this.F.style.margin="auto"):(this.b.style.width=a,this.b.style.height="auto");this.b.style.backgroundColor="black";this.b.Xa();a=!0}this.V&&this.V.focus()}return a}; function ef(a,b){!b&&a.b&&(a.Ta?a.F.style.width=a.F.style.height="":a.b.style.width=a.b.style.height="");Fa(a,"notifyFullScreen("+b+")")}function gf(a,b){a.gb=b;a.W=!1;if(void 0===a.A||a.A.length!=a.gb)a.A=Array(a.gb)}function sf(a,b,c,d,e){d=a.g?(b.height-c-1)*b.width+d:c+d*b.width;e&&a.Y==jf&&(208<=c&&236>c?e=a.X+kf:28<=c&&72>c&&(e=a.X+lf));a=a.U[e];d*=a.length;b.data[d]=a[0];b.data[d+1]=a[1];b.data[d+2]=a[2];b.data[d+3]=a[3]} -function Sc(a,b){var c=!0;if(!b){a.oa&&(120==a.oa?a.ib&1?(Jd(a.u,2),c=!1):Jd(a.u,1):Jd(a.u,4));if(c&&a.W&&a.L){for(var d=a.H,e=a.L,f=!0,g=a.la>>>d.g;0>=1);;){var y=Kb(a.H,u++);if((y&tf)==tf){var w=Kb(a.H,u++),d=w&uf,c=(w&vf)<<8|Kb(a.H,u),c=c+(w&wf? +function Sc(a,b){var c=!0;if(!b){a.oa&&(120==a.oa?a.ib&1?(Jd(a.u,2),c=!1):Jd(a.u,1):Jd(a.u,4));if(c&&a.W&&a.L){for(var d=a.H,e=a.L,f=!0,g=a.ma>>>d.g;0>=1);;){var y=Kb(a.H,u++);if((y&tf)==tf){var w=Kb(a.H,u++),d=w&uf,c=(w&vf)<<8|Kb(a.H,u),c=c+(w&wf? xf:yf);break}if(p>4)*y.ba,L,ja,ua,na,Ma=y.fa,ec=y.ba;C?(L=B*w.fa,ja=e*w.ba,ua=w.fa,na=w.ba):(L=B*w.La,ja=e*w.Ma,ua=w.La,na=w.Ma);y.fa>w.fa&&(L*=2,ua*=2);y.ba>w.ba&&(v==rf&&(T+=w.ba),ec=w.ba);C?C.drawImage(y.canvas,za,T,Ma,ec,L,ja,ua,na):(L+=0,ja+=0,w.j.drawImage(y.canvas, -za,T,Ma,ec,L,ja,ua,na))}h++}g++}e++}}a.W=!0;!b&&a.ya&&1==h&&(a.A[k]=-1,h=0);a.ya=!1;(h||b)&&a.wa&&a.j.drawImage(a.D,0,a.sa,a.C,a.N-a.ba,0,0,a.Db,a.td)}else{e=a.la;f=e+a.L;k=h=g=0;b=a.C;p=0;c=a.N;v=d=0;u=a.na;B=(1<>8|(w&255)<<8);h>C&B,sf(a,a.Va,h++,k,za),C+=u;h>p&&(p=h);k=d&&(d=k+1)}e+=2;g++;if(h>=a.C&&(h=0,k++,k>a.N))break}a.W=!0;b>8|(w&255)<<8);h>C&B,sf(a,a.Va,h++,k,za),C+=u;h>p&&(p=h);k=d&&(d=k+1)}e+=2;g++;if(h>=a.C&&(h=0,k++,k>a.N))break}a.W=!0;bMissing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=cb().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= (a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||ib("aspect"));f&&.3<=f&&3.33>=f&&(mb("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");hb("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new bf(d,e,g,f,c);pa(d,c)}}); @@ -203,13 +203,13 @@ d))}return d}function Wf(a,b){for(var c,d=/\{(.*?)\}/;(c=b.match(d))&&!(0<=c[1]. function Xf(a,b,c,d){var e;null!=b?(e=a.Kb(b),0<=e?e=a.Lb(e):(e=a.S[b],null==e&&(e=Ha(b,a.na))),null!=e||d||a.i("invalid "+(c?c:"value")+": "+b)):d||a.i("missing "+(c||"value"));return e} function Zf(a,b,c){var d,e=!1;if(void 0!==c){e=!0;d=c;var f=4,g="";if(!f||4>=1,y--;g=v+g;d>>=8}d=t(c,0,!0)+" "+c+". "+Ia(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.i((null!=b?b+": ":"")+d);return e} function ag(a,b){if(b)return Zf(a,b,a.S[b]);var c=0;for(b in a.S)Zf(a,b,a.S[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Yf={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};function bg(a){Tf.call(this,a);this.style=cg;this.F=dg();this.la=dg();this.O=dg();this.A=[];this.j=this.I=this.w=[];eg(this);this.W=0;fg(this);this.Z={};gg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Fc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Fc(b,a)})}aa(bg,Tf);l=bg.prototype; +var Yf={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};function bg(a){Tf.call(this,a);this.style=cg;this.F=dg();this.ma=dg();this.O=dg();this.A=[];this.j=this.I=this.w=[];eg(this);this.W=0;fg(this);this.Z={};gg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Fc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Fc(b,a)})}aa(bg,Tf);l=bg.prototype; l.Ea=function(a,b,c,d){this.H=b;this.u=c;this.R=a;(a=Bc(a,"messages"))&&gg(this,a);this.ga=hg;Sd(this,64,function(a){a:{var b=d.H.b,c=a[0],e=a=0,k=b.length;if(c){a=ig(jg(d,c));if(-1===a){d.i("invalid address: "+c);break a}e=a>>>d.H.g;k=1}d.i("blockid physical blockaddr used size type");d.i("-------- --------- ---------- ------ ------ ----");for(var c=-1,p=0;k--;){var u=b[e];u.type==c?p++||d.i("..."):(c=u.type,p=Ib[c],u&&d.i(t(u.id)+" %"+t(e<>>e.g;f!=e.j?e.b[g].Sb(f,b&65535,d):(e.b[g++].qb(f,b&255,d),e.b[g&e.I].qb(0,b>>8&255,d+1));c&&lg(a,c);Gc(this.u,!0)}};function dg(a){return{J:a,Da:!1}}function mg(a){return[a.J,a.Da]}function ng(a){return{J:a[0],Da:a[1]}} -function jg(a,b,c){var d;c=(c?a.F:a.la).J;if(void 0!==b){d=b=Wf(a,b);var e;if(d.match(/^[a-z_][a-z0-9_]*$/i))for(d=d.toUpperCase(),c=0;cc&&(c=Xa(Pg,a.substr(b,1))));return c};function Qg(a,b){var c=0;a=a.Lb(b);if(void 0!==a)switch(b){case Rg:case Sg:case Tg:case Ug:case Vg:case Wg:case Xg:case Yg:c=2;break;case Zg:case $g:case ah:case bh:case ch:case dh:case eh:c=4}return c?t(a,c):"??"} l.Lb=function(a){var b;if(0<=a){var c=this.u;switch(a){case Rg:b=c.g;break;case Sg:b=c.w;break;case Tg:b=c.A;break;case Zg:b=md(c);break;case Ug:b=c.B;break;case Vg:b=c.C;break;case $g:b=od(c);break;case Wg:b=c.D;break;case Xg:b=c.F;break;case ah:b=D(c);break;case Yg:b=E(c,D(c));break;case bh:b=c.M;break;case ch:b=c.j;break;case dh:b=kd(c);break;case eh:b=kd(c)&255|c.g<<8}}return b}; @@ -218,14 +218,14 @@ function fh(a,b){b=Wf(a,b);for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.Kb(b,c+1 function Ga(a,b,c,d,e,f,g,h){h|=256;null!=f&&(a.ha&h)!=h||a.message(b.cb+"."+(null!=d?"outPort":"inPort")+"("+x(c)+","+(f?f:"unknown")+(null!=d?","+Ja(d):"")+")"+(null!=g?": "+Ja(g):"")+(null!=e?" at "+Ng(e):""))} function fg(a){var b;if(Kd(a)){if(!a.D||!a.D.length){a.D=Array(gh);for(b=0;b>>d.g],!1)}a.I=["br"];if(a.w)for(b=1;b>>d.g],!0);a.w=["bw"];a.oa=0}l.Pa=function(a,b,c){var d=!0;c||mh(this,a,b,!1,!0);if(a!=this.j){var e=ig(b);if(-1===e)this.i("invalid address: "+Ng(b.J)),d=!1;else{var f=this.H;f.b[e>>>f.g].Pa(e&f.j,a==this.w)}}d&&(a.push(b),c?b.Da=!0:(nh(this,a,a.length-1,"set"),fg(this)));return d}; function mh(a,b,c,d,e){var f=!1;c=ig(c);for(var g=1;g>>d.g],b==a.w));h.Da||fg(a);break}}return f}function oh(a,b){for(var c=1;c>24,4);break;case Bh:C=t(y.Gb(C,2),4);break;default:y="imm("+x(w)+")";break a}y.style==rh&&w&Ch?C="["+C+"]":w&Dh||(C=(y.style==cg?"$":"0x")+C);y=C}else w&Dh?(y=(v&Eh)>>8, w=Pg[y],a.style==rh&&v&Ch&&(y==Yg&&(w="HL"),w="["+w+"]"),y=w):w&Fh&&(y=(f>>3&7).toString());if(!y||!y.length){h="INVALID";break}0b[0]?1:a[0]Za.length&&(a.i("note: only "+Za.length+" available"),Ba=Za.length);Na-=Ba;0>Na&&(null==Za[Za.length-1].J?(Ba=Na+Ba,Na=0):Na+=Za.length);var me=[];"call"==sg&&(jc=1E5,me=["CALL"]);for(void 0!==rg&&a.i(Ba+" instructions earlier:");0< jc&&Na!=a.T;){var vg=Za[Na++];if(null==vg.J)break;var kc=dg(vg.J),vi=Ba--,wg=qh(a,kc,"history",vi);(!me.length||0<=wg.indexOf(me[0]))&&a.i(wg);kc.Jb&&(Na+=kc.Jb,jc-=kc.Jb,Ba-=kc.Jb);Na>=Za.length&&(Na=0);a.sa=Ba;ug++;jc--}}ug||(a.i("no "+tg+"history available"),a.sa=void 0)}else{var Yc=jg(a,na);if(Yc){var Zc=0;Ma&&("l"==Ma.charAt(0)&&(Ma=Ma.substr(1)||ec),Zc=Xf(a,Ma)>>>0,65536>4||1;wi--&&0cd?String.fromCharCode(cd):".";ad--}lc&&(lc+="\n");lc+=na+" "+oe+(mc?"":" "+xg)}lc&&a.i(lc);a.la=Yc}}}}break;case "e":if("else"==f[0])break;var dd=1,yg=255,zg=a.Ga,Ag=a.Xb;"ew"==f[0]&&(dd=2,yg=65535,zg=a.Gb,Ag=a.Qc);var Bg=dd<<1,Cg=f[1];if(null==Cg)a.i("edit memory commands:"),a.i("\teb [a] [...] edit bytes at address a"),a.i("\tew [a] [...] edit words at address a"); +xg="",na=Ng(Yc.J);for(mc=16;0cd?String.fromCharCode(cd):".";ad--}lc&&(lc+="\n");lc+=na+" "+oe+(mc?"":" "+xg)}lc&&a.i(lc);a.ma=Yc}}}}break;case "e":if("else"==f[0])break;var dd=1,yg=255,zg=a.Ga,Ag=a.Xb;"ew"==f[0]&&(dd=2,yg=65535,zg=a.Gb,Ag=a.Qc);var Bg=dd<<1,Cg=f[1];if(null==Cg)a.i("edit memory commands:"),a.i("\teb [a] [...] edit bytes at address a"),a.i("\tew [a] [...] edit words at address a"); else{var ed=jg(a,Cg);if(ed)for(var fd=2;fdve;){for(var ub=null,Ci=256;65536>pc.J>>>0;){Eg.J=a.Gb(pc,2);if(null==pc.J||!Ci--)break;for(var Di=a,hd=Eg, Fg=null,qc=hd.J,Gg=qc,we=1;6>=we&&qc;we++){if(2":62,"?":63,"@":64,Ia:65,sb:66,tb:67,kb:68,E:69,wb:70,xb:71,yb:72,zb:73,Ab:74,Bb:75,lb:76,Fb:77,Gb:78,Jb:79,Kb:80,Q:81,Lb:82,Nb:83,Ob:84,Pb:85,Rb:86,Sb:87, Ub:88,Vb:89,$a:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Wb:97,Rc:98,Tc:99,d:100,e:101,Xc:102,Yc:103,Zc:104,$c:105,jd:106,k:107,kd:108,ld:109,n:110,md:111,p:112,q:113,r:114,Kd:115,t:116,Ld:117,Md:118,Nd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ae:127},aa={59:186,61:187,173:189,224:91}; -function p(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Tb=b.comment;this.Uc=b;this.exports={};this.w=this.bindings={};a=this.id.indexOf(".");0>a?this.Ya=this.id:(this.Ka=this.id.substr(0,a),this.Ya=this.id.substr(a+1));this.i={ready:!1,ab:!1,nb:!1,U:!1,error:!1};this.eb=null;this.i.error=!1;this.J=this.m=this.u=this.D=this.pa=null;r.push(this)}function ba(a,b,c){ca[a]&&b&&(ca[a][b]=c)}function ea(){return Date.now()||+new Date} +function p(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Tb=b.comment;this.Uc=b;this.exports={};this.w=this.bindings={};a=this.id.indexOf(".");0>a?this.Ya=this.id:(this.Ka=this.id.substr(0,a),this.Ya=this.id.substr(a+1));this.i={ready:!1,ab:!1,nb:!1,V:!1,error:!1};this.eb=null;this.i.error=!1;this.J=this.m=this.u=this.D=this.pa=null;r.push(this)}function ba(a,b,c){ca[a]&&b&&(ca[a][b]=c)}function ea(){return Date.now()||+new Date} function fa(a,b,c){b||t((c?c+": ":"")+a)}function t(a){window&&window.alert(a)}function ga(a){var b=!1;window&&(b=window.confirm(a));return b}function ha(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b":">",'"':""","'":"'"},Ba={0:"NUL" function Ca(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function Da(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var m="",q;for(q in b)b.hasOwnProperty(q)&&(m&&(m+="&"),m+=q+"="+encodeURIComponent(b[q]));m=m.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(m)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={W:null,sa:null,Aa:null,ta:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Aa=g.load;d.ta=g.exec;if(e=g.bytes)d.W=e;else if(e=g.words)for(d.W=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.W=Array(4*e.length),f=c=0;c>8&255,d.W[f++]=e[c]>>16&255,d.W[f++]=e[c]>>24&255;else d.W=g;d.sa=g.symbols;d.W.length?1==d.W.length&&(t(d.W[0]),d=null):(t("Empty resource: "+a),d=null)}catch(h){t("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Aa=g.load;d.ta=g.exec;if(e=g.bytes)d.T=e;else if(e=g.words)for(d.T=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.T=Array(4*e.length),f=c=0;c>8&255,d.T[f++]=e[c]>>16&255,d.T[f++]=e[c]>>24&255;else(e=g.data)?d.hf=e:d.T=g;d.T&&(d.T.length?1==d.T.length&&(t(d.T[0]),d=null):(t("Empty resource: "+a),d=null));d.sa=g.symbols}catch(h){t("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca.R/a.X&&(b=1);a.O=b;b=a.Ea*a.O;if(a.X!=b){a.X=b;b=a.X.toFixed(2)+"Mhz";var d=a.w.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.D&&Ob(a.D)}a.I+=a.P;a.P=0;a.L=ea();a.V=0;Lb(a)}function Pb(a,b){var c=a.H.length;a.H.push([-1,b]);return c}function Qb(a,b,c){0<=b&&ba.H[b][0]&&(c*=a.na*a.O/1E3,a.H[b][0]=c+Rb(a))}function Rb(a,b){var c=a.da-=a.a;a.a=0;b&&(a.da=0);return c} -k.jb=function(a){if(ra(this,!0)){if(!this.i.ka){Kb(this);this.D&&this.D.start(this.L,Nb(this));this.i.ka=!0;this.i.fc=!0;this.N&&this.N.start();var b=this.w.run;b&&(b.textContent="Halt");this.D&&(Sb(this.D,!0),a&&Ob(this.D,!0))}this.Ga>=this.na&&Lb(this,!0);this.oa=0;this.va=ea();this.V&&(a=this.va-this.V,a>this.Pa&&(this.L+=a,this.L>this.va&&(this.L=this.va)));try{do{for(var c,d=this.i.bb?1:this.ya,e=this.H.length-1;0<=e;e--){var f=this.H[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.vb(c);c=Rb(this,!0); +function Kb(a,b,c){if(void 0!==b){.8>a.R/a.X&&(b=1);a.O=b;b=a.Ea*a.O;if(a.X!=b){a.X=b;b=a.X.toFixed(2)+"Mhz";var d=a.w.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.D&&Ob(a.D)}a.I+=a.P;a.P=0;a.L=ea();a.W=0;Lb(a)}function Pb(a,b){var c=a.H.length;a.H.push([-1,b]);return c}function Qb(a,b,c){0<=b&&ba.H[b][0]&&(c*=a.na*a.O/1E3,a.H[b][0]=c+Rb(a))}function Rb(a,b){var c=a.da-=a.a;a.a=0;b&&(a.da=0);return c} +k.jb=function(a){if(ra(this,!0)){if(!this.i.ka){Kb(this);this.D&&this.D.start(this.L,Nb(this));this.i.ka=!0;this.i.fc=!0;this.N&&this.N.start();var b=this.w.run;b&&(b.textContent="Halt");this.D&&(Sb(this.D,!0),a&&Ob(this.D,!0))}this.Ga>=this.na&&Lb(this,!0);this.oa=0;this.va=ea();this.W&&(a=this.va-this.W,a>this.Pa&&(this.L+=a,this.L>this.va&&(this.L=this.va)));try{do{for(var c,d=this.i.bb?1:this.ya,e=this.H.length-1;0<=e;e--){var f=this.H[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.vb(c);c=Rb(this,!0); this.oa+=c;this.P+=c;a=c;this.i.bb&&(b=!1,this.wa=this.wa+this.$b()|0,this.ea-=a,0>=this.ea&&(this.ea+=this.ha,b=!0),0<=this.la&&this.la<=Nb(this)&&(this.ha=this.la=-1,Hb(this),Jb(this),b=!0),b&&this.aa(Nb(this)+" cycles: checksum="+B(this.wa)));a=c;for(var g=this.H.length-1;0<=g;g--){var h=this.H[g];0>h[0]||(h[0]-=a,0>=h[0]&&(h[0]=-1,h[1]()))}this.ma-=c;if(0>=this.ma){this.ma+=this.ya;++this.Qa>=Tb&&(this.D&&Sb(this.D),this.Qa=0);break}}while(this.i.ka)}catch(m){Jb(this);Ib(this);this.D&&this.D.stop(ea(), -Nb(this));ra(this,!1);c=m.stack||m.message;this.i.error=!0;this.G(c);return}c=setTimeout;d=this.mb;this.V=ea();e=this.Pa;this.oa&&(e=Math.round(e*this.oa/this.ya));e-=this.V-this.va;if(f=this.V-this.L)this.R=Math.round(this.P/(10*f))/100,864E5<=f&&(this.I=0,Kb(this));if(0>e||this.Re&&(this.L-=e),e=0;this.Ga+=this.oa;this.V+=e;c(d,e)}else Ib(this),this.D&&this.D.stop(ea(),Nb(this))};k.vb=function(){return 0}; +Nb(this));ra(this,!1);c=m.stack||m.message;this.i.error=!0;this.G(c);return}c=setTimeout;d=this.mb;this.W=ea();e=this.Pa;this.oa&&(e=Math.round(e*this.oa/this.ya));e-=this.W-this.va;if(f=this.W-this.L)this.R=Math.round(this.P/(10*f))/100,864E5<=f&&(this.I=0,Kb(this));if(0>e||this.Re&&(this.L-=e),e=0;this.Ga+=this.oa;this.W+=e;c(d,e)}else Ib(this),this.D&&this.D.stop(ea(),Nb(this))};k.vb=function(){return 0}; function Jb(a){a.i.ab&&(a.i.nb=!0);Rb(a);a.I+=a.P;a.P=0;if(a.i.ka){a.i.ka=!1;a.N&&a.N.stop();var b=a.w.run;b&&(b.textContent="Run")}a.i.complete=void 0}function Ib(a){if(a.D){for(var b=a.D,c=0;c>8-this.H&255};k.qd=function(a,b){this.H=b};k.sd=function(a,b){this.P=b};k.rd=function(a,b){this.B=b<<8|this.B>>8};k.td=function(a,b){this.R=b};k.ud=function(){};function xc(a){var b=0,c=0,d=~a.A;for(a=0;10>a;a++)d&1&&(b=9-a),d>>=1;for(a=0;10>a;a++)d&1&&(c=9-a),d>>=1;return 10*b+c} k.gd=function(){var a=this.s,a=a&~V.ga.Hb;if((Nb(this.m)&64)<<1&&(a|=V.ga.Hb,a!=this.s)){var b,c;b=this.v&1;switch(this.v>>1&7){case V.ia.Ca.kc:this.A=this.A<<1|b;break;case V.ia.Ca.pc:b=xc(this);this.j[b]=V.ia.Za;break;case V.ia.Ca.lc:this.a=this.a<<1|b;break;case V.ia.Ca.Pc:b=xc(this);c=this.a&V.ia.Za;this.j[b]=c;break;case V.ia.Ca.Kc:b=xc(this);c=this.j[b];null==c&&(c=V.ia.Za);this.a=c;break;case V.ia.Ca.Lc:this.a<<=1,this.F=this.a&V.ia.Za+1}}a&=~V.ga.Ib;this.F&&(a|=V.ga.Ib);a&=~V.ga.Cb;if(b=this.h){b= -this.h;if(c=b.h)c=b.m,c=Nb(b.m)>=b.o+c.na*c.O/1E3*1.2731488;c&&(b.h=!1);b=!b.h}b&&(a|=V.ga.Cb);a&=~V.ga.Qb;this.g&&this.g.T&yc&&(a|=V.ga.Qb);return this.s=a};k.vd=function(a,b){this.N=b};k.yd=function(a,b){this.v=b};k.xd=function(a,b){a=b&3;switch(b>>2&3){case 0:this.c=this.c&-4|a;break;case 1:this.c=this.c&-13|a<<2;this.video&&(b=this.video,a=this.c,b.la!==a&&((b.la=a)?Ub(b,!0):b.na=!0));break;case 2:switch(a){case 0:this.C=~this.C;break;case 2:case 3:this.O=3-a}break;case 3:this.L=a}}; +this.h;if(c=b.h)c=b.m,c=Nb(b.m)>=b.o+c.na*c.O/1E3*1.2731488;c&&(b.h=!1);b=!b.h}b&&(a|=V.ga.Cb);a&=~V.ga.Qb;this.g&&this.g.U&yc&&(a|=V.ga.Qb);return this.s=a};k.vd=function(a,b){this.N=b};k.yd=function(a,b){this.v=b};k.xd=function(a,b){a=b&3;switch(b>>2&3){case 0:this.c=this.c&-4|a;break;case 1:this.c=this.c&-13|a<<2;this.video&&(b=this.video,a=this.c,b.la!==a&&((b.la=a)?Ub(b,!0):b.na=!0));break;case 2:switch(a){case 0:this.C=~this.C;break;case 2:case 3:this.O=3-a}break;case 3:this.L=a}}; k.wd=function(a,b){b&V.ua.Jc?(b&=V.ua.Mb,this.o!=b&&(this.o=b,this.video&&(this.video.bc=this.o==V.ua.Mb?50:60))):(b&=V.ua.ub,this.l!=b&&(this.l=b,this.video&&(a=this.video,b=this.l==V.ua.ub?132:80,a.C=b,a.M=a.va,80>>f.b;0>>=f.b;0"]]= 229,Y[n["<"]]=230,Y[n.Gb]=231,Y[n.sb]=232,Y[n.Ub]=233,Y[n["?"]]=245,Y[n.Fb]=246,Y[n.Rb]=248,Y[n.tb]=249,Y[n.$a]=250,Y),rb:{},La:{},Fa:{"caps-lock":20,ctrl:17,esc:27,tab:9,"num-comma":116,"break":117,"line-feed":118,"no-scroll":119,setup:120},mc:{Z:130,INIT:127},fa:{Z:130,Ac:1,zc:2,yc:4,xc:8,Bc:16,Eb:32,Db:63,Mc:64,Zd:128,INIT:0},wc:127};W.La={l4:W.fa.Ac,l3:W.fa.zc,l2:W.fa.yc,l1:W.fa.xc,locked:W.fa.Bc,local:W.fa.Eb,online:~W.fa.Eb,"caps-lock":Sc};var Nc={SI1978:Yc,VT100:W}; W.INIT=[[W.fa.INIT,W.mc.INIT,!1,0,-1]];W.fb={130:Mc.prototype.hd};W.gb={130:Mc.prototype.zd};Na(function(){for(var a=y(document,"pc8080","keyboard"),b=0;b>3)*a.B,!cb(a.u,a.da,a.v,3)))return!1;a.v?(a.Ga=a.c.createImageData(b,c),a.Na=16/a.ea|0,qd(a,a.v>>1)):qd(a,(a.C+1)*a.R);a.l=document.createElement("canvas");a.l.width=b;a.l.height=c;a.ma=a.l.getContext("2d");a.H={};a.O=1<=a.va?8:16,f=8>(7=a.va?8:16,f=8>(7>4)*c)}return m}k.ca=function(a,b){return b||!a||this.restore(a)?!0:!1};k.ba=function(a){return!a||this.save()};k.save=function(){var a=new E(this);a.set(0,[]);return a.data()};k.restore=function(){return!0}; k.Ha=function(){var a=!1;if(this.a){if(this.a.Ha){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.A/this.s;b>c&&(a=Math.round(c/b*100)+"%")}this.Ea?(this.o.style.width=a,this.o.style.width=a,this.o.style.display="block",this.o.style.margin="auto"):(this.a.style.width=a,this.a.style.height="auto");this.a.style.backgroundColor="black";this.a.Ha();a=!0}this.L&&this.L.focus()}return a}; function od(a,b){!b&&a.a&&(a.Ea?a.o.style.width=a.o.style.height="":a.a.style.width=a.a.style.height="")}function qd(a,b){a.Ma=b;a.N=!1;if(void 0===a.g||a.g.length!=a.Ma)a.g=Array(a.Ma)}function Bd(a,b,c,d,e){d=a.b?(b.height-c-1)*b.width+d:c+d*b.width;e&&a.P==sd&&(208<=c&&236>c?e=a.O+td:28<=c&&72>c&&(e=a.O+ud));a=a.I[e];d*=a.length;b.data[d]=a[0];b.data[d+1]=a[1];b.data[d+2]=a[2];b.data[d+3]=a[3]} @@ -179,33 +179,33 @@ function Id(a){p.call(this,"SerialPort",a);this.H=+a.adapter;switch(this.H){case k=Id.prototype;k.S=function(a,b,c,d){var e=this;switch(b){case Jd:return this.w[b]=this.b=c,c.onkeydown=function(a){a=a||window.event;var b=a.keyCode;if(8===b||a.ctrlKey&&65<=b&&90>=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Aa(c[0]);if(d!=this.Ya)return;c=Aa(c[1]);if(this.a=ia(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.l);if(this.Ba=e.receiveData){this.l=a;this.s=e.receiveStatus;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; -k.ca=function(a,b){if(!b)if(this.ac(this.l),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};k.ba=function(a){return a?this.save():!0};k.reset=function(){Nd(this)};k.save=function(){var a=new E(this),b=0,c=[];c[b++]=this.o;c[b++]=this.A;c[b++]=this.C;c[b++]=this.T;c[b++]=this.h;c[b++]=this.j;c[b]=this.v;a.set(0,c);return a.data()};k.restore=function(a){return Nd(this,a[0])}; -function Nd(a,b){var c=0;b||(b=Od);a.o=b[c++];a.A=b[c++];a.C=b[c++];a.T=b[c++];a.h=b[c++];a.j=b[c++];a.v=b[c];return!0}function Pd(a,b){var c=a.v&b;b&15||(c>>=4);b=Qd[c];c=((a.h&Rd)>>2)+6;a.h&Sd&&c++;c+=((a.h&Td)>>6)+1>>1;return 1E3/Math.round(b/c)}function Kd(a,b){return a.B||a.T&Ud?!1:(a.A=b,a.T|=Ud,rc(a.m,a.O),!0)} -k.pb=function(a){null!=a&&(this.g="number"!=typeof a?a:this.g+String.fromCharCode(a));this.g&&(Kd(this,this.g.charCodeAt(0))&&(this.g=this.g.substr(1)),this.g&&this.m&&Qb(this.m,this.P,Pd(this,Vd)));return!0};k.Jd=function(a){this.T&=~Wd;a&64&&(this.T|=Wd)};function Uc(a,b){a.T=a.T|yc|Xd;b&&a.Ba&&a.Ba.call(a.a,b)}k.bd=function(){var a=this.A;this.T&=~Ud;return a};k.ad=function(){return this.T}; -k.pd=function(a,b){this.C=b;this.T&=~(yc|Xd);if(19==b)this.B=!0;else if(17==b)this.B=!1;else if(this.Ba&&this.Ba.call(this.a,b),this.b)if(8==b)this.b.value=this.b.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;9==b?(b=this.L||8,c=b-this.f%b,this.L&&(a=" ".slice(0,c))):13==b&&(this.f=c=0,a="\n");this.F&&!this.f&&c&&(a=String.fromCharCode(this.F)+a);this.b.value+=a;this.b.scrollTop=this.b.scrollHeight; +k.ca=function(a,b){if(!b)if(this.ac(this.l),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};k.ba=function(a){return a?this.save():!0};k.reset=function(){Nd(this)};k.save=function(){var a=new E(this),b=0,c=[];c[b++]=this.o;c[b++]=this.A;c[b++]=this.C;c[b++]=this.U;c[b++]=this.h;c[b++]=this.j;c[b]=this.v;a.set(0,c);return a.data()};k.restore=function(a){return Nd(this,a[0])}; +function Nd(a,b){var c=0;b||(b=Od);a.o=b[c++];a.A=b[c++];a.C=b[c++];a.U=b[c++];a.h=b[c++];a.j=b[c++];a.v=b[c];return!0}function Pd(a,b){var c=a.v&b;b&15||(c>>=4);b=Qd[c];c=((a.h&Rd)>>2)+6;a.h&Sd&&c++;c+=((a.h&Td)>>6)+1>>1;return 1E3/Math.round(b/c)}function Kd(a,b){return a.B||a.U&Ud?!1:(a.A=b,a.U|=Ud,rc(a.m,a.O),!0)} +k.pb=function(a){null!=a&&(this.g="number"!=typeof a?a:this.g+String.fromCharCode(a));this.g&&(Kd(this,this.g.charCodeAt(0))&&(this.g=this.g.substr(1)),this.g&&this.m&&Qb(this.m,this.P,Pd(this,Vd)));return!0};k.Jd=function(a){this.U&=~Wd;a&64&&(this.U|=Wd)};function Uc(a,b){a.U=a.U|yc|Xd;b&&a.Ba&&a.Ba.call(a.a,b)}k.bd=function(){var a=this.A;this.U&=~Ud;return a};k.ad=function(){return this.U}; +k.pd=function(a,b){this.C=b;this.U&=~(yc|Xd);if(19==b)this.B=!0;else if(17==b)this.B=!1;else if(this.Ba&&this.Ba.call(this.a,b),this.b)if(8==b)this.b.value=this.b.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;9==b?(b=this.L||8,c=b-this.f%b,this.L&&(a=" ".slice(0,c))):13==b&&(this.f=c=0,a="\n");this.F&&!this.f&&c&&(a=String.fromCharCode(this.F)+a);this.b.value+=a;this.b.scrollTop=this.b.scrollHeight; this.f+=c}else if(null!=this.c){if(10==b||1024<=this.c.length)this.aa(this.c),this.c="";10!=b&&(this.c+=String.fromCharCode(b))}this.m&&Qb(this.m,this.R,Pd(this,Yd))};k.od=function(a,b){this.o?(this.s&&(b^this.j)&(Zd|$d)&&(a=0,this.l?(a|=b&Zd?32:0,a|=b&$d?320:0):(a|=b&Zd?16:0,a|=b&$d?1048576:0),this.s.call(this.a,a)),this.j=b,this.j&ae&&(this.o=!1)):(this.h=b,this.o=!0)};k.nd=function(a,b){this.v=b}; var Rd=12,Sd=16,Td=192,$d=2,Zd=32,ae=64,yc=1,Ud=2,Xd=4,Wd=128,Vd=15,Yd=240,Qd=[50,75,110,134.5,150,200,300,600,1200,1800,2E3,2400,3600,4800,9600,19200],Od=[!1,0,0,133,142,39,238],Jd="buffer",Ld={0:Id.prototype.bd,1:Id.prototype.ad},Md={0:Id.prototype.pd,1:Id.prototype.od,2:Id.prototype.nd};Na(function(){for(var a=y(document,"pc8080","serial"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bde){if(fe(d,this.o)){this.f=new E(this,"1.34.0",oe);fe(this.f)&&(pe(this,d),a=qe,re(this.f));this.f.set(le,Ca());se(this.f);var e=this.a&&!this.j;if(a==me||ga("Click OK to restore the previous PC8080 machine state, or CANCEL to reset the machine.")){if(c=ke(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?fe(d,g):("error"==f&&"no machine state"!= g?(this.G("Error: "+g),"unable to verify user"==g&&(Ia(te,""),this.b=null)):this.aa(f+": "+g),re(d),fe(d)?(c=ke(d),e=!0):c=!1))}e&&ie(this,c?d:null)}else a==qe&&d.clear()}else ie(this);delete this.o;delete this.s}e=ha(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.i.U=!0;var d=this.w.power;d&&(d.textContent="Shutdown");this.m&&(ue(this,this.m,b,c,a),this.m.Sa());this.B&&(pe(this,b),b.clear());!c&&this.f&&(this.f.clear(),delete this.f);this.c=0}; +function ue(a,b,c,d,e){if(!b.i.V){b.i.V=!0;if(b.ca){var f=null;e&&((f=c.get(b.id))||(f=c.get(b.id.replace(/[a-z0-9]\./i,"."))));"string"===typeof f&&(f=null);!b.ca(f,d)&&f&&(t("Unable to restore state for "+b.type),a.A&&!a.C?(c.clear(),a.a=de,window&&window.location.reload()):a.B=!0,b.ca(null),e=!1)}if(!d&&b.Tb)for(a=b.Tb.split("|"),c=0;ca[1];a=a[2];this.N=!0;this.i.V=!0;var d=this.w.power;d&&(d.textContent="Shutdown");this.m&&(ue(this,this.m,b,c,a),this.m.Sa());this.B&&(pe(this,b),b.clear());!c&&this.f&&(this.f.clear(),delete this.f);this.c=0}; function pe(a,b){if(ga("There may be a problem with your PC8080 machine.\n\nTo help us diagnose it, click OK to send this PC8080 machine state to http://www.pcjs.org.")){var c=a.b||"";b=b.toString();var d={app:"PC8080",ver:"1.34.0"};d.url=a.I;d.user=c;d.type="bug";d.data=b;Da("http://www.pcjs.org/api/v1/report",d,!0)}} -function ve(a,b,c){var d,e="none";if(a.c)return null;a.c--;var f=new E(a,"1.34.0"),g=new E(a,"1.34.0",je),h=Ca();g.set(le,h);f.set(le,h);f.set(we,"1.34.0");f.set(xe,window?window.location.href:null);f.set(ye,window?window.navigator.userAgent:"");a.m&&a.m.ba&&(c&&Jb(a.m),d=a.m.ba(b,c),"object"===typeof d&&f.set(a.m.id,d),c&&(a.m.i.U=!1,!1===d&&(e=null)));for(var h=ha(a.id),m=0;ma?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ra=Math.pow(2,36),sa=-Math.pow(2,35),q={ac:0,ob:1,cc:2,dc:3,ec:4,fc:5,gc:6,hc:7,Za:8,ic:9,pb:10,jc:11,kc:12,qb:13,lc:14,mc:15,nc:16,oc:17,pc:18,qc:19,rc:20,sc:21,tc:22,uc:23,vc:24,wc:25,xc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,$b:66,bc:67,yc:68,E:69,zc:70,Ac:71,Bc:72,Cc:73,Dc:74,Ec:75,Fc:76,Gc:77,Hc:78,Ic:79,Jc:80,Q:81, +var la=Math.pow(2,36),sa=-Math.pow(2,35),q={ac:0,ob:1,cc:2,dc:3,ec:4,fc:5,gc:6,hc:7,Za:8,ic:9,pb:10,jc:11,kc:12,qb:13,lc:14,mc:15,nc:16,oc:17,pc:18,qc:19,rc:20,sc:21,tc:22,uc:23,vc:24,wc:25,xc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,$b:66,bc:67,yc:68,E:69,zc:70,Ac:71,Bc:72,Cc:73,Dc:74,Ec:75,Fc:76,Gc:77,Hc:78,Ic:79,Jc:80,Q:81, Kc:82,Lc:83,Mc:84,Nc:85,Oc:86,Pc:87,Qc:88,Rc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Sc:97,Tc:98,Uc:99,d:100,e:101,Vc:102,Wc:103,Xc:104,Yc:105,Zc:106,k:107,$c:108,ad:109,n:110,bd:111,p:112,q:113,r:114,cd:115,t:116,ed:117,fd:118,gd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.j={ready:!1,Fa:!1,Va:!1,U:!1,error:!1};this.Na=null;this.j.error=!1;this.V=c||0;this.A=this.g=this.D=this.C=this.ka=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.j={ready:!1,Fa:!1,Va:!1,W:!1,error:!1};this.Na=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.la=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function v(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function w(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function gb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function Za(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function H(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +function ib(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function ib(a,b){var c,d={W:null,T:null,ja:null,ia:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ja=f.load;d.ia=f.exec;if(e=f.bytes)d.W=e;else if(e=f.words)for(d.W=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.W=Array(4*e.length),g=c=0;c>8&255,d.W[g++]=e[c]>>16&255,d.W[g++]=e[c]>>24&255;else(e=f.data)?d.Aa=e:d.W=f;d.W&&(d.W.length?1==d.W.length&&(v(d.W[0]),d=null):(v("Empty resource: "+a),d=null));d.T=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Tb,reset:this.Pb, -set:this.Sb};E(this)}p(Nb,t);l=Nb.prototype;l.reset=function(a){this.stop();a&&Pb(this,this.w=0)}; -l.ea=function(a,b,c,d){if(this.C&&this.C.ea(a,b,c,d)||this.g&&this.g.ea(a,b,c,d)||this.A&&this.A.ea(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.K++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.K++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Qb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Rb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Qb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Rb(a,b)}}(this,b),!0):t.prototype.ea.call(this,a,b,c,d)}};l.ua=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Sb(this);Tb(this)};l.ma=function(a,b){if(!b)if(this.S&&Ub(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.da=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.w,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Vb(this,this.i=a[0]),Pb(this,this.w=a[1]),Wb(this,a[2]);return!0};l.Pb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Tb(this);return!0};function Xb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Sb(a,b){for(var c in a.B)Xb(a,c,null!=b?b:a.B[c])}function Yb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Tb(a){for(var b in a.b)Yb(a,b,a.b[b][1])} -l.yb=function(a,b,c){if(Qb(this,b)){if(c){var d=this;setTimeout(function(){Rb(d,b);a&&a()},+c);return!1}Rb(this,b)}return!0};l.Sb=function(a,b){if("SR"==a)return Wb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Yb(this,a,c[1]),!0):!1};l.Tb=function(a){return Qb(this,a)?(Rb(this,a),!0):!1};function Qb(a,b){var c=a.b[b];return c?(Yb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Zb&&(a.N=b==$b,a.O=b==ac),!0):!1} -function Rb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Yb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.J||(this.g.i=this.i%Hb,this.b[bc]&&this.b[bc][1]&&cc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.R()}; -l.Ab=function(a){if(!a&&!this.g.j.J)if(this.b[bc]&&this.b[bc][1])cc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),dc(a,0,null),Ma(a,!1);else try{var b=this.g.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.v)return h.Ia+=h.v-e,h.v=e,!0;if(e>=h.v+h.Ia){m=h.size-(e-k);m>g&&(m=g);h.Ia=e-h.v+m;e=k+16384;g-=m;f++;continue}}return oc(pc,e,g)}e=new M(a,e,m,16384,d);lc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Gc[d]+" at "+Qa(b)),!0):oc(Hc,b,c)} -function jc(a,b){var c=a.b[(b&a.u)>>>a.i];a.w++;b=c.i(b&16383,b);a.w--;return b}function ic(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function mc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.fa&&(a.fa+=a.ba,c=!0);0<=a.ga&&a.ga<=bd(a)&&(a.ba=a.ga=-1,Yc(a),a.R(),c=!0);c&&a.f(bd(a)+" cycles: checksum="+F(a.ra))}} -l.ea=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.U)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.O/a.P?b=1:d=!0;a.S=b;b=a.Ra*a.S;if(a.P!=b){a.P=b;b=a.P.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&fd(a.C)}fc(a,a.F);a.F=0;a.B=va();a.I=0;dd(a);return d}function gd(a,b){for(var c=a.H.length-1;0<=c;c--){var d=a.H[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function hd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function id(a,b){var c=a.K-=a.L;a.L=0;b&&(a.K=0);return c} -l.Qb=function(){if(this.j.J){this.ya>=this.Ta&&dd(this,!0);this.ha=0;this.qa=va();if(this.I){var a=this.qa-this.I;a>this.Sa&&(this.B+=a,this.B>this.qa&&(this.B=this.qa))}try{do{var b=gd(this,this.j.Ea?1:this.ta);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=id(this,!0);this.ha+=b;this.F+=b;gc(this,b);ec(this,b);this.Y-=b;if(0>=this.Y){this.Y+=this.ta;++this.Ua>=jd&&(this.C&&K(this.C,void 0),this.Ua=0);break}}while(this.j.J)}catch(e){this.R();this.C&&this.C.stop(va(),bd(this));Ia(this,e.stack|| -e.message);return}if(this.j.J){a=setTimeout;b=this.fb;this.I=va();var c=this.Sa;this.ha&&(c=Math.round(c*this.ha/this.ta));var c=c-(this.I-this.qa),d=this.I-this.B;d&&(this.O=Math.round(this.F/(10*d))/100,864E5<=d&&(this.M=0,cd(this)));if(0>c||this.Oc&&(this.B-=c),c=0;this.ya+=this.ha;this.I+=c;a(b,c)}}}; -function cc(a,b){if(!Ja(a))if(a.j.J)a.f(a.toString()+" busy");else{cd(a);a.j.J=!0;a.j.Qa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&fd(a.C,!0),a.C.start(a.B,bd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ja=function(){return 0};l.R=function(a){var b=!1;if(this.j.J){id(this);fc(this,this.F);this.F=0;this.j.J=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),bd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var ed=30,jd=15,Vc=["power","reset"]; -function kd(a){var b=+a.model||1001;Uc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=ld.bind(this);this.b=O.bind(this);this.na=null;this.ab=[];this.j.complete=!1}p(kd,Uc);l=kd.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.J&&this.R();this.w=this.N=this.za=0;this.oa=this.i=this.pa=this.bb;this.u=0;this.aa=this.Mb;this.wa=this.Zb;this.na=null;Xc(this);this.j.error=!1;Uc.prototype.reset.call(this)};l.lb=function(){return 0}; -l.save=function(){var a=new J(this);a.set(0,[this.w,this.N,this.za,this.i,this.pa,this.oa,this.u]);a.set(1,[]);a.set(2,[this.M,this.S,this.j.X]);a.set(3,md(this));a.set(4,hd(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.w=b.next().value;this.N=b.next().value;this.za=b.next().value;this.i=b.next().value;this.pa=b.next().value;this.oa=b.next().value;this.u=b.next().value;b=a[2];this.M=b[0];cd(this,b[1]);this.j.X=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].aa(a&16383,a)};l.Zb=function(a,b){var c=this.D;a=this.oa=a;c.b[(a&c.u)>>>c.i].wa(b,a&16383,a)}; -l.Ja=function(a){this.j.complete=!0;var b=this.A?od(this.A)?1:this.j.Qa?-1:0:0,c=a?this.j.Qa?0:1:-1;this.j.Qa=!1;this.K=this.L=a;this.u=this.u&-5|(b?4:0);do{if(this.u){if(this.u&4){if(pd(this.A,this.i,c)){this.R();break}++b||(this.u&=-5);c||c++}if(a=this.u&11)this.u&2?this.na||(this.u&=-3):this.u&1&&this.u++,a=!1;if(a){if(this.u&4&&pd(this.A,this.i,c)){this.R();break}if(0>c)break}}this.u&=15;this.N=this.N&4194304?this.aa(this.w):this.za=this.aa(this.pa=this.i);this.w=this.N&262143;if(a=this.N>>18& -15)this.w=this.w+this.aa(a)&Ib;this.N&4194304?a=-1:(this.i=(this.i+1)%Hb,a=this.za/Mb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function rd(a){this.b(a)}function sd(a){this.b(a)}function td(a){a&=15;var b=this.aa(this.w),c=this.aa(a);this.wa(a,(c&262143)+(b-(b&262143)))} -function W(a){this.b(a)}function O(a){this.f("undefined opcode: "+Qa(a));nd(this,-1);this.R()} -var qd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function jb(a,b){var c,d={Y:null,V:null,ka:null,ja:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ka=f.load;d.ja=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;c>8&255,d.Y[g++]=e[c]>>16&255,d.Y[g++]=e[c]>>24&255;else(e=f.data)?d.Aa=e:d.Y=f;d.Y&&(d.Y.length?1==d.Y.length&&(v(d.Y[0]),d=null):(v("Empty resource: "+a),d=null));d.V=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Tb,reset:this.Pb, +set:this.Sb};E(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.v=0)}; +l.fa=function(a,b,c,d){if(this.C&&this.C.fa(a,b,c,d)||this.g&&this.g.fa(a,b,c,d)||this.A&&this.A.fa(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Rb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Sb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.fa.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.na=function(a,b){if(!b)if(this.U&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ea=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.v=a[1]),Xb(this,a[2]);return!0};l.Pb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} +l.yb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Sb=function(a,b){if("SR"==a)return Xb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Tb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.O=b==ac,a.P=b==bc),!0):!1} +function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Ib,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.S()}; +l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ec(a,0,null),Ma(a,!1);else try{var b=this.g.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ia+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ia){m=h.size-(e-k);m>g&&(m=g);h.Ia=e-h.w+m;e=k+16384;g-=m;f++;continue}}return pc(qc,e,g)}e=new M(a,e,m,16384,d);mc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Hc[d]+" at "+Qa(b)),!0):pc(Ic,b,c)} +function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.i(b&16383,b);a.v--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function nc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.ga&&(a.ga+=a.ca,c=!0);0<=a.ha&&a.ha<=cd(a)&&(a.ca=a.ha=-1,Zc(a),a.S(),c=!0);c&&a.f(cd(a)+" cycles: checksum="+F(a.sa))}} +l.fa=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.W)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.P/a.R?b=1:d=!0;a.U=b;b=a.Ra*a.U;if(a.R!=b){a.R=b;b=a.R.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&gd(a.C)}gc(a,a.F);a.F=0;a.B=va();a.J=0;ed(a);return d}function hd(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function id(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function jd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} +l.Qb=function(){if(this.j.K){this.ya>=this.Ta&&ed(this,!0);this.ia=0;this.ra=va();if(this.J){var a=this.ra-this.J;a>this.Sa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=hd(this,this.j.Ea?1:this.ua);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=jd(this,!0);this.ia+=b;this.F+=b;hc(this,b);fc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Ua>=kd&&(this.C&&K(this.C,void 0),this.Ua=0);break}}while(this.j.K)}catch(e){this.S();this.C&&this.C.stop(va(),cd(this));Da(this, +e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=va();var c=this.Sa;this.ia&&(c=Math.round(c*this.ia/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.P=Math.round(this.F/(10*d))/100,864E5<=d&&(this.N=0,dd(this)));if(0>c||this.Pc&&(this.B-=c),c=0;this.ya+=this.ia;this.J+=c;a(b,c)}}}; +function dc(a,b){if(!Ja(a))if(a.j.K)a.f(a.toString()+" busy");else{dd(a);a.j.K=!0;a.j.Qa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&gd(a.C,!0),a.C.start(a.B,cd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ja=function(){return 0};l.S=function(a){var b=!1;if(this.j.K){jd(this);gc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),cd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var fd=30,kd=15,Wc=["power","reset"]; +function ld(a){var b=+a.model||1001;Vc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=md.bind(this);this.b=O.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(ld,Vc);l=ld.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.S();this.i=this.O=this.za=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Mb;this.T=this.Zb;this.oa=null;Yc(this);this.j.error=!1;Vc.prototype.reset.call(this)};l.lb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.i,this.O,this.za,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.N,this.U,this.j.Z]);a.set(3,nd(this));a.set(4,id(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.i=b.next().value;this.O=b.next().value;this.za=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.N=b[0];dd(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Zb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].T(b,a&16383,a)}; +l.Ja=function(a){this.j.complete=!0;var b=this.A?pd(this.A)?1:this.j.Qa?-1:0:0,c=a?this.j.Qa?0:1:-1;this.j.Qa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(qd(this.A,this.u,c)){this.S();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&qd(this.A,this.u,c)){this.S();break}if(0>c)break}}this.v&=15;this.O=this.O&4194304?this.H(this.i):this.za=this.H(this.qa=this.u);this.i=this.O&262143;if(a=this.O>>18&15)this.i= +this.i+this.H(a)&Jb;this.O&4194304?a=-1:(this.u=(this.u+1)%Ib,a=this.za/Nb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function sd(a){this.b(a)}function td(a){this.b(a)}function ud(a){a&=15;var b=this.H(this.i),c=this.H(a);this.T(a,(c&262143)+(b-(b&262143)))} +function vd(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a);this.T(a,c-(c&262143)+b)}function R(a){this.b(a)}function O(a){this.f("undefined opcode: "+Qa(a));od(this,-1);this.S()} +var rd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},rd,sd,sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},rd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,td,td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, @@ -111,114 +111,117 @@ function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a) function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){a&=15;var b=this.aa(a);this.wa(a,b&262143)},function(a){a=this.aa(a&15);var b=this.aa(this.w);this.wa(this.w,(b&262143)+(a-(a&262143)))},function(a){a&15&&td.call(this, -a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},ud,function(a){a&=15;var b=this.H(a);this.T(a,b&262143)},function(a){a=this.H(a&15);var b=this.H(this.i);this.T(this.i,(b&262143)+(a-(a&262143)))},function(a){a&15&&ud.call(this,a)}, +function(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a),c=(c&262143)+b*H;this.T(a,c)},function(a){a&=15;var b=this.H(a),b=(b&262143)+this.i*H;this.T(a,b)},function(a){a=this.H(a&15)&262143;var b=this.H(this.i),b=(b&262143)+a*H;this.T(this.i,b)},function(a){var b=this.H(this.i)&262143;this.T(this.i,b+b*H);if(a&=15)b=this.H(a)&262143,this.T(a,b+b*H)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,function(a){a&=15;var b=this.H(a),b=b-(b&262143)+this.i;this.T(a,b)},function(a){a=this.H(a&15)&262143;var b= +this.H(this.i);this.T(this.i,b-(b&262143)+a)},function(a){a&15&&vd.call(this,a)},function(a){a&=15;var b=this.H(this.i)/H|0,c=this.H(a);this.T(a,c-(c&262143)+b)},function(a){a&=15;var b=this.H(a);this.T(a,b-(b&262143))},function(a){a=this.H(a&15)/H|0;var b=this.H(this.i);this.T(this.i,b-(b&262143)+a)},function(a){var b=this.H(this.i);this.T(this.i,(b&262143)+(b/H|0));if(a&=15)b=this.H(a),this.T(a,(b&262143)+(b/H|0))},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W]; -function ud(a){t.call(this,"ROM",a,128);this.T=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.w=a.file;this.F=Ra(this.w);if(this.w){a=this.w;var b=Sa(this.F);"json"!=b&&"hex"!=b&&(a=Ua()+"/api/v1/dump?file="+this.w+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,g){g?(c.Z("Unable to load ROM resource (error "+g+": "+a+")"),c.w=null):(ta(c.La,a,b),(a=ib(a,b))?(c.b=a.W,c.T=a.T):c.w=null);vd(c)})}}p(ud,t); -ud.prototype.ua=function(a,b,c,d){this.D=b;this.g=c;this.A=d;vd(this)};ud.prototype.ma=function(){this.T&&(this.A&&wd(this.A,this.id,this.B,this.u,this.T),delete this.T);return!0};ud.prototype.da=function(){return!0}; -function vd(a){if(!Ka(a)){if(a.w){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ia(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(nc(a.D,b,a.u,Lc)){var c;for(c=0;c>>g.i;0>>= -g.i;0>>a.i;0f&&f>=sa&&(f+=ra);f=Math.trunc(Math.abs(f))%ra;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Oa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Oa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.ua=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; -l.nb=function(a){if(!this.b){var b=Wc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ka)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.ma=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.da=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Oa=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.w&&a.u.length&&(a.w=0);if(0>a.w||b!=a.u[a.w])a.u.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.u[a.w+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} -function Ed(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R, +R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; +function wd(a){t.call(this,"ROM",a,128);this.V=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Ra(this.v);if(this.v){a=this.v;var b=Sa(this.F);"json"!=b&&"hex"!=b&&(a=Ua()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;ib(a,null,!0,function(a,b,g){g?(c.ba("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(ta(c.La,a,b),(a=jb(a,b))?(c.b=a.Y,c.V=a.V):c.v=null);xd(c)})}}p(wd,t); +wd.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;xd(this)};wd.prototype.na=function(){this.V&&(this.A&&yd(this.A,this.id,this.B,this.u,this.V),delete this.V);return!0};wd.prototype.ea=function(){return!0}; +function xd(a){if(!Ka(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Da(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(oc(a.D,b,a.u,Mc)){var c;for(c=0;c>>g.i;0>>= +g.i;0>>a.i;0f&&f>=sa&&(f+=la);f=Math.trunc(Math.abs(f))%la;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Oa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Oa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; +l.nb=function(a){if(!this.b){var b=Xc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ka)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ea=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Oa=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.P?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} +function Gd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Fd(a,b,c){var d;if(b){b=Gd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,R--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Kd(a,b){if(b)return Jd(a,b,a.Y[b]);var c=0;for(b in a.Y)Jd(a,b,a.Y[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Id={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Ld(a){Cd.call(this,a);this.xa=!1;this.na=!0;this.I=X();this.ta=X();this.N=X();this.H=[];this.b=this.K=this.F=[];Md(this);this.P=this.ha=0;this.i=[];this.qa=void 0;Nd(this);this.A=this;this.oa={};this.V=this.ib=0;this.S=null;this.M=[];Od(this,a.messages);this.sa=a.commands;this.L=0;this.Da=this.ra=null;this.B=this.za=this.ya=this.ga=this.pa=0;this.fa=this.ba=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return ad(b,a)}):void 0===global[C]&&(global[C]=function(a){return ad(b, -a)})}p(Ld,Cd);function Y(a){a=a&&a.v;null==a&&(a=-1);return a}function X(a,b,c){return{v:void 0===a?null:a,wb:void 0===b?!1:b,la:!1,ca:c}}function Pd(a){return[a.v,a.wb,a.ca,a.la,a.Pa]}function Qd(a,b){var c=X(b[0],b[1],b[2]);c.la=b[3];b[4]&&(c.gb=Dd(a,c.Pa=b[4]));return c}l=Ld.prototype; -l.ua=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.fa=a.u;(a=Wc(a,"messages"))&&Od(this,a);Rd(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Gc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.pa==b&&(b=nd(a.g,1)));if(0d&&(d=a.g.aa(b)),0<=d&&(c=a.i[a.P],c.v=b,c.la=!1,c.ca=void 0,++a.P==a.i.length&&(a.P=0)));return!1} -function Ge(a,b,c,d){var e=X(b.v),g=a.Ca(b,1),f,h,k,m=0,n=g/Kb|0,r;for(r in He)if(f=He[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ie;m=n&3;break;case 32256:k=Je;m=n&7;break;case 29248:k=Ke,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Le&&(k="B");k=Me[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Lb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=Td(g);g=k;f="";h=N(a,e.v)+":";if(-1!==e.v&&-1!==b.v){do if(k=a.Ca(e,1),f+=" "+Td(k),null== -e.v)break;while(e.v!=b.v)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Ea?h+("cycles="+bd(a.g).toString()+" cs="+F(a.g.ra)):h+(null!=d?"="+d.toString():""));return h}function Md(a){var b,c;a.b=["bp"];if(a.K)for(b=1;b>>d.i],!1)}a.K=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.pa=0;a.ha=0} -l.Ba=function(a,b,c){var d=!0;c||Ne(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.v)),d=!1;else{var g=this.D;g.b[e>>>g.i].Ba(e&16383,a==this.F)}}d&&(a.push(b),c?b.la=!0:(Oe(this,a,a.length-1,"set"),Nd(this)));return d};function Ne(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.F));h.la||Nd(a);break}}return g} -function Pe(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=gb(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.H.push({dd:b,v:c,zb:d,T:e,hb:g})} -function Se(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ge(a,b,f,g);a.f(g);a.I=b;e-=b.v-k;c++}}} -function Qe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ce+b):(a.O&&(a.f("ended assemble at "+N(a,a.N.v)),a.I=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.S=null;if(Ka(a)&&0n||"z"T.length&&(a.f("note: only "+T.length+" available"),L=T.length);P-=L;0>P&&(null==T[T.length-1].v?(L=P+L,P=0):P+=T.length);var uc=[];"call"==ee&&(Za=1E5,uc=["CALL"]);for(void 0!==de&&a.f(L+" instructions earlier:");0=T.length&&(P=0);a.qa=L;ge++;Za--}}ge||(a.f("no "+fe+"history available"), -a.qa=void 0)}else{var ma=Z(a,S);if(ma){var na=0,je="ds"==Fa;if(da){if("l"==da.charAt(0))da=da.substr(1)||Bf,na=Hd(a,da);else{var ke=Z(a,da);ke&&(na=ke.v-ma.v)}0>na&&(na=0);65536oe;oe++)me+=String.fromCharCode((Cb%64|0)+32), -Cb/=64}oa&&(oa+="\n");oa=je?oa+(pa+","):oa+(S+": "+pa+(0>ne?" "+me:""))}oa&&a.f(oa);a.ta=ma;a.ca=Df}}}}break;case "e":if("else"==f[0])break;var pe,qe,re=f[0],xc=f[1];"e"==re||"ew"==re?(pe=a.Ca,qe=a.$a):xc=null;if(null==xc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Db=Z(a,xc);if(Db)for(var Eb=2;EbBc;){for(var qa=null,Hf=256;65536>bb.v>>>0;){Cc.v=a.Ca(bb,2);if(null==bb.v||!Hf--)break;if(!(Cc.v&1)){for(var If=a,Fb=Cc,te=null,cb=Fb.v,ue=cb,Dc=1;6>=Dc&&cb;Dc++){if(2> ";tb(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bdf){if(ef(d,this.K)){this.B=new J(this,"1.34.0",of);ef(this.B)&&(pf(this,d),a=qf,rf(this.B));this.B.set(lf,hb());sf(this.B);var e=this.b&&!this.I;if(a==mf||wa("Click OK to restore the previous "+Bb+" machine state, or CANCEL to reset the machine.")){if(c=kf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?ef(d,f):("error"==g&&"no machine state"!= -f?(this.Z("Error: "+f),"unable to verify user"==f&&(mb(tf,""),this.i=null)):this.f(g+": "+f),rf(d),ef(d)?(c=kf(d),e=!0):c=!1))}e&&hf(this,c?d:null)}else a==qf&&d.clear()}else hf(this);delete this.K;delete this.H}e=w(this.id);for(g=0;ga[1];a=a[2];this.P=!0;this.j.U=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(uf(this,this.g,b,c,a),K(this,-2),this.g.X());this.N&&(pf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.w=0}; -function pf(a,b){if(wa("There may be a problem with your "+Bb+" machine.\n\nTo help us diagnose it, click OK to send this "+Bb+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=Bb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function Ye(a,b,c){var d,e="none";if(a.w)return null;a.w--;var g=new J(a,"1.34.0"),f=new J(a,"1.34.0",jf),h=hb();f.set(lf,h);g.set(lf,h);g.set(vf,"1.34.0");g.set(wf,window?window.location.href:null);g.set(xf,window?window.navigator.userAgent:"");a.g&&a.g.da&&(c&&(b&&(a.g.j.X=a.g.j.J),a.g.R()),d=a.g.da(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.U=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,S--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Md(a,b){if(b)return Ld(a,b,a.aa[b]);var c=0;for(b in a.aa)Ld(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Kd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Nd(a){Ed.call(this,a);this.xa=!1;this.oa=!0;this.J=X();this.ua=X();this.O=X();this.I=[];this.b=this.L=this.F=[];Od(this);this.R=this.ia=0;this.i=[];this.ra=void 0;Pd(this);this.A=this;this.pa={};this.X=this.ib=0;this.U=null;this.N=[];Qd(this,a.messages);this.ta=a.commands;this.M=0;this.Da=this.sa=null;this.B=this.za=this.ya=this.ha=this.qa=0;this.ga=this.ca=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return bd(b,a)}):void 0===global[C]&&(global[C]=function(a){return bd(b, +a)})}p(Nd,Ed);function Y(a){a=a&&a.w;null==a&&(a=-1);return a}function X(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ma:!1,da:c}}function Rd(a){return[a.w,a.wb,a.da,a.ma,a.Pa]}function Sd(a,b){var c=X(b[0],b[1],b[2]);c.ma=b[3];b[4]&&(c.gb=Fd(a,c.Pa=b[4]));return c}l=Nd.prototype; +l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ga=a.u;(a=Xc(a,"messages"))&&Qd(this,a);Td(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Hc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=od(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(c=a.i[a.R],c.w=b,c.ma=!1,c.da=void 0,++a.R==a.i.length&&(a.R=0)));return!1} +function Ie(a,b,c,d){var e=X(b.w),g=a.Ca(b,1),f,h,k,m=0,n=g/Lb|0,r;for(r in Je)if(f=Je[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ke;m=n&3;break;case 32256:k=Le;m=n&7;break;case 29248:k=Me,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Ne&&(k="B");k=Oe[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Mb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=Vd(g);g=k;f="";h=N(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.Ca(e,1),f+=" "+Vd(k),null== +e.w)break;while(e.w!=b.w)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Ea?h+("cycles="+cd(a.g).toString()+" cs="+F(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function Od(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.qa=0;a.ia=0} +l.Ba=function(a,b,c){var d=!0;c||Pe(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Ba(e&16383,a==this.F)}}d&&(a.push(b),c?b.ma=!0:(Qe(this,a,a.length-1,"set"),Pd(this)));return d};function Pe(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.F));h.ma||Pd(a);break}}return g} +function Re(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=Za(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.I.push({dd:b,w:c,zb:d,V:e,hb:g})} +function Ue(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ie(a,b,f,g);a.f(g);a.J=b;e-=b.w-k;c++}}} +function Se(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ee+b):(a.P&&(a.f("ended assemble at "+N(a,a.O.w)),a.J=a.O,a.P=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ka(a)&&0n||"z"U.length&&(a.f("note: only "+U.length+" available"),L=U.length);P-=L;0>P&&(null==U[U.length-1].w?(L=P+L,P=0):P+=U.length);var vc=[];"call"==ge&&($a=1E5,vc=["CALL"]);for(void 0!==fe&&a.f(L+" instructions earlier:");0<$a&&P!=a.R;){var je=U[P++];if(null==je.w)break;var ab=X(je.w),Ef=L--,ke=Ie(a,ab,"history",Ef);(!vc.length||0<=ke.indexOf(vc[0]))&&a.f(ke);ab.Wa&&(P+=ab.Wa,$a-=ab.Wa,L-=ab.Wa);P>=U.length&&(P=0);a.ra=L;ie++;$a--}}ie||(a.f("no "+he+"history available"), +a.ra=void 0)}else{var na=Z(a,T);if(na){var oa=0,le="ds"==Ga;if(ea){if("l"==ea.charAt(0))ea=ea.substr(1)||Df,oa=Jd(a,ea);else{var me=Z(a,ea);me&&(oa=me.w-na.w)}0>oa&&(oa=0);65536qe;qe++)oe+=String.fromCharCode((Db%64|0)+32), +Db/=64}pa&&(pa+="\n");pa=le?pa+(qa+","):pa+(T+": "+qa+(0>pe?" "+oe:""))}pa&&a.f(pa);a.ua=na;a.da=Ff}}}}break;case "e":if("else"==f[0])break;var re,se,te=f[0],yc=f[1];"e"==te||"ew"==te?(re=a.Ca,se=a.$a):yc=null;if(null==yc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Eb=Z(a,yc);if(Eb)for(var Fb=2;FbCc;){for(var ra=null,Jf=256;65536>cb.w>>>0;){Dc.w=a.Ca(cb,2);if(null==cb.w||!Jf--)break;if(!(Dc.w&1)){for(var Kf=a,Gb=Dc,ve=null,db=Gb.w,we=db,Ec=1;6>=Ec&&db;Ec++){if(2> ";ub(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bff){if(gf(d,this.L)){this.B=new J(this,"1.34.0",qf);gf(this.B)&&(rf(this,d),a=sf,tf(this.B));this.B.set(nf,hb());uf(this.B);var e=this.b&&!this.J;if(a==of||wa("Click OK to restore the previous "+Cb+" machine state, or CANCEL to reset the machine.")){if(c=mf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?gf(d,f):("error"==g&&"no machine state"!= +f?(this.ba("Error: "+f),"unable to verify user"==f&&(nb(vf,""),this.i=null)):this.f(g+": "+f),tf(d),gf(d)?(c=mf(d),e=!0):c=!1))}e&&kf(this,c?d:null)}else a==sf&&d.clear()}else kf(this);delete this.L;delete this.I}e=w(this.id);for(g=0;ga[1];a=a[2];this.R=!0;this.j.W=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(wf(this,this.g,b,c,a),K(this,-2),this.g.Z());this.O&&(rf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; +function rf(a,b){if(wa("There may be a problem with your "+Cb+" machine.\n\nTo help us diagnose it, click OK to send this "+Cb+" machine state to http://www.pcjs.org.")){var c=a.ca;a=a.i||"";b=b.toString();var d={};d.app=Cb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;ib("http://www.pcjs.org/api/v1/report",d,!0)}} +function $e(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new J(a,"1.34.0"),f=new J(a,"1.34.0",lf),h=hb();f.set(nf,h);g.set(nf,h);g.set(xf,"1.34.0");g.set(yf,window?window.location.href:null);g.set(zf,window?window.navigator.userAgent:"");a.g&&a.g.ea&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.S()),d=a.g.ea(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.W=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Da+=d))&&(e.textContent=c.j.J?c.O.toFixed(2)+"Mhz":"Stopped",c.Da=0)}if(a.u&&(a=a.u,b=b||0,a.K)){c=a.g.j.J;d=!!(a.g.u&8);if(0>=b||60<=(a.I+=b)){e=a.g.i;if(a.G.PC){var g=a.A&&a.A.ca||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.I=0}-1>b?a.i=a.g.i:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],f);Tf(a,b,c)}})}else c(a,null)} -function Uf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Qf||xb(!0));m=!1}var h,k,m=!0;Qf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Rf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Qf||xb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Qf|| -xb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Rf(c,b,a,e,!0,g,n):Sf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(R){f(R.message)}return m}window.embedPDP10=function(a,b,c,d){xb(!1);return Uf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){xb(!1);return Uf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n=d||30<=(c.Da+=d))&&(e.textContent=c.j.K?c.P.toFixed(2)+"Mhz":"Stopped",c.Da=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.da||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");ib(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);Vf(a,b,c)}})}else c(a,null)} +function Wf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Sf||yb(!0));m=!1}var h,k,m=!0;Sf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Tf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Sf||yb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Sf|| +yb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Tf(c,b,a,e,!0,g,n):Uf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(S){f(S.message)}return m}window.embedPDP10=function(a,b,c,d){yb(!1);return Wf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){yb(!1);return Wf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;na?-b:b}});ia("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +function n(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]}function ha(a,b){if(b){var c=m;a=a.split(".");for(var d=0;da?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); var ja=Math.pow(2,36),ka=-Math.pow(2,35),q={Cb:0,Ra:1,Eb:2,Fb:3,Gb:4,Hb:5,Ib:6,Jb:7,Ja:8,Kb:9,Sa:10,Lb:11,Mb:12,Ta:13,Nb:14,Ob:15,Pb:16,Qb:17,Rb:18,Sb:19,Tb:20,Ub:21,Vb:22,Wb:23,Xb:24,Yb:25,Zb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,Bb:66,Db:67,$b:68,E:69,ac:70,bc:71,cc:72,dc:73,ec:74,fc:75,gc:76,hc:77,ic:78,jc:79,kc:80,Q:81, lc:82,mc:83,nc:84,oc:85,pc:86,qc:87,rc:88,sc:89,Ya:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,tc:97,uc:98,vc:99,d:100,e:101,wc:102,xc:103,yc:104,zc:105,Ac:106,k:107,Bc:108,Cc:109,n:110,Dc:111,p:112,q:113,r:114,Ec:115,t:116,Fc:117,Gc:118,Hc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ua:127}; -function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.na=this.id:(this.oa=this.id.substr(0,a),this.na=this.id.substr(a+1));this.b={ready:!1,ta:!1,Ga:!1,w:!1,error:!1};this.wa=null;this.b.error=!1;this.o=this.f=this.l=this.m=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} +function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.na=this.id:(this.oa=this.id.substr(0,a),this.na=this.id.substr(a+1));this.b={ready:!1,ta:!1,Ga:!1,B:!1,error:!1};this.wa=null;this.b.error=!1;this.s=this.f=this.l=this.o=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function na(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, f,e))});if(b&&"object"==typeof b){var l="",p;for(p in b)b.hasOwnProperty(p)&&(l&&(l+="&"),l+=p+"="+encodeURIComponent(b[p]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} -function Ea(a,b){var c,d={F:null,L:null,S:null,R:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.S=g.load;d.R=g.exec;if(e=g.bytes)d.F=e;else if(e=g.words)for(d.F=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.F=Array(4*e.length),f=c=0;c>8&255,d.F[f++]=e[c]>>16&255,d.F[f++]=e[c]>>24&255;else(e=g.data)?d.X=e:d.F=g;d.F&&(d.F.length?1==d.F.length&&(x(d.F[0]),d=null):(x("Empty resource: "+a),d=null));d.L=g.symbols}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.T=g.load;d.S=g.exec;if(e=g.bytes)d.H=e;else if(e=g.words)for(d.H=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.H=Array(4*e.length),f=c=0;c>8&255,d.H[f++]=e[c]>>16&255,d.H[f++]=e[c]>>24&255;else(e=g.data)?d.Y=e:d.H=g;d.H&&(d.H.length?1==d.H.length&&(x(d.H[0]),d=null):(x("Empty resource: "+a),d=null));d.N=g.symbols}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.o=this.f=this.l=this.m=null;this.exports={hold:this.$a,toggle:this.ub,reset:this.qb, -set:this.tb};E(this)}n(Wa,t);k=Wa.prototype;k.reset=function(a){this.stop();a&&M(this,this.h=0)}; -k.T=function(a,b,c,d){if(this.m&&this.m.T(a,b,c,d)||this.f&&this.f.T(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.B++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.B++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){N(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){N(a,b)}}(this,b),!0):t.prototype.T.call(this,a,b,c,d)}};k.Y=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;Za(this);$a(this)};k.U=function(a,b){if(!b)if(this.P&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.O=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])P(this,this.c=a[0]),M(this,this.h=a[1]),bb(this,a[2]);return!0};k.qb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} -k.$a=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){N(d,b);a&&a()},+c);return!1}N(this,b)}return!0}; +var C="pdp10",L="PDPjs",Sa=Math.pow(2,18),Ta=Math.pow(2,18)-1,Ua=Math.pow(2,36),M=Math.pow(2,18),Va=Math.pow(2,23),C="pdp10",L="PDPjs"; +function Wa(a,b){t.call(this,"Panel",a);this.C=this.D=0;this.R=b;this.c=this.v=this.g=this.h=0;this.G=this.I=-1;this.L=this.M=this.u=!1;this.O=Xa;this.j={};this.a={START:[1,1,!0,!1,this.ib],STEP:[1,1,!1,!1,this.jb],ENABLE:[1,1,!1,!1,this.cb],CONT:[1,1,!0,!1,this.ab],DEP:[0,0,!0,!1,this.bb],EXAM:[1,1,!0,!1,this.eb],LOAD:[1,1,!0,!1,this.gb],TEST:[0,0,!0,!1,this.fb]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.s=this.f=this.l=this.o=null;this.exports={hold:this.$a,toggle:this.ub,reset:this.qb, +set:this.tb};E(this)}n(Wa,t);k=Wa.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; +k.U=function(a,b,c,d){if(this.o&&this.o.U(a,b,c,d)||this.f&&this.f.U(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.D++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.D++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):t.prototype.U.call(this,a,b,c,d)}};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.s=d;Za(this);$a(this)};k.V=function(a,b){if(!b)if(this.R&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.P=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),N(this,this.h=a[1]),bb(this,a[2]);return!0};k.qb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} +k.$a=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; k.tb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.M(this.c);M(this,this.h=a)}};k.gb=function(a){a||this.f.b.v||P(this,this.g)};k.fb=function(a){a?(this.s=!0,Za(this,!0)):(this.s=!1,Za(this),bb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.ya+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.ya){p=h.size-(e-l);p>f&&(p=f);h.ya=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return rb(sb,e,f)}e=new T(a,e,p,16384,d);ob(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+tb[d]+" at "+wa(b)),!0):rb(ub,b,c)}function mb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} -function pb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.P&&(a.P+=a.da,c=!0);0<=a.ea&&a.ea<=Jb(a)&&(a.da=a.ea=-1,Ib(a),R(a),c=!0);c&&a.I(Jb(a)+" cycles: checksum="+F(a.pa))}} -k.T=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.m)if(a=d.m,a.b.w)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.J/a.N&&(b=1);a.V=b;b=a.Ca*a.V;if(a.N!=b){a.N=b;b=a.N.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.I("target speed: "+b)}c&&a.m&&(c=a.m,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}jb(a,a.j);a.j=0;a.h=w();a.A=0;Lb(a)}function Nb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Ob(a,b){var c=a.B-=a.D;a.D=0;b&&(a.B=0);return c} -k.rb=function(){if(this.b.v){this.ra>=this.Ea&&Lb(this,!0);this.ca=0;this.la=w();if(this.A){var a=this.la-this.A;a>this.Da&&(this.h+=a,this.h>this.la&&(this.h=this.la))}try{do{for(var b,c=this.b.ua?1:this.fa,d=this.u.length-1;0<=d;d--){var e=this.u[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.za(b)}catch(f){if("number"!=typeof f)throw f;}b=Ob(this,!0);this.ca+=b;this.j+=b;kb(this,b);ib(this,b);this.W-=b;if(0>=this.W){this.W+=this.fa;++this.Fa>=Pb&&(this.m&&S(this.m,void 0),this.Fa=0);break}}while(this.b.v)}catch(f){R(this); -this.m&&this.m.stop(w(),Jb(this));a=f.stack||f.message;this.b.error=!0;this.C(a);return}if(this.b.v){a=setTimeout;b=this.Na;this.A=w();c=this.Da;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.A-this.la;if(d=this.A-this.h)this.J=Math.round(this.j/(10*d))/100,864E5<=d&&(this.G=0,Kb(this));if(0>c||this.Jc&&(this.h-=c),c=0;this.ra+=this.ca;this.A+=c;a(b,c)}}}; -function Q(a){var b;a.b.error?(a.I(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.v)a.I(a.toString()+" busy");else{Kb(a);a.b.v=!0;a.b.Ha=!0;if(b=a.i.run)b.textContent="Halt";a.m&&a.m.start(a.h,Jb(a));a.o||a.status("Started");setTimeout(a.Na,0)}}k.za=function(){return 0};function R(a){var b=!1;if(a.b.v){Ob(a);jb(a,a.j);a.j=0;a.b.v=!1;if(b=a.i.run)b.textContent="Run";a.m&&a.m.stop(w(),Jb(a));b=!0;a.o||a.status("Stopped")}a.b.complete=void 0;return b}var Mb=30,Pb=15,Gb=["power","reset"]; -function Qb(a){var b=+a.model||1001;Fb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Rb.bind(this);this.a=V.bind(this);this.ja=null;this.Ka=[];this.b.complete=!1}n(Qb,Fb);k=Qb.prototype;k.reset=function(){this.status("Model "+this.Va);this.b.v&&R(this);this.s=this.K=this.sa=0;this.ka=this.g=this.Ba=this.La;this.c=0;this.M=this.nb;this.Z=this.Ab;this.ja=null;Hb(this);this.b.error=!1;Fb.prototype.reset.call(this)};k.Pa=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[this.s,this.K,this.sa,this.g,this.Ba,this.ka,this.c]);a.set(1,[]);a.set(2,[this.G,this.V,this.b.H]);a.set(3,Sb(this));a.set(4,Nb(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.s=b.next().value;this.K=b.next().value;this.sa=b.next().value;this.g=b.next().value;this.Ba=b.next().value;this.ka=b.next().value;this.c=b.next().value;b=a[2];this.G=b[0];Kb(this,b[1]);this.b.H=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].M(a&16383,a)};k.Ab=function(a,b){var c=this.l;a=this.ka=a;c.a[(a&c.g)>>>c.c].Z(b,a&16383,a)}; -k.za=function(a){this.b.complete=!0;var b=a?this.b.Ha?0:1:-1;this.b.Ha=!1;this.B=this.D=a;this.c=this.c&-5|0;do{if(a=this.c)if(a=this.c&11)this.c&2?this.ja||(this.c&=-3):this.c&1&&this.c++,a=!1;if(a){if(this.c&4&&this.o.h(this.g,b)){R(this);break}if(0>b)break}this.c&=15;this.K=this.K&4194304?this.M(this.s):this.sa=this.M(this.Ba=this.g);this.s=this.K&262143;if(a=this.K>>18&15)this.s=this.s+this.M(a)&Ta;this.K&4194304?a=-1:(this.g=(this.g+1)%Sa,a=this.sa/Va|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Ub(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){a&=15;var b=this.M(this.s),c=this.M(a);this.Z(a,(c&262143)+(b-(b&262143)))}function X(a){this.a(a)}function V(a){this.I("undefined opcode: "+wa(a));this.g=(this.g+-1)%Sa;R(this)} -var Tb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +2==e&&d.match(/^[01]+$/):d.match(/^[0-9]+$/))&&!isNaN(f=parseInt(a,b))&&(c=f)}return bb(this,c)}return(c=this.a[a])?(c[1]=+b?1:0,db(this,a,c[1]),!0):!1};k.ub=function(a){return Ya(this,a)?(O(this,a),!0):!1};function Ya(a,b){var c=a.a[b];return c?(db(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=eb&&(a.L=b==fb,a.M=b==gb),!0):!1}function O(a,b){var c=a.a[b];c&&(c[2]&&c[3]&&(db(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} +k.ib=function(a){a||this.f.b.w||(this.f.h=this.c%Sa,this.a[hb]&&this.a[hb][1]&&ib(this.f))};k.jb=function(){};k.cb=function(a){a||R(this.f)};k.ab=function(a){if(!a&&!this.f.b.w)if(this.a[hb]&&this.a[hb][1])ib(this.f);else{a=this.s;var b;if(b=a)a.b.ta&&(a.b.Ga=!0),b=!a.b.ta;if(b)va(a,!0),a.c(0,null),va(a,!1);else try{var c=this.f.za(1);0>>a.c];a.h++;b=c.s(b&16383,b);a.h--;a=b}else a=this.f.m(this.c);N(this,this.h=a)}};k.gb=function(a){a||this.f.b.w||Q(this,this.g)};k.fb=function(a){a?(this.u=!0,Za(this,!0)):(this.u=!1,Za(this),bb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.ya+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.ya){p=h.size-(e-l);p>f&&(p=f);h.ya=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function qb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.R&&(a.R+=a.da,c=!0);0<=a.ea&&a.ea<=Kb(a)&&(a.da=a.ea=-1,Jb(a),R(a),c=!0);c&&a.K(Kb(a)+" cycles: checksum="+F(a.pa))}} +k.U=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.o)if(a=d.o,a.b.B)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.O&&(b=1);a.W=b;b=a.Ca*a.W;if(a.O!=b){a.O=b;b=a.O.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.K("target speed: "+b)}c&&a.o&&(c=a.o,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}kb(a,a.u);a.u=0;a.j=w();a.C=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.D-=a.G;a.G=0;b&&(a.D=0);return c} +k.rb=function(){if(this.b.w){this.ra>=this.Ea&&Mb(this,!0);this.ca=0;this.la=w();if(this.C){var a=this.la-this.C;a>this.Da&&(this.j+=a,this.j>this.la&&(this.j=this.la))}try{do{for(var b,c=this.b.ua?1:this.fa,d=this.v.length-1;0<=d;d--){var e=this.v[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.za(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.ca+=b;this.u+=b;lb(this,b);jb(this,b);this.X-=b;if(0>=this.X){this.X+=this.fa;++this.Fa>=Qb&&(this.o&&S(this.o,void 0),this.Fa=0);break}}while(this.b.w)}catch(f){R(this); +this.o&&this.o.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.F(a);return}if(this.b.w){a=setTimeout;b=this.Na;this.C=w();c=this.Da;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.C-this.la;if(d=this.C-this.j)this.L=Math.round(this.u/(10*d))/100,864E5<=d&&(this.I=0,Lb(this));if(0>c||this.Lc&&(this.j-=c),c=0;this.ra+=this.ca;this.C+=c;a(b,c)}}}; +function ib(a){var b;a.b.error?(a.K(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.w)a.K(a.toString()+" busy");else{Lb(a);a.b.w=!0;a.b.Ha=!0;if(b=a.i.run)b.textContent="Halt";a.o&&a.o.start(a.j,Kb(a));a.s||a.status("Started");setTimeout(a.Na,0)}}k.za=function(){return 0};function R(a){var b=!1;if(a.b.w){Pb(a);kb(a,a.u);a.u=0;a.b.w=!1;if(b=a.i.run)b.textContent="Run";a.o&&a.o.stop(w(),Kb(a));b=!0;a.s||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; +function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Sb.bind(this);this.a=V.bind(this);this.ja=null;this.Ka=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Va);this.b.w&&R(this);this.c=this.M=this.sa=0;this.ka=this.h=this.Ba=this.La;this.g=0;this.m=this.nb;this.A=this.Ab;this.ja=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Pa=function(){return 0}; +k.save=function(){var a=new P(this);a.set(0,[this.c,this.M,this.sa,this.h,this.Ba,this.ka,this.g]);a.set(1,[]);a.set(2,[this.I,this.W,this.b.J]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.c=b.next().value;this.M=b.next().value;this.sa=b.next().value;this.h=b.next().value;this.Ba=b.next().value;this.ka=b.next().value;this.g=b.next().value;b=a[2];this.I=b[0];Lb(this,b[1]);this.b.J=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].m(a&16383,a)};k.Ab=function(a,b){var c=this.l;a=this.ka=a;c.a[(a&c.g)>>>c.c].A(b,a&16383,a)}; +k.za=function(a){this.b.complete=!0;var b=a?this.b.Ha?0:1:-1;this.b.Ha=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ja||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.s.h(this.h,b)){R(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.m(this.c):this.sa=this.m(this.Ba=this.h);this.c=this.M&262143;if(a=this.M>>18&15)this.c=this.c+this.m(a)&Ta;this.M&4194304?a=-1:(this.h=(this.h+1)%Sa,a=this.sa/Va|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.m(this.c),c=this.m(a);this.A(a,(c&262143)+(b-(b&262143)))}function Yb(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a);this.A(a,c-(c&262143)+b)}function X(a){this.a(a)} +function V(a){this.K("undefined opcode: "+wa(a));this.h=(this.h+-1)%Sa;R(this)} +var Ub=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Ub,Vb,Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Ub,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,Wb,Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, @@ -106,56 +107,58 @@ function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a) function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Wb,function(a){a&=15;var b=this.M(a);this.Z(a,b&262143)},function(a){a=this.M(a&15);var b=this.M(this.s);this.Z(this.s,(b&262143)+(a-(a&262143)))},function(a){a&15&&Wb.call(this,a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.m(a);this.A(a,b&262143)},function(a){a=this.m(a&15);var b=this.m(this.c);this.A(this.c,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, +function(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a),c=(c&262143)+b*M;this.A(a,c)},function(a){a&=15;var b=this.m(a),b=(b&262143)+this.c*M;this.A(a,b)},function(a){a=this.m(a&15)&262143;var b=this.m(this.c),b=(b&262143)+a*M;this.A(this.c,b)},function(a){var b=this.m(this.c)&262143;this.A(this.c,b+b*M);if(a&=15)b=this.m(a)&262143,this.A(a,b+b*M)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Yb,function(a){a&=15;var b=this.m(a),b=b-(b&262143)+this.c;this.A(a,b)},function(a){a=this.m(a&15)&262143;var b= +this.m(this.c);this.A(this.c,b-(b&262143)+a)},function(a){a&15&&Yb.call(this,a)},function(a){a&=15;var b=this.m(this.c)/M|0,c=this.m(a);this.A(a,c-(c&262143)+b)},function(a){a&=15;var b=this.m(a);this.A(a,b-(b&262143))},function(a){a=this.m(a&15)/M|0;var b=this.m(this.c);this.A(this.c,b-(b&262143)+a)},function(a){var b=this.m(this.c);this.A(this.c,(b&262143)+(b/M|0));if(a&=15)b=this.m(a),this.A(a,(b&262143)+(b/M|0))},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; -function Xb(a){t.call(this,"ROM",a);this.L=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.s=xa(this.h);if(this.h){a=this.h;var b=ya(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.C("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(la(c.oa,a,b),(a=Ea(a,b))?(c.a=a.F,c.L=a.L):c.h=null);Yb(c)})}}n(Xb,t); -Xb.prototype.Y=function(a,b,c,d){this.l=b;this.f=c;this.o=d;Yb(this)};Xb.prototype.U=function(){this.L&&(this.o&&this.o.a(this.id,this.j,this.g,this.L),delete this.L);return!0};Xb.prototype.O=function(){return!0}; -function Yb(a){if(!ua(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.C(b)}else{b=a.j;if(qb(a.l,b,a.g,yb)){var c;for(c=0;c>>f.c;0>>=f.c;0>>a.c;0g&&g>=ka&&(g+=ja);g=Math.trunc(Math.abs(g))%ja;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.xa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.xa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.xa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Y=function(a,b,c,d){this.m=a;this.l=b;this.f=c;this.o=d;E(this)}; -k.Qa=function(a){if(!this.a){var b=U(this.m,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.na)return;c=Ca(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.oa+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.U=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.O=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.xa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bfc){if(Z(d,this.B)){this.j=new O(this,"1.34.0",oc);Z(this.j)&&(pc(this,d),a=qc,rc(this.j));this.j.set(lc,Da());sc(this.j);var e=this.a&&!this.A;if(a==mc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=kc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.C("Error: "+g),"unable to verify user"==g&&(Ia(tc,""),this.c=null)):this.I(f+": "+g),rc(d),Z(d)?(c=kc(d),e=!0):c=!1))}e&&ic(this,c?d:null)}else a==qc&&d.clear()}else ic(this);delete this.B;delete this.u}e=y(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.b.w=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(uc(this,this.f,b,c,a),S(this,-2),this.f.H());this.J&&(pc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; -function pc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.W;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function vc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.0"),g=new O(a,"1.34.0",jc),h=Da();g.set(lc,h);f.set(lc,h);f.set(wc,"1.34.0");f.set(xc,window?window.location.href:null);f.set(yc,window?window.navigator.userAgent:"");a.f&&a.f.O&&(c&&(b&&(a.f.b.H=a.f.b.v),R(a.f)),d=a.f.O(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.w=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l>>f.c;0>>=f.c;0>>a.c;0g&&g>=ka&&(g+=ja);g=Math.trunc(Math.abs(g))%ja;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.xa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.xa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.xa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.s=d;E(this)}; +k.Qa=function(a){if(!this.a){var b=U(this.o,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.na)return;c=Ca(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.oa+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.V=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.P=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.xa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bhc){if(Z(d,this.D)){this.j=new P(this,"1.34.0",qc);Z(this.j)&&(rc(this,d),a=sc,tc(this.j));this.j.set(nc,Da());uc(this.j);var e=this.a&&!this.C;if(a==oc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=mc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.F("Error: "+g),"unable to verify user"==g&&(Ia(vc,""),this.c=null)):this.K(f+": "+g),tc(d),Z(d)?(c=mc(d),e=!0):c=!1))}e&&kc(this,c?d:null)}else a==sc&&d.clear()}else kc(this);delete this.D;delete this.v}e=y(this.id);for(f=0;fa[1];a=a[2];this.O=!0;this.b.B=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(wc(this,this.f,b,c,a),S(this,-2),this.f.J());this.L&&(rc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function rc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function xc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new P(a,"1.34.0"),g=new P(a,"1.34.0",lc),h=Da();g.set(nc,h);f.set(nc,h);f.set(yc,"1.34.0");f.set(zc,window?window.location.href:null);f.set(Ac,window?window.navigator.userAgent:"");a.f&&a.f.P&&(c&&(b&&(a.f.b.J=a.f.b.w),R(a.f)),d=a.f.P(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.B=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.Aa+=d))&&(e.textContent=c.b.v?c.J.toFixed(2)+"Mhz":"Stopped",c.Aa=0)}if(a.g&&(a=a.g,b=b||0,a.B)){c=a.f.b.v;d=!!(a.f.c&8);if(0>=b||60<=(a.A+=b)){e=a.f.g;if(a.i.PC){var f=a.o&&a.o.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.A=0}-1>b?a.c=a.f.g:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Gc(a,b,c)}})}else c(a,null)} -function Hc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Dc||K(!0));p=!1}var h,l,p=!0;Dc++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ha=document.createElement("style");ha.type="text/css";ha.styleSheet?ha.styleSheet.cssText=r:ha.appendChild(document.createTextNode(r));v.appendChild(ha)}d|| -(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.0/components.xsl");r=function(e,l){l?Ec(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Dc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Dc|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Ec(c,b,a,e,!0,f,r):Fc(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(Ic){g(Ic.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Hc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Hc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +function S(a,b){if(a.f){var c=a.f,d=b||0,e=c.i.speed;e&&(0>=d||30<=(c.Aa+=d))&&(e.textContent=c.b.w?c.L.toFixed(2)+"Mhz":"Stopped",c.Aa=0)}if(a.g&&(a=a.g,b=b||0,a.D)){c=a.f.b.w;d=!!(a.f.g&8);if(0>=b||60<=(a.C+=b)){e=a.f.h;if(a.i.PC){var f=a.s&&a.s.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.C=0}-1>b?a.c=a.f.h:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Ic(a,b,c)}})}else c(a,null)} +function Jc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Fc||K(!0));p=!1}var h,l,p=!0;Fc++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ia=document.createElement("style");ia.type="text/css";ia.styleSheet?ia.styleSheet.cssText=r:ia.appendChild(document.createTextNode(r));v.appendChild(ia)}d|| +(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.0/components.xsl");r=function(e,l){l?Gc(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Fc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Fc|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Gc(c,b,a,e,!0,f,r):Hc(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(Kc){g(Kc.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Jc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Jc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!qa[a]){for(var c=!0,d=qa,e=a,f=b.length,g=[],h=[],l="",p=null,r=0;r Date: Mon, 27 Feb 2017 12:25:13 -0800 Subject: [PATCH 19/30] Tested a couple half-word instructions (so far, so good) --- apps/pdp10/tests/optest.json | 38 +++- modules/pdp10/lib/bus.js | 2 +- modules/pdp10/lib/cpuops.js | 204 ++++++------------ modules/pdp10/lib/defines.js | 1 + modules/pdp10/lib/memory.js | 118 ++-------- modules/shared/lib/int36.js | 171 +++++++++------ versions/pdpjs/1.34.0/pdp10-dbg.js | 333 ++++++++++++++--------------- versions/pdpjs/1.34.0/pdp10.js | 191 ++++++++--------- 8 files changed, 479 insertions(+), 579 deletions(-) diff --git a/apps/pdp10/tests/optest.json b/apps/pdp10/tests/optest.json index 506aef7c2..e4cdc9c42 100644 --- a/apps/pdp10/tests/optest.json +++ b/apps/pdp10/tests/optest.json @@ -2,6 +2,42 @@ "load": 0o100, "exec": 0o100, "data": [ - 0o505040111111, // HRLI 1,111111 + 0o505040111111, // HRLI 1,111111 + 0o541040222222, // HRRI 1,222222 + 0o544100000001, // HLR 2,1 + 0o504100000001, // HRL 2,1 + // + // >> dw 0 l4 + // 000000: 000000 000000 111111 222222 222222 111111 000000 000000 + // + // Compare to SIMH: + // + // sim> dep 100 505040111111 + // sim> dep 101 541040222222 + // sim> dep 102 544100000001 + // sim> dep 103 504100000001 + // sim> ex -m 100-103 + // 100: HRLI 1,111111 + // 101: HRRI 1,222222 + // 102: HLR 2,1 + // 103: HRL 2,1 + // sim> dep pc 100 + // sim> step + // + // Step expired, PC: 000101 (HRRI 1,222222) + // sim> step + // + // Step expired, PC: 000102 (HLR 2,1) + // sim> step + // + // Step expired, PC: 000103 (HRL 2,1) + // sim> step + // + // Step expired, PC: 000104 (000000000000) + // sim> ex 0-3 + // 0: 000000000000 + // 1: 111111222222 + // 2: 222222111111 + // 3: 000000000000 ] } diff --git a/modules/pdp10/lib/bus.js b/modules/pdp10/lib/bus.js index 0d869f12c..813dfc22d 100644 --- a/modules/pdp10/lib/bus.js +++ b/modules/pdp10/lib/bus.js @@ -540,7 +540,7 @@ class BusPDP10 extends Component { * * @this {BusPDP10} * @param {number} addr is a physical address - * @param {number} w is the word (36-bit) value to write (we truncate it to 16 bits to be safe) + * @param {number} w is the word (36-bit) value to write */ setWordDirect(addr, w) { diff --git a/modules/pdp10/lib/cpuops.js b/modules/pdp10/lib/cpuops.js index e53e7c491..0ee28dbe9 100644 --- a/modules/pdp10/lib/cpuops.js +++ b/modules/pdp10/lib/cpuops.js @@ -2651,7 +2651,7 @@ PDP10.opSETOB = function(op) }; /** - * opHLL(0o500000): Half Word Left to Left + * opHLL(0o5N0000): Half Word Left to Left * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * @@ -2668,12 +2668,12 @@ PDP10.opHLL = function(op) var a = op & PDP10.OPCODE.A_MASK; var src = this.readWord(this.regEA); var dst = this.readWord(a); - dst = (dst & PDP10.WORD_MASK) + (src - (src & PDP10.WORD_MASK)); + dst = PDP10.setHR(op, dst, src) + (src - (src & PDP10.WORD_MASK)); this.writeWord(a, dst); }; /** - * opHLLI(0o501000): Half Word Left to Left, Immediate + * opHLLI(0o5N1000): Half Word Left to Left, Immediate * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * @@ -2692,12 +2692,12 @@ PDP10.opHLLI = function(op) { var a = op & PDP10.OPCODE.A_MASK; var dst = this.readWord(a); - dst = (dst & PDP10.WORD_MASK); + dst = PDP10.setHR(op, dst, 0); this.writeWord(a, dst); }; /** - * opHLLM(0o502000): Half Word Left to Left, Memory + * opHLLM(0o5N2000): Half Word Left to Left, Memory * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * @@ -2714,12 +2714,12 @@ PDP10.opHLLM = function(op) var a = op & PDP10.OPCODE.A_MASK; var src = this.readWord(a); var dst = this.readWord(this.regEA); - dst = (dst & PDP10.WORD_MASK) + (src - (src & PDP10.WORD_MASK)); + dst = PDP10.setHR(op, dst, src) + (src - (src & PDP10.WORD_MASK)); this.writeWord(this.regEA, dst); }; /** - * opHLLS(0o503000): Half Word Left to Left, Self + * opHLLS(0o5N3000): Half Word Left to Left, Self * * From the DEC PDP-10 System Reference Manual (May 1968), p. 2-3: * @@ -2735,7 +2735,13 @@ PDP10.opHLLM = function(op) */ PDP10.opHLLS = function(op) { - if (op & PDP10.OPCODE.A_MASK) PDP10.opHLL.call(this, op); + var dst = this.readWord(this.regEA); + this.writeWord(this.regEA, PDP10.setHR(op, dst, dst)); + var a = op & PDP10.OPCODE.A_MASK; + if (a) { + dst = this.readWord(a); + this.writeWord(a, PDP10.setHR(op, dst, dst)); + } }; /** @@ -2831,50 +2837,6 @@ PDP10.opHRLS = function(op) } }; -/** - * opHLLZ(0o510000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLZ = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLZI(0o511000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLZI = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLZM(0o512000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLZM = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLZS(0o513000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLZS = function(op) -{ - this.opUndefined(op); -}; - /** * opHRLZ(0o514000) * @@ -2919,50 +2881,6 @@ PDP10.opHRLZS = function(op) this.opUndefined(op); }; -/** - * opHLLO(0o520000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLO = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLOI(0o521000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLOI = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLOM(0o522000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLOM = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLOS(0o523000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLOS = function(op) -{ - this.opUndefined(op); -}; - /** * opHRLO(0o524000) * @@ -3007,50 +2925,6 @@ PDP10.opHRLOS = function(op) this.opUndefined(op); }; -/** - * opHLLE(0o530000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLE = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLEI(0o531000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLEI = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLEM(0o532000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLEM = function(op) -{ - this.opUndefined(op); -}; - -/** - * opHLLES(0o533000) - * - * @this {CPUStatePDP10} - * @param {number} op - */ -PDP10.opHLLES = function(op) -{ - this.opUndefined(op); -}; - /** * opHRLE(0o534000) * @@ -4355,6 +4229,56 @@ PDP10.opUndefined = function(op) this.stopCPU(); }; +/** + * setHR(op, dst, src) + * + * @param {number} op + * @param {number} dst (36-bit value whose 18-bit right half is either preserved or modified) + * @param {number} src (36-bit value used to determine the sign extension, if any, for the right half of dst) + * @return {number} (updated dst) + */ +PDP10.setHR = function(op, dst, src) +{ + switch(op & 0o600) { + case 0o000: + dst = (dst & PDP10.WORD_MASK); + break; + case 0o200: + dst = 0; + break; + case 0o400: + dst = PDP10.WORD_MASK; + break; + case 0o600: + dst = (src > PDP10.MAX_POS? PDP10.WORD_MASK : 0); + break; + } + return dst; +}; + +/* + * If we want the basic half-word operations to handle all the sub-operations; ie: + * + * None + * Zero-extend + * One-extend + * Sign-extend + * + * then we need to alias all the sub-functions to the corresponding primary functions. + */ +PDP10.opHLLZ = PDP10.opHLL; +PDP10.opHLLZI = PDP10.opHLLI; +PDP10.opHLLZM = PDP10.opHLLM; +PDP10.opHLLZS = PDP10.opHLLS; +PDP10.opHLLO = PDP10.opHLL; +PDP10.opHLLOI = PDP10.opHLLI; +PDP10.opHLLOM = PDP10.opHLLM; +PDP10.opHLLOS = PDP10.opHLLS; +PDP10.opHLLE = PDP10.opHLL; +PDP10.opHLLEI = PDP10.opHLLI; +PDP10.opHLLEM = PDP10.opHLLM; +PDP10.opHLLES = PDP10.opHLLS; + PDP10.aOpXXX_KA10 = [ PDP10.opUUO, // 0o000xxx PDP10.opUUO, // 0o001xxx diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 924573c43..7dab8fc3f 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -102,6 +102,7 @@ var PDP10 = { DATA_LIMIT: Math.pow(2, 36), WORD_SHIFT: Math.pow(2, 18), WORD_MASK: 0o777777, + MAX_POS: Math.pow(2, 35) - 1, /* * PDP-10 opcodes are 36-bit values, most of which use the following layout: diff --git a/modules/pdp10/lib/memory.js b/modules/pdp10/lib/memory.js index 41afe49f7..d3de7b54a 100644 --- a/modules/pdp10/lib/memory.js +++ b/modules/pdp10/lib/memory.js @@ -83,9 +83,7 @@ class MemoryPDP10 { this.type = type || MemoryPDP10.TYPE.NONE; this.fReadOnly = (type == MemoryPDP10.TYPE.ROM); this.dbg = null; - this.readBits = this.readBitsDirect = this.readNone; this.readWord = this.readWordDirect = this.readNone; - this.writeBits = this.writeBitsDirect = this.writeNone; this.writeWord = this.writeWordDirect = this.writeNone; this.cReadBreakpoints = this.cWriteBreakpoints = 0; this.copyBreakpoints(); // initialize the block's Debugger info; the caller will reinitialize @@ -222,13 +220,11 @@ class MemoryPDP10 { /** * setAccess(afn, fDirect) * - * The afn parameter should be a 4-entry function table containing two bits handlers and - * two word handlers. See the static afnMemory table for an example. + * The afn parameter should be a 2-entry function table containing word read and write handlers. + * See the static afnMemory table for an example. * - * If no function table is specified, a default is selected based on the Memory type; - * similarly, any undefined entries in the table are filled with default handlers that fall - * back to the bits handlers, and if one or both bits handlers are undefined, they default - * to handlers that simply ignore the access. + * If no function table is specified, a default is selected based on the Memory type; similarly, + * any undefined entries in the table are filled with default handlers. * * fDirect indicates that both the default AND the direct handlers should be updated. Direct * handlers normally match the default handlers, except when "checked" handlers are installed; @@ -260,12 +256,10 @@ class MemoryPDP10 { setReadAccess(afn, fDirect) { if (!fDirect || !this.cReadBreakpoints) { - this.readBits = afn[0] || this.readNone; - this.readWord = afn[2] || this.readNone; + this.readWord = afn[0] || this.readNone; } if (fDirect || fDirect === undefined) { - this.readBitsDirect = afn[0] || this.readNone; - this.readWordDirect = afn[2] || this.readNone; + this.readWordDirect = afn[0] || this.readNone; } } @@ -279,12 +273,10 @@ class MemoryPDP10 { setWriteAccess(afn, fDirect) { if (!fDirect || !this.cWriteBreakpoints) { - this.writeBits = !this.fReadOnly && afn[1] || this.writeNone; - this.writeWord = !this.fReadOnly && afn[3] || this.writeNone; + this.writeWord = !this.fReadOnly && afn[1] || this.writeNone; } if (fDirect || fDirect === undefined) { - this.writeBitsDirect = afn[1] || this.writeNone; - this.writeWordDirect = afn[3] || this.writeNone; + this.writeWordDirect = afn[1] || this.writeNone; } } @@ -295,7 +287,6 @@ class MemoryPDP10 { */ resetReadAccess() { - this.readBits = this.readBitsDirect; this.readWord = this.readWordDirect; } @@ -306,7 +297,6 @@ class MemoryPDP10 { */ resetWriteAccess() { - this.writeBits = this.fReadOnly? this.writeNone : this.writeBitsDirect; this.writeWord = this.fReadOnly? this.writeNone : this.writeWordDirect; } @@ -424,27 +414,6 @@ class MemoryPDP10 { } } - /** - * readBitsMemory(off, addr, offBits, lenBits) - * - * @this {MemoryPDP10} - * @param {number} off - * @param {number} addr - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits - * @return {number} - */ - readBitsMemory(off, addr, offBits, lenBits) - { - var w = this.aw[off]; - if (offBits + lenBits <= 32) { - w = (w >> offBits) & ((1 << lenBits) - 1); - } else { - w = Math.trunc(w / Math.pow(2, offBits)) % Math.pow(2, lenBits); - } - return w; - } - /** * readWordMemory(off, addr) * @@ -458,29 +427,6 @@ class MemoryPDP10 { return this.aw[off]; } - /** - * writeBitsMemory(bits, off, addr, offBits, lenBits) - * - * @this {MemoryPDP10} - * @param {number} bits (only the right-most lenBits of bits are used, so it doesn't need to be pre-masked) - * @param {number} off - * @param {number} addr - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits - */ - writeBitsMemory(bits, off, addr, offBits, lenBits) - { - var w = this.aw[off]; - var shiftBits = Math.pow(2, offBits); - bits %= Math.pow(2, lenBits); - var v = (w % Math.pow(2, offBits + lenBits)); - w = (w - v) + (bits * shiftBits) + (v % shiftBits); - if (this.aw[off] != w) { - this.aw[off] = w; - this.fDirty = true; - } - } - /** * writeWordMemory(w, off, addr) * @@ -491,26 +437,10 @@ class MemoryPDP10 { */ writeWordMemory(w, off, addr) { - this.aw[off] = w; - this.fDirty = true; - } - - /** - * readBitsChecked(off, addr, offBits, lenBits) - * - * @this {MemoryPDP10} - * @param {number} off - * @param {number} addr - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits - * @return {number} - */ - readBitsChecked(off, addr, offBits, lenBits) - { - if (DEBUGGER && this.dbg && this.addr != null) { - this.dbg.checkMemoryRead(this.addr + off); + if (this.aw[off] != w) { + this.aw[off] = w; + this.fDirty = true; } - return this.readBitsDirect(off, addr, offBits, lenBits); } /** @@ -529,24 +459,6 @@ class MemoryPDP10 { return this.readWordDirect(off, addr); } - /** - * writeBitsChecked(bits, off, addr, offBits, lenBits) - * - * @this {MemoryPDP10} - * @param {number} bits - * @param {number} off - * @param {number} addr - * @param {number} offBits (the bit position of the right-most bit of the result, using modern bit numbering) - * @param {number} lenBits - */ - writeBitsChecked(bits, off, addr, offBits, lenBits) - { - if (DEBUGGER && this.dbg && this.addr != null) { - this.dbg.checkMemoryWrite(this.addr + off); - } - if (this.fReadOnly) this.writeNone(bits, off, addr); else this.writeBitsDirect(bits, off, addr, offBits, lenBits); - } - /** * writeWordChecked(w, off, addr) * @@ -587,11 +499,9 @@ MemoryPDP10.idBlock = 0; /* * This is the effective definition of afnNone, but we need not fully define it, because setAccess() - * uses these defaults when any of the 4 handlers (ie, 2 bits handlers and 2 word handlers) are undefined. + * uses these defaults when any of the handlers are undefined. * MemoryPDP10.afnNone = [ - MemoryPDP10.prototype.readNone, - MemoryPDP10.prototype.writeNone, MemoryPDP10.prototype.readNone, MemoryPDP10.prototype.writeNone ]; @@ -599,15 +509,11 @@ MemoryPDP10.afnNone = [ MemoryPDP10.afnNone = []; MemoryPDP10.afnMemory = [ - MemoryPDP10.prototype.readBitsMemory, - MemoryPDP10.prototype.writeBitsMemory, MemoryPDP10.prototype.readWordMemory, MemoryPDP10.prototype.writeWordMemory ]; MemoryPDP10.afnChecked = [ - MemoryPDP10.prototype.readBitsChecked, - MemoryPDP10.prototype.writeBitsChecked, MemoryPDP10.prototype.readWordChecked, MemoryPDP10.prototype.writeWordChecked ]; diff --git a/modules/shared/lib/int36.js b/modules/shared/lib/int36.js index 06d5a786e..440aaf1c1 100644 --- a/modules/shared/lib/int36.js +++ b/modules/shared/lib/int36.js @@ -155,7 +155,7 @@ class Int36 { * The lower bound is ZERO and the upper bound is Int36.MAXVAL. Whenever an Int36 value should be * interpreted as a signed value, values above Int36.MAXPOS (ie, values with bit 35 set) should be * converted to their signed counterpart by subtracting the value from Int36.BIT36 (aka MAXVAL + 1); - * the easiest way to do that is call isNegative() to check the sign bit and then call negate() as + * the easiest way to do that is call isNeg() to check the sign bit and then call negate() as * appropriate. * * NOTE: We use modern bit numbering, where bit 0 is the right-most (least-significant) bit and @@ -233,7 +233,7 @@ class Int36 { var i36Rem = new Int36(); var i36Tmp = new Int36(this.value, this.extended); - if (!fUnsigned && i36Tmp.isNegative()) { + if (!fUnsigned && i36Tmp.isNeg()) { i36Tmp.negate(); fNeg = true; } @@ -585,7 +585,7 @@ class Int36 { fNegQ = !fNegQ; } - if (this.isNegative()) { + if (this.isNeg()) { this.negate(); fNegR = true; fNegQ = !fNegQ; } @@ -593,52 +593,52 @@ class Int36 { this.extend(); /* - * Initialize the four double-length 72-bit "bits" values we need for the division process. + * Initialize the four double-length 72-bit values we need for the division process. * * The process involves shifting the divisor left 1 bit (ie, doubling it) until it equals * or exceeds the dividend, and then repeatedly subtracting the divisor from the dividend and * shifting the divisor right 1 bit until the divisor is "exhausted" (no bits left), with an * "early out" if the dividend gets "exhausted" first. * - * Note that each element of these "bits" arrays is a 36-bit value, so it's rarely a good idea + * Note that each element of these double arrays is a 36-bit value, so it's rarely a good idea * to use bit-wise operators on them, because those would operate on only the low 32 bits. - * Stick with the "bits" worker functions I've created, and trust your JavaScript engine to + * Stick with the double worker functions I've created, and trust your JavaScript engine to * inline/optimize the code. * - * TODO: Profile this code to determine if individual variables (eg, bitsResLo and bitsResHi) + * TODO: Profile this code to determine if individual variables (eg, dResLo and dResHi) * instead of 2-element arrays is faster and/or less impactful on garbage collection. I prefer * both the simplified syntax of arrays as well as their extensibility if we ever want/need * to go beyond 72 bits. */ - var bitsRes = [0, 0]; - var bitsPow = [1, 0]; - var bitsDiv = [divisor, 0]; - var bitsRem = [this.value, this.extended]; + var dRes = [0, 0]; + var dPow = [1, 0]; + var dDiv = [divisor, 0]; + var dRem = [this.value, this.extended]; - while (Int36.cmpBits(bitsRem, bitsDiv) > 0) { - Int36.addBits(bitsDiv, bitsDiv); - Int36.addBits(bitsPow, bitsPow); + while (Int36.cmpD(dRem, dDiv) > 0) { + Int36.addD(dDiv, dDiv); + Int36.addD(dPow, dPow); } do { - if (Int36.cmpBits(bitsRem, bitsDiv) >= 0) { - Int36.subBits(bitsRem, bitsDiv); - Int36.addBits(bitsRes, bitsPow); - if (Int36.zeroBits(bitsRem)) break; + if (Int36.cmpD(dRem, dDiv) >= 0) { + Int36.subD(dRem, dDiv); + Int36.addD(dRes, dPow); + if (Int36.zeroD(dRem)) break; } - Int36.shrBits(bitsDiv); - Int36.shrBits(bitsPow); - } while (!Int36.zeroBits(bitsPow)); + Int36.shrD(dDiv); + Int36.shrD(dPow); + } while (!Int36.zeroD(dPow)); /* * Since divisors are limited to 36-bit values, something's wrong if we have an extended remainder. */ - if (DEBUG && bitsRem[1]) { + if (DEBUG && dRem[1]) { console.log("divExtended() assertion failure"); } - this.value = bitsRes[0]; - this.extended = bitsRes[1]; - this.remainder = bitsRem[0]; + this.value = dRes[0]; + this.extended = dRes[1]; + this.remainder = dRem[0]; if (fNegQ) this.negate(); @@ -689,11 +689,11 @@ class Int36 { } /** - * isNegative() + * isNeg() * * @return {boolean} */ - isNegative() + isNeg() { return (this.extended > Int36.MAXPOS || this.extended == null && this.value > Int36.MAXPOS); } @@ -738,83 +738,118 @@ class Int36 { } /** - * addBits(bitsDst, bitsSrc) + * readBits(off, len) * - * Adds bitsSrc to bitsDst. - * - * @param {Array.} bitsDst - * @param {Array.} bitsSrc + * @param {number} off (the bit position of the right-most bit of the result, using modern bit numbering) + * @param {number} len + * @return {number} */ - static addBits(bitsDst, bitsSrc) + readBits(off, len) { - bitsDst[0] += bitsSrc[0]; - bitsDst[1] += bitsSrc[1]; - if (bitsDst[0] >= Int36.BIT36) { - bitsDst[0] %= Int36.BIT36; - bitsDst[1]++; + var w = this.value; + if (off + len <= 32) { + w = (w >> off) & ((1 << len) - 1); + } else { + w = Math.trunc(w / Math.pow(2, off)) % Math.pow(2, len); + } + return w; + } + + /** + * writeBits(bits, off, len) + * + * @param {number} bits (only the right-most len of bits are used, so it doesn't need to be pre-masked) + * @param {number} off (the bit position of the right-most bit of the result, using modern bit numbering) + * @param {number} len + */ + writeBits(bits, off, len) + { + var w = this.value; + var shift = Math.pow(2, off); + bits %= Math.pow(2, len); + var v = (w % Math.pow(2, off + len)); + w = (w - v) + (bits * shift) + (v % shift); + this.value = w; + } + + /** + * addD(dDst, dSrc) + * + * Adds dSrc to dDst. + * + * @param {Array.} dDst + * @param {Array.} dSrc + */ + static addD(dDst, dSrc) + { + dDst[0] += dSrc[0]; + dDst[1] += dSrc[1]; + if (dDst[0] >= Int36.BIT36) { + dDst[0] %= Int36.BIT36; + dDst[1]++; } } /** - * cmpBits(bitsDst, bitsSrc) + * cmpD(dDst, dSrc) * - * Compares bitsDst to bitsSrc, by computing bitsDst - bitsSrc. + * Compares dDst to dSrc, by computing dDst - dSrc. * - * @param {Array.} bitsDst - * @param {Array.} bitsSrc - * @return {number} > 0 if bitsDst > bitsSrc, == 0 if bitsDst == bitsSrc, < 0 if bitsDst < bitsSrc + * @param {Array.} dDst + * @param {Array.} dSrc + * @return {number} > 0 if dDst > dSrc, == 0 if dDst == dSrc, < 0 if dDst < dSrc */ - static cmpBits(bitsDst, bitsSrc) + static cmpD(dDst, dSrc) { - var result = bitsDst[1] - bitsSrc[1]; - if (!result) result = bitsDst[0] - bitsSrc[0]; + var result = dDst[1] - dSrc[1]; + if (!result) result = dDst[0] - dSrc[0]; return result; } /** - * shrBits(bitsDst) + * shrD(dDst) * - * Shifts bitsDst right one bit. + * Shifts dDst right one bit. * - * @param {Array.} bitsDst + * @param {Array.} dDst */ - static shrBits(bitsDst) + static shrD(dDst) { - if (bitsDst[1] % 2) { - bitsDst[0] += Int36.BIT36; + if (dDst[1] % 2) { + dDst[0] += Int36.BIT36; } - bitsDst[0] = Math.trunc(bitsDst[0] / 2); - bitsDst[1] = Math.trunc(bitsDst[1] / 2); + dDst[0] = Math.trunc(dDst[0] / 2); + dDst[1] = Math.trunc(dDst[1] / 2); } /** - * subBits(bitsDst, bitsSrc) + * subD(dDst, dSrc) * - * Subtracts bitsSrc from bitsDst. + * Subtracts dSrc from dDst. * - * @param {Array.} bitsDst - * @param {Array.} bitsSrc + * @param {Array.} dDst + * @param {Array.} dSrc */ - static subBits(bitsDst, bitsSrc) + static subD(dDst, dSrc) { - bitsDst[0] -= bitsSrc[0]; - bitsDst[1] -= bitsSrc[1]; - if (bitsDst[0] < 0) { - bitsDst[0] += Int36.BIT36; - bitsDst[1]--; + dDst[0] -= dSrc[0]; + dDst[1] -= dSrc[1]; + if (dDst[0] < 0) { + dDst[0] += Int36.BIT36; + dDst[1]--; } } /** - * zeroBits(bits) + * zeroD(d) * * True if bits are all zero, false otherwise. * - * @param {Array.} bits + * @param {Array.} d */ - static zeroBits(bits) + static zeroD(d) { - return !bits[0] && !bits[1]; + return !d[0] && !d[1]; } /** diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index d6e7910e9..6251aeeba 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -28,22 +28,22 @@ http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ -var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var ga=0;function da(a){return"jscomp_symbol_"+(a||"")+ga++} +var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=fa)}var ga=0;function fa(a){return"jscomp_symbol_"+(a||"")+ga++} function ha(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return ja(function(){return ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var la=Math.pow(2,36),sa=-Math.pow(2,35),q={ac:0,ob:1,cc:2,dc:3,ec:4,fc:5,gc:6,hc:7,Za:8,ic:9,pb:10,jc:11,kc:12,qb:13,lc:14,mc:15,nc:16,oc:17,pc:18,qc:19,rc:20,sc:21,tc:22,uc:23,vc:24,wc:25,xc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,$b:66,bc:67,yc:68,E:69,zc:70,Ac:71,Bc:72,Cc:73,Dc:74,Ec:75,Fc:76,Gc:77,Hc:78,Ic:79,Jc:80,Q:81, -Kc:82,Lc:83,Mc:84,Nc:85,Oc:86,Pc:87,Qc:88,Rc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Sc:97,Tc:98,Uc:99,d:100,e:101,Vc:102,Wc:103,Xc:104,Yc:105,Zc:106,k:107,$c:108,ad:109,n:110,bd:111,p:112,q:113,r:114,cd:115,t:116,ed:117,fd:118,gd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.j={ready:!1,Fa:!1,Va:!1,W:!1,error:!1};this.Na=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.la=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} +var la=Math.pow(2,36),sa=-Math.pow(2,35),q={Xb:0,ob:1,Zb:2,$b:3,ac:4,bc:5,cc:6,dc:7,Za:8,ec:9,pb:10,fc:11,gc:12,qb:13,hc:14,ic:15,jc:16,kc:17,lc:18,mc:19,nc:20,oc:21,pc:22,qc:23,rc:24,sc:25,tc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,Wb:66,Yb:67,uc:68,E:69,vc:70,wc:71,xc:72,yc:73,zc:74,Ac:75,Bc:76,Cc:77,Dc:78,Ec:79,Fc:80,Q:81, +Gc:82,Hc:83,Ic:84,Jc:85,Kc:86,Lc:87,Mc:88,Nc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Oc:97,Pc:98,Qc:99,d:100,e:101,Rc:102,Sc:103,Tc:104,Uc:105,Vc:106,k:107,Wc:108,Xc:109,n:110,Yc:111,p:112,q:113,r:114,Zc:115,t:116,ad:117,bd:118,cd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ta:!1,V:!1,error:!1};this.La=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.la=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} function v(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function w(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function Za(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function ib(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +function H(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function jb(a,b){var c,d={Y:null,V:null,ka:null,ja:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ka=f.load;d.ja=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;c>8&255,d.Y[g++]=e[c]>>16&255,d.Y[g++]=e[c]>>24&255;else(e=f.data)?d.Aa=e:d.Y=f;d.Y&&(d.Y.length?1==d.Y.length&&(v(d.Y[0]),d=null):(v("Empty resource: "+a),d=null));d.V=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Tb,reset:this.Pb, -set:this.Sb};E(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.v=0)}; +function ib(a,b){var c,d={Y:null,U:null,ka:null,ja:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ka=f.load;d.ja=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;c>8&255,d.Y[g++]=e[c]>>16&255,d.Y[g++]=e[c]>>24&255;else(e=f.data)?d.za=e:d.Y=f;d.Y&&(d.Y.length?1==d.Y.length&&(v(d.Y[0]),d=null):(v("Empty resource: "+a),d=null));d.U=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Rb,reset:this.Nb, +set:this.Qb};E(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.v=0)}; l.fa=function(a,b,c,d){if(this.C&&this.C.fa(a,b,c,d)||this.g&&this.g.fa(a,b,c,d)||this.A&&this.A.fa(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Rb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Sb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.fa.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.na=function(a,b){if(!b)if(this.U&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ea=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.v=a[1]),Xb(this,a[2]);return!0};l.Pb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} -l.yb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Sb=function(a,b){if("SR"==a)return Xb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Tb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.O=b==ac,a.P=b==bc),!0):!1} -function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Ib,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.S()}; -l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ec(a,0,null),Ma(a,!1);else try{var b=this.g.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ia+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ia){m=h.size-(e-k);m>g&&(m=g);h.Ia=e-h.w+m;e=k+16384;g-=m;f++;continue}}return pc(qc,e,g)}e=new M(a,e,m,16384,d);mc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Hc[d]+" at "+Qa(b)),!0):pc(Ic,b,c)} -function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.i(b&16383,b);a.v--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function nc(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.ga&&(a.ga+=a.ca,c=!0);0<=a.ha&&a.ha<=cd(a)&&(a.ca=a.ha=-1,Zc(a),a.S(),c=!0);c&&a.f(cd(a)+" cycles: checksum="+F(a.sa))}} -l.fa=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.W)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.P/a.R?b=1:d=!0;a.U=b;b=a.Ra*a.U;if(a.R!=b){a.R=b;b=a.R.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&gd(a.C)}gc(a,a.F);a.F=0;a.B=va();a.J=0;ed(a);return d}function hd(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function id(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function jd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} -l.Qb=function(){if(this.j.K){this.ya>=this.Ta&&ed(this,!0);this.ia=0;this.ra=va();if(this.J){var a=this.ra-this.J;a>this.Sa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=hd(this,this.j.Ea?1:this.ua);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=jd(this,!0);this.ia+=b;this.F+=b;hc(this,b);fc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Ua>=kd&&(this.C&&K(this.C,void 0),this.Ua=0);break}}while(this.j.K)}catch(e){this.S();this.C&&this.C.stop(va(),cd(this));Da(this, -e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=va();var c=this.Sa;this.ia&&(c=Math.round(c*this.ia/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.P=Math.round(this.F/(10*d))/100,864E5<=d&&(this.N=0,dd(this)));if(0>c||this.Pc&&(this.B-=c),c=0;this.ya+=this.ia;this.J+=c;a(b,c)}}}; -function dc(a,b){if(!Ja(a))if(a.j.K)a.f(a.toString()+" busy");else{dd(a);a.j.K=!0;a.j.Qa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&gd(a.C,!0),a.C.start(a.B,cd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ja=function(){return 0};l.S=function(a){var b=!1;if(this.j.K){jd(this);gc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),cd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var fd=30,kd=15,Wc=["power","reset"]; -function ld(a){var b=+a.model||1001;Vc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=md.bind(this);this.b=O.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(ld,Vc);l=ld.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.S();this.i=this.O=this.za=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Mb;this.T=this.Zb;this.oa=null;Yc(this);this.j.error=!1;Vc.prototype.reset.call(this)};l.lb=function(){return 0}; -l.save=function(){var a=new J(this);a.set(0,[this.i,this.O,this.za,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.N,this.U,this.j.Z]);a.set(3,nd(this));a.set(4,id(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.i=b.next().value;this.O=b.next().value;this.za=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.N=b[0];dd(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Zb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].T(b,a&16383,a)}; -l.Ja=function(a){this.j.complete=!0;var b=this.A?pd(this.A)?1:this.j.Qa?-1:0:0,c=a?this.j.Qa?0:1:-1;this.j.Qa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(qd(this.A,this.u,c)){this.S();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&qd(this.A,this.u,c)){this.S();break}if(0>c)break}}this.v&=15;this.O=this.O&4194304?this.H(this.i):this.za=this.H(this.qa=this.u);this.i=this.O&262143;if(a=this.O>>18&15)this.i= -this.i+this.H(a)&Jb;this.O&4194304?a=-1:(this.u=(this.u+1)%Ib,a=this.za/Nb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function sd(a){this.b(a)}function td(a){this.b(a)}function ud(a){a&=15;var b=this.H(this.i),c=this.H(a);this.T(a,(c&262143)+(b-(b&262143)))} -function vd(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a);this.T(a,c-(c&262143)+b)}function R(a){this.b(a)}function O(a){this.f("undefined opcode: "+Qa(a));od(this,-1);this.S()} -var rd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.fa.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.na=function(a,b){if(!b)if(this.T&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ea=function(a){return a?this.save():!0};l.save=function(){var a=new L(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.v=a[1]),Xb(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} +l.yb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return Xb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Rb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.O=b==ac,a.R=b==bc),!0):!1} +function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Cb,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.W()}; +l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ec(a,0,null),Ma(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ga+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ga){m=h.size-(e-k);m>g&&(m=g);h.Ga=e-h.w+m;e=k+16384;g-=m;f++;continue}}return qc(rc,e,g)}e=new mc(a,e,m,16384,d);nc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+sc[d]+" at "+Qa(b)),!0):qc(tc,b,c)} +function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.G(b&16383,b);a.v--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function oc(a){for(var b=0,c=[],d=0;d=a.ga&&(a.ga+=a.ca,c=!0);0<=a.ha&&a.ha<=dd(a)&&(a.ca=a.ha=-1,$c(a),a.W(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.sa))}} +l.fa=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.V)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.R/a.S?b=1:d=!0;a.T=b;b=a.Pa*a.T;if(a.S!=b){a.S=b;b=a.S.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&hd(a.C)}gc(a,a.F);a.F=0;a.B=va();a.J=0;fd(a);return d}function id(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} +l.Ob=function(){if(this.j.K){this.xa>=this.Ra&&fd(this,!0);this.ia=0;this.ra=va();if(this.J){var a=this.ra-this.J;a>this.Qa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=id(this,this.j.Da?1:this.ua);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.ia+=b;this.F+=b;hc(this,b);fc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Sa>=ld&&(this.C&&M(this.C,void 0),this.Sa=0);break}}while(this.j.K)}catch(e){this.W();this.C&&this.C.stop(va(),dd(this));Ia(this, +e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=va();var c=this.Qa;this.ia&&(c=Math.round(c*this.ia/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.R=Math.round(this.F/(10*d))/100,864E5<=d&&(this.N=0,ed(this)));if(0>c||this.Rc&&(this.B-=c),c=0;this.xa+=this.ia;this.J+=c;a(b,c)}}}; +function dc(a,b){if(!Ja(a))if(a.j.K)a.f(a.toString()+" busy");else{ed(a);a.j.K=!0;a.j.Oa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&hd(a.C,!0),a.C.start(a.B,dd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ia=function(){return 0};l.W=function(a){var b=!1;if(this.j.K){kd(this);gc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; +function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=nd.bind(this);this.b=P.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.W();this.i=this.O=this.ya=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Kb;this.P=this.Vb;this.oa=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.lb=function(){return 0}; +l.save=function(){var a=new L(this);a.set(0,[this.i,this.O,this.ya,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.N,this.T,this.j.Z]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.i=b.next().value;this.O=b.next().value;this.ya=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.N=b[0];ed(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Vb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].P(b,a&16383,a)}; +l.Ia=function(a){this.j.complete=!0;var b=this.A?qd(this.A)?1:this.j.Oa?-1:0:0,c=a?this.j.Oa?0:1:-1;this.j.Oa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(rd(this.A,this.u,c)){this.W();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&rd(this.A,this.u,c)){this.W();break}if(0>c)break}}this.v&=15;this.O=this.O&4194304?this.H(this.i):this.ya=this.H(this.qa=this.u);this.i=this.O&262143;if(a=this.O>>18&15)this.i= +this.i+this.H(a)&Db;this.O&4194304?a=-1:(this.u=(this.u+1)%Cb,a=this.ya/Nb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function td(a){this.b(a)}function ud(a){this.b(a)}function vd(a){var b=a&15,c=this.H(this.i),d=this.H(b),d=wd(a,d,c)+(c-(c&262143));this.P(b,d)} +function xd(a){var b=a&15,c=this.H(b),c=wd(a,c,0);this.P(b,c)}function yd(a){var b=this.H(a&15),c=this.H(this.i),c=wd(a,c,b)+(b-(b&262143));this.P(this.i,c)}function zd(a){var b=this.H(this.i);this.P(this.i,wd(a,b,b));var c=a&15;c&&(b=this.H(c),this.P(c,wd(a,b,b)))}function Ad(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a);this.P(a,c-(c&262143)+b)}function W(a){this.b(a)}function P(a){this.f("undefined opcode: "+Qa(a));pd(this,-1);this.W()} +function wd(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Fb?262143:0}return b} +var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,td,td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},sd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},O,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,ud,ud,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},ud,function(a){a&=15;var b=this.H(a);this.T(a,b&262143)},function(a){a=this.H(a&15);var b=this.H(this.i);this.T(this.i,(b&262143)+(a-(a&262143)))},function(a){a&15&&ud.call(this,a)}, -function(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a),c=(c&262143)+b*H;this.T(a,c)},function(a){a&=15;var b=this.H(a),b=(b&262143)+this.i*H;this.T(a,b)},function(a){a=this.H(a&15)&262143;var b=this.H(this.i),b=(b&262143)+a*H;this.T(this.i,b)},function(a){var b=this.H(this.i)&262143;this.T(this.i,b+b*H);if(a&=15)b=this.H(a)&262143,this.T(a,b+b*H)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,function(a){a&=15;var b=this.H(a),b=b-(b&262143)+this.i;this.T(a,b)},function(a){a=this.H(a&15)&262143;var b= -this.H(this.i);this.T(this.i,b-(b&262143)+a)},function(a){a&15&&vd.call(this,a)},function(a){a&=15;var b=this.H(this.i)/H|0,c=this.H(a);this.T(a,c-(c&262143)+b)},function(a){a&=15;var b=this.H(a);this.T(a,b-(b&262143))},function(a){a=this.H(a&15)/H|0;var b=this.H(this.i);this.T(this.i,b-(b&262143)+a)},function(a){var b=this.H(this.i);this.T(this.i,(b&262143)+(b/H|0));if(a&=15)b=this.H(a),this.T(a,(b&262143)+(b/H|0))},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a),c=(c&262143)+b*I;this.P(a,c)},function(a){a&=15;var b=this.H(a),b=(b&262143)+this.i*I;this.P(a,b)},function(a){a= +this.H(a&15)&262143;var b=this.H(this.i),b=(b&262143)+a*I;this.P(this.i,b)},function(a){var b=this.H(this.i)&262143;this.P(this.i,b+b*I);if(a&=15)b=this.H(a)&262143,this.P(a,b+b*I)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Ad,function(a){a&= +15;var b=this.H(a),b=b-(b&262143)+this.i;this.P(a,b)},function(a){a=this.H(a&15)&262143;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){a&15&&Ad.call(this,a)},function(a){a&=15;var b=this.H(this.i)/I|0,c=this.H(a);this.P(a,c-(c&262143)+b)},function(a){a&=15;var b=this.H(a);this.P(a,b-(b&262143))},function(a){a=this.H(a&15)/I|0;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){var b=this.H(this.i);this.P(this.i,(b&262143)+(b/I|0));if(a&=15)b=this.H(a),this.P(a,(b&262143)+ +(b/I|0))},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R, -R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R,R]; -function wd(a){t.call(this,"ROM",a,128);this.V=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Ra(this.v);if(this.v){a=this.v;var b=Sa(this.F);"json"!=b&&"hex"!=b&&(a=Ua()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;ib(a,null,!0,function(a,b,g){g?(c.ba("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(ta(c.La,a,b),(a=jb(a,b))?(c.b=a.Y,c.V=a.V):c.v=null);xd(c)})}}p(wd,t); -wd.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;xd(this)};wd.prototype.na=function(){this.V&&(this.A&&yd(this.A,this.id,this.B,this.u,this.V),delete this.V);return!0};wd.prototype.ea=function(){return!0}; -function xd(a){if(!Ka(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Da(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(oc(a.D,b,a.u,Mc)){var c;for(c=0;c>>g.i;0>>= -g.i;0>>a.i;0f&&f>=sa&&(f+=la);f=Math.trunc(Math.abs(f))%la;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Oa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Oa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; -l.nb=function(a){if(!this.b){var b=Xc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ka)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ea=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Oa=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.P?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} -function Gd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W]; +function Bd(a){t.call(this,"ROM",a,128);this.U=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Ra(this.v);if(this.v){a=this.v;var b=Sa(this.F);"json"!=b&&"hex"!=b&&(a=Ua()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,g){g?(c.ba("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(ta(c.Ka,a,b),(a=ib(a,b))?(c.b=a.Y,c.U=a.U):c.v=null);Cd(c)})}}p(Bd,t); +Bd.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;Cd(this)};Bd.prototype.na=function(){this.U&&(this.A&&Dd(this.A,this.id,this.B,this.u,this.U),delete this.U);return!0};Bd.prototype.ea=function(){return!0}; +function Cd(a){if(!Ka(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ia(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.D,b,a.u,Nc)){var c;for(c=0;c>>g.i;0>>= +g.i;0>>a.i;0f&&f>=sa&&(f+=la);f=Math.trunc(Math.abs(f))%la;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Ma(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Ma(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Ma(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; +l.nb=function(a){if(!this.b){var b=Yc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.ea=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new L(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Ma=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.R?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} +function Ld(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Hd(a,b,c){var d;if(b){b=Id(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,S--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Md(a,b){if(b)return Ld(a,b,a.aa[b]);var c=0;for(b in a.aa)Ld(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Kd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Nd(a){Ed.call(this,a);this.xa=!1;this.oa=!0;this.J=X();this.ua=X();this.O=X();this.I=[];this.b=this.L=this.F=[];Od(this);this.R=this.ia=0;this.i=[];this.ra=void 0;Pd(this);this.A=this;this.pa={};this.X=this.ib=0;this.U=null;this.N=[];Qd(this,a.messages);this.ta=a.commands;this.M=0;this.Da=this.sa=null;this.B=this.za=this.ya=this.ha=this.qa=0;this.ga=this.ca=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return bd(b,a)}):void 0===global[C]&&(global[C]=function(a){return bd(b, -a)})}p(Nd,Ed);function Y(a){a=a&&a.w;null==a&&(a=-1);return a}function X(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ma:!1,da:c}}function Rd(a){return[a.w,a.wb,a.da,a.ma,a.Pa]}function Sd(a,b){var c=X(b[0],b[1],b[2]);c.ma=b[3];b[4]&&(c.gb=Fd(a,c.Pa=b[4]));return c}l=Nd.prototype; -l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ga=a.u;(a=Xc(a,"messages"))&&Qd(this,a);Td(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Hc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=od(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(c=a.i[a.R],c.w=b,c.ma=!1,c.da=void 0,++a.R==a.i.length&&(a.R=0)));return!1} -function Ie(a,b,c,d){var e=X(b.w),g=a.Ca(b,1),f,h,k,m=0,n=g/Lb|0,r;for(r in Je)if(f=Je[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Ke;m=n&3;break;case 32256:k=Le;m=n&7;break;case 29248:k=Me,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Ne&&(k="B");k=Oe[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Mb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=Vd(g);g=k;f="";h=N(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.Ca(e,1),f+=" "+Vd(k),null== -e.w)break;while(e.w!=b.w)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Ea?h+("cycles="+cd(a.g).toString()+" cs="+F(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function Od(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.F)for(b=1;b>>d.i],!0);a.F=["bw"];a.qa=0;a.ia=0} -l.Ba=function(a,b,c){var d=!0;c||Pe(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Ba(e&16383,a==this.F)}}d&&(a.push(b),c?b.ma=!0:(Qe(this,a,a.length-1,"set"),Pd(this)));return d};function Pe(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.F));h.ma||Pd(a);break}}return g} -function Re(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=Za(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.I.push({dd:b,w:c,zb:d,V:e,hb:g})} -function Ue(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ie(a,b,f,g);a.f(g);a.J=b;e-=b.w-k;c++}}} -function Se(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Ee+b):(a.P&&(a.f("ended assemble at "+N(a,a.O.w)),a.J=a.O,a.P=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.U=null;if(Ka(a)&&0n||"z"U.length&&(a.f("note: only "+U.length+" available"),L=U.length);P-=L;0>P&&(null==U[U.length-1].w?(L=P+L,P=0):P+=U.length);var vc=[];"call"==ge&&($a=1E5,vc=["CALL"]);for(void 0!==fe&&a.f(L+" instructions earlier:");0<$a&&P!=a.R;){var je=U[P++];if(null==je.w)break;var ab=X(je.w),Ef=L--,ke=Ie(a,ab,"history",Ef);(!vc.length||0<=ke.indexOf(vc[0]))&&a.f(ke);ab.Wa&&(P+=ab.Wa,$a-=ab.Wa,L-=ab.Wa);P>=U.length&&(P=0);a.ra=L;ie++;$a--}}ie||(a.f("no "+he+"history available"), -a.ra=void 0)}else{var na=Z(a,T);if(na){var oa=0,le="ds"==Ga;if(ea){if("l"==ea.charAt(0))ea=ea.substr(1)||Df,oa=Jd(a,ea);else{var me=Z(a,ea);me&&(oa=me.w-na.w)}0>oa&&(oa=0);65536qe;qe++)oe+=String.fromCharCode((Db%64|0)+32), -Db/=64}pa&&(pa+="\n");pa=le?pa+(qa+","):pa+(T+": "+qa+(0>pe?" "+oe:""))}pa&&a.f(pa);a.ua=na;a.da=Ff}}}}break;case "e":if("else"==f[0])break;var re,se,te=f[0],yc=f[1];"e"==te||"ew"==te?(re=a.Ca,se=a.$a):yc=null;if(null==yc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Eb=Z(a,yc);if(Eb)for(var Fb=2;FbCc;){for(var ra=null,Jf=256;65536>cb.w>>>0;){Dc.w=a.Ca(cb,2);if(null==cb.w||!Jf--)break;if(!(Dc.w&1)){for(var Kf=a,Gb=Dc,ve=null,db=Gb.w,we=db,Ec=1;6>=Ec&&db;Ec++){if(2> ";ub(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bff){if(gf(d,this.L)){this.B=new J(this,"1.34.0",qf);gf(this.B)&&(rf(this,d),a=sf,tf(this.B));this.B.set(nf,hb());uf(this.B);var e=this.b&&!this.J;if(a==of||wa("Click OK to restore the previous "+Cb+" machine state, or CANCEL to reset the machine.")){if(c=mf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?gf(d,f):("error"==g&&"no machine state"!= -f?(this.ba("Error: "+f),"unable to verify user"==f&&(nb(vf,""),this.i=null)):this.f(g+": "+f),tf(d),gf(d)?(c=mf(d),e=!0):c=!1))}e&&kf(this,c?d:null)}else a==sf&&d.clear()}else kf(this);delete this.L;delete this.I}e=w(this.id);for(g=0;ga[1];a=a[2];this.R=!0;this.j.W=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(wf(this,this.g,b,c,a),K(this,-2),this.g.Z());this.O&&(rf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; -function rf(a,b){if(wa("There may be a problem with your "+Cb+" machine.\n\nTo help us diagnose it, click OK to send this "+Cb+" machine state to http://www.pcjs.org.")){var c=a.ca;a=a.i||"";b=b.toString();var d={};d.app=Cb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;ib("http://www.pcjs.org/api/v1/report",d,!0)}} -function $e(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new J(a,"1.34.0"),f=new J(a,"1.34.0",lf),h=hb();f.set(nf,h);g.set(nf,h);g.set(xf,"1.34.0");g.set(yf,window?window.location.href:null);g.set(zf,window?window.navigator.userAgent:"");a.g&&a.g.ea&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.S()),d=a.g.ea(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.W=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Da+=d))&&(e.textContent=c.j.K?c.P.toFixed(2)+"Mhz":"Stopped",c.Da=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.da||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");ib(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],f);Vf(a,b,c)}})}else c(a,null)} -function Wf(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Sf||yb(!0));m=!1}var h,k,m=!0;Sf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Tf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Sf||yb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Sf|| -yb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Tf(c,b,a,e,!0,g,n):Uf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(S){f(S.message)}return m}window.embedPDP10=function(a,b,c,d){yb(!1);return Wf("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){yb(!1);return Wf("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,R--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function Rd(a,b){if(b)return Qd(a,b,a.aa[b]);var c=0;for(b in a.aa)Qd(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var Pd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Sd(a){Jd.call(this,a);this.wa=!1;this.oa=!0;this.J=X();this.ua=X();this.O=X();this.F=[];this.b=this.L=this.I=[];Td(this);this.S=this.ia=0;this.i=[];this.ra=void 0;Ud(this);this.A=this;this.pa={};this.X=this.ib=0;this.T=null;this.N=[];Vd(this,a.messages);this.ta=a.commands;this.M=0;this.Ca=this.sa=null;this.B=this.ya=this.xa=this.ha=this.qa=0;this.ga=this.ca=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return cd(b,a)}):void 0===global[C]&&(global[C]=function(a){return cd(b, +a)})}p(Sd,Jd);function Y(a){a=a&&a.w;null==a&&(a=-1);return a}function X(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ma:!1,da:c}}function Wd(a){return[a.w,a.wb,a.da,a.ma,a.Na]}function Xd(a,b){var c=X(b[0],b[1],b[2]);c.ma=b[3];b[4]&&(c.gb=Kd(a,c.Na=b[4]));return c}l=Sd.prototype; +l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ga=a.u;(a=Yc(a,"messages"))&&Vd(this,a);Yd(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=sc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=pd(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(c=a.i[a.S],c.w=b,c.ma=!1,c.da=void 0,++a.S==a.i.length&&(a.S=0)));return!1} +function Ne(a,b,c,d){var e=X(b.w),g=a.Ba(b,1),f,h,k,m=0,n=g/Gb|0,r;for(r in Oe)if(f=Oe[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Pe;m=n&3;break;case 32256:k=Qe;m=n&7;break;case 29248:k=Re,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Se&&(k="B");k=Te[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Hb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=$d(g);g=k;f="";h=N(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.Ba(e,1),f+=" "+$d(k),null== +e.w)break;while(e.w!=b.w)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function Td(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.I)for(b=1;b>>d.i],!0);a.I=["bw"];a.qa=0;a.ia=0} +l.Aa=function(a,b,c){var d=!0;c||Ue(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Aa(e&16383,a==this.I)}}d&&(a.push(b),c?b.ma=!0:(Ve(this,a,a.length-1,"set"),Ud(this)));return d};function Ue(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.I));h.ma||Ud(a);break}}return g} +function We(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=Za(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.F.push({$c:b,w:c,zb:d,U:e,hb:g})} +function Ze(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ne(a,b,f,g);a.f(g);a.J=b;e-=b.w-k;c++}}} +function Xe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Je+b):(a.R&&(a.f("ended assemble at "+N(a,a.O.w)),a.J=a.O,a.R=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.T=null;if(Ka(a)&&0n||"z"T.length&&(a.f("note: only "+T.length+" available"),K=T.length);O-=K;0>O&&(null==T[T.length-1].w?(K=O+K,O=0):O+=T.length);var Ac=[];"call"==ke&&($a=1E5,Ac=["CALL"]);for(void 0!==je&&a.f(K+" instructions earlier:");0<$a&&O!=a.S;){var ne=T[O++];if(null==ne.w)break;var ab=X(ne.w),Jf=K--,oe=Ne(a,ab,"history",Jf);(!Ac.length||0<=oe.indexOf(Ac[0]))&&a.f(oe);ab.Ua&&(O+=ab.Ua,$a-=ab.Ua,K-=ab.Ua);O>=T.length&&(O=0);a.ra=K;me++;$a--}}me||(a.f("no "+le+"history available"), +a.ra=void 0)}else{var na=Z(a,S);if(na){var oa=0,pe="ds"==Fa;if(da){if("l"==da.charAt(0))da=da.substr(1)||If,oa=Od(a,da);else{var qe=Z(a,da);qe&&(oa=qe.w-na.w)}0>oa&&(oa=0);65536ue;ue++)se+=String.fromCharCode((Ib%64|0)+32), +Ib/=64}pa&&(pa+="\n");pa=pe?pa+(qa+","):pa+(S+": "+qa+(0>te?" "+se:""))}pa&&a.f(pa);a.ua=na;a.da=Kf}}}}break;case "e":if("else"==f[0])break;var ve,we,xe=f[0],Dc=f[1];"e"==xe||"ew"==xe?(ve=a.Ba,we=a.$a):Dc=null;if(null==Dc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Jb=Z(a,Dc);if(Jb)for(var Kb=2;KbHc;){for(var ra=null,Of=256;65536>cb.w>>>0;){Ic.w=a.Ba(cb,2);if(null==cb.w||!Of--)break;if(!(Ic.w&1)){for(var Pf=a,Lb=Ic,ze=null,db=Lb.w,Ae=db,Jc=1;6>=Jc&&db;Jc++){if(2> ";tb(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;blf){if(mf(d,this.L)){this.B=new L(this,"1.34.0",vf);mf(this.B)&&(wf(this,d),a=xf,yf(this.B));this.B.set(sf,hb());zf(this.B);var e=this.b&&!this.J;if(a==tf||wa("Click OK to restore the previous "+Bb+" machine state, or CANCEL to reset the machine.")){if(c=rf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?mf(d,f):("error"==g&&"no machine state"!= +f?(this.ba("Error: "+f),"unable to verify user"==f&&(mb(Af,""),this.i=null)):this.f(g+": "+f),yf(d),mf(d)?(c=rf(d),e=!0):c=!1))}e&&pf(this,c?d:null)}else a==xf&&d.clear()}else pf(this);delete this.L;delete this.I}e=w(this.id);for(g=0;ga[1];a=a[2];this.S=!0;this.j.V=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(Bf(this,this.g,b,c,a),M(this,-2),this.g.Z());this.O&&(wf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; +function wf(a,b){if(wa("There may be a problem with your "+Bb+" machine.\n\nTo help us diagnose it, click OK to send this "+Bb+" machine state to http://www.pcjs.org.")){var c=a.ca;a=a.i||"";b=b.toString();var d={};d.app=Bb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function ef(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new L(a,"1.34.0"),f=new L(a,"1.34.0",qf),h=hb();f.set(sf,h);g.set(sf,h);g.set(Cf,"1.34.0");g.set(Df,window?window.location.href:null);g.set(Ef,window?window.navigator.userAgent:"");a.g&&a.g.ea&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.W()),d=a.g.ea(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.V=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Ca+=d))&&(e.textContent=c.j.K?c.R.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.da||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);$f(a,b,c)}})}else c(a,null)} +function ag(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Xf||xb(!0));m=!1}var h,k,m=!0;Xf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Yf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Xf||xb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Xf|| +xb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Yf(c,b,a,e,!0,g,n):Zf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(R){f(R.message)}return m}window.embedPDP10=function(a,b,c,d){xb(!1);return ag("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){xb(!1);return ag("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var ja=Math.pow(2,36),ka=-Math.pow(2,35),q={Cb:0,Ra:1,Eb:2,Fb:3,Gb:4,Hb:5,Ib:6,Jb:7,Ja:8,Kb:9,Sa:10,Lb:11,Mb:12,Ta:13,Nb:14,Ob:15,Pb:16,Qb:17,Rb:18,Sb:19,Tb:20,Ub:21,Vb:22,Wb:23,Xb:24,Yb:25,Zb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,Bb:66,Db:67,$b:68,E:69,ac:70,bc:71,cc:72,dc:73,ec:74,fc:75,gc:76,hc:77,ic:78,jc:79,kc:80,Q:81, -lc:82,mc:83,nc:84,oc:85,pc:86,qc:87,rc:88,sc:89,Ya:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,tc:97,uc:98,vc:99,d:100,e:101,wc:102,xc:103,yc:104,zc:105,Ac:106,k:107,Bc:108,Cc:109,n:110,Dc:111,p:112,q:113,r:114,Ec:115,t:116,Fc:117,Gc:118,Hc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ua:127}; -function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.na=this.id:(this.oa=this.id.substr(0,a),this.na=this.id.substr(a+1));this.b={ready:!1,ta:!1,Ga:!1,B:!1,error:!1};this.wa=null;this.b.error=!1;this.s=this.f=this.l=this.o=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} +var ia=Math.pow(2,36),ka=-Math.pow(2,35),q={yb:0,Ra:1,Ab:2,Bb:3,Cb:4,Db:5,Eb:6,Fb:7,Ja:8,Gb:9,Sa:10,Hb:11,Ib:12,Ta:13,Jb:14,Kb:15,Lb:16,Mb:17,Nb:18,Ob:19,Pb:20,Qb:21,Rb:22,Sb:23,Tb:24,Ub:25,Vb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,xb:66,zb:67,Wb:68,E:69,Xb:70,Yb:71,Zb:72,$b:73,ac:74,bc:75,cc:76,dc:77,ec:78,fc:79,gc:80,Q:81, +hc:82,ic:83,jc:84,kc:85,lc:86,mc:87,nc:88,oc:89,Ya:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pc:97,qc:98,rc:99,d:100,e:101,sc:102,tc:103,uc:104,vc:105,wc:106,k:107,xc:108,yc:109,n:110,zc:111,p:112,q:113,r:114,Ac:115,t:116,Bc:117,Cc:118,Dc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ua:127}; +function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.la=this.id:(this.ma=this.id.substr(0,a),this.la=this.id.substr(a+1));this.b={ready:!1,ra:!1,Da:!1,B:!1,error:!1};this.ta=null;this.b.error=!1;this.u=this.f=this.l=this.o=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} function x(a){window&&window.alert(a)}function na(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.s=this.f=this.l=this.o=null;this.exports={hold:this.$a,toggle:this.ub,reset:this.qb, -set:this.tb};E(this)}n(Wa,t);k=Wa.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; -k.U=function(a,b,c,d){if(this.o&&this.o.U(a,b,c,d)||this.f&&this.f.U(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.D++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.D++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Ya(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Ya(a, -b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):t.prototype.U.call(this,a,b,c,d)}};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.s=d;Za(this);$a(this)};k.V=function(a,b){if(!b)if(this.R&&ab(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.P=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; -k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),N(this,this.h=a[1]),bb(this,a[2]);return!0};k.qb=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}$a(this);return!0};function cb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Za(a,b){for(var c in a.j)cb(a,c,null!=b?b:a.j[c])}function db(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function $a(a){for(var b in a.a)db(a,b,a.a[b][1])} -k.$a=function(a,b,c){if(Ya(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; -k.tb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.s(b&16383,b);a.h--;a=b}else a=this.f.m(this.c);N(this,this.h=a)}};k.gb=function(a){a||this.f.b.w||Q(this,this.g)};k.fb=function(a){a?(this.u=!0,Za(this,!0)):(this.u=!1,Za(this),bb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.ya+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.ya){p=h.size-(e-l);p>f&&(p=f);h.ya=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return sb(tb,e,f)}e=new T(a,e,p,16384,d);pb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+ub[d]+" at "+wa(b)),!0):sb(vb,b,c)}function nb(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} -function qb(a){for(var b=0,c=[],d=0;d=c+d?a>>c&(1<=a.R&&(a.R+=a.da,c=!0);0<=a.ea&&a.ea<=Kb(a)&&(a.da=a.ea=-1,Jb(a),R(a),c=!0);c&&a.K(Kb(a)+" cycles: checksum="+F(a.pa))}} -k.U=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.o)if(a=d.o,a.b.B)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.O&&(b=1);a.W=b;b=a.Ca*a.W;if(a.O!=b){a.O=b;b=a.O.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.K("target speed: "+b)}c&&a.o&&(c=a.o,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}kb(a,a.u);a.u=0;a.j=w();a.C=0;Mb(a)}function Ob(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Pb(a,b){var c=a.D-=a.G;a.G=0;b&&(a.D=0);return c} -k.rb=function(){if(this.b.w){this.ra>=this.Ea&&Mb(this,!0);this.ca=0;this.la=w();if(this.C){var a=this.la-this.C;a>this.Da&&(this.j+=a,this.j>this.la&&(this.j=this.la))}try{do{for(var b,c=this.b.ua?1:this.fa,d=this.v.length-1;0<=d;d--){var e=this.v[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.za(b)}catch(f){if("number"!=typeof f)throw f;}b=Pb(this,!0);this.ca+=b;this.u+=b;lb(this,b);jb(this,b);this.X-=b;if(0>=this.X){this.X+=this.fa;++this.Fa>=Qb&&(this.o&&S(this.o,void 0),this.Fa=0);break}}while(this.b.w)}catch(f){R(this); -this.o&&this.o.stop(w(),Kb(this));a=f.stack||f.message;this.b.error=!0;this.F(a);return}if(this.b.w){a=setTimeout;b=this.Na;this.C=w();c=this.Da;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.C-this.la;if(d=this.C-this.j)this.L=Math.round(this.u/(10*d))/100,864E5<=d&&(this.I=0,Lb(this));if(0>c||this.Lc&&(this.j-=c),c=0;this.ra+=this.ca;this.C+=c;a(b,c)}}}; -function ib(a){var b;a.b.error?(a.K(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.w)a.K(a.toString()+" busy");else{Lb(a);a.b.w=!0;a.b.Ha=!0;if(b=a.i.run)b.textContent="Halt";a.o&&a.o.start(a.j,Kb(a));a.s||a.status("Started");setTimeout(a.Na,0)}}k.za=function(){return 0};function R(a){var b=!1;if(a.b.w){Pb(a);kb(a,a.u);a.u=0;a.b.w=!1;if(b=a.i.run)b.textContent="Run";a.o&&a.o.stop(w(),Kb(a));b=!0;a.s||a.status("Stopped")}a.b.complete=void 0;return b}var Nb=30,Qb=15,Hb=["power","reset"]; -function Rb(a){var b=+a.model||1001;Gb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Sb.bind(this);this.a=V.bind(this);this.ja=null;this.Ka=[];this.b.complete=!1}n(Rb,Gb);k=Rb.prototype;k.reset=function(){this.status("Model "+this.Va);this.b.w&&R(this);this.c=this.M=this.sa=0;this.ka=this.h=this.Ba=this.La;this.g=0;this.m=this.nb;this.A=this.Ab;this.ja=null;Ib(this);this.b.error=!1;Gb.prototype.reset.call(this)};k.Pa=function(){return 0}; -k.save=function(){var a=new P(this);a.set(0,[this.c,this.M,this.sa,this.h,this.Ba,this.ka,this.g]);a.set(1,[]);a.set(2,[this.I,this.W,this.b.J]);a.set(3,Tb(this));a.set(4,Ob(this));return a.data()}; -k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.c=b.next().value;this.M=b.next().value;this.sa=b.next().value;this.h=b.next().value;this.Ba=b.next().value;this.ka=b.next().value;this.g=b.next().value;b=a[2];this.I=b[0];Lb(this,b[1]);this.b.J=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].m(a&16383,a)};k.Ab=function(a,b){var c=this.l;a=this.ka=a;c.a[(a&c.g)>>>c.c].A(b,a&16383,a)}; -k.za=function(a){this.b.complete=!0;var b=a?this.b.Ha?0:1:-1;this.b.Ha=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ja||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.s.h(this.h,b)){R(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.m(this.c):this.sa=this.m(this.Ba=this.h);this.c=this.M&262143;if(a=this.M>>18&15)this.c=this.c+this.m(a)&Ta;this.M&4194304?a=-1:(this.h=(this.h+1)%Sa,a=this.sa/Va|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Vb(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){a&=15;var b=this.m(this.c),c=this.m(a);this.A(a,(c&262143)+(b-(b&262143)))}function Yb(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a);this.A(a,c-(c&262143)+b)}function X(a){this.a(a)} -function V(a){this.K("undefined opcode: "+wa(a));this.h=(this.h+-1)%Sa;R(this)} -var Ub=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +var C="pdp10",L="PDPjs",Sa=Math.pow(2,18),Ta=Math.pow(2,18)-1,Ua=Math.pow(2,36),M=Math.pow(2,18),Va=Math.pow(2,35)-1,Wa=Math.pow(2,23),C="pdp10",L="PDPjs"; +function Xa(a,b){t.call(this,"Panel",a);this.C=this.D=0;this.R=b;this.c=this.w=this.g=this.h=0;this.G=this.I=-1;this.L=this.M=this.s=!1;this.O=Ya;this.j={};this.a={START:[1,1,!0,!1,this.ib],STEP:[1,1,!1,!1,this.jb],ENABLE:[1,1,!1,!1,this.cb],CONT:[1,1,!0,!1,this.ab],DEP:[0,0,!0,!1,this.bb],EXAM:[1,1,!0,!1,this.eb],LOAD:[1,1,!0,!1,this.gb],TEST:[0,0,!0,!1,this.fb]};for(a=0;22>a;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.u=this.f=this.l=this.o=null;this.exports={hold:this.$a,toggle:this.sb,reset:this.ob, +set:this.rb};E(this)}n(Xa,t);k=Xa.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; +k.U=function(a,b,c,d){if(this.o&&this.o.U(a,b,c,d)||this.f&&this.f.U(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.D++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.D++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Za(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){O(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Za(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){O(a,b)}}(this,b),!0):t.prototype.U.call(this,a,b,c,d)}};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.u=d;$a(this);ab(this)};k.V=function(a,b){if(!b)if(this.R&&bb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.P=function(a){return a?this.save():!0};k.save=function(){var a=new P(this);a.set(0,[this.c,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])Q(this,this.c=a[0]),N(this,this.h=a[1]),cb(this,a[2]);return!0};k.ob=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}ab(this);return!0};function db(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function $a(a,b){for(var c in a.j)db(a,c,null!=b?b:a.j[c])}function eb(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function ab(a){for(var b in a.a)eb(a,b,a.a[b][1])} +k.$a=function(a,b,c){if(Za(this,b)){if(c){var d=this;setTimeout(function(){O(d,b);a&&a()},+c);return!1}O(this,b)}return!0}; +k.rb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.c];a.h++;b=c.o(b&16383,b);a.h--;a=b}else a=this.f.m(this.c);N(this,this.h=a)}};k.gb=function(a){a||this.f.b.A||Q(this,this.g)};k.fb=function(a){a?(this.s=!0,$a(this,!0)):(this.s=!1,$a(this),cb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.c;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.va+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.va){p=h.size-(e-l);p>f&&(p=f);h.va=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return tb(ub,e,f)}e=new T(a,e,p,16384,d);qb(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+vb[d]+" at "+wa(b)),!0):tb(wb,b,c)}function ob(a,b,c){var d=a.a[(b&a.g)>>>a.c];a.h++;d.l(c,b&16383,b);a.h--} +function rb(a){for(var b=0,c=[],d=0;d=a.R&&(a.R+=a.da,c=!0);0<=a.ea&&a.ea<=Lb(a)&&(a.da=a.ea=-1,Kb(a),R(a),c=!0);c&&a.K(Lb(a)+" cycles: checksum="+F(a.na))}} +k.U=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.o)if(a=d.o,a.b.B)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.O&&(b=1);a.W=b;b=a.za*a.W;if(a.O!=b){a.O=b;b=a.O.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.K("target speed: "+b)}c&&a.o&&(c=a.o,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}lb(a,a.s);a.s=0;a.j=w();a.C=0;Nb(a)}function Pb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Qb(a,b){var c=a.D-=a.G;a.G=0;b&&(a.D=0);return c} +k.pb=function(){if(this.b.A){this.pa>=this.Ba&&Nb(this,!0);this.ca=0;this.ja=w();if(this.C){var a=this.ja-this.C;a>this.Aa&&(this.j+=a,this.j>this.ja&&(this.j=this.ja))}try{do{for(var b,c=this.b.sa?1:this.fa,d=this.w.length-1;0<=d;d--){var e=this.w[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.wa(b)}catch(f){if("number"!=typeof f)throw f;}b=Qb(this,!0);this.ca+=b;this.s+=b;mb(this,b);kb(this,b);this.X-=b;if(0>=this.X){this.X+=this.fa;++this.Ca>=Rb&&(this.o&&S(this.o,void 0),this.Ca=0);break}}while(this.b.A)}catch(f){R(this); +this.o&&this.o.stop(w(),Lb(this));a=f.stack||f.message;this.b.error=!0;this.F(a);return}if(this.b.A){a=setTimeout;b=this.Na;this.C=w();c=this.Aa;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.C-this.ja;if(d=this.C-this.j)this.L=Math.round(this.s/(10*d))/100,864E5<=d&&(this.I=0,Mb(this));if(0>c||this.Lc&&(this.j-=c),c=0;this.pa+=this.ca;this.C+=c;a(b,c)}}}; +function jb(a){var b;a.b.error?(a.K(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.b.A)a.K(a.toString()+" busy");else{Mb(a);a.b.A=!0;a.b.Ga=!0;if(b=a.i.run)b.textContent="Halt";a.o&&a.o.start(a.j,Lb(a));a.u||a.status("Started");setTimeout(a.Na,0)}}k.wa=function(){return 0};function R(a){var b=!1;if(a.b.A){Qb(a);lb(a,a.s);a.s=0;a.b.A=!1;if(b=a.i.run)b.textContent="Run";a.o&&a.o.stop(w(),Lb(a));b=!0;a.u||a.status("Stopped")}a.b.complete=void 0;return b}var Ob=30,Rb=15,Ib=["power","reset"]; +function Sb(a){var b=+a.model||1001;Hb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Tb.bind(this);this.a=V.bind(this);this.ha=null;this.Ka=[];this.b.complete=!1}n(Sb,Hb);k=Sb.prototype;k.reset=function(){this.status("Model "+this.Va);this.b.A&&R(this);this.c=this.M=this.qa=0;this.ia=this.h=this.ya=this.La;this.g=0;this.m=this.lb;this.v=this.wb;this.ha=null;Jb(this);this.b.error=!1;Hb.prototype.reset.call(this)};k.Pa=function(){return 0}; +k.save=function(){var a=new P(this);a.set(0,[this.c,this.M,this.qa,this.h,this.ya,this.ia,this.g]);a.set(1,[]);a.set(2,[this.I,this.W,this.b.J]);a.set(3,Ub(this));a.set(4,Pb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.c=b.next().value;this.M=b.next().value;this.qa=b.next().value;this.h=b.next().value;this.ya=b.next().value;this.ia=b.next().value;this.g=b.next().value;b=a[2];this.I=b[0];Mb(this,b[1]);this.b.J=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.c].m(a&16383,a)};k.wb=function(a,b){var c=this.l;a=this.ia=a;c.a[(a&c.g)>>>c.c].v(b,a&16383,a)}; +k.wa=function(a){this.b.complete=!0;var b=a?this.b.Ga?0:1:-1;this.b.Ga=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ha||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.u.h(this.h,b)){R(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.m(this.c):this.qa=this.m(this.ya=this.h);this.c=this.M&262143;if(a=this.M>>18&15)this.c=this.c+this.m(a)&Ta;this.M&4194304?a=-1:(this.h=(this.h+1)%Sa,a=this.qa/Wa|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){this.a(a)}function Yb(a){var b=a&15,c=this.m(this.c),d=this.m(b),d=Zb(a,d,c)+(c-(c&262143));this.v(b,d)}function $b(a){var b=a&15,c=this.m(b),c=Zb(a,c,0);this.v(b,c)} +function ac(a){var b=this.m(a&15),c=this.m(this.c),c=Zb(a,c,b)+(b-(b&262143));this.v(this.c,c)}function bc(a){var b=this.m(this.c);this.v(this.c,Zb(a,b,b));var c=a&15;c&&(b=this.m(c),this.v(c,Zb(a,b,b)))}function cc(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a);this.v(a,c-(c&262143)+b)}function X(a){this.a(a)}function V(a){this.K("undefined opcode: "+wa(a));this.h=(this.h+-1)%Sa;R(this)} +function Zb(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Va?262143:0}return b} +var Vb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,Wb,Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Vb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Wb,Xb,Xb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Wb,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, @@ -107,58 +107,57 @@ function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a) function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Xb,function(a){a&=15;var b=this.m(a);this.A(a,b&262143)},function(a){a=this.m(a&15);var b=this.m(this.c);this.A(this.c,(b&262143)+(a-(a&262143)))},function(a){a&15&&Xb.call(this,a)}, -function(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a),c=(c&262143)+b*M;this.A(a,c)},function(a){a&=15;var b=this.m(a),b=(b&262143)+this.c*M;this.A(a,b)},function(a){a=this.m(a&15)&262143;var b=this.m(this.c),b=(b&262143)+a*M;this.A(this.c,b)},function(a){var b=this.m(this.c)&262143;this.A(this.c,b+b*M);if(a&=15)b=this.m(a)&262143,this.A(a,b+b*M)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Yb,function(a){a&=15;var b=this.m(a),b=b-(b&262143)+this.c;this.A(a,b)},function(a){a=this.m(a&15)&262143;var b= -this.m(this.c);this.A(this.c,b-(b&262143)+a)},function(a){a&15&&Yb.call(this,a)},function(a){a&=15;var b=this.m(this.c)/M|0,c=this.m(a);this.A(a,c-(c&262143)+b)},function(a){a&=15;var b=this.m(a);this.A(a,b-(b&262143))},function(a){a=this.m(a&15)/M|0;var b=this.m(this.c);this.A(this.c,b-(b&262143)+a)},function(a){var b=this.m(this.c);this.A(this.c,(b&262143)+(b/M|0));if(a&=15)b=this.m(a),this.A(a,(b&262143)+(b/M|0))},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Yb,$b,ac,bc,function(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a),c=(c&262143)+b*M;this.v(a,c)},function(a){a&=15;var b=this.m(a),b=(b&262143)+this.c*M;this.v(a,b)},function(a){a= +this.m(a&15)&262143;var b=this.m(this.c),b=(b&262143)+a*M;this.v(this.c,b)},function(a){var b=this.m(this.c)&262143;this.v(this.c,b+b*M);if(a&=15)b=this.m(a)&262143,this.v(a,b+b*M)},Yb,$b,ac,bc,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Yb,$b,ac,bc,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},Yb,$b,ac,bc,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},cc,function(a){a&= +15;var b=this.m(a),b=b-(b&262143)+this.c;this.v(a,b)},function(a){a=this.m(a&15)&262143;var b=this.m(this.c);this.v(this.c,b-(b&262143)+a)},function(a){a&15&&cc.call(this,a)},function(a){a&=15;var b=this.m(this.c)/M|0,c=this.m(a);this.v(a,c-(c&262143)+b)},function(a){a&=15;var b=this.m(a);this.v(a,b-(b&262143))},function(a){a=this.m(a&15)/M|0;var b=this.m(this.c);this.v(this.c,b-(b&262143)+a)},function(a){var b=this.m(this.c);this.v(this.c,(b&262143)+(b/M|0));if(a&=15)b=this.m(a),this.v(a,(b&262143)+ +(b/M|0))},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, -function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, -X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; -function Zb(a){t.call(this,"ROM",a);this.N=this.a=null;this.j=+a.addr;this.g=+a.size;this.c=a.alias;"string"==typeof this.c&&(this.c=eval(this.c));this.h=a.file;this.u=xa(this.h);if(this.h){a=this.h;var b=ya(this.u);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.F("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(la(c.oa,a,b),(a=Ea(a,b))?(c.a=a.H,c.N=a.N):c.h=null);$b(c)})}}n(Zb,t); -Zb.prototype.Z=function(a,b,c,d){this.l=b;this.f=c;this.s=d;$b(this)};Zb.prototype.V=function(){this.N&&(this.s&&this.s.a(this.id,this.j,this.g,this.N),delete this.N);return!0};Zb.prototype.P=function(){return!0}; -function $b(a){if(!ua(a)){if(a.h){if(!a.a||!a.l)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.b.error=!0;a.F(b)}else{b=a.j;if(rb(a.l,b,a.g,zb)){var c;for(c=0;c>>f.c;0>>=f.c;0>>a.c;0g&&g>=ka&&(g+=ja);g=Math.trunc(Math.abs(g))%ja;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.xa(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.xa(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.xa(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.s=d;E(this)}; -k.Qa=function(a){if(!this.a){var b=U(this.o,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.na)return;c=Ca(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.oa+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.V=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -k.P=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.xa=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bhc){if(Z(d,this.D)){this.j=new P(this,"1.34.0",qc);Z(this.j)&&(rc(this,d),a=sc,tc(this.j));this.j.set(nc,Da());uc(this.j);var e=this.a&&!this.C;if(a==oc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=mc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= -g?(this.F("Error: "+g),"unable to verify user"==g&&(Ia(vc,""),this.c=null)):this.K(f+": "+g),tc(d),Z(d)?(c=mc(d),e=!0):c=!1))}e&&kc(this,c?d:null)}else a==sc&&d.clear()}else kc(this);delete this.D;delete this.v}e=y(this.id);for(f=0;fa[1];a=a[2];this.O=!0;this.b.B=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(wc(this,this.f,b,c,a),S(this,-2),this.f.J());this.L&&(rc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; -function rc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function xc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new P(a,"1.34.0"),g=new P(a,"1.34.0",lc),h=Da();g.set(nc,h);f.set(nc,h);f.set(yc,"1.34.0");f.set(zc,window?window.location.href:null);f.set(Ac,window?window.navigator.userAgent:"");a.f&&a.f.P&&(c&&(b&&(a.f.b.J=a.f.b.w),R(a.f)),d=a.f.P(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.B=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l>>f.c;0>>=f.c;0>>a.c;0g&&g>=ka&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.ua(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.ua(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ua(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Z=function(a,b,c,d){this.o=a;this.l=b;this.f=c;this.u=d;E(this)}; +k.Qa=function(a){if(!this.a){var b=U(this.o,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ca(c[0]);if(d!=this.la)return;c=Ca(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ma+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.V=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.P=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new P(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ua=function(a){if("number"==typeof a)this.c.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bmc){if(Z(d,this.D)){this.j=new P(this,"1.34.0",vc);Z(this.j)&&(wc(this,d),a=xc,yc(this.j));this.j.set(sc,Da());zc(this.j);var e=this.a&&!this.C;if(a==tc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=rc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.F("Error: "+g),"unable to verify user"==g&&(Ia(Ac,""),this.c=null)):this.K(f+": "+g),yc(d),Z(d)?(c=rc(d),e=!0):c=!1))}e&&pc(this,c?d:null)}else a==xc&&d.clear()}else pc(this);delete this.D;delete this.w}e=y(this.id);for(f=0;fa[1];a=a[2];this.O=!0;this.b.B=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(Bc(this,this.f,b,c,a),S(this,-2),this.f.J());this.L&&(wc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function wc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.c||"";b=b.toString();var d={};d.app=L;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function Cc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new P(a,"1.34.0"),g=new P(a,"1.34.0",qc),h=Da();g.set(sc,h);f.set(sc,h);f.set(Dc,"1.34.0");f.set(Ec,window?window.location.href:null);f.set(Fc,window?window.navigator.userAgent:"");a.f&&a.f.P&&(c&&(b&&(a.f.b.J=a.f.b.A),R(a.f)),d=a.f.P(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.b.B=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.Aa+=d))&&(e.textContent=c.b.w?c.L.toFixed(2)+"Mhz":"Stopped",c.Aa=0)}if(a.g&&(a=a.g,b=b||0,a.D)){c=a.f.b.w;d=!!(a.f.g&8);if(0>=b||60<=(a.C+=b)){e=a.f.h;if(a.i.PC){var f=a.s&&a.s.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.C=0}-1>b?a.c=a.f.h:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);Ic(a,b,c)}})}else c(a,null)} -function Jc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Fc||K(!0));p=!1}var h,l,p=!0;Fc++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ia=document.createElement("style");ia.type="text/css";ia.styleSheet?ia.styleSheet.cssText=r:ia.appendChild(document.createTextNode(r));v.appendChild(ia)}d|| -(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.0/components.xsl");r=function(e,l){l?Gc(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Fc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Fc|| -K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Gc(c,b,a,e,!0,f,r):Hc(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(Kc){g(Kc.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Jc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Jc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +function S(a,b){if(a.f){var c=a.f,d=b||0,e=c.i.speed;e&&(0>=d||30<=(c.xa+=d))&&(e.textContent=c.b.A?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.g&&(a=a.g,b=b||0,a.D)){c=a.f.b.A;d=!!(a.f.g&8);if(0>=b||60<=(a.C+=b)){e=a.f.h;if(a.i.PC){var f=a.u&&a.u.j||8,e=e||0,e=8==f?wa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.C=0}-1>b?a.c=a.f.h:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Nc(a,b,c)}})}else c(a,null)} +function Oc(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Aa(a))}function g(a){f("Error: "+a);p&&(--Kc||K(!0));p=!1}var h,l,p=!0;Kc++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ja=document.createElement("style");ja.type="text/css";ja.styleSheet?ja.styleSheet.cssText=r:ja.appendChild(document.createTextNode(r));v.appendChild(ja)}d|| +(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.0/components.xsl");r=function(e,l){l?Lc(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--Kc||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Kc|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Lc(c,b,a,e,!0,f,r):Mc(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(Pc){g(Pc.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return Oc("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return Oc("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!qa[a]){for(var c=!0,d=qa,e=a,f=b.length,g=[],h=[],l="",p=null,r=0;r Date: Mon, 27 Feb 2017 12:27:23 -0800 Subject: [PATCH 20/30] Minor PDP-10 debugger alignment change --- modules/pdp10/lib/debugger.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 736a72a3b..244624463 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -2495,7 +2495,7 @@ class DebuggerPDP10 extends Debugger { if (fJSON) { sDump += sData + ","; } else { - sDump += sAddr + ": " + sData + ((n < 0)? (' ' + sChars) : ""); + sDump += sAddr + ": " + sData + ((n < 0)? (' ' + sChars) : ""); } } From 8863f1127c0343de55966978d474dca076a6cb58 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Mon, 27 Feb 2017 18:06:08 -0800 Subject: [PATCH 21/30] Added rudimentary PDP-10 assembler capability to the built-in debugger --- apps/README.md | 2 +- apps/pdp10/README.md | 12 + apps/pdp10/tests/README.md | 122 ++++++ apps/pdp10/tests/optest-v01.json | 10 + apps/pdp10/tests/optest.json | 43 --- devices/pdp10/machine/ka10/test/README.md | 4 +- .../machine/ka10/test/debugger/README.md | 4 +- .../machine/ka10/test/debugger/machine.xml | 4 +- devices/pdp10/machine/ka10/test/machine.xml | 4 +- modules/pdp10/lib/cpustate.js | 8 +- modules/pdp10/lib/debugger.js | 183 +++++++-- modules/pdp10/lib/defines.js | 3 +- versions/pdpjs/1.34.0/pdp10-dbg.js | 360 +++++++++--------- versions/pdpjs/1.34.0/pdp10.js | 4 +- 14 files changed, 501 insertions(+), 262 deletions(-) create mode 100644 apps/pdp10/README.md create mode 100644 apps/pdp10/tests/README.md create mode 100644 apps/pdp10/tests/optest-v01.json delete mode 100644 apps/pdp10/tests/optest.json diff --git a/apps/README.md b/apps/README.md index 2e00e9101..dce8a53e3 100644 --- a/apps/README.md +++ b/apps/README.md @@ -13,7 +13,7 @@ PCjs has archived selected software for the following machines: * [IBM PC](pcx86/) * [Challenger 1P](c1p/) -* [PDP-11](pdp11/) +* DEC [PDP-10](pdp10/) and [PDP-11](pdp11/) PCjs also includes a small collection of disk images in the [Disk Libraries](/disks/): diff --git a/apps/pdp10/README.md b/apps/pdp10/README.md new file mode 100644 index 000000000..e8e7bce25 --- /dev/null +++ b/apps/pdp10/README.md @@ -0,0 +1,12 @@ +--- +layout: page +title: PDP-10 Software +permalink: /apps/pdp10/ +--- + +PDP-10 Software +--------------- + +PCjs provides the following PDP-10 tests: + +- [PDP-10 Opcode Tests](tests/) diff --git a/apps/pdp10/tests/README.md b/apps/pdp10/tests/README.md new file mode 100644 index 000000000..77c1ec717 --- /dev/null +++ b/apps/pdp10/tests/README.md @@ -0,0 +1,122 @@ +--- +layout: page +title: DEC PDP-10 Opcode Tests +permalink: /apps/pdp10/tests/ +machines: + - id: testka10 + type: pdp10 + debugger: true + config: /devices/pdp10/machine/ka10/test/debugger/machine.xml +--- + +DEC PDP-10 Opcode Tests +----------------------- + +The PDP-10 machine below loads the following test: + +- [PDP-10 Half-Word Opcode Test](optest-v01.json) + +Details on how to run and modify the test, and perform similar tests in [SIMH](https://github.com/simh/simh), +are provided below. + +{% include machine.html id="testka10" %} + +The [PDP-10 Half-Word Opcode Test](optest-v01.json) file specifies that the following words: + + 0o505040111111, // HRLI 1,111111 + 0o541040444444, // HRRI 1,444444 + 0o544100000001, // HLR 2,1 + 0o504100000001, // HRL 2,1 + +should be loaded at address 0o100, and that the program counter (PC register) should be set to 0o100. The embedded +comments display the instructions that correspond to each word. + +If you want to alter or add new instructions, the PDP-10 Debugger now includes a rudimentary assembler. Using the `a` command, +along with an optional start address, you can enter "assembler mode". For example, here's how the first four instructions from +the [PDP-10 Half-Word Opcode Test](optest-v01.json) could be entered by hand: + + >> a 100 + begin assemble at 000100 + >> hrli 1,111111 + 000100: 505040 111111 HRLI 1,111111 + >> hrri 1,444444 + 000101: 541040 444444 HRRI 1,444444 + >> hlr 2,1 + 000102: 544100 000001 HLR 2,1 + >> hrl 2,1 + 000103: 504100 000001 HRL 2,1 + ended assemble at 000104 + +Entering a blank line exits "assembler mode". To disassemble the four instructions, use `u 100 l4`: + + >> u 100 l4 + 000100: 505040 111111 HRLI 1,111111 + 000101: 541040 444444 HRRI 1,444444 + 000102: 544100 000001 HLR 2,1 + 000103: 504100 000001 HRL 2,1 + +You can also copy-and-paste a series of instructions into the PDPjs Debugger, as long as each command ends +with a semicolon: + + a 100; + hrli 1,111111; + hrri 1,444444; + hlr 2,1; + hrl 2,1; + end + +Individual instructions can also be assembled *without* entering "assembler mode", as long as you precede +each instruction with the `a` command and a specific address: + + a 100 hrli 1,111111; + a 101 hrri 1,444444; + a 102 hlr 2,1; + a 103 hrl 2,1 + +Individual instructions can be executed with the `t` command and memory can be dumped with the `d` command. + +After executing the first four instructions and using the `d 0 l4` command to dump first four words of memory +(also known as AC registers 0-3), you should see the following output: + + >> r + 000100: 505040 111111 HRLI 1,111111 + >> t + 000101: 541040 444444 HRRI 1,444444 + >> t + 000102: 544100 000001 HLR 2,1 + >> t + 000103: 504100 000001 HRL 2,1 + >> t + 000104: 000000 000000 UUO 0,0 + >> d 0 l4 + 000000: 000000 000000 111111 444444 444444 111111 000000 000000 + +To assemble and test the same instructions in [SIMH](https://github.com/simh/simh), using the `pdp10` binary: + + sim> dep 100 505040111111 + sim> dep 101 541040444444 + sim> dep 102 544100000001 + sim> dep 103 504100000001 + sim> ex -m 100-103 + 100: HRLI 1,111111 + 101: HRRI 1,444444 + 102: HLR 2,1 + 103: HRL 2,1 + sim> dep pc 100 + sim> step + + Step expired, PC: 000101 (HRRI 1,444444) + sim> step + + Step expired, PC: 000102 (HLR 2,1) + sim> step + + Step expired, PC: 000103 (HRL 2,1) + sim> step + + Step expired, PC: 000104 (000000000000) + sim> ex 0-3 + 0: 000000000000 + 1: 111111444444 + 2: 444444111111 + 3: 000000000000 diff --git a/apps/pdp10/tests/optest-v01.json b/apps/pdp10/tests/optest-v01.json new file mode 100644 index 000000000..fa347e3a4 --- /dev/null +++ b/apps/pdp10/tests/optest-v01.json @@ -0,0 +1,10 @@ +{ + "load": 0o100, + "exec": 0o100, + "data": [ + 0o505040111111, // HRLI 1,111111 + 0o541040444444, // HRRI 1,444444 + 0o544100000001, // HLR 2,1 + 0o504100000001, // HRL 2,1 + ] +} diff --git a/apps/pdp10/tests/optest.json b/apps/pdp10/tests/optest.json deleted file mode 100644 index e4cdc9c42..000000000 --- a/apps/pdp10/tests/optest.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "load": 0o100, - "exec": 0o100, - "data": [ - 0o505040111111, // HRLI 1,111111 - 0o541040222222, // HRRI 1,222222 - 0o544100000001, // HLR 2,1 - 0o504100000001, // HRL 2,1 - // - // >> dw 0 l4 - // 000000: 000000 000000 111111 222222 222222 111111 000000 000000 - // - // Compare to SIMH: - // - // sim> dep 100 505040111111 - // sim> dep 101 541040222222 - // sim> dep 102 544100000001 - // sim> dep 103 504100000001 - // sim> ex -m 100-103 - // 100: HRLI 1,111111 - // 101: HRRI 1,222222 - // 102: HLR 2,1 - // 103: HRL 2,1 - // sim> dep pc 100 - // sim> step - // - // Step expired, PC: 000101 (HRRI 1,222222) - // sim> step - // - // Step expired, PC: 000102 (HLR 2,1) - // sim> step - // - // Step expired, PC: 000103 (HRL 2,1) - // sim> step - // - // Step expired, PC: 000104 (000000000000) - // sim> ex 0-3 - // 0: 000000000000 - // 1: 111111222222 - // 2: 222222111111 - // 3: 000000000000 - ] -} diff --git a/devices/pdp10/machine/ka10/test/README.md b/devices/pdp10/machine/ka10/test/README.md index bccf4f095..70ad9e6e5 100644 --- a/devices/pdp10/machine/ka10/test/README.md +++ b/devices/pdp10/machine/ka10/test/README.md @@ -3,7 +3,7 @@ layout: page title: PDP-10 (Model KA10) Test Machine permalink: /devices/pdp10/machine/ka10/test/ machines: - - id: ka10test + - id: testka10 type: pdp10 --- @@ -14,4 +14,4 @@ A PDP-10 (Model KA10) is simulated below. **WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. -{% include machine.html id="ka10test" %} +{% include machine.html id="testka10" %} diff --git a/devices/pdp10/machine/ka10/test/debugger/README.md b/devices/pdp10/machine/ka10/test/debugger/README.md index ad8b6c6ea..4af850265 100644 --- a/devices/pdp10/machine/ka10/test/debugger/README.md +++ b/devices/pdp10/machine/ka10/test/debugger/README.md @@ -3,7 +3,7 @@ layout: page title: PDP-10 (Model KA10) Test Machine with Debugger permalink: /devices/pdp10/machine/ka10/test/debugger/ machines: - - id: ka10test + - id: testka10 type: pdp10 debugger: true --- @@ -15,4 +15,4 @@ A PDP-10 (Model KA10) is simulated below. **WARNING**: PDP-10 emulation is still in development, so functionality will be limited until further notice. -{% include machine.html id="ka10test" %} +{% include machine.html id="testka10" %} diff --git a/devices/pdp10/machine/ka10/test/debugger/machine.xml b/devices/pdp10/machine/ka10/test/debugger/machine.xml index 64045e743..31fdcacc5 100644 --- a/devices/pdp10/machine/ka10/test/debugger/machine.xml +++ b/devices/pdp10/machine/ka10/test/debugger/machine.xml @@ -1,10 +1,10 @@ - + PDP-10 Test Machine with Debugger - + diff --git a/devices/pdp10/machine/ka10/test/machine.xml b/devices/pdp10/machine/ka10/test/machine.xml index e8a6fe7a0..86bae80b6 100644 --- a/devices/pdp10/machine/ka10/test/machine.xml +++ b/devices/pdp10/machine/ka10/test/machine.xml @@ -1,10 +1,10 @@ - + PDP-10 Test Machine - + diff --git a/modules/pdp10/lib/cpustate.js b/modules/pdp10/lib/cpustate.js index f94addad5..05449adfe 100644 --- a/modules/pdp10/lib/cpustate.js +++ b/modules/pdp10/lib/cpustate.js @@ -337,10 +337,14 @@ class CPUStatePDP10 extends CPUPDP10 { */ getOpcode() { + /* + * Technically, we don't REALLY need to mask regRA with R_MASK, because all regRA accesses + * ignore any higher opcode bits, but let's keep things tidy. + */ if ((this.regRA & PDP10.OPCODE.I_BIT)) { - this.regRA = this.readWord(this.regEA); + this.regRA = this.readWord(this.regEA) & PDP10.OPCODE.R_MASK; } else { - this.regRA = this.regOP = this.readWord(this.lastPC = this.regPC); + this.regRA = (this.regOP = this.readWord(this.lastPC = this.regPC)) & PDP10.OPCODE.R_MASK; } /* diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 244624463..12eccc19d 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -227,6 +227,24 @@ class DebuggerPDP10 extends Debugger { return {addr: addr, fPhysical: fPhysical, fTemporary: false, nBase: nBase}; } + /** + * copyAddr(dbgAddr, dbgCopy) + * + * Updates an EXISTING DbgAddrPDP10 object, initialized with specified values and/or defaults. + * + * @this {DebuggerPDP10} + * @param {DbgAddrPDP10} dbgAddr + * @param {DbgAddrPDP10} dbgCopy + * @return {DbgAddrPDP10} + */ + copyAddr(dbgAddr, dbgCopy) + { + dbgAddr.addr = dbgCopy.addr; + dbgAddr.fTemporary = dbgCopy.fTemporary; + dbgAddr.nBase = dbgCopy.nBase; + return dbgAddr; + } + /** * setAddr(dbgAddr, addr) * @@ -1083,7 +1101,7 @@ class DebuggerPDP10 extends Debugger { this.println(DebuggerPDP10.PROMPT + sCmd); } - this.dbgAddrNextCode = this.newAddr(this.cpu.getPC()); + this.setAddr(this.dbgAddrNextCode, this.cpu.getPC()); /* * this.nStep used to be a simple boolean, but now it's 0 (or undefined) @@ -1170,7 +1188,7 @@ class DebuggerPDP10 extends Debugger { this.cInstructions = this.cInstructionsStart = 0; this.sMessagePrev = null; this.nCycles = 0; - this.dbgAddrNextCode = this.newAddr(this.cpu.getPC()); + this.setAddr(this.dbgAddrNextCode, this.cpu.getPC()); /* * fRunning is set by start() and cleared by stop(). In addition, we clear * it here, so that if the CPU is reset while running, we can prevent stop() @@ -1480,21 +1498,129 @@ class DebuggerPDP10 extends Debugger { } /** - * parseInstruction(sOp, sOperand, addr) - * - * TODO: Unimplemented. See parseInstruction() in modules/c1pjs/lib/debugger.js for a sample implementation. + * parseInstruction(sOpCode, sOperands, addr) * * @this {DebuggerPDP10} - * @param {string} sOp - * @param {string|undefined} sOperand + * @param {string} sOpCode + * @param {string|undefined} sOperands * @param {DbgAddrPDP10} dbgAddr of memory where this instruction is being assembled - * @return {Array.} of opcode bytes; if the instruction can't be parsed, the array will be empty + * @return {number} (opcode, or -1 if unrecognized instruction) */ - parseInstruction(sOp, sOperand, dbgAddr) + parseInstruction(sOpCode, sOperands, dbgAddr) { - var aOpBytes = []; - this.println("not supported yet"); - return aOpBytes; + var opCode = -1, opMask; + var sMnemonic = sOpCode.toUpperCase(); + + for (var mask in DebuggerPDP10.OPTABLE) { + + var aModes; + opMask = +mask; + var opMasks = DebuggerPDP10.OPTABLE[mask]; + + switch(opMask) { + case PDP10.OPCODE.OPMODE: + aModes = DebuggerPDP10.OPMODES; + break; + case PDP10.OPCODE.OPCOMP: + aModes = DebuggerPDP10.OPCOMPS; + break; + case PDP10.OPCODE.OPTEST: + aModes = DebuggerPDP10.OPTESTS; + break; + default: + aModes = [""]; + break; + } + + var opMode = 0; + for (var op in opMasks) { + + var opNum = opMasks[op]; + for (var iMode = 0; iMode < aModes.length; iMode++) { + + var sMode = aModes[iMode]; + if (sMode == "S" && opNum > DebuggerPDP10.OPS.MOVM) sMode = "B"; + var sCandidate = DebuggerPDP10.OPNAMES[opNum] + sMode; + + if (sMnemonic == sCandidate) { + if (opMask != PDP10.OPCODE.OPTEST) { + opMode = iMode; + } else { + opMode = ((iMode & 0o3) << 1) | ((iMode & 0o14) << 2); + } + opCode = (op | (opMode << 6)) * PDP10.OPCODE.OPSHIFT; + break; + } + } + if (opCode >= 0) break; + } + if (opCode >= 0) break; + } + + if (opCode >= 0) { + if (!sOperands) { + this.println("missing operand(s)"); + opCode = -1; + } + else { + var aOperands = sOperands.split(','); + for (var i = 0; i < aOperands.length; i++) { + var sOperand = aOperands[i].trim(); + if (!sOperand) continue; + if (i > 1) { + this.println("too many operands: " + sOperand); + opCode = -1; + break; + } + var match = sOperand.match(/(@?)([^(]*)\(?([^)]*)\)?/); + if (!match) { + this.println("unknown operand: " + sOperand); + opCode = -1; + break; + } + var operand = this.parseExpression(match[2]); + if (operand == undefined) { + opCode = -1; + break; + } + if (!i && aOperands.length > 1) { + if (operand < 0 || operand > PDP10.OPCODE.A_MASK) { + this.println("accumulator index out of range: " + match[2]); + opCode = -1; + break; + } + opCode += (operand << PDP10.OPCODE.A_SHIFT); + continue; + } + if (operand < 0 || operand > PDP10.OPCODE.Y_MASK) { + this.println("address out of range: " + match[2]); + opCode = -1; + break; + } + opCode += operand; + if (match[3]) { + operand = this.parseExpression(match[3]); + if (operand == undefined) { + opCode = -1; + break; + } + if (operand < 0 || operand > PDP10.OPCODE.X_MASK) { + this.println("index out of range: " + match[3]); + opCode = -1; + break; + } + opCode += operand << PDP10.OPCODE.X_SHIFT; + } + if (match[1]) { + opCode += PDP10.OPCODE.I_BIT; + } + } + } + } + else { + this.println("unknown instruction: " + sOpCode); + } + return opCode; } /** @@ -1903,7 +2029,8 @@ class DebuggerPDP10 extends Debugger { { var sReg = this.getRegName(iReg); if (sReg) { - sReg += '=' + this.toStrBase(this.getRegValue(iReg)) + ' '; + var nBits = (iReg == DebuggerPDP10.REGS.RA? 23 : 18); + sReg += '=' + this.toStrBase(this.getRegValue(iReg), nBits) + ' '; } return sReg; } @@ -2230,19 +2357,24 @@ class DebuggerPDP10 extends Debugger { var dbgAddr = this.parseAddr(asArgs[1], true); if (!dbgAddr) return; + var sOpCode = asArgs[2]; this.dbgAddrAssemble = dbgAddr; - if (asArgs[2] === undefined) { + + if (sOpCode == undefined) { this.println("begin assemble at " + this.toStrAddr(dbgAddr)); this.fAssemble = true; this.cmp.updateDisplays(); return; } - var aOps = this.parseInstruction(asArgs[2], asArgs[3], dbgAddr); - if (aOps.length) { - for (var i = 0; i < aOps.length; i++) { - this.setWord(dbgAddr, aOps[i], 1); - } + asArgs.shift(); + asArgs.shift(); + asArgs.shift(); + var sOperands = asArgs.join(""); + var opCode = this.parseInstruction(sOpCode, sOperands, dbgAddr); + + if (opCode >= 0) { + this.setWord(dbgAddr, opCode); /* * Since getInstruction() also updates the specified address, dbgAddrAssemble is automatically advanced. */ @@ -2500,8 +2632,7 @@ class DebuggerPDP10 extends Debugger { } if (sDump) this.println(sDump); - - this.dbgAddrNextData = dbgAddr; + this.copyAddr(this.dbgAddrNextData, dbgAddr); this.nBase = nBase; } @@ -2532,7 +2663,7 @@ class DebuggerPDP10 extends Debugger { for (var i = 2; i < asArgs.length; i++) { var vNew = this.parseExpression(asArgs[i]); if (vNew === undefined) { - this.println("unrecognized value: " + asArgs[i]); + this.println("unknown value: " + asArgs[i]); break; } this.println("changing " + this.toStrAddr(dbgAddr) + " from " + this.toStrWord(fnGet.call(this, dbgAddr)) + " to " + this.toStrWord(vNew)); @@ -2897,7 +3028,7 @@ class DebuggerPDP10 extends Debugger { switch (sRegMatch) { case "PC": cpu.setPC(w); - this.dbgAddrNextCode = this.newAddr(cpu.getPC()); + this.setAddr(this.dbgAddrNextCode, cpu.getPC()); break; default: this.println("unknown register: " + sReg); @@ -2911,7 +3042,7 @@ class DebuggerPDP10 extends Debugger { this.println(this.getRegDump(fMisc)); if (fInstruction) { - this.dbgAddrNextCode = this.newAddr(cpu.getPC()); + this.setAddr(this.dbgAddrNextCode, cpu.getPC()); this.doUnassemble(this.toStrAddr(this.dbgAddrNextCode)); } } @@ -3243,7 +3374,7 @@ class DebuggerPDP10 extends Debugger { sInstruction = this.getInstruction(dbgAddr, sComment, nSequence); this.println(sInstruction); - this.dbgAddrNextCode = dbgAddr; + this.copyAddr(this.dbgAddrNextCode, dbgAddr); nBytes -= dbgAddr.addr - addr; nPrinted++; } @@ -3295,7 +3426,7 @@ class DebuggerPDP10 extends Debugger { if (!sCmd.length || sCmd == "end") { if (this.fAssemble) { this.println("ended assemble at " + this.toStrAddr(this.dbgAddrAssemble)); - this.dbgAddrNextCode = this.dbgAddrAssemble; + this.copyAddr(this.dbgAddrNextCode, this.dbgAddrAssemble); this.fAssemble = false; } sCmd = ""; diff --git a/modules/pdp10/lib/defines.js b/modules/pdp10/lib/defines.js index 7dab8fc3f..849100ef2 100644 --- a/modules/pdp10/lib/defines.js +++ b/modules/pdp10/lib/defines.js @@ -147,13 +147,14 @@ var PDP10 = { OPSHIFT: Math.pow(2, 21), // operation shift IOSHIFT: Math.pow(2, 26), // input-output device code shift IOMASK: 0o177, // input-output device code mask (after shift) - ACSHIFT: Math.pow(2, 23), // used to isolate the high 13 bits, with A starting at bit 0 + ACSHIFT: Math.pow(2, 23), // used to shift down the high 13 bits, with A starting at bit 0 A_SHIFT: 23, // A shift A_MASK: 0o17, // A mask (after shift) I_BIT: 0o20000000, // indirect bit X_SHIFT: 18, // X shift X_MASK: 0o17, // X mask (after shift) Y_MASK: 0o777777, // Y mask + R_MASK: 0o37777777, // used to isolate the low 23 bits (I,X,Y) HALT: 0o5304 // operation code for HALT }, diff --git a/versions/pdpjs/1.34.0/pdp10-dbg.js b/versions/pdpjs/1.34.0/pdp10-dbg.js index 6251aeeba..ad014f0af 100644 --- a/versions/pdpjs/1.34.0/pdp10-dbg.js +++ b/versions/pdpjs/1.34.0/pdp10-dbg.js @@ -28,199 +28,201 @@ http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 */ -var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=fa)}var ga=0;function fa(a){return"jscomp_symbol_"+(a||"")+ga++} -function ha(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ia(this)}});ha=function(){}}function ia(a){var b=0;return ja(function(){return ba?-b:b}});ka("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); -var la=Math.pow(2,36),sa=-Math.pow(2,35),q={Xb:0,ob:1,Zb:2,$b:3,ac:4,bc:5,cc:6,dc:7,Za:8,ec:9,pb:10,fc:11,gc:12,qb:13,hc:14,ic:15,jc:16,kc:17,lc:18,mc:19,nc:20,oc:21,pc:22,qc:23,rc:24,sc:25,tc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,Wb:66,Yb:67,uc:68,E:69,vc:70,wc:71,xc:72,yc:73,zc:74,Ac:75,Bc:76,Cc:77,Dc:78,Ec:79,Fc:80,Q:81, +var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var ea=0;function da(a){return"jscomp_symbol_"+(a||"")+ea++} +function fa(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ja(this)}});fa=function(){}}function ja(a){var b=0;return ka(function(){return ba?-b:b}});la("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var ma=Math.pow(2,36),na=-Math.pow(2,35),q={Xb:0,ob:1,Zb:2,$b:3,ac:4,bc:5,cc:6,dc:7,Za:8,ec:9,pb:10,fc:11,gc:12,qb:13,hc:14,ic:15,jc:16,kc:17,lc:18,mc:19,nc:20,oc:21,pc:22,qc:23,rc:24,sc:25,tc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,Wb:66,Yb:67,uc:68,E:69,vc:70,wc:71,xc:72,yc:73,zc:74,Ac:75,Bc:76,Cc:77,Dc:78,Ec:79,Fc:80,Q:81, Gc:82,Hc:83,Ic:84,Jc:85,Kc:86,Lc:87,Mc:88,Nc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Oc:97,Pc:98,Qc:99,d:100,e:101,Rc:102,Sc:103,Tc:104,Uc:105,Vc:106,k:107,Wc:108,Xc:109,n:110,Yc:111,p:112,q:113,r:114,Zc:115,t:116,ad:117,bd:118,cd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; -function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ta:!1,V:!1,error:!1};this.La=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.la=null;u.push(this)}function ta(a,b,c){ua[a]&&b&&(ua[a][b]=c)}function va(){return Date.now()||+new Date} -function v(a){window&&window.alert(a)}function wa(a){var b=!1;window&&(b=window.confirm(a));return b}function w(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?this.Ja=this.id:(this.Ka=this.id.substr(0,a),this.Ja=this.id.substr(a+1));this.j={ready:!1,Ea:!1,Ta:!1,V:!1,error:!1};this.La=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.ma=null;u.push(this)}function oa(a,b,c){va[a]&&b&&(va[a][b]=c)}function wa(){return Date.now()||+new Date} +function v(a){window&&window.alert(a)}function xa(a){var b=!1;window&&(b=window.confirm(a));return b}function w(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1>=3;return(c?"0o":"")+d} -function F(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Ra(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Wa[a]})}function Xa(a,b){return(a+" ").slice(0,b)}function Ya(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Wa={"&":"&","<":"<",">":">",'"':""","'":"'"};function Za(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} -function H(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +function Ua(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1>=3;return(c?"0o":"")+d} +function E(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function Wa(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return ab[a]})}function bb(a,b){return(a+" ").slice(0,b)}function cb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var ab={"&":"&","<":"<",">":">",'"':""","'":"'"};function db(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function ob(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} -function ib(a,b){var c,d={Y:null,U:null,ka:null,ja:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ka=f.load;d.ja=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.la=f.load;d.ka=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;c>8&255,d.Y[g++]=e[c]>>16&255,d.Y[g++]=e[c]>>24&255;else(e=f.data)?d.za=e:d.Y=f;d.Y&&(d.Y.length?1==d.Y.length&&(v(d.Y[0]),d=null):(v("Empty resource: "+a),d=null));d.U=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Rb,reset:this.Nb, -set:this.Qb};E(this)}p(Ob,t);l=Ob.prototype;l.reset=function(a){this.stop();a&&Qb(this,this.v=0)}; -l.fa=function(a,b,c,d){if(this.C&&this.C.fa(a,b,c,d)||this.g&&this.g.fa(a,b,c,d)||this.A&&this.A.fa(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Rb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Sb(a,b)}}(this,b),a.ontouchstart= -function(a,b){return function(c){Rb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Sb(a,b)}}(this,b),!0):t.prototype.fa.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Tb(this);Ub(this)};l.na=function(a,b){if(!b)if(this.T&&Vb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.ea=function(a){return a?this.save():!0};l.save=function(){var a=new L(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; -l.restore=function(a){if(a=a[0])Wb(this,this.i=a[0]),Qb(this,this.v=a[1]),Xb(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Ub(this);return!0};function Yb(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Tb(a,b){for(var c in a.B)Yb(a,c,null!=b?b:a.B[c])}function Zb(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Ub(a){for(var b in a.b)Zb(a,b,a.b[b][1])} -l.yb=function(a,b,c){if(Rb(this,b)){if(c){var d=this;setTimeout(function(){Sb(d,b);a&&a()},+c);return!1}Sb(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return Xb(this,Pa(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,Zb(this,a,c[1]),!0):!1};l.Rb=function(a){return Rb(this,a)?(Sb(this,a),!0):!1};function Rb(a,b){var c=a.b[b];return c?(Zb(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=$b&&(a.O=b==ac,a.R=b==bc),!0):!1} -function Sb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(Zb(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Cb,this.b[cc]&&this.b[cc][1]&&dc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.W()}; -l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[cc]&&this.b[cc][1])dc(this.g);else{if((a=this.A)&&!La(a,!0))Ma(a,!0),ec(a,0,null),Ma(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ga+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ga){m=h.size-(e-k);m>g&&(m=g);h.Ga=e-h.w+m;e=k+16384;g-=m;f++;continue}}return qc(rc,e,g)}e=new mc(a,e,m,16384,d);nc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+sc[d]+" at "+Qa(b)),!0):qc(tc,b,c)} -function kc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.G(b&16383,b);a.v--;return b}function jc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function oc(a){for(var b=0,c=[],d=0;d=a.ga&&(a.ga+=a.ca,c=!0);0<=a.ha&&a.ha<=dd(a)&&(a.ca=a.ha=-1,$c(a),a.W(),c=!0);c&&a.f(dd(a)+" cycles: checksum="+F(a.sa))}} -l.fa=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.V)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.R/a.S?b=1:d=!0;a.T=b;b=a.Pa*a.T;if(a.S!=b){a.S=b;b=a.S.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&hd(a.C)}gc(a,a.F);a.F=0;a.B=va();a.J=0;fd(a);return d}function id(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function jd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function kd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} -l.Ob=function(){if(this.j.K){this.xa>=this.Ra&&fd(this,!0);this.ia=0;this.ra=va();if(this.J){var a=this.ra-this.J;a>this.Qa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=id(this,this.j.Da?1:this.ua);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=kd(this,!0);this.ia+=b;this.F+=b;hc(this,b);fc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Sa>=ld&&(this.C&&M(this.C,void 0),this.Sa=0);break}}while(this.j.K)}catch(e){this.W();this.C&&this.C.stop(va(),dd(this));Ia(this, -e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=va();var c=this.Qa;this.ia&&(c=Math.round(c*this.ia/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.R=Math.round(this.F/(10*d))/100,864E5<=d&&(this.N=0,ed(this)));if(0>c||this.Rc&&(this.B-=c),c=0;this.xa+=this.ia;this.J+=c;a(b,c)}}}; -function dc(a,b){if(!Ja(a))if(a.j.K)a.f(a.toString()+" busy");else{ed(a);a.j.K=!0;a.j.Oa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&hd(a.C,!0),a.C.start(a.B,dd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ia=function(){return 0};l.W=function(a){var b=!1;if(this.j.K){kd(this);gc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(va(),dd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var gd=30,ld=15,Xc=["power","reset"]; -function md(a){var b=+a.model||1001;Wc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=nd.bind(this);this.b=P.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(md,Wc);l=md.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.W();this.i=this.O=this.ya=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Kb;this.P=this.Vb;this.oa=null;Zc(this);this.j.error=!1;Wc.prototype.reset.call(this)};l.lb=function(){return 0}; -l.save=function(){var a=new L(this);a.set(0,[this.i,this.O,this.ya,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.N,this.T,this.j.Z]);a.set(3,od(this));a.set(4,jd(this));return a.data()}; -l.restore=function(a){var b;b=a[0];ha();ca();ha();var c=b[Symbol.iterator];b=c?c.call(b):ia(b);this.i=b.next().value;this.O=b.next().value;this.ya=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.N=b[0];ed(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Vb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].P(b,a&16383,a)}; -l.Ia=function(a){this.j.complete=!0;var b=this.A?qd(this.A)?1:this.j.Oa?-1:0:0,c=a?this.j.Oa?0:1:-1;this.j.Oa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(rd(this.A,this.u,c)){this.W();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&rd(this.A,this.u,c)){this.W();break}if(0>c)break}}this.v&=15;this.O=this.O&4194304?this.H(this.i):this.ya=this.H(this.qa=this.u);this.i=this.O&262143;if(a=this.O>>18&15)this.i= -this.i+this.H(a)&Db;this.O&4194304?a=-1:(this.u=(this.u+1)%Cb,a=this.ya/Nb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function Q(a){this.b(a)}function td(a){this.b(a)}function ud(a){this.b(a)}function vd(a){var b=a&15,c=this.H(this.i),d=this.H(b),d=wd(a,d,c)+(c-(c&262143));this.P(b,d)} -function xd(a){var b=a&15,c=this.H(b),c=wd(a,c,0);this.P(b,c)}function yd(a){var b=this.H(a&15),c=this.H(this.i),c=wd(a,c,b)+(b-(b&262143));this.P(this.i,c)}function zd(a){var b=this.H(this.i);this.P(this.i,wd(a,b,b));var c=a&15;c&&(b=this.H(c),this.P(c,wd(a,b,b)))}function Ad(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a);this.P(a,c-(c&262143)+b)}function W(a){this.b(a)}function P(a){this.f("undefined opcode: "+Qa(a));pd(this,-1);this.W()} -function wd(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Fb?262143:0}return b} -var sd=[Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function Za(){return"http://"+(window?window.location.host:"www.pcjs.org")}function qb(){if(null==rb){var a=!1;if(window)try{window.localStorage.setItem("PCjs.localStorage","PCjs.localStorage"),a="PCjs.localStorage"==window.localStorage.getItem("PCjs.localStorage"),window.localStorage.removeItem("PCjs.localStorage")}catch(b){a=!1}rb=a}return rb}function sb(a){var b;if(window)try{b=window.localStorage.getItem(a)}catch(c){}return b} +function tb(a,b){try{return window.localStorage.setItem(a,b),!0}catch(c){}return!1}function ub(a){if(window){var b=window?window.navigator.userAgent:"";return"iOS"==a&&!!b.match(/(iPod|iPhone|iPad)/)&&!!b.match(/AppleWebKit/)||"MSIE"==a&&!!b.match(/(MSIE|Trident)/)||0<=b.indexOf(a)}return!1} +function vb(a){if(!wb){var b,c={};if(window){b||(b=window.location.search.substr(1));for(var d,e=/\+/g,g=/([^&=]+)=?([^&]*)/g;d=g.exec(b);)c[decodeURIComponent(d[1].replace(e," "))]=decodeURIComponent(d[2].replace(e," "))}wb=c}return wb[a]}function xb(a,b,c){function d(){--a;0<=a&&(b()||(a=0));0a;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Rb,reset:this.Nb, +set:this.Qb};D(this)}p(Wb,t);l=Wb.prototype;l.reset=function(a){this.stop();a&&Yb(this,this.v=0)}; +l.ga=function(a,b,c,d){if(this.C&&this.C.ga(a,b,c,d)||this.g&&this.g.ga(a,b,c,d)||this.A&&this.A.ga(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Zb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){$b(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Zb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){$b(a,b)}}(this,b),!0):t.prototype.ga.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;ac(this);bc(this)};l.na=function(a,b){if(!b)if(this.T&&cc(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.fa=function(a){return a?this.save():!0};l.save=function(){var a=new J(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])dc(this,this.i=a[0]),Yb(this,this.v=a[1]),ec(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}bc(this);return!0};function fc(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function ac(a,b){for(var c in a.B)fc(a,c,null!=b?b:a.B[c])}function gc(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function bc(a){for(var b in a.b)gc(a,b,a.b[b][1])} +l.yb=function(a,b,c){if(Zb(this,b)){if(c){var d=this;setTimeout(function(){$b(d,b);a&&a()},+c);return!1}$b(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return ec(this,Ua(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,gc(this,a,c[1]),!0):!1};l.Rb=function(a){return Zb(this,a)?($b(this,a),!0):!1};function Zb(a,b){var c=a.b[b];return c?(gc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=hc&&(a.O=b==ic,a.R=b==jc),!0):!1} +function $b(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(gc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Jb,this.b[kc]&&this.b[kc][1]&&lc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.W()}; +l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[kc]&&this.b[kc][1])lc(this.g);else{if((a=this.A)&&!Qa(a,!0))Ra(a,!0),mc(a,0,null),Ra(a,!1);else try{var b=this.g.Ia(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ga+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ga){m=h.size-(e-k);m>g&&(m=g);h.Ga=e-h.w+m;e=k+16384;g-=m;f++;continue}}return yc(zc,e,g)}e=new uc(a,e,m,16384,d);vc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Ac[d]+" at "+Va(b)),!0):yc(Bc,b,c)} +function sc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.G(b&16383,b);a.v--;return b}function rc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function wc(a){for(var b=0,c=[],d=0;d=a.ha&&(a.ha+=a.da,c=!0);0<=a.ia&&a.ia<=qd(a)&&(a.da=a.ia=-1,md(a),a.W(),c=!0);c&&a.f(qd(a)+" cycles: checksum="+E(a.sa))}} +l.ga=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.V)a=!0;else{var b=null,c,h=w(a.id);for(c=0;ca.R/a.S?b=1:d=!0;a.T=b;b=a.Pa*a.T;if(a.S!=b){a.S=b;b=a.S.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&ud(a.C)}oc(a,a.F);a.F=0;a.B=wa();a.J=0;sd(a);return d}function vd(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function wd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function xd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} +l.Ob=function(){if(this.j.K){this.xa>=this.Ra&&sd(this,!0);this.ja=0;this.ra=wa();if(this.J){var a=this.ra-this.J;a>this.Qa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=vd(this,this.j.Da?1:this.ua);try{this.Ia(b)}catch(e){if("number"!=typeof e)throw e;}b=xd(this,!0);this.ja+=b;this.F+=b;pc(this,b);nc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Sa>=yd&&(this.C&&K(this.C,void 0),this.Sa=0);break}}while(this.j.K)}catch(e){this.W();this.C&&this.C.stop(wa(),qd(this));Na(this, +e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=wa();var c=this.Qa;this.ja&&(c=Math.round(c*this.ja/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.R=Math.round(this.F/(10*d))/100,864E5<=d&&(this.N=0,rd(this)));if(0>c||this.Rc&&(this.B-=c),c=0;this.xa+=this.ja;this.J+=c;a(b,c)}}}; +function lc(a,b){if(!Oa(a))if(a.j.K)a.f(a.toString()+" busy");else{rd(a);a.j.K=!0;a.j.Oa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&ud(a.C,!0),a.C.start(a.B,qd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ia=function(){return 0};l.W=function(a){var b=!1;if(this.j.K){xd(this);oc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(wa(),qd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var td=30,yd=15,jd=["power","reset"]; +function zd(a){var b=+a.model||1001;id.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=Ad.bind(this);this.b=N.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(zd,id);l=zd.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.W();this.i=this.O=this.ya=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Kb;this.P=this.Vb;this.oa=null;ld(this);this.j.error=!1;id.prototype.reset.call(this)};l.lb=function(){return 0}; +l.save=function(){var a=new J(this);a.set(0,[this.i,this.O,this.ya,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.N,this.T,this.j.Z]);a.set(3,Bd(this));a.set(4,wd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];fa();ca();fa();var c=b[Symbol.iterator];b=c?c.call(b):ja(b);this.i=b.next().value;this.O=b.next().value;this.ya=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.N=b[0];rd(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Vb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].P(b,a&16383,a)}; +l.Ia=function(a){this.j.complete=!0;var b=this.A?Dd(this.A)?1:this.j.Oa?-1:0:0,c=a?this.j.Oa?0:1:-1;this.j.Oa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(Ed(this.A,this.u,c)){this.W();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&Ed(this.A,this.u,c)){this.W();break}if(0>c)break}}this.v&=15;this.O=this.O&4194304?this.H(this.i)&8388607:(this.ya=this.H(this.qa=this.u))&8388607;this.i=this.O&262143; +if(a=this.O>>18&15)this.i=this.i+this.H(a)&Kb;this.O&4194304?a=-1:(this.u=(this.u+1)%Jb,a=this.ya/Pb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function O(a){this.b(a)}function Gd(a){this.b(a)}function Hd(a){this.b(a)} +function Id(a){var b=a&15,c=this.H(this.i),d=this.H(b),d=Jd(a,d,c)+(c-(c&262143));this.P(b,d)}function Kd(a){var b=a&15,c=this.H(b),c=Jd(a,c,0);this.P(b,c)}function Ld(a){var b=this.H(a&15),c=this.H(this.i),c=Jd(a,c,b)+(b-(b&262143));this.P(this.i,c)}function Md(a){var b=this.H(this.i);this.P(this.i,Jd(a,b,b));var c=a&15;c&&(b=this.H(c),this.P(c,Jd(a,b,b)))}function Nd(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a);this.P(a,c-(c&262143)+b)}function P(a){this.b(a)} +function N(a){this.f("undefined opcode: "+Va(a));Cd(this,-1);this.W()}function Jd(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Mb?262143:0}return b} +var Fd=[O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,ud,ud,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},td,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},P,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Gd,Hd,Hd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Gd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},N,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},N,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a),c=(c&262143)+b*I;this.P(a,c)},function(a){a&=15;var b=this.H(a),b=(b&262143)+this.i*I;this.P(a,b)},function(a){a= -this.H(a&15)&262143;var b=this.H(this.i),b=(b&262143)+a*I;this.P(this.i,b)},function(a){var b=this.H(this.i)&262143;this.P(this.i,b+b*I);if(a&=15)b=this.H(a)&262143,this.P(a,b+b*I)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},vd,xd,yd,zd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Ad,function(a){a&= -15;var b=this.H(a),b=b-(b&262143)+this.i;this.P(a,b)},function(a){a=this.H(a&15)&262143;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){a&15&&Ad.call(this,a)},function(a){a&=15;var b=this.H(this.i)/I|0,c=this.H(a);this.P(a,c-(c&262143)+b)},function(a){a&=15;var b=this.H(a);this.P(a,b-(b&262143))},function(a){a=this.H(a&15)/I|0;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){var b=this.H(this.i);this.P(this.i,(b&262143)+(b/I|0));if(a&=15)b=this.H(a),this.P(a,(b&262143)+ -(b/I|0))},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Id,Kd,Ld,Md,function(a){a&=15;var b=this.H(this.i)&262143,c=this.H(a),c=(c&262143)+b*F;this.P(a,c)},function(a){a&=15;var b=this.H(a),b=(b&262143)+this.i*F;this.P(a,b)},function(a){a= +this.H(a&15)&262143;var b=this.H(this.i),b=(b&262143)+a*F;this.P(this.i,b)},function(a){var b=this.H(this.i)&262143;this.P(this.i,b+b*F);if(a&=15)b=this.H(a)&262143,this.P(a,b+b*F)},Id,Kd,Ld,Md,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Id,Kd,Ld,Md,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Id,Kd,Ld,Md,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Nd,function(a){a&= +15;var b=this.H(a),b=b-(b&262143)+this.i;this.P(a,b)},function(a){a=this.H(a&15)&262143;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){a&15&&Nd.call(this,a)},function(a){a&=15;var b=this.H(this.i)/F|0,c=this.H(a);this.P(a,c-(c&262143)+b)},function(a){a&=15;var b=this.H(a);this.P(a,b-(b&262143))},function(a){a=this.H(a&15)/F|0;var b=this.H(this.i);this.P(this.i,b-(b&262143)+a)},function(a){var b=this.H(this.i);this.P(this.i,(b&262143)+(b/F|0));if(a&=15)b=this.H(a),this.P(a,(b&262143)+ +(b/F|0))},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, -W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W]; -function Bd(a){t.call(this,"ROM",a,128);this.U=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Ra(this.v);if(this.v){a=this.v;var b=Sa(this.F);"json"!=b&&"hex"!=b&&(a=Ua()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,g){g?(c.ba("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(ta(c.Ka,a,b),(a=ib(a,b))?(c.b=a.Y,c.U=a.U):c.v=null);Cd(c)})}}p(Bd,t); -Bd.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;Cd(this)};Bd.prototype.na=function(){this.U&&(this.A&&Dd(this.A,this.id,this.B,this.u,this.U),delete this.U);return!0};Bd.prototype.ea=function(){return!0}; -function Cd(a){if(!Ka(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ia(a,"ROM size ("+F(a.b.length,8,!0)+") does not match specified size ("+F(a.u,8,!0)+")");else{var b;b=a.B;if(pc(a.D,b,a.u,Nc)){var c;for(c=0;c>>g.i;0>>= -g.i;0>>a.i;0f&&f>=sa&&(f+=la);f=Math.trunc(Math.abs(f))%la;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Ma(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Ma(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); -a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Ma(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;E(this)}; -l.nb=function(a){if(!this.b){var b=Yc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ya(c[0]);if(d!=this.Ja)return;c=Ya(c[1]);if(this.b=xa(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; -l.ea=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new L(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Ma=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.R?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(Ya(b.substring(c,g))),c=g+1}}return a} -function Ld(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P]; +function Od(a){t.call(this,"ROM",a,128);this.U=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Wa(this.v);if(this.v){a=this.v;var b=Xa(this.F);"json"!=b&&"hex"!=b&&(a=Za()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;ob(a,null,!0,function(a,b,g){g?(c.ca("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(oa(c.Ka,a,b),(a=pb(a,b))?(c.b=a.Y,c.U=a.U):c.v=null);Pd(c)})}}p(Od,t); +Od.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;Pd(this)};Od.prototype.na=function(){this.U&&(this.A&&Qd(this.A,this.id,this.B,this.u,this.U),delete this.U);return!0};Od.prototype.fa=function(){return!0}; +function Pd(a){if(!Pa(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Na(a,"ROM size ("+E(a.b.length,8,!0)+") does not match specified size ("+E(a.u,8,!0)+")");else{var b;b=a.B;if(xc(a.D,b,a.u,Fc)){var c;for(c=0;c>>g.i;0>>= +g.i;0>>a.i;0f&&f>=na&&(f+=ma);f=Math.trunc(Math.abs(f))%ma;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Ma(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Ma(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Ma(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;D(this)}; +l.nb=function(a){if(!this.b){var b=kd(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=cb(c[0]);if(d!=this.Ja)return;c=cb(c[1]);if(this.b=ya(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.fa=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new J(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Ma=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.R?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(cb(b.substring(c,g))),c=g+1}}return a} +function Yd(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Md(a,b,c){var d;if(b){b=Nd(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,R--;f=r+f;d>>=8}d=F(c,0,!0)+" "+c+". "+Qa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} -function Rd(a,b){if(b)return Qd(a,b,a.aa[b]);var c=0;for(b in a.aa)Qd(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} -var Pd={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Sd(a){Jd.call(this,a);this.wa=!1;this.oa=!0;this.J=X();this.ua=X();this.O=X();this.F=[];this.b=this.L=this.I=[];Td(this);this.S=this.ia=0;this.i=[];this.ra=void 0;Ud(this);this.A=this;this.pa={};this.X=this.ib=0;this.T=null;this.N=[];Vd(this,a.messages);this.ta=a.commands;this.M=0;this.Ca=this.sa=null;this.B=this.ya=this.xa=this.ha=this.qa=0;this.ga=this.ca=null;var b=this;window?void 0===window[C]&&(window[C]=function(a){return cd(b,a)}):void 0===global[C]&&(global[C]=function(a){return cd(b, -a)})}p(Sd,Jd);function Y(a){a=a&&a.w;null==a&&(a=-1);return a}function X(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ma:!1,da:c}}function Wd(a){return[a.w,a.wb,a.da,a.ma,a.Na]}function Xd(a,b){var c=X(b[0],b[1],b[2]);c.ma=b[3];b[4]&&(c.gb=Kd(a,c.Na=b[4]));return c}l=Sd.prototype; -l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ga=a.u;(a=Yc(a,"messages"))&&Vd(this,a);Yd(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=Y(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=sc[c],n&&d.f(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=pd(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(c=a.i[a.S],c.w=b,c.ma=!1,c.da=void 0,++a.S==a.i.length&&(a.S=0)));return!1} -function Ne(a,b,c,d){var e=X(b.w),g=a.Ba(b,1),f,h,k,m=0,n=g/Gb|0,r;for(r in Oe)if(f=Oe[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=Pe;m=n&3;break;case 32256:k=Qe;m=n&7;break;case 29248:k=Re,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Se&&(k="B");k=Te[f||0]+k;k=Xa(k,8);f?(k=28700==h?k+N(a,g/Hb&127,-1):k+N(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=N(a,g&262143,-1),(g=g>>18&15)&&(k+="("+N(a,g,-1)+")")):k+=$d(g);g=k;f="";h=N(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.Ba(e,1),f+=" "+$d(k),null== -e.w)break;while(e.w!=b.w)}h+=Xa(f,16)+g;c&&(h=Xa(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+dd(a.g).toString()+" cs="+F(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function Td(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.I)for(b=1;b>>d.i],!0);a.I=["bw"];a.qa=0;a.ia=0} -l.Aa=function(a,b,c){var d=!0;c||Ue(this,a,b,!1,!0);if(a!=this.b){var e=Y(b);if(-1===e)this.f("invalid address: "+N(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Aa(e&16383,a==this.I)}}d&&(a.push(b),c?b.ma=!0:(Ve(this,a,a.length-1,"set"),Ud(this)));return d};function Ue(a,b,c,d,e){var g=!1;c=Y(c);for(var f=1;f>>d.i],b==a.I));h.ma||Ud(a);break}}return g} -function We(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=Za(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.F.push({$c:b,w:c,zb:d,U:e,hb:g})} -function Ze(a,b,c){var d=[],e=Y(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Ne(a,b,f,g);a.f(g);a.J=b;e-=b.w-k;c++}}} -function Xe(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Je+b):(a.R&&(a.f("ended assemble at "+N(a,a.O.w)),a.J=a.O,a.R=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.T=null;if(Ka(a)&&0n||"z"T.length&&(a.f("note: only "+T.length+" available"),K=T.length);O-=K;0>O&&(null==T[T.length-1].w?(K=O+K,O=0):O+=T.length);var Ac=[];"call"==ke&&($a=1E5,Ac=["CALL"]);for(void 0!==je&&a.f(K+" instructions earlier:");0<$a&&O!=a.S;){var ne=T[O++];if(null==ne.w)break;var ab=X(ne.w),Jf=K--,oe=Ne(a,ab,"history",Jf);(!Ac.length||0<=oe.indexOf(Ac[0]))&&a.f(oe);ab.Ua&&(O+=ab.Ua,$a-=ab.Ua,K-=ab.Ua);O>=T.length&&(O=0);a.ra=K;me++;$a--}}me||(a.f("no "+le+"history available"), -a.ra=void 0)}else{var na=Z(a,S);if(na){var oa=0,pe="ds"==Fa;if(da){if("l"==da.charAt(0))da=da.substr(1)||If,oa=Od(a,da);else{var qe=Z(a,da);qe&&(oa=qe.w-na.w)}0>oa&&(oa=0);65536ue;ue++)se+=String.fromCharCode((Ib%64|0)+32), -Ib/=64}pa&&(pa+="\n");pa=pe?pa+(qa+","):pa+(S+": "+qa+(0>te?" "+se:""))}pa&&a.f(pa);a.ua=na;a.da=Kf}}}}break;case "e":if("else"==f[0])break;var ve,we,xe=f[0],Dc=f[1];"e"==xe||"ew"==xe?(ve=a.Ba,we=a.$a):Dc=null;if(null==Dc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Jb=Z(a,Dc);if(Jb)for(var Kb=2;KbHc;){for(var ra=null,Of=256;65536>cb.w>>>0;){Ic.w=a.Ba(cb,2);if(null==cb.w||!Of--)break;if(!(Ic.w&1)){for(var Pf=a,Lb=Ic,ze=null,db=Lb.w,Ae=db,Jc=1;6>=Jc&&db;Jc++){if(2> ";tb(function(){for(var a=D(document,C,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;blf){if(mf(d,this.L)){this.B=new L(this,"1.34.0",vf);mf(this.B)&&(wf(this,d),a=xf,yf(this.B));this.B.set(sf,hb());zf(this.B);var e=this.b&&!this.J;if(a==tf||wa("Click OK to restore the previous "+Bb+" machine state, or CANCEL to reset the machine.")){if(c=rf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?mf(d,f):("error"==g&&"no machine state"!= -f?(this.ba("Error: "+f),"unable to verify user"==f&&(mb(Af,""),this.i=null)):this.f(g+": "+f),yf(d),mf(d)?(c=rf(d),e=!0):c=!1))}e&&pf(this,c?d:null)}else a==xf&&d.clear()}else pf(this);delete this.L;delete this.I}e=w(this.id);for(g=0;ga[1];a=a[2];this.S=!0;this.j.V=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(Bf(this,this.g,b,c,a),M(this,-2),this.g.Z());this.O&&(wf(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; -function wf(a,b){if(wa("There may be a problem with your "+Bb+" machine.\n\nTo help us diagnose it, click OK to send this "+Bb+" machine state to http://www.pcjs.org.")){var c=a.ca;a=a.i||"";b=b.toString();var d={};d.app=Bb;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} -function ef(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new L(a,"1.34.0"),f=new L(a,"1.34.0",qf),h=hb();f.set(sf,h);g.set(sf,h);g.set(Cf,"1.34.0");g.set(Df,window?window.location.href:null);g.set(Ef,window?window.navigator.userAgent:"");a.g&&a.g.ea&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.W()),d=a.g.ea(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.V=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Ca+=d))&&(e.textContent=c.j.K?c.R.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.da||8,e=e||0,e=8==g?Qa(e,void 0):F(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],f);$f(a,b,c)}})}else c(a,null)} -function ag(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&D(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Va(a))}function f(a){g("Error: "+a);m&&(--Xf||xb(!0));m=!1}var h,k,m=!0;Xf++;ua[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| -(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?Yf(d,null,a,null,!1,g,function(a,e){e?(ta(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Xf||xb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Xf|| -xb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Yf(c,b,a,e,!0,g,n):Zf(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(R){f(R.message)}return m}window.embedPDP10=function(a,b,c,d){xb(!1);return ag("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){xb(!1);return ag("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return y(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,U--;f=r+f;d>>=8}d=E(c,0,!0)+" "+c+". "+Va(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function ce(a,b){if(b)return be(a,b,a.aa[b]);var c=0;for(b in a.aa)be(a,b,a.aa[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c} +var ae={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function de(a){Wd.call(this,a);this.wa=!1;this.oa=!0;this.J=S();this.ua=S();this.O=S();this.F=[];this.b=this.L=this.I=[];ee(this);this.S=this.ja=0;this.i=[];this.ra=void 0;fe(this);this.A=this;this.pa={};this.X=this.ib=0;this.T=null;this.N=[];ge(this,a.messages);this.ta=a.commands;this.M=0;this.Ca=this.sa=null;this.B=this.ya=this.xa=this.ia=this.qa=0;this.ha=this.da=null;var b=this;window?void 0===window[B]&&(window[B]=function(a){return pd(b,a)}):void 0===global[B]&&(global[B]=function(a){return pd(b, +a)})}p(de,Wd);function T(a){a=a&&a.w;null==a&&(a=-1);return a}function S(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ea:!1,ba:c}}function he(a,b){a.w=b.w;a.ea=b.ea;a.ba=b.ba}function ie(a,b){a.w=b;a.ea=!1;a.ba=void 0}function je(a){return[a.w,a.wb,a.ba,a.ea,a.Na]}function ke(a,b){var c=S(b[0],b[1],b[2]);c.ea=b[3];b[4]&&(c.gb=Xd(a,c.Na=b[4]));return c}l=de.prototype; +l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ha=a.u;(a=kd(a,"messages"))&&ge(this,a);le(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=T(Z(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Ac[c],n&&d.f(E(n.id,8)+" %"+E(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=Cd(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(ie(a.i[a.S],b),++a.S==a.i.length&&(a.S=0)));return!1} +function ef(a,b,c,d){var e=S(b.w),g=a.Ba(b,1),f,h,k,m=0,n=g/Nb|0,r;for(r in ff)if(f=ff[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=gf;m=n&3;break;case 32256:k=hf;m=n&7;break;case 29248:k=jf,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>kf&&(k="B");k=lf[f||0]+k;k=bb(k,8);f?(k=28700==h?k+L(a,g/Ob&127,-1):k+L(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=L(a,g&262143,-1),(g=g>>18&15)&&(k+="("+L(a,g,-1)+")")):k+=ne(g);g=k;f="";h=L(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.Ba(e,1),f+=" "+ne(k),null== +e.w)break;while(e.w!=b.w)}h+=bb(f,16)+g;c&&(h=bb(h,60)+";"+(c||""),h=a.g.j.Da?h+("cycles="+qd(a.g).toString()+" cs="+E(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function ee(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.I)for(b=1;b>>d.i],!0);a.I=["bw"];a.qa=0;a.ja=0} +l.Aa=function(a,b,c){var d=!0;c||mf(this,a,b,!1,!0);if(a!=this.b){var e=T(b);if(-1===e)this.f("invalid address: "+L(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Aa(e&16383,a==this.I)}}d&&(a.push(b),c?b.ea=!0:(nf(this,a,a.length-1,"set"),fe(this)));return d};function mf(a,b,c,d,e){var g=!1;c=T(c);for(var f=1;f>>d.i],b==a.I));h.ea||fe(a);break}}return g} +function of(a,b){for(var c=1;cb[0]?1:a[0]>>0,f],r=db(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.F.push({$c:b,w:c,zb:d,U:e,hb:g})} +function rf(a,b,c){var d=[],e=T(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=ef(a,b,f,g);a.f(g);he(a.J,b);e-=b.w-k;c++}}} +function pf(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(ve+b):(a.R&&(a.f("ended assemble at "+L(a,a.O.w)),he(a.J,a.O),a.R=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.T=null;if(Pa(a)&&0n||"z"kf&&(Lc="B");if(Yf==lf[Be]+Lc){Ae=29248!=Ic?Ha:(Ha&3)<<1|(Ha&12)<<2;A=(Kc|Ae<<6)*Nb;break}}if(0<= +A)break}if(0<=A)break}if(0<=A)if(ye)for(var Mc=ye.split(","),eb=0;ebH||15H||262143H||15W.length&&(a.f("note: only "+W.length+" available"),M=W.length);Q-=M;0>Q&&(null==W[W.length-1].w?(M=Q+M,Q=0):Q+=W.length);var Rc=[];"call"==He&&(gb=1E5,Rc=["CALL"]);for(void 0!==Ge&&a.f(M+" instructions earlier:");0=W.length&&(Q=0);a.ra=M;Je++;gb--}}Je||(a.f("no "+Ie+"history available"), +a.ra=void 0)}else{var qa=Z(a,V);if(qa){var ra=0,Me="ds"==Ka;if(ha){if("l"==ha.charAt(0))ha=ha.substr(1)||ag,ra=$d(a,ha);else{var Ne=Z(a,ha);Ne&&(ra=Ne.w-qa.w)}0>ra&&(ra=0);65536Re;Re++)Pe+=String.fromCharCode((Rb%64|0)+32), +Rb/=64}sa&&(sa+="\n");sa=Me?sa+(ta+","):sa+(V+": "+ta+(0>Qe?" "+Pe:""))}sa&&a.f(sa);he(a.ua,qa);a.ba=cg}}}}break;case "e":if("else"==f[0])break;var Se,Te,Ue=f[0],Uc=f[1];"e"==Ue||"ew"==Ue?(Se=a.Ba,Te=a.$a):Uc=null;if(null==Uc)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var Sb=Z(a,Uc);if(Sb)for(var Tb=2;TbYc;){for(var ua=null,gg=256;65536>jb.w>>>0;){Zc.w=a.Ba(jb,2);if(null==jb.w||!gg--)break;if(!(Zc.w&1)){for(var hg=a,Ub=Zc,We=null,kb=Ub.w,Xe=kb,$c=1;6>=$c&&kb;$c++){if(2<$c){Ub.w=kb;var Vb=ef(hg,Ub);if(0<=Vb.indexOf("JSR")){var Ye=Vb.indexOf(" ");if(kb+(Vb.indexOf(" ",Ye+1)-Ye-1)/2==Xe){We=Vb;break}}}kb-=2}Ub.w=Xe;if(ua=We)break}}if(!ua||null==ua)break;var Ze=null;if("ks"==fg){var $e=ua.match(/[0-9A-F]+$/);$e&&(Ze=uf(a,$e[0]))}ua= +bb(ua,50)+" ;"+(Ze||"stack="+L(a,jb.w));a.f(ua);Yc++}Yc||a.f("no return addresses found")}break;case "l":if("ln"==f[0]){uf(a,f[1],!0);break}g=!0;break;case "m":a:{var X,Y=null,y=f[1];"?"==y&&(y=void 0);if(void 0!==y){var ia=0;if("all"==y)ia=1879046143,y=null;else if("on"==y)Y=!0,y=null;else if("off"==y)Y=!1,y=null;else{"keys"==y&&(y="key");"kbd"==y&&(y="keyboard");for(X in G)if(y==X){ia=G[X];Y=!!(a.X&ia);break}if(!ia){a.f("unknown message category: "+y);break a}}if(ia)if("on"==f[2])a.X|=ia,Y=!0; +else if("off"==f[2]&&(a.X&=~ia,Y=!1,1073741824==ia)){for(var af=1E3<=a.N.length?a.N.length-1E3:0;af> ";Ab(function(){for(var a=C(document,B,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bDf){if(Ef(d,this.L)){this.B=new J(this,"1.34.0",Nf);Ef(this.B)&&(Of(this,d),a=Pf,Qf(this.B));this.B.set(Kf,fb());Rf(this.B);var e=this.b&&!this.J;if(a==Lf||xa("Click OK to restore the previous "+Ib+" machine state, or CANCEL to reset the machine.")){if(c=Jf(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Ef(d,f):("error"==g&&"no machine state"!= +f?(this.ca("Error: "+f),"unable to verify user"==f&&(tb(Sf,""),this.i=null)):this.f(g+": "+f),Qf(d),Ef(d)?(c=Jf(d),e=!0):c=!1))}e&&Hf(this,c?d:null)}else a==Pf&&d.clear()}else Hf(this);delete this.L;delete this.I}e=w(this.id);for(g=0;ga[1];a=a[2];this.S=!0;this.j.V=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(Tf(this,this.g,b,c,a),K(this,-2),this.g.Z());this.O&&(Of(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; +function Of(a,b){if(xa("There may be a problem with your "+Ib+" machine.\n\nTo help us diagnose it, click OK to send this "+Ib+" machine state to http://www.pcjs.org.")){var c=a.da;a=a.i||"";b=b.toString();var d={};d.app=Ib;d.ver="1.34.0";d.url=c;d.user=a;d.type="bug";d.data=b;ob("http://www.pcjs.org/api/v1/report",d,!0)}} +function xf(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new J(a,"1.34.0"),f=new J(a,"1.34.0",If),h=fb();f.set(Kf,h);g.set(Kf,h);g.set(Uf,"1.34.0");g.set(Vf,window?window.location.href:null);g.set(Wf,window?window.navigator.userAgent:"");a.g&&a.g.fa&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.W()),d=a.g.fa(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.V=!1,!1===d&&(e=null)));for(var h=w(a.id),k=0;k=d||30<=(c.Ca+=d))&&(e.textContent=c.j.K?c.R.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Va(e,void 0):E(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");ob(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);sg(a,b,c)}})}else c(a,null)} +function tg(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&C(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=$a(a))}function f(a){g("Error: "+a);m&&(--pg||Eb(!0));m=!1}var h,k,m=!0;pg++;va[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=n:x.appendChild(document.createTextNode(n));r.appendChild(x)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.0/components.xsl");n=function(e,k){k?qg(d,null,a,null,!1,g,function(a,e){e?(oa(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--pg||Eb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--pg|| +Eb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?qg(c,b,a,e,!0,g,n):rg(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(U){f(U.message)}return m}window.embedPDP10=function(a,b,c,d){Eb(!1);return tg("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){Eb(!1);return tg("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return za(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Ca[a]){for(var c=!0,d=Ca,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;n>>b.c].m(a&16383,a)};k.wb=function(a,b){var c=this.l;a=this.ia=a;c.a[(a&c.g)>>>c.c].v(b,a&16383,a)}; -k.wa=function(a){this.b.complete=!0;var b=a?this.b.Ga?0:1:-1;this.b.Ga=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ha||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.u.h(this.h,b)){R(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.m(this.c):this.qa=this.m(this.ya=this.h);this.c=this.M&262143;if(a=this.M>>18&15)this.c=this.c+this.m(a)&Ta;this.M&4194304?a=-1:(this.h=(this.h+1)%Sa,a=this.qa/Wa|0);0<=a&&this.Wa(a)}while(0>4].call(this,a)}function W(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){this.a(a)}function Yb(a){var b=a&15,c=this.m(this.c),d=this.m(b),d=Zb(a,d,c)+(c-(c&262143));this.v(b,d)}function $b(a){var b=a&15,c=this.m(b),c=Zb(a,c,0);this.v(b,c)} +k.wa=function(a){this.b.complete=!0;var b=a?this.b.Ga?0:1:-1;this.b.Ga=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ha||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.u.h(this.h,b)){R(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.m(this.c)&8388607:(this.qa=this.m(this.ya=this.h))&8388607;this.c=this.M&262143;if(a=this.M>>18&15)this.c=this.c+this.m(a)&Ta;this.M&4194304?a=-1:(this.h=(this.h+1)%Sa,a=this.qa/Wa|0);0<=a&&this.Wa(a)}while(0< +this.G);return this.b.complete?this.D-this.G:!1===this.b.complete?-1:0};I(function(){for(var a=D(document,C,"cpu"),b=0;b>4].call(this,a)}function W(a){this.a(a)}function Wb(a){this.a(a)}function Xb(a){this.a(a)}function Yb(a){var b=a&15,c=this.m(this.c),d=this.m(b),d=Zb(a,d,c)+(c-(c&262143));this.v(b,d)}function $b(a){var b=a&15,c=this.m(b),c=Zb(a,c,0);this.v(b,c)} function ac(a){var b=this.m(a&15),c=this.m(this.c),c=Zb(a,c,b)+(b-(b&262143));this.v(this.c,c)}function bc(a){var b=this.m(this.c);this.v(this.c,Zb(a,b,b));var c=a&15;c&&(b=this.m(c),this.v(c,Zb(a,b,b)))}function cc(a){a&=15;var b=this.m(this.c)&262143,c=this.m(a);this.v(a,c-(c&262143)+b)}function X(a){this.a(a)}function V(a){this.K("undefined opcode: "+wa(a));this.h=(this.h+-1)%Sa;R(this)} function Zb(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Va?262143:0}return b} var Vb=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,V,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, From caa5fd6c86d9a19c027ddfba94ba216331f7e133 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Mon, 27 Feb 2017 18:20:34 -0800 Subject: [PATCH 22/30] Tighten up disassembler output --- modules/pdp10/lib/debugger.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/pdp10/lib/debugger.js b/modules/pdp10/lib/debugger.js index 12eccc19d..5658f19b6 100644 --- a/modules/pdp10/lib/debugger.js +++ b/modules/pdp10/lib/debugger.js @@ -1486,7 +1486,7 @@ class DebuggerPDP10 extends Debugger { sLine += Str.pad(sOpCodes, 16) + sOperation; if (sComment) { - sLine = Str.pad(sLine, 60) + ';' + (sComment || ""); + sLine = Str.pad(sLine, 48) + ';' + (sComment || ""); if (!this.cpu.flags.checksum) { sLine += (nSequence != null? '=' + nSequence.toString() : ""); } else { From c4f7262e71e5c476e81ffefd13d545534c943368 Mon Sep 17 00:00:00 2001 From: Jeff Parsons Date: Mon, 27 Feb 2017 19:18:19 -0800 Subject: [PATCH 23/30] Cleaned up the integer base conversion code, and expanded the PDP-10 register dump --- docs/pcx86/examples/pcx86-dbg.js | 1580 +++++++++++++------------- docs/pcx86/examples/pcx86.js | 1164 +++++++++---------- modules/pdp10/lib/debugger.js | 26 +- modules/shared/lib/strlib.js | 145 +-- versions/pc8080/1.34.0/pc8080-dbg.js | 494 ++++---- versions/pc8080/1.34.0/pc8080.js | 326 +++--- versions/pcx86/1.34.0/pcx86-dbg.js | 1580 +++++++++++++------------- versions/pdpjs/1.34.0/pdp10-dbg.js | 328 +++--- versions/pdpjs/1.34.0/pdp10.js | 190 ++-- versions/pdpjs/1.34.0/pdp11-dbg.js | 632 +++++------ versions/pdpjs/1.34.0/pdp11.js | 458 ++++---- 11 files changed, 3457 insertions(+), 3466 deletions(-) diff --git a/docs/pcx86/examples/pcx86-dbg.js b/docs/pcx86/examples/pcx86-dbg.js index 2396aa0ea..4f0ddb362 100644 --- a/docs/pcx86/examples/pcx86-dbg.js +++ b/docs/pcx86/examples/pcx86-dbg.js @@ -44,42 +44,44 @@ http://pcjs.org/modules/shared/lib/save.js (C) Jeff Parsons 2012-2017 */ var l,aa;function ba(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]} -var da={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[40,2,9,,253],737280:[80,2,9,,249],1228800:[80,2,15,,249],1474560:[80,2,18,,240],2949120:[80,2,36,,240],21368320:[615,4,17],256256:[77,1,26,128],2494464:[203,2,12,512],5242880:[256,2,40,256],10485760:[512,2,40,256]},n={lp:0,np:1,op:2,hl:3,pp:4,qp:5,rp:6,sp:7,tp:8,up:9,vp:10,wp:11,xp:12,yp:13,zp:14,Ap:15,Bp:16,Cp:17,Dp:18,Ep:19,Fp:20,Gp:21,Hp:22,Ip:23,Jp:24,Kp:25,Lp:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39, +for(var da="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ea="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this,fa=["Math","trunc"],ga=0;gaa?-b:b};ka!=ja&&null!=ka&&da(ea,ia,{configurable:!0,writable:!0,value:ka}); +var la={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[40,2,9,,253],737280:[80,2,9,,249],1228800:[80,2,15,,249],1474560:[80,2,18,,240],2949120:[80,2,36,,240],21368320:[615,4,17],256256:[77,1,26,128],2494464:[203,2,12,512],5242880:[256,2,40,256],10485760:[512,2,40,256]},n={lp:0,np:1,op:2,hl:3,pp:4,qp:5,rp:6,sp:7,tp:8,up:9,vp:10,wp:11,xp:12,yp:13,zp:14,Ap:15,Bp:16,Cp:17,Dp:18,Ep:19,Fp:20,Gp:21,Hp:22,Ip:23,Jp:24,Kp:25,Lp:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39, "(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,ce:65,ti:66,ui:67,vi:68,E:69,wi:70,xi:71,yi:72,zi:73,Ai:74,Bi:75,Ci:76,Di:77,Ei:78,Fi:79,Gi:80,Q:81,Hi:82,Ii:83,Ji:84,Ki:85,Li:86,Mi:87,Ni:88,Oi:89,eg:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,de:97,vl:98,xl:99,d:100,e:101,Hl:102,Il:103,Jl:104,Kl:105,an:106,k:107,dn:108,hn:109,n:110,qn:111,p:112,q:113,r:114,No:115,t:116,Qo:117,Ro:118,So:119,x:120, -y:121,z:122,"{":123,"|":124,"}":125,"~":126,Mp:127},ea={};ea[173]=n["-"];ea[186]=n[";"];ea[187]=n["="];ea[189]=n["-"];ea[188]=n[","];ea[190]=n["."];ea[191]=n["/"];ea[192]=n["`"];ea[219]=n["["];ea[220]=n["\\"];ea[221]=n["]"];ea[222]=n["'"];var fa={};fa[n["1"]]=n["!"];fa[n["2"]]=n["@"];fa[n["3"]]=n["#"];fa[n["4"]]=n.$;fa[n["5"]]=n["%"];fa[n["6"]]=n["^"];fa[n["7"]]=n["&"];fa[n["8"]]=n["*"];fa[n["9"]]=n["("];fa[n["0"]]=n[")"];fa[186]=n[":"];fa[187]=n["+"];fa[188]=n["<"];fa[189]=n._;fa[190]=n[">"]; -fa[191]=n["?"];fa[192]=n["~"];fa[219]=n["{"];fa[220]=n["|"];fa[221]=n["}"];fa[222]=n['"'];fa[173]=n._;fa[61]=n["+"];fa[59]=n[":"]; -function ga(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0>=1,f--;return d}function ia(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d} -function ja(a,b,c){var d="";b?11a&&-1>=3;return(c?"0o":"")+d}function q(a,b,c){var d="";b?8a&&-1=e?48:55),d=String.fromCharCode(e)+d;a>>=4}return(c?"0x":"")+d}function r(a){return q(a,2,!0)}function ka(a){return q(a,4,!0)} -function la(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return pa[a]})} -function qa(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function ra(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} -var pa={"&":"&","<":"<",">":">",'"':""","'":"'"},sa={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function ta(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function wa(a,b){var c=0,d=1,e;for(e in a){if(d>=arguments.length)break;var f=a[e],g=arguments[d++],c=c&~f.nh|g<>a.shift} -function ya(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;c"]; +na[191]=n["?"];na[192]=n["~"];na[219]=n["{"];na[220]=n["|"];na[221]=n["}"];na[222]=n['"'];na[173]=n._;na[61]=n["+"];na[59]=n[":"]; +function oa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function qa(a,b){var c,d="";b?32>=1,f--;return d} +function ra(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d}function sa(a,b,c){b?12"']/g,function(a){return Aa[a]})} +function Ba(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Aa={"&":"&","<":"<",">":">",'"':""","'":"'"},Da={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function Ea(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function Ga(a,b){var c=0,d=1,e;for(e in a){if(d>=arguments.length)break;var f=a[e],g=arguments[d++],c=c&~f.nh|g<>a.shift} +function Ia(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;ca?this.be=this.id:(this.xe=this.id.substr(0,a),this.be=this.id.substr(a+1));this.ea={ready:!1,pf:!1,$g:!1,Yb:!1,error:!1};this.pg=null;this.ea.error=!1;this.ic=c||0;this.ba=this.H=this.ka=this.pa=this.Ie=null;bb.push(this)} -function eb(a,b,c){gb[a]&&b&&(gb[a][b]=c)}function Wa(a){window&&window.alert(a)}function hb(a){var b=!1;window&&(b=window.confirm(a));return b}function jb(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba?this.be=this.id:(this.xe=this.id.substr(0,a),this.be=this.id.substr(a+1));this.ea={ready:!1,pf:!1,$g:!1,Yb:!1,error:!1};this.pg=null;this.ea.error=!1;this.ic=c||0;this.ba=this.H=this.ka=this.pa=this.Ie=null;ob.push(this)} +function pb(a,b,c){qb[a]&&b&&(qb[a][b]=c)}function hb(a){window&&window.alert(a)}function sb(a){var b=!1;window&&(b=window.confirm(a));return b}function tb(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b=this.x&&a=this.y&&b=c>>2);d?(b=new Lb(a.x,a.y,a.Nc,a.A*b/c|0),a.y+=b.A,a.A-=b.A):(b=new Lb(a.x,a.y,a.Nc*b/c|0,a.A),a.x+=b.Nc,a.Nc-=b.Nc);return b}function Nb(a){ab.call(this,"Panel",a);this.F=this.G=this.L=-1}ba(Nb,ab);l=Nb.prototype;l.Cb=function(a,b,c,d){return this.pa&&this.pa.Cb(a,b,c,d)||this.H&&this.H.Cb(a,b,c,d)||this.B&&this.B.Cb(a,b,c,d)||this.ba&&this.ba.Cb(a,b,c,d)?!0:ab.prototype.Cb.call(this,a,b,c,d)}; -l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.B=Ob(a,"Keyboard")};l.Xb=function(a,b){b||Pb();return!0};l.Wb=function(){return!0};l.Vd=function(a,b){a.button||(this.L=b?0:-1,Qb(this,a,b))};l.tf=function(a){Qb(this,a)}; -function Qb(a,b,c){var d=Rb/null.offsetWidth,e=Sb/null.offsetHeight,f=null.getBoundingClientRect(),d=(b.clientX-f.left)*d|0;b=(b.clientY-f.top)*e|0;null==c&&(a.L||(a.L=Math.abs(a.F-d)>Math.abs(a.G-b)?1:2),1==a.L?b=a.G:2==a.L&&(d=a.F));a.F=d;a.G=b;if(0<=d&&dd&&(f=d);c= -f;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.ga)){b=c;if(a.context&&a.N&&a.O){e=Vb-Wb;f=a.N.width;a.O.fillStyle=Xb;a.O.fillRect(0,e,f,Wb);Yb(a,e+Zb,a.N,a.O);a.W=a.ha.width/24|0;if(null==b)$b(a,"Mouse over memory to dump");else for($b(a,q(b,8,!0),null,0,1),d=1;16>=d;d++){for(var g="",h=1;8>=h;h++){var k;k=a.ka;var m=b++;k=k.aa[(m&k.C)>>>k.A].Zd(m&k.D,m);$b(a,q(k,2),null,1);g+=32<=k&&128>k?String.fromCharCode(k):"."}$b(a,g,null,0,1)}a.context.drawImage(a.N,0,e,f,Wb,a.Da,a.Ha,a.va,a.za)}a.ga=c}}} -function ac(a,b,c,d){a.A.kf[a.A.$i++]={Ll:b,Hd:c,type:d};return wa(Ub,b,c,0,d)}function Yb(a,b,c,d){var e,f=null.style.color,g=a.ta=10;a.C=g;a.I=b;a.J=a.aa=Zb;e||(e=a.Z||a.aa+"px "+bc);a.M=a.Z=e;c&&(a.ha=c);d&&(a.D=d,a.la=f||"white")}function $b(a,b,c,d,e){a.D.font=a.M;a.D.fillStyle=a.la;a.D.fillText(b,a.C,a.I);a.C+=a.W;null!=c&&(16!=a.Ca?b=c.toString():(b=8>a.qa?"0x":"",b+=q(c,a.qa)),a.D.fillText(b,a.C,a.I),a.C+=a.W);d&&(a.C+=a.W*d);e&&(a.C=a.ta,a.I+=(a.J+2)*(e||1))} -function Pb(){for(var a=!1,b=pb(document,"pcx86","panel"),c=0;c>2,cc=Sb,Vb=Sb,Xb="black",Wb=Sb>>1;Ra(Pb); -function dc(a,b,c){ab.call(this,"Bus",a);this.H=b;this.ba=c;this.I=a.busWidth||20;this.O=Math.pow(2,this.I);this.N=this.C=this.O-1|0;this.A=32==this.I||20>=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.O/this.B|0;this.W=this.M-1;this.F=[];this.G=[];this.K=this.L=!1;this.Y=[];this.Z=[];a=new x;ec(a,this.ba);this.aa=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.xa)return k.ve+=k.xa-f,k.xa=f,!0;if(f>=k.xa+k.ve){p=k.size-(f-m);p>g&&(p=g);k.ve=f-k.xa+p;f=m+a.B;g-=p;h++;continue}}return hc(a,ic,f,g)}f=new x(f,p,a.B,d,e);ec(f,a.ba,k);a.aa[h++]=f;f=m+a.B;g-=p}return 0>=g?(jc(a.H),a.H.ea.vb||a.status(Math.floor(c/1024)+"Kb "+kc[d]+" at "+q(b)),!0):hc(a,lc,b,c)} -function fc(a,b){32==a.I?b?a.J&&(mc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=nc(a,1048576,1048576),mc(a,1048576,1048576,nc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Bc(a&this.D,a)};function Ac(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.aa[d].Nf(c,b):a.aa[d++].Zd(c,b)|a.aa[d&a.W].Zd(0,b+1)<<8} -l.fc=function(a,b){this.aa[(a&this.C)>>>this.A].Dc(a&this.D,b&255,a)};function Bc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.aa[e].ri(d,c&65535,b):(a.aa[e++].bf(d,c&255,b),a.aa[e&a.W].bf(0,c>>8&255,b+1))}l.wj=function(){return null}; -function Cc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||fc(a,!0);for(var f=0;f>>=f)&k;if(void 0!==g){if(g[0])g[0](b,k,e);a.ba&&a.L!=g[1]&&Kc(a.ba,b,k)}else a.ba&&(Db(a.ba,a,b,k,e),a.L&&Kc(a.ba,b,k));f+=h<<3;b+=h;c-=h}}function hc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ba?a.ba.message(b):a.log(b):Wa(b);return!1}var Ub,Lc={Hk:20,count:8,aq:1,type:3},Nc=0,Oc;for(Oc in Lc){var Pc=Lc[Oc];Lc[Oc]={nh:(1<>1),this.X=new Int32Array(this.I,0,c>>2),pc(this,wc?xc:yc);else{this.X=Array(c>>2);for(e=0;e>2),b=0;b=this.x&&a=this.y&&b=c>>2);d?(b=new Ub(a.x,a.y,a.Nc,a.A*b/c|0),a.y+=b.A,a.A-=b.A):(b=new Ub(a.x,a.y,a.Nc*b/c|0,a.A),a.x+=b.Nc,a.Nc-=b.Nc);return b}function Wb(a){nb.call(this,"Panel",a);this.F=this.G=this.L=-1}ba(Wb,nb);l=Wb.prototype;l.Cb=function(a,b,c,d){return this.pa&&this.pa.Cb(a,b,c,d)||this.H&&this.H.Cb(a,b,c,d)||this.B&&this.B.Cb(a,b,c,d)||this.ba&&this.ba.Cb(a,b,c,d)?!0:nb.prototype.Cb.call(this,a,b,c,d)}; +l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.B=Xb(a,"Keyboard")};l.Xb=function(a,b){b||Yb();return!0};l.Wb=function(){return!0};l.Vd=function(a,b){a.button||(this.L=b?0:-1,Zb(this,a,b))};l.tf=function(a){Zb(this,a)}; +function Zb(a,b,c){var d=$b/null.offsetWidth,e=ac/null.offsetHeight,f=null.getBoundingClientRect(),d=(b.clientX-f.left)*d|0;b=(b.clientY-f.top)*e|0;null==c&&(a.L||(a.L=Math.abs(a.F-d)>Math.abs(a.G-b)?1:2),1==a.L?b=a.G:2==a.L&&(d=a.F));a.F=d;a.G=b;if(0<=d&&d<$b&&0<=b&&bd&&(f=d);c= +f;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.ga)){b=c;if(a.context&&a.N&&a.O){e=dc-ec;f=a.N.width;a.O.fillStyle=fc;a.O.fillRect(0,e,f,ec);gc(a,e+hc,a.N,a.O);a.W=a.ha.width/24|0;if(null==b)ic(a,"Mouse over memory to dump");else for(ic(a,q(b,8,!0),null,0,1),d=1;16>=d;d++){for(var g="",h=1;8>=h;h++){var k;k=a.ka;var m=b++;k=k.aa[(m&k.C)>>>k.A].Zd(m&k.D,m);ic(a,q(k,2),null,1);g+=32<=k&&128>k?String.fromCharCode(k):"."}ic(a,g,null,0,1)}a.context.drawImage(a.N,0,e,f,ec,a.Da,a.Ha,a.va,a.za)}a.ga=c}}} +function jc(a,b,c,d){a.A.kf[a.A.$i++]={Ll:b,Hd:c,type:d};return Ga(cc,b,c,0,d)}function gc(a,b,c,d){var e,f=null.style.color,g=a.ta=10;a.C=g;a.I=b;a.J=a.aa=hc;e||(e=a.Z||a.aa+"px "+kc);a.M=a.Z=e;c&&(a.ha=c);d&&(a.D=d,a.la=f||"white")}function ic(a,b,c,d,e){a.D.font=a.M;a.D.fillStyle=a.la;a.D.fillText(b,a.C,a.I);a.C+=a.W;null!=c&&(16!=a.Ca?b=c.toString():(b=8>a.qa?"0x":"",b+=q(c,a.qa)),a.D.fillText(b,a.C,a.I),a.C+=a.W);d&&(a.C+=a.W*d);e&&(a.C=a.ta,a.I+=(a.J+2)*(e||1))} +function Yb(){for(var a=!1,b=Ab(document,"pcx86","panel"),c=0;c>2,lc=ac,dc=ac,fc="black",ec=ac>>1;ab(Yb); +function mc(a,b,c){nb.call(this,"Bus",a);this.H=b;this.ba=c;this.I=a.busWidth||20;this.O=Math.pow(2,this.I);this.N=this.C=this.O-1|0;this.A=32==this.I||20>=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.O/this.B|0;this.W=this.M-1;this.F=[];this.G=[];this.K=this.L=!1;this.Y=[];this.Z=[];a=new x;nc(a,this.ba);this.aa=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.xa)return k.ve+=k.xa-f,k.xa=f,!0;if(f>=k.xa+k.ve){p=k.size-(f-m);p>g&&(p=g);k.ve=f-k.xa+p;f=m+a.B;g-=p;h++;continue}}return qc(a,sc,f,g)}f=new x(f,p,a.B,d,e);nc(f,a.ba,k);a.aa[h++]=f;f=m+a.B;g-=p}return 0>=g?(tc(a.H),a.H.ea.vb||a.status(Math.floor(c/1024)+"Kb "+vc[d]+" at "+q(b)),!0):qc(a,wc,b,c)} +function oc(a,b){32==a.I?b?a.J&&(xc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=yc(a,1048576,1048576),xc(a,1048576,1048576,yc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Bc(a&this.D,a)};function Jc(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.aa[d].Nf(c,b):a.aa[d++].Zd(c,b)|a.aa[d&a.W].Zd(0,b+1)<<8} +l.fc=function(a,b){this.aa[(a&this.C)>>>this.A].Dc(a&this.D,b&255,a)};function Kc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.aa[e].ri(d,c&65535,b):(a.aa[e++].bf(d,c&255,b),a.aa[e&a.W].bf(0,c>>8&255,b+1))}l.wj=function(){return null}; +function Lc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||oc(a,!0);for(var f=0;f>>=f)&k;if(void 0!==g){if(g[0])g[0](b,k,e);a.ba&&a.L!=g[1]&&Uc(a.ba,b,k)}else a.ba&&(Nb(a.ba,a,b,k,e),a.L&&Uc(a.ba,b,k));f+=h<<3;b+=h;c-=h}}function qc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ba?a.ba.message(b):a.log(b):hb(b);return!1}var cc,Vc={Hk:20,count:8,aq:1,type:3},Wc=0,Xc;for(Xc in Vc){var Yc=Vc[Xc];Vc[Xc]={nh:(1<>1),this.X=new Int32Array(this.I,0,c>>2),Ac(this,Fc?Gc:Hc);else{this.X=Array(c>>2);for(e=0;e>2),b=0;b>8,c)};l.oi=function(a,b,c){this.Dc(a++,b&255,c++);this.Dc(a++,b>>8&255,c++);this.Dc(a++,b>>16&255,c++);this.Dc(a,b>>>24,c)};l.xo=function(a){return this.X[a>>2]>>>((a&3)<<3)&255}; l.Jo=function(a){var b=a>>2;a=(a&3)<<3;var c=this.X[b]>>a;return 24>a?c&65535:c&255|(this.X[b+1]&255)<<8};l.Do=function(a){var b=a>>2;a=(a&3)<<3;var c=this.X[b];a&&(c=c>>>a|this.X[b+1]<<32-a);return c};l.Vo=function(a,b){var c=a>>2;a=(a&3)<<3;this.X[c]=this.X[c]&~(255<>2;a=(a&3)<<3;24>a?this.X[c]=this.X[c]&~(65535<>8);this.Oa=!0}; -l.ap=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.X[c]=b;this.Oa=!0};l.wo=function(a,b){this.ba&&null!=this.xa&&dd(this.ba,this.xa+a)||this.C&&ed(this.C,b,1,!1);return this.Zd(a,b)};l.Io=function(a,b){this.ba&&null!=this.xa&&dd(this.ba,this.xa+a,2)||this.C&&ed(this.C,b,2,!1);return this.Nf(a,b)};l.Co=function(a,b){this.ba&&null!=this.xa&&dd(this.ba,this.xa+a,4)||this.C&&ed(this.C,b,4,!1);return this.ji(a,b)}; -l.Uo=function(a,b,c){this.ba&&null!=this.xa&&fd(this.ba,this.xa+a)||this.C&&ed(this.C,c,1,!0);this.D?this.cf(0,b,c):this.bf(a,b,c)};l.gp=function(a,b,c){this.ba&&null!=this.xa&&fd(this.ba,this.xa+a,2)||this.C&&ed(this.C,c,2,!0);this.D?this.cf(0,b,c):this.ri(a,b,c)};l.$o=function(a,b,c){this.ba&&null!=this.xa&&fd(this.ba,this.xa+a,4)||this.C&&ed(this.C,c,4,!0);this.D?this.cf(0,b,c):this.K(a,b,c)};l.zo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Bc(a,b)}; +l.ap=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.X[c]=b;this.Oa=!0};l.wo=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a)||this.C&&rd(this.C,b,1,!1);return this.Zd(a,b)};l.Io=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a,2)||this.C&&rd(this.C,b,2,!1);return this.Nf(a,b)};l.Co=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a,4)||this.C&&rd(this.C,b,4,!1);return this.ji(a,b)}; +l.Uo=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a)||this.C&&rd(this.C,c,1,!0);this.D?this.cf(0,b,c):this.bf(a,b,c)};l.gp=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a,2)||this.C&&rd(this.C,c,2,!0);this.D?this.cf(0,b,c):this.ri(a,b,c)};l.$o=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a,4)||this.C&&rd(this.C,c,4,!0);this.D?this.cf(0,b,c):this.K(a,b,c)};l.zo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Bc(a,b)}; l.Lo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Mf(a,b)};l.Fo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Nd(a,b)};l.Xo=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Dc(a,b,c)};l.jp=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Tf(a,b,c)};l.cp=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Sf(a,b,c)}; -l.Ao=function(a,b){return gd(this.C,b,!1).Bc(a,b)};l.Mo=function(a,b){return gd(this.C,b,!1).Mf(a,b)};l.Go=function(a,b){return gd(this.C,b,!1).Nd(a,b)};l.Yo=function(a,b,c){gd(this.C,c,!0).Dc(a,b,c)};l.kp=function(a,b,c){gd(this.C,c,!0).Tf(a,b,c)};l.ep=function(a,b,c){gd(this.C,c,!0).Sf(a,b,c)};l.vo=function(a){return this.Pa[a]};l.Qk=function(a){return this.Pa[a]};l.yo=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Bc=this.Qk;return this.Pa[a]}; +l.Ao=function(a,b){return td(this.C,b,!1).Bc(a,b)};l.Mo=function(a,b){return td(this.C,b,!1).Mf(a,b)};l.Go=function(a,b){return td(this.C,b,!1).Nd(a,b)};l.Yo=function(a,b,c){td(this.C,c,!0).Dc(a,b,c)};l.kp=function(a,b,c){td(this.C,c,!0).Tf(a,b,c)};l.ep=function(a,b,c){td(this.C,c,!0).Sf(a,b,c)};l.vo=function(a){return this.Pa[a]};l.Qk=function(a){return this.Pa[a]};l.yo=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Bc=this.Qk;return this.Pa[a]}; l.Ho=function(a){return this.G.getUint16(a,!0)};l.Vk=function(a){return a&1?this.Pa[a]|this.Pa[a+1]<<8:this.Rd[a>>1]};l.Ko=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Mf=this.Vk;return a&1?this.Pa[a]|this.Pa[a+1]<<8:this.Rd[a>>1]};l.Bo=function(a){return this.G.getInt32(a,!0)};l.Sk=function(a){return a&3?this.Pa[a]|this.Pa[a+1]<<8|this.Pa[a+2]<<16|this.Pa[a+3]<<24:this.X[a>>2]}; l.Eo=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Nd=this.Sk;return a&3?this.Pa[a]|this.Pa[a+1]<<8|this.Pa[a+2]<<16|this.Pa[a+3]<<24:this.X[a>>2]};l.To=function(a,b){this.Pa[a]=b;this.Oa=!0};l.el=function(a,b){this.Pa[a]=b;this.Oa=!0};l.Wo=function(a,b){this.Pa[a]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Dc=this.el;this.pd.Oa=!0};l.fp=function(a,b){this.G.setUint16(a,b,!0);this.Oa=!0};l.gl=function(a,b){a&1?(this.Pa[a]=b,this.Pa[a+1]=b>>8):this.Rd[a>>1]=b;this.Oa=!0}; l.ip=function(a,b){a&1?(this.Pa[a]=b,this.Pa[a+1]=b>>8):this.Rd[a>>1]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Tf=this.gl;this.pd.Oa=!0};l.Zo=function(a,b){this.G.setInt32(a,b,!0);this.Oa=!0};l.fl=function(a,b){a&3?(this.Pa[a]=b,this.Pa[a+1]=b>>8,this.Pa[a+2]=b>>16,this.Pa[a+3]=b>>24):this.X[a>>2]=b;this.Oa=!0}; -l.bp=function(a,b){a&3?(this.Pa[a]=b,this.Pa[a+1]=b>>8,this.Pa[a+2]=b>>16,this.Pa[a+3]=b>>24):this.X[a>>2]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Sf=this.fl;this.pd.Oa=!0};function hd(a){Eb&&!wc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} -var Tc=0,vc=2,Uc=5,Wc=6,id=["black","blue","green","cyan"],kc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),Sc=0,Yc=[],zc=[x.prototype.xo,x.prototype.Vo,x.prototype.Jo,x.prototype.hp,x.prototype.Do,x.prototype.ap],cd=[x.prototype.wo,x.prototype.Uo,x.prototype.Io,x.prototype.gp,x.prototype.Co,x.prototype.$o],Xc=[x.prototype.zo,x.prototype.Xo,x.prototype.Lo,x.prototype.jp,x.prototype.Fo,x.prototype.cp],Vc=[x.prototype.Ao,x.prototype.Yo,x.prototype.Mo,x.prototype.kp,x.prototype.Go,x.prototype.ep]; -if(Eb)var yc=[x.prototype.vo,x.prototype.To,x.prototype.Ho,x.prototype.fp,x.prototype.Bo,x.prototype.Zo],xc=[x.prototype.Qk,x.prototype.el,x.prototype.Vk,x.prototype.gl,x.prototype.Sk,x.prototype.fl],nd=[x.prototype.yo,x.prototype.Wo,x.prototype.Ko,x.prototype.ip,x.prototype.Eo,x.prototype.bp]; -function od(a,b){ab.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.T={};this.T.sd=b;this.T.Kd=c;this.T.rg=Math.round(this.T.sd/1E4)/100;this.T.oe=this.T.rg*this.T.Kd;this.ea.vb=!1;this.ea.ni=!1;this.ea.lf=a.autoStart;this.ea.kj=!1;this.ea.He=!1;this.T.uf=this.T.Te=0;this.T.wf=a.csStart;this.T.Se=a.csInterval;this.T.Ue=a.csStop;this.Ql=this.Uf.bind(this);zb(this)}ba(od,ab);l=od.prototype; -l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.ba=d;for(b=0;b=a.T.Te&&(a.T.Te+=a.T.Se,c=!0);0<=a.T.Ue&&a.T.Ue<=vd(a)&&(a.T.Se=a.T.Ue=-1,sd(a),a.Jb(),c=!0);c&&a.P(vd(a)+" cycles: checksum="+q(a.T.uf))}} -l.Cb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.na[b]=c;a=!0;break;case "run":this.na[b]=c;c.onclick=function(){var a;if(a=d.pa)if(a=d.pa,a.ea.Yb)a=!0;else{var b=null,c,h=jb(a.id);for(c=0;ca.T.rg&&(c=Math.round(c/a.T.Kd));return c}function rd(a){a.T.Wd=0;a.Dd=a.md=a.zc=a.A=0;sd(a);wd(a,1)} -function wd(a,b,c){var d=!1;if(void 0!==b){.8>a.T.Wd/a.T.oe?b=1:d=!0;a.T.Kd=b;b=a.T.rg*a.T.Kd;if(a.T.oe!=b){a.T.oe=b;b=a.T.oe.toFixed(2)+"Mhz";var e=a.na.setSpeed;e&&(e.textContent=b);a.P("target speed: "+b)}c&&a.pa&&a.pa.ld()}yd(a,a.md);a.md=0;a.T.Xd=Ba();a.T.pe=0;zd(a);return d} -l.Uf=function(a){if(Bb(this,!0)){if(!this.ea.vb){wd(this);this.pa&&this.pa.start(this.T.Xd,vd(this));this.ea.vb=!0;this.ea.ni=!0;this.W&&this.W.start();var b=this.na.run;b&&(b.textContent="Halt");this.pa&&(Dd(this.pa,!0),a&&this.pa.ld(!0))}this.T.th>=this.T.sd&&zd(this,!0);this.T.zf=0;this.T.sg=Ba();this.T.pe&&(a=this.T.sg-this.T.pe,a>this.T.Dj&&(this.T.Xd+=a,this.T.Xd>this.T.sg&&(this.T.Xd=this.T.sg)));try{do{var c=this.ea.He?1:this.T.nn;if(this.W){Ed(this.W);var d=this.W;a=c;var e=d.G[0];if(e.le){var f= -(vd(d.H,d.O)-e.jd)/d.Ba|0,g=Fd(d,0)-f;e.mode==Gd&&(g-=f);var h=g*d.Ba|0;e.mode==Gd&&(h>>=1);a>h&&(a=h)}var c=a,k=this.W;a=c;if(k.A&&k.A[Hd]&Id){var m=k.Z-vd(k.H,k.O);0m&&(a=m)}c=a}try{this.Lg(c)}catch(w){if("number"!=typeof w)throw w;}var p=this.zc-this.A;this.md+=p;this.T.zf+=p;yd(this,0,!0);ud(this,p);this.T.yf-=p;0>=this.T.yf&&(this.T.yf+=this.T.Fj,this.pa&&Jd(this.pa));this.T.xf-=p;0>=this.T.xf&&(this.T.xf+=this.T.Ej,this.pa&&Dd(this.pa));this.T.Ve-=p;if(0>=this.T.Ve){this.T.Ve+=this.T.sh; -break}}while(this.ea.vb)}catch(w){this.Jb();td(this);this.pa&&this.pa.stop(Ba(),vd(this));Bb(this,!1);wb(this,w.stack||w.message);return}c=setTimeout;d=this.Ql;this.T.pe=Ba();e=this.T.Dj;this.T.zf&&(e=Math.round(e*this.T.zf/this.T.sh));e-=this.T.pe-this.T.sg;if(f=this.T.pe-this.T.Xd)this.T.Wd=Math.round(this.md/(10*f))/100,864E5<=f&&(this.Dd=0,this.W&&Ed(this.W,!0),wd(this));if(0>e||this.T.Wde&&(this.T.Xd-=e),e=0;this.T.th+=this.T.zf;this.T.pe+=e;c(d,e)}else td(this),this.pa&&this.pa.stop(Ba(), -vd(this))};l.Lg=function(){return 0};l.Jb=function(a){Ab(this,!0);this.zc-=this.A;this.A=0;yd(this,this.md);this.md=0;if(this.ea.vb){this.ea.vb=!1;this.W&&this.W.stop();var b=this.na.run;b&&(b.textContent="Run")}this.ea.complete=a};function td(a,b){a.pa&&(Jd(a.pa,b),Dd(a.pa,b))}var Ad=30,Bd=60,Cd=2,pd=["power","reset"]; -function Kd(a,b,c,d){this.gc=a;this.ba=a.ba;this.id=b;this.$b=c||"";this.U=0;this.Ka=65535;this.Nb=this.Ka+1;this.Ab=this.qc=this.ext=this.jb=this.type=this.ua=0;this.Lb=-1;this.V=this.Jc=2;this.R=this.wa=65535;this.G=this.mh;this.D=this.dj;this.F=this.fj;this.A={U:-1,ua:0,Ka:0,jb:0,type:0,ext:0,Lb:-1};1==this.id&&(this.Jf=0,this.C=null,this.Pe=!1,this.H=Array(32),this.B=[]);Md(this,!0,d)}function Nd(a,b){a.B.push(b);return[a.B.length,Od]}l=Kd.prototype; -l.mh=function(a){this.U=a&65535;return this.ua=this.U<<4};l.qg=function(a,b){var c,d,e=this.gc;a&=65535;a&4?(c=e.Eb.ua,d=c+e.Eb.Ka|0):(c=e.Kb,d=e.Pc);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,Pd(this,c,a,b);this.id>>0)+b<=this.Nb?this.ua+a|0:this.kg()};l.zl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.kg()};l.kg=function(){y.call(this.gc,13,0);return-1};l.ej=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.lg()}; -l.Al=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.lg()};l.lg=function(){y.call(this.gc,13,0);return-1};function Td(a,b,c,d,e){a.U=b;a.ua=d;a.Ka=e;a.Nb=(e>>>0)+1;a.jb=c;a.type=c&7936;a.ext=c>>16&192;a.Lb=(b&4?a.gc.Eb.ua:a.gc.Kb)+(b&65528)|0;a.id>>0)+1;a.jb=e;a.type=e&7936;a.ext=0;a.Lb=b;a.id>>0)+1,a.jb=a.A.jb,a.type=a.A.type,a.ext=a.A.ext,a.Lb=a.A.Lb,a.A.U=-1,Md(a,!0,!0,!1),a.ua;a.A.U=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.ca){var w=f,k=k|(m&65280)<<16,f=f|(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case Wd:var u=a.C;a.Pe=!1;if(u&&c==Od&&a.B.length){var F=a.B[a.Jf-1];if(F&&!F())return-1}var K=c&3,H=(g&24576)>>13,F=-1,I,T;p||b>= -e.Kb&&b=a.Ab&&(K>a.Ab&&(F=Xd(e),Yd(e,Xd(e),!0),Zd(e,F),a.Pe=!0),F=0);else{if(256==h||2304==h)return $d(a,c,u)?a.ua:-1;if(1024==h)F=2,T=0,Kh||2048==(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,11,c&65532),-1}break;case Rd:if(!p||4096>h||512!=(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,12,c&65532), --1;break;case Ud:u=h&-513;if(!p||256!=u&&2304!=u)return y.call(e,13,c&65532),-1;2304==u&&(a.Si=k+e.ja(k+102)|0,a.tl=k+a.Ka|0);break;case Qd:if(!(h&4096)&&768>>0)+1,a.jb=g,a.type=h,a.ext=m,a.Lb=b,Md(a,!0,!0,!1));return k} -function $d(a,b,c){var d=a.gc,e=a.Ab,f=d.la.U,g=d.la.ua;if(!c){if(!(d.la.type&512))return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb&=-513)}if(-1===d.la.load(b))return!1;var h=d.la.ua;if(!1!==c){if(d.la.type&512)return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb|=512)}d.la.type=d.la.type&-513|d.la.jb&512;256==d.la.type||768==d.la.type?(d.fb(g+14,A(d)),d.fb(g+16,ie(d)),d.fb(g+18,d.D),d.fb(g+20,d.I),d.fb(g+22,d.L),d.fb(g+24,d.G),d.fb(g+26,z(d)),d.fb(g+28,d.M),d.fb(g+30,d.K),d.fb(g+32,d.J),d.fb(g+ -34,d.oa.U),d.fb(g+36,d.Z.U),d.fb(g+38,d.Y.U),d.fb(g+40,d.Ca.U),d.Eb.load(d.ja(h+42)),je(d,d.ja(h+16)|(c?16384:0)),d.D=d.ja(h+18),d.I=d.ja(h+20),d.L=d.ja(h+22),d.G=d.ja(h+24),d.M=d.ja(h+28),d.K=d.ja(h+30),d.J=d.ja(h+32),d.oa.load(d.ja(h+34)),d.Ca.load(d.ja(h+40)),ke(d,d.ja(h+14),d.ja(h+36)),b=38,g=26,a.Ab>8,this.Pa[a+2]=b>>16,this.Pa[a+3]=b>>24):this.X[a>>2]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Sf=this.fl;this.pd.Oa=!0};function ud(a){Ob&&!Fc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} +var bd=0,Ec=2,cd=5,ed=6,vd=["black","blue","green","cyan"],vc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),ad=0,gd=[],Ic=[x.prototype.xo,x.prototype.Vo,x.prototype.Jo,x.prototype.hp,x.prototype.Do,x.prototype.ap],pd=[x.prototype.wo,x.prototype.Uo,x.prototype.Io,x.prototype.gp,x.prototype.Co,x.prototype.$o],fd=[x.prototype.zo,x.prototype.Xo,x.prototype.Lo,x.prototype.jp,x.prototype.Fo,x.prototype.cp],dd=[x.prototype.Ao,x.prototype.Yo,x.prototype.Mo,x.prototype.kp,x.prototype.Go,x.prototype.ep]; +if(Ob)var Hc=[x.prototype.vo,x.prototype.To,x.prototype.Ho,x.prototype.fp,x.prototype.Bo,x.prototype.Zo],Gc=[x.prototype.Qk,x.prototype.el,x.prototype.Vk,x.prototype.gl,x.prototype.Sk,x.prototype.fl],wd=[x.prototype.yo,x.prototype.Wo,x.prototype.Ko,x.prototype.ip,x.prototype.Eo,x.prototype.bp]; +function xd(a,b){nb.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.T={};this.T.sd=b;this.T.Kd=c;this.T.rg=Math.round(this.T.sd/1E4)/100;this.T.oe=this.T.rg*this.T.Kd;this.ea.vb=!1;this.ea.ni=!1;this.ea.lf=a.autoStart;this.ea.kj=!1;this.ea.He=!1;this.T.uf=this.T.Te=0;this.T.wf=a.csStart;this.T.Se=a.csInterval;this.T.Ue=a.csStop;this.Ql=this.Uf.bind(this);Jb(this)}ba(xd,nb);l=xd.prototype; +l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.ba=d;for(b=0;b=a.T.Te&&(a.T.Te+=a.T.Se,c=!0);0<=a.T.Ue&&a.T.Ue<=Ed(a)&&(a.T.Se=a.T.Ue=-1,Bd(a),a.Jb(),c=!0);c&&a.P(Ed(a)+" cycles: checksum="+q(a.T.uf))}} +l.Cb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.na[b]=c;a=!0;break;case "run":this.na[b]=c;c.onclick=function(){var a;if(a=d.pa)if(a=d.pa,a.ea.Yb)a=!0;else{var b=null,c,h=tb(a.id);for(c=0;ca.T.rg&&(c=Math.round(c/a.T.Kd));return c}function Ad(a){a.T.Wd=0;a.Dd=a.md=a.zc=a.A=0;Bd(a);Fd(a,1)} +function Fd(a,b,c){var d=!1;if(void 0!==b){.8>a.T.Wd/a.T.oe?b=1:d=!0;a.T.Kd=b;b=a.T.rg*a.T.Kd;if(a.T.oe!=b){a.T.oe=b;b=a.T.oe.toFixed(2)+"Mhz";var e=a.na.setSpeed;e&&(e.textContent=b);a.P("target speed: "+b)}c&&a.pa&&a.pa.ld()}Hd(a,a.md);a.md=0;a.T.Xd=Ka();a.T.pe=0;Id(a);return d} +l.Uf=function(a){if(Lb(this,!0)){if(!this.ea.vb){Fd(this);this.pa&&this.pa.start(this.T.Xd,Ed(this));this.ea.vb=!0;this.ea.ni=!0;this.W&&this.W.start();var b=this.na.run;b&&(b.textContent="Halt");this.pa&&(Nd(this.pa,!0),a&&this.pa.ld(!0))}this.T.th>=this.T.sd&&Id(this,!0);this.T.zf=0;this.T.sg=Ka();this.T.pe&&(a=this.T.sg-this.T.pe,a>this.T.Dj&&(this.T.Xd+=a,this.T.Xd>this.T.sg&&(this.T.Xd=this.T.sg)));try{do{var c=this.ea.He?1:this.T.nn;if(this.W){Od(this.W);var d=this.W;a=c;var e=d.G[0];if(e.le){var f= +(Ed(d.H,d.O)-e.jd)/d.Ba|0,g=Pd(d,0)-f;e.mode==Qd&&(g-=f);var h=g*d.Ba|0;e.mode==Qd&&(h>>=1);a>h&&(a=h)}var c=a,k=this.W;a=c;if(k.A&&k.A[Rd]&Td){var m=k.Z-Ed(k.H,k.O);0m&&(a=m)}c=a}try{this.Lg(c)}catch(w){if("number"!=typeof w)throw w;}var p=this.zc-this.A;this.md+=p;this.T.zf+=p;Hd(this,0,!0);Dd(this,p);this.T.yf-=p;0>=this.T.yf&&(this.T.yf+=this.T.Fj,this.pa&&Ud(this.pa));this.T.xf-=p;0>=this.T.xf&&(this.T.xf+=this.T.Ej,this.pa&&Nd(this.pa));this.T.Ve-=p;if(0>=this.T.Ve){this.T.Ve+=this.T.sh; +break}}while(this.ea.vb)}catch(w){this.Jb();Cd(this);this.pa&&this.pa.stop(Ka(),Ed(this));Lb(this,!1);Gb(this,w.stack||w.message);return}c=setTimeout;d=this.Ql;this.T.pe=Ka();e=this.T.Dj;this.T.zf&&(e=Math.round(e*this.T.zf/this.T.sh));e-=this.T.pe-this.T.sg;if(f=this.T.pe-this.T.Xd)this.T.Wd=Math.round(this.md/(10*f))/100,864E5<=f&&(this.Dd=0,this.W&&Od(this.W,!0),Fd(this));if(0>e||this.T.Wde&&(this.T.Xd-=e),e=0;this.T.th+=this.T.zf;this.T.pe+=e;c(d,e)}else Cd(this),this.pa&&this.pa.stop(Ka(), +Ed(this))};l.Lg=function(){return 0};l.Jb=function(a){Kb(this,!0);this.zc-=this.A;this.A=0;Hd(this,this.md);this.md=0;if(this.ea.vb){this.ea.vb=!1;this.W&&this.W.stop();var b=this.na.run;b&&(b.textContent="Run")}this.ea.complete=a};function Cd(a,b){a.pa&&(Ud(a.pa,b),Nd(a.pa,b))}var Jd=30,Kd=60,Md=2,yd=["power","reset"]; +function Vd(a,b,c,d){this.gc=a;this.ba=a.ba;this.id=b;this.$b=c||"";this.U=0;this.Ka=65535;this.Nb=this.Ka+1;this.Ab=this.qc=this.ext=this.jb=this.type=this.ua=0;this.Lb=-1;this.V=this.Jc=2;this.R=this.wa=65535;this.G=this.mh;this.D=this.dj;this.F=this.fj;this.A={U:-1,ua:0,Ka:0,jb:0,type:0,ext:0,Lb:-1};1==this.id&&(this.Jf=0,this.C=null,this.Pe=!1,this.H=Array(32),this.B=[]);Wd(this,!0,d)}function Xd(a,b){a.B.push(b);return[a.B.length,Yd]}l=Vd.prototype; +l.mh=function(a){this.U=a&65535;return this.ua=this.U<<4};l.qg=function(a,b){var c,d,e=this.gc;a&=65535;a&4?(c=e.Eb.ua,d=c+e.Eb.Ka|0):(c=e.Kb,d=e.Pc);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,Zd(this,c,a,b);this.id<$d&&y.call(e,b&&this.id==ae?10:13,a&65532)}return-1};l.gn=function(a){var b=this.gc;a=b.Pb+(a<<2);var c=b.ja(a);b.O&=-769;return this.load(b.ja(a+2))+c|0}; +l.fn=function(a){var b=this.gc;a<<=3;var c=b.Pb+a|0;if(7<=(b.cd-c|0))return this.C=!0,a=Zd(this,c,a),-1!==a&&(a+=this.Jf),a;y.call(b,13,a|2);return-1};l.dj=function(a){return this.ua+a|0};l.fj=function(a){return this.ua+a|0};l.cj=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.kg()};l.zl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.kg()};l.kg=function(){y.call(this.gc,13,0);return-1};l.ej=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.lg()}; +l.Al=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.lg()};l.lg=function(){y.call(this.gc,13,0);return-1};function be(a,b,c,d,e){a.U=b;a.ua=d;a.Ka=e;a.Nb=(e>>>0)+1;a.jb=c;a.type=c&7936;a.ext=c>>16&192;a.Lb=(b&4?a.gc.Eb.ua:a.gc.Kb)+(b&65528)|0;a.id>>0)+1;a.jb=e;a.type=e&7936;a.ext=0;a.Lb=b;a.id>>0)+1,a.jb=a.A.jb,a.type=a.A.type,a.ext=a.A.ext,a.Lb=a.A.Lb,a.A.U=-1,Wd(a,!0,!0,!1),a.ua;a.A.U=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.ca){var w=f,k=k|(m&65280)<<16,f=f|(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case ee:var u=a.C;a.Pe=!1;if(u&&c==Yd&&a.B.length){var F=a.B[a.Jf-1];if(F&&!F())return-1}var K=c&3,H=(g&24576)>>13,F=-1,I,T;p||b>= +e.Kb&&b=a.Ab&&(K>a.Ab&&(F=fe(e),ge(e,fe(e),!0),he(e,F),a.Pe=!0),F=0);else{if(256==h||2304==h)return ie(a,c,u)?a.ua:-1;if(1024==h)F=2,T=0,Kh||2048==(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,11,c&65532),-1}break;case ae:if(!p||4096>h||512!=(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,12,c&65532), +-1;break;case ce:u=h&-513;if(!p||256!=u&&2304!=u)return y.call(e,13,c&65532),-1;2304==u&&(a.Si=k+e.ja(k+102)|0,a.tl=k+a.Ka|0);break;case $d:if(!(h&4096)&&768>>0)+1,a.jb=g,a.type=h,a.ext=m,a.Lb=b,Wd(a,!0,!0,!1));return k} +function ie(a,b,c){var d=a.gc,e=a.Ab,f=d.la.U,g=d.la.ua;if(!c){if(!(d.la.type&512))return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb&=-513)}if(-1===d.la.load(b))return!1;var h=d.la.ua;if(!1!==c){if(d.la.type&512)return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb|=512)}d.la.type=d.la.type&-513|d.la.jb&512;256==d.la.type||768==d.la.type?(d.fb(g+14,A(d)),d.fb(g+16,re(d)),d.fb(g+18,d.D),d.fb(g+20,d.I),d.fb(g+22,d.L),d.fb(g+24,d.G),d.fb(g+26,z(d)),d.fb(g+28,d.M),d.fb(g+30,d.K),d.fb(g+32,d.J),d.fb(g+ +34,d.oa.U),d.fb(g+36,d.Z.U),d.fb(g+38,d.Y.U),d.fb(g+40,d.Ca.U),d.Eb.load(d.ja(h+42)),se(d,d.ja(h+16)|(c?16384:0)),d.D=d.ja(h+18),d.I=d.ja(h+20),d.L=d.ja(h+22),d.G=d.ja(h+24),d.M=d.ja(h+28),d.K=d.ja(h+30),d.J=d.ja(h+32),d.oa.load(d.ja(h+34)),d.Ca.load(d.ja(h+40)),te(d,d.ja(h+14),d.ja(h+36)),b=38,g=26,a.Ab>>0)+1)}; -function Md(a,b,c,d){void 0===c&&(c=!!(a.gc.qa&1));a.Oc=!1;if(c)if(a.load=a.qg,a.Cj=a.fn,a.bc=a.cj,a.cc=a.ej,void 0===d&&(d=!!(a.gc.O&131072)),d)a.load=a.G,a.bc=a.D,a.cc=a.F,a.Ab=a.qc=3,a.V=2,a.R=a.wa=65535,a.Ka=65535,a.Nb=a.Ka+1,a.Jc=a.V,a.Lb=-1,a.Pe=!1;else{if(!(a.U&-4))a.bc=a.kg,a.cc=a.lg;else if(a.type&4096){6144==(a.type&6656)&&(a.bc=a.kg);if(a.type&2048||!(a.type&512))a.cc=a.lg;1024==(a.type&3072)&&(a.bc==a.cj&&(a.bc=a.zl),a.cc==a.ej&&(a.cc=a.Al),a.Oc=!0);b&&a.id>13,80386>a.gc.ca||!(a.ext&64)?(a.V=2,a.R=65535):(a.V=4,a.R=-1),a.Jc=a.V,a.wa=a.R)}else a.load=a.mh,a.Cj=a.gn,a.bc=a.dj,a.cc=a.fj,a.Ab=a.qc=0,a.Lb=-1,a.Pe=!1}var Wd=1,he=2,Rd=3,Ud=4,Qd=6,Od=1; -function me(a){var b=+a.model||8088,c;switch(b){default:c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}od.call(this,a,c);this.ca=b;a=a.stepping;this.we=b+(a?ga(a,16):0);this.Ri=61442;this.Qd=1792;this.si=28672;this.Vf=4;this.Ta=255;this.B=80286<=this.ca?Gb:Fb;this.va=ne;this.bj=oe;this.ij=pe;this.nj=qe;if(80186<=this.ca&&(this.va=ne.slice(),this.bj=oe.slice(),this.ij=pe.slice(),this.Ta=31,this.va[15]=re,this.va[96]=se,this.va[97]=te,this.va[98]=ue,this.va[99]=re,this.va[100]=re,this.va[101]= -re,this.va[102]=re,this.va[103]=re,this.va[104]=ze,this.va[105]=Ae,this.va[106]=Be,this.va[107]=Ce,this.va[108]=De,this.va[109]=Ee,this.va[110]=Fe,this.va[111]=Ge,this.va[192]=He,this.va[193]=Ie,this.va[200]=Je,this.va[201]=Ke,this.va[241]=Le,this.bj[7]=Me,this.ij[7]=Me,80286<=this.ca)){this.Ri=2;this.Qd|=28672;this.Vf=0;this.va[15]=Ne;this.Pd=Oe.slice();for(b=0;b=this.we&&(this.Pd[166]=We,this.Pd[167]=Xe)}}this.Yf=[];this.Zf=[];this.ag=0;rd(this);this.ea.complete=this.ea.jj=!1;this.tj=0;this.sc=this.aa=[];this.qb=this.Ng=this.Db=this.Wf=this.df=this.ef=this.ed=0;Ye(this)}ba(me,od);function Ze(a,b,c,d){b=(d?a.sc:a.aa)[b>>>a.qb];c?--b.ie||bd(b):--b.he||ad(b);d&&jc(a)} -function $e(a){var b;if(a.aa===a.sc){a.aa=Array(a.Wf);a.$f=new x(null,0,0,Uc,null,a);ec(a.$f,a.ba);for(b=0;b>>20,f=a.sc[(a.Wc+e&a.ef)>>>a.qb],g=f.Nd(e);if(!(g&1))return d||ef.call(a,b,!1,c),a.ff;if(!(g&4)&&3==a.Ma)return d||ef.call(a,b,!0,c),a.ff;var h=(b&4190208)>>>10,g=a.sc[((g&-4096)+h&a.ef)>>>a.qb],k=g.Nd(h);if(!(k&1))return d||ef.call(a,b,!1,c),a.ff;if(!(k&4)&&3==a.Ma)return d||ef.call(a,b,!0,c),a.ff;c=a.sc[((k&-4096)+(b&4095)&a.ef)>>>a.qb];if(d)return c;d=b>>>a.qb;k=a.aa[d];b&=-4096;var m;0>2;b.mb=g;b.B=h>>2;Eb&&wc&&c.X&&!c.controller&&!c.he&&!c.ie?(b.Pa=c.Pa,b.Rd=c.Rd,b.X=c.X,pc(b,nd)):(b.F=c?hd(32):0,b.J=c?hd(96):0,pc(b,Xc));ec(b,a.ba,k);a.aa[d]=b;a.Xf.push(d);return b}function ff(a){a.aa!==a.sc&&(a.aa=a.sc,a.$f=null,a.Xf=null,a.ff=null)}l=me.prototype;l.reset=function(){this.ea.vb&&this.Jb();Ye(this);rd(this);this.ea.error=!1}; -function gf(a,b){var c;switch(b){case 0:c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.G;break;case 4:c=z(a);break;case 5:c=a.M;break;case 6:c=a.K;break;case 7:c=a.J}return c}function hf(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.G=c;break;case 4:Zd(a,c);break;case 5:a.M=c;break;case 6:a.K=c;break;case 7:a.J=c}} -function Ye(a){a.D=0;a.G=0;a.I=0;a.L=0;a.Hc=0;a.M=0;a.K=0;a.J=0;a.vc=!1;a.Ba=a.$a=0;a.bn=[0,0];a.cn=[0,0];a.ya=0;a.sj=0;a.ga=0;a.qa=65520;a.Pb=0;a.cd=1023;a.O=a.lc=0;a.ze=a.hf=a.ye=a.Ae=0;a.Uc=-1;a.Ad=a.Vc=-1;a.Bd=a.ta=-1;a.Z=new Kd(a,Wd,"CS");a.Ca=new Kd(a,he,"DS");a.oa=new Kd(a,he,"ES");a.Y=new Kd(a,Rd,"SS");Zd(a,0);Yd(a,0);if(80386<=a.ca){switch(a.we){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.qa=16;a.Og=0;a.Cd=0;a.Wc=0; -a.Qb=[0,0,0,0,null,null,0,0];a.dg=[null,null,null,null,null,null,0,0];a.Ga=new Kd(a,he,"FS");a.Ha=new Kd(a,he,"GS");ff(a)}a.Qg=new Kd(a,0,"NULL");a.Da=a.Ca;a.Rb=a.Y;a.N=a.ha=0;a.C=a.F=-1;a.eb=a.Qg;a.Za=0;if(80286>a.ca)ke(a,0,65535);else{a.Kb=0;a.Pc=65535;a.Eb=new Kd(a,5,"LDT",!0);a.la=new Kd(a,Ud,"TSS",!0);a.xb=new Kd(a,Qd,"VER",!0);ke(a,65520,61440);var b,c=A(a);b=a.Z;var d=-65536;80386>b.gc.ca&&(d&=16777215);b=b.ua=d;a.da=b+c|0;a.Pg=(b>>>0)+(a.Z.Ka>>>0)+1}je(a,0);ae(a)} -function jf(a){2==a.Jc?(a.Sb=a.ja,a.kc=kf,a.tc=lf,a.kd=rf,2==a.V?(a.ma=sf,a.za=tf,a.rb=uf):(a.ma=vf,a.za=wf,a.rb=xf)):(a.Sb=a.ia,a.kc=yf,a.tc=zf,a.kd=Af,2==a.V?(a.ma=Bf,a.za=Cf,a.rb=Df):(a.ma=Ef,a.za=Ff,a.rb=Gf))}function be(a,b){a.V!=b&&(a.ha|=1024,a.V=b,a.R=2==b?65535:-1,Hf(a))}function Hf(a){2==a.V?(a.Fb=32768,a.hb=a.ja,a.yb=a.fb,2==a.Jc?(a.ma=sf,a.za=tf,a.rb=uf):(a.ma=Bf,a.za=Cf,a.rb=Df)):(a.Fb=-2147483648,a.hb=a.ia,a.yb=a.ab,2==a.Jc?(a.ma=vf,a.za=wf,a.rb=xf):(a.ma=Ef,a.za=Ff,a.rb=Gf))} -function If(a){a.Jc=a.Z.Jc;a.wa=a.Z.wa;jf(a);a.V=a.Z.V;a.R=a.Z.R;Hf(a);a.ha&=-3073}l.uj=function(){var a=this.D+this.G+this.I+this.L+z(this)+this.M+this.K+this.J|0;return a=a+A(this)+this.Z.U+this.Ca.U+this.Y.U+this.oa.U+ie(this)|0};function Jf(a,b,c){void 0===a.Yf[b]&&(a.Yf[b]=[]);a.Yf[b].push(c)}function Kf(a,b,c){c&&(null==a.Zf[b]&&a.ag++,a.Zf[b]=c)}function Lf(a,b){var c=a.Zf[b];null!=c&&(c(--a.ag),delete a.Zf[b])} -function Mf(a,b){for(var c=a.Qb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Qb[e],g=g&~(d>>2&3);b?a.aa[g>>>a.qb].Gd(g&a.Db,f,a):(g=a.aa[g>>>a.qb],f?--g.ie||bd(g):--g.he||ad(g))}c>>=2;d>>=4}}function ed(a,b,c,d){if(!(a.N&8192)&&a.Qb[7]&255){c--;var e=a.Qb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Qb[g]&&b<=a.Qb[g]+h){a.Qb[6]|=1<>=2;f>>=4}}} -function ae(a,b,c){void 0===b&&(b=!!(a.qa&1));void 0===c&&(c=!!(a.O&131072));a.nj=b&&!c?Nf:qe;Md(a.Z,!1,b,c);Md(a.Ca,!1,b,c);Md(a.Y,!1,b,c);Md(a.oa,!1,b,c);80386<=a.ca&&(Md(a.Ga,!1,b,c),Md(a.Ha,!1,b,c));If(a)} -l.save=function(){var a=new Of(this);a.set(0,[this.D,this.G,this.I,this.L,z(this),this.M,this.K,this.J]);var b=A(this),c=this.Z.save(),d=this.Ca.save(),e=this.Y.save(),f=this.oa.save(),g;null!=this.Kb?(g=[this.qa,this.Kb,this.Pc,this.Pb,this.cd,this.Eb.save(),this.la.save(),this.lc],80386<=this.ca&&(g.push(this.Og),g.push(this.Cd),g.push(this.Wc),g.push(this.Qb),g.push(this.dg))):g=null;b=[b,c,d,e,f,g,ie(this)];80386<=this.ca&&(b.push(this.Ga.save()),b.push(this.Ha.save()));a.set(1,b);a.set(2,[this.Da.$b, -this.Rb.$b,this.N,this.ha,this.Za,this.C,this.F]);a.set(3,[0,this.Dd,this.T.Kd]);a.set(4,Cc(this.ka,!!(this.qa&-2147483648)));return a.data()}; -l.restore=function(a){var b=a[0];this.D=b[0];this.G=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.M=b[5];this.K=b[6];this.J=b[7];b=a[1];this.Z.restore(b[1]);this.Ca.restore(b[2]);this.Y.restore(b[3]);this.oa.restore(b[4]);var d=b[5];d&&d.length&&(this.qa=d[0],this.Kb=d[1],this.Pc=d[2],this.Pb=d[3],this.cd=d[4],this.Eb.restore(d[5]),this.la.restore(d[6]),this.lc=d[7],80386<=this.ca&&(this.Og=d[8],this.Cd=d[9],this.Wc=d[10],this.Qb=d[11],this.dg=d[12]),ae(this));je(this,b[6]);var d=!1,e;a:{e=this.ka; -var f=a[4],g;for(g=0;g>>0)+(a.Z.Ka>>>0)+1;a.Ma=a.Z.Ab;If(a)}function ke(a,b,c,d){var e=a.Z;e.Jf=b;e.C=d;b=e.load(c);return-1!==b?(Rf(a,b+(a.Z.Jf&a.Z.R)),a.Z.Pe):null} -function Sf(a,b){b=(a.da>>>0)+b;b>a.Pg&&(8088>=a.ca||a.Z.Ka==a.Z.wa?b=a.Z.ua+(b-a.Pg&a.R):y.call(a,13,0));return b|0}function Tf(a){a.da=a.Bd}function z(a){return a.Hc&~a.Y.wa|a.Aa-a.Y.ua}function Zd(a,b){a.Hc=b;a.Aa=a.Y.ua+(b&a.Y.wa)|0}function Uf(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&Vf(a),g&2&&Wf(a),g&4&&Xf(a),g&8&&Yf(a),g&16&&Zf(a),g&32&&$f(a))}f?(a.ze=d,a.ye=b):(a.ze=b,a.ye=d);a.hf=c;a.Ae=d;a.resultType=e} -function ag(a,b,c,d,e){a.resultType=c|26;a.Ae=b;d?bg(a):cg(a);e?dg(a):eg(a);return b}function fg(a,b,c,d){c&d?bg(a):cg(a);(b^c)&d?dg(a):eg(a)}function gg(a){return Vf(a)?1:0}function Vf(a){a.resultType&1&&(a.O&=-2,(a.ze^(a.ze^a.hf)&(a.hf^a.ye))&a.resultType&-2147450752&&(a.O|=1),a.resultType&=-2);return a.O&1}function Wf(a){a.resultType&2&&(a.O&=-5,38505>>((a.Ae^a.Ae>>4)&15)&1&&(a.O|=4),a.resultType&=-3);return a.O&4} -function Xf(a){a.resultType&4&&(a.O&=-17,(a.ye^a.ze^a.hf)&16&&(a.O|=16),a.resultType&=-5);return a.O&16}function Yf(a){a.resultType&8&&(a.O&=-65,a.Ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.O|=64),a.resultType&=-9);return a.O&64}function Zf(a){a.resultType&16&&(a.O&=-129,a.Ae&a.resultType&-2147450752&&(a.O|=128),a.resultType&=-17);return a.O&128} -function $f(a){a.resultType&32&&(a.O&=-2049,(a.ze^a.ye)&(a.hf^a.ye)&a.resultType&-2147450752&&(a.O|=2048),a.resultType&=-33);return a.O&2048}function cg(a){a.resultType&=-2;a.O&=-2}function hg(a){a.resultType&=-5;a.O&=-17}function ig(a){a.resultType&=-9;a.O&=-65}function eg(a){a.resultType&=-33;a.O&=-2049}function bg(a){a.resultType&=-2;a.O|=1}function jg(a){a.resultType&=-5;a.O|=16}function kg(a){a.resultType&=-9;a.O|=64}function dg(a){a.resultType&=-33;a.O|=2048} -function ie(a){return a.O&-2262|Vf(a)|Wf(a)|Xf(a)|Yf(a)|Zf(a)|$f(a)}function lg(a,b){b|=a.qa&1|65520;a.qa=a.qa&-65536|b&65535;a.qa&1&&ae(a,!0)}function je(a,b,c){a.qa&1||(b&=~a.si);void 0===c&&(c=a.Ma);c?b=b&-12289|a.O&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.O&512);a.resultType=128;a.O=a.O&~(a.Qd|2261)|b&(a.Qd|2261)|a.Ri;a.O&256&&(a.Za|=2,a.N|=4)} -function mg(a,b,c,d){var e=0;if(a.qa&1&&(a.Ma>a.lc||a.O&131072)&&a.la.Si)for(var f=a.la.Si+(b>>>3),e=(1<>>=8,f++;return e?(t(a,256)&&Cb(a,"checkIOPM("+ka(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),y.call(a,13,0),!1):!0} -l.Cb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.na[b]=c;this.tj++;a=!0;break;default:a=od.prototype.Cb.call(this,a,b,c)}return a}; -function ng(a,b,c,d){var e=(d?a.sc:a.aa)[(b&a.ed)>>>a.qb];e&&e.type==Uc&&(e=gd(a,b,!1,!0));if(e){var f=b&a.Db;if(!c||1==c)return e.Zd(f,b);if(2==c)return f>>this.qb].Bc(a&this.Db,a)}; +function Wd(a,b,c,d){void 0===c&&(c=!!(a.gc.qa&1));a.Oc=!1;if(c)if(a.load=a.qg,a.Cj=a.fn,a.bc=a.cj,a.cc=a.ej,void 0===d&&(d=!!(a.gc.O&131072)),d)a.load=a.G,a.bc=a.D,a.cc=a.F,a.Ab=a.qc=3,a.V=2,a.R=a.wa=65535,a.Ka=65535,a.Nb=a.Ka+1,a.Jc=a.V,a.Lb=-1,a.Pe=!1;else{if(!(a.U&-4))a.bc=a.kg,a.cc=a.lg;else if(a.type&4096){6144==(a.type&6656)&&(a.bc=a.kg);if(a.type&2048||!(a.type&512))a.cc=a.lg;1024==(a.type&3072)&&(a.bc==a.cj&&(a.bc=a.zl),a.cc==a.ej&&(a.cc=a.Al),a.Oc=!0);b&&a.id<$d&&a.U&-4&&-1!==a.Lb&&(c=a.Lb+ +5,d=a.gc.Ia(c),d&1||a.gc.fc(c,d|1))}b&&(a.Ab=a.U&3,a.qc=(a.jb&24576)>>13,80386>a.gc.ca||!(a.ext&64)?(a.V=2,a.R=65535):(a.V=4,a.R=-1),a.Jc=a.V,a.wa=a.R)}else a.load=a.mh,a.Cj=a.gn,a.bc=a.dj,a.cc=a.fj,a.Ab=a.qc=0,a.Lb=-1,a.Pe=!1}var ee=1,qe=2,ae=3,ce=4,$d=6,Yd=1; +function ze(a){var b=+a.model||8088,c;switch(b){default:c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}xd.call(this,a,c);this.ca=b;a=a.stepping;this.we=b+(a?oa(a,16):0);this.Ri=61442;this.Qd=1792;this.si=28672;this.Vf=4;this.Ta=255;this.B=80286<=this.ca?Qb:Pb;this.va=Ae;this.bj=Be;this.ij=Ce;this.nj=De;if(80186<=this.ca&&(this.va=Ae.slice(),this.bj=Be.slice(),this.ij=Ce.slice(),this.Ta=31,this.va[15]=Ee,this.va[96]=Fe,this.va[97]=Ge,this.va[98]=He,this.va[99]=Ee,this.va[100]=Ee,this.va[101]= +Ee,this.va[102]=Ee,this.va[103]=Ee,this.va[104]=Ie,this.va[105]=Je,this.va[106]=Ke,this.va[107]=Le,this.va[108]=Me,this.va[109]=Ne,this.va[110]=Oe,this.va[111]=Pe,this.va[192]=Qe,this.va[193]=Re,this.va[200]=Se,this.va[201]=Te,this.va[241]=Ue,this.bj[7]=Ve,this.ij[7]=Ve,80286<=this.ca)){this.Ri=2;this.Qd|=28672;this.Vf=0;this.va[15]=We;this.Pd=Xe.slice();for(b=0;b=this.we&&(this.Pd[166]=hf,this.Pd[167]=jf)}}this.Yf=[];this.Zf=[];this.ag=0;Ad(this);this.ea.complete=this.ea.jj=!1;this.tj=0;this.sc=this.aa=[];this.qb=this.Ng=this.Db=this.Wf=this.df=this.ef=this.ed=0;kf(this)}ba(ze,xd);function lf(a,b,c,d){b=(d?a.sc:a.aa)[b>>>a.qb];c?--b.ie||od(b):--b.he||nd(b);d&&tc(a)} +function mf(a){var b;if(a.aa===a.sc){a.aa=Array(a.Wf);a.$f=new x(null,0,0,cd,null,a);nc(a.$f,a.ba);for(b=0;b>>20,f=a.sc[(a.Wc+e&a.ef)>>>a.qb],g=f.Nd(e);if(!(g&1))return d||tf.call(a,b,!1,c),a.ff;if(!(g&4)&&3==a.Ma)return d||tf.call(a,b,!0,c),a.ff;var h=(b&4190208)>>>10,g=a.sc[((g&-4096)+h&a.ef)>>>a.qb],k=g.Nd(h);if(!(k&1))return d||tf.call(a,b,!1,c),a.ff;if(!(k&4)&&3==a.Ma)return d||tf.call(a,b,!0,c),a.ff;c=a.sc[((k&-4096)+(b&4095)&a.ef)>>>a.qb];if(d)return c;d=b>>>a.qb;k=a.aa[d];b&=-4096;var m;0>2;b.mb=g;b.B=h>>2;Ob&&Fc&&c.X&&!c.controller&&!c.he&&!c.ie?(b.Pa=c.Pa,b.Rd=c.Rd,b.X=c.X,Ac(b,wd)):(b.F=c?ud(32):0,b.J=c?ud(96):0,Ac(b,fd));nc(b,a.ba,k);a.aa[d]=b;a.Xf.push(d);return b}function uf(a){a.aa!==a.sc&&(a.aa=a.sc,a.$f=null,a.Xf=null,a.ff=null)}l=ze.prototype;l.reset=function(){this.ea.vb&&this.Jb();kf(this);Ad(this);this.ea.error=!1}; +function vf(a,b){var c;switch(b){case 0:c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.G;break;case 4:c=z(a);break;case 5:c=a.M;break;case 6:c=a.K;break;case 7:c=a.J}return c}function wf(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.G=c;break;case 4:he(a,c);break;case 5:a.M=c;break;case 6:a.K=c;break;case 7:a.J=c}} +function kf(a){a.D=0;a.G=0;a.I=0;a.L=0;a.Hc=0;a.M=0;a.K=0;a.J=0;a.vc=!1;a.Ba=a.$a=0;a.bn=[0,0];a.cn=[0,0];a.ya=0;a.sj=0;a.ga=0;a.qa=65520;a.Pb=0;a.cd=1023;a.O=a.lc=0;a.ze=a.hf=a.ye=a.Ae=0;a.Uc=-1;a.Ad=a.Vc=-1;a.Bd=a.ta=-1;a.Z=new Vd(a,ee,"CS");a.Ca=new Vd(a,qe,"DS");a.oa=new Vd(a,qe,"ES");a.Y=new Vd(a,ae,"SS");he(a,0);ge(a,0);if(80386<=a.ca){switch(a.we){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.qa=16;a.Og=0;a.Cd=0;a.Wc=0; +a.Qb=[0,0,0,0,null,null,0,0];a.dg=[null,null,null,null,null,null,0,0];a.Ga=new Vd(a,qe,"FS");a.Ha=new Vd(a,qe,"GS");uf(a)}a.Qg=new Vd(a,0,"NULL");a.Da=a.Ca;a.Rb=a.Y;a.N=a.ha=0;a.C=a.F=-1;a.eb=a.Qg;a.Za=0;if(80286>a.ca)te(a,0,65535);else{a.Kb=0;a.Pc=65535;a.Eb=new Vd(a,5,"LDT",!0);a.la=new Vd(a,ce,"TSS",!0);a.xb=new Vd(a,$d,"VER",!0);te(a,65520,61440);var b,c=A(a);b=a.Z;var d=-65536;80386>b.gc.ca&&(d&=16777215);b=b.ua=d;a.da=b+c|0;a.Pg=(b>>>0)+(a.Z.Ka>>>0)+1}se(a,0);je(a)} +function xf(a){2==a.Jc?(a.Sb=a.ja,a.kc=yf,a.tc=zf,a.kd=Af,2==a.V?(a.ma=Bf,a.za=Cf,a.rb=Df):(a.ma=Ef,a.za=Ff,a.rb=Gf)):(a.Sb=a.ia,a.kc=Hf,a.tc=If,a.kd=Jf,2==a.V?(a.ma=Kf,a.za=Lf,a.rb=Mf):(a.ma=Nf,a.za=Of,a.rb=Pf))}function ke(a,b){a.V!=b&&(a.ha|=1024,a.V=b,a.R=2==b?65535:-1,Qf(a))}function Qf(a){2==a.V?(a.Fb=32768,a.hb=a.ja,a.yb=a.fb,2==a.Jc?(a.ma=Bf,a.za=Cf,a.rb=Df):(a.ma=Kf,a.za=Lf,a.rb=Mf)):(a.Fb=-2147483648,a.hb=a.ia,a.yb=a.ab,2==a.Jc?(a.ma=Ef,a.za=Ff,a.rb=Gf):(a.ma=Nf,a.za=Of,a.rb=Pf))} +function Rf(a){a.Jc=a.Z.Jc;a.wa=a.Z.wa;xf(a);a.V=a.Z.V;a.R=a.Z.R;Qf(a);a.ha&=-3073}l.uj=function(){var a=this.D+this.G+this.I+this.L+z(this)+this.M+this.K+this.J|0;return a=a+A(this)+this.Z.U+this.Ca.U+this.Y.U+this.oa.U+re(this)|0};function Sf(a,b,c){void 0===a.Yf[b]&&(a.Yf[b]=[]);a.Yf[b].push(c)}function Tf(a,b,c){c&&(null==a.Zf[b]&&a.ag++,a.Zf[b]=c)}function Uf(a,b){var c=a.Zf[b];null!=c&&(c(--a.ag),delete a.Zf[b])} +function Vf(a,b){for(var c=a.Qb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Qb[e],g=g&~(d>>2&3);b?a.aa[g>>>a.qb].Gd(g&a.Db,f,a):(g=a.aa[g>>>a.qb],f?--g.ie||od(g):--g.he||nd(g))}c>>=2;d>>=4}}function rd(a,b,c,d){if(!(a.N&8192)&&a.Qb[7]&255){c--;var e=a.Qb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Qb[g]&&b<=a.Qb[g]+h){a.Qb[6]|=1<>=2;f>>=4}}} +function je(a,b,c){void 0===b&&(b=!!(a.qa&1));void 0===c&&(c=!!(a.O&131072));a.nj=b&&!c?Wf:De;Wd(a.Z,!1,b,c);Wd(a.Ca,!1,b,c);Wd(a.Y,!1,b,c);Wd(a.oa,!1,b,c);80386<=a.ca&&(Wd(a.Ga,!1,b,c),Wd(a.Ha,!1,b,c));Rf(a)} +l.save=function(){var a=new Xf(this);a.set(0,[this.D,this.G,this.I,this.L,z(this),this.M,this.K,this.J]);var b=A(this),c=this.Z.save(),d=this.Ca.save(),e=this.Y.save(),f=this.oa.save(),g;null!=this.Kb?(g=[this.qa,this.Kb,this.Pc,this.Pb,this.cd,this.Eb.save(),this.la.save(),this.lc],80386<=this.ca&&(g.push(this.Og),g.push(this.Cd),g.push(this.Wc),g.push(this.Qb),g.push(this.dg))):g=null;b=[b,c,d,e,f,g,re(this)];80386<=this.ca&&(b.push(this.Ga.save()),b.push(this.Ha.save()));a.set(1,b);a.set(2,[this.Da.$b, +this.Rb.$b,this.N,this.ha,this.Za,this.C,this.F]);a.set(3,[0,this.Dd,this.T.Kd]);a.set(4,Lc(this.ka,!!(this.qa&-2147483648)));return a.data()}; +l.restore=function(a){var b=a[0];this.D=b[0];this.G=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.M=b[5];this.K=b[6];this.J=b[7];b=a[1];this.Z.restore(b[1]);this.Ca.restore(b[2]);this.Y.restore(b[3]);this.oa.restore(b[4]);var d=b[5];d&&d.length&&(this.qa=d[0],this.Kb=d[1],this.Pc=d[2],this.Pb=d[3],this.cd=d[4],this.Eb.restore(d[5]),this.la.restore(d[6]),this.lc=d[7],80386<=this.ca&&(this.Og=d[8],this.Cd=d[9],this.Wc=d[10],this.Qb=d[11],this.dg=d[12]),je(this));se(this,b[6]);var d=!1,e;a:{e=this.ka; +var f=a[4],g;for(g=0;g>>0)+(a.Z.Ka>>>0)+1;a.Ma=a.Z.Ab;Rf(a)}function te(a,b,c,d){var e=a.Z;e.Jf=b;e.C=d;b=e.load(c);return-1!==b?($f(a,b+(a.Z.Jf&a.Z.R)),a.Z.Pe):null} +function ag(a,b){b=(a.da>>>0)+b;b>a.Pg&&(8088>=a.ca||a.Z.Ka==a.Z.wa?b=a.Z.ua+(b-a.Pg&a.R):y.call(a,13,0));return b|0}function bg(a){a.da=a.Bd}function z(a){return a.Hc&~a.Y.wa|a.Aa-a.Y.ua}function he(a,b){a.Hc=b;a.Aa=a.Y.ua+(b&a.Y.wa)|0}function cg(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&dg(a),g&2&&eg(a),g&4&&fg(a),g&8&&gg(a),g&16&&hg(a),g&32&&ig(a))}f?(a.ze=d,a.ye=b):(a.ze=b,a.ye=d);a.hf=c;a.Ae=d;a.resultType=e} +function jg(a,b,c,d,e){a.resultType=c|26;a.Ae=b;d?kg(a):lg(a);e?mg(a):ng(a);return b}function og(a,b,c,d){c&d?kg(a):lg(a);(b^c)&d?mg(a):ng(a)}function pg(a){return dg(a)?1:0}function dg(a){a.resultType&1&&(a.O&=-2,(a.ze^(a.ze^a.hf)&(a.hf^a.ye))&a.resultType&-2147450752&&(a.O|=1),a.resultType&=-2);return a.O&1}function eg(a){a.resultType&2&&(a.O&=-5,38505>>((a.Ae^a.Ae>>4)&15)&1&&(a.O|=4),a.resultType&=-3);return a.O&4} +function fg(a){a.resultType&4&&(a.O&=-17,(a.ye^a.ze^a.hf)&16&&(a.O|=16),a.resultType&=-5);return a.O&16}function gg(a){a.resultType&8&&(a.O&=-65,a.Ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.O|=64),a.resultType&=-9);return a.O&64}function hg(a){a.resultType&16&&(a.O&=-129,a.Ae&a.resultType&-2147450752&&(a.O|=128),a.resultType&=-17);return a.O&128} +function ig(a){a.resultType&32&&(a.O&=-2049,(a.ze^a.ye)&(a.hf^a.ye)&a.resultType&-2147450752&&(a.O|=2048),a.resultType&=-33);return a.O&2048}function lg(a){a.resultType&=-2;a.O&=-2}function qg(a){a.resultType&=-5;a.O&=-17}function rg(a){a.resultType&=-9;a.O&=-65}function ng(a){a.resultType&=-33;a.O&=-2049}function kg(a){a.resultType&=-2;a.O|=1}function ug(a){a.resultType&=-5;a.O|=16}function vg(a){a.resultType&=-9;a.O|=64}function mg(a){a.resultType&=-33;a.O|=2048} +function re(a){return a.O&-2262|dg(a)|eg(a)|fg(a)|gg(a)|hg(a)|ig(a)}function wg(a,b){b|=a.qa&1|65520;a.qa=a.qa&-65536|b&65535;a.qa&1&&je(a,!0)}function se(a,b,c){a.qa&1||(b&=~a.si);void 0===c&&(c=a.Ma);c?b=b&-12289|a.O&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.O&512);a.resultType=128;a.O=a.O&~(a.Qd|2261)|b&(a.Qd|2261)|a.Ri;a.O&256&&(a.Za|=2,a.N|=4)} +function xg(a,b,c,d){var e=0;if(a.qa&1&&(a.Ma>a.lc||a.O&131072)&&a.la.Si)for(var f=a.la.Si+(b>>>3),e=(1<>>=8,f++;return e?(t(a,256)&&Mb(a,"checkIOPM("+ta(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),y.call(a,13,0),!1):!0} +l.Cb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.na[b]=c;this.tj++;a=!0;break;default:a=xd.prototype.Cb.call(this,a,b,c)}return a}; +function yg(a,b,c,d){var e=(d?a.sc:a.aa)[(b&a.ed)>>>a.qb];e&&e.type==cd&&(e=td(a,b,!1,!0));if(e){var f=b&a.Db;if(!c||1==c)return e.Zd(f,b);if(2==c)return f>>this.qb].Bc(a&this.Db,a)}; l.ja=function(a){var b=a&this.Db,c=(a&this.ed)>>>this.qb;this.A-=this.B.zg;if(b>>this.qb;if(b>>this.qb].Dc(a&this.Db,b&255,a)}; l.fb=function(a,b){var c=a&this.Db,d=(a&this.ed)>>>this.qb;this.A-=this.B.zg;c>8&255,a+1))};l.ab=function(a,b){var c=a&this.Db,d=(a&this.ed)>>>this.qb;this.A-=this.B.zg;if(c>>=8}}; -function og(a,b,c){a.eb=b;a.wb=c&a.wa;a.C=b.bc(a.wb,1);return a.N&1?0:a.Ia(a.C)}function D(a,b){return og(a,a.Da,b)}function pg(a,b){return og(a,a.Rb,b)}function qg(a,b,c){a.eb=b;a.wb=c&a.wa;a.C=b.bc(a.wb,a.V);return a.N&1?0:a.hb(a.C)}function E(a,b){a.eb=a.Da;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,2);return a.N&1?0:a.ja(a.C)}function tg(a,b){a.eb=a.Rb;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,2);return a.N&1?0:a.ja(a.C)}function G(a,b){a.eb=a.Da;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,4);return a.N&1?0:a.ia(a.C)} -function ug(a,b){a.eb=a.Rb;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,4);return a.N&1?0:a.ia(a.C)}function vg(a,b){a.N&2||a.fc(a.eb.cc(a.wb,1),b)}function wg(a,b){a.N&2||a.fb(a.eb.cc(a.wb,2),b)}function xg(a,b){a.N&2||a.ab(a.eb.cc(a.wb,4),b)}function ce(a,b,c){return a.hb(b.bc(c,a.V))}l.ra=function(){var a=Sf(this,1),b=this.Ia(this.da);this.da=a;return b};function yg(a){var b=Sf(a,2),c=a.ja(a.da);a.da=b;return c}function J(a){var b=Sf(a,a.Jc),c=a.Sb(a.da);a.da=b;return c} -l.Ea=function(){var a=Sf(this,this.V),b=this.hb(this.da);this.da=a;return b};l.S=function(){var a=Sf(this,1),b=this.Ia(this.da)<<24>>24;this.da=a;return b};function Xd(a){var b=a.hb(a.Aa);a.Aa=a.Aa+a.V|0;var c=a.cg-a.Aa|0;0>c&&0<=(a.cg^a.Aa)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?Zd(a,a.Aa-a.Y.ua&a.Y.wa):-1>c&&y.call(a,12,0));return b} -function de(a,b,c,d){c=a.Aa-c|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(Zd(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));switch(d){case 1:a.fc(c,b);break;case 2:a.fb(c,b);break;case 4:a.ab(c,b)}a.Aa=c}function ge(a,b){var c=a.Aa-a.V|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(Zd(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));a.yb(c,b);a.Aa=c} -function zg(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.ca)2this.ca?0:1,e=0;2>e;e++){switch(d){case 0:if(this.Za&1&&this.O&512){var f=Bg(this.W);if(-1<=f&&(this.Za&=-2,0<=f)){this.Za&=-5; -Cg.call(this,f);d=!0;break a}}break;case 1:if(this.Za&2){this.Za&=-3;80386<=this.ca&&(this.Qb[6]|=16384);Cg.call(this,1);d=!0;break a}}d=1-d}d=!1}if(d&&!a){this.P("interrupt dispatched");this.N=0;break}if(this.Za&4){this.N=this.A=0;break}}if(b){if(Dg(this.ba,this.da,c)){this.Jb();break}c=1}this.N=0;this.va[this.ra()].call(this)}while(0>11;Ig(this);Jg(this,a[b++]);for(c=0;c=Kg&&Lg(a,Yg))}function Ig(a){a.fa&=-129;a.fa&~a.Zb&63&&(a.fa|=128);if(a.fa&128&&!(a.Zb&128))return a=a.W,a.ca>=Kg?Zg(a,Yg):a.da&$g||Cg.call(a.H,2),!0;a=a.W;a.ca>=Kg&&Lg(a,Yg);return!1}function ah(a,b){80387<=a.ca||(b&=-65);a.fa|=b;return Ig(a)} -function Gg(a){return a.fa|a.B<<11}function bh(a,b){return isFinite(b)?!0:!ah(a,Infinity===b?8:16)}function ch(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,bh(a,d)||(d=null));return d}function dh(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,bh(a,d)||(d=null));return d}function eh(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,bh(a,d)||(d=null));return d}function fh(a,b,c){var d=null;null==b||null==c||!c&&ah(a,2)||(d=b/c,bh(a,d)||(d=null));return d} -function gh(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:b||(d=16384));a.fa=a.fa&-18177|d;return!0}return!1}function hh(a,b,c){if(null==b)return null;var d=a.Zb&3072;d?d=1024==d||3072==d&&0=c){if(ah(a,1))return null;d=-c}else if(d<-c){if(ah(a,1))return null;d=-c}a.G[0]=d|0;2147483648d&&(a.G[1]=-1))}return d} -function ih(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function jh(a){var b=a.B+0&7;return a.C&1<>16}function oh(a){return a.H.ia(a.H.C)}function ph(a){a.ha[0]=a.H.ia(a.H.C);return a.Z[0]}function qh(a){a.G[0]=a.H.ia(a.H.C);a.G[1]=a.H.ia(a.H.C+4);return a.K[0]} -function rh(a){a.D[0]=a.H.ia(a.H.C);a.D[1]=a.H.ia(a.H.C+4);a.D[2]=a.H.ja(a.H.C+8);return a.D}l.mi=function(){this.H.ab(this.H.C,this.G[0])};l.bl=function(){this.H.ab(this.H.C,this.G[0]);this.H.ab(this.H.C+4,this.G[1])};function sh(a){a.H.ab(a.H.C,a.D[0]);a.H.ab(a.H.C+4,a.D[1]);a.H.fb(a.H.C+8,a.D[2])}function th(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.G[0]=b;a.G[1]=c|(d|e)<<20;return a.K[0]} -function mh(a,b,c){var d=c>>20&2047,e=2147483648|(c&1048575)<<11|b>>>21;2047==d?d=32767:d?d+=15360:e&=2147483647;a.D[0]=b<<11;a.D[1]=e;a.D[2]=c>>16&32768|d;return a.D}function uh(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function vh(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;Ig(a);Jg(a,d.hb(b+=d.V));!(d.qa&1)||d.O&131072?(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.O=c&2047,a.I|=(c&-4096)<<4,a.M=-1,a.J=d.hb(b+=d.V),a.J|=(d.hb(b+=d.V)&-4096)<<4,a.N=-1):(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.M=c&65535,a.O=c>>16&2047,a.J=d.hb(b+=d.V),a.N=d.hb(b+=d.V)&65535);return b+d.V} -function zh(a,b){var c=a.H;c.yb(b,a.Zb);c.yb(b+=c.V,Gg(a));c.yb(b+=c.V,Hg(a));if(!(c.qa&1)||c.O&131072){var d=(a.M<<4)+a.I;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096|a.O);d=(a.N<<4)+a.J;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096)}else c.yb(b+=c.V,a.I),c.yb(b+=c.V,a.M|a.O<<16),c.yb(b+=c.V,a.J),c.yb(b+=c.V,a.N);return b+c.V}function Ah(){this.fa&=-32896;Ig(this)}function Bh(){gh(this,M(this,0),M(this,this.A))}function Ch(){gh(this,M(this,0),M(this,this.A))&&wh(this)}function Dh(){Ch.call(this)} -function Eh(){N(this,0,fh(this,M(this,0),ph(this)))}function Fh(){this.C&=~(1<>20&2047)-1023),this.G[1]=(this.G[1]|1072693248)&-1073741825,xh(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.fa&=-513},103:function(){this.B= -this.B+1&7;this.fa&=-513},112:function(){N(this,0,M(this,0)%M(this,1))},113:function(){N(this,1,M(this,1)*Math.log(M(this,0)+1)/Math.LN2)&&wh(this)},114:function(){var a=M(this,0),b=null;if(0<=a||!ah(this,1))b=Math.sqrt(a),bh(this,b)||(b=null);N(this,0,b)},116:function(){N(this,0,hh(this,M(this,0),Yh))},117:function(){var a=M(this,0),b=M(this,1);null!=a&&null!=b&&N(this,0,a*Math.pow(2,0>>0);xh(this,a)},6:function(){var a=hh(this,wh(this));null!=a&&(this.D[0]=vh(a,8),this.D[1]=vh(a/1E8,8),this.D[2]=vh(a/1E16,2),0>a&&(this.D[2]|=32768),sh(this))},7:function(){null!=hh(this,M(this,0),Yh)&&(this.bl(),wh(this))},48:function(){Fh.call(this);wh(this)},49:Sh,50:Nh,51:Nh,52:Qh}},$h=[Ah,Gh,Hh,Ih,Jh,Kh,Oh,Lh,Ph,Qh];Ra(function(){for(var a=pb(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Ij;(bd)&&y.call(this,5);this.N|=2;return a}function ii(a,b){var c=0;if(b){ig(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else kg(this);this.A-=11+3*c;return a}function ji(a,b){var c=0;if(b){ig(this);for(var d=2==this.V?15:31,e=1<>>=1;c++;d--}}else kg(this);this.A-=11+3*c;return a} -function ki(a,b){a&1<<(b&(2==this.V?15:31))?bg(this):cg(this);this.A-=-1===this.C?3:6;this.N|=2;return a}function li(a,b){b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=-1===this.C?6:8;return a^b}function mi(a,b){b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=-1===this.C?6:8;return a&~b}function ni(a,b){b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=-1===this.C?6:8;return a|b} -function oi(a,b){if(-1===this.C)return ki.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=qg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=6;this.N|=2;return a}function pi(a,b){if(-1===this.C)return li.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=qg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=8;return a^b} -function qi(a,b){if(-1===this.C)return mi.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=qg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=8;return a&~b}function ri(a,b){if(-1===this.C)return ni.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=qg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?bg(this):cg(this);this.A-=8;return a|b} -function si(a,b){Uf(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a}function ti(a,b){Uf(this,a,b,a-b|0,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a} -function ui(a){if(this.Tc){var b=this.Tc,c=this.sj,d=this.ga,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=Zh[c][f]){if(0>$h.indexOf(e)){var f=b.H,g=f.Bd;8087==b.ca&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.Z.U;b.I=g-f.Z.ua;-1!==f.C&&(b.N=f.eb.U,b.J=f.C-f.eb.ua);b.O=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function vi(a){if(80186>this.ca)return wi.call(this,a);y.call(this,13,0);return a}function Me(a){y.call(this,6);return a} -function wi(a){Pe.call(this);return a}function xi(a,b){a=yi.call(this,this.S(),b);80386>this.ca&&(this.A-=12);return a}function zi(a,b){a=this.Ea();a=2==this.V?yi.call(this,a,b):Ai.call(this,a,b);80386>this.ca&&(this.A-=12);return a}function Bi(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);Ci.call(this,a,b);c&&(this.Ba=~this.Ba+1|0,this.$a=~this.$a+(this.Ba?0:1)|0)} -function yi(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(bg(this),dg(this)):(cg(this),eg(this));this.A-=-1===this.C?9:12;return a&65535}function Ai(a,b){Bi.call(this,a,b);this.$a!=this.Ba>>31?(bg(this),dg(this)):(cg(this),eg(this));this.A-=-1===this.C?9:12;return this.Ba}function Di(a,b){this.A-=14+(-1===this.C?0:2);ig(this);-1!==this.xb.load(b)&&this.xb.qc>=this.Ma&&this.xb.qc>=(b&3)&&(kg(this),a=this.xb.jb&-256,2=this.Ma)&&this.xb.qc>=(b&3))return kg(this),this.xb.Ka;ig(this);return a}function Ki(a,b){if(-1===this.C)return Pe.call(this),a;Yd(this,this.ja(this.C+this.V));this.A-=this.B.Xe;return b} -function Li(a,b){this.A-=-1===this.F?-1===this.C?this.B.sk:this.B.rk:this.B.pk;return b}function Mi(a,b){switch(this.ga>>3&7){case 4:this.ya=this.D;break;case 5:this.ya=this.I;break;case 6:this.ya=this.L;break;case 7:this.ya=this.G}return b}function Ni(a,b){return b} -function Oi(a,b){a=this.ga>>3&7;switch(a){case 0:this.ya=this.D;break;case 2:this.ya=this.L;break;case 3:this.ya=this.G;break;default:if(80286==this.ca||80386==this.ca&&4!=a&&5!=a)y.call(this,6);else switch(a){case 1:this.ya=this.I;break;case 4:this.ya=z(this);break;case 5:this.ya=this.M;break;case 6:this.ya=this.K;break;case 7:this.ya=this.J}}return Li.call(this,0,b)} -function Pi(a,b){switch(this.ga>>3&7){case 0:b=this.oa.U;break;case 1:b=this.Z.U;break;case 2:b=this.Y.U;break;case 3:b=this.Ca.U;break;case 4:if(80386<=this.ca){b=this.Ga.U;break}y.call(this,6);b=a;break;case 5:if(80386<=this.ca){b=this.Ha.U;break}default:y.call(this,6),b=a}-1!==this.F&&be(this,2);return Li.call(this,0,b)} -function Ci(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d,d=(e>>>16)+b*d,f=d>>>16,d=(d&65535)+c*a;this.Ba=d<<16|e&65535;this.$a=f+((d>>>16)+b*a)|0}else this.Ba=a*b|0,this.$a=0}function Qi(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return ag(this,a|b,128)}function aj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return ag(this,a|b,this.Fb)&this.R} -function bj(a,b){var c=a-b-gg(this)|0;Uf(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255}function cj(a,b){var c=a-b-gg(this)|0;Uf(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function dj(){return $f(this)?1:0}function ej(){return Vf(this)?1:0}function fj(){return Vf(this)?0:1}function gj(){return Yf(this)?1:0}function hj(){return Yf(this)?0:1}function ij(){return Vf(this)||Yf(this)?1:0} -function jj(){return Vf(this)||Yf(this)?0:1}function kj(){return Zf(this)?1:0}function lj(){return Zf(this)?0:1}function mj(){return Wf(this)?1:0}function nj(){return Wf(this)?0:1}function oj(){return!Zf(this)!=!$f(this)?1:0}function pj(){return!Zf(this)!=!$f(this)?0:1}function qj(){return Yf(this)||!Zf(this)!=!$f(this)?1:0}function rj(){return Yf(this)||!Zf(this)!=!$f(this)?0:1}function sj(a,b){return tj.call(this,a,b,this.ra())}function uj(a,b){return vj.call(this,a,b,this.ra())} -function wj(a,b){return tj.call(this,a,b,this.I&31)}function xj(a,b){return vj.call(this,a,b,this.I&31)}function yj(a,b){return zj.call(this,a,b,this.ra())}function Aj(a,b){return Bj.call(this,a,b,this.ra())}function Cj(a,b){return zj.call(this,a,b,this.I&31)}function Dj(a,b){return Bj.call(this,a,b,this.I&31)}function Ej(a,b){var c=a-b|0;Uf(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255} -function Fj(a,b){var c=a-b|0;Uf(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function Gj(a,b){ag(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Hj(a,b){ag(this,a&b,this.Fb);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Ij(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Kj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}this.A-=this.B.di}else this.F=this.C,vg(this,a),this.A-=this.B.ci;return b} -function Lj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.G=this.G&~this.R|a;break;case 4:Zd(this,z(this)&~this.R|a);break;case 5:this.M=this.G&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.di}else this.F=this.C,this.N&2||this.yb(this.eb.cc(this.wb,this.V),a),this.A-=this.B.ci;return b} -function Mj(a,b){a^=b;ag(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return a}function Nj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return ag(this,a^b,this.Fb)&this.R}function Oj(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function Pj(a){var b=a-1|0;Uf(this,a,1,b,this.Fb|62,!0);this.A-=2;return a&~this.R|b&this.R} -function Qj(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.bn;f[0]=c>>>0;f[1]=0;c=this.cn;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=Oj(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ba=d;this.$a=c[0];return!0}function Rj(a){var b=a+1|0;Uf(this,a,1,b,this.Fb|62);this.A-=2;return a&~this.R|b&this.R} -function Sj(a){this.qa=a;ae(this);this.qa&-2147483648?$e(this):ff(this)}function le(a){this.Wc=a;jc(this)}function Tj(a){this.N|=1;this.tc.call(this,a);this.A-=-1===this.C?4:5}function tj(a,b,c){if(c){16>>16-c)&65535;ag(this,a,32768,d&32768)}return a}function vj(a,b,c){if(c){var d=a<>>32-c;ag(this,a,-2147483648,d&-2147483648)}return a} -function zj(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;ag(this,a,32768,d&1)}return a}function Bj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;ag(this,a,-2147483648,d&1)}return a}function Uj(){this.A-=-1===this.C?2:this.B.Fk;return 1}function Vj(){var a=this.I&255;this.A-=(-1===this.C?this.B.Vh:this.B.Uh)+(a<this.Uc?(-1!=this.Ad&&(this.Ad!==this.Z.U&&(this.Z.Ab=this.Ad&3,Qf(this,this.Ad)),this.Ad=-1),this.Bd!==this.da&&Rf(this,this.Bd),-1!=this.Vc&&(this.Vc!==this.Y.U&&Yd(this,this.Vc),this.Vc=-1),-1!==this.ta&&(this.ta!==this.Aa&&Zd(this,this.Hc&~this.Y.wa|this.ta-this.Y.ua),this.ta=-1)):8!=this.Uc?(b=0,a=8):(b=0,a=-1,Ye(this),e=d=!1)):Rf(this,this.Bd);var f=a,g=b,h=32,k=ng(this,this.da);204!=k||this.cd||(d=!1);this.O&131072&&(6== -f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.da&&1048575>=this.da&&(d=!1);t(this,h|-2147483648)&&(d=!0);if(t(this,h)||d){var m=this.ea.vb,f="Fault "+r(f)+(null!=g?" ("+ka(g)+")":"")+" on opcode "+r(k);d&&m&&(f+=" (blocked)");this.ba?(Cb(this,f,d||h,!0),d&&(d=m,this.ba.Jb())):(this.Fa(f),this.Jb())}if(d&&e)throw-1;if(e)throw this.Uc=a,ak.call(this,a,b,c),this.Bd=this.da,this.N=1==a?this.N|8192:this.N|4096,a;} -function ef(a,b,c){this.Cd=a;a=0;b&&(a|=1);c&&(a|=2);3==this.Ma&&(a|=4);y.call(this,14,a)}function ck(a){var b=a.jb&7680;a.U&65528&&(6144==b||7168==b||7168>b&&a.qc>24;this.da=a;return b};function fe(a){var b=a.hb(a.Aa);a.Aa=a.Aa+a.V|0;var c=a.cg-a.Aa|0;0>c&&0<=(a.cg^a.Aa)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?he(a,a.Aa-a.Y.ua&a.Y.wa):-1>c&&y.call(a,12,0));return b} +function me(a,b,c,d){c=a.Aa-c|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(he(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));switch(d){case 1:a.fc(c,b);break;case 2:a.fb(c,b);break;case 4:a.ab(c,b)}a.Aa=c}function pe(a,b){var c=a.Aa-a.V|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(he(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));a.yb(c,b);a.Aa=c} +function Ig(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.ca)2this.ca?0:1,e=0;2>e;e++){switch(d){case 0:if(this.Za&1&&this.O&512){var f=Kg(this.W);if(-1<=f&&(this.Za&=-2,0<=f)){this.Za&=-5; +Lg.call(this,f);d=!0;break a}}break;case 1:if(this.Za&2){this.Za&=-3;80386<=this.ca&&(this.Qb[6]|=16384);Lg.call(this,1);d=!0;break a}}d=1-d}d=!1}if(d&&!a){this.P("interrupt dispatched");this.N=0;break}if(this.Za&4){this.N=this.A=0;break}}if(b){if(Mg(this.ba,this.da,c)){this.Jb();break}c=1}this.N=0;this.va[this.ra()].call(this)}while(0>11;ch(this);dh(this,a[b++]);for(c=0;c=eh&&fh(a,gh))}function ch(a){a.fa&=-129;a.fa&~a.Zb&63&&(a.fa|=128);if(a.fa&128&&!(a.Zb&128))return a=a.W,a.ca>=eh?hh(a,gh):a.da&ih||Lg.call(a.H,2),!0;a=a.W;a.ca>=eh&&fh(a,gh);return!1}function jh(a,b){80387<=a.ca||(b&=-65);a.fa|=b;return ch(a)} +function ah(a){return a.fa|a.B<<11}function kh(a,b){return isFinite(b)?!0:!jh(a,Infinity===b?8:16)}function lh(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,kh(a,d)||(d=null));return d}function mh(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,kh(a,d)||(d=null));return d}function nh(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,kh(a,d)||(d=null));return d}function oh(a,b,c){var d=null;null==b||null==c||!c&&jh(a,2)||(d=b/c,kh(a,d)||(d=null));return d} +function ph(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:b||(d=16384));a.fa=a.fa&-18177|d;return!0}return!1}function qh(a,b,c){if(null==b)return null;var d=a.Zb&3072;d?d=1024==d||3072==d&&0=c){if(jh(a,1))return null;d=-c}else if(d<-c){if(jh(a,1))return null;d=-c}a.G[0]=d|0;2147483648d&&(a.G[1]=-1))}return d} +function rh(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function sh(a){var b=a.B+0&7;return a.C&1<>16}function xh(a){return a.H.ia(a.H.C)}function yh(a){a.ha[0]=a.H.ia(a.H.C);return a.Z[0]}function zh(a){a.G[0]=a.H.ia(a.H.C);a.G[1]=a.H.ia(a.H.C+4);return a.K[0]} +function Ah(a){a.D[0]=a.H.ia(a.H.C);a.D[1]=a.H.ia(a.H.C+4);a.D[2]=a.H.ja(a.H.C+8);return a.D}l.mi=function(){this.H.ab(this.H.C,this.G[0])};l.bl=function(){this.H.ab(this.H.C,this.G[0]);this.H.ab(this.H.C+4,this.G[1])};function Bh(a){a.H.ab(a.H.C,a.D[0]);a.H.ab(a.H.C+4,a.D[1]);a.H.fb(a.H.C+8,a.D[2])}function Ch(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.G[0]=b;a.G[1]=c|(d|e)<<20;return a.K[0]} +function vh(a,b,c){var d=c>>20&2047,e=2147483648|(c&1048575)<<11|b>>>21;2047==d?d=32767:d?d+=15360:e&=2147483647;a.D[0]=b<<11;a.D[1]=e;a.D[2]=c>>16&32768|d;return a.D}function Dh(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function Eh(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;ch(a);dh(a,d.hb(b+=d.V));!(d.qa&1)||d.O&131072?(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.O=c&2047,a.I|=(c&-4096)<<4,a.M=-1,a.J=d.hb(b+=d.V),a.J|=(d.hb(b+=d.V)&-4096)<<4,a.N=-1):(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.M=c&65535,a.O=c>>16&2047,a.J=d.hb(b+=d.V),a.N=d.hb(b+=d.V)&65535);return b+d.V} +function Ih(a,b){var c=a.H;c.yb(b,a.Zb);c.yb(b+=c.V,ah(a));c.yb(b+=c.V,bh(a));if(!(c.qa&1)||c.O&131072){var d=(a.M<<4)+a.I;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096|a.O);d=(a.N<<4)+a.J;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096)}else c.yb(b+=c.V,a.I),c.yb(b+=c.V,a.M|a.O<<16),c.yb(b+=c.V,a.J),c.yb(b+=c.V,a.N);return b+c.V}function Jh(){this.fa&=-32896;ch(this)}function Kh(){ph(this,M(this,0),M(this,this.A))}function Lh(){ph(this,M(this,0),M(this,this.A))&&Fh(this)}function Mh(){Lh.call(this)} +function Nh(){N(this,0,oh(this,M(this,0),yh(this)))}function Oh(){this.C&=~(1<>20&2047)-1023),this.G[1]=(this.G[1]|1072693248)&-1073741825,Gh(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.fa&=-513},103:function(){this.B= +this.B+1&7;this.fa&=-513},112:function(){N(this,0,M(this,0)%M(this,1))},113:function(){N(this,1,M(this,1)*Math.log(M(this,0)+1)/Math.LN2)&&Fh(this)},114:function(){var a=M(this,0),b=null;if(0<=a||!jh(this,1))b=Math.sqrt(a),kh(this,b)||(b=null);N(this,0,b)},116:function(){N(this,0,qh(this,M(this,0),gi))},117:function(){var a=M(this,0),b=M(this,1);null!=a&&null!=b&&N(this,0,a*Math.pow(2,0>>0);Gh(this,a)},6:function(){var a=qh(this,Fh(this));null!=a&&(this.D[0]=Eh(a,8),this.D[1]=Eh(a/1E8,8),this.D[2]=Eh(a/1E16,2),0>a&&(this.D[2]|=32768),Bh(this))},7:function(){null!=qh(this,M(this,0),gi)&&(this.bl(),Fh(this))},48:function(){Oh.call(this);Fh(this)},49:ai,50:Wh,51:Wh,52:Zh}},ii=[Jh,Ph,Qh,Rh,Sh,Th,Xh,Uh,Yh,Zh];ab(function(){for(var a=Ab(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Ij;(bd)&&y.call(this,5);this.N|=2;return a}function ri(a,b){var c=0;if(b){rg(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else vg(this);this.A-=11+3*c;return a}function si(a,b){var c=0;if(b){rg(this);for(var d=2==this.V?15:31,e=1<>>=1;c++;d--}}else vg(this);this.A-=11+3*c;return a} +function ti(a,b){a&1<<(b&(2==this.V?15:31))?kg(this):lg(this);this.A-=-1===this.C?3:6;this.N|=2;return a}function ui(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a^b}function vi(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a&~b}function wi(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a|b} +function xi(a,b){if(-1===this.C)return ti.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=6;this.N|=2;return a}function yi(a,b){if(-1===this.C)return ui.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a^b} +function zi(a,b){if(-1===this.C)return vi.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a&~b}function Ai(a,b){if(-1===this.C)return wi.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a|b} +function Bi(a,b){cg(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a}function Ci(a,b){cg(this,a,b,a-b|0,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a} +function Di(a){if(this.Tc){var b=this.Tc,c=this.sj,d=this.ga,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=hi[c][f]){if(0>ii.indexOf(e)){var f=b.H,g=f.Bd;8087==b.ca&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.Z.U;b.I=g-f.Z.ua;-1!==f.C&&(b.N=f.eb.U,b.J=f.C-f.eb.ua);b.O=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function Ei(a){if(80186>this.ca)return Fi.call(this,a);y.call(this,13,0);return a}function Ve(a){y.call(this,6);return a} +function Fi(a){Ye.call(this);return a}function Gi(a,b){a=Hi.call(this,this.S(),b);80386>this.ca&&(this.A-=12);return a}function Ii(a,b){a=this.Ea();a=2==this.V?Hi.call(this,a,b):Ji.call(this,a,b);80386>this.ca&&(this.A-=12);return a}function Ki(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);Li.call(this,a,b);c&&(this.Ba=~this.Ba+1|0,this.$a=~this.$a+(this.Ba?0:1)|0)} +function Hi(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(kg(this),mg(this)):(lg(this),ng(this));this.A-=-1===this.C?9:12;return a&65535}function Ji(a,b){Ki.call(this,a,b);this.$a!=this.Ba>>31?(kg(this),mg(this)):(lg(this),ng(this));this.A-=-1===this.C?9:12;return this.Ba}function Mi(a,b){this.A-=14+(-1===this.C?0:2);rg(this);-1!==this.xb.load(b)&&this.xb.qc>=this.Ma&&this.xb.qc>=(b&3)&&(vg(this),a=this.xb.jb&-256,2=this.Ma)&&this.xb.qc>=(b&3))return vg(this),this.xb.Ka;rg(this);return a}function cj(a,b){if(-1===this.C)return Ye.call(this),a;ge(this,this.ja(this.C+this.V));this.A-=this.B.Xe;return b} +function dj(a,b){this.A-=-1===this.F?-1===this.C?this.B.sk:this.B.rk:this.B.pk;return b}function ej(a,b){switch(this.ga>>3&7){case 4:this.ya=this.D;break;case 5:this.ya=this.I;break;case 6:this.ya=this.L;break;case 7:this.ya=this.G}return b}function fj(a,b){return b} +function gj(a,b){a=this.ga>>3&7;switch(a){case 0:this.ya=this.D;break;case 2:this.ya=this.L;break;case 3:this.ya=this.G;break;default:if(80286==this.ca||80386==this.ca&&4!=a&&5!=a)y.call(this,6);else switch(a){case 1:this.ya=this.I;break;case 4:this.ya=z(this);break;case 5:this.ya=this.M;break;case 6:this.ya=this.K;break;case 7:this.ya=this.J}}return dj.call(this,0,b)} +function hj(a,b){switch(this.ga>>3&7){case 0:b=this.oa.U;break;case 1:b=this.Z.U;break;case 2:b=this.Y.U;break;case 3:b=this.Ca.U;break;case 4:if(80386<=this.ca){b=this.Ga.U;break}y.call(this,6);b=a;break;case 5:if(80386<=this.ca){b=this.Ha.U;break}default:y.call(this,6),b=a}-1!==this.F&&ke(this,2);return dj.call(this,0,b)} +function Li(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d,d=(e>>>16)+b*d,f=d>>>16,d=(d&65535)+c*a;this.Ba=d<<16|e&65535;this.$a=f+((d>>>16)+b*a)|0}else this.Ba=a*b|0,this.$a=0}function ij(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a|b,128)}function jj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a|b,this.Fb)&this.R} +function kj(a,b){var c=a-b-pg(this)|0;cg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255}function lj(a,b){var c=a-b-pg(this)|0;cg(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function mj(){return ig(this)?1:0}function nj(){return dg(this)?1:0}function oj(){return dg(this)?0:1}function pj(){return gg(this)?1:0}function qj(){return gg(this)?0:1}function rj(){return dg(this)||gg(this)?1:0} +function sj(){return dg(this)||gg(this)?0:1}function tj(){return hg(this)?1:0}function uj(){return hg(this)?0:1}function vj(){return eg(this)?1:0}function wj(){return eg(this)?0:1}function xj(){return!hg(this)!=!ig(this)?1:0}function yj(){return!hg(this)!=!ig(this)?0:1}function zj(){return gg(this)||!hg(this)!=!ig(this)?1:0}function Aj(){return gg(this)||!hg(this)!=!ig(this)?0:1}function Bj(a,b){return Cj.call(this,a,b,this.ra())}function Dj(a,b){return Ej.call(this,a,b,this.ra())} +function Fj(a,b){return Cj.call(this,a,b,this.I&31)}function Gj(a,b){return Ej.call(this,a,b,this.I&31)}function Hj(a,b){return Ij.call(this,a,b,this.ra())}function Jj(a,b){return Kj.call(this,a,b,this.ra())}function Lj(a,b){return Ij.call(this,a,b,this.I&31)}function Mj(a,b){return Kj.call(this,a,b,this.I&31)}function Nj(a,b){var c=a-b|0;cg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255} +function Oj(a,b){var c=a-b|0;cg(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function Pj(a,b){jg(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Qj(a,b){jg(this,a&b,this.Fb);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Rj(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Tj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}this.A-=this.B.di}else this.F=this.C,Eg(this,a),this.A-=this.B.ci;return b} +function Uj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.G=this.G&~this.R|a;break;case 4:he(this,z(this)&~this.R|a);break;case 5:this.M=this.G&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.di}else this.F=this.C,this.N&2||this.yb(this.eb.cc(this.wb,this.V),a),this.A-=this.B.ci;return b} +function Vj(a,b){a^=b;jg(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return a}function Wj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a^b,this.Fb)&this.R}function Xj(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function Yj(a){var b=a-1|0;cg(this,a,1,b,this.Fb|62,!0);this.A-=2;return a&~this.R|b&this.R} +function Zj(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.bn;f[0]=c>>>0;f[1]=0;c=this.cn;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=Xj(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ba=d;this.$a=c[0];return!0}function ak(a){var b=a+1|0;cg(this,a,1,b,this.Fb|62);this.A-=2;return a&~this.R|b&this.R} +function bk(a){this.qa=a;je(this);this.qa&-2147483648?mf(this):uf(this)}function ue(a){this.Wc=a;tc(this)}function ck(a){this.N|=1;this.tc.call(this,a);this.A-=-1===this.C?4:5}function Cj(a,b,c){if(c){16>>16-c)&65535;jg(this,a,32768,d&32768)}return a}function Ej(a,b,c){if(c){var d=a<>>32-c;jg(this,a,-2147483648,d&-2147483648)}return a} +function Ij(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;jg(this,a,32768,d&1)}return a}function Kj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;jg(this,a,-2147483648,d&1)}return a}function dk(){this.A-=-1===this.C?2:this.B.Fk;return 1}function ek(){var a=this.I&255;this.A-=(-1===this.C?this.B.Vh:this.B.Uh)+(a<this.Uc?(-1!=this.Ad&&(this.Ad!==this.Z.U&&(this.Z.Ab=this.Ad&3,Zf(this,this.Ad)),this.Ad=-1),this.Bd!==this.da&&$f(this,this.Bd),-1!=this.Vc&&(this.Vc!==this.Y.U&&ge(this,this.Vc),this.Vc=-1),-1!==this.ta&&(this.ta!==this.Aa&&he(this,this.Hc&~this.Y.wa|this.ta-this.Y.ua),this.ta=-1)):8!=this.Uc?(b=0,a=8):(b=0,a=-1,kf(this),e=d=!1)):$f(this,this.Bd);var f=a,g=b,h=32,k=yg(this,this.da);204!=k||this.cd||(d=!1);this.O&131072&&(6== +f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.da&&1048575>=this.da&&(d=!1);t(this,h|-2147483648)&&(d=!0);if(t(this,h)||d){var m=this.ea.vb,f="Fault "+r(f)+(null!=g?" ("+ta(g)+")":"")+" on opcode "+r(k);d&&m&&(f+=" (blocked)");this.ba?(Mb(this,f,d||h,!0),d&&(d=m,this.ba.Jb())):(this.Fa(f),this.Jb())}if(d&&e)throw-1;if(e)throw this.Uc=a,jk.call(this,a,b,c),this.Bd=this.da,this.N=1==a?this.N|8192:this.N|4096,a;} +function tf(a,b,c){this.Cd=a;a=0;b&&(a|=1);c&&(a|=2);3==this.Ma&&(a|=4);y.call(this,14,a)}function lk(a){var b=a.jb&7680;a.U&65528&&(6144==b||7168==b||7168>b&&a.qc>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&255;break;case 1:b=this.I&255;break;case 2:b=this.L&255;break;case 3:b=this.G&255;break;case 4:b=this.D>>8&255;break;case 5:b=this.I>>8&255;break;case 6:b=this.L>>8&255;break;case 7:b=this.G>>8&255;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} -function lf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.G+this.K);this.F=this.C;break;case 1:b=D(this,this.G+this.J);this.F=this.C;break;case 2:b=pg(this,this.M+this.K);this.F=this.C;break;case 3:b=pg(this,this.M+this.J);this.F=this.C;break;case 4:b=D(this,this.K);this.F=this.C;break;case 5:b=D(this,this.J);this.F=this.C;break;case 6:b=D(this,J(this));this.F=this.C;break;case 7:b=D(this,this.G);this.F=this.C;break;case 64:b=D(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:b=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=pg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=pg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=D(this,this.K+this.S());this.F=this.C;break;case 69:b=D(this,this.J+this.S());this.F=this.C;break;case 70:b=pg(this,this.M+this.S());this.F=this.C;break;case 71:b=D(this,this.G+this.S());this.F=this.C;break;case 128:b=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=D(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:b=pg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=pg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=D(this,this.K+J(this));this.F=this.C;break;case 133:b=D(this,this.J+J(this));this.F=this.C;break;case 134:b=pg(this,this.M+J(this));this.F=this.C;break;case 135:b=D(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break; -case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.G>>8&255;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&255;break;case 1:c=this.I&255;break;case 2:c=this.L&255;break;case 3:c=this.G&255;break;case 4:c=this.D>>8&255;break;case 5:c=this.I>>8&255;break;case 6:c=this.L>>8&255;break;case 7:c=this.G>>8&255;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:vg(this,a);this.A-=this.B.Rc;break;case 1:case 2:vg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:vg(this, -a);this.A-=this.B.wc;break;case 6:vg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:vg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:vg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:vg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= +function zf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.G+this.K);this.F=this.C;break;case 1:b=D(this,this.G+this.J);this.F=this.C;break;case 2:b=Ag(this,this.M+this.K);this.F=this.C;break;case 3:b=Ag(this,this.M+this.J);this.F=this.C;break;case 4:b=D(this,this.K);this.F=this.C;break;case 5:b=D(this,this.J);this.F=this.C;break;case 6:b=D(this,J(this));this.F=this.C;break;case 7:b=D(this,this.G);this.F=this.C;break;case 64:b=D(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Ag(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Ag(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=D(this,this.K+this.S());this.F=this.C;break;case 69:b=D(this,this.J+this.S());this.F=this.C;break;case 70:b=Ag(this,this.M+this.S());this.F=this.C;break;case 71:b=D(this,this.G+this.S());this.F=this.C;break;case 128:b=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=D(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Ag(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Ag(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=D(this,this.K+J(this));this.F=this.C;break;case 133:b=D(this,this.J+J(this));this.F=this.C;break;case 134:b=Ag(this,this.M+J(this));this.F=this.C;break;case 135:b=D(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break; +case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.G>>8&255;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&255;break;case 1:c=this.I&255;break;case 2:c=this.L&255;break;case 3:c=this.G&255;break;case 4:c=this.D>>8&255;break;case 5:c=this.I>>8&255;break;case 6:c=this.L>>8&255;break;case 7:c=this.G>>8&255;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Eg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Eg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Eg(this, +a);this.A-=this.B.wc;break;case 6:Eg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Eg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Eg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Eg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} -function rf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.G+this.K);this.F=this.C;break;case 1:c=D(this,this.G+this.J);this.F=this.C;break;case 2:c=pg(this,this.M+this.K);this.F=this.C;break;case 3:c=pg(this,this.M+this.J);this.F=this.C;break;case 4:c=D(this,this.K);this.F=this.C;break;case 5:c=D(this,this.J);this.F=this.C;break;case 6:c=D(this,J(this));this.F=this.C;break;case 7:c=D(this,this.G);this.F=this.C;break;case 64:c=D(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:c=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=pg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=pg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=D(this,this.K+this.S());this.F=this.C;break;case 69:c=D(this,this.J+this.S());this.F=this.C;break;case 70:c=pg(this,this.M+this.S());this.F=this.C;break;case 71:c=D(this,this.G+this.S());this.F=this.C;break;case 128:c=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=D(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:c=pg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=pg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=D(this,this.K+J(this));this.F=this.C;break;case 133:c=D(this,this.J+J(this));this.F=this.C;break;case 134:c=pg(this,this.M+J(this));this.F=this.C;break;case 135:c=D(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break; -case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:vg(this,a);this.A-=this.B.Rc;break;case 1:case 2:vg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:vg(this,a);this.A-=this.B.wc;break;case 6:vg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:vg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:vg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:vg(this, +function Af(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.G+this.K);this.F=this.C;break;case 1:c=D(this,this.G+this.J);this.F=this.C;break;case 2:c=Ag(this,this.M+this.K);this.F=this.C;break;case 3:c=Ag(this,this.M+this.J);this.F=this.C;break;case 4:c=D(this,this.K);this.F=this.C;break;case 5:c=D(this,this.J);this.F=this.C;break;case 6:c=D(this,J(this));this.F=this.C;break;case 7:c=D(this,this.G);this.F=this.C;break;case 64:c=D(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Ag(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Ag(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=D(this,this.K+this.S());this.F=this.C;break;case 69:c=D(this,this.J+this.S());this.F=this.C;break;case 70:c=Ag(this,this.M+this.S());this.F=this.C;break;case 71:c=D(this,this.G+this.S());this.F=this.C;break;case 128:c=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=D(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Ag(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Ag(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=D(this,this.K+J(this));this.F=this.C;break;case 133:c=D(this,this.J+J(this));this.F=this.C;break;case 134:c=Ag(this,this.M+J(this));this.F=this.C;break;case 135:c=D(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break; +case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Eg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Eg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Eg(this,a);this.A-=this.B.wc;break;case 6:Eg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Eg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Eg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Eg(this, a);this.A-=this.B.Va;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} -function sf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=E(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=tg(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=tg(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=E(this,this.K);this.A-=this.B.wc;break;case 5:c=E(this,this.J);this.A-=this.B.wc;break;case 6:c=E(this,J(this));this.A-=this.B.td;break;case 7:c=E(this,this.G);this.A-=this.B.wc;break;case 64:c=E(this,this.G+this.K+ -this.S());this.A-=this.B.Tb;break;case 65:c=E(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=tg(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=tg(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=E(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=E(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=tg(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=E(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=E(this,this.G+this.K+J(this)); -this.A-=this.B.Tb;break;case 129:c=E(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=tg(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=tg(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=E(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=E(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=tg(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=E(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D&65535;break;case 193:c=this.I& +function Bf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=E(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=Cg(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=Cg(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=E(this,this.K);this.A-=this.B.wc;break;case 5:c=E(this,this.J);this.A-=this.B.wc;break;case 6:c=E(this,J(this));this.A-=this.B.td;break;case 7:c=E(this,this.G);this.A-=this.B.wc;break;case 64:c=E(this,this.G+this.K+ +this.S());this.A-=this.B.Tb;break;case 65:c=E(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=Cg(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=Cg(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=E(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=E(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=Cg(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=E(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=E(this,this.G+this.K+J(this)); +this.A-=this.B.Tb;break;case 129:c=E(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=Cg(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=Cg(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=E(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=E(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=Cg(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=E(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D&65535;break;case 193:c=this.I& 65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&65535;break;case 1:b=this.I&65535;break;case 2:b=this.L&65535;break;case 3:b=this.G&65535;break;case 4:b=z(this)&65535;break;case 5:b=this.M&65535;break;case 6:b=this.K&65535;break;case 7:b=this.J&65535;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= -this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:Zd(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} -function tf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.G+this.K);this.F=this.C;break;case 1:b=E(this,this.G+this.J);this.F=this.C;break;case 2:b=tg(this,this.M+this.K);this.F=this.C;break;case 3:b=tg(this,this.M+this.J);this.F=this.C;break;case 4:b=E(this,this.K);this.F=this.C;break;case 5:b=E(this,this.J);this.F=this.C;break;case 6:b=E(this,J(this));this.F=this.C;break;case 7:b=E(this,this.G);this.F=this.C;break;case 64:b=E(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:b=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=tg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=tg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=E(this,this.K+this.S());this.F=this.C;break;case 69:b=E(this,this.J+this.S());this.F=this.C;break;case 70:b=tg(this,this.M+this.S());this.F=this.C;break;case 71:b=E(this,this.G+this.S());this.F=this.C;break;case 128:b=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=E(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:b=tg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=tg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=E(this,this.K+J(this));this.F=this.C;break;case 133:b=E(this,this.J+J(this));this.F=this.C;break;case 134:b=tg(this,this.M+J(this));this.F=this.C;break;case 135:b=E(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535; -break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break;case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:wg(this,a);this.A-=this.B.Rc;break;case 1:case 2:wg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:wg(this, -a);this.A-=this.B.wc;break;case 6:wg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:wg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:wg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:wg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:Zd(this,z(this)&-65536|a);break; +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:he(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Cf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.G+this.K);this.F=this.C;break;case 1:b=E(this,this.G+this.J);this.F=this.C;break;case 2:b=Cg(this,this.M+this.K);this.F=this.C;break;case 3:b=Cg(this,this.M+this.J);this.F=this.C;break;case 4:b=E(this,this.K);this.F=this.C;break;case 5:b=E(this,this.J);this.F=this.C;break;case 6:b=E(this,J(this));this.F=this.C;break;case 7:b=E(this,this.G);this.F=this.C;break;case 64:b=E(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Cg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Cg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=E(this,this.K+this.S());this.F=this.C;break;case 69:b=E(this,this.J+this.S());this.F=this.C;break;case 70:b=Cg(this,this.M+this.S());this.F=this.C;break;case 71:b=E(this,this.G+this.S());this.F=this.C;break;case 128:b=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=E(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Cg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Cg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=E(this,this.K+J(this));this.F=this.C;break;case 133:b=E(this,this.J+J(this));this.F=this.C;break;case 134:b=Cg(this,this.M+J(this));this.F=this.C;break;case 135:b=E(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535; +break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break;case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Fg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Fg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Fg(this, +a);this.A-=this.B.wc;break;case 6:Fg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Fg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Fg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Fg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break; case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} -function uf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.G+this.K);this.F=this.C;break;case 1:c=E(this,this.G+this.J);this.F=this.C;break;case 2:c=tg(this,this.M+this.K);this.F=this.C;break;case 3:c=tg(this,this.M+this.J);this.F=this.C;break;case 4:c=E(this,this.K);this.F=this.C;break;case 5:c=E(this,this.J);this.F=this.C;break;case 6:c=E(this,J(this));this.F=this.C;break;case 7:c=E(this,this.G);this.F=this.C;break;case 64:c=E(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:c=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=tg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=tg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=E(this,this.K+this.S());this.F=this.C;break;case 69:c=E(this,this.J+this.S());this.F=this.C;break;case 70:c=tg(this,this.M+this.S());this.F=this.C;break;case 71:c=E(this,this.G+this.S());this.F=this.C;break;case 128:c=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=E(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:c=tg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=tg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=E(this,this.K+J(this));this.F=this.C;break;case 133:c=E(this,this.J+J(this));this.F=this.C;break;case 134:c=tg(this,this.M+J(this));this.F=this.C;break;case 135:c=E(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535; -break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:wg(this,a);this.A-=this.B.Rc;break;case 1:case 2:wg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:wg(this,a);this.A-=this.B.wc;break;case 6:wg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:wg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:wg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:wg(this, -a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:Zd(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} -function vf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=G(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=ug(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=ug(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=G(this,this.K);this.A-=this.B.wc;break;case 5:c=G(this,this.J);this.A-=this.B.wc;break;case 6:c=G(this,J(this));this.A-=this.B.td;break;case 7:c=G(this,this.G);this.A-=this.B.wc;break;case 64:c=G(this,this.G+this.K+ -this.S());this.A-=this.B.Tb;break;case 65:c=G(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=ug(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=ug(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=G(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=G(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=ug(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=G(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=G(this,this.G+this.K+J(this)); -this.A-=this.B.Tb;break;case 129:c=G(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=ug(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=ug(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=G(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=G(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=ug(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=G(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D;break;case 193:c=this.I;break; -case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:Zd(this, +function Df(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.G+this.K);this.F=this.C;break;case 1:c=E(this,this.G+this.J);this.F=this.C;break;case 2:c=Cg(this,this.M+this.K);this.F=this.C;break;case 3:c=Cg(this,this.M+this.J);this.F=this.C;break;case 4:c=E(this,this.K);this.F=this.C;break;case 5:c=E(this,this.J);this.F=this.C;break;case 6:c=E(this,J(this));this.F=this.C;break;case 7:c=E(this,this.G);this.F=this.C;break;case 64:c=E(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Cg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Cg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=E(this,this.K+this.S());this.F=this.C;break;case 69:c=E(this,this.J+this.S());this.F=this.C;break;case 70:c=Cg(this,this.M+this.S());this.F=this.C;break;case 71:c=E(this,this.G+this.S());this.F=this.C;break;case 128:c=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=E(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Cg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Cg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=E(this,this.K+J(this));this.F=this.C;break;case 133:c=E(this,this.J+J(this));this.F=this.C;break;case 134:c=Cg(this,this.M+J(this));this.F=this.C;break;case 135:c=E(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535; +break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Fg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Fg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Fg(this,a);this.A-=this.B.wc;break;case 6:Fg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Fg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Fg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Fg(this, +a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} +function Ef(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=G(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=Dg(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=Dg(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=G(this,this.K);this.A-=this.B.wc;break;case 5:c=G(this,this.J);this.A-=this.B.wc;break;case 6:c=G(this,J(this));this.A-=this.B.td;break;case 7:c=G(this,this.G);this.A-=this.B.wc;break;case 64:c=G(this,this.G+this.K+ +this.S());this.A-=this.B.Tb;break;case 65:c=G(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=Dg(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=Dg(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=G(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=G(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=Dg(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=G(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=G(this,this.G+this.K+J(this)); +this.A-=this.B.Tb;break;case 129:c=G(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=Dg(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=Dg(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=G(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=G(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=Dg(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=G(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D;break;case 193:c=this.I;break; +case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:he(this, a);break;case 5:this.M=a;break;case 6:this.K=a;break;case 7:this.J=a}} -function wf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.G+this.K);this.F=this.C;break;case 1:b=G(this,this.G+this.J);this.F=this.C;break;case 2:b=ug(this,this.M+this.K);this.F=this.C;break;case 3:b=ug(this,this.M+this.J);this.F=this.C;break;case 4:b=G(this,this.K);this.F=this.C;break;case 5:b=G(this,this.J);this.F=this.C;break;case 6:b=G(this,J(this));this.F=this.C;break;case 7:b=G(this,this.G);this.F=this.C;break;case 64:b=G(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:b=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=ug(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=ug(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=G(this,this.K+this.S());this.F=this.C;break;case 69:b=G(this,this.J+this.S());this.F=this.C;break;case 70:b=ug(this,this.M+this.S());this.F=this.C;break;case 71:b=G(this,this.G+this.S());this.F=this.C;break;case 128:b=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=G(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:b=ug(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=ug(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=G(this,this.K+J(this));this.F=this.C;break;case 133:b=G(this,this.J+J(this));this.F=this.C;break;case 134:b=ug(this,this.M+J(this));this.F=this.C;break;case 135:b=G(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break; -case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:xg(this,a);this.A-=this.B.Rc;break;case 1:case 2:xg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:xg(this,a);this.A-=this.B.wc;break;case 6:xg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:xg(this, -a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:xg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:xg(this,a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:Zd(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} -function xf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.G+this.K);this.F=this.C;break;case 1:c=G(this,this.G+this.J);this.F=this.C;break;case 2:c=ug(this,this.M+this.K);this.F=this.C;break;case 3:c=ug(this,this.M+this.J);this.F=this.C;break;case 4:c=G(this,this.K);this.F=this.C;break;case 5:c=G(this,this.J);this.F=this.C;break;case 6:c=G(this,J(this));this.F=this.C;break;case 7:c=G(this,this.G);this.F=this.C;break;case 64:c=G(this,this.G+this.K+this.S());this.F=this.C;break; -case 65:c=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=ug(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=ug(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=G(this,this.K+this.S());this.F=this.C;break;case 69:c=G(this,this.J+this.S());this.F=this.C;break;case 70:c=ug(this,this.M+this.S());this.F=this.C;break;case 71:c=G(this,this.G+this.S());this.F=this.C;break;case 128:c=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=G(this,this.G+this.J+J(this)); -this.F=this.C;break;case 130:c=ug(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=ug(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=G(this,this.K+J(this));this.F=this.C;break;case 133:c=G(this,this.J+J(this));this.F=this.C;break;case 134:c=ug(this,this.M+J(this));this.F=this.C;break;case 135:c=G(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break; -case 198:c=this.K;break;case 199:c=this.J}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:xg(this,a);this.A-=this.B.Rc;break;case 1:case 2:xg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:xg(this,a);this.A-=this.B.wc;break;case 6:xg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:xg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:xg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:xg(this, -a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:Zd(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} -function yf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=D(this,this.D);break;case 1:c=D(this,this.I);break;case 2:c=D(this,this.L);break;case 3:c=D(this,this.G);break;case 4:c=D(this,ek.call(this,0));break;case 5:c=D(this,J(this));break;case 6:c=D(this,this.K);break;case 7:c=D(this,this.J);break;case 64:c=D(this,this.D+this.S());break;case 65:c=D(this,this.I+this.S());break;case 66:c=D(this,this.L+this.S());break;case 67:c=D(this,this.G+this.S());break;case 68:c=D(this,ek.call(this,1)+this.S()); -break;case 69:c=pg(this,this.M+this.S());break;case 70:c=D(this,this.K+this.S());break;case 71:c=D(this,this.J+this.S());break;case 128:c=D(this,this.D+J(this));break;case 129:c=D(this,this.I+J(this));break;case 130:c=D(this,this.L+J(this));break;case 131:c=D(this,this.G+J(this));break;case 132:c=D(this,ek.call(this,2)+J(this));break;case 133:c=pg(this,this.M+J(this));break;case 134:c=D(this,this.K+J(this));break;case 135:c=D(this,this.J+J(this));break;case 192:c=this.D&255;break;case 193:c=this.I& +function Ff(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.G+this.K);this.F=this.C;break;case 1:b=G(this,this.G+this.J);this.F=this.C;break;case 2:b=Dg(this,this.M+this.K);this.F=this.C;break;case 3:b=Dg(this,this.M+this.J);this.F=this.C;break;case 4:b=G(this,this.K);this.F=this.C;break;case 5:b=G(this,this.J);this.F=this.C;break;case 6:b=G(this,J(this));this.F=this.C;break;case 7:b=G(this,this.G);this.F=this.C;break;case 64:b=G(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Dg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Dg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=G(this,this.K+this.S());this.F=this.C;break;case 69:b=G(this,this.J+this.S());this.F=this.C;break;case 70:b=Dg(this,this.M+this.S());this.F=this.C;break;case 71:b=G(this,this.G+this.S());this.F=this.C;break;case 128:b=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=G(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Dg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Dg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=G(this,this.K+J(this));this.F=this.C;break;case 133:b=G(this,this.J+J(this));this.F=this.C;break;case 134:b=Dg(this,this.M+J(this));this.F=this.C;break;case 135:b=G(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break; +case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Gg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Gg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Gg(this,a);this.A-=this.B.wc;break;case 6:Gg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Gg(this, +a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Gg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Gg(this,a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Gf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.G+this.K);this.F=this.C;break;case 1:c=G(this,this.G+this.J);this.F=this.C;break;case 2:c=Dg(this,this.M+this.K);this.F=this.C;break;case 3:c=Dg(this,this.M+this.J);this.F=this.C;break;case 4:c=G(this,this.K);this.F=this.C;break;case 5:c=G(this,this.J);this.F=this.C;break;case 6:c=G(this,J(this));this.F=this.C;break;case 7:c=G(this,this.G);this.F=this.C;break;case 64:c=G(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Dg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Dg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=G(this,this.K+this.S());this.F=this.C;break;case 69:c=G(this,this.J+this.S());this.F=this.C;break;case 70:c=Dg(this,this.M+this.S());this.F=this.C;break;case 71:c=G(this,this.G+this.S());this.F=this.C;break;case 128:c=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=G(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Dg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Dg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=G(this,this.K+J(this));this.F=this.C;break;case 133:c=G(this,this.J+J(this));this.F=this.C;break;case 134:c=Dg(this,this.M+J(this));this.F=this.C;break;case 135:c=G(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break; +case 198:c=this.K;break;case 199:c=this.J}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Gg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Gg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Gg(this,a);this.A-=this.B.wc;break;case 6:Gg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Gg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Gg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Gg(this, +a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Hf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=D(this,this.D);break;case 1:c=D(this,this.I);break;case 2:c=D(this,this.L);break;case 3:c=D(this,this.G);break;case 4:c=D(this,nk.call(this,0));break;case 5:c=D(this,J(this));break;case 6:c=D(this,this.K);break;case 7:c=D(this,this.J);break;case 64:c=D(this,this.D+this.S());break;case 65:c=D(this,this.I+this.S());break;case 66:c=D(this,this.L+this.S());break;case 67:c=D(this,this.G+this.S());break;case 68:c=D(this,nk.call(this,1)+this.S()); +break;case 69:c=Ag(this,this.M+this.S());break;case 70:c=D(this,this.K+this.S());break;case 71:c=D(this,this.J+this.S());break;case 128:c=D(this,this.D+J(this));break;case 129:c=D(this,this.I+J(this));break;case 130:c=D(this,this.L+J(this));break;case 131:c=D(this,this.G+J(this));break;case 132:c=D(this,nk.call(this,2)+J(this));break;case 133:c=Ag(this,this.M+J(this));break;case 134:c=D(this,this.K+J(this));break;case 135:c=D(this,this.J+J(this));break;case 192:c=this.D&255;break;case 193:c=this.I& 255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&255;break;case 1:b=this.I&255;break;case 2:b=this.L&255;break;case 3:b=this.G&255;break;case 4:b=this.D>>8&255;break;case 5:b=this.I>>8&255;break;case 6:b=this.L>>8&255;break;case 7:b=this.G>>8&255;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} -function zf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.D);this.F=this.C;break;case 1:b=D(this,this.I);this.F=this.C;break;case 2:b=D(this,this.L);this.F=this.C;break;case 3:b=D(this,this.G);this.F=this.C;break;case 4:b=D(this,ek.call(this,0));this.F=this.C;break;case 5:b=D(this,J(this));this.F=this.C;break;case 6:b=D(this,this.K);this.F=this.C;break;case 7:b=D(this,this.J);this.F=this.C;break;case 64:b=D(this,this.D+this.S());this.F=this.C;break;case 65:b=D(this,this.I+this.S()); -this.F=this.C;break;case 66:b=D(this,this.L+this.S());this.F=this.C;break;case 67:b=D(this,this.G+this.S());this.F=this.C;break;case 68:b=D(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:b=pg(this,this.M+this.S());this.F=this.C;break;case 70:b=D(this,this.K+this.S());this.F=this.C;break;case 71:b=D(this,this.J+this.S());this.F=this.C;break;case 128:b=D(this,this.D+J(this));this.F=this.C;break;case 129:b=D(this,this.I+J(this));this.F=this.C;break;case 130:b=D(this,this.L+J(this));this.F= -this.C;break;case 131:b=D(this,this.G+J(this));this.F=this.C;break;case 132:b=D(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:b=pg(this,this.M+J(this));this.F=this.C;break;case 134:b=D(this,this.K+J(this));this.F=this.C;break;case 135:b=D(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break;case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b= +function If(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.D);this.F=this.C;break;case 1:b=D(this,this.I);this.F=this.C;break;case 2:b=D(this,this.L);this.F=this.C;break;case 3:b=D(this,this.G);this.F=this.C;break;case 4:b=D(this,nk.call(this,0));this.F=this.C;break;case 5:b=D(this,J(this));this.F=this.C;break;case 6:b=D(this,this.K);this.F=this.C;break;case 7:b=D(this,this.J);this.F=this.C;break;case 64:b=D(this,this.D+this.S());this.F=this.C;break;case 65:b=D(this,this.I+this.S()); +this.F=this.C;break;case 66:b=D(this,this.L+this.S());this.F=this.C;break;case 67:b=D(this,this.G+this.S());this.F=this.C;break;case 68:b=D(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Ag(this,this.M+this.S());this.F=this.C;break;case 70:b=D(this,this.K+this.S());this.F=this.C;break;case 71:b=D(this,this.J+this.S());this.F=this.C;break;case 128:b=D(this,this.D+J(this));this.F=this.C;break;case 129:b=D(this,this.I+J(this));this.F=this.C;break;case 130:b=D(this,this.L+J(this));this.F= +this.C;break;case 131:b=D(this,this.G+J(this));this.F=this.C;break;case 132:b=D(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Ag(this,this.M+J(this));this.F=this.C;break;case 134:b=D(this,this.K+J(this));this.F=this.C;break;case 135:b=D(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break;case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b= this.G>>8&255;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&255;break;case 1:c=this.I&255;break;case 2:c=this.L&255;break;case 3:c=this.G&255;break;case 4:c=this.D>>8&255;break;case 5:c=this.I>>8&255;break;case 6:c=this.L>>8&255;break;case 7:c=this.G>>8&255;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= -this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:vg(this,a)}} -function Af(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.D);this.F=this.C;break;case 1:c=D(this,this.I);this.F=this.C;break;case 2:c=D(this,this.L);this.F=this.C;break;case 3:c=D(this,this.G);this.F=this.C;break;case 4:c=D(this,ek.call(this,0));this.F=this.C;break;case 5:c=D(this,J(this));this.F=this.C;break;case 6:c=D(this,this.K);this.F=this.C;break;case 7:c=D(this,this.J);this.F=this.C;break;case 64:c=D(this,this.D+this.S());this.F=this.C;break;case 65:c=D(this,this.I+this.S()); -this.F=this.C;break;case 66:c=D(this,this.L+this.S());this.F=this.C;break;case 67:c=D(this,this.G+this.S());this.F=this.C;break;case 68:c=D(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:c=pg(this,this.M+this.S());this.F=this.C;break;case 70:c=D(this,this.K+this.S());this.F=this.C;break;case 71:c=D(this,this.J+this.S());this.F=this.C;break;case 128:c=D(this,this.D+J(this));this.F=this.C;break;case 129:c=D(this,this.I+J(this));this.F=this.C;break;case 130:c=D(this,this.L+J(this));this.F= -this.C;break;case 131:c=D(this,this.G+J(this));this.F=this.C;break;case 132:c=D(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:c=pg(this,this.M+J(this));this.F=this.C;break;case 134:c=D(this,this.K+J(this));this.F=this.C;break;case 135:c=D(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c= -this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:vg(this,a)}} -function Bf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.D);break;case 1:c=E(this,this.I);break;case 2:c=E(this,this.L);break;case 3:c=E(this,this.G);break;case 4:c=E(this,ek.call(this,0));break;case 5:c=E(this,J(this));break;case 6:c=E(this,this.K);break;case 7:c=E(this,this.J);break;case 64:c=E(this,this.D+this.S());break;case 65:c=E(this,this.I+this.S());break;case 66:c=E(this,this.L+this.S());break;case 67:c=E(this,this.G+this.S());break;case 68:c=E(this,ek.call(this,1)+this.S()); -break;case 69:c=tg(this,this.M+this.S());break;case 70:c=E(this,this.K+this.S());break;case 71:c=E(this,this.J+this.S());break;case 128:c=E(this,this.D+J(this));break;case 129:c=E(this,this.I+J(this));break;case 130:c=E(this,this.L+J(this));break;case 131:c=E(this,this.G+J(this));break;case 132:c=E(this,ek.call(this,2)+J(this));break;case 133:c=tg(this,this.M+J(this));break;case 134:c=E(this,this.K+J(this));break;case 135:c=E(this,this.J+J(this));break;case 192:c=this.D&65535;break;case 193:c=this.I& +this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:Eg(this,a)}} +function Jf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.D);this.F=this.C;break;case 1:c=D(this,this.I);this.F=this.C;break;case 2:c=D(this,this.L);this.F=this.C;break;case 3:c=D(this,this.G);this.F=this.C;break;case 4:c=D(this,nk.call(this,0));this.F=this.C;break;case 5:c=D(this,J(this));this.F=this.C;break;case 6:c=D(this,this.K);this.F=this.C;break;case 7:c=D(this,this.J);this.F=this.C;break;case 64:c=D(this,this.D+this.S());this.F=this.C;break;case 65:c=D(this,this.I+this.S()); +this.F=this.C;break;case 66:c=D(this,this.L+this.S());this.F=this.C;break;case 67:c=D(this,this.G+this.S());this.F=this.C;break;case 68:c=D(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Ag(this,this.M+this.S());this.F=this.C;break;case 70:c=D(this,this.K+this.S());this.F=this.C;break;case 71:c=D(this,this.J+this.S());this.F=this.C;break;case 128:c=D(this,this.D+J(this));this.F=this.C;break;case 129:c=D(this,this.I+J(this));this.F=this.C;break;case 130:c=D(this,this.L+J(this));this.F= +this.C;break;case 131:c=D(this,this.G+J(this));this.F=this.C;break;case 132:c=D(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Ag(this,this.M+J(this));this.F=this.C;break;case 134:c=D(this,this.K+J(this));this.F=this.C;break;case 135:c=D(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c= +this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:Eg(this,a)}} +function Kf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.D);break;case 1:c=E(this,this.I);break;case 2:c=E(this,this.L);break;case 3:c=E(this,this.G);break;case 4:c=E(this,nk.call(this,0));break;case 5:c=E(this,J(this));break;case 6:c=E(this,this.K);break;case 7:c=E(this,this.J);break;case 64:c=E(this,this.D+this.S());break;case 65:c=E(this,this.I+this.S());break;case 66:c=E(this,this.L+this.S());break;case 67:c=E(this,this.G+this.S());break;case 68:c=E(this,nk.call(this,1)+this.S()); +break;case 69:c=Cg(this,this.M+this.S());break;case 70:c=E(this,this.K+this.S());break;case 71:c=E(this,this.J+this.S());break;case 128:c=E(this,this.D+J(this));break;case 129:c=E(this,this.I+J(this));break;case 130:c=E(this,this.L+J(this));break;case 131:c=E(this,this.G+J(this));break;case 132:c=E(this,nk.call(this,2)+J(this));break;case 133:c=Cg(this,this.M+J(this));break;case 134:c=E(this,this.K+J(this));break;case 135:c=E(this,this.J+J(this));break;case 192:c=this.D&65535;break;case 193:c=this.I& 65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&65535;break;case 1:b=this.I&65535;break;case 2:b=this.L&65535;break;case 3:b=this.G&65535;break;case 4:b=z(this)&65535;break;case 5:b=this.M&65535;break;case 6:b=this.K&65535;break;case 7:b=this.J&65535;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= -this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:Zd(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} -function Cf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.D);this.F=this.C;break;case 1:b=E(this,this.I);this.F=this.C;break;case 2:b=E(this,this.L);this.F=this.C;break;case 3:b=E(this,this.G);this.F=this.C;break;case 4:b=E(this,ek.call(this,0));this.F=this.C;break;case 5:b=E(this,J(this));this.F=this.C;break;case 6:b=E(this,this.K);this.F=this.C;break;case 7:b=E(this,this.J);this.F=this.C;break;case 64:b=E(this,this.D+this.S());this.F=this.C;break;case 65:b=E(this,this.I+this.S()); -this.F=this.C;break;case 66:b=E(this,this.L+this.S());this.F=this.C;break;case 67:b=E(this,this.G+this.S());this.F=this.C;break;case 68:b=E(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:b=tg(this,this.M+this.S());this.F=this.C;break;case 70:b=E(this,this.K+this.S());this.F=this.C;break;case 71:b=E(this,this.J+this.S());this.F=this.C;break;case 128:b=E(this,this.D+J(this));this.F=this.C;break;case 129:b=E(this,this.I+J(this));this.F=this.C;break;case 130:b=E(this,this.L+J(this));this.F= -this.C;break;case 131:b=E(this,this.G+J(this));this.F=this.C;break;case 132:b=E(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:b=tg(this,this.M+J(this));this.F=this.C;break;case 134:b=E(this,this.K+J(this));this.F=this.C;break;case 135:b=E(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535;break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break; -case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:Zd(this,z(this)& --65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:wg(this,a)}} -function Df(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.D);this.F=this.C;break;case 1:c=E(this,this.I);this.F=this.C;break;case 2:c=E(this,this.L);this.F=this.C;break;case 3:c=E(this,this.G);this.F=this.C;break;case 4:c=E(this,ek.call(this,0));this.F=this.C;break;case 5:c=E(this,J(this));this.F=this.C;break;case 6:c=E(this,this.K);this.F=this.C;break;case 7:c=E(this,this.J);this.F=this.C;break;case 64:c=E(this,this.D+this.S());this.F=this.C;break;case 65:c=E(this,this.I+this.S()); -this.F=this.C;break;case 66:c=E(this,this.L+this.S());this.F=this.C;break;case 67:c=E(this,this.G+this.S());this.F=this.C;break;case 68:c=E(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:c=tg(this,this.M+this.S());this.F=this.C;break;case 70:c=E(this,this.K+this.S());this.F=this.C;break;case 71:c=E(this,this.J+this.S());this.F=this.C;break;case 128:c=E(this,this.D+J(this));this.F=this.C;break;case 129:c=E(this,this.I+J(this));this.F=this.C;break;case 130:c=E(this,this.L+J(this));this.F= -this.C;break;case 131:c=E(this,this.G+J(this));this.F=this.C;break;case 132:c=E(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:c=tg(this,this.M+J(this));this.F=this.C;break;case 134:c=E(this,this.K+J(this));this.F=this.C;break;case 135:c=E(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break; -case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:Zd(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:wg(this,a)}} -function Ef(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.D);break;case 1:c=G(this,this.I);break;case 2:c=G(this,this.L);break;case 3:c=G(this,this.G);break;case 4:c=G(this,ek.call(this,0));break;case 5:c=G(this,J(this));break;case 6:c=G(this,this.K);break;case 7:c=G(this,this.J);break;case 64:c=G(this,this.D+this.S());break;case 65:c=G(this,this.I+this.S());break;case 66:c=G(this,this.L+this.S());break;case 67:c=G(this,this.G+this.S());break;case 68:c=G(this,ek.call(this,1)+this.S()); -break;case 69:c=ug(this,this.M+this.S());break;case 70:c=G(this,this.K+this.S());break;case 71:c=G(this,this.J+this.S());break;case 128:c=G(this,this.D+J(this));break;case 129:c=G(this,this.I+J(this));break;case 130:c=G(this,this.L+J(this));break;case 131:c=G(this,this.G+J(this));break;case 132:c=G(this,ek.call(this,2)+J(this));break;case 133:c=ug(this,this.M+J(this));break;case 134:c=G(this,this.K+J(this));break;case 135:c=G(this,this.J+J(this));break;case 192:c=this.D;break;case 193:c=this.I;break; -case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:Zd(this, +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:he(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Lf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.D);this.F=this.C;break;case 1:b=E(this,this.I);this.F=this.C;break;case 2:b=E(this,this.L);this.F=this.C;break;case 3:b=E(this,this.G);this.F=this.C;break;case 4:b=E(this,nk.call(this,0));this.F=this.C;break;case 5:b=E(this,J(this));this.F=this.C;break;case 6:b=E(this,this.K);this.F=this.C;break;case 7:b=E(this,this.J);this.F=this.C;break;case 64:b=E(this,this.D+this.S());this.F=this.C;break;case 65:b=E(this,this.I+this.S()); +this.F=this.C;break;case 66:b=E(this,this.L+this.S());this.F=this.C;break;case 67:b=E(this,this.G+this.S());this.F=this.C;break;case 68:b=E(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Cg(this,this.M+this.S());this.F=this.C;break;case 70:b=E(this,this.K+this.S());this.F=this.C;break;case 71:b=E(this,this.J+this.S());this.F=this.C;break;case 128:b=E(this,this.D+J(this));this.F=this.C;break;case 129:b=E(this,this.I+J(this));this.F=this.C;break;case 130:b=E(this,this.L+J(this));this.F= +this.C;break;case 131:b=E(this,this.G+J(this));this.F=this.C;break;case 132:b=E(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Cg(this,this.M+J(this));this.F=this.C;break;case 134:b=E(this,this.K+J(this));this.F=this.C;break;case 135:b=E(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535;break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break; +case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)& +-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Fg(this,a)}} +function Mf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.D);this.F=this.C;break;case 1:c=E(this,this.I);this.F=this.C;break;case 2:c=E(this,this.L);this.F=this.C;break;case 3:c=E(this,this.G);this.F=this.C;break;case 4:c=E(this,nk.call(this,0));this.F=this.C;break;case 5:c=E(this,J(this));this.F=this.C;break;case 6:c=E(this,this.K);this.F=this.C;break;case 7:c=E(this,this.J);this.F=this.C;break;case 64:c=E(this,this.D+this.S());this.F=this.C;break;case 65:c=E(this,this.I+this.S()); +this.F=this.C;break;case 66:c=E(this,this.L+this.S());this.F=this.C;break;case 67:c=E(this,this.G+this.S());this.F=this.C;break;case 68:c=E(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Cg(this,this.M+this.S());this.F=this.C;break;case 70:c=E(this,this.K+this.S());this.F=this.C;break;case 71:c=E(this,this.J+this.S());this.F=this.C;break;case 128:c=E(this,this.D+J(this));this.F=this.C;break;case 129:c=E(this,this.I+J(this));this.F=this.C;break;case 130:c=E(this,this.L+J(this));this.F= +this.C;break;case 131:c=E(this,this.G+J(this));this.F=this.C;break;case 132:c=E(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Cg(this,this.M+J(this));this.F=this.C;break;case 134:c=E(this,this.K+J(this));this.F=this.C;break;case 135:c=E(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break; +case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Fg(this,a)}} +function Nf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.D);break;case 1:c=G(this,this.I);break;case 2:c=G(this,this.L);break;case 3:c=G(this,this.G);break;case 4:c=G(this,nk.call(this,0));break;case 5:c=G(this,J(this));break;case 6:c=G(this,this.K);break;case 7:c=G(this,this.J);break;case 64:c=G(this,this.D+this.S());break;case 65:c=G(this,this.I+this.S());break;case 66:c=G(this,this.L+this.S());break;case 67:c=G(this,this.G+this.S());break;case 68:c=G(this,nk.call(this,1)+this.S()); +break;case 69:c=Dg(this,this.M+this.S());break;case 70:c=G(this,this.K+this.S());break;case 71:c=G(this,this.J+this.S());break;case 128:c=G(this,this.D+J(this));break;case 129:c=G(this,this.I+J(this));break;case 130:c=G(this,this.L+J(this));break;case 131:c=G(this,this.G+J(this));break;case 132:c=G(this,nk.call(this,2)+J(this));break;case 133:c=Dg(this,this.M+J(this));break;case 134:c=G(this,this.K+J(this));break;case 135:c=G(this,this.J+J(this));break;case 192:c=this.D;break;case 193:c=this.I;break; +case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:he(this, a);break;case 5:this.M=a;break;case 6:this.K=a;break;case 7:this.J=a}} -function Ff(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.D);this.F=this.C;break;case 1:b=G(this,this.I);this.F=this.C;break;case 2:b=G(this,this.L);this.F=this.C;break;case 3:b=G(this,this.G);this.F=this.C;break;case 4:b=G(this,ek.call(this,0));this.F=this.C;break;case 5:b=G(this,J(this));this.F=this.C;break;case 6:b=G(this,this.K);this.F=this.C;break;case 7:b=G(this,this.J);this.F=this.C;break;case 64:b=G(this,this.D+this.S());this.F=this.C;break;case 65:b=G(this,this.I+this.S()); -this.F=this.C;break;case 66:b=G(this,this.L+this.S());this.F=this.C;break;case 67:b=G(this,this.G+this.S());this.F=this.C;break;case 68:b=G(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:b=ug(this,this.M+this.S());this.F=this.C;break;case 70:b=G(this,this.K+this.S());this.F=this.C;break;case 71:b=G(this,this.J+this.S());this.F=this.C;break;case 128:b=G(this,this.D+J(this));this.F=this.C;break;case 129:b=G(this,this.I+J(this));this.F=this.C;break;case 130:b=G(this,this.L+J(this));this.F= -this.C;break;case 131:b=G(this,this.G+J(this));this.F=this.C;break;case 132:b=G(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:b=ug(this,this.M+J(this));this.F=this.C;break;case 134:b=G(this,this.K+J(this));this.F=this.C;break;case 135:b=G(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break;case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>> -3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:Zd(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:xg(this,a)}} -function Gf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.D);this.F=this.C;break;case 1:c=G(this,this.I);this.F=this.C;break;case 2:c=G(this,this.L);this.F=this.C;break;case 3:c=G(this,this.G);this.F=this.C;break;case 4:c=G(this,ek.call(this,0));this.F=this.C;break;case 5:c=G(this,J(this));this.F=this.C;break;case 6:c=G(this,this.K);this.F=this.C;break;case 7:c=G(this,this.J);this.F=this.C;break;case 64:c=G(this,this.D+this.S());this.F=this.C;break;case 65:c=G(this,this.I+this.S()); -this.F=this.C;break;case 66:c=G(this,this.L+this.S());this.F=this.C;break;case 67:c=G(this,this.G+this.S());this.F=this.C;break;case 68:c=G(this,ek.call(this,1)+this.S());this.F=this.C;break;case 69:c=ug(this,this.M+this.S());this.F=this.C;break;case 70:c=G(this,this.K+this.S());this.F=this.C;break;case 71:c=G(this,this.J+this.S());this.F=this.C;break;case 128:c=G(this,this.D+J(this));this.F=this.C;break;case 129:c=G(this,this.I+J(this));this.F=this.C;break;case 130:c=G(this,this.L+J(this));this.F= -this.C;break;case 131:c=G(this,this.G+J(this));this.F=this.C;break;case 132:c=G(this,ek.call(this,2)+J(this));this.F=this.C;break;case 133:c=ug(this,this.M+J(this));this.F=this.C;break;case 134:c=G(this,this.K+J(this));this.F=this.C;break;case 135:c=G(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}a=a[this.ga>> -3&7].call(this,c,b.call(this));switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:Zd(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:xg(this,a)}} -function ek(a){var b=this.ra(),c=b>>6,d,e;switch(b>>3&7){case 0:d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=0;break;case 5:d=this.M;break;case 6:d=this.K;break;case 7:d=this.J}switch(b&7){case 0:e=this.D;break;case 1:e=this.I;break;case 2:e=this.L;break;case 3:e=this.G;break;case 4:e=z(this);this.Da=this.Rb;break;case 5:a?(e=this.M,this.Da=this.Rb):e=J(this);break;case 6:e=this.K;break;case 7:e=this.J}return(d<>8&255;9<(c&15)||Xf(this)?(c+=6,80286<=this.ca&&255>8&255;9<(c&15)||Xf(this)?(c=c-6&15,d=d-1&255,a=b=1):a=b=0;this.D=this.D&-65536|d<<8|c;a?bg(this):cg(this);b?jg(this):hg(this);this.A-=this.B.qe},function(){this.D=Rj.call(this,this.D)},function(){this.I=Rj.call(this,this.I)},function(){this.L=Rj.call(this,this.L)},function(){this.G=Rj.call(this,this.G)},function(){Zd(this, -Rj.call(this,z(this)))},function(){this.M=Rj.call(this,this.M)},function(){this.K=Rj.call(this,this.K)},function(){this.J=Rj.call(this,this.J)},function(){this.D=Pj.call(this,this.D)},function(){this.I=Pj.call(this,this.I)},function(){this.L=Pj.call(this,this.L)},function(){this.G=Pj.call(this,this.G)},function(){Zd(this,Pj.call(this,z(this)))},function(){this.M=Pj.call(this,this.M)},function(){this.K=Pj.call(this,this.K)},function(){this.J=Pj.call(this,this.J)},function(){ge(this,this.D&this.R); -this.A-=this.B.Ic},function(){ge(this,this.I&this.R);this.A-=this.B.Ic},function(){ge(this,this.L&this.R);this.A-=this.B.Ic},function(){ge(this,this.G&this.R);this.A-=this.B.Ic},function(){ge(this,z(this)-2&65535);this.A-=this.B.Ic},function(){ge(this,this.M&this.R);this.A-=this.B.Ic},function(){ge(this,this.K&this.R);this.A-=this.B.Ic},function(){ge(this,this.J&this.R);this.A-=this.B.Ic},function(){this.D=this.D&~this.R|Xd(this);this.A-=this.B.nc},function(){this.I=this.I&~this.R|Xd(this);this.A-= -this.B.nc},function(){this.L=this.L&~this.R|Xd(this);this.A-=this.B.nc},function(){this.G=this.G&~this.R|Xd(this);this.A-=this.B.nc},function(){Zd(this,z(this)&~this.R|Xd(this));this.A-=this.B.nc},function(){this.M=this.M&~this.R|Xd(this);this.A-=this.B.nc},function(){this.K=this.K&~this.R|Xd(this);this.A-=this.B.nc},function(){this.J=this.J&~this.R|Xd(this);this.A-=this.B.nc},fk,gk,hk,ik,jk,kk,lk,mk,nk,ok,pk,qk,rk,sk,tk,uk,fk,gk,hk,ik,jk,kk,lk,mk,nk,ok,pk,qk,rk,sk,tk,uk,vk,function(){this.rb.call(this, -Kk,this.Ea);this.A-=-1===this.F?1:this.B.yg},vk,function(){this.rb.call(this,Kk,this.S);this.A-=-1===this.F?1:this.B.yg},function(){this.tc.call(this,Gj)},function(){this.za.call(this,Hj)},function(){this.kc.call(this,Kj)},function(){this.ma.call(this,Lj)},xk,yk,zk,Ak,function(){this.N|=1;this.za.call(this,Pi)},function(){this.N|=1;this.Da=this.Rb=this.Qg;this.ma.call(this,Fi)},function(){var a;this.ma.call(this,Oi);switch(this.ga>>3&7){case 0:a=this.D;this.D=this.ya;fe(this,a);break;case 1:a=this.I; -this.I=this.ya;Qf(this,a);break;case 2:a=this.L;this.L=this.ya;Yd(this,a);break;case 3:a=this.G;this.G=this.ya;ee(this,a);break;case 4:a=z(this);Zd(this,this.ya);80386<=this.ca?this.Ga.load(a):fe(this,a);break;case 5:a=this.M;this.M=this.ya;80386<=this.ca?this.Ha.load(a):Qf(this,a);break;case 6:a=this.K;this.K=this.ya;Yd(this,a);break;case 7:a=this.J,this.J=this.ya,ee(this,a)}},function(){this.N|=1;this.ta=this.Aa;this.ya=Xd(this);this.rb.call(this,Lk,Yj);this.ta=-1},function(){this.A-=3},function(){var a= -this.D;this.D=this.D&~this.R|this.I&this.R;this.I=this.I&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.L&this.R;this.L=this.L&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.G&this.R;this.G=this.G&~this.R|a&this.R;this.A-=3},function(){var a=this.D,b=z(this);this.D=this.D&~this.R|b&this.R;Zd(this,b&~this.R|a&this.R);this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.M&this.R;this.M=this.M&~this.R|a&this.R;this.A-=3},function(){var a= -this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.V?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.V?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Kj},function(){Zj.call(this,this.Ea(),yg(this));this.A-=this.B.Nj},function(){this.A-=3},function(){var a=ie(this);a&131072&& -3>this.lc?y.call(this,13,0):(ge(this,a&-196609),this.A-=this.B.Ic)},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var a=Xd(this),a=a&65535|this.O&-65536;je(this,a);this.A-=this.B.nc}},function(){var a=this.D>>8&255;a&1?bg(this):cg(this);a&4?(this.resultType&=-3,this.O|=4):(this.resultType&=-3,this.O&=-5);a&16?jg(this):hg(this);a&64?kg(this):ig(this);a&128?(this.resultType&=-17,this.O|=128):(this.resultType&=-17,this.O&=-129);this.A-=this.B.Vb},function(){this.D=this.D&-65281|(ie(this)& -213)<<8;this.A-=this.B.Vb},function(){var a=this.D&-256,b;b=J(this);b=this.Ia(this.Da.bc(b,1));this.D=a|b;this.A-=this.B.Kh},function(){this.D=this.D&~this.R|ce(this,this.Da,J(this));this.A-=this.B.Kh},function(){var a=J(this),b=this.D;this.fc(this.Da.cc(a,1),b);this.A-=this.B.Lh},function(){var a=J(this),b=this.D;this.yb(this.Da.cc(a,this.V),b);this.A-=this.B.Lh},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e= -this.Ia(this.Da.bc(this.K&c,1));this.fc(this.oa.cc(this.J&c,1),e);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e=ce(this,this.Da,this.K&c);this.yb(this.oa.cc(this.J&c,this.V),e);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d; -this.I=this.I&~c|this.I-b&c;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=og(this,this.Da,this.K),f=og(this,this.oa,this.J);this.F=this.C;si.call(this,e,f);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&Yf(this)==(this.ha&64)&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&& -(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=qg(this,this.Da,this.K&c),f=qg(this,this.oa,this.J&c);this.F=this.C;ti.call(this,e,f);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&Yf(this)==(this.ha&64)&&(Tf(this),this.N|=256)}},function(){ag(this,this.D&this.ra(),128);this.A-=this.B.qe},function(){ag(this,this.D&this.Ea(),this.Fb);this.A-=this.B.qe},function(){var a=1,b=0,c=this.wa, -d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.fc(this.oa.cc(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.we&&80564>=this.we&&!(this.ha&2048)!=(103!=this.Ia(this.da))&&(c^=-65536);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.A-=d;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.yb(this.oa.cc(this.J& -c,this.V),e);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=this.Ia(this.Da.bc(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c, -b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=ce(this,this.Da,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&255,f=og(this,this.oa,this.J);this.F=this.C;si.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I- -b&c;this.A-=d-this.B.Ib;a&&Yf(this)==(this.ha&64)&&(Tf(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&this.R,f=qg(this,this.oa,this.J&c);this.F=this.C;ti.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&Yf(this)==(this.ha&64)&&(Tf(this),this.N|=256)}},function(){this.D=this.D&-256|this.ra();this.A-=this.B.Vb},function(){this.I= +function Of(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.D);this.F=this.C;break;case 1:b=G(this,this.I);this.F=this.C;break;case 2:b=G(this,this.L);this.F=this.C;break;case 3:b=G(this,this.G);this.F=this.C;break;case 4:b=G(this,nk.call(this,0));this.F=this.C;break;case 5:b=G(this,J(this));this.F=this.C;break;case 6:b=G(this,this.K);this.F=this.C;break;case 7:b=G(this,this.J);this.F=this.C;break;case 64:b=G(this,this.D+this.S());this.F=this.C;break;case 65:b=G(this,this.I+this.S()); +this.F=this.C;break;case 66:b=G(this,this.L+this.S());this.F=this.C;break;case 67:b=G(this,this.G+this.S());this.F=this.C;break;case 68:b=G(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Dg(this,this.M+this.S());this.F=this.C;break;case 70:b=G(this,this.K+this.S());this.F=this.C;break;case 71:b=G(this,this.J+this.S());this.F=this.C;break;case 128:b=G(this,this.D+J(this));this.F=this.C;break;case 129:b=G(this,this.I+J(this));this.F=this.C;break;case 130:b=G(this,this.L+J(this));this.F= +this.C;break;case 131:b=G(this,this.G+J(this));this.F=this.C;break;case 132:b=G(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Dg(this,this.M+J(this));this.F=this.C;break;case 134:b=G(this,this.K+J(this));this.F=this.C;break;case 135:b=G(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break;case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>> +3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Gg(this,a)}} +function Pf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.D);this.F=this.C;break;case 1:c=G(this,this.I);this.F=this.C;break;case 2:c=G(this,this.L);this.F=this.C;break;case 3:c=G(this,this.G);this.F=this.C;break;case 4:c=G(this,nk.call(this,0));this.F=this.C;break;case 5:c=G(this,J(this));this.F=this.C;break;case 6:c=G(this,this.K);this.F=this.C;break;case 7:c=G(this,this.J);this.F=this.C;break;case 64:c=G(this,this.D+this.S());this.F=this.C;break;case 65:c=G(this,this.I+this.S()); +this.F=this.C;break;case 66:c=G(this,this.L+this.S());this.F=this.C;break;case 67:c=G(this,this.G+this.S());this.F=this.C;break;case 68:c=G(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Dg(this,this.M+this.S());this.F=this.C;break;case 70:c=G(this,this.K+this.S());this.F=this.C;break;case 71:c=G(this,this.J+this.S());this.F=this.C;break;case 128:c=G(this,this.D+J(this));this.F=this.C;break;case 129:c=G(this,this.I+J(this));this.F=this.C;break;case 130:c=G(this,this.L+J(this));this.F= +this.C;break;case 131:c=G(this,this.G+J(this));this.F=this.C;break;case 132:c=G(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Dg(this,this.M+J(this));this.F=this.C;break;case 134:c=G(this,this.K+J(this));this.F=this.C;break;case 135:c=G(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}a=a[this.ga>> +3&7].call(this,c,b.call(this));switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Gg(this,a)}} +function nk(a){var b=this.ra(),c=b>>6,d,e;switch(b>>3&7){case 0:d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=0;break;case 5:d=this.M;break;case 6:d=this.K;break;case 7:d=this.J}switch(b&7){case 0:e=this.D;break;case 1:e=this.I;break;case 2:e=this.L;break;case 3:e=this.G;break;case 4:e=z(this);this.Da=this.Rb;break;case 5:a?(e=this.M,this.Da=this.Rb):e=J(this);break;case 6:e=this.K;break;case 7:e=this.J}return(d<>8&255;9<(c&15)||fg(this)?(c+=6,80286<=this.ca&&255>8&255;9<(c&15)||fg(this)?(c=c-6&15,d=d-1&255,a=b=1):a=b=0;this.D=this.D&-65536|d<<8|c;a?kg(this):lg(this);b?ug(this):qg(this);this.A-=this.B.qe},function(){this.D=ak.call(this,this.D)},function(){this.I=ak.call(this,this.I)},function(){this.L=ak.call(this,this.L)},function(){this.G=ak.call(this,this.G)},function(){he(this, +ak.call(this,z(this)))},function(){this.M=ak.call(this,this.M)},function(){this.K=ak.call(this,this.K)},function(){this.J=ak.call(this,this.J)},function(){this.D=Yj.call(this,this.D)},function(){this.I=Yj.call(this,this.I)},function(){this.L=Yj.call(this,this.L)},function(){this.G=Yj.call(this,this.G)},function(){he(this,Yj.call(this,z(this)))},function(){this.M=Yj.call(this,this.M)},function(){this.K=Yj.call(this,this.K)},function(){this.J=Yj.call(this,this.J)},function(){pe(this,this.D&this.R); +this.A-=this.B.Ic},function(){pe(this,this.I&this.R);this.A-=this.B.Ic},function(){pe(this,this.L&this.R);this.A-=this.B.Ic},function(){pe(this,this.G&this.R);this.A-=this.B.Ic},function(){pe(this,z(this)-2&65535);this.A-=this.B.Ic},function(){pe(this,this.M&this.R);this.A-=this.B.Ic},function(){pe(this,this.K&this.R);this.A-=this.B.Ic},function(){pe(this,this.J&this.R);this.A-=this.B.Ic},function(){this.D=this.D&~this.R|fe(this);this.A-=this.B.nc},function(){this.I=this.I&~this.R|fe(this);this.A-= +this.B.nc},function(){this.L=this.L&~this.R|fe(this);this.A-=this.B.nc},function(){this.G=this.G&~this.R|fe(this);this.A-=this.B.nc},function(){he(this,z(this)&~this.R|fe(this));this.A-=this.B.nc},function(){this.M=this.M&~this.R|fe(this);this.A-=this.B.nc},function(){this.K=this.K&~this.R|fe(this);this.A-=this.B.nc},function(){this.J=this.J&~this.R|fe(this);this.A-=this.B.nc},ok,pk,qk,rk,sk,tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,ok,pk,qk,rk,sk,tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,Ek,function(){this.rb.call(this, +Tk,this.Ea);this.A-=-1===this.F?1:this.B.yg},Ek,function(){this.rb.call(this,Tk,this.S);this.A-=-1===this.F?1:this.B.yg},function(){this.tc.call(this,Pj)},function(){this.za.call(this,Qj)},function(){this.kc.call(this,Tj)},function(){this.ma.call(this,Uj)},Gk,Hk,Ik,Jk,function(){this.N|=1;this.za.call(this,hj)},function(){this.N|=1;this.Da=this.Rb=this.Qg;this.ma.call(this,Oi)},function(){var a;this.ma.call(this,gj);switch(this.ga>>3&7){case 0:a=this.D;this.D=this.ya;oe(this,a);break;case 1:a=this.I; +this.I=this.ya;Zf(this,a);break;case 2:a=this.L;this.L=this.ya;ge(this,a);break;case 3:a=this.G;this.G=this.ya;ne(this,a);break;case 4:a=z(this);he(this,this.ya);80386<=this.ca?this.Ga.load(a):oe(this,a);break;case 5:a=this.M;this.M=this.ya;80386<=this.ca?this.Ha.load(a):Zf(this,a);break;case 6:a=this.K;this.K=this.ya;ge(this,a);break;case 7:a=this.J,this.J=this.ya,ne(this,a)}},function(){this.N|=1;this.ta=this.Aa;this.ya=fe(this);this.rb.call(this,Uk,hk);this.ta=-1},function(){this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.I&this.R;this.I=this.I&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.L&this.R;this.L=this.L&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.G&this.R;this.G=this.G&~this.R|a&this.R;this.A-=3},function(){var a=this.D,b=z(this);this.D=this.D&~this.R|b&this.R;he(this,b&~this.R|a&this.R);this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.M&this.R;this.M=this.M&~this.R|a&this.R;this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.V?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.V?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Kj},function(){ik.call(this,this.Ea(),Hg(this));this.A-=this.B.Nj},function(){this.A-=3},function(){var a=re(this);a&131072&& +3>this.lc?y.call(this,13,0):(pe(this,a&-196609),this.A-=this.B.Ic)},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var a=fe(this),a=a&65535|this.O&-65536;se(this,a);this.A-=this.B.nc}},function(){var a=this.D>>8&255;a&1?kg(this):lg(this);a&4?(this.resultType&=-3,this.O|=4):(this.resultType&=-3,this.O&=-5);a&16?ug(this):qg(this);a&64?vg(this):rg(this);a&128?(this.resultType&=-17,this.O|=128):(this.resultType&=-17,this.O&=-129);this.A-=this.B.Vb},function(){this.D=this.D&-65281|(re(this)& +213)<<8;this.A-=this.B.Vb},function(){var a=this.D&-256,b;b=J(this);b=this.Ia(this.Da.bc(b,1));this.D=a|b;this.A-=this.B.Kh},function(){this.D=this.D&~this.R|le(this,this.Da,J(this));this.A-=this.B.Kh},function(){var a=J(this),b=this.D;this.fc(this.Da.cc(a,1),b);this.A-=this.B.Lh},function(){var a=J(this),b=this.D;this.yb(this.Da.cc(a,this.V),b);this.A-=this.B.Lh},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e= +this.Ia(this.Da.bc(this.K&c,1));this.fc(this.oa.cc(this.J&c,1),e);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e=le(this,this.Da,this.K&c);this.yb(this.oa.cc(this.J&c,this.V),e);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d; +this.I=this.I&~c|this.I-b&c;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=zg(this,this.Da,this.K),f=zg(this,this.oa,this.J);this.F=this.C;Bi.call(this,e,f);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&& +(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=Bg(this,this.Da,this.K&c),f=Bg(this,this.oa,this.J&c);this.F=this.C;Ci.call(this,e,f);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){jg(this,this.D&this.ra(),128);this.A-=this.B.qe},function(){jg(this,this.D&this.Ea(),this.Fb);this.A-=this.B.qe},function(){var a=1,b=0,c=this.wa, +d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.fc(this.oa.cc(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.we&&80564>=this.we&&!(this.ha&2048)!=(103!=this.Ia(this.da))&&(c^=-65536);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.yb(this.oa.cc(this.J& +c,this.V),e);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=this.Ia(this.Da.bc(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c, +b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=le(this,this.Da,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&255,f=zg(this,this.oa,this.J);this.F=this.C;Bi.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I- +b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&this.R,f=Bg(this,this.oa,this.J&c);this.F=this.C;Ci.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){this.D=this.D&-256|this.ra();this.A-=this.B.Vb},function(){this.I= this.I&-256|this.ra();this.A-=this.B.Vb},function(){this.L=this.L&-256|this.ra();this.A-=this.B.Vb},function(){this.G=this.G&-256|this.ra();this.A-=this.B.Vb},function(){this.D=this.D&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.I=this.I&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.L=this.L&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.G=this.G&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.D=this.D&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.I=this.I& -~this.R|this.Ea();this.A-=this.B.Vb},function(){this.L=this.L&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.G=this.G&~this.R|this.Ea();this.A-=this.B.Vb},function(){Zd(this,z(this)&~this.R|this.Ea());this.A-=this.B.Vb},function(){this.M=this.M&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.K=this.K&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.J=this.J&~this.R|this.Ea();this.A-=this.B.Vb},Ek,Fk,Ek,Fk,function(){this.ma.call(this,Gi)},function(){this.ma.call(this,Ei)},function(){this.N|= -1;this.kd.call(this,Mk,this.ra)},function(){this.N|=1;this.rb.call(this,Mk,this.Ea)},Gk,Hk,Gk,Hk,function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var a=this.B.dk;this.Uc=-1;ak.call(this,3,null,a)}},function(){var a=this.ra();if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var b;a:{b=this.Yf[a];if(void 0!==b)for(var c=0;cthis.lc)y.call(this,13,0);else{var a=this.B.ek;this.Uc=-1;ak.call(this,4,null,a)}else this.A-=this.B.fk},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{this.Vc=this.Y.U;this.ta=this.Aa;this.A-=this.B.bk;if(this.qa&1&&this.O&16384){var a=this.ja(this.la.ua+0);$d(this.Z,a,!1)}else{var a=this.Ma,b=Xd(this),c=Xd(this),d=Xd(this);if(this.O&131072)d=d&131071|this.O&-131072;else if(d&131072){var e=Xd(this),f=Xd(this),g=Xd(this),h=Xd(this),k=Xd(this),m=Xd(this);ae(this,!0,!0);Yd(this, -f);Zd(this,e);fe(this,g);ee(this,h);this.Ga.load(k);this.Ha.load(m)}null!=ke(this,b,c,!1)&&(je(this,d,a),this.ag&&Lf(this,this.da))}this.Vc=this.ta=-1}},function(){this.kd.call(this,Bk,Uj)},function(){this.rb.call(this,2==this.V?Ck:Dk,Uj)},function(){this.kd.call(this,Bk,Vj)},function(){this.rb.call(this,2==this.V?Ck:Dk,Vj)},function(){var a=this.ra();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;ag(this,this.D,128);this.A-=this.B.Hj}else dk.call(this)},function(){var a=this.D&255,b=(this.D>> -8&255)*this.ra()|0,c=a+b|0;this.D=this.D&-65536|c&255;Uf(this,a,b,c,191);this.A-=this.B.Gj},function(){this.D=this.D&-256|(Vf(this)?255:0);this.A-=2},function(){this.D=this.D&-256|og(this,this.Da,this.G+(this.D&255));this.A-=this.B.Gk},function(){Ik.call(this,216)},function(){Ik.call(this,217)},function(){Ik.call(this,218)},function(){Ik.call(this,219)},function(){Ik.call(this,220)},function(){Ik.call(this,221)},function(){Ik.call(this,222)},function(){Ik.call(this,223)},function(){var a=this.S(), -b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&!Yf(this)?(C(this,A(this)+a),this.A-=this.B.mk):this.A-=this.B.Hh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&Yf(this)?(C(this,A(this)+a),this.A-=this.B.Ih):this.A-=this.B.Jh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b?(C(this,A(this)+a),this.A-=this.B.lk):this.A-=this.B.Hh},function(){var a=this.S();this.I&this.wa?this.A-=this.B.Jh:(C(this,A(this)+a),this.A-=this.B.Ih)},function(){var a=this.ra(); -mg(this,a,1,!0)&&(this.D=this.D&-256|Fc(this.ka,a,1,this.da-2)&255,this.A-=this.B.Ch)},function(){var a=this.ra();mg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Fc(this.ka,a,this.V,this.da-2)&this.R,this.A-=this.B.Ch)},function(){var a=this.ra();mg(this,a,1,!1)&&(Jc(this.ka,a,1,this.D&255,this.da-2),this.A-=this.B.Qh)},function(){var a=this.ra();mg(this,a,this.V,!1)&&(Jc(this.ka,a,this.V,this.D&this.R,this.da-2),this.A-=this.B.Qh)},function(){var a=this.Ea(),b=A(this),a=b+a;ge(this,b);C(this,a);this.A-= -this.B.Lj},function(){var a=this.Ea();C(this,A(this)+a);this.A-=this.B.Dh},function(){ke(this,this.Ea(),yg(this));this.A-=this.B.hk},function(){var a=this.S();C(this,A(this)+a);this.A-=this.B.Dh},function(){var a=this.L&65535;mg(this,a,1,!0)&&(this.D=this.D&-256|Fc(this.ka,a,1,this.da-1)&255,this.A-=this.B.Bh)},function(){var a=this.L&65535;mg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Fc(this.ka,a,this.V,this.da-1)&this.R,this.A-=this.B.Bh)},function(){var a=this.L&65535;mg(this,a,1,!1)&&(Jc(this.ka, -a,1,this.D&255,this.da-1),this.A-=this.B.Ph)},function(){var a=this.L&65535;mg(this,a,2,!1)&&(Jc(this.ka,a,this.V,this.D&this.R,this.da-1),this.A-=this.B.Ph)},Jk,Jk,function(){this.N|=132;this.A-=this.B.bd},function(){this.N|=68;this.A-=this.B.bd},function(){this.O&131072?y.call(this,13,0):(this.Za|=4,this.A-=2,this.ba&&t(this,-2147483648)?(Tf(this),this.ba.Jb()):this.O&512||(this.ba&&Tf(this),this.Jb()))},function(){Vf(this)?cg(this):bg(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,Ok, -Xj);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R)},function(){this.vc=!1;this.rb.call(this,Pk,Xj);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R,this.L=this.L&~this.R|this.$a&this.R)},function(){cg(this);this.A-=2},function(){bg(this);this.A-=2},function(){this.Ma>this.lc?y.call(this,13,0):(this.O&=-513,this.A-=this.B.Jj)},function(){this.Ma>this.lc?y.call(this,13,0):(this.O|=512,this.N|=4,this.A-=2)},function(){this.O&=-1025;this.A-=2},function(){this.O|=1024;this.A-=2},function(){this.kd.call(this, -oe,Xj)},function(){this.rb.call(this,pe,Xj)}],wk=[ci,Qi,ai,bj,ei,Ej,Mj,si],Kk=[di,aj,bi,cj,fi,Fj,Nj,ti],Lk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.yk;return b},vi,vi,vi,vi,vi,vi,vi],Mk=[function(a,b){this.A-=-1===this.F?this.B.qk:this.B.nk;return b},wi,wi,wi,wi,wi,wi,wi],Bk=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<>8-b)&255):d=a<<7;fg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<<8-b,c=(a>>>b|d)&255):d=a;fg(this,c,d,128)}return c}, -function(a,b){var c=a;if(b&=this.Ta){var d=gg(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<<8-b|a<<9-b)&255,d=a<<8-b):d<<=7;fg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;8>>b-1,a=b>>>1&255,ag(this,a,128,b&1,a&128);return a},wi,function(a,b){if(b&=this.Ta)9>24>>b-1,a=b>>1&255,ag(this,a,128,b&1);return a}],Ck=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<>16-b)&65535):d=a<<15;fg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<<16-b,c=(a>>>b|d)&65535):d=a;fg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=gg(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<<16-b):d<<=15;fg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;16>>b-1,a=b>>>1&65535,ag(this,a,32768,b&1,a&32768);return a},wi,function(a,b){if(b&=this.Ta)17>16>>b-1,a=b>>1&65535,ag(this,a,32768,b&1);return a}],Dk=[function(a,b){var c=a;if(b&=this.Ta)c=a<>>32-b,fg(this,c,a<>>b|d;fg(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ta)c=gg(this),c=a<>>32-b>>>1,fg(this,c,a<>>b|c<<32-b|a<<32-b<<1,fg(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ta)a<<=b-1,c=a<<1,ag(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ta)b=a>>>b-1,a=b>>>1,ag(this,a,-2147483648, -b&1,a&-2147483648);return a},wi,function(a,b){if(b&=this.Ta)b=a>>b-1,a=b>>1,ag(this,a,-2147483648,b&1);return a}],Ok=[function(a,b){b=this.ra();ag(this,a&b,128);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},wi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^255},function(a){var b=-a|0;Uf(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&255},function(a){this.Ba=(this.D&255)*a&65535;this.Ba&65280?(bg(this),dg(this)):(cg(this),eg(this));this.vc=!0;this.A-= --1===this.C?this.B.uk:this.B.tk;this.N|=2;return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ba=b&65535;127b?(bg(this),dg(this)):(cg(this),eg(this));this.vc=!0;this.A-=-1===this.C?this.B.Zj:this.B.Yj;this.N|=2;return a},function(a,b){if(!a)return dk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d= -(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086==this.ca&&-128==d)return dk.call(this),a;this.Ba=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Vj:this.B.Uj;this.N|=2;return a}],Pk=[function(a,b){b=this.Ea();ag(this,a&b,this.Fb);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},wi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^this.R},function(a){var b=-a|0;Uf(this,0,a,b,this.Fb|63,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&this.R},function(a,b){2==this.V? -(b=this.D&65535,b=b*a|0,this.Ba=b&65535,this.$a=b>>16&65535):(Ci.call(this,a,this.D),80563==this.we&&68657152==this.D&&129==a&&(this.$a=0));this.$a?(bg(this),dg(this)):(cg(this),eg(this));this.vc=!0;this.A-=-1===this.C?this.B.wk:this.B.vk;this.N|=2;return a},function(a,b){2==this.V?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ba=b&65535,this.$a=b>>16&65535,b=32767b):(Bi.call(this,a,this.D),b=this.$a!=this.Ba>>31);b?(bg(this),dg(this)):(cg(this),eg(this));this.vc=!0;this.A-=-1===this.C? -this.B.ak:this.B.$j;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return dk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return dk.call(this),a;this.Ba=c&65535;this.$a=b%a&65535}else{if(!Qj.call(this,this.D,this.L,a))return dk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Tj:this.B.Sj;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return dk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.ca&& --32768==d)return dk.call(this),a;this.Ba=d&65535;this.$a=b%c&65535}else{b=this.D;var c=this.L,d=a,e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!Qj.call(this,b,c,d)||this.Ba>2147483647+e||this.$a>2147483647+f?b=!1:(e&&(this.Ba=-this.Ba),f&&(this.$a=-this.$a),b=!0);if(!b)return dk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Xj:this.B.Wj;this.N|=2;return a}],oe=[function(a){var b=a+1|0;Uf(this,a,1,b,190);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b& -255},function(a){var b=a-1|0;Uf(this,a,1,b,190,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&255},wi,wi,wi,wi,wi,wi],pe=[function(a){var b=a+1|0;Uf(this,a,1,b,this.Fb|62);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){var b=a-1|0;Uf(this,a,1,b,this.Fb|62,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){ge(this,A(this));C(this,a);this.A-=-1===this.C?this.B.Pj:this.B.Oj;this.N|=2;return a},function(a){if(-1===this.C)return wi.call(this,a);this.ta= -this.Aa;Zj.call(this,a,this.ja(this.C+this.V));this.A-=this.B.Mj;this.N|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.jk:this.B.ik;this.N|=2;return a},function(a){if(-1===this.C)return wi.call(this,a);ke(this,a,this.ja(this.C+this.V));this.A-=this.B.gk;this.N|=2;return a},function(a){var b=a;this.N&512&&(a=a-2&65535,80286>this.ca&&(b=a));ge(this,b);this.A-=-1===this.C?this.B.Ic:this.B.Ak;this.N|=2;return a},wi]; -function We(){this.ma.call(this,Jj);this.A-=-1===this.C?6:13}function Xe(){this.za.call(this,Ij);this.A-=-1===this.C?12:19}var Oe=Array(256);Oe[0]=function(){16>(this.Ia(this.da)&56)&&(this.N|=1);this.rb.call(this,this.nj,Xj)};Oe[1]=function(){this.Ia(this.da)&16||(this.N|=1);this.rb.call(this,Qk,Xj)};Oe[2]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Di)};Oe[3]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Ji)}; -Oe[5]=function(){this.Ma?y.call(this,13,0,0,!0):(lg(this,this.ja(2054)),this.J=this.ja(2086),this.K=this.ja(2088),this.M=this.ja(2090),this.G=this.ja(2094),this.L=this.ja(2096),this.I=this.ja(2098),this.D=this.ja(2100),Vd(this.oa,2102,this.ja(2084)),Vd(this.Z,2108,this.ja(2082)),Vd(this.Y,2114,this.ja(2080)),Vd(this.Ca,2120,this.ja(2078)),je(this,this.ja(2072)),C(this,this.ja(2074)),Zd(this,this.ja(2092)),this.Kb=this.ja(2126)|this.Ia(2128)<<16,this.Pc=this.Kb+this.ja(2130),this.Pb=this.ja(2138)| -this.Ia(2140)<<16,this.cd=this.Pb+this.ja(2142),Vd(this.Eb,2132,this.ja(2076)),Vd(this.la,2144,this.ja(2070)),this.A-=195)};Oe[6]=function(){this.Ma?y.call(this,13,0):(this.qa&=-9,this.A-=2)};Oe[11]=re;Oe[166]=re;Oe[255]=re;var B=[];B[5]=re; -B[7]=function(){if(this.Ma)y.call(this,13,0,0,!0);else{var a=this.oa.bc(this.J&this.wa,204);if(-1!==a){Sj.call(this,this.ia(a));var b=this.ia(a+168),c=(b&24576)>>13;je(this,this.ia(a+4),c);this.Kb=this.ia(a+112);this.Pc=this.Kb+this.ia(a+116);this.Pb=this.ia(a+100);this.cd=this.Pb+this.ia(a+104);Td(this.Eb,this.ia(a+56),this.ia(a+120),this.ia(a+124),this.ia(a+128));Td(this.la,this.ia(a+52),this.ia(a+84),this.ia(a+88),this.ia(a+92));this.J=this.ia(a+12);this.K=this.ia(a+16);this.M=this.ia(a+20);this.G= -this.ia(a+28);this.L=this.ia(a+32);this.I=this.ia(a+36);this.D=this.ia(a+40);Td(this.Ha,this.ia(a+60),this.ia(a+132),this.ia(a+136),this.ia(a+140));Td(this.Ga,this.ia(a+64),this.ia(a+144),this.ia(a+148),this.ia(a+152));Td(this.Ca,this.ia(a+68),this.ia(a+156),this.ia(a+160),this.ia(a+164));Td(this.Y,this.ia(a+72),b,this.ia(a+172),this.ia(a+176));Td(this.Z,this.ia(a+76),this.ia(a+180),this.ia(a+184),this.ia(a+188));Td(this.oa,this.ia(a+80),this.ia(a+192),this.ia(a+196),this.ia(a+200));C(this,this.ia(a+ -8));Zd(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=xk;B[17]=yk;B[18]=zk;B[19]=Ak;B[32]=function(){if(this.Ma)y.call(this,13,0);else{var a,b=this.ra();switch((b&56)>>3){case 0:a=this.qa;break;case 2:a=this.Cd;break;case 3:a=this.Wc;break;default:Pe.call(this);return}hf(this,b&7,a);this.A-=6}};B[33]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Pe.call(this):(hf(this,a&7,this.Qb[b]),this.A-=22)}}; -B[34]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=gf(this,a&7);switch((a&56)>>3){case 0:Sj.call(this,b);this.A-=10;break;case 2:this.Cd=b;this.A-=4;break;case 3:le.call(this,b);this.A-=5;break;default:Pe.call(this)}}};B[35]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Pe.call(this):(a=gf(this,a&7),a!=this.Qb[b]&&(Mf(this,!1),this.Qb[b]=a,Mf(this,!0)),this.A-=4>b?22:14)}}; -B[36]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Pe.call(this):(hf(this,a&7,this.dg[b]),this.A-=12)}};B[38]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Pe.call(this):(this.dg[b]=gf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ea();$f(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[129]=function(){var a=this.Ea();$f(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; -B[130]=function(){var a=this.Ea();Vf(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[131]=function(){var a=this.Ea();Vf(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[132]=function(){var a=this.Ea();Yf(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[133]=function(){var a=this.Ea();Yf(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[134]=function(){var a=this.Ea();Vf(this)||Yf(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra}; -B[135]=function(){var a=this.Ea();Vf(this)||Yf(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[136]=function(){var a=this.Ea();Zf(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[137]=function(){var a=this.Ea();Zf(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[138]=function(){var a=this.Ea();Wf(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[139]=function(){var a=this.Ea();Wf(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; -B[140]=function(){var a=this.Ea();!Zf(this)!=!$f(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[141]=function(){var a=this.Ea();!Zf(this)==!$f(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[142]=function(){var a=this.Ea();Yf(this)||!Zf(this)!=!$f(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[143]=function(){var a=this.Ea();Yf(this)||!Zf(this)!=!$f(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[144]=function(){Tj.call(this,dj)}; -B[145]=function(){Tj.call(this,dj)};B[146]=function(){Tj.call(this,ej)};B[147]=function(){Tj.call(this,fj)};B[148]=function(){Tj.call(this,gj)};B[149]=function(){Tj.call(this,hj)};B[150]=function(){Tj.call(this,ij)};B[151]=function(){Tj.call(this,jj)};B[152]=function(){Tj.call(this,kj)};B[153]=function(){Tj.call(this,lj)};B[154]=function(){Tj.call(this,mj)};B[155]=function(){Tj.call(this,nj)};B[156]=function(){Tj.call(this,oj)};B[157]=function(){Tj.call(this,pj)};B[158]=function(){Tj.call(this,qj)}; -B[159]=function(){Tj.call(this,rj)};B[160]=function(){de(this,this.Ga.U,this.V,2);this.A-=this.B.re};B[161]=function(){this.ta=this.Aa;var a=Xd(this);this.Ga.load(a);this.A-=this.B.nc;this.ta=-1};B[163]=function(){this.za.call(this,oi);-1!==this.C&&(this.A-=6)};B[164]=function(){this.za.call(this,2==this.V?sj:uj);this.A-=-1===this.C?3:7};B[165]=function(){this.za.call(this,2==this.V?wj:xj);this.A-=-1===this.C?3:7};B[168]=function(){de(this,this.Ha.U,this.V,2);this.A-=this.B.re}; -B[169]=function(){this.ta=this.Aa;var a=Xd(this);this.Ha.load(a);this.A-=this.B.nc;this.ta=-1};B[171]=function(){this.za.call(this,ri);-1!==this.C&&(this.A-=5)};B[172]=function(){this.za.call(this,2==this.V?yj:Aj);this.A-=-1===this.C?3:7};B[173]=function(){this.za.call(this,2==this.V?Cj:Dj);this.A-=-1===this.C?3:7};B[175]=function(){this.ma.call(this,2==this.V?yi:Ai)};B[178]=function(){this.ma.call(this,Ki)};B[179]=function(){this.za.call(this,qi);-1!==this.C&&(this.A-=5)}; -B[180]=function(){this.ma.call(this,Hi)};B[181]=function(){this.ma.call(this,Ii)}; -B[182]=function(){this.kc.call(this,Mi);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|this.D&255;break;case 1:this.I=this.I&~this.R|this.I&255;break;case 2:this.L=this.L&~this.R|this.L&255;break;case 3:this.G=this.G&~this.R|this.G&255;break;case 4:this.Hc=this.Hc&~this.R|this.D>>8&255;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I>>8&255;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L>>8&255;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G>>8&255,this.G=this.ya}this.A-= --1===this.C?3:6};B[183]=function(){be(this,2);this.ma.call(this,Ni);switch(this.ga>>3&7){case 0:this.D=this.D&65535;break;case 1:this.I=this.I&65535;break;case 2:this.L=this.L&65535;break;case 3:this.G=this.G&65535;break;case 4:this.Hc=this.Hc&65535;break;case 5:this.M=this.M&65535;break;case 6:this.K=this.K&65535;break;case 7:this.J=this.J&65535}this.A-=-1===this.C?3:6};B[186]=function(){this.rb.call(this,Rk,this.ra)};B[187]=function(){this.za.call(this,pi);-1!==this.C&&(this.A-=5)}; -B[188]=function(){this.ma.call(this,ii)};B[189]=function(){this.ma.call(this,ji)}; -B[190]=function(){this.kc.call(this,Mi);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|(this.D&255)<<24>>24&this.R;break;case 1:this.I=this.I&~this.R|(this.I&255)<<24>>24&this.R;break;case 2:this.L=this.L&~this.R|(this.L&255)<<24>>24&this.R;break;case 3:this.G=this.G&~this.R|(this.G&255)<<24>>24&this.R;break;case 4:this.Hc=this.Hc&~this.R|this.D<<16>>24&this.R;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I<<16>>24&this.R;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L<<16>>24& -this.R;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G<<16>>24&this.R,this.G=this.ya}this.A-=-1===this.C?3:6};B[191]=function(){be(this,2);this.ma.call(this,Ni);switch(this.ga>>3&7){case 0:this.D=this.D<<16>>16;break;case 1:this.I=this.I<<16>>16;break;case 2:this.L=this.L<<16>>16;break;case 3:this.G=this.G<<16>>16;break;case 4:this.Hc=this.Hc<<16>>16;break;case 5:this.M=this.M<<16>>16;break;case 6:this.K=this.K<<16>>16;break;case 7:this.J=this.J<<16>>16}this.A-=-1===this.C?3:6}; -var Nf=[function(){this.A-=2+(-1===this.C?0:1);return this.Eb.U},function(){this.A-=2+(-1===this.C?0:1);return this.la.U},function(a){this.N|=2;this.Eb.load(a);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;-1!==this.la.load(a)&&(this.fb(this.la.Lb+4,this.la.jb|=512),this.la.type|=512);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&2048!=(this.xb.jb&2560)&&(this.xb.qc>=this.Ma&&this.xb.qc>=(a&3)||7168==(this.xb.jb&7168)))return kg(this), -a;ig(this);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&512==(this.xb.jb&2560)&&this.xb.qc>=this.Ma&&this.xb.qc>=(a&3))return kg(this),a;ig(this);return a},wi,wi],qe=[Me,Me,Me,Me,Me,Me,wi,wi],Qk=[function(a){if(-1===this.C)y.call(this,6);else{a=this.Pc-this.Kb;var b=this.Kb;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=11}return a},function(a){if(-1===this.C)y.call(this,6);else{a=this.cd-this.Pb;var b=this.Pb; -80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=12}return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Kb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.Pc=this.Kb+a,this.N|=2,this.A-=11);return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Pb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.cd=this.Pb+a,this.N|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.C?0:1);return this.qa},wi,function(a){this.O& -131072?y.call(this,6):(lg(this,a),this.A-=-1===this.C?3:6,this.N|=2);return a},wi],Rk=[wi,wi,wi,wi,ki,ni,mi,li]; -function Sk(a){ab.call(this,"ChipSet",a,32768);var b=a.model;b&&!Tk[b]&&Wa("Unrecognized ChipSet model: "+b);this.ca=Tk[b]||Uk;this.C=[];b=Vk(a[Wk]);this.C[0]=[b,b];null==b&&(this.N=[360,360],(b=a.floppies)&&b.length&&(this.N=b),Xk(this,Yk,this.N.length),Xk(this,Zk,a.monitor||(this.ca=Kg&&(this.za=this.ha=2);this.O=a.scaleTimers||!1;this.Ma=a.rtcDate;this.Ga=!1;a.sound&&(this.Da=this.la=null,window&&(this.Da=window.AudioContext|| -window.webkitAudioContext),this.Da&&(this.la=new this.Da));this.reset(!0);zb(this)}ba(Sk,ab);l=Sk.prototype;l.Cb=function(a,b,c){switch(b){case Wk:return this.na[b]=c,al(this,0,b),!0;case $k:if((this.ca|0)==bl||this.ca==cl)return this.na[b]=c,al(this,1,b),!0;break;case dl:return this.na[b]=c,!0}return!1}; -l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.Tc=Ob(a,"FPU");Xk(this,el,this.Tc?1:0,!0);this.B=Ob(a,"Keyboard");this.Ba=c.T.sd/fl;Ec(b,this,gl);Ic(b,this,hl);this.cathis.lc)y.call(this,13,0);else{var a=this.B.dk;this.Uc=-1;jk.call(this,3,null,a)}},function(){var a=this.ra();if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var b;a:{b=this.Yf[a];if(void 0!==b)for(var c=0;cthis.lc)y.call(this,13,0);else{var a=this.B.ek;this.Uc=-1;jk.call(this,4,null,a)}else this.A-=this.B.fk},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{this.Vc=this.Y.U;this.ta=this.Aa;this.A-=this.B.bk;if(this.qa&1&&this.O&16384){var a=this.ja(this.la.ua+0);ie(this.Z,a,!1)}else{var a=this.Ma,b=fe(this),c=fe(this),d=fe(this);if(this.O&131072)d=d&131071|this.O&-131072;else if(d&131072){var e=fe(this),f=fe(this),g=fe(this),h=fe(this),k=fe(this),m=fe(this);je(this,!0,!0);ge(this, +f);he(this,e);oe(this,g);ne(this,h);this.Ga.load(k);this.Ha.load(m)}null!=te(this,b,c,!1)&&(se(this,d,a),this.ag&&Uf(this,this.da))}this.Vc=this.ta=-1}},function(){this.kd.call(this,Kk,dk)},function(){this.rb.call(this,2==this.V?Lk:Mk,dk)},function(){this.kd.call(this,Kk,ek)},function(){this.rb.call(this,2==this.V?Lk:Mk,ek)},function(){var a=this.ra();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;jg(this,this.D,128);this.A-=this.B.Hj}else mk.call(this)},function(){var a=this.D&255,b=(this.D>> +8&255)*this.ra()|0,c=a+b|0;this.D=this.D&-65536|c&255;cg(this,a,b,c,191);this.A-=this.B.Gj},function(){this.D=this.D&-256|(dg(this)?255:0);this.A-=2},function(){this.D=this.D&-256|zg(this,this.Da,this.G+(this.D&255));this.A-=this.B.Gk},function(){Rk.call(this,216)},function(){Rk.call(this,217)},function(){Rk.call(this,218)},function(){Rk.call(this,219)},function(){Rk.call(this,220)},function(){Rk.call(this,221)},function(){Rk.call(this,222)},function(){Rk.call(this,223)},function(){var a=this.S(), +b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&!gg(this)?(C(this,A(this)+a),this.A-=this.B.mk):this.A-=this.B.Hh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&gg(this)?(C(this,A(this)+a),this.A-=this.B.Ih):this.A-=this.B.Jh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b?(C(this,A(this)+a),this.A-=this.B.lk):this.A-=this.B.Hh},function(){var a=this.S();this.I&this.wa?this.A-=this.B.Jh:(C(this,A(this)+a),this.A-=this.B.Ih)},function(){var a=this.ra(); +xg(this,a,1,!0)&&(this.D=this.D&-256|Pc(this.ka,a,1,this.da-2)&255,this.A-=this.B.Ch)},function(){var a=this.ra();xg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Pc(this.ka,a,this.V,this.da-2)&this.R,this.A-=this.B.Ch)},function(){var a=this.ra();xg(this,a,1,!1)&&(Tc(this.ka,a,1,this.D&255,this.da-2),this.A-=this.B.Qh)},function(){var a=this.ra();xg(this,a,this.V,!1)&&(Tc(this.ka,a,this.V,this.D&this.R,this.da-2),this.A-=this.B.Qh)},function(){var a=this.Ea(),b=A(this),a=b+a;pe(this,b);C(this,a);this.A-= +this.B.Lj},function(){var a=this.Ea();C(this,A(this)+a);this.A-=this.B.Dh},function(){te(this,this.Ea(),Hg(this));this.A-=this.B.hk},function(){var a=this.S();C(this,A(this)+a);this.A-=this.B.Dh},function(){var a=this.L&65535;xg(this,a,1,!0)&&(this.D=this.D&-256|Pc(this.ka,a,1,this.da-1)&255,this.A-=this.B.Bh)},function(){var a=this.L&65535;xg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Pc(this.ka,a,this.V,this.da-1)&this.R,this.A-=this.B.Bh)},function(){var a=this.L&65535;xg(this,a,1,!1)&&(Tc(this.ka, +a,1,this.D&255,this.da-1),this.A-=this.B.Ph)},function(){var a=this.L&65535;xg(this,a,2,!1)&&(Tc(this.ka,a,this.V,this.D&this.R,this.da-1),this.A-=this.B.Ph)},Sk,Sk,function(){this.N|=132;this.A-=this.B.bd},function(){this.N|=68;this.A-=this.B.bd},function(){this.O&131072?y.call(this,13,0):(this.Za|=4,this.A-=2,this.ba&&t(this,-2147483648)?(bg(this),this.ba.Jb()):this.O&512||(this.ba&&bg(this),this.Jb()))},function(){dg(this)?lg(this):kg(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,Xk, +gk);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R)},function(){this.vc=!1;this.rb.call(this,Yk,gk);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R,this.L=this.L&~this.R|this.$a&this.R)},function(){lg(this);this.A-=2},function(){kg(this);this.A-=2},function(){this.Ma>this.lc?y.call(this,13,0):(this.O&=-513,this.A-=this.B.Jj)},function(){this.Ma>this.lc?y.call(this,13,0):(this.O|=512,this.N|=4,this.A-=2)},function(){this.O&=-1025;this.A-=2},function(){this.O|=1024;this.A-=2},function(){this.kd.call(this, +Be,gk)},function(){this.rb.call(this,Ce,gk)}],Fk=[li,ij,ji,kj,ni,Nj,Vj,Bi],Tk=[mi,jj,ki,lj,oi,Oj,Wj,Ci],Uk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.yk;return b},Ei,Ei,Ei,Ei,Ei,Ei,Ei],Vk=[function(a,b){this.A-=-1===this.F?this.B.qk:this.B.nk;return b},Fi,Fi,Fi,Fi,Fi,Fi,Fi],Kk=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<>8-b)&255):d=a<<7;og(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<<8-b,c=(a>>>b|d)&255):d=a;og(this,c,d,128)}return c}, +function(a,b){var c=a;if(b&=this.Ta){var d=pg(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<<8-b|a<<9-b)&255,d=a<<8-b):d<<=7;og(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;8>>b-1,a=b>>>1&255,jg(this,a,128,b&1,a&128);return a},Fi,function(a,b){if(b&=this.Ta)9>24>>b-1,a=b>>1&255,jg(this,a,128,b&1);return a}],Lk=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<>16-b)&65535):d=a<<15;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<<16-b,c=(a>>>b|d)&65535):d=a;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=pg(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<<16-b):d<<=15;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;16>>b-1,a=b>>>1&65535,jg(this,a,32768,b&1,a&32768);return a},Fi,function(a,b){if(b&=this.Ta)17>16>>b-1,a=b>>1&65535,jg(this,a,32768,b&1);return a}],Mk=[function(a,b){var c=a;if(b&=this.Ta)c=a<>>32-b,og(this,c,a<>>b|d;og(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ta)c=pg(this),c=a<>>32-b>>>1,og(this,c,a<>>b|c<<32-b|a<<32-b<<1,og(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ta)a<<=b-1,c=a<<1,jg(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ta)b=a>>>b-1,a=b>>>1,jg(this,a,-2147483648, +b&1,a&-2147483648);return a},Fi,function(a,b){if(b&=this.Ta)b=a>>b-1,a=b>>1,jg(this,a,-2147483648,b&1);return a}],Xk=[function(a,b){b=this.ra();jg(this,a&b,128);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},Fi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^255},function(a){var b=-a|0;cg(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&255},function(a){this.Ba=(this.D&255)*a&65535;this.Ba&65280?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-= +-1===this.C?this.B.uk:this.B.tk;this.N|=2;return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ba=b&65535;127b?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C?this.B.Zj:this.B.Yj;this.N|=2;return a},function(a,b){if(!a)return mk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d= +(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086==this.ca&&-128==d)return mk.call(this),a;this.Ba=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Vj:this.B.Uj;this.N|=2;return a}],Yk=[function(a,b){b=this.Ea();jg(this,a&b,this.Fb);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},Fi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^this.R},function(a){var b=-a|0;cg(this,0,a,b,this.Fb|63,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&this.R},function(a,b){2==this.V? +(b=this.D&65535,b=b*a|0,this.Ba=b&65535,this.$a=b>>16&65535):(Li.call(this,a,this.D),80563==this.we&&68657152==this.D&&129==a&&(this.$a=0));this.$a?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C?this.B.wk:this.B.vk;this.N|=2;return a},function(a,b){2==this.V?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ba=b&65535,this.$a=b>>16&65535,b=32767b):(Ki.call(this,a,this.D),b=this.$a!=this.Ba>>31);b?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C? +this.B.ak:this.B.$j;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return mk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return mk.call(this),a;this.Ba=c&65535;this.$a=b%a&65535}else{if(!Zj.call(this,this.D,this.L,a))return mk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Tj:this.B.Sj;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return mk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.ca&& +-32768==d)return mk.call(this),a;this.Ba=d&65535;this.$a=b%c&65535}else{b=this.D;var c=this.L,d=a,e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!Zj.call(this,b,c,d)||this.Ba>2147483647+e||this.$a>2147483647+f?b=!1:(e&&(this.Ba=-this.Ba),f&&(this.$a=-this.$a),b=!0);if(!b)return mk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Xj:this.B.Wj;this.N|=2;return a}],Be=[function(a){var b=a+1|0;cg(this,a,1,b,190);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b& +255},function(a){var b=a-1|0;cg(this,a,1,b,190,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&255},Fi,Fi,Fi,Fi,Fi,Fi],Ce=[function(a){var b=a+1|0;cg(this,a,1,b,this.Fb|62);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){var b=a-1|0;cg(this,a,1,b,this.Fb|62,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){pe(this,A(this));C(this,a);this.A-=-1===this.C?this.B.Pj:this.B.Oj;this.N|=2;return a},function(a){if(-1===this.C)return Fi.call(this,a);this.ta= +this.Aa;ik.call(this,a,this.ja(this.C+this.V));this.A-=this.B.Mj;this.N|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.jk:this.B.ik;this.N|=2;return a},function(a){if(-1===this.C)return Fi.call(this,a);te(this,a,this.ja(this.C+this.V));this.A-=this.B.gk;this.N|=2;return a},function(a){var b=a;this.N&512&&(a=a-2&65535,80286>this.ca&&(b=a));pe(this,b);this.A-=-1===this.C?this.B.Ic:this.B.Ak;this.N|=2;return a},Fi]; +function hf(){this.ma.call(this,Sj);this.A-=-1===this.C?6:13}function jf(){this.za.call(this,Rj);this.A-=-1===this.C?12:19}var Xe=Array(256);Xe[0]=function(){16>(this.Ia(this.da)&56)&&(this.N|=1);this.rb.call(this,this.nj,gk)};Xe[1]=function(){this.Ia(this.da)&16||(this.N|=1);this.rb.call(this,Zk,gk)};Xe[2]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Mi)};Xe[3]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Si)}; +Xe[5]=function(){this.Ma?y.call(this,13,0,0,!0):(wg(this,this.ja(2054)),this.J=this.ja(2086),this.K=this.ja(2088),this.M=this.ja(2090),this.G=this.ja(2094),this.L=this.ja(2096),this.I=this.ja(2098),this.D=this.ja(2100),de(this.oa,2102,this.ja(2084)),de(this.Z,2108,this.ja(2082)),de(this.Y,2114,this.ja(2080)),de(this.Ca,2120,this.ja(2078)),se(this,this.ja(2072)),C(this,this.ja(2074)),he(this,this.ja(2092)),this.Kb=this.ja(2126)|this.Ia(2128)<<16,this.Pc=this.Kb+this.ja(2130),this.Pb=this.ja(2138)| +this.Ia(2140)<<16,this.cd=this.Pb+this.ja(2142),de(this.Eb,2132,this.ja(2076)),de(this.la,2144,this.ja(2070)),this.A-=195)};Xe[6]=function(){this.Ma?y.call(this,13,0):(this.qa&=-9,this.A-=2)};Xe[11]=Ee;Xe[166]=Ee;Xe[255]=Ee;var B=[];B[5]=Ee; +B[7]=function(){if(this.Ma)y.call(this,13,0,0,!0);else{var a=this.oa.bc(this.J&this.wa,204);if(-1!==a){bk.call(this,this.ia(a));var b=this.ia(a+168),c=(b&24576)>>13;se(this,this.ia(a+4),c);this.Kb=this.ia(a+112);this.Pc=this.Kb+this.ia(a+116);this.Pb=this.ia(a+100);this.cd=this.Pb+this.ia(a+104);be(this.Eb,this.ia(a+56),this.ia(a+120),this.ia(a+124),this.ia(a+128));be(this.la,this.ia(a+52),this.ia(a+84),this.ia(a+88),this.ia(a+92));this.J=this.ia(a+12);this.K=this.ia(a+16);this.M=this.ia(a+20);this.G= +this.ia(a+28);this.L=this.ia(a+32);this.I=this.ia(a+36);this.D=this.ia(a+40);be(this.Ha,this.ia(a+60),this.ia(a+132),this.ia(a+136),this.ia(a+140));be(this.Ga,this.ia(a+64),this.ia(a+144),this.ia(a+148),this.ia(a+152));be(this.Ca,this.ia(a+68),this.ia(a+156),this.ia(a+160),this.ia(a+164));be(this.Y,this.ia(a+72),b,this.ia(a+172),this.ia(a+176));be(this.Z,this.ia(a+76),this.ia(a+180),this.ia(a+184),this.ia(a+188));be(this.oa,this.ia(a+80),this.ia(a+192),this.ia(a+196),this.ia(a+200));C(this,this.ia(a+ +8));he(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=Gk;B[17]=Hk;B[18]=Ik;B[19]=Jk;B[32]=function(){if(this.Ma)y.call(this,13,0);else{var a,b=this.ra();switch((b&56)>>3){case 0:a=this.qa;break;case 2:a=this.Cd;break;case 3:a=this.Wc;break;default:Ye.call(this);return}wf(this,b&7,a);this.A-=6}};B[33]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Ye.call(this):(wf(this,a&7,this.Qb[b]),this.A-=22)}}; +B[34]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=vf(this,a&7);switch((a&56)>>3){case 0:bk.call(this,b);this.A-=10;break;case 2:this.Cd=b;this.A-=4;break;case 3:ue.call(this,b);this.A-=5;break;default:Ye.call(this)}}};B[35]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Ye.call(this):(a=vf(this,a&7),a!=this.Qb[b]&&(Vf(this,!1),this.Qb[b]=a,Vf(this,!0)),this.A-=4>b?22:14)}}; +B[36]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Ye.call(this):(wf(this,a&7,this.dg[b]),this.A-=12)}};B[38]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Ye.call(this):(this.dg[b]=vf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ea();ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[129]=function(){var a=this.Ea();ig(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; +B[130]=function(){var a=this.Ea();dg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[131]=function(){var a=this.Ea();dg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[132]=function(){var a=this.Ea();gg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[133]=function(){var a=this.Ea();gg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[134]=function(){var a=this.Ea();dg(this)||gg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra}; +B[135]=function(){var a=this.Ea();dg(this)||gg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[136]=function(){var a=this.Ea();hg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[137]=function(){var a=this.Ea();hg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[138]=function(){var a=this.Ea();eg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[139]=function(){var a=this.Ea();eg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; +B[140]=function(){var a=this.Ea();!hg(this)!=!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[141]=function(){var a=this.Ea();!hg(this)==!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[142]=function(){var a=this.Ea();gg(this)||!hg(this)!=!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[143]=function(){var a=this.Ea();gg(this)||!hg(this)!=!ig(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[144]=function(){ck.call(this,mj)}; +B[145]=function(){ck.call(this,mj)};B[146]=function(){ck.call(this,nj)};B[147]=function(){ck.call(this,oj)};B[148]=function(){ck.call(this,pj)};B[149]=function(){ck.call(this,qj)};B[150]=function(){ck.call(this,rj)};B[151]=function(){ck.call(this,sj)};B[152]=function(){ck.call(this,tj)};B[153]=function(){ck.call(this,uj)};B[154]=function(){ck.call(this,vj)};B[155]=function(){ck.call(this,wj)};B[156]=function(){ck.call(this,xj)};B[157]=function(){ck.call(this,yj)};B[158]=function(){ck.call(this,zj)}; +B[159]=function(){ck.call(this,Aj)};B[160]=function(){me(this,this.Ga.U,this.V,2);this.A-=this.B.re};B[161]=function(){this.ta=this.Aa;var a=fe(this);this.Ga.load(a);this.A-=this.B.nc;this.ta=-1};B[163]=function(){this.za.call(this,xi);-1!==this.C&&(this.A-=6)};B[164]=function(){this.za.call(this,2==this.V?Bj:Dj);this.A-=-1===this.C?3:7};B[165]=function(){this.za.call(this,2==this.V?Fj:Gj);this.A-=-1===this.C?3:7};B[168]=function(){me(this,this.Ha.U,this.V,2);this.A-=this.B.re}; +B[169]=function(){this.ta=this.Aa;var a=fe(this);this.Ha.load(a);this.A-=this.B.nc;this.ta=-1};B[171]=function(){this.za.call(this,Ai);-1!==this.C&&(this.A-=5)};B[172]=function(){this.za.call(this,2==this.V?Hj:Jj);this.A-=-1===this.C?3:7};B[173]=function(){this.za.call(this,2==this.V?Lj:Mj);this.A-=-1===this.C?3:7};B[175]=function(){this.ma.call(this,2==this.V?Hi:Ji)};B[178]=function(){this.ma.call(this,cj)};B[179]=function(){this.za.call(this,zi);-1!==this.C&&(this.A-=5)}; +B[180]=function(){this.ma.call(this,Qi)};B[181]=function(){this.ma.call(this,Ri)}; +B[182]=function(){this.kc.call(this,ej);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|this.D&255;break;case 1:this.I=this.I&~this.R|this.I&255;break;case 2:this.L=this.L&~this.R|this.L&255;break;case 3:this.G=this.G&~this.R|this.G&255;break;case 4:this.Hc=this.Hc&~this.R|this.D>>8&255;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I>>8&255;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L>>8&255;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G>>8&255,this.G=this.ya}this.A-= +-1===this.C?3:6};B[183]=function(){ke(this,2);this.ma.call(this,fj);switch(this.ga>>3&7){case 0:this.D=this.D&65535;break;case 1:this.I=this.I&65535;break;case 2:this.L=this.L&65535;break;case 3:this.G=this.G&65535;break;case 4:this.Hc=this.Hc&65535;break;case 5:this.M=this.M&65535;break;case 6:this.K=this.K&65535;break;case 7:this.J=this.J&65535}this.A-=-1===this.C?3:6};B[186]=function(){this.rb.call(this,$k,this.ra)};B[187]=function(){this.za.call(this,yi);-1!==this.C&&(this.A-=5)}; +B[188]=function(){this.ma.call(this,ri)};B[189]=function(){this.ma.call(this,si)}; +B[190]=function(){this.kc.call(this,ej);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|(this.D&255)<<24>>24&this.R;break;case 1:this.I=this.I&~this.R|(this.I&255)<<24>>24&this.R;break;case 2:this.L=this.L&~this.R|(this.L&255)<<24>>24&this.R;break;case 3:this.G=this.G&~this.R|(this.G&255)<<24>>24&this.R;break;case 4:this.Hc=this.Hc&~this.R|this.D<<16>>24&this.R;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I<<16>>24&this.R;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L<<16>>24& +this.R;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G<<16>>24&this.R,this.G=this.ya}this.A-=-1===this.C?3:6};B[191]=function(){ke(this,2);this.ma.call(this,fj);switch(this.ga>>3&7){case 0:this.D=this.D<<16>>16;break;case 1:this.I=this.I<<16>>16;break;case 2:this.L=this.L<<16>>16;break;case 3:this.G=this.G<<16>>16;break;case 4:this.Hc=this.Hc<<16>>16;break;case 5:this.M=this.M<<16>>16;break;case 6:this.K=this.K<<16>>16;break;case 7:this.J=this.J<<16>>16}this.A-=-1===this.C?3:6}; +var Wf=[function(){this.A-=2+(-1===this.C?0:1);return this.Eb.U},function(){this.A-=2+(-1===this.C?0:1);return this.la.U},function(a){this.N|=2;this.Eb.load(a);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;-1!==this.la.load(a)&&(this.fb(this.la.Lb+4,this.la.jb|=512),this.la.type|=512);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&2048!=(this.xb.jb&2560)&&(this.xb.qc>=this.Ma&&this.xb.qc>=(a&3)||7168==(this.xb.jb&7168)))return vg(this), +a;rg(this);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&512==(this.xb.jb&2560)&&this.xb.qc>=this.Ma&&this.xb.qc>=(a&3))return vg(this),a;rg(this);return a},Fi,Fi],De=[Ve,Ve,Ve,Ve,Ve,Ve,Fi,Fi],Zk=[function(a){if(-1===this.C)y.call(this,6);else{a=this.Pc-this.Kb;var b=this.Kb;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=11}return a},function(a){if(-1===this.C)y.call(this,6);else{a=this.cd-this.Pb;var b=this.Pb; +80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=12}return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Kb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.Pc=this.Kb+a,this.N|=2,this.A-=11);return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Pb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.cd=this.Pb+a,this.N|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.C?0:1);return this.qa},Fi,function(a){this.O& +131072?y.call(this,6):(wg(this,a),this.A-=-1===this.C?3:6,this.N|=2);return a},Fi],$k=[Fi,Fi,Fi,Fi,ti,wi,vi,ui]; +function al(a){nb.call(this,"ChipSet",a,32768);var b=a.model;b&&!bl[b]&&hb("Unrecognized ChipSet model: "+b);this.ca=bl[b]||cl;this.C=[];b=dl(a[el]);this.C[0]=[b,b];null==b&&(this.N=[360,360],(b=a.floppies)&&b.length&&(this.N=b),fl(this,gl,this.N.length),fl(this,hl,a.monitor||(this.ca=eh&&(this.za=this.ha=2);this.O=a.scaleTimers||!1;this.Ma=a.rtcDate;this.Ga=!1;a.sound&&(this.Da=this.la=null,window&&(this.Da=window.AudioContext|| +window.webkitAudioContext),this.Da&&(this.la=new this.Da));this.reset(!0);Jb(this)}ba(al,nb);l=al.prototype;l.Cb=function(a,b,c){switch(b){case el:return this.na[b]=c,jl(this,0,b),!0;case il:if((this.ca|0)==kl||this.ca==ll)return this.na[b]=c,jl(this,1,b),!0;break;case ml:return this.na[b]=c,!0}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.Tc=Xb(a,"FPU");fl(this,nl,this.Tc?1:0,!0);this.B=Xb(a,"Keyboard");this.Ba=c.T.sd/ol;Oc(b,this,pl);Sc(b,this,ql);this.ca=Kg){this.D=El;this.L=0;this.K=Fl;this.oa=0;this.M=Gl|Hl;512<=Il(this)&&(this.M|=Jl);+Kl(this,Zk,void 0)==Ll&&(this.M|=Ml);(this.ca|0)==ol&&(this.M=this.M|Nl|Ol);this.qa= -Pl|Ql;this.Y=Array(8);this.W=0;a&&(this.A=Array(tl));Rl(this,this.Ma);for(a=Sl;a<=Tl;a++)this.A[a]=0;for(a=Ul;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Hd]&Im||(d&&128>8} -l.save=function(){var a=new Of(this);a.set(0,[this.C]);for(var b=[],c=0;c=Kg&&(a.set(5,[this.D,this.L,this.K,this.oa,this.M,this.qa]),a.set(6,[this.Y[7],this.Y,this.W,this.A,this.ma,this.Z]));return a.data()}; -l.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.C=b[0]:(this.C[0][0]=b[0],this.C[1][0]=b[1]&15,this.C[0][1]=b[2],this.C[1][1]=b[3]&15);wl(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;Tm(a,b,c,!0)}function Um(a,b,c){if(b=(a=Vm[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.yc&1<g.nb[0]&&(g.nb[0]=255,g.nb[1]--,0>g.nb[1]&&(g.nb[1]=255)));return h}function jn(a,b,c,d,e,f){var g=a.F[b];t(a,768)&&v(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.zb+"]",null,!0);a=g.oc[c];a.nb[g.zb]=a.pc[g.zb]=e;g.zb^=1}function kn(a,b,c,d){var e=a.F[b],f=e.Mb|ln;e.Mb&=~mn;t(a,768)&&v(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} -function nn(a,b,c,d,e){var f=a.F[b];t(a,768)&&v(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Mb=f.Mb&~(16<>2].oc[b&3],c,d,e)}function rn(a,b,c){b=a.F[b>>2].oc[b&3];b.mg&&b.eh&&b.Ag?(c&&(b.done=c),b.ne||Bn(a,b,!0)):c&&c(!0)} -function Bn(a,b,c){c&&(b.count=b.nb[1]<<8|b.nb[0],b.type=b.mode&Cn,b.rj=b.ng=!1);for(var d=!1;0<=b.count&&(c=b.hg<<16|b.sb[1]<<8|b.sb[0],b.type==Dn?(d=!0,function(c){b.eh.call(b.mg,b.Ag,-1,function(e,g){0>e&&(b.rj||(b.rj=!0),e=255);b.ne||a.ka.fc(c,e);(d=g)&&setTimeout(function(){En(b)||Bn(a,b)},0)})}(c)):b.type==Fn?(c=a.ka.Ia(c),0>b.eh.call(b.mg,b.Ag,c)&&(b.ng=!0)):b.type!=Gn&&(b.ng=!0)),!d&&!En(b););} -function En(a){if(!a.ng&&0<=--a.count&&(a.mode&Hn?(a.sb[0]--,0>a.sb[0]&&(a.sb[0]=255,a.sb[1]--,0>a.sb[1]&&(a.sb[1]=255))):(a.sb[0]++,255>3];b=1<<(b&7);d.ac&b||(d.ac|=b,d.We=c||0,Wn(a))}function Lg(a,b){var c=a.hc[b>>3];b=1<<(b&7);c.ac&b&&(c.ac&=~b,Wn(a))}function Wn(a,b){var c,d=-1;1>=1),xd(a.H,e))),b==jo&&c==no&&Mm(a))}function oo(a,b,c,d){v(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.va:a.ta} -function po(a,b,c,d,e){v(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&qo;b?(e=3,a.va=d):a.ta=d;if(c==ro){if(!(d&so))for(c=0;2>=c;c++)if(d&to<=c;c++)d&to<>=yo;var f=d&zo,g=d&Ao;d&=Bo;if(d==Co)xo(a,e+c);else{e+=c;var h=a.G[e];h.Qf=d;h.mode=g;h.Zg=f;h.pc=[0,0];h.nb=[0,0];h.je=[0,0];h.gd=!1;h.Me=!1;h.le=!1;h.Qe=!1;fo(a,e);b==jo&&c==ko&&Lg(a,lo);b==jo&&c==no&&255==a.hc[0].od&& -a.J==(Do|Eo|Fo|Go)&&(b=a.G[0],b.Mc[0]=b.pc[0],b.Mc[1]=b.pc[1],b.jd=vd(a.H,a.O))}}}function mo(a,b){a=a.G[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.ad?256:65536);return b}function Fd(a,b){a=a.G[b];(b=a.Mc[1]<<8|a.Mc[0])||(b=1==a.ad?256:65536);return b}function xo(a,b){sl(a,b);var c=a.G[b];c.je[0]=c.nb[0];c.je[1]=c.nb[1];c.Me=!0;fo(a,b)}function fo(a,b){a=a.G[b];a.rd=a.Qf==Ho?1:0;a.ad=a.Qf==Io?2:1} -function sl(a,b,c){var d=a.G[b];if(d.le&&(b!=no||a.J&Do)){var e=vd(a.H,a.O),f=(e-d.jd)/a.Ba|0;0>f&&(d.jd=e,f=0);var g=mo(a,b),h=Fd(a,b)-f;d.mode==ho?(0>=h&&(h=0),h||(d.gd=!0,d.le=!1,b||Zg(a,lo))):d.mode==Jo?(d.gd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&Zg(a,lo))):d.mode==Gd&&(h-=f,0>=h&&(d.gd=!d.gd,h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&Zg(a,lo)));d.nb[0]=h&255;d.nb[1]=h>>8&255;c&&(a.jd=0)}return d} -function Ed(a,b){for(var c=0;c=Kg){b=a.H.T.sd;c=vd(a.H,a.O);null==a.Aa&&(a.ma=vd(a.H,a.O),a.Ha=1024,a.Aa=Math.floor(a.H.T.sd/a.Ha),Km(a));c>=a.Z&&(a.A[Gm]|=Ko,a.A[Hd]&Id&&(a.A[Gm]|=Lo,Zg(a,Mo)),a.Z=c+a.Aa);a.A[cm]==a.A[dm]&&a.A[em]==a.A[fm]&&a.A[gm]==a.A[hm]&&(a.A[Gm]|=No,a.A[Hd]&Oo&&(a.A[Gm]|=Lo,Zg(a,Mo)));var d=c-a.ma,e=Math.floor(d/b);if(e&&!(a.A[Hd]&Po)){for(;e--;)if(60<=++a.A[cm]&&(a.A[cm]=0,60<=++a.A[em]&&(a.A[em]=0,24<=++a.A[gm]))){a.A[gm]=0;a.A[im]=a.A[im]% -7+1;var f;f=a.A[Cm];var g=Aa[a.A[Bm]-1];28==g&&(f%4||!(f%100)&&f%400||g++);f=g;++a.A[Am]>f&&(a.A[Am]=1,12<++a.A[Bm]&&(a.A[Bm]=1,a.A[Cm]=(a.A[Cm]+1)%100))}a.A[Gm]|=Qo;a.A[Hd]&Ro&&(a.A[Gm]|=Lo,Zg(a,Mo))}a.ma=c-d%b}}l.Gm=function(a,b){var c=this.ya;this.ga&So&&(this.J&To?c=this.C[0][1]:this.B&&(c=Uo(this.B)));v(this,a,null,b,"PPI_A",c);return c};l.jo=function(a,b,c){v(this,a,b,c,"PPI_A");this.ya=b};l.Hm=function(a,b){var c=this.J;v(this,a,null,b,"PPI_B",c);return c}; -l.ko=function(a,b,c){v(this,a,b,c,"PPI_B");Vo(this,b)};function Vo(a,b){var c=!!(b&Wo),d=!!(a.J&Wo);a.J=b;a.B&&Xo(a.B,!(b&To),!!(b&Go));c!=d&&Mm(a,c)}l.Im=function(a,b){var c=0,c=(this.ca|0)==bl?this.J&Eo?c|this.C[1][1]&Yo:c|this.C[1][1]>>4&1:this.J&Zo?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.J&Do&&sl(this,no).gd&&(c=this.J&Wo?c|$o:c|ap);v(this,a,null,b,"PPI_C",c,32896);return c};l.lo=function(a,b,c){v(this,a,b,c,"PPI_C");this.Ca=b};l.Jm=function(a,b){var c=this.ga;v(this,a,null,b,"PPI_CTRL",c);return c}; -l.mo=function(a,b,c){v(this,a,b,c,"PPI_CTRL");this.ga=b};l.Sl=function(a,b){var c=this.B?Uo(this.B):0;v(this,a,null,b,"8041_KBD",c);this.aa&=~bp;return c};l.tn=function(a,b,c){v(this,a,b,c,"8041_KBD")};l.Rl=function(a,b){var c=this.J;v(this,a,null,b,"8041_CTRL",c);return c};l.sn=function(a,b,c){v(this,a,b,c,"8041_CTRL");Vo(this,b)};l.Tl=function(a,b){var c=this.aa;v(this,a,null,b,"8041_STATUS",c);return c}; -l.Ul=function(a,b){var c=this.oa;v(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(bp|cp);this.B&&dp(this.B);return c}; -l.vn=function(a,b,c){v(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&ep)switch(this.L){case fp:gp(this,b);break;case hp:ip(this,b);break;default:if(gp(this,this.K&~Fl),this.B){a=this.B;c=b;var d=-1;t(a)&&Cb(a,"sendCmd("+r(c)+")");switch(a.F||c){case jp:d=kp;lp(a);break;case mp:a.F&&(c=0);np(a,kp);a.F=c;break;case op:a.F&&(c=0);np(a,kp);a.F=c;break;default:Cb(a,"sendCmd(): unrecognized command")}pp(this,d)}}this.L=b;this.D&=~ep}; -l.Vl=function(a,b){var c=this.J&~(qp|rp)|(vd(this.H)&64?rp:0);v(this,a,null,b,"8042_RWREG",c,16384);return c};l.wn=function(a,b,c){v(this,a,b,c,"8042_RWREG",null,16384);Vo(this,b)};l.Wl=function(a,b){v(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&cp&&(this.D|=bp,this.D&=~cp);return a}; -l.un=function(a,b,c){v(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.L=b;this.D|=ep;a=0;this.L>=sp&&(a=this.L^15,this.L=sp);switch(this.L){case tp:pp(this,this.K);break;case up:gp(this,this.K|Fl);break;case vp:gp(this,this.K&~Fl);this.B&&dp(this.B);break;case wp:this.B&&(a=this.B,a.A=[],t(a)&&Cb(a,"scan codes flushed"));gp(this,this.K|Fl);pp(this,xp);ip(this,Pl|Ql);break;case yp:pp(this,zp);break;case Ap:pp(this,this.M);break;case Bp:pp(this,this.qa);break;case Cp:pp(this,this.K&Fl?0:Dp);break;case sp:a& -1&&Ye(this.H)}};function gp(a,b){a.K=b;a.D=a.D&~Ep|b&Fp;a.B&&Xo(a.B,!!(b&Gp),!(b&Fl))}function pp(a,b,c){0<=b&&(a.oa=b,c?a.D|=bp:(a.D&=~bp,a.D|=cp))}function ip(a,b){a.qa=b;fc(a.ka,!!(b&Ql));b&Pl||Ye(a.H)}function Hp(a,b){a.ca>4)+(c&15),e=!0);if(d==gm||d==hm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Hd&&a&Id&&b&Id&&Km(this)};l.Nk=function(a,b,c){v(this,a,b,c,"NMI");this.da=b};l.Vn=function(a,b,c){v(this,a,b,c,"FPU.CLEAR")};l.Wn=function(a,b,c){v(this,a,b,c,"FPU.RESET");this.Tc&&Fg(this.Tc)}; -l.Xm=function(a){if(t(this,16)&&Nk(this.ba,26,a)){var b=this.H.D>>8;Kf(this.H,a,function(a,d){return function(c){d=vd(a.H)-d;var e,g=a.H.L&255,h=a.H.L>>8,k=a.H.L&255,m=a.H.L>>8;if(2==b||3==b)e=" CH(hour)="+ka(h)+" CL(min)="+r(g)+" DH(sec)="+r(m);else if(4==b||5==b)e=" CX(year)="+ka(a.H.I)+" DH(month)="+r(m)+" DL(day)="+r(k);g=a.ba;h=d;g.message("INT "+r(26)+": C="+(Vf(g.H)?1:0)+(e||"")+" (cycles="+h+(c?",level="+(c+1):"")+")")}}(this,vd(this.H)))}return!0}; -function Mm(a,b){if(a.la)try{void 0!==b?a.Ga=b:b=!!(a.Ga&&a.H&&a.H.ea.vb);var c=Math.round(fl/mo(a,no));if(20>c||2E4>>4,0,this.F,this.C,this.Fd),delete this.Fd);return!0};Pp.prototype.Wb=function(){return!0}; -function Qp(a,b,c,d){if(d)a.Fa("Unable to load system ROM (error "+d+": "+b+")");else{eb(a.xe,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.Fd=e.symbols;if(!a.A.length){Wa("Empty ROM: "+b);return}if(1==a.A.length){Wa(a.A[0]);return}}catch(h){a.Fa("ROM data error: "+h.message);return}else for(b= -c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.A].bf(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.D?b.push(a.D):null!=a.D&&a.D.length&&(b=a.D);for(c=0;c=eh){this.D=Nl;this.L=0;this.K=Ol;this.oa=0;this.M=Pl|Ql;512<=Rl(this)&&(this.M|=Sl);+Tl(this,hl,void 0)==Ul&&(this.M|=Vl);(this.ca|0)==xl&&(this.M=this.M|Wl|Xl);this.qa= +Yl|Zl;this.Y=Array(8);this.W=0;a&&(this.A=Array(Cl));$l(this,this.Ma);for(a=am;a<=bm;a++)this.A[a]=0;for(a=cm;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Rd]&Rm||(d&&128>8} +l.save=function(){var a=new Xf(this);a.set(0,[this.C]);for(var b=[],c=0;c=eh&&(a.set(5,[this.D,this.L,this.K,this.oa,this.M,this.qa]),a.set(6,[this.Y[7],this.Y,this.W,this.A,this.ma,this.Z]));return a.data()}; +l.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.C=b[0]:(this.C[0][0]=b[0],this.C[1][0]=b[1]&15,this.C[0][1]=b[2],this.C[1][1]=b[3]&15);Fl(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;bn(a,b,c,!0)}function cn(a,b,c){if(b=(a=dn[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.yc&1<g.nb[0]&&(g.nb[0]=255,g.nb[1]--,0>g.nb[1]&&(g.nb[1]=255)));return h}function sn(a,b,c,d,e,f){var g=a.F[b];t(a,768)&&v(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.zb+"]",null,!0);a=g.oc[c];a.nb[g.zb]=a.pc[g.zb]=e;g.zb^=1}function tn(a,b,c,d){var e=a.F[b],f=e.Mb|un;e.Mb&=~vn;t(a,768)&&v(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} +function wn(a,b,c,d,e){var f=a.F[b];t(a,768)&&v(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Mb=f.Mb&~(16<>2].oc[b&3],c,d,e)}function An(a,b,c){b=a.F[b>>2].oc[b&3];b.mg&&b.eh&&b.Ag?(c&&(b.done=c),b.ne||Kn(a,b,!0)):c&&c(!0)} +function Kn(a,b,c){c&&(b.count=b.nb[1]<<8|b.nb[0],b.type=b.mode&Ln,b.rj=b.ng=!1);for(var d=!1;0<=b.count&&(c=b.hg<<16|b.sb[1]<<8|b.sb[0],b.type==Mn?(d=!0,function(c){b.eh.call(b.mg,b.Ag,-1,function(e,g){0>e&&(b.rj||(b.rj=!0),e=255);b.ne||a.ka.fc(c,e);(d=g)&&setTimeout(function(){Nn(b)||Kn(a,b)},0)})}(c)):b.type==On?(c=a.ka.Ia(c),0>b.eh.call(b.mg,b.Ag,c)&&(b.ng=!0)):b.type!=Pn&&(b.ng=!0)),!d&&!Nn(b););} +function Nn(a){if(!a.ng&&0<=--a.count&&(a.mode&Qn?(a.sb[0]--,0>a.sb[0]&&(a.sb[0]=255,a.sb[1]--,0>a.sb[1]&&(a.sb[1]=255))):(a.sb[0]++,255>3];b=1<<(b&7);d.ac&b||(d.ac|=b,d.We=c||0,fo(a))}function fh(a,b){var c=a.hc[b>>3];b=1<<(b&7);c.ac&b&&(c.ac&=~b,fo(a))}function fo(a,b){var c,d=-1;1>=1),Gd(a.H,e))),b==so&&c==wo&&Vm(a))}function xo(a,b,c,d){v(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.va:a.ta} +function yo(a,b,c,d,e){v(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&zo;b?(e=3,a.va=d):a.ta=d;if(c==Ao){if(!(d&Bo))for(c=0;2>=c;c++)if(d&Co<=c;c++)d&Co<>=Ho;var f=d&Io,g=d&Jo;d&=Ko;if(d==Lo)Go(a,e+c);else{e+=c;var h=a.G[e];h.Qf=d;h.mode=g;h.Zg=f;h.pc=[0,0];h.nb=[0,0];h.je=[0,0];h.gd=!1;h.Me=!1;h.le=!1;h.Qe=!1;oo(a,e);b==so&&c==to&&fh(a,uo);b==so&&c==wo&&255==a.hc[0].od&& +a.J==(Mo|No|Oo|Po)&&(b=a.G[0],b.Mc[0]=b.pc[0],b.Mc[1]=b.pc[1],b.jd=Ed(a.H,a.O))}}}function vo(a,b){a=a.G[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.ad?256:65536);return b}function Pd(a,b){a=a.G[b];(b=a.Mc[1]<<8|a.Mc[0])||(b=1==a.ad?256:65536);return b}function Go(a,b){Bl(a,b);var c=a.G[b];c.je[0]=c.nb[0];c.je[1]=c.nb[1];c.Me=!0;oo(a,b)}function oo(a,b){a=a.G[b];a.rd=a.Qf==Qo?1:0;a.ad=a.Qf==Ro?2:1} +function Bl(a,b,c){var d=a.G[b];if(d.le&&(b!=wo||a.J&Mo)){var e=Ed(a.H,a.O),f=(e-d.jd)/a.Ba|0;0>f&&(d.jd=e,f=0);var g=vo(a,b),h=Pd(a,b)-f;d.mode==qo?(0>=h&&(h=0),h||(d.gd=!0,d.le=!1,b||hh(a,uo))):d.mode==So?(d.gd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&hh(a,uo))):d.mode==Qd&&(h-=f,0>=h&&(d.gd=!d.gd,h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&hh(a,uo)));d.nb[0]=h&255;d.nb[1]=h>>8&255;c&&(a.jd=0)}return d} +function Od(a,b){for(var c=0;c=eh){b=a.H.T.sd;c=Ed(a.H,a.O);null==a.Aa&&(a.ma=Ed(a.H,a.O),a.Ha=1024,a.Aa=Math.floor(a.H.T.sd/a.Ha),Tm(a));c>=a.Z&&(a.A[Pm]|=To,a.A[Rd]&Td&&(a.A[Pm]|=Uo,hh(a,Vo)),a.Z=c+a.Aa);a.A[lm]==a.A[mm]&&a.A[nm]==a.A[om]&&a.A[pm]==a.A[Hm]&&(a.A[Pm]|=Wo,a.A[Rd]&Xo&&(a.A[Pm]|=Uo,hh(a,Vo)));var d=c-a.ma,e=Math.floor(d/b);if(e&&!(a.A[Rd]&Yo)){for(;e--;)if(60<=++a.A[lm]&&(a.A[lm]=0,60<=++a.A[nm]&&(a.A[nm]=0,24<=++a.A[pm]))){a.A[pm]=0;a.A[Im]=a.A[Im]% +7+1;var f;f=a.A[Lm];var g=Ja[a.A[Km]-1];28==g&&(f%4||!(f%100)&&f%400||g++);f=g;++a.A[Jm]>f&&(a.A[Jm]=1,12<++a.A[Km]&&(a.A[Km]=1,a.A[Lm]=(a.A[Lm]+1)%100))}a.A[Pm]|=Zo;a.A[Rd]&$o&&(a.A[Pm]|=Uo,hh(a,Vo))}a.ma=c-d%b}}l.Gm=function(a,b){var c=this.ya;this.ga&ap&&(this.J&bp?c=this.C[0][1]:this.B&&(c=cp(this.B)));v(this,a,null,b,"PPI_A",c);return c};l.jo=function(a,b,c){v(this,a,b,c,"PPI_A");this.ya=b};l.Hm=function(a,b){var c=this.J;v(this,a,null,b,"PPI_B",c);return c}; +l.ko=function(a,b,c){v(this,a,b,c,"PPI_B");dp(this,b)};function dp(a,b){var c=!!(b&ep),d=!!(a.J&ep);a.J=b;a.B&&fp(a.B,!(b&bp),!!(b&Po));c!=d&&Vm(a,c)}l.Im=function(a,b){var c=0,c=(this.ca|0)==kl?this.J&No?c|this.C[1][1]&gp:c|this.C[1][1]>>4&1:this.J&hp?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.J&Mo&&Bl(this,wo).gd&&(c=this.J&ep?c|ip:c|jp);v(this,a,null,b,"PPI_C",c,32896);return c};l.lo=function(a,b,c){v(this,a,b,c,"PPI_C");this.Ca=b};l.Jm=function(a,b){var c=this.ga;v(this,a,null,b,"PPI_CTRL",c);return c}; +l.mo=function(a,b,c){v(this,a,b,c,"PPI_CTRL");this.ga=b};l.Sl=function(a,b){var c=this.B?cp(this.B):0;v(this,a,null,b,"8041_KBD",c);this.aa&=~kp;return c};l.tn=function(a,b,c){v(this,a,b,c,"8041_KBD")};l.Rl=function(a,b){var c=this.J;v(this,a,null,b,"8041_CTRL",c);return c};l.sn=function(a,b,c){v(this,a,b,c,"8041_CTRL");dp(this,b)};l.Tl=function(a,b){var c=this.aa;v(this,a,null,b,"8041_STATUS",c);return c}; +l.Ul=function(a,b){var c=this.oa;v(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(kp|lp);this.B&&mp(this.B);return c}; +l.vn=function(a,b,c){v(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&np)switch(this.L){case op:pp(this,b);break;case qp:rp(this,b);break;default:if(pp(this,this.K&~Ol),this.B){a=this.B;c=b;var d=-1;t(a)&&Mb(a,"sendCmd("+r(c)+")");switch(a.F||c){case sp:d=tp;up(a);break;case vp:a.F&&(c=0);wp(a,tp);a.F=c;break;case xp:a.F&&(c=0);wp(a,tp);a.F=c;break;default:Mb(a,"sendCmd(): unrecognized command")}yp(this,d)}}this.L=b;this.D&=~np}; +l.Vl=function(a,b){var c=this.J&~(zp|Ap)|(Ed(this.H)&64?Ap:0);v(this,a,null,b,"8042_RWREG",c,16384);return c};l.wn=function(a,b,c){v(this,a,b,c,"8042_RWREG",null,16384);dp(this,b)};l.Wl=function(a,b){v(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&lp&&(this.D|=kp,this.D&=~lp);return a}; +l.un=function(a,b,c){v(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.L=b;this.D|=np;a=0;this.L>=Bp&&(a=this.L^15,this.L=Bp);switch(this.L){case Cp:yp(this,this.K);break;case Dp:pp(this,this.K|Ol);break;case Ep:pp(this,this.K&~Ol);this.B&&mp(this.B);break;case Fp:this.B&&(a=this.B,a.A=[],t(a)&&Mb(a,"scan codes flushed"));pp(this,this.K|Ol);yp(this,Gp);rp(this,Yl|Zl);break;case Hp:yp(this,Ip);break;case Jp:yp(this,this.M);break;case Kp:yp(this,this.qa);break;case Lp:yp(this,this.K&Ol?0:Mp);break;case Bp:a& +1&&kf(this.H)}};function pp(a,b){a.K=b;a.D=a.D&~Np|b&Op;a.B&&fp(a.B,!!(b&Pp),!(b&Ol))}function yp(a,b,c){0<=b&&(a.oa=b,c?a.D|=kp:(a.D&=~kp,a.D|=lp))}function rp(a,b){a.qa=b;oc(a.ka,!!(b&Zl));b&Yl||kf(a.H)}function Qp(a,b){a.ca>4)+(c&15),e=!0);if(d==pm||d==Hm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Rd&&a&Td&&b&Td&&Tm(this)};l.Nk=function(a,b,c){v(this,a,b,c,"NMI");this.da=b};l.Vn=function(a,b,c){v(this,a,b,c,"FPU.CLEAR")};l.Wn=function(a,b,c){v(this,a,b,c,"FPU.RESET");this.Tc&&$g(this.Tc)}; +l.Xm=function(a){if(t(this,16)&&Wk(this.ba,26,a)){var b=this.H.D>>8;Tf(this.H,a,function(a,d){return function(c){d=Ed(a.H)-d;var e,g=a.H.L&255,h=a.H.L>>8,k=a.H.L&255,m=a.H.L>>8;if(2==b||3==b)e=" CH(hour)="+ta(h)+" CL(min)="+r(g)+" DH(sec)="+r(m);else if(4==b||5==b)e=" CX(year)="+ta(a.H.I)+" DH(month)="+r(m)+" DL(day)="+r(k);g=a.ba;h=d;g.message("INT "+r(26)+": C="+(dg(g.H)?1:0)+(e||"")+" (cycles="+h+(c?",level="+(c+1):"")+")")}}(this,Ed(this.H)))}return!0}; +function Vm(a,b){if(a.la)try{void 0!==b?a.Ga=b:b=!!(a.Ga&&a.H&&a.H.ea.vb);var c=Math.round(ol/vo(a,wo));if(20>c||2E4>>4,0,this.F,this.C,this.Fd),delete this.Fd);return!0};Yp.prototype.Wb=function(){return!0}; +function Zp(a,b,c,d){if(d)a.Fa("Unable to load system ROM (error "+d+": "+b+")");else{pb(a.xe,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.Fd=e.symbols;if(!a.A.length){hb("Empty ROM: "+b);return}if(1==a.A.length){hb(a.A[0]);return}}catch(h){a.Fa("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.A].bf(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.D?b.push(a.D):null!=a.D&&a.D.length&&(b=a.D);for(c=0;cthis.B?Sl:23,c=a.A[b]|a.A[b+1]<<8,c=c+(this.A>>10);a.A[b]=c&255;a.A[b+1]=c>>8;bm(a)}}else Wa("No RAM allocated")}; -l.save=function(){var a=new Of(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function Xp(a){this.D=a;this.C=Zp;this.H=$p;this.B=aq;this.A=null}l=Xp.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.fc(0,a[0]&255);this.fc(2,a[1]&255);return!0};l.Ia=function(a){var b=255;2>a?b=a&1?this.H>>8:this.H&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; -l.fc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.D.ka;if(b&bq)this.A&&(mc(a,cq,dq,this.A),this.A=null);else{this.A||(this.A=nc(a,cq,dq));var c=nc(a,eq,dq);mc(a,cq,dq,c,b&fq?1:vc)}this.C=this.C&-256|b}};l.vj=function(){return gq};l.fh=function(){return hq};var Yp=-2134900736,eq=16646144,cq=917504,dq=131072,bq=1,fq=2,Zp=65535,$p=2575,aq=2,gq=[null,0],hq=[function(a){return this.controller.Ia(a)},null,null,function(a,b){this.controller.fc(a,b)},null,null]; -Ra(function(){for(var a=pb(document,"pcx86","ram"),b=0;b=n.de&&d<=n.z&&(d-=n.de-n.ce),d=sq[e]==d),d){(a=a.na["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.W=Ob(a,"ChipSet")}; -function jq(a,b){var c=0;a.ca=null;"string"==typeof b&&(a.ca=b.toUpperCase(),c=wq.indexOf(a.ca),0>c&&(c=0));if(b=wq[c])a.Y=parseInt(b.substr(2),10)}function lp(a){Cb(a,"keyboard reset",65792);a.A=[];np(a,xq)}function Xo(a,b,c){a.J!==c&&(a.J=a.K=c)&&(a.G=!0);a.I!==b&&(a.I=b)&&!a.K&&Jp(a,!0);a.I&&a.K&&(lp(a),a.K=!1)}function np(a,b){a.W&&(a.A.unshift(b),a.G=!0,Hp(a.W,b))} -function dp(a){var b=0;a.A.length&&a.G&&(b=a.A[0],a.W&&Hp(a.W,b));t(a)&&Cb(a,b?"scan code "+r(b)+" available":"no scan codes available")}function Uo(a){var b=0;a.A.length&&(b=a.A[0]);t(a)&&Cb(a,"scan code "+r(b)+" delivered");return b}function Jp(a,b){0>=1);if(b&Bq){if(!1===d)return!0;d=null}null==d?d=!((c?a.C:a.jc)&b):d||b&Cq&&(b=Cq);if(c){a.C&=~b;d&&(a.C|=b);c=b;var f,g;for(g in Dq)d="led-"+g,e=Dq[g],c&&c!=e||!(f=a.na[d])||(f.style.backgroundColor=a.C&e?"#00ff00":"#000000")}else a.jc&=~b,d&&(a.jc|=b);return!0}}return!1} -function mq(a,b,c){if(O[b]&&a.H&&a.H.ea.vb){zq[b]&&a.B.length&&0e||(e==a.B.length&&(d={},d.ue=b,d.jc=a.jc,vq(a,b,!0),e++),0b.ud){if(!b.qf){tq(a,b.ue);return}b.qf=!1;c=a.Z}else c=1==b.ud++?500:100;b.cl=setTimeout(function(a){return function(){Eq(a,b)}}(a),c)}} -function Gq(a,b,c){var d=b;if(b>=n.ce&&b<=n.eg)!(a.jc&(Hq|Iq|Jq))==c&&(d=b+(n.de-n.ce));else if(b>=n.de&&b<=n.z)!!(a.jc&(Hq|Iq|Jq))==c&&(d=b-(n.de-n.ce));else if(!!(a.jc&(Hq|Iq))==c){if(a=fa[b])d=a}else if(a=ea[b])d=a;return d}l.Bg=function(a){a||(this.jc&=~Cq)}; -function kq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode,h=Gq(a,g,!0);a.dh&&h==n["`"]&&(g=h=27);if(O[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),rq(a,h,!1,c)){if(20==g||144==g||145==g)a.O||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.ce&&b<=n.eg||b>=n.de&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==Tq||f==Uq?d.push(f|(c?0:Sq)):(h==P?a.C&(Hq|Iq)||a.C&Jq&&b||(g=h):h==Vq?a.C&(Kq|Wq)||(g=h):h==Xq?a.C&(Lq|Yq)||(g=h):d.push(f|(c?0:Sq)),g&&(c?d.unshift(g):d.push(g|Sq)))}for(c=0;cthis.B?am:23,c=a.A[b]|a.A[b+1]<<8,c=c+(this.A>>10);a.A[b]=c&255;a.A[b+1]=c>>8;km(a)}}else hb("No RAM allocated")}; +l.save=function(){var a=new Xf(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function fq(a){this.D=a;this.C=hq;this.H=iq;this.B=jq;this.A=null}l=fq.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.fc(0,a[0]&255);this.fc(2,a[1]&255);return!0};l.Ia=function(a){var b=255;2>a?b=a&1?this.H>>8:this.H&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; +l.fc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.D.ka;if(b&kq)this.A&&(xc(a,lq,mq,this.A),this.A=null);else{this.A||(this.A=yc(a,lq,mq));var c=yc(a,nq,mq);xc(a,lq,mq,c,b&oq?1:Ec)}this.C=this.C&-256|b}};l.vj=function(){return pq};l.fh=function(){return qq};var gq=-2134900736,nq=16646144,lq=917504,mq=131072,kq=1,oq=2,hq=65535,iq=2575,jq=2,pq=[null,0],qq=[function(a){return this.controller.Ia(a)},null,null,function(a,b){this.controller.fc(a,b)},null,null]; +ab(function(){for(var a=Ab(document,"pcx86","ram"),b=0;b=n.de&&d<=n.z&&(d-=n.de-n.ce),d=Bq[e]==d),d){(a=a.na["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.W=Xb(a,"ChipSet")}; +function sq(a,b){var c=0;a.ca=null;"string"==typeof b&&(a.ca=b.toUpperCase(),c=Fq.indexOf(a.ca),0>c&&(c=0));if(b=Fq[c])a.Y=parseInt(b.substr(2),10)}function up(a){Mb(a,"keyboard reset",65792);a.A=[];wp(a,Gq)}function fp(a,b,c){a.J!==c&&(a.J=a.K=c)&&(a.G=!0);a.I!==b&&(a.I=b)&&!a.K&&Sp(a,!0);a.I&&a.K&&(up(a),a.K=!1)}function wp(a,b){a.W&&(a.A.unshift(b),a.G=!0,Qp(a.W,b))} +function mp(a){var b=0;a.A.length&&a.G&&(b=a.A[0],a.W&&Qp(a.W,b));t(a)&&Mb(a,b?"scan code "+r(b)+" available":"no scan codes available")}function cp(a){var b=0;a.A.length&&(b=a.A[0]);t(a)&&Mb(a,"scan code "+r(b)+" delivered");return b}function Sp(a,b){0>=1);if(b&Kq){if(!1===d)return!0;d=null}null==d?d=!((c?a.C:a.jc)&b):d||b&Lq&&(b=Lq);if(c){a.C&=~b;d&&(a.C|=b);c=b;var f,g;for(g in Mq)d="led-"+g,e=Mq[g],c&&c!=e||!(f=a.na[d])||(f.style.backgroundColor=a.C&e?"#00ff00":"#000000")}else a.jc&=~b,d&&(a.jc|=b);return!0}}return!1} +function vq(a,b,c){if(O[b]&&a.H&&a.H.ea.vb){Iq[b]&&a.B.length&&0e||(e==a.B.length&&(d={},d.ue=b,d.jc=a.jc,Eq(a,b,!0),e++),0b.ud){if(!b.qf){Cq(a,b.ue);return}b.qf=!1;c=a.Z}else c=1==b.ud++?500:100;b.cl=setTimeout(function(a){return function(){Nq(a,b)}}(a),c)}} +function Pq(a,b,c){var d=b;if(b>=n.ce&&b<=n.eg)!(a.jc&(Qq|Rq|Sq))==c&&(d=b+(n.de-n.ce));else if(b>=n.de&&b<=n.z)!!(a.jc&(Qq|Rq|Sq))==c&&(d=b-(n.de-n.ce));else if(!!(a.jc&(Qq|Rq))==c){if(a=na[b])d=a}else if(a=ma[b])d=a;return d}l.Bg=function(a){a||(this.jc&=~Lq)}; +function tq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode,h=Pq(a,g,!0);a.dh&&h==n["`"]&&(g=h=27);if(O[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),Aq(a,h,!1,c)){if(20==g||144==g||145==g)a.O||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.ce&&b<=n.eg||b>=n.de&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==br||f==cr?d.push(f|(c?0:ar)):(h==P?a.C&(Qq|Rq)||a.C&Sq&&b||(g=h):h==dr?a.C&(Tq|er)||(g=h):h==fr?a.C&(Uq|gr)||(g=h):d.push(f|(c?0:ar)),g&&(c?d.unshift(g):d.push(g|ar)))}for(c=0;c"]]=52|P<<8;O[n["/"]]=53; -O[n["?"]]=53|P<<8;O[3016]=54;O[1044]=55;O[1018]=Xq;O[1032]=57;O[nq]=58;O[1112]=59;O[1113]=60;O[1114]=61;O[1115]=62;O[1116]=63;O[1117]=64;O[1118]=65;O[1119]=66;O[1120]=67;O[1121]=68;O[oq]=69;O[pq]=70;O[1036]=71;O[1038]=72;O[1033]=73;O[1109]=74;O[1037]=75;O[1101]=76;O[1039]=77;O[1107]=78;O[1035]=79;O[1040]=80;O[1034]=81;O[1045]=82;O[1046]=Rq;O[4027]=84;O[1122]=87;O[1123]=88;O[1091]=91;O[1093]=93;O[1224]=91;O[ar]=46|Vq<<8;O[Mq]=70|Vq<<8;O[4046]=Rq|Vq<<8|Xq<<16;O[4045]=82|Vq<<8|Xq<<16; -O[4013]=28|Vq<<8|Xq<<16;var jp=255,mp=243,op=237,xq=170,kp=250,$q=255,Zq=20;Ra(function(){for(var a=pb(document,"pcx86","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Xc=c[1];this.Ze=c[2];this.fa=c[3];this.ec=c[4]&255;this.Fg=c[4]>>8&255;this.Wa=c[5];this.oh=dr;this.gg=fr;if(b>=Tp){this.oh=er;this.gg=gr;(b=c[6])||(b=[!1,0,Array(hr),0,f== -Ll?0:ir,0,0,Array(jr),0,0,0,Array(kr),0,[this.bb,this.Ob,this.qd],Array(this.qd>>2),lr|mr|nr|or|pr,0,-1,0,-1,0,-1,0,0,0,0,qr,rr,0,0,sr,Array(tr)]);this.Ke=b[0];this.wd=b[1];this.Cc=b[2];this.Tg=ur;this.Ig=b[3];this.af=b[4];this.Pf=b[5];this.zd=b[6];this.$d=b[7];this.Vg=vr;this.Wk=b[8];this.Xk=b[9];this.yd=b[10];this.xd=b[11];this.Ug=wr;this.tb=b[12];d=b[13];"number"==typeof d&&(d=[this.bb,this.Ob,d]);this.bb=d[0];this.Ob=d[1];d=this.qd>>2;if((this.fd=b[14])&&this.fd.lengthc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Xc=c[1];this.Ze=c[2];this.fa=c[3];this.ec=c[4]&255;this.Fg=c[4]>>8&255;this.Wa=c[5];this.oh=mr;this.gg=or;if(b>=bq){this.oh=nr;this.gg=pr;(b=c[6])||(b=[!1,0,Array(qr),0,f== +Ul?0:rr,0,0,Array(sr),0,0,0,Array(tr),0,[this.bb,this.Ob,this.qd],Array(this.qd>>2),ur|vr|wr|xr|yr,0,-1,0,-1,0,-1,0,0,0,0,zr,Ar,0,0,Br,Array(Cr)]);this.Ke=b[0];this.wd=b[1];this.Cc=b[2];this.Tg=Dr;this.Ig=b[3];this.af=b[4];this.Pf=b[5];this.zd=b[6];this.$d=b[7];this.Vg=Er;this.Wk=b[8];this.Xk=b[9];this.yd=b[10];this.xd=b[11];this.Ug=Fr;this.tb=b[12];d=b[13];"number"==typeof d&&(d=[this.bb,this.Ob,d]);this.bb=d[0];this.Ob=d[1];d=this.qd>>2;if((this.fd=b[14])&&this.fd.length=Tp){var c=[];c[0]=a.Ke;c[1]=a.wd;c[2]=a.Cc;c[3]=a.Ig;c[4]=a.af;c[5]=a.Pf;c[6]=a.zd;c[7]=a.$d;c[8]=a.Wk;c[9]=a.Xk;c[10]=a.yd;c[11]=a.xd;c[12]=a.tb;c[13]=[a.bb,a.Ob,a.qd];var d;if(d=a.fd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=Tp){var d=0,e=0,f=0;switch(b){case Fr:d=Gr;a.La==Vp&&(e=Hr);break;case Ir:a.La==Tp&&(d=Jr);break;case Kr:d=Lr;a.La==Vp&&(e=Mr);break;case Nr:d=Or;a.La==Vp&&(e=Pr);break;case Qr:d=Rr;a.La==Vp&&(f=Sr);break;case Tr:d=Ur,a.La==Vp&&(f=Vr)}d&&(c|=a.Wa[Wr]&d?256:0,c|=a.Wa[Wr]&e?512:0,c|=a.Wa[Xr]&f?512:0)}return c} -var dr=18,Fr=6,Wr=7,Gr=1,Or=2,Lr=4,Rr=8,Ur=16,Jr=32,Hr=32,Pr=64,Mr=128,Xr=9,Sr=32,Vr=64,Ir=10,Kr=16,Nr=18,Qr=21,Tr=24,er=25,fr="HTOTAL HDISP HSYNC_POS HSYNC_WIDTH VTOTAL VTOTAL_ADJ VDISP VSYNC_POS INTERLACE_POS MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO LIGHT_PEN_HI LIGHT_PEN_LO".split(" "),gr="HTOTAL HDISP_END HBLANK_START HBLANK_END HRETRACE_START HRETRACE_END VTOTAL OVERFLOW PRESET_SCAN MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO VRETRACE_START VRETRACE_END VDISP_END OFFSET UNDERLINE VBLANK_START VBLANK_END MODE_CTRL LINE_COMPARE".split(" "), -hr=20,ur="PAL00 PAL01 PAL02 PAL03 PAL04 PAL05 PAL06 PAL07 PAL08 PAL09 PAL0A PAL0B PAL0C PAL0D PAL0E PAL0F MODE OVERSCAN PLANES HPAN".split(" "),ir=1,qr=1,jr=5,vr=["RESET","CLOCKING","MAPMASK","CHARMAP","MEMMODE"],rr=255,sr=0,tr=256,kr=9,wr="SRESET ESRESET COLORCMP DATAROT READMAP MODE MISC COLORDC BITMASK".split(" "),lr=1024,mr=4096,Cr=65280,nr=0,or=16,Er=255,pr=-2147483648,xr=[];xr[2]=lr;xr[3]=lr|mr;xr[16]=1280;xr[512]=nr;xr[1024]=nr|32;xr[1536]=nr|96;xr[2560]=nr|160;xr[3584]=nr|224;xr[768]=nr|or; -xr[4096]=1;xr[8192]=2;xr[24576]=98;xr[40960]=162;xr[57344]=226;var Dr=[];Dr[lr]=function(a){a+=this.H;return(this.controller.tb=this.X[a])>>this.controller.ei&255};Dr[lr|16384]=function(a){return(this.controller.tb=this.X[(a&-4)+this.H])>>((a&3)<<3)&255};Dr[lr|mr]=function(a){a+=this.H;var b=this.controller.tb=this.X[a&-2];return(a&1?b>>8:b)&255}; -Dr[1280]=function(a){a+=this.H;a=this.controller.tb=this.X[a];for(var b=this.controller.qh,c=this.controller.ph&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Dr[nr]=function(a,b){a+=this.H;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; -Dr[nr|32]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; -Dr[nr|96]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b&=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; -Dr[nr|160]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b|=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; -Dr[nr|224]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b^=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)};Dr[nr|4]=function(a,b){var c=(a&-4)+this.H;a=(a&3)<<3;b=b<>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Bb;b=this.controller.Hf&b|this.controller.tb&~b;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; -function Q(a,b,c,d,e){ab.call(this,"Video",a,262144);var f=this;this.Tc=Ja("Gecko/");var g=["","moz","ms","webkit"];this.ca=a.model;var h=Zr[this.ca]||Zr.mda;this.La=h[0];this.qd=a.memory||0;this.cd=a.switches;this.da=a.mode;if(null==this.da||null==$r[this.da])this.da=h[1];this.Fb=a.charCols;this.sc=a.charRows;if(void 0===this.Fb||void 0===this.sc)this.Fb=$r[this.da][0],this.sc=$r[this.da][1];this.Z=a.screenWidth;this.la=a.screenHeight;this.Uc=a.scale;this.Cd=12<=Math.round(this.Z/this.Fb);this.O= -b;this.L=c;this.D=(this.Qd=d)||b||null;b=a.smoothing;(c=Ka("smoothing"))&&(b="true"==c);if(null!=b)for(c=0;c=bq){var c=[];c[0]=a.Ke;c[1]=a.wd;c[2]=a.Cc;c[3]=a.Ig;c[4]=a.af;c[5]=a.Pf;c[6]=a.zd;c[7]=a.$d;c[8]=a.Wk;c[9]=a.Xk;c[10]=a.yd;c[11]=a.xd;c[12]=a.tb;c[13]=[a.bb,a.Ob,a.qd];var d;if(d=a.fd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=bq){var d=0,e=0,f=0;switch(b){case Or:d=Pr;a.La==dq&&(e=Qr);break;case Rr:a.La==bq&&(d=Sr);break;case Tr:d=Ur;a.La==dq&&(e=Vr);break;case Wr:d=Xr;a.La==dq&&(e=Yr);break;case Zr:d=$r;a.La==dq&&(f=as);break;case bs:d=cs,a.La==dq&&(f=ds)}d&&(c|=a.Wa[es]&d?256:0,c|=a.Wa[es]&e?512:0,c|=a.Wa[fs]&f?512:0)}return c} +var mr=18,Or=6,es=7,Pr=1,Xr=2,Ur=4,$r=8,cs=16,Sr=32,Qr=32,Yr=64,Vr=128,fs=9,as=32,ds=64,Rr=10,Tr=16,Wr=18,Zr=21,bs=24,nr=25,or="HTOTAL HDISP HSYNC_POS HSYNC_WIDTH VTOTAL VTOTAL_ADJ VDISP VSYNC_POS INTERLACE_POS MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO LIGHT_PEN_HI LIGHT_PEN_LO".split(" "),pr="HTOTAL HDISP_END HBLANK_START HBLANK_END HRETRACE_START HRETRACE_END VTOTAL OVERFLOW PRESET_SCAN MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO VRETRACE_START VRETRACE_END VDISP_END OFFSET UNDERLINE VBLANK_START VBLANK_END MODE_CTRL LINE_COMPARE".split(" "), +qr=20,Dr="PAL00 PAL01 PAL02 PAL03 PAL04 PAL05 PAL06 PAL07 PAL08 PAL09 PAL0A PAL0B PAL0C PAL0D PAL0E PAL0F MODE OVERSCAN PLANES HPAN".split(" "),rr=1,zr=1,sr=5,Er=["RESET","CLOCKING","MAPMASK","CHARMAP","MEMMODE"],Ar=255,Br=0,Cr=256,tr=9,Fr="SRESET ESRESET COLORCMP DATAROT READMAP MODE MISC COLORDC BITMASK".split(" "),ur=1024,vr=4096,Lr=65280,wr=0,xr=16,Nr=255,yr=-2147483648,Gr=[];Gr[2]=ur;Gr[3]=ur|vr;Gr[16]=1280;Gr[512]=wr;Gr[1024]=wr|32;Gr[1536]=wr|96;Gr[2560]=wr|160;Gr[3584]=wr|224;Gr[768]=wr|xr; +Gr[4096]=1;Gr[8192]=2;Gr[24576]=98;Gr[40960]=162;Gr[57344]=226;var Mr=[];Mr[ur]=function(a){a+=this.H;return(this.controller.tb=this.X[a])>>this.controller.ei&255};Mr[ur|16384]=function(a){return(this.controller.tb=this.X[(a&-4)+this.H])>>((a&3)<<3)&255};Mr[ur|vr]=function(a){a+=this.H;var b=this.controller.tb=this.X[a&-2];return(a&1?b>>8:b)&255}; +Mr[1280]=function(a){a+=this.H;a=this.controller.tb=this.X[a];for(var b=this.controller.qh,c=this.controller.ph&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Mr[wr]=function(a,b){a+=this.H;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|32]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|96]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b&=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|160]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b|=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|224]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b^=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)};Mr[wr|4]=function(a,b){var c=(a&-4)+this.H;a=(a&3)<<3;b=b<>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Bb;b=this.controller.Hf&b|this.controller.tb&~b;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +function Q(a,b,c,d,e){nb.call(this,"Video",a,262144);var f=this;this.Tc=Ua("Gecko/");var g=["","moz","ms","webkit"];this.ca=a.model;var h=hs[this.ca]||hs.mda;this.La=h[0];this.qd=a.memory||0;this.cd=a.switches;this.da=a.mode;if(null==this.da||null==is[this.da])this.da=h[1];this.Fb=a.charCols;this.sc=a.charRows;if(void 0===this.Fb||void 0===this.sc)this.Fb=is[this.da][0],this.sc=is[this.da][1];this.Z=a.screenWidth;this.la=a.screenHeight;this.Uc=a.scale;this.Cd=12<=Math.round(this.Z/this.Fb);this.O= +b;this.L=c;this.D=(this.Qd=d)||b||null;b=a.smoothing;(c=Va("smoothing"))&&(b="true"==c);if(null!=b)for(c=0;c=Tp&&(Ec(b,this,js),Ic(b,this,ks));this.La==Vp&&(Ec(b,this,ls),Ic(b,this,ms));if(d){var e=this;rl(d,262144,function(a){if(e.C)if(a[0]){var b=e.C;if(b.fd){var c,d,f,g=!1,u=8,F=8,K=-1,H=b.video.F>>3;for(c=0;c=d&&(F=d,g=!0);break; -case "p":0<=d&&3>=d&&(K=d);break;case "w":d=b.bb&&(f-=b.bb);a="";for(c=0;cK?q(T):ha(T>>(K<<3),8));g&&(f+=H-F);a&&(a+="\n");a+=I}a&&b.ba.P(a);b.B=f}else b.ba.P("no buffer")}else e.ba.P("BIOSMODE: "+r(e.oa)),b=e.C,Ar(b,"CRTC",b.ec,b.Wa,b.gg),b.La>=Tp&&(Ar(b," GRC",b.yd,b.xd,b.Ug),Ar(b," SEQ",b.zd,b.$d,b.Vg),Ar(b," ATC",b.wd,b.Cc, -b.Tg),Ar(b," ATCINDX",b.wd),b.ba.P(" ATCDATA: "+b.Ke),Ar(b," FEAT",b.Pf),Ar(b," MISC",b.af),Ar(b," STATUS0",b.Ig)),Ar(b," STATUS1",b.fa),b.La!=gs&&b.La!=ds||Ar(b," MODEREG",b.Xc),b.La==ds&&Ar(b," COLOR",b.Ze),b.La>=Tp&&(b.ba.P(" LATCHES: "+q(b.tb)),b.ba.P(" ACCESS: "+q(b.tg,4)),b.ba.P("Use 'dump video [addr]' to dump video memory"));else e.ba.P("no active video card")})}if((this.B=Ob(a,"Keyboard"))&&this.O){for(var f in this.na)0=bq&&(Oc(b,this,ss),Sc(b,this,ts));this.La==dq&&(Oc(b,this,us),Sc(b,this,vs));if(d){var e=this;Al(d,262144,function(a){if(e.C)if(a[0]){var b=e.C;if(b.fd){var c,d,f,g=!1,u=8,F=8,K=-1,H=b.video.F>>3;for(c=0;c=d&&(F=d,g=!0);break; +case "p":0<=d&&3>=d&&(K=d);break;case "w":d=b.bb&&(f-=b.bb);a="";for(c=0;cK?q(T):qa(T>>(K<<3),8));g&&(f+=H-F);a&&(a+="\n");a+=I}a&&b.ba.P(a);b.B=f}else b.ba.P("no buffer")}else e.ba.P("BIOSMODE: "+r(e.oa)),b=e.C,Jr(b,"CRTC",b.ec,b.Wa,b.gg),b.La>=bq&&(Jr(b," GRC",b.yd,b.xd,b.Ug),Jr(b," SEQ",b.zd,b.$d,b.Vg),Jr(b," ATC",b.wd,b.Cc, +b.Tg),Jr(b," ATCINDX",b.wd),b.ba.P(" ATCDATA: "+b.Ke),Jr(b," FEAT",b.Pf),Jr(b," MISC",b.af),Jr(b," STATUS0",b.Ig)),Jr(b," STATUS1",b.fa),b.La!=ps&&b.La!=ms||Jr(b," MODEREG",b.Xc),b.La==ms&&Jr(b," COLOR",b.Ze),b.La>=bq&&(b.ba.P(" LATCHES: "+q(b.tb)),b.ba.P(" ACCESS: "+q(b.tg,4)),b.ba.P("Use 'dump video [addr]' to dump video memory"));else e.ba.P("no active video card")})}if((this.B=Xb(a,"Keyboard"))&&this.O){for(var f in this.na)0c&&(a=Math.round(c/b*100)+"%")}this.Tc?(this.O.style.width=a,this.O.style.width=a,this.O.style.display="block",this.O.style.margin="auto"):(this.N.style.width=a,this.N.style.height="auto");this.N.style.backgroundColor="black";this.N.Je();a=!0}this.D&&this.D.focus()}return a}; -function bs(a,b){!b&&a.N&&(a.Tc?a.O.style.width=a.O.style.height="":a.N.style.width=a.N.style.height="");Cb(a,"notifyFullScreen("+b+")",!0);a.B&&(a.B.dh=b)}l.me=function(a){var b=!1;this.D&&(a?this.D.me&&(this.D.me(),this.G&&this.G.If(!0),b=!0):this.D.dl&&(this.D.dl(),this.G&&this.G.If(!1),b=!0),this.D&&this.D.focus());return b};l.If=function(a){this.G&&(this.G.If(a),this.B&&(this.B.dh=a));var b=this.na.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Dd)}; -function ns(a,b){var c=a.D;c&&!a.tc&&(c.addEventListener("touchstart",function(b){rs(a,b,!0)},!1),c.addEventListener("touchmove",function(b){rs(a,b)},!0),c.addEventListener("touchend",function(b){rs(a,b,!1)},!1),a.tc=b,a.qb=a.rb=a.kd=-1,a.lc=!1,a.Db=null,a.kc=!1,a.Pd=function(){a.kc=!0;a.G.Vd(ss,!0)})}l.Bg=function(a){this.B&&this.B.Bg(a)}; -function rs(a,b,c){var d,e,f=0,g=0;e=a.O;do isNaN(e.offsetLeft)||(f+=e.offsetLeft,g+=e.offsetTop);while(e=e.offsetParent);var h=a.Z/a.O.offsetWidth,k=a.la/a.O.offsetHeight;b.targetTouches&&b.targetTouches.length?(d=b.targetTouches[0].pageX,e=b.targetTouches[0].pageY):(d=b.pageX,e=b.pageY);d=(d-f)*h;e=(e-g)*k;if(a.tc==ps)d=d/(a.Z/3)|0,e=e/(a.la/3)|0,1!=e?e?mq(a.B,1040,!0):mq(a.B,1038,!0):1!=d&&(d?mq(a.B,1039,!0):mq(a.B,1037,!0));else if(a.G){g=a.lc;f=b.timeStamp-a.kd;!0===c?(a.lc=500f){a.G.Vd(ss,!0);a.G.Vd(ss,!1);return}}if(c||0>a.qb||0>a.rb)a.qb=d,a.rb=e;c=Math.round(d-a.qb);b=Math.round(e-a.rb);a.qb=d;a.rb=e;a.G.tf(c,b,a.qb,a.rb)}}l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0}; -l.reset=function(){var a=!0,b=0;this.W&&(b=+Kl(this.W,Zk,void 0));this.ca||(this.La=b==Ll?gs:ds);this.da=ts;switch(this.La){case Vp:b=7;break;case Tp:var c=us[this.xb];c&&(b=c[0]);b||(b=4);break;case gs:b=Ll;this.da=vs;break;default:b=2}this.ga!==b&&(this.ga=b,a=!0);this.C=null;this.Y=this.Kb=new br(this,gs);this.K=this.yb=new br(this,ds);this.La>1&255,d=d>>8&~zs,d>>4==(d&15)&&(d^=15)):(c=d&255,d=(d&256?As|Bs:Cs|Ds)|Es&d>>8);Bc(this.ka,b,c|d<<8)}qs(this,!0)}};function ws(a){a.A.af&ir?(a.Y=a.Kb,a.K=a.A):(a.Y=a.A,a.K=a.yb)}l.save=function(){var a=new Of(this);a.set(0,zr(this.Kb));a.set(1,zr(this.yb));a.set(2,[this.ga,this.da,this.oa]);a.set(3,zr(this.A));return a.data()}; -l.restore=function(a){var b=a[2];this.ga=b[0];this.da=b[1];this.oa=b[2];this.C=null;this.Y=this.Kb=new br(this,gs,a[0]);this.K=this.yb=new br(this,ds,a[1]);this.A=new br(this,this.La,a[3],this.qd);this.A.rc&&ws(this);xs(this);if(!Fs(this))return!1;Gs(this);return!0}; -function cs(a,b,c,d){if(d)a.Fa("Unable to load font ROM (error "+d+": "+b+")");else{eb(a.xe,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){Wa("Empty font ROM: "+b);return}if(1==f.length){Wa(f[0]);return}if(8192==f.length)Up(a,f,[6144,0]);else if(2048==f.length)Up(a,f,[0]);else{a.Fa("Unrecognized font data length ("+f.length+")");return}}catch(g){a.Fa("Font ROM data error: "+g.message);return}(a.L||a.ba)&&zb(a)}} -function Hs(a,b){if(1==b)return a.ha[0]=Is[Cs],a.ha[1]=Is[As],a.ha;if(2==b){var c=a.C.Ze;if(a.C===a.A){var d=a.A.Cc[0],c=d&7;d&16&&(c|=8);18!=a.A.Cc[1]&&(c|=32)}a.ha[0]=Is[c&15];c=c&32?Js:Ks;for(d=0;de;e++)f=d[e]||0,g=f<<2&252,h=f>>4&252,f=f>>10&252,a.ha[e]=[g,h,f,255];else{var k=d&&d[255];b=null!=c.Cc[15]?c.Cc:Ls;for(e=0;16>e;e++)f=b[e]&63,k?(f|= -(c.Cc[20]&12)<<4,c.Cc[16]&128&&(f&=-49,f|=(c.Cc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.ha[e]=[g,h,f,255]}a.Ga=!0}return a.ha}function Up(a,b,c,d){a.wb=b;a.Ta=c;a.Da=d} -function xs(a,b){var c=!1;if(window&&a.wb&&(!b||a.I)){b=0;var d=a.Da?a.Da:8,e=Hs(a);null!=a.Ta[0]&&Ms(a,Ns,a.Ta[0],b,d,8,a.wb,e)&&(c=!0);b=a.Da?0:2048;d=a.Da?a.Da:9;null!=a.Ta[1]&&(Ms(a,Os,a.Ta[1],b,d,14,a.wb,Ps,Qs)&&(c=!0),a.Da&&Ms(a,a.La,a.Ta[1],0,a.Da,14,a.wb,e)&&(c=!0))}return c}function Ms(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&(Rs(a,b,c,d,e,f,g,h,k)&&(m=!0),a.Cd&&Rs(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} -function Rs(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,w=a.va[b],u=16>h.length?h.length:16;w||(w={Fc:e<ua||!T?ua:8,ib=cb.createImageData(m.Fc,m.Gc);for(Sa=0;256>Sa;Sa++){for(db=0;db=ua-2,Ld=ca[db>(8<=rb&&192<=Sa&&223>=Sa?7:rb)?F:xb;Ss(ib,rg,df,sg);H&&Ss(ib,rg+1,df,sg)}cb.putImageData(ib,(Sa&15)*m.Fc,(Sa>>4)*m.Gc)}m.Be[K]="#"+q(F[0],2)+q(F[1],2)+q(F[2],2);m.Qi[K]=F;m.Sg[K]=za;m=!0}}a.va[b]=w;return m}function Ts(a){0a.Aa&&(a.Aa=0):a.Aa=-1} -function Gs(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.C.Wa[b])return;var c=a.C.Wa[10],b=c&31,d=a.C.Wa[11]&31,e=a.C.Wa[9]&31,f=!1;a.C===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)Us(a);else{c=a.C.Wa[15]+((a.C.Wa[14]&63)<<8);a.aa!=c&&(Us(a),a.aa=c);d=d-b+1;if(a.md!=b||a.Hc!=d)a.md=b,a.Hc=d;a.za=e+1;Ts(a)}}} -function Us(a){if(0<=a.aa){if(void 0!==a.M){var b=Vs<<8,c=a.M[a.aa];if(c&b){var c=c&~b,b=a.aa%a.F,d=a.aa/a.F|0;a.I&&a.va[a.I]&&(a.Ca&&Ws(a,b,d,c,a.Ca),Ws(a,b,d,c));a.M[a.aa]=c}}a.aa=-1}} -function Xs(a){var b,c=a.C;a.Pc=!1;var d=c.xd[5];if(null!=d){b=lr;var e=nr,f=c.xd[3]&31;switch(d&3){case 0:if(f){e=nr|32;switch(f&24){case 8:e=nr|96;break;case 16:e=nr|160;break;case 24:e=nr|224}c.Qc=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.La==Vp&&(e=3,c.Qc=f&7)}d&8&&(b=1280);c=c.$d[4];null!=c&&(c&4||(b|=mr,e|=or),d&64&&(c&8&&(b|=16384,e|=4),a.Pc=!0));b|=e}return b} -function Ys(a,b){var c=a.C;return c&&null!=b&&b!=c.tg?(c.Kg(b),a.ka.Kg(c.bb,c.Ob,c.fh(),!0),!0):!1} -function Fs(a,b){var c,d=a.oa,e=a.C;if(e)if(e.La==gs)d=vs;else if(e.La>=Tp){var d=null,f=e.qd>>2,g=32768=e.Wa[Nr]?ct:dt:et:g&128|| -350>f?d=m?ft:gt:480<=f&&(d=a.ga==Ll?ht:it):d=m?7-d:jt:d-=m?2:0);c=Xs(a)}}else e.Xc&8&&(e.Xc&2?(d=e.Xc&16?jt:kt,e.Xc&4||--d):(d=e.Xc&1?ts:Jt,e.Xc&4&&--d));else a.oa=null,null==d&&(d=a.da);if(!ys(a,d,b))return!1;Ys(a,c);return!0} -function ys(a,b,c){if(null!=b&&(b!=a.oa||c)){a.Ad=0;a.oa=b;a.Ga=!1;b=a.C||(b==vs?a.Y:a.K);if(b!=a.C||b.bb!=a.bb||b.Ob!=a.Ob){Us(a);if(a.bb){if(!sc(a.ka,a.bb,a.Ob))return!1;a.C&&(a.C.rc=!1)}a.C=b;b.rc=!0;a.bb=b.bb;a.Ob=b.Ob;if(!gc(a.ka,b.bb,b.Ob,3,b===a.A?b:null))return!1}a:{a.I=0;a.F=a.Fb;a.J=a.sc;a.Ma=a.F;a.Eb=$r[vs][2];b=0;if(c=$r[a.oa])a.F=c[0],a.J=c[1],a.Eb=c[2],b=c[3],a.I=c[4],4!=a.ga&&7!=a.ga||a.C!==a.A||a.I!=Ns||(7==(a.A.Wa[Xr]&31)?a.J=350>Br(a.A,Nr)?43:50:a.I=a.La);a.Wc=a.F*a.J|0;a.Vc=a.Wc/ +function ks(a,b){!b&&a.N&&(a.Tc?a.O.style.width=a.O.style.height="":a.N.style.width=a.N.style.height="");Mb(a,"notifyFullScreen("+b+")",!0);a.B&&(a.B.dh=b)}l.me=function(a){var b=!1;this.D&&(a?this.D.me&&(this.D.me(),this.G&&this.G.If(!0),b=!0):this.D.dl&&(this.D.dl(),this.G&&this.G.If(!1),b=!0),this.D&&this.D.focus());return b};l.If=function(a){this.G&&(this.G.If(a),this.B&&(this.B.dh=a));var b=this.na.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Dd)}; +function ws(a,b){var c=a.D;c&&!a.tc&&(c.addEventListener("touchstart",function(b){As(a,b,!0)},!1),c.addEventListener("touchmove",function(b){As(a,b)},!0),c.addEventListener("touchend",function(b){As(a,b,!1)},!1),a.tc=b,a.qb=a.rb=a.kd=-1,a.lc=!1,a.Db=null,a.kc=!1,a.Pd=function(){a.kc=!0;a.G.Vd(Bs,!0)})}l.Bg=function(a){this.B&&this.B.Bg(a)}; +function As(a,b,c){var d,e,f=0,g=0;e=a.O;do isNaN(e.offsetLeft)||(f+=e.offsetLeft,g+=e.offsetTop);while(e=e.offsetParent);var h=a.Z/a.O.offsetWidth,k=a.la/a.O.offsetHeight;b.targetTouches&&b.targetTouches.length?(d=b.targetTouches[0].pageX,e=b.targetTouches[0].pageY):(d=b.pageX,e=b.pageY);d=(d-f)*h;e=(e-g)*k;if(a.tc==ys)d=d/(a.Z/3)|0,e=e/(a.la/3)|0,1!=e?e?vq(a.B,1040,!0):vq(a.B,1038,!0):1!=d&&(d?vq(a.B,1039,!0):vq(a.B,1037,!0));else if(a.G){g=a.lc;f=b.timeStamp-a.kd;!0===c?(a.lc=500f){a.G.Vd(Bs,!0);a.G.Vd(Bs,!1);return}}if(c||0>a.qb||0>a.rb)a.qb=d,a.rb=e;c=Math.round(d-a.qb);b=Math.round(e-a.rb);a.qb=d;a.rb=e;a.G.tf(c,b,a.qb,a.rb)}}l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0}; +l.reset=function(){var a=!0,b=0;this.W&&(b=+Tl(this.W,hl,void 0));this.ca||(this.La=b==Ul?ps:ms);this.da=Cs;switch(this.La){case dq:b=7;break;case bq:var c=Ds[this.xb];c&&(b=c[0]);b||(b=4);break;case ps:b=Ul;this.da=Es;break;default:b=2}this.ga!==b&&(this.ga=b,a=!0);this.C=null;this.Y=this.Kb=new kr(this,ps);this.K=this.yb=new kr(this,ms);this.La>1&255,d=d>>8&~Is,d>>4==(d&15)&&(d^=15)):(c=d&255,d=(d&256?Js|Ks:Ls|Ms)|Ns&d>>8);Kc(this.ka,b,c|d<<8)}zs(this,!0)}};function Fs(a){a.A.af&rr?(a.Y=a.Kb,a.K=a.A):(a.Y=a.A,a.K=a.yb)}l.save=function(){var a=new Xf(this);a.set(0,Ir(this.Kb));a.set(1,Ir(this.yb));a.set(2,[this.ga,this.da,this.oa]);a.set(3,Ir(this.A));return a.data()}; +l.restore=function(a){var b=a[2];this.ga=b[0];this.da=b[1];this.oa=b[2];this.C=null;this.Y=this.Kb=new kr(this,ps,a[0]);this.K=this.yb=new kr(this,ms,a[1]);this.A=new kr(this,this.La,a[3],this.qd);this.A.rc&&Fs(this);Gs(this);if(!Os(this))return!1;Ps(this);return!0}; +function ls(a,b,c,d){if(d)a.Fa("Unable to load font ROM (error "+d+": "+b+")");else{pb(a.xe,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){hb("Empty font ROM: "+b);return}if(1==f.length){hb(f[0]);return}if(8192==f.length)cq(a,f,[6144,0]);else if(2048==f.length)cq(a,f,[0]);else{a.Fa("Unrecognized font data length ("+f.length+")");return}}catch(g){a.Fa("Font ROM data error: "+g.message);return}(a.L||a.ba)&&Jb(a)}} +function Qs(a,b){if(1==b)return a.ha[0]=Rs[Ls],a.ha[1]=Rs[Js],a.ha;if(2==b){var c=a.C.Ze;if(a.C===a.A){var d=a.A.Cc[0],c=d&7;d&16&&(c|=8);18!=a.A.Cc[1]&&(c|=32)}a.ha[0]=Rs[c&15];c=c&32?Ss:Ts;for(d=0;de;e++)f=d[e]||0,g=f<<2&252,h=f>>4&252,f=f>>10&252,a.ha[e]=[g,h,f,255];else{var k=d&&d[255];b=null!=c.Cc[15]?c.Cc:Us;for(e=0;16>e;e++)f=b[e]&63,k?(f|= +(c.Cc[20]&12)<<4,c.Cc[16]&128&&(f&=-49,f|=(c.Cc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.ha[e]=[g,h,f,255]}a.Ga=!0}return a.ha}function cq(a,b,c,d){a.wb=b;a.Ta=c;a.Da=d} +function Gs(a,b){var c=!1;if(window&&a.wb&&(!b||a.I)){b=0;var d=a.Da?a.Da:8,e=Qs(a);null!=a.Ta[0]&&Vs(a,Ws,a.Ta[0],b,d,8,a.wb,e)&&(c=!0);b=a.Da?0:2048;d=a.Da?a.Da:9;null!=a.Ta[1]&&(Vs(a,Xs,a.Ta[1],b,d,14,a.wb,Ys,Zs)&&(c=!0),a.Da&&Vs(a,a.La,a.Ta[1],0,a.Da,14,a.wb,e)&&(c=!0))}return c}function Vs(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&($s(a,b,c,d,e,f,g,h,k)&&(m=!0),a.Cd&&$s(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} +function $s(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,w=a.va[b],u=16>h.length?h.length:16;w||(w={Fc:e<ua||!T?ua:8,ib=cb.createImageData(m.Fc,m.Gc);for(Sa=0;256>Sa;Sa++){for(db=0;db=ua-2,Ld=ca[db>(8<=rb&&192<=Sa&&223>=Sa?7:rb)?F:xb;at(ib,sg,ef,tg);H&&at(ib,sg+1,ef,tg)}cb.putImageData(ib,(Sa&15)*m.Fc,(Sa>>4)*m.Gc)}m.Be[K]="#"+q(F[0],2)+q(F[1],2)+q(F[2],2);m.Qi[K]=F;m.Sg[K]=za;m=!0}}a.va[b]=w;return m}function bt(a){0a.Aa&&(a.Aa=0):a.Aa=-1} +function Ps(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.C.Wa[b])return;var c=a.C.Wa[10],b=c&31,d=a.C.Wa[11]&31,e=a.C.Wa[9]&31,f=!1;a.C===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ct(a);else{c=a.C.Wa[15]+((a.C.Wa[14]&63)<<8);a.aa!=c&&(ct(a),a.aa=c);d=d-b+1;if(a.md!=b||a.Hc!=d)a.md=b,a.Hc=d;a.za=e+1;bt(a)}}} +function ct(a){if(0<=a.aa){if(void 0!==a.M){var b=dt<<8,c=a.M[a.aa];if(c&b){var c=c&~b,b=a.aa%a.F,d=a.aa/a.F|0;a.I&&a.va[a.I]&&(a.Ca&&et(a,b,d,c,a.Ca),et(a,b,d,c));a.M[a.aa]=c}}a.aa=-1}} +function ft(a){var b,c=a.C;a.Pc=!1;var d=c.xd[5];if(null!=d){b=ur;var e=wr,f=c.xd[3]&31;switch(d&3){case 0:if(f){e=wr|32;switch(f&24){case 8:e=wr|96;break;case 16:e=wr|160;break;case 24:e=wr|224}c.Qc=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.La==dq&&(e=3,c.Qc=f&7)}d&8&&(b=1280);c=c.$d[4];null!=c&&(c&4||(b|=vr,e|=xr),d&64&&(c&8&&(b|=16384,e|=4),a.Pc=!0));b|=e}return b} +function gt(a,b){var c=a.C;return c&&null!=b&&b!=c.tg?(c.Kg(b),a.ka.Kg(c.bb,c.Ob,c.fh(),!0),!0):!1} +function Os(a,b){var c,d=a.oa,e=a.C;if(e)if(e.La==ps)d=Es;else if(e.La>=bq){var d=null,f=e.qd>>2,g=32768=e.Wa[Wr]?lt:mt:nt:g&128|| +350>f?d=m?ot:pt:480<=f&&(d=a.ga==Ul?qt:rt):d=m?7-d:st:d-=m?2:0);c=ft(a)}}else e.Xc&8&&(e.Xc&2?(d=e.Xc&16?st:Rt,e.Xc&4||--d):(d=e.Xc&1?Cs:Tt,e.Xc&4&&--d));else a.oa=null,null==d&&(d=a.da);if(!Hs(a,d,b))return!1;gt(a,c);return!0} +function Hs(a,b,c){if(null!=b&&(b!=a.oa||c)){a.Ad=0;a.oa=b;a.Ga=!1;b=a.C||(b==Es?a.Y:a.K);if(b!=a.C||b.bb!=a.bb||b.Ob!=a.Ob){ct(a);if(a.bb){if(!Cc(a.ka,a.bb,a.Ob))return!1;a.C&&(a.C.rc=!1)}a.C=b;b.rc=!0;a.bb=b.bb;a.Ob=b.Ob;if(!pc(a.ka,b.bb,b.Ob,3,b===a.A?b:null))return!1}a:{a.I=0;a.F=a.Fb;a.J=a.sc;a.Ma=a.F;a.Eb=is[Es][2];b=0;if(c=is[a.oa])a.F=c[0],a.J=c[1],a.Eb=c[2],b=c[3],a.I=c[4],4!=a.ga&&7!=a.ga||a.C!==a.A||a.I!=Ws||(7==(a.A.Wa[fs]&31)?a.J=350>Kr(a.A,Wr)?43:50:a.I=a.La);a.Wc=a.F*a.J|0;a.Vc=a.Wc/ a.Eb|0;a.Za=a.Vc;a.Pb=0;void 0!==b&&(a.Za=(a.Za<<1)+b|0,a.Pb=a.Za+b>>1);if(a.va.length){a.qa=a.Z/a.F|0;a.ta=a.la/a.J|0;if(a.I){b=a.va[a.I];if(!b)break a;c=a.va[a.I<<1];a.Uc&&80==a.F?c&&a.qa>=3*c.Fc>>2&&(a.I<<=1,b=c):(c&&a.qa>=c.Fc&&(a.I<<=1,b=c),a.Uc||(a.qa=b.Fc,a.ta=b.Gc));a.$a=a.eb=0;b&&(a.$a=a.F*b.Fc,a.eb=a.J*b.Gc)}else a.qa=a.ta=1,a.$a=a.F,a.eb=a.J;a.Ha=a.L.createImageData(a.$a,a.eb);a.Ba=document.createElement("canvas");a.Ba.width=a.$a;a.Ba.height=a.eb;a.Ca=a.Ba.getContext("2d");a.vc=a.zc=0; -a.Qb=a.Z;a.Rb=a.la;b=a.Z-a.F*a.qa;c=a.la-a.J*a.ta;0>1,a.Qb-=b);0>1,a.Rb-=c);if(b||c)a.L.fillStyle=a.O.style.backgroundColor,a.L.fillRect(0,0,a.Z,a.la)}}Lt(a,!0);qs(a)}return!0}function Ss(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function Mt(a){a.ya=-1;a.ma=!1;var b=a.Vc;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function Lt(a,b){b||(a.Ga=!1);Mt(a)} -function Ws(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.va[a.I];h.jf&&(d=h.jf[d]);var k=g>>4&15;h.jf&&(k=h.jf[k]);e?(b*=h.Fc,c*=h.Gc,e.fillStyle=h.Be[k],e.fillRect(b,c,h.Fc,h.Gc)):(b=b*a.qa+a.vc,c=c*a.ta+a.zc,a.L.fillStyle=h.Be[k],a.L.fillRect(b,c,a.qa,a.ta));g&Nt&&(k=(f&15)*h.Fc,f=(f>>4)*h.Gc,e?e.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,h.Fc,h.Gc):a.L.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,a.qa,a.ta));g&Vs&&(f=a.md,g=a.Hc,e?(a.za&&a.za!==h.Gc&&(f=f*h.Gc/a.za|0,g=g*h.Gc/a.za|0),e.fillStyle=h.Be[d],e.fillRect(b, +a.Qb=a.Z;a.Rb=a.la;b=a.Z-a.F*a.qa;c=a.la-a.J*a.ta;0>1,a.Qb-=b);0>1,a.Rb-=c);if(b||c)a.L.fillStyle=a.O.style.backgroundColor,a.L.fillRect(0,0,a.Z,a.la)}}Ut(a,!0);zs(a)}return!0}function at(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function Vt(a){a.ya=-1;a.ma=!1;var b=a.Vc;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function Ut(a,b){b||(a.Ga=!1);Vt(a)} +function et(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.va[a.I];h.jf&&(d=h.jf[d]);var k=g>>4&15;h.jf&&(k=h.jf[k]);e?(b*=h.Fc,c*=h.Gc,e.fillStyle=h.Be[k],e.fillRect(b,c,h.Fc,h.Gc)):(b=b*a.qa+a.vc,c=c*a.ta+a.zc,a.L.fillStyle=h.Be[k],a.L.fillRect(b,c,a.qa,a.ta));g&Wt&&(k=(f&15)*h.Fc,f=(f>>4)*h.Gc,e?e.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,h.Fc,h.Gc):a.L.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,a.qa,a.ta));g&dt&&(f=a.md,g=a.Hc,e?(a.za&&a.za!==h.Gc&&(f=f*h.Gc/a.za|0,g=g*h.Gc/a.za|0),e.fillStyle=h.Be[d],e.fillRect(b, c+f,h.Fc,g)):(a.za&&a.za!==a.ta&&(f=f*a.ta/a.za|0,g=g*a.ta/a.za|0),a.L.fillStyle=h.Be[d],a.L.fillRect(b,c+f,a.qa,g)))} -function qs(a,b){if(a.ea.Yb){var c=!1,d=a.C;d&&(d!==a.A?d.Xc&8&&(c=!0):d.wd&32&&(c=!0));if(c||b){if(b)Mt(a);else if(void 0===a.M)return;var e=!1;!(b||++a.Ad&15)&&0<=a.Aa&&(a.Aa++,e=!0);var f=0,g=a.Wc,h=a.bb,c=h,k=c+a.Ob;a.oa>=ct&&(h=c=655360,k=c+65536);if(Ot(a,d)&8||d.Ye&&d.Ye=Tp&&d.Wa[19]&&d.Wa[19]<<1!=d.Wa[1]+1&&(a.Ma=d.Wa[19]<<(a.I?1:d.Wa[20]&64?3:4),m=(a.Ma*(a.J-1)+a.F)/a.Eb|0,a.oa<=vs&& -(m<<=1));c+m>k&&(m=k-c,0>m&&(m=0));k=c+m;if(b=!b&&a.ma){b=a.ka;for(var p=!0,w=c>>>b.A;0f)return;g=f+1}}if(a.I){if(a.va[a.I]){d=f;f=0;e=a.ya=0;h=Nt<<8;b=1048575;p=a.C.Xc&32;a.La>=Tp&&(p=a.C.Cc[16]&8);m=a.aa-a.C.vd;p&&(e=zs<<8,b&=~e,a.Aa&2||(b&=~h));for(c+=d<<1;c>8|(u&255)<<8;var I=e,T=16;m>=h))>>(T-=h);Ss(a.Ha,m++,p,b[ua])}m>F&&(F=m);p=H&&(H=p+1)}k+=2;d++;if(m>=a.F){m=0;p+=2;if(p>a.J)break;p==a.J&&(p=1,k=c+a.Pb)}}a.ma=!0; -wa.F?a.Ma-a.F-u>>3:0;c>=8;b>w&&(w=b);m=K&&(K=m+1)}c+=H;if(b>=a.F){b=0;if(++m>a.J)break;c+=I}}u||(a.ma=!0);pa.F?a.Ma-a.F-K>>3:0;cI&&(T=I)):(u<<=K,T-=K,a.ma=!1):(a.ma&&u===a.M[d]?(h+=T,T=0):a.M[d]=u,d++);if(T){hp&&(p=h);b=F&&(F=b+1)}if(h>=a.F){h=0;if(++b>a.J)break;c+=H}}K||(a.ma=!0);ma&&(b.wh=a,a=-a|0);a%b.rh>b.mn&&(c|=1);a%b.uh>b.on&&(c|=9);b.fi=a/b.uh|0;return c}l.Cm=function(a,b){return Qt(this,this.Y,a,b)};l.fo=function(a,b,c){var d=this.Y;d.Fg=d.ec;d.ec=b&31;v(this,a,b,c,"CRTC.INDX")};l.Bm=function(a,b){return Rt(this,this.Y,a,b)};l.eo=function(a,b,c){St(this,this.Y,a,b,c)};l.Dm=function(a,b){return Tt(this,this.Y,b)};l.ho=function(a,b,c){a=this.Y;v(this,a.port+4,b,c,"MODE");a.Xc=b;Fs(this,!1)}; -l.Em=function(a,b){return Ut(this,this.Y,b)};l.Mk=function(a,b,c){this.A.Pf=this.A.Pf&-4|b&3;v(this,a,b,c,"FEAT")};l.am=function(a,b){a=this.A.wd;b&&!t(this)||v(this,960,null,b,"ATC.INDX",a);return a};l.rl=function(a,b){a=this.A.Cc[this.A.wd&31];b&&!t(this)||v(this,960,null,b,"ATC."+this.A.Tg[this.A.wd&31],a);return a}; -l.Lk=function(a,b,c){var d=this.A,e=d.wd&32;if(d.Ke){d.Ke=!1;var f=d.wd&31;if(16<=f||!e)if(Vt||d.Cc[f]!==b)c&&!t(this)||v(this,a,b,c,"ATC."+d.Tg[f]),d.Cc[f]=b,Lt(this,!1)}else d.wd=b,v(this,a,b,c,"ATC.INDX"),d.Ke=!0,b&32&&!e&&xs(this,!0)&&qs(this,!0),a=(d.Wa[12]<<8)+d.Wa[13]|0,d.vd!=a&&(d.vd=a,Lt(this)),d.Ye=0}; -l.Om=function(a,b){a=0;if(this.La==Tp)a=3-((this.A.af&12)>>2),a=(this.xb&1<>this.A.xc&63;b&&!t(this)||v(this,969,null,b,"DAC.DATA["+r(this.A.dd)+"]["+r(this.A.xc)+"]",a);this.A.xc+=6;12=lt&&(h=c=655360,k=c+65536);if(Xt(a,d)&8||d.Ye&&d.Ye=bq&&d.Wa[19]&&d.Wa[19]<<1!=d.Wa[1]+1&&(a.Ma=d.Wa[19]<<(a.I?1:d.Wa[20]&64?3:4),m=(a.Ma*(a.J-1)+a.F)/a.Eb|0,a.oa<=Es&& +(m<<=1));c+m>k&&(m=k-c,0>m&&(m=0));k=c+m;if(b=!b&&a.ma){b=a.ka;for(var p=!0,w=c>>>b.A;0f)return;g=f+1}}if(a.I){if(a.va[a.I]){d=f;f=0;e=a.ya=0;h=Wt<<8;b=1048575;p=a.C.Xc&32;a.La>=bq&&(p=a.C.Cc[16]&8);m=a.aa-a.C.vd;p&&(e=Is<<8,b&=~e,a.Aa&2||(b&=~h));for(c+=d<<1;c>8|(u&255)<<8;var I=e,T=16;m>=h))>>(T-=h);at(a.Ha,m++,p,b[ua])}m>F&&(F=m);p=H&&(H=p+1)}k+=2;d++;if(m>=a.F){m=0;p+=2;if(p>a.J)break;p==a.J&&(p=1,k=c+a.Pb)}}a.ma=!0; +wa.F?a.Ma-a.F-u>>3:0;c>=8;b>w&&(w=b);m=K&&(K=m+1)}c+=H;if(b>=a.F){b=0;if(++m>a.J)break;c+=I}}u||(a.ma=!0);pa.F?a.Ma-a.F-K>>3:0;cI&&(T=I)):(u<<=K,T-=K,a.ma=!1):(a.ma&&u===a.M[d]?(h+=T,T=0):a.M[d]=u,d++);if(T){hp&&(p=h);b=F&&(F=b+1)}if(h>=a.F){h=0;if(++b>a.J)break;c+=H}}K||(a.ma=!0);ma&&(b.wh=a,a=-a|0);a%b.rh>b.mn&&(c|=1);a%b.uh>b.on&&(c|=9);b.fi=a/b.uh|0;return c}l.Cm=function(a,b){return Zt(this,this.Y,a,b)};l.fo=function(a,b,c){var d=this.Y;d.Fg=d.ec;d.ec=b&31;v(this,a,b,c,"CRTC.INDX")};l.Bm=function(a,b){return $t(this,this.Y,a,b)};l.eo=function(a,b,c){au(this,this.Y,a,b,c)};l.Dm=function(a,b){return bu(this,this.Y,b)};l.ho=function(a,b,c){a=this.Y;v(this,a.port+4,b,c,"MODE");a.Xc=b;Os(this,!1)}; +l.Em=function(a,b){return cu(this,this.Y,b)};l.Mk=function(a,b,c){this.A.Pf=this.A.Pf&-4|b&3;v(this,a,b,c,"FEAT")};l.am=function(a,b){a=this.A.wd;b&&!t(this)||v(this,960,null,b,"ATC.INDX",a);return a};l.rl=function(a,b){a=this.A.Cc[this.A.wd&31];b&&!t(this)||v(this,960,null,b,"ATC."+this.A.Tg[this.A.wd&31],a);return a}; +l.Lk=function(a,b,c){var d=this.A,e=d.wd&32;if(d.Ke){d.Ke=!1;var f=d.wd&31;if(16<=f||!e)if(du||d.Cc[f]!==b)c&&!t(this)||v(this,a,b,c,"ATC."+d.Tg[f]),d.Cc[f]=b,Ut(this,!1)}else d.wd=b,v(this,a,b,c,"ATC.INDX"),d.Ke=!0,b&32&&!e&&Gs(this,!0)&&zs(this,!0),a=(d.Wa[12]<<8)+d.Wa[13]|0,d.vd!=a&&(d.vd=a,Ut(this)),d.Ye=0}; +l.Om=function(a,b){a=0;if(this.La==bq)a=3-((this.A.af&12)>>2),a=(this.xb&1<>this.A.xc&63;b&&!t(this)||v(this,969,null,b,"DAC.DATA["+r(this.A.dd)+"]["+r(this.A.xc)+"]",a);this.A.xc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=Ea().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= -(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||Ka("aspect"));f&&.3<=f&&3.33>=f&&(Pa("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ja("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new Q(d,e,g,f,c);ob(d,c)}}); -function Wt(a){ab.call(this,"ParallelPort",a,4194304);this.G=a.adapter;switch(this.G){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:Wa("Unrecognized parallel adapter #"+this.G);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":nb(this,a,Xt)}ba(Wt,ab);l=Wt.prototype;l.Cb=function(a,b,c){switch(b){case Xt:return this.na[b]=this.A=c,!0}return!1}; -l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.W=Ob(a,"ChipSet");Ec(b,this,Yt,this.D);Ic(b,this,Zt,this.D);zb(this)};l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){$t(this)};l.save=function(){var a=new Of(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Mb;c[b]=this.mf;a.set(0,c);return a.data()};l.restore=function(a){return $t(this,a[0])}; -function $t(a,b){var c=0;b||(b=[0,0,0]);a.F=b[c++];a.Mb=b[c++];a.mf=b[c];return!0}l.pm=function(a,b){var c=this.F;v(this,a,null,b,"DATA",c);return c};l.Nm=function(a,b){var c=this.Mb;v(this,a,null,b,"STAT",c);return c};l.lm=function(a,b){var c=this.mf;v(this,a,null,b,"CTRL",c);return c}; -l.Rn=function(a,b,c){v(this,a,b,c,"DATA");this.F=b;this.Mb|=au;a=!1;Cb(this,"transmitByte("+r(b)+")");this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.P(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Mb&=~au);bu(this)};l.Mn=function(a,b,c){v(this,a,b,c,"CTRL");this.mf=b;bu(this)}; -function bu(a){a.W&&a.C&&(a.mf&cu&&!(a.Mb&au)?Zg(a.W,a.C):Lg(a.W,a.C))}var Xt="buffer",au=64,cu=16,Yt={0:Wt.prototype.pm,1:Wt.prototype.Nm,2:Wt.prototype.lm},Zt={0:Wt.prototype.Rn,2:Wt.prototype.Mn};Ra(function(){for(var a=pb(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=ra(c[0]);if(d!=this.be)return;c=ra(c[1]);if(this.D=kb(c)){var e=this.D.exports;if(e){var f=e.connect;f&&f.call(this.D,this.O);if(this.aa=e.receiveData){this.O=a;this.Y=e.receiveStatus;this.status("Connected "+this.xe+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; -l.Xb=function(a,b){if(!b)if(this.zj(this.O),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){ju(this)};l.save=function(){var a=new Of(this),b=0,c=[];c[b++]=this.ga;c[b++]=this.la;c[b++]=this.L;c[b++]=this.N;c[b++]=this.G;c[b++]=this.C;c[b++]=this.Z;c[b++]=this.B;c[b++]=this.A;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return ju(this,a[0])}; -function ju(a,b){var c=0;b||(b=[0,0,ku,0,lu,0,0,mu|nu,a.qa,[]]);a.ga=b[c++];a.la=b[c++];a.L=b[c++];a.N=b[c++];a.G=b[c++];a.C=b[c++];a.Z=b[c++];a.B=b[c++];a.A=b[c++];a.J=b[c];return!0}l.Of=function(a){if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.N;v(this,a,null,b,this.C&tu?"DLM":"IER",c);return c};l.xm=function(a,b){var c=this.G;v(this,a,null,b,"IIR",c);return c};l.ym=function(a,b){var c=this.C;v(this,a,null,b,"LCR",c);return c};l.Am=function(a,b){var c=this.Z;v(this,a,null,b,"MCR",c);return c}; -l.zm=function(a,b){var c=this.B;v(this,a,null,b,"LSR",c);return c};l.Fm=function(a,b){var c=this.A;this.A&=~(pu|qu);v(this,a,null,b,"MSR",c);return c}; -l.po=function(a,b,c){v(this,a,b,c,this.C&tu?"DLL":"THR");if(this.C&tu)this.L=this.L&-256|b;else{this.la=b;this.B&=~(mu|nu);a=!1;Cb(this,"transmitByte("+r(b)+")");this.aa&&this.aa.call(this.D,b)&&(a=!0);if(this.F){if(13==b)this.K=0;else if(8==b)this.F.value=this.F.value.slice(0,-1),0":String.fromCharCode(b);a=d.length;32>b&&1==a&&(a=0);9==b&&(b=this.oa||8,a=b-this.K%b,this.oa&&(d=qa("",a)));this.ma&&!this.K&&a&&(d=String.fromCharCode(this.ma)+ -d);this.F.value+=d;this.F.scrollTop=this.F.scrollHeight;this.K+=a}a=!0}else if(null!=this.I){if(10==b||1024<=this.I.length)this.P(this.I),this.I="";10!=b&&(this.I+=String.fromCharCode(b));a=!0}a&&(this.B=this.B|mu|nu)}};l.ao=function(a,b,c){v(this,a,b,c,this.C&tu?"DLM":"IER");this.C&tu?this.L=this.L&255|b<<8:this.N=b};l.bo=function(a,b,c){v(this,a,b,c,"LCR");this.C=b}; -l.co=function(a,b,c){var d=b^this.Z;v(this,a,b,c,"MCR");this.Z=b;d&(uu|vu)&&this.Y&&(a=0,this.O?(a|=b&vu?32:0,a|=b&uu?320:0):(a|=b&vu?16:0,a|=b&uu?1048576:0),this.Y.call(this.D,a))};function ru(a){var b=-1;a.B&su&&a.N&wu?b=xu:a.A&(pu|qu)&&a.N&yu&&(b=zu);0<=b?(a.G&=~(lu|Au),a.G|=b,a.W&&a.M&&Zg(a.W,a.M,100)):(a.G|=lu,a.W&&a.M&&Lg(a.W,a.M))} -var gu="buffer",ku=384,wu=1,yu=8,lu=1,xu=4,zu=0,Au=6,tu=128,uu=1,vu=2,su=1,mu=32,nu=64,pu=1,qu=2,eu=16,fu=32,hu={0:du.prototype.Km,1:du.prototype.wm,2:du.prototype.xm,3:du.prototype.ym,4:du.prototype.Am,5:du.prototype.zm,6:du.prototype.Fm},iu={0:du.prototype.po,1:du.prototype.ao,3:du.prototype.bo,4:du.prototype.co};Ra(function(){for(var a=pb(document,"pcx86","serial"),b=0;ba.F||0>a.G)a.F=b.clientX,a.G=b.clientY;a.M?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.clientX-a.F,d=b.clientY-a.G);a.F=b.clientX;a.G=b.clientY;a.tf(c,d,a.F,a.G)}} -l.Vd=function(a,b){if(this.rc&&this.H&&this.H.ea.vb){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case ss:if(this.K!=b){this.K=b;Hu(this,c);return}break;case Iu:if(this.L!=b){this.L=b;Hu(this,c);return}}Cb(this,c+": ignored")}};l.tf=function(a,b,c,d){this.rc&&this.H&&this.H.ea.vb&&(a||b)&&(this.I=a,this.J=b,Hu(this,null,c,d))}; -function Hu(a,b,c,d){var e=64|(a.K?32:0)|(a.L?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;t(a,8388608)&&Cb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+r(e)+","+r(f)+","+r(g)+"]",0,!0);a.D.Of([e,f,g]);a.I=a.J=0} -l.pl=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.A&16||(this.reset(),Cb(this,"serial mouse reset"),c=!0);this.A&1048576||(Cb(this,"serial mouse ID requested"),c=!0);c&&(this.D.Of([Ju,Ju]),Cb(this,"serial mouse ID sent"));Cu(this);this.rc=b}}else this.rc&&(Cb(this,"serial mouse inactive"),Du(this),this.rc=b);this.A=a};var Ju=77,ss=0,Iu=2;Ra(function(){for(var a=pb(document,"pcx86","mouse"),b=0;b>2;var e=d=0,a=new DataView(a,0,c);g.A=Array(g.ob);for(c=0;cb.indexOf("/api/v1/dump")&&(a=ma(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=Ru(this,b),this.og=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"):na(b, -"/")&&(c="dir"),f=Da()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Oe?"":d)+"&format=json"));return!!Ca(f,null,!0,function(a,b,c){Su(g,a,b,c)})}; -function Su(a,b,c,d){var e=null;a.Re=!1;var f=!(!(0>d&&a.pa)||a.pa.ea.Yb);if(a.og)d?a.controller.Fa('Unable to connect to disk "'+a.I+'" (error '+d+": "+c+")",f):(a.D=!0,Tu(a),e=a);else if(d)a.controller.Fa('Unable to load disk "'+a.F+'" (error '+d+": "+b+")",f);else{eb(a.controller.xe,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)Wa(h[0]);else{a.ob=h.length;a.ib=h[0].length;a.Ya=h[0][0].length;var k=h[0][0][0];a.Na=k&&k.length||512;for(d=c=0;d>2,p=k.pattern;void 0===p&&(p=k.pattern=0);var w=k.data;if(void 0===w){var u=k.bytes;if(void 0!==u&&u.length){for(var F= -m<<2,K=u.length;Kb;b++){if(128==Wu(a,e,c+0,1)){d.Kf=Wu(a,e,c+8,4);(e=Vu(a,d.Kf))&&(f=!0);break}c+=16}if(!f)return}d.sf||(d.sf=Wu(a,e,19,2)||Wu(a,e,32,4),d.rf=Wu(a,e,14,2),d.lh=d.rf+Wu(a,e,22,2)*Wu(a,e,16,1),d.vh=Wu(a,e,17,2),d.vf=Wu(a,e,13,1));d.jh=d.lh+((32*d.vh+(d.Na-1))/d.Na|0);d.kn=(d.sf-d.jh)/d.vf|0;d.vg=4084>=d.kn?12:16;d.Nl=12==d.vg?4086:65526;b=[];for(e=d.lh;e>=8;f+=2;if(k)for(;m--;)jv(d,f,1),254>=k?(p=k,w=jv(d,f+1),f+=3):(p=jv(d,f+3,1),w=jv(d,f+4),f+=6),d.nd[p]&&(d.nd[p].ee[h]=[w]),d.A[h]=[p,w],h++;else h+=m}(g=Zu(e,mv,c))&&nv(e,g+c);g=Zu(e,ov,c);h=Zu(e,pv,c);g&&h&&nv(e,g,g+h)}}}} -function Yu(a,b,c,d,e){var f,g=a.C.length,h=b.Na/32|0;b.cq=d+"\\";for(var k=0;kK)break;for(var H=u.jh+(K-2)*u.vf,I=0;I>3,1),d?e=16==b.vg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} -function Vu(a,b){var c=a.ib*a.Ya,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function Qu(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Ol=b;a.Pl=c;a.hd=a.Lc=0;a.Oa=!1;return a} -function Ru(a,b){b="action=open&volume="+b+("&mode="+a.mode);b+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;b+="&machine="+Ou(a.controller);b+="&user="+Pu(a.controller);return Da()+"/api/v1/disk?"+b} -function sv(a,b,c,d,e,f,g){if(a.D){var h;h="action=read&volume="+a.I;h+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h=h+("&addr="+b+":"+c+":"+d+":"+e)+("&machine="+Ou(a.controller));h+="&user="+Pu(a.controller);Ca(Da()+"/api/v1/disk?"+h,null,f,function(h,m,p){h=[b,c,d,e,f,g];var k=!1,u=h[0],F=h[1],K=h[2],H=h[3];if(!p){m=JSON.parse(m);for(k=0;H--;){var I=a.seek(u,F,K,!0);if(!I)break;Uu(I,m,k);k+=I.length;K++}k=h[4]}(h=h[5])&&h(p,k)})}else g&&g(-1,!1)} -function tv(a,b,c,d,e,f,g){if(a.D){var h={};a.N=!0;h.action="write";h.volume=a.I;h.chs=a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h.addr=b+":"+c+":"+d+":"+e;h.machine=Ou(a.controller);h.user=Pu(a.controller);h.data=JSON.stringify(f);Ca(Da()+"/api/v1/disk",h,g,function(f,h,p){var k=[b,c,d,e,g];f=k[0];h=k[1];var m=k[2],F=k[3],k=k[4];a.N=!1;if(0<=f&&fb&&(b=0);2E3>2,e=Array(d),f=0;f>2,e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2,c=(d>((b&3)<<3)&255;return c}; -l.write=function(a,b,c){if(this.Re)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Lc?f=a.hd+a.Lc&&(a.Lc+=f-(a.hd+a.Lc)+1):(a.hd=f,a.Lc=1);d[f]=d[f]&~(255<Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=Na().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= +(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||Va("aspect"));f&&.3<=f&&3.33>=f&&($a("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ua("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new Q(d,e,g,f,c);zb(d,c)}}); +function eu(a){nb.call(this,"ParallelPort",a,4194304);this.G=a.adapter;switch(this.G){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:hb("Unrecognized parallel adapter #"+this.G);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":yb(this,a,fu)}ba(eu,nb);l=eu.prototype;l.Cb=function(a,b,c){switch(b){case fu:return this.na[b]=this.A=c,!0}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.W=Xb(a,"ChipSet");Oc(b,this,gu,this.D);Sc(b,this,hu,this.D);Jb(this)};l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){iu(this)};l.save=function(){var a=new Xf(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Mb;c[b]=this.mf;a.set(0,c);return a.data()};l.restore=function(a){return iu(this,a[0])}; +function iu(a,b){var c=0;b||(b=[0,0,0]);a.F=b[c++];a.Mb=b[c++];a.mf=b[c];return!0}l.pm=function(a,b){var c=this.F;v(this,a,null,b,"DATA",c);return c};l.Nm=function(a,b){var c=this.Mb;v(this,a,null,b,"STAT",c);return c};l.lm=function(a,b){var c=this.mf;v(this,a,null,b,"CTRL",c);return c}; +l.Rn=function(a,b,c){v(this,a,b,c,"DATA");this.F=b;this.Mb|=ju;a=!1;Mb(this,"transmitByte("+r(b)+")");this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.P(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Mb&=~ju);ku(this)};l.Mn=function(a,b,c){v(this,a,b,c,"CTRL");this.mf=b;ku(this)}; +function ku(a){a.W&&a.C&&(a.mf&lu&&!(a.Mb&ju)?hh(a.W,a.C):fh(a.W,a.C))}var fu="buffer",ju=64,lu=16,gu={0:eu.prototype.pm,1:eu.prototype.Nm,2:eu.prototype.lm},hu={0:eu.prototype.Rn,2:eu.prototype.Mn};ab(function(){for(var a=Ab(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Ca(c[0]);if(d!=this.be)return;c=Ca(c[1]);if(this.D=ub(c)){var e=this.D.exports;if(e){var f=e.connect;f&&f.call(this.D,this.O);if(this.aa=e.receiveData){this.O=a;this.Y=e.receiveStatus;this.status("Connected "+this.xe+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.Xb=function(a,b){if(!b)if(this.zj(this.O),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){su(this)};l.save=function(){var a=new Xf(this),b=0,c=[];c[b++]=this.ga;c[b++]=this.la;c[b++]=this.L;c[b++]=this.N;c[b++]=this.G;c[b++]=this.C;c[b++]=this.Z;c[b++]=this.B;c[b++]=this.A;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return su(this,a[0])}; +function su(a,b){var c=0;b||(b=[0,0,tu,0,uu,0,0,vu|wu,a.qa,[]]);a.ga=b[c++];a.la=b[c++];a.L=b[c++];a.N=b[c++];a.G=b[c++];a.C=b[c++];a.Z=b[c++];a.B=b[c++];a.A=b[c++];a.J=b[c];return!0}l.Of=function(a){if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.N;v(this,a,null,b,this.C&Cu?"DLM":"IER",c);return c};l.xm=function(a,b){var c=this.G;v(this,a,null,b,"IIR",c);return c};l.ym=function(a,b){var c=this.C;v(this,a,null,b,"LCR",c);return c};l.Am=function(a,b){var c=this.Z;v(this,a,null,b,"MCR",c);return c}; +l.zm=function(a,b){var c=this.B;v(this,a,null,b,"LSR",c);return c};l.Fm=function(a,b){var c=this.A;this.A&=~(yu|zu);v(this,a,null,b,"MSR",c);return c}; +l.po=function(a,b,c){v(this,a,b,c,this.C&Cu?"DLL":"THR");if(this.C&Cu)this.L=this.L&-256|b;else{this.la=b;this.B&=~(vu|wu);a=!1;Mb(this,"transmitByte("+r(b)+")");this.aa&&this.aa.call(this.D,b)&&(a=!0);if(this.F){if(13==b)this.K=0;else if(8==b)this.F.value=this.F.value.slice(0,-1),0":String.fromCharCode(b);a=d.length;32>b&&1==a&&(a=0);9==b&&(b=this.oa||8,a=b-this.K%b,this.oa&&(d=Ba("",a)));this.ma&&!this.K&&a&&(d=String.fromCharCode(this.ma)+ +d);this.F.value+=d;this.F.scrollTop=this.F.scrollHeight;this.K+=a}a=!0}else if(null!=this.I){if(10==b||1024<=this.I.length)this.P(this.I),this.I="";10!=b&&(this.I+=String.fromCharCode(b));a=!0}a&&(this.B=this.B|vu|wu)}};l.ao=function(a,b,c){v(this,a,b,c,this.C&Cu?"DLM":"IER");this.C&Cu?this.L=this.L&255|b<<8:this.N=b};l.bo=function(a,b,c){v(this,a,b,c,"LCR");this.C=b}; +l.co=function(a,b,c){var d=b^this.Z;v(this,a,b,c,"MCR");this.Z=b;d&(Du|Eu)&&this.Y&&(a=0,this.O?(a|=b&Eu?32:0,a|=b&Du?320:0):(a|=b&Eu?16:0,a|=b&Du?1048576:0),this.Y.call(this.D,a))};function Au(a){var b=-1;a.B&Bu&&a.N&Fu?b=Gu:a.A&(yu|zu)&&a.N&Hu&&(b=Iu);0<=b?(a.G&=~(uu|Ju),a.G|=b,a.W&&a.M&&hh(a.W,a.M,100)):(a.G|=uu,a.W&&a.M&&fh(a.W,a.M))} +var pu="buffer",tu=384,Fu=1,Hu=8,uu=1,Gu=4,Iu=0,Ju=6,Cu=128,Du=1,Eu=2,Bu=1,vu=32,wu=64,yu=1,zu=2,nu=16,ou=32,qu={0:mu.prototype.Km,1:mu.prototype.wm,2:mu.prototype.xm,3:mu.prototype.ym,4:mu.prototype.Am,5:mu.prototype.zm,6:mu.prototype.Fm},ru={0:mu.prototype.po,1:mu.prototype.ao,3:mu.prototype.bo,4:mu.prototype.co};ab(function(){for(var a=Ab(document,"pcx86","serial"),b=0;ba.F||0>a.G)a.F=b.clientX,a.G=b.clientY;a.M?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.clientX-a.F,d=b.clientY-a.G);a.F=b.clientX;a.G=b.clientY;a.tf(c,d,a.F,a.G)}} +l.Vd=function(a,b){if(this.rc&&this.H&&this.H.ea.vb){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case Bs:if(this.K!=b){this.K=b;Qu(this,c);return}break;case Ru:if(this.L!=b){this.L=b;Qu(this,c);return}}Mb(this,c+": ignored")}};l.tf=function(a,b,c,d){this.rc&&this.H&&this.H.ea.vb&&(a||b)&&(this.I=a,this.J=b,Qu(this,null,c,d))}; +function Qu(a,b,c,d){var e=64|(a.K?32:0)|(a.L?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;t(a,8388608)&&Mb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+r(e)+","+r(f)+","+r(g)+"]",0,!0);a.D.Of([e,f,g]);a.I=a.J=0} +l.pl=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.A&16||(this.reset(),Mb(this,"serial mouse reset"),c=!0);this.A&1048576||(Mb(this,"serial mouse ID requested"),c=!0);c&&(this.D.Of([Su,Su]),Mb(this,"serial mouse ID sent"));Lu(this);this.rc=b}}else this.rc&&(Mb(this,"serial mouse inactive"),Mu(this),this.rc=b);this.A=a};var Su=77,Bs=0,Ru=2;ab(function(){for(var a=Ab(document,"pcx86","mouse"),b=0;b>2;var e=d=0,a=new DataView(a,0,c);g.A=Array(g.ob);for(c=0;cb.indexOf("/api/v1/dump")&&(a=wa(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=$u(this,b),this.og=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"):xa(b, +"/")&&(c="dir"),f=Ma()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Oe?"":d)+"&format=json"));return!!La(f,null,!0,function(a,b,c){av(g,a,b,c)})}; +function av(a,b,c,d){var e=null;a.Re=!1;var f=!(!(0>d&&a.pa)||a.pa.ea.Yb);if(a.og)d?a.controller.Fa('Unable to connect to disk "'+a.I+'" (error '+d+": "+c+")",f):(a.D=!0,bv(a),e=a);else if(d)a.controller.Fa('Unable to load disk "'+a.F+'" (error '+d+": "+b+")",f);else{pb(a.controller.xe,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)hb(h[0]);else{a.ob=h.length;a.ib=h[0].length;a.Ya=h[0][0].length;var k=h[0][0][0];a.Na=k&&k.length||512;for(d=c=0;d>2,p=k.pattern;void 0===p&&(p=k.pattern=0);var w=k.data;if(void 0===w){var u=k.bytes;if(void 0!==u&&u.length){for(var F= +m<<2,K=u.length;Kb;b++){if(128==ev(a,e,c+0,1)){d.Kf=ev(a,e,c+8,4);(e=dv(a,d.Kf))&&(f=!0);break}c+=16}if(!f)return}d.sf||(d.sf=ev(a,e,19,2)||ev(a,e,32,4),d.rf=ev(a,e,14,2),d.lh=d.rf+ev(a,e,22,2)*ev(a,e,16,1),d.vh=ev(a,e,17,2),d.vf=ev(a,e,13,1));d.jh=d.lh+((32*d.vh+(d.Na-1))/d.Na|0);d.kn=(d.sf-d.jh)/d.vf|0;d.vg=4084>=d.kn?12:16;d.Nl=12==d.vg?4086:65526;b=[];for(e=d.lh;e>=8;f+=2;if(k)for(;m--;)sv(d,f,1),254>=k?(p=k,w=sv(d,f+1),f+=3):(p=sv(d,f+3,1),w=sv(d,f+4),f+=6),d.nd[p]&&(d.nd[p].ee[h]=[w]),d.A[h]=[p,w],h++;else h+=m}(g=hv(e,vv,c))&&wv(e,g+c);g=hv(e,xv,c);h=hv(e,yv,c);g&&h&&wv(e,g,g+h)}}}} +function gv(a,b,c,d,e){var f,g=a.C.length,h=b.Na/32|0;b.cq=d+"\\";for(var k=0;kK)break;for(var H=u.jh+(K-2)*u.vf,I=0;I>3,1),d?e=16==b.vg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} +function dv(a,b){var c=a.ib*a.Ya,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function Zu(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Ol=b;a.Pl=c;a.hd=a.Lc=0;a.Oa=!1;return a} +function $u(a,b){b="action=open&volume="+b+("&mode="+a.mode);b+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;b+="&machine="+Xu(a.controller);b+="&user="+Yu(a.controller);return Ma()+"/api/v1/disk?"+b} +function Bv(a,b,c,d,e,f,g){if(a.D){var h;h="action=read&volume="+a.I;h+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h=h+("&addr="+b+":"+c+":"+d+":"+e)+("&machine="+Xu(a.controller));h+="&user="+Yu(a.controller);La(Ma()+"/api/v1/disk?"+h,null,f,function(h,m,p){h=[b,c,d,e,f,g];var k=!1,u=h[0],F=h[1],K=h[2],H=h[3];if(!p){m=JSON.parse(m);for(k=0;H--;){var I=a.seek(u,F,K,!0);if(!I)break;cv(I,m,k);k+=I.length;K++}k=h[4]}(h=h[5])&&h(p,k)})}else g&&g(-1,!1)} +function Cv(a,b,c,d,e,f,g){if(a.D){var h={};a.N=!0;h.action="write";h.volume=a.I;h.chs=a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h.addr=b+":"+c+":"+d+":"+e;h.machine=Xu(a.controller);h.user=Yu(a.controller);h.data=JSON.stringify(f);La(Ma()+"/api/v1/disk",h,g,function(f,h,p){var k=[b,c,d,e,g];f=k[0];h=k[1];var m=k[2],F=k[3],k=k[4];a.N=!1;if(0<=f&&fb&&(b=0);2E3>2,e=Array(d),f=0;f>2,e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2,c=(d>((b&3)<<3)&255;return c}; +l.write=function(a,b,c){if(this.Re)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Lc?f=a.hd+a.Lc&&(a.Lc+=f-(a.hd+a.Lc)+1):(a.hd=f,a.Lc=1);d[f]=d[f]&~(255<=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+m+") out of range ("+ -b+" changes applied)";b=-1;break}if(this.Re){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.controller.Fa("Unable to restore disk '"+this.F+": "+c):Tu(this);return b}; -l.toJSON=function(){var a;a=0;for(var b;b=Vu(this,a++);)yv(b);a=JSON.stringify(this.A,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; -function yv(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var Lu=0;function rv(a,b,c,d,e,f){this.sa=a;this.$b=c;this.Wg=d;this.aj=e;this.fe=f}function jv(a,b,c){var d;c=c||2;var e=b&511,f=Vu(a.sa,a.fe[b>>9]);if(f){if(e+c<=f.length)return Wu(a.sa,f,e,c);for(e=d=0;c--;)d|=jv(a,b++,1)<=e.gi&&a<=e.Ik){d=a-=e.gi;var f,g;for(g in e.ee){var h=e.ee[g],k=a-h[0];if(!k){c=this.Rf+"!"+h[1];break}b&&0'+b+"");a.innerHTML=b}};return!0;case "descDisk":case "listDrives":return this.na[b]=c,c.onchange=function(){var a=ga(c.value,10);null!=a&&Av(d,a)},!0;case "loadDisk":return this.na[b]=c,c.onclick=function(){var a=d.na.listDisks;a&&Bv(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDisk":if(!this.M){c.parentNode.removeChild(c);break}this.na[b]=c;c.onclick=function(){var a=d.na.listDrives;a&&a.options&&d.A&&((a=d.A[ga(a.value, -10)||0])?(a=a.sa)?(a=Ma(xv(a),"octet-stream",!0,a.Jg.replace(".json",".img")),Wa(a)):d.Fa("No diskette loaded in drive."):d.Fa("No diskette drive selected."))};return!0;case "mountDisk":if(this.M)return this.na[b]=c,c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length}),c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Bv(d,la(b,!0),b,a)}return!1},!0;c.parentNode.removeChild(c)}return!1}; -l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.W=Ob(a,"ChipSet");if((this.G=qd(this.pa,"autoMount")||this.G)&&"string"==typeof this.G)try{this.G=eval("("+this.G+")")}catch(e){Wa("FDC auto-mount error: "+e.message+" ("+this.G+")"),this.G=null}Cv(this);Ec(b,this,Dv);Ic(b,this,Ev);Fv(this,"None","",!0);this.M&&Fv(this,"Local Disk","?");Fv(this,"Remote Disk","??");Gv(this)||zb(this)}; -l.Xb=function(a,b){if(!b){if(!a){if(this.reset(),this.pa.O){this.B=[];for(a=0;ag.sa.restore(F)&&(h=!1);h&&g.sa&&void 0!==g.Sa&&(g.cb=g.sa.seek(g.Gb,g.Xa,g.kb));h||(e=!1)}a.I=b[c++]||0;a.Zb=b[c]||Ov;return e} -function Iv(a){var b=0,c=[];c[b++]=a.Ua;c[b++]=0;c[b++]=a.fa;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.J;for(var d=b++,e=0,f=[],g=0;gMv(a,e,b,c,!1,d)&&window.confirm("Click OK to reload the original disk.\n(WARNING: All disk changes will be discarded)");){var f=a,g=c,h;for(h=0;ha.ob||f[1]>a.ib)&&(this.Fa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ua)),b=null);b?(a.sa=b,a.Zk=c,a.te=d,Nv(this,c,d,b),f=b.info(),this.I|=Rv,this.Fa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ua),a.ke||e),a.ug=f[0],a.Af=f[1],a.Bf=f[2],this.pa&&this.pa.ld()):a.Ne=!1;a.ke&&(a.ke=!1,--this.K||zb(this));Av(this,a.Ua)}; -function Fv(a,b,c,d){if((a=a.na.listDisks)&&a.options){for(var e=0;e=this.C&&(this.fa&=~(Uv|Vv),this.D=this.C=0);return c}; -l.Tn=function(a,b,c){t(this)&&v(this,a,b,c,"DATA["+this.C+"]");this.C=Xv[a].Id){b=!1;this.D=0;a=Yv(this);var d,e,f,g,h=a&Wv;switch(h){case Zv:Yv(this);Yv(this);$v(this);break;case aw:c=Yv(this);this.Ua=c&3;d=this.A[this.Ua];$v(this);bw(this,(d.pb&cw)>>>24);break;case dw:case ew:c=Yv(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];d.Xa=b;c=d.Gb=Yv(this);e=Yv(this);f=d.kb=Yv(this);g=Yv(this);d.ub=128<>2&1;this.Ua= -c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=d.kb=1;g=0;d.pb=Qv;d.sa&&(d.cb=d.sa.seek(d.Gb,d.Xa,d.kb))?g=d.cb.length>>8:d.pb=fw|gw;iw(this,d,a,b,c,e,f,g);b=!0;break;case pw:c=Yv(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=1;g=Yv(this);d.ub=128<>2&1,c=Yv(this),d.Gb+=c-d.Sd,0>d.Gb&&(d.Gb=0),d.Gb>=d.ob&&(d.Gb=d.ob-1),d.Sd=c,d.pb=kw,d.Gb||(d.pb|=lw),$v(this),b=!0}0>>8);bw(a,(b.pb&sw)>>>16);var k=0;if(e!=b.Gb||f!=b.Xa)k=g=1;c&tw&&(f^=k,d||(k=0));bw(a,e+k);bw(a,f);bw(a,g);bw(a,h)}function Yv(a){var b=a.F[a.D];a.D++;return b}function $v(a){a.D=a.C=0}function bw(a,b){a.F[a.C++]=b}l.jl=function(a,b,c){void 0===b||0>b?this.se(a,c):c(-1,!1)};l.kl=function(a,b){return void 0!==b&&0<=b?uw(a,b):-1}; -l.Cl=function(a,b){if(void 0!==b&&0<=b)a:if(a.pb)a=-1;else{a.$c[a.Ge++]=b;if(a.Ge==a.$c.length){a.Gb=a.$c[0];a.Xa=a.$c[1];a.kb=a.$c[2];a.ub=128<uw(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a};l.se=function(a,b){var c=-1,d=null,e=0;if(!a.pb&&a.sa){do{if(a.cb&&(e=a.Sa,0<=(c=a.sa.read(a.cb,a.Sa++)))){d=a.cb;break}a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=vw|gw;break}a.Sa=0;ww(a)}while(1)}b(c,!1,d,e)}; -function uw(a,b){if(a.pb||!a.sa)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=xw|gw;b=-1;break}a.Sa=0;ww(a)}while(1);return b}function ww(a){a.kb++;a.kb>=a.Bf+1&&(a.kb=1,a.Xa++,a.Xa>=a.Af&&(a.Xa=0,a.Gb++))}var Lv="Floppy Drive",Sv=4,Tv=8,Vv=16,Uv=64,Jv=128,Zv=3,aw=4,dw=5,ew=6,jw=7,mw=8,ow=10,pw=13,qw=15,Wv=31,tw=128,Qv=0,fw=8,kw=32,gw=64,Kv=192,nw=255,hw=512,vw=1024,xw=8192,rw=65280,sw=16711680,lw=268435456,cw=-16777216,Rv=128,Ov=0;aa={}; -var Xv={3:{Id:3,Ud:0,name:aa.Wp},4:{Id:2,Ud:1,name:aa.Up},5:{Id:9,Ud:7,name:aa.$p},6:{Id:9,Ud:7,name:aa.Qp},7:{Id:2,Ud:0,name:aa.Sp},8:{Id:1,Ud:2,name:aa.Vp},10:{Id:2,Ud:7,name:aa.Rp},13:{Id:6,Ud:7,name:aa.Np},15:{Id:3,Ud:0,name:aa.Tp}},Dv={1009:zv.prototype.rm,1012:zv.prototype.tm,1013:zv.prototype.qm,1015:zv.prototype.sm},Ev={1010:zv.prototype.Un,1013:zv.prototype.Tn,1015:zv.prototype.Sn}; -Ra(function(){for(var a=pb(document,"pcx86","fdc"),b=0;bk.sa.restore(g)&&(F=!1),F&&void 0!==k.Sa&&(k.cb=k.sa.seek(k.Od,k.Xa,k.kb+k.ig)));F||(e=!1);null!=a.O&&1>=d&&(a.O|=(f.type&3)<<(1-d<< +l.restore=function(a){var b=0,c="unsupported restore format";if(a&&0=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+m+") out of range ("+ +b+" changes applied)";b=-1;break}if(this.Re){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.controller.Fa("Unable to restore disk '"+this.F+": "+c):bv(this);return b}; +l.toJSON=function(){var a;a=0;for(var b;b=dv(this,a++);)Hv(b);a=JSON.stringify(this.A,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; +function Hv(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var Uu=0;function Av(a,b,c,d,e,f){this.sa=a;this.$b=c;this.Wg=d;this.aj=e;this.fe=f}function sv(a,b,c){var d;c=c||2;var e=b&511,f=dv(a.sa,a.fe[b>>9]);if(f){if(e+c<=f.length)return ev(a.sa,f,e,c);for(e=d=0;c--;)d|=sv(a,b++,1)<=e.gi&&a<=e.Ik){d=a-=e.gi;var f,g;for(g in e.ee){var h=e.ee[g],k=a-h[0];if(!k){c=this.Rf+"!"+h[1];break}b&&0'+b+"");a.innerHTML=b}};return!0;case "descDisk":case "listDrives":return this.na[b]=c,c.onchange=function(){var a=oa(c.value,10);null!=a&&Jv(d,a)},!0;case "loadDisk":return this.na[b]=c,c.onclick=function(){var a=d.na.listDisks;a&&Kv(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDisk":if(!this.M){c.parentNode.removeChild(c);break}this.na[b]=c;c.onclick=function(){var a=d.na.listDrives;a&&a.options&&d.A&&((a=d.A[oa(a.value, +10)||0])?(a=a.sa)?(a=Xa(Gv(a),"octet-stream",!0,a.Jg.replace(".json",".img")),hb(a)):d.Fa("No diskette loaded in drive."):d.Fa("No diskette drive selected."))};return!0;case "mountDisk":if(this.M)return this.na[b]=c,c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length}),c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Kv(d,va(b,!0),b,a)}return!1},!0;c.parentNode.removeChild(c)}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.W=Xb(a,"ChipSet");if((this.G=zd(this.pa,"autoMount")||this.G)&&"string"==typeof this.G)try{this.G=eval("("+this.G+")")}catch(e){hb("FDC auto-mount error: "+e.message+" ("+this.G+")"),this.G=null}Lv(this);Oc(b,this,Mv);Sc(b,this,Nv);Ov(this,"None","",!0);this.M&&Ov(this,"Local Disk","?");Ov(this,"Remote Disk","??");Pv(this)||Jb(this)}; +l.Xb=function(a,b){if(!b){if(!a){if(this.reset(),this.pa.O){this.B=[];for(a=0;ag.sa.restore(F)&&(h=!1);h&&g.sa&&void 0!==g.Sa&&(g.cb=g.sa.seek(g.Gb,g.Xa,g.kb));h||(e=!1)}a.I=b[c++]||0;a.Zb=b[c]||Xv;return e} +function Rv(a){var b=0,c=[];c[b++]=a.Ua;c[b++]=0;c[b++]=a.fa;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.J;for(var d=b++,e=0,f=[],g=0;gVv(a,e,b,c,!1,d)&&window.confirm("Click OK to reload the original disk.\n(WARNING: All disk changes will be discarded)");){var f=a,g=c,h;for(h=0;ha.ob||f[1]>a.ib)&&(this.Fa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ua)),b=null);b?(a.sa=b,a.Zk=c,a.te=d,Wv(this,c,d,b),f=b.info(),this.I|=$v,this.Fa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ua),a.ke||e),a.ug=f[0],a.Af=f[1],a.Bf=f[2],this.pa&&this.pa.ld()):a.Ne=!1;a.ke&&(a.ke=!1,--this.K||Jb(this));Jv(this,a.Ua)}; +function Ov(a,b,c,d){if((a=a.na.listDisks)&&a.options){for(var e=0;e=this.C&&(this.fa&=~(cw|dw),this.D=this.C=0);return c}; +l.Tn=function(a,b,c){t(this)&&v(this,a,b,c,"DATA["+this.C+"]");this.C=fw[a].Id){b=!1;this.D=0;a=gw(this);var d,e,f,g,h=a&ew;switch(h){case hw:gw(this);gw(this);iw(this);break;case jw:c=gw(this);this.Ua=c&3;d=this.A[this.Ua];iw(this);kw(this,(d.pb&lw)>>>24);break;case mw:case nw:c=gw(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];d.Xa=b;c=d.Gb=gw(this);e=gw(this);f=d.kb=gw(this);g=gw(this);d.ub=128<>2&1;this.Ua= +c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=d.kb=1;g=0;d.pb=Zv;d.sa&&(d.cb=d.sa.seek(d.Gb,d.Xa,d.kb))?g=d.cb.length>>8:d.pb=ow|pw;rw(this,d,a,b,c,e,f,g);b=!0;break;case yw:c=gw(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=1;g=gw(this);d.ub=128<>2&1,c=gw(this),d.Gb+=c-d.Sd,0>d.Gb&&(d.Gb=0),d.Gb>=d.ob&&(d.Gb=d.ob-1),d.Sd=c,d.pb=tw,d.Gb||(d.pb|=uw),iw(this),b=!0}0>>8);kw(a,(b.pb&Bw)>>>16);var k=0;if(e!=b.Gb||f!=b.Xa)k=g=1;c&Cw&&(f^=k,d||(k=0));kw(a,e+k);kw(a,f);kw(a,g);kw(a,h)}function gw(a){var b=a.F[a.D];a.D++;return b}function iw(a){a.D=a.C=0}function kw(a,b){a.F[a.C++]=b}l.jl=function(a,b,c){void 0===b||0>b?this.se(a,c):c(-1,!1)};l.kl=function(a,b){return void 0!==b&&0<=b?Dw(a,b):-1}; +l.Cl=function(a,b){if(void 0!==b&&0<=b)a:if(a.pb)a=-1;else{a.$c[a.Ge++]=b;if(a.Ge==a.$c.length){a.Gb=a.$c[0];a.Xa=a.$c[1];a.kb=a.$c[2];a.ub=128<Dw(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a};l.se=function(a,b){var c=-1,d=null,e=0;if(!a.pb&&a.sa){do{if(a.cb&&(e=a.Sa,0<=(c=a.sa.read(a.cb,a.Sa++)))){d=a.cb;break}a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=Ew|pw;break}a.Sa=0;Fw(a)}while(1)}b(c,!1,d,e)}; +function Dw(a,b){if(a.pb||!a.sa)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=Gw|pw;b=-1;break}a.Sa=0;Fw(a)}while(1);return b}function Fw(a){a.kb++;a.kb>=a.Bf+1&&(a.kb=1,a.Xa++,a.Xa>=a.Af&&(a.Xa=0,a.Gb++))}var Uv="Floppy Drive",aw=4,bw=8,dw=16,cw=64,Sv=128,hw=3,jw=4,mw=5,nw=6,sw=7,vw=8,xw=10,yw=13,zw=15,ew=31,Cw=128,Zv=0,ow=8,tw=32,pw=64,Tv=192,ww=255,qw=512,Ew=1024,Gw=8192,Aw=65280,Bw=16711680,uw=268435456,lw=-16777216,$v=128,Xv=0;aa={}; +var fw={3:{Id:3,Ud:0,name:aa.Wp},4:{Id:2,Ud:1,name:aa.Up},5:{Id:9,Ud:7,name:aa.$p},6:{Id:9,Ud:7,name:aa.Qp},7:{Id:2,Ud:0,name:aa.Sp},8:{Id:1,Ud:2,name:aa.Vp},10:{Id:2,Ud:7,name:aa.Rp},13:{Id:6,Ud:7,name:aa.Np},15:{Id:3,Ud:0,name:aa.Tp}},Mv={1009:Iv.prototype.rm,1012:Iv.prototype.tm,1013:Iv.prototype.qm,1015:Iv.prototype.sm},Nv={1010:Iv.prototype.Un,1013:Iv.prototype.Tn,1015:Iv.prototype.Sn}; +ab(function(){for(var a=Ab(document,"pcx86","fdc"),b=0;bk.sa.restore(g)&&(F=!1),F&&void 0!==k.Sa&&(k.cb=k.sa.seek(k.Od,k.Xa,k.kb+k.ig)));F||(e=!1);null!=a.O&&1>=d&&(a.O|=(f.type&3)<<(1-d<< 1))}0<=a.Ua&&(a.B=a.A[a.Ua]);return e} -function Gw(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.va,c[b++]=a.J,c[b++]=a.ga,c[b++]=a.da,c[b++]=a.aa,c[b++]=a.Y,c[b++]=a.fa,c[b++]=a.ha,c[b++]=[a.L,a.Ua]):(c[b++]=a.O,c[b++]=a.fa,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ta,c[b++]=a.qa,c[b++]=a.oa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.fa&=~(Pw|Qw|Rw));return c};l.ro=function(a,b,c){v(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.fa|=Pw,this.fa&=~Tw,Uw(this))};l.Um=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.fa=Ww,a.se(a.B,function(b){0<=b?(Xw(a),a.W&&a.W.ca==ol&&(a.fa=0),a.fa=a.fa|Hw|Yw|Zw):(a.fa=$w,a.I=ax)},!1)):a.fa=Hw|Yw));return d}l.nl=function(a,b){return Vw(this,a,b)|Vw(this,a,b)<<8}; -function bx(a,b,c,d){if(a.B&&a.B.ub>=a.B.Na)if(0>cx(a.B,c))a.fa=$w,a.I=ax;else if(1==a.B.Sa||a.B.Sa==a.B.Na)t(a,1048832)&&v(a,b,c,d,"DATA["+a.B.Sa+"]"),1=a.B.Na&&(a.fa|=Zw))}l.An=function(a,b,c){bx(this,a,b&255,c);bx(this,a,b>>8&255,c)};l.$l=function(a,b){var c=this.I;v(this,a,null,b,"ERROR",c);return c};l.Fn=function(a,b,c){v(this,a,b,c,"WPREC");this.va=b};l.bm=function(a,b){var c=this.J;v(this,a,null,b,"SECCNT",c);return c}; +function Pw(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.va,c[b++]=a.J,c[b++]=a.ga,c[b++]=a.da,c[b++]=a.aa,c[b++]=a.Y,c[b++]=a.fa,c[b++]=a.ha,c[b++]=[a.L,a.Ua]):(c[b++]=a.O,c[b++]=a.fa,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ta,c[b++]=a.qa,c[b++]=a.oa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.fa&=~(Yw|Zw|$w));return c};l.ro=function(a,b,c){v(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.fa|=Yw,this.fa&=~bx,cx(this))};l.Um=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.fa=ex,a.se(a.B,function(b){0<=b?(fx(a),a.W&&a.W.ca==xl&&(a.fa=0),a.fa=a.fa|Qw|gx|hx):(a.fa=ix,a.I=jx)},!1)):a.fa=Qw|gx));return d}l.nl=function(a,b){return dx(this,a,b)|dx(this,a,b)<<8}; +function kx(a,b,c,d){if(a.B&&a.B.ub>=a.B.Na)if(0>lx(a.B,c))a.fa=ix,a.I=jx;else if(1==a.B.Sa||a.B.Sa==a.B.Na)t(a,1048832)&&v(a,b,c,d,"DATA["+a.B.Sa+"]"),1=a.B.Na&&(a.fa|=hx))}l.An=function(a,b,c){kx(this,a,b&255,c);kx(this,a,b>>8&255,c)};l.$l=function(a,b){var c=this.I;v(this,a,null,b,"ERROR",c);return c};l.Fn=function(a,b,c){v(this,a,b,c,"WPREC");this.va=b};l.bm=function(a,b){var c=this.J;v(this,a,null,b,"SECCNT",c);return c}; l.Dn=function(a,b,c){v(this,a,b,c,"SECCNT");this.J=b};l.cm=function(a,b){var c=this.ga;v(this,a,null,b,"SECNUM",c);return c};l.En=function(a,b,c){v(this,a,b,c,"SECNUM");this.ga=b};l.Yl=function(a,b){var c=this.da;v(this,a,null,b,"CYLLO",c);return c};l.zn=function(a,b,c){v(this,a,b,c,"CYLLO");this.da=b};l.Xl=function(a,b){var c=this.aa;v(this,a,null,b,"CYLHI",c);return c};l.yn=function(a,b,c){v(this,a,b,c,"CYLHI");this.aa=b};l.Zl=function(a,b){var c=this.Y;v(this,a,null,b,"DRVHD",c);return c}; -l.Bn=function(a,b,c){v(this,a,b,c,"DRVHD");this.Y=b;this.fa=this.A[this.Y&dx?1:0]?this.fa|Hw|Yw:this.fa&~Hw};l.dm=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.fa&Hw&&(this.fa&=~Ww);return c};l.xn=function(a,b,c){v(this,a,b,c,"COMMAND");this.ha=b;this.W&&Lg(this.W,14);ex(this)};l.Cn=function(a,b,c){v(this,a,b,c,"FDR");this.L&fx&&!(b&fx)&&(this.I=gx);this.L=b}; -function ex(a){var b=!1,c=a.ha,d=a.Y&dx?1:0,e=a.Y&hx,f=a.da|(a.aa&ix)<<8,g=a.ga,h=a.J||256;a.Ua=-1;a.B=null;a.I=jx;a.fa=Hw|Yw;var k=a.A[d];k?(k.Od=f,k.Xa=e,k.kb=g,k.ub=h*k.Na,c=c>=kx?c:c&lx,k.cb=null,k.Sa=0,k.errorCode=0,a.Ua=d,a.B=k):c=-1;switch(c&lx){case mx:b=!0;break;case nx:a.fa=Ww;a.se(k,function(b){0<=b&&a.W?(Xw(a),a.fa=Hw|Yw|Zw):(a.fa=$w,a.I=ax)},!1);break;case ox:a.fa=Zw;break;case px:b=!0;break;case qx:b=!0;break;case kx:a.I=gx;b=!0;break;case rx:k.ib=e+1,k.Ya=h,b=!0}b&&Xw(a)} -function Xw(a){!a.W||a.L&sx||Zg(a.W,14,120)} -function Uw(a){a.D=0;var b=tx(a),c=tx(a),d=c&32,e=d>>5,f=c&31,g=tx(a),h=tx(a),k=g<<2&768|h,m=g&63,p=tx(a),w=tx(a),u=a.A[e];u&&(u.Od=k,u.Xa=f,u.kb=m,u.ub=p*u.Na);switch(b){case ux:vx(a,u?u.errorCode:wx);xx(a,c);xx(a,g);xx(a,h);xx(a,yx|d);b=-1;break;case Sw:for(c=0;0<=(b=tx(a));)u&&cb?this.se(a,c):c(-1,!1)};l.ml=function(a,b){return void 0!==b&&0<=b?cx(a,b):-1}; -l.Dl=function(a,b){void 0!==b&&0<=b?(a.Sacx(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a}; -function Gx(a,b,c){b.errorCode=wx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Jw;An(a.W,3,a,"dmaRead",b);rn(a.W,3,function(a){a||b.errorCode!=Jw||(b.errorCode=wx);c(b.errorCode?zx:yx)});return}c(b.errorCode?zx:yx)}function Ix(a,b,c){b.errorCode=wx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Jw;An(a.W,3,a,"dmaWrite",b);rn(a.W,3,function(a){a||(b.errorCode==Jw&&(b.errorCode=wx),b.errorCode==Lx&&(b.errorCode=Jw));c(b.errorCode?zx:yx)});return}c(b.errorCode?zx:yx)} -function Kx(a,b,c){b.errorCode=wx;b.Ee&&b.Ee.length==b.ub||(b.Ee=Array(b.ub));b.Sa=0;a.W?(b.errorCode=Jw,An(a.W,3,a,"dmaWriteBuffer",b),rn(a.W,3,function(a){a||b.errorCode!=Jw||(b.errorCode=wx);c(b.errorCode?zx:yx)})):c(b.errorCode?zx:yx)} -l.se=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.cb&&(f=a.Sa,d=a.sa.read(a.cb,a.Sa),a.Sa+=g,0<=d))return e=a.cb,b&&b(d,!1,e,f),d;if(b){if(a.sa)return a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!1,function(c,k){(a.cb=c)?(e=c,f=a.Sa=0,Mx(a),d=a.sa.read(a.cb,a.Sa),a.Sa+=g):a.errorCode=Lx;b(d,k,e,f)}),d;a.errorCode=Lx;b(d,!1,e,f)}return d}; -function cx(a,b){if(a.errorCode)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.sa&&a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!0,function(b){a.cb=b});if(!a.cb){a.errorCode=Lx;b=-1;break}a.Sa=0;Mx(a)}while(1);return b}function Mx(a){a.kb++;var b=1-a.ig;a.kb>=a.Ya+b&&(a.kb=b,a.Xa++,a.Xa>=a.ib&&(a.Xa=0,a.Od++))}l.Vm=function(){var a=this.H.L&255;!(this.H.D>>8)&&128>8||!this.W)||(a=!(this.W.hc[0].od&64));return a?!0:!1}; -var Kw="Hard Drive",Nw=["XTC","ATC","COMPAQ"],Lw=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, -6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],Dw=496,gx=1,jx=0,ax=16,ix=3,hx=15,dx=16,$w=1,Zw=8,Yw=16,Hw=64,Ww=128,mx=16,nx=32,ox=48,px=64,qx= -112,kx=144,rx=145,lx=240,sx=2,fx=4,yx=0,zx=2,Cx=0,Dx=1,ux=3,Ex=5,Fx=8,Hx=10,Sw=12,Jx=15,Ax=224,Bx=228,Jw=0,wx=4,Lx=20,Iw=0,Tw=1,Pw=2,Qw=4,Rw=8,Ow=32,Aw={800:yw.prototype.Tm,801:yw.prototype.Um,802:yw.prototype.Sm},zw={496:yw.prototype.nl,497:yw.prototype.$l,498:yw.prototype.bm,499:yw.prototype.cm,500:yw.prototype.Yl,501:yw.prototype.Xl,502:yw.prototype.Zl,503:yw.prototype.dm},Cw={800:yw.prototype.ro,801:yw.prototype.uo,802:yw.prototype.to,803:yw.prototype.so,807:yw.prototype.hi,811:yw.prototype.hi, -815:yw.prototype.hi},Bw={496:yw.prototype.An,497:yw.prototype.Fn,498:yw.prototype.Dn,499:yw.prototype.En,500:yw.prototype.zn,501:yw.prototype.yn,502:yw.prototype.Bn,503:yw.prototype.xn,1014:yw.prototype.Cn};Ra(function(){for(var a=pb(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.aa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(ra(a.substring(d,f))),d=f+1}}return b}; -function Ox(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +l.Bn=function(a,b,c){v(this,a,b,c,"DRVHD");this.Y=b;this.fa=this.A[this.Y&mx?1:0]?this.fa|Qw|gx:this.fa&~Qw};l.dm=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.fa&Qw&&(this.fa&=~ex);return c};l.xn=function(a,b,c){v(this,a,b,c,"COMMAND");this.ha=b;this.W&&fh(this.W,14);nx(this)};l.Cn=function(a,b,c){v(this,a,b,c,"FDR");this.L&ox&&!(b&ox)&&(this.I=px);this.L=b}; +function nx(a){var b=!1,c=a.ha,d=a.Y&mx?1:0,e=a.Y&qx,f=a.da|(a.aa&rx)<<8,g=a.ga,h=a.J||256;a.Ua=-1;a.B=null;a.I=sx;a.fa=Qw|gx;var k=a.A[d];k?(k.Od=f,k.Xa=e,k.kb=g,k.ub=h*k.Na,c=c>=tx?c:c&ux,k.cb=null,k.Sa=0,k.errorCode=0,a.Ua=d,a.B=k):c=-1;switch(c&ux){case vx:b=!0;break;case wx:a.fa=ex;a.se(k,function(b){0<=b&&a.W?(fx(a),a.fa=Qw|gx|hx):(a.fa=ix,a.I=jx)},!1);break;case xx:a.fa=hx;break;case yx:b=!0;break;case zx:b=!0;break;case tx:a.I=px;b=!0;break;case Ax:k.ib=e+1,k.Ya=h,b=!0}b&&fx(a)} +function fx(a){!a.W||a.L&Bx||hh(a.W,14,120)} +function cx(a){a.D=0;var b=Cx(a),c=Cx(a),d=c&32,e=d>>5,f=c&31,g=Cx(a),h=Cx(a),k=g<<2&768|h,m=g&63,p=Cx(a),w=Cx(a),u=a.A[e];u&&(u.Od=k,u.Xa=f,u.kb=m,u.ub=p*u.Na);switch(b){case Dx:Ex(a,u?u.errorCode:Fx);Gx(a,c);Gx(a,g);Gx(a,h);Gx(a,Hx|d);b=-1;break;case ax:for(c=0;0<=(b=Cx(a));)u&&cb?this.se(a,c):c(-1,!1)};l.ml=function(a,b){return void 0!==b&&0<=b?lx(a,b):-1}; +l.Dl=function(a,b){void 0!==b&&0<=b?(a.Salx(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a}; +function Px(a,b,c){b.errorCode=Fx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Sw;Jn(a.W,3,a,"dmaRead",b);An(a.W,3,function(a){a||b.errorCode!=Sw||(b.errorCode=Fx);c(b.errorCode?Ix:Hx)});return}c(b.errorCode?Ix:Hx)}function Rx(a,b,c){b.errorCode=Fx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Sw;Jn(a.W,3,a,"dmaWrite",b);An(a.W,3,function(a){a||(b.errorCode==Sw&&(b.errorCode=Fx),b.errorCode==Ux&&(b.errorCode=Sw));c(b.errorCode?Ix:Hx)});return}c(b.errorCode?Ix:Hx)} +function Tx(a,b,c){b.errorCode=Fx;b.Ee&&b.Ee.length==b.ub||(b.Ee=Array(b.ub));b.Sa=0;a.W?(b.errorCode=Sw,Jn(a.W,3,a,"dmaWriteBuffer",b),An(a.W,3,function(a){a||b.errorCode!=Sw||(b.errorCode=Fx);c(b.errorCode?Ix:Hx)})):c(b.errorCode?Ix:Hx)} +l.se=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.cb&&(f=a.Sa,d=a.sa.read(a.cb,a.Sa),a.Sa+=g,0<=d))return e=a.cb,b&&b(d,!1,e,f),d;if(b){if(a.sa)return a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!1,function(c,k){(a.cb=c)?(e=c,f=a.Sa=0,Vx(a),d=a.sa.read(a.cb,a.Sa),a.Sa+=g):a.errorCode=Ux;b(d,k,e,f)}),d;a.errorCode=Ux;b(d,!1,e,f)}return d}; +function lx(a,b){if(a.errorCode)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.sa&&a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!0,function(b){a.cb=b});if(!a.cb){a.errorCode=Ux;b=-1;break}a.Sa=0;Vx(a)}while(1);return b}function Vx(a){a.kb++;var b=1-a.ig;a.kb>=a.Ya+b&&(a.kb=b,a.Xa++,a.Xa>=a.ib&&(a.Xa=0,a.Od++))}l.Vm=function(){var a=this.H.L&255;!(this.H.D>>8)&&128>8||!this.W)||(a=!(this.W.hc[0].od&64));return a?!0:!1}; +var Tw="Hard Drive",Ww=["XTC","ATC","COMPAQ"],Uw=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, +6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],Mw=496,px=1,sx=0,jx=16,rx=3,qx=15,mx=16,ix=1,hx=8,gx=16,Qw=64,ex=128,vx=16,wx=32,xx=48,yx=64,zx= +112,tx=144,Ax=145,ux=240,Bx=2,ox=4,Hx=0,Ix=2,Lx=0,Mx=1,Dx=3,Nx=5,Ox=8,Qx=10,ax=12,Sx=15,Jx=224,Kx=228,Sw=0,Fx=4,Ux=20,Rw=0,bx=1,Yw=2,Zw=4,$w=8,Xw=32,Jw={800:Hw.prototype.Tm,801:Hw.prototype.Um,802:Hw.prototype.Sm},Iw={496:Hw.prototype.nl,497:Hw.prototype.$l,498:Hw.prototype.bm,499:Hw.prototype.cm,500:Hw.prototype.Yl,501:Hw.prototype.Xl,502:Hw.prototype.Zl,503:Hw.prototype.dm},Lw={800:Hw.prototype.ro,801:Hw.prototype.uo,802:Hw.prototype.to,803:Hw.prototype.so,807:Hw.prototype.hi,811:Hw.prototype.hi, +815:Hw.prototype.hi},Kw={496:Hw.prototype.An,497:Hw.prototype.Fn,498:Hw.prototype.Dn,499:Hw.prototype.En,500:Hw.prototype.zn,501:Hw.prototype.yn,502:Hw.prototype.Bn,503:Hw.prototype.xn,1014:Hw.prototype.Cn};ab(function(){for(var a=Ab(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.aa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Ca(a.substring(d,f))),d=f+1}}return b}; +function Xx(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} -function Px(a,b,c){var d;if(b){b=Qx(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function Vx(a,b){if(b)return Tx(a,b,a.da[b]);var c=0;for(b in a.da)Tx(a,b,a.da[b]),c++;return 0a&&-1>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Sx={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; -function Wx(a){Nx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=Xx(this);this.Ga=Xx(this);this.Z=Xx(this);this.D=[];this.B=this.Y=this.M=[];Yx(this);this.ta=0;Zx(this);this.za={};$x(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return ay(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return ay(b,a)})}ba(Wx,Nx);l=Wx.prototype; -l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Ob(a,"FDC");this.Ha=Ob(a,"HDC");this.Tc=Ob(a,"FPU");this.G=Ob(a,"Mouse");(a=qd(a,"messages"))&&$x(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Kd(this.H,7,"DBG");this.ma=by;80186<=this.H.ca&&(this.ma=by.slice(),this.ma[15]=cy,80286<=this.H.ca&&(this.ma[15]=dy,80386<=this.H.ca&&(this.oa=8)));rl(this,64,function(a){ey(d,d.H.sc,a[0])});rl(this,4,function(a){if(a=a[0]){var b=Rx(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=fy(d, -b,gy),d.P("dumpSel("+ka(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=hy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ka(a.ua&65535)+" off="+ka(a.Ka):"base="+q(a.ua,d.ha)+" limit="+iy(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ka(a.ext&-65296)+ -" dpl="+r(a.qc))}}else d.P("no selector")});rl(this,134217728,function(a){var b;(a=a[0])&&(b=Rx(d,a));if(void 0===b)d.P("invalid MCB");else for(d.P("dumpMCB("+ka(b)+")");b;){a=Xx(d,0,b);var c=d.Ia(a,1),e=d.Yc(a,2),k=d.Yc(a,5);if(77!=c&&90!=c)break;d.P(jy(0,b)+": '"+String.fromCharCode(c)+"' PID="+ka(e)+" LEN="+ka(k)+' "'+ky(d,a,8)+'"');b+=1+k}});rl(this,128,function(a){ey(d,d.H.aa,a[0],d.H.aa!==d.H.sc)});rl(this,8,function(a){a:{if(a=a[0]){var b=Rx(d,a);if(void 0===b){d.P("invalid task selector: "+ -a);break a}a=fy(d,b,gy)}else a=d.H.la;d.P("dumpTSS("+ka(a?a.U:b)+"): %"+q(a?a.ua:null,d.ha));if(a){var b="",c=a.type&-513,e=256==c?4:8,k=256==c?ly:my,m,p,w,u;for(u in k)m=k[u],p=a.ua+m,w=ng(d.H,p,2),2304==c&&(w|=ng(d.H,p+2,2)<<16),b&&(b+="\n"),b+=ka(m)+" "+qa(u+":",11)+q(w,e);if(2304==c)for(u=0,m=w>>>16;mu;)p=a.ua+m,w=ng(d.H,p,2),b+="\n"+ka(m)+" ports "+ka(u)+"-"+ka(u+15)+": "+ia(w,2),u+=16,m+=2;d.P(b)}}});this.F=null;this.Da=0;this.Aa=!1;Jf(this.H,48,this.Ym.bind(this));Jf(this.H,65, -this.Zm.bind(this));this.O=null;Jf(this.H,104,this.$m.bind(this));zb(this)};function ny(a,b,c,d,e,f){b=ky(a,b);var g=fy(a,d),g=g?g.Ka+1:0,h=(e?"_CODE":"_DATA")+q(c,2);f&&t(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=oy(a,b,c);e[b+h]=0;Sp(a,b,c,d,0,null,g,e)} -function py(a,b,c,d){var e=a.Yc(b,2),f=a.Yc(b,2),g=qy(a,b,4),h=qy(a,b,4),k=Xx(a,qy(a,b,4),a.Yc(b,2));b=Xx(a,qy(a,b,4),a.Yc(b,2));b=ky(a,b).toUpperCase();var k=ky(a,k).toUpperCase(),m=(c?"_CODE":"_DATA")+q(e,2);d&&t(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+q(e,4)+")="+q(f,4)+":"+q(g)+" len "+q(h));c=oy(a,k,e);c[k+m]=g;Sp(a,k,e,f,g,null,h,c)}function ry(a,b,c){c=ky(a,c).toUpperCase();sy(a,c,b)} -l.Ym=function(){var a=this.H;if(null!=this.F&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=Xx(this,z(a)+12,a.Y.U);switch(qy(this,d)){case 336:py(this,Xx(this,a.G,b),!c,!!this.F)}}return!0}; -l.Zm=function(a){var b=this.H,c=b.D&65535,d=b.G&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.oa.U;if(null==this.F)return 79==c&&Kf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Cb(a,"INT 0x41 handling enabled",128),a.F=!0):(Cb(a,"INT 0x41 monitoring enabled",128),a.F=!1)}}(this)),!0;switch(c){case 79:this.F&&(b.D=b.D&-65536|62342,Cb(this,"INT 0x41 handling enabled",128));break;case 80:ny(this,Xx(this,h,k),d+1,e,!(g&1),!!this.F);break;case 82:sy(this,null, -d);break;case 127:this.F&&(b.D=b.D&-65536|(this.Aa?0:1));break;case 131:this.F&&(a=Xx(this,b.L,e),this.Da++?(this.P("TRAPFAULT failed"),ty(this,this.B,a,!0,!0),this.Da=0,this.Jb()):(this.P("INT 0x41 TRAPFAULT: fault="+ka(d)+" error="+q(b.K,8,!0)+" addr="+uy(a)),this.Gd(this.B,a,!0),Zx(this,!0)));break;case 141:this.F&&(b.D=b.D&-65536|1);break;case 336:py(this,Xx(this,b.G,f),!g,!!this.F);break;case 338:ry(this,d,Xx(this,b.J,f))}this.Aa=!1;return!this.F}; -l.$m=function(a){var b=this.H,c=b.D&255,d=b.D>>8&255,e=b.G&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.oa.U;if(null==this.O){if(67==d){if(609437257==b.ia((b.Z.U<<4)+10)||1111835735==b.ia((b.Z.U<<4)+95))return!0;Kf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Cb(a,"INT 0x68 handling enabled",128),a.F=a.O=!0):(Cb(a,"INT 0x68 monitoring enabled",128),a.O=!1)}}(this))}return!0}switch(d){case 67:this.O&&(b.D=b.D&-65536|62342);break;case 68:this.O&&(a=Nd(b.Z,this.yl.bind(this)))&& -(b.J=a[0],fe(b,a[1]));break;case 72:sy(this,null,e);break;case 80:32==c?ny(this,Xx(this,h,k),0,f,!0,!!this.O):128>c?ny(this,Xx(this,h,k),e+1,c&64?g:f,!(c&1),!!this.O):py(this,Xx(this,h,k),!(c&1),!!this.O),this.O&&(b.D=b.D&-256|1)}return!this.O};l.yl=function(){var a=this.H;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; -l.Cb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.qa=this.na[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",ay(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.A>>0)+1;a.jb=f;a.type=g;a.ext=k;a.Lb=d;Md(a,!0,!0,!1)}}return a}l.Sb=function(a,b,c){var d=a&&a.xa;if(null==d&&(d=-1,a)){var e=fy(this,a.U,a.type);e&&(b=a.Ja||0,c=c||1,d=e=-1===e.Lb||e.Oc&&(b>>>0)+c>e.Nb||!e.Oc&&(b>>>0)+c<=e.Nb?e.ua+b|0:-1,a.xa=d)}return d};l.Ia=function(a,b){var c=255,d=this.Sb(a,!1,1);-1!==d&&(c=ng(this.H,d,1,a.type==yy)|0,b&&zy(this,a,b));return c}; -l.hb=function(a,b){return a.Hb?qy(this,a,b?4:0):this.Yc(a,b?2:0)};l.Yc=function(a,b){var c=65535,d=this.Sb(a,!1,2);-1!==d&&(c=ng(this.H,d,2,a.type==yy)|0,b&&zy(this,a,b));return c};function qy(a,b,c){var d=-1,e=a.Sb(b,!1,4);-1!==e&&(d=ng(a.H,e,4,b.type==yy)|0,c&&zy(a,b,c));return d}l.fc=function(a,b,c,d){var e=this.Sb(a,!0,1);if(-1!==e){if(a.type!=yy)this.H.fc(e,b);else{var f=this.ka;f.aa[(e&f.C)>>>f.A].bf(e&f.D,b&255,e)}c&&zy(this,a,c);d||td(this.H,!0)}}; -l.il=function(a,b,c){var d=this.Sb(a,!0,2);-1!==d&&(a.type!=yy?this.H.fb(d,b):Bc(this.ka,d,b),c&&zy(this,a,c),td(this.H,!0))};function Xx(a,b,c,d,e,f,g){return Ay(a,{},b,c,d,e,f,g)}function Ay(a,b,c,d,e,f,g,h){b.Ja=c||0;b.U=d;b.xa=e;b.type=f||(wy(a)?gy:xy);b.Hb=null!=g?g:!(!a.H||4!=a.H.Z.V);b.dc=null!=h?h:!(!a.H||4!=a.H.Z.Jc);b.Jd=!1;return b}function By(a){return[a.Ja,a.U,a.xa,a.Jd,a.Hb,a.dc,a.Fe,a.bh]}function Cy(a){return{Ja:a[0],U:a[1],xa:a[2],Jd:a[3],Hb:a[4],dc:a[5],Fe:a[6],bh:a[7]}} -function Dy(a,b,c){if(null!=b.U&&(a=fy(a,b.U,b.type))){var d=b.Ja&a.wa;if(!a.Oc){if(d>>>0>=a.Nb)return!1}else if(d>>>0f?null!=h?(g=Px(a,b,void 0),f=null):(f=Px(a,b,void 0),null==f&&(g=null)):(h=Px(a,b.substring(0,f),void 0),g=Px(a,b.substring(f+1),void 0),f=null)}null!=g&&(e=Xx(a,g,h,f,c),d||Dy(a,e,!0)||(a.P("invalid offset: "+uy(e)),e=null));return e}function Hy(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.sl=a.Cg(b.Yk=c[2]))}l.Pk=function(a,b){var c=Ey(this,b);return a.replace("["+b+"]",c?q(this.hb(c),c.Hb?8:4):"undefined")}; -function zy(a,b,c){c=c||1;null!=b.xa&&(b.xa+=c);null!=b.U&&(b.Ja+=c,Dy(a,b)||(b.Ja=0,b.xa=null))}function jy(a,b,c){return null!=b?q(b,4)+":"+q(a,a&-65536||c?8:4):q(a)}function uy(a){var b;switch(a.type){case xy:case Iy:b="&";break;case gy:b="#";break;case Gy:b="%";break;case yy:b="%%";break;default:b=a.U?"":"%"}return a.type>=Gy||null==a.U?b+q(a.xa):b+jy(a.Ja,a.U,a.dc)} -function ky(a,b,c){var d="";for(c=c||256;d.length>>a.H.qb;g=1}a.P("blockid "+(d?"linear ":"physical")+" blockaddr used size type");a.P("-------- --------- ---------- ------ ------ ----");c=-1;for(var h=0;g--;)(d=b[f])&&d.type==Uc&&(d=gd(a.H,e,!1,!0)),d.type==c?h++||a.P("..."):(c=d.type,h=kc[c],c==Wc&&(d=d.pd,h+=" -> "+kc[d.type]),d&&a.P(q(d.id,8)+" %"+q(f<c&&(c=ya(Ky,a.substr(b,2))));return c}; -function Ly(a,b){var c=0,d=a.hh(b);if(null!=d)switch(b){case My:case Ny:case Oy:case Py:case Qy:case Ry:case Sy:case Ty:c=2;break;case Uy:case Vy:case Wy:case Xy:case Yy:case Zy:case $y:case az:case bz:case cz+dz:case cz+ez:case cz+fz:case cz+gz:case cz+hz:case cz+iz:c=4;break;case jz:case kz:case lz:case mz:case nz:case oz:case pz:case qz:case rz:case sz:case tz:case uz:case vz:c=8;break;case wz:c=a.oa}return c?q(d,c):"??"} -l.hh=function(a){var b;if(0<=a){var c=this.H;switch(a){case My:b=c.D&255;break;case Ny:b=c.I&255;break;case Oy:b=c.L&255;break;case Py:b=c.G&255;break;case Qy:b=c.D>>8&255;break;case Ry:b=c.I>>8&255;break;case Sy:b=c.L>>8&255;break;case Ty:b=c.G>>8&255;break;case Uy:b=c.D&65535;break;case Vy:b=c.I&65535;break;case Wy:b=c.L&65535;break;case Xy:b=c.G&65535;break;case Yy:b=z(c)&65535;break;case Zy:b=c.M&65535;break;case $y:b=c.K&65535;break;case az:b=c.J&65535;break;case bz:b=A(c)&65535;break;case wz:b= -ie(c);break;case cz+dz:b=c.oa.U;break;case cz+ez:b=c.Z.U;break;case cz+fz:b=c.Y.U;break;case cz+gz:b=c.Ca.U;break;default:if(80286==this.H.ca)a==rz&&(b=c.qa);else if(80386<=this.H.ca)switch(a){case jz:b=c.D;break;case kz:b=c.I;break;case lz:b=c.L;break;case mz:b=c.G;break;case nz:b=z(c);break;case oz:b=c.M;break;case pz:b=c.K;break;case qz:b=c.J;break;case rz:b=c.qa;break;case sz:b=c.Og;break;case tz:b=c.Cd;break;case uz:b=c.Wc;break;case cz+hz:b=c.Ga.U;break;case cz+iz:b=c.Ha.U;break;case vz:b=A(c)}}}return b}; -function xz(a,b){b=Qx(a,b);for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.gh(b,c+1),0<=e&&(b=b.substr(0,c)+Ly(a,e)+b.substr(c+1+Ky[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=ga(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=Ey(a,e))?(d=e+' "'+ky(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=Ey(a,e))?(zy(a,d),d= -e+' "'+ky(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+uy(Xx(this,A(this.H),this.H.Z.U))+" (%"+q(this.H.da)+")");this.va&&a==this.va||(this.va=a,this.ic&-2147483648&&(this.Jb(),a+=" (cpu halted)"),this.P(a),this.H&&(a=this.H,a.zc-=a.A,a.A=0,a.T.Ve=0,td(a)))}; -function Nk(a,b,c,d){var e,f;if(!d&&(d=t(a,1)&&0>yz.indexOf(b),!d)){var g=zz[b];g&&(d=t(a,g)?!0:524288==g&&t(a,g=1048576))}d&&(e=a.H.D>>8&255,f=a.H.L&255,33==b&&11==e||524288==g&&128<=f||1048576==g&&128>f)&&(d=!1);d&&((g=(g=Ib[b])&&g[e]||"")&&(g=" "+xz(a,g)),a.message("INT "+r(b)+": AH="+r(e)+" at "+jy(c-2-a.H.Z.ua,a.H.Z.U)+g));return d} -function Db(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.ic&h)==h)h=null,null!=e&&(h=a.H.Z.U,e-=a.H.Z.ua),a.message(b.be+"."+(null!=d?"outPort":"inPort")+"("+ka(c)+","+(f?f:"unknown")+(null!=d?","+r(d):"")+")"+(null!=g?": "+r(g):"")+(null!=e?" at "+jy(e,h):""))}l.ih=function(){this.P("Type ? for help with PCx86 Debugger commands");Az(this);if(this.Ca){var a=this.Ca;this.Ca=null;ay(this,a)}}; -function Zx(a,b){var c;if(Ag(a)){if(!a.N||!a.N.length){a.N=Array(Bz);for(c=0;c>>f.qb].Gd(e&f.Db,a==this.M);g&&jc(f)}}d&&(a.push(b),c?(null!=b.xa&&(b.U=null),b.Jd=!0):(Iz(this,a,a.length-1,"set"),Zx(this)));return d}; -function ty(a,b,c,d,e){for(var f=!1,g=Jz(a,a.Sb(c)),h=1;h>3&7,F=(3>(g>>6&3)?0:48)+u;(217==f||219==f)&&52<=F&&(F=u<<4|g&7);(u=Rz[f])&&(w=u[F]);w&&(p=Sz,k=w,m=k[0])}m>=p.length&&(g=a.Ia(b,1),k=Tz[m-p.length][g>>3&7],m=k[0]);p=p[m];u=k.length-1;w="";b.Hb&&(m==Uz? -p="CWDE":m==Vz?p="CDQ":m>=Wz&&m<=Xz&&(p+="D"));if(164<=f&&167>=f||170<=f&&175>=f)u=0,b.Hb&&"W"==p.slice(-1)&&(p=p.slice(0,-1)+"D");for(var f=-1,F=!0,K=1;K<=u;K++){var H,I;H="";I=k[K];if(void 0!==I){0>f&&(f=I>>Yz);m==Zz&&(f==$z?w="[%800]":f==aA&&(w="ES:["+(b.dc?"E":"")+"DI]"));var T=I&bA;if(T!=cA)if(T==dA)F=!1;else{var L=I&eA;if(L>=R)if(0>g&&(g=a.Ia(b,1)),L>6,za=g&7;if(3>xb){T=!p.indexOf("FI");if(!xb&&(!I.dc&&6==za||I.dc&&5==za))xb=2;else{if(I.dc)if(4!=za)za+= -8;else{var ca=L,cb=xb,Sa=I,rb=ca.Ia(Sa,1),db=rb>>6,rc=rb>>3&7,rb=rb&7,ib="";if(cb||5!=rb)ib=gA[rb+8];4!=rc&&(ib&&(ib+="+"),ib+=gA[rc+8],db&&(ib+="*"+(1<>24),2)):ca+("+"+q(L,2))):2==xb&&(ca&&(ca+="+"),I.dc?(L=qy(L,I,4),ca+=q(L)):(L=L.Yc(I,2),ca+=q(L,4)));ca="["+ca+"]";if(1==ua){L="";H&=bA;H==S&&(H=I.Hb?hA:U);switch(H){case iA:L="FAR";break;case V:L="BYTE";break;case U:if(T){L="INT16"; -break}L="WORD";break;case hA:L="DWORD";break;case jA:if(T){L="INT32";break}case kA:L="REAL32";break;case lA:if(T){L="INT64";break}case mA:L="REAL64";break;case nA:L="REAL80";break;case oA:L="BCD80"}L&&(ca=L+" "+ca)}}else ca=pA(L,za,H,I);H=ca}else H=L==fA?pA(a,g&7,I,b):pA(a,g>>3&7,I,b);else if(L==qA)H="1";else if(L==W){H=a;T=I;L=b;I=" ";switch(T&bA){case V:T&X&&(I=q(H.Ia(L,1),2));break;case rA:I=q(H.Ia(L,1)<<24>>24,L.Hb?8:4);break;case S:if(L.Hb){I=q(qy(H,L,4));break}case U:I=q(H.Yc(L,2),4);break; -case iA:L=Xx(H,H.hb(L,!0),H.Yc(L,2),null,L.type,L.Hb,L.dc);I=uy(L);H=sA(H,L);H[0]&&(I+=" ("+H[0]+")");break;default:I="imm("+ka(T)+")"}H=I}else L==tA?(b.dc?(H=8,I=qy(a,b,4)):(H=4,I=a.Yc(b,2)),H="["+q(I,H)+"]"):L==uA?(H=T==V?a.Ia(b,1)<<24>>24:a.hb(b,!0),I=b.Ja+H&(b.Hb?-1:65535),H=q(I,b.Hb?8:4),I=sA(a,Xx(a,I,b.U)),I[0]&&(H+=" ("+I[0]+")")):L==Y?H=T==vA?"ST":T==wA?"ST("+(g&7)+")":pA(a,(I&xA)>>8,I,b):L==yA?H=pA(a,(I&xA)>>8,zA,b):L==AA?H="DS:[SI]":L==BA&&(H="ES:[DI]");if(!H||!H.length){w="INVALID";break}0< -w.length&&(w+=",");w+=H||"???"}}}g="";k=uy(e)+" ";if(-1!==e.xa&&-1!==b.xa){do if(g+=q(a.Ia(e,1),2),null==e.xa)break;while(e.xa!=b.xa)}k+=qa(g,e.dc?24:16);k+=qa(p,8);w&&(k+=" "+w);a.H.caiz||b>=hz&&80386>a.H.ca)return"??";b+=cz}else if(e==EA)b+=rz;else if(e==FA)b+=GA;else if(e==HA)b+=IA;else if(a=c&bA,a>=U&&(b=Uy&&b<=az&&4a.H.ca&&(d="\n"+d,c+=e,e="");c+="\n"+LA(a,a.H.Z,b)+" ";80386<=a.H.ca&&(e+="\n",c+=LA(a,a.H.Ga,b)+" "+LA(a,a.H.Ha,b)+"\n");c+=MA(a,"LD",a.H.Eb.U,a.H.Eb.ua,a.H.Eb.ua+a.H.Eb.Ka)+" "+MA(a,"GD",null,a.H.Kb,a.H.Pc)+" "+MA(a,"ID", -null,a.H.Pb,a.H.cd)+" ";c=c+(d+" "+e)+KA(a,rz);80386<=a.H.ca&&(c+=KA(a,tz)+KA(a,uz))}else 80386<=a.H.ca&&(c+=LA(a,a.H.Ga,b)+" "+LA(a,a.H.Ha,b)+" ");return c+=KA(a,wz)+JA(a,"V")+JA(a,"D")+JA(a,"I")+JA(a,"T")+JA(a,"S")+JA(a,"Z")+JA(a,"A")+JA(a,"P")+JA(a,"C")}l.gj=function(a,b){return a[0]>b[0]?1:a[0]>>0,p],H=ta(F,u,a.gj);0>H&&F.splice(-(H+1),0,u)}K&&(w.a=K.replace(/''/g,'"'))}a.D.push({Rf:b,pn:c,U:d,Ja:e,xa:f,en:g,Fd:h,Pi:m})} -function sy(a,b,c){for(var d=0;d>>0,f=a.Sb(b)>>>0,g=0;g>>0,p=h.xa;null!=p&&(p>>>=0);var w=h.en;48==k&&(k=40);if(k==b.U&&e>=m&&e=p&&fc?(a.P("out of data at address "+uy(b)),p=!0):(a.fc(b,c,1,!0),m++)})})(a,g);td(a.H, +function Yx(a,b,c){var d;if(b){b=Zx(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function dy(a,b){if(b)return by(a,b,a.da[b]);var c=0;for(b in a.da)by(a,b,a.da[b]),c++;return 0>2:0)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c}var ay={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function ey(a){Wx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=fy(this);this.Ga=fy(this);this.Z=fy(this);this.D=[];this.B=this.Y=this.M=[];gy(this);this.ta=0;hy(this);this.za={};iy(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return jy(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return jy(b,a)})}ba(ey,Wx);l=ey.prototype; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Xb(a,"FDC");this.Ha=Xb(a,"HDC");this.Tc=Xb(a,"FPU");this.G=Xb(a,"Mouse");(a=zd(a,"messages"))&&iy(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Vd(this.H,7,"DBG");this.ma=ky;80186<=this.H.ca&&(this.ma=ky.slice(),this.ma[15]=ly,80286<=this.H.ca&&(this.ma[15]=my,80386<=this.H.ca&&(this.oa=8)));Al(this,64,function(a){ny(d,d.H.sc,a[0])});Al(this,4,function(a){if(a=a[0]){var b=$x(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=oy(d, +b,py),d.P("dumpSel("+ta(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=qy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ta(a.ua&65535)+" off="+ta(a.Ka):"base="+q(a.ua,d.ha)+" limit="+ry(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ta(a.ext&-65296)+ +" dpl="+r(a.qc))}}else d.P("no selector")});Al(this,134217728,function(a){var b;(a=a[0])&&(b=$x(d,a));if(void 0===b)d.P("invalid MCB");else for(d.P("dumpMCB("+ta(b)+")");b;){a=fy(d,0,b);var c=d.Ia(a,1),e=d.Yc(a,2),k=d.Yc(a,5);if(77!=c&&90!=c)break;d.P(sy(0,b)+": '"+String.fromCharCode(c)+"' PID="+ta(e)+" LEN="+ta(k)+' "'+ty(d,a,8)+'"');b+=1+k}});Al(this,128,function(a){ny(d,d.H.aa,a[0],d.H.aa!==d.H.sc)});Al(this,8,function(a){a:{if(a=a[0]){var b=$x(d,a);if(void 0===b){d.P("invalid task selector: "+ +a);break a}a=oy(d,b,py)}else a=d.H.la;d.P("dumpTSS("+ta(a?a.U:b)+"): %"+q(a?a.ua:null,d.ha));if(a){var b="",c=a.type&-513,e=256==c?4:8,k=256==c?uy:vy,m,p,w,u;for(u in k)m=k[u],p=a.ua+m,w=yg(d.H,p,2),2304==c&&(w|=yg(d.H,p+2,2)<<16),b&&(b+="\n"),b+=ta(m)+" "+Ba(u+":",11)+q(w,e);if(2304==c)for(u=0,m=w>>>16;mu;)p=a.ua+m,w=yg(d.H,p,2),b+="\n"+ta(m)+" ports "+ta(u)+"-"+ta(u+15)+": "+ra(w,2),u+=16,m+=2;d.P(b)}}});this.F=null;this.Da=0;this.Aa=!1;Sf(this.H,48,this.Ym.bind(this));Sf(this.H,65, +this.Zm.bind(this));this.O=null;Sf(this.H,104,this.$m.bind(this));Jb(this)};function wy(a,b,c,d,e,f){b=ty(a,b);var g=oy(a,d),g=g?g.Ka+1:0,h=(e?"_CODE":"_DATA")+q(c,2);f&&t(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=xy(a,b,c);e[b+h]=0;aq(a,b,c,d,0,null,g,e)} +function yy(a,b,c,d){var e=a.Yc(b,2),f=a.Yc(b,2),g=zy(a,b,4),h=zy(a,b,4),k=fy(a,zy(a,b,4),a.Yc(b,2));b=fy(a,zy(a,b,4),a.Yc(b,2));b=ty(a,b).toUpperCase();var k=ty(a,k).toUpperCase(),m=(c?"_CODE":"_DATA")+q(e,2);d&&t(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+q(e,4)+")="+q(f,4)+":"+q(g)+" len "+q(h));c=xy(a,k,e);c[k+m]=g;aq(a,k,e,f,g,null,h,c)}function Ay(a,b,c){c=ty(a,c).toUpperCase();By(a,c,b)} +l.Ym=function(){var a=this.H;if(null!=this.F&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=fy(this,z(a)+12,a.Y.U);switch(zy(this,d)){case 336:yy(this,fy(this,a.G,b),!c,!!this.F)}}return!0}; +l.Zm=function(a){var b=this.H,c=b.D&65535,d=b.G&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.oa.U;if(null==this.F)return 79==c&&Tf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Mb(a,"INT 0x41 handling enabled",128),a.F=!0):(Mb(a,"INT 0x41 monitoring enabled",128),a.F=!1)}}(this)),!0;switch(c){case 79:this.F&&(b.D=b.D&-65536|62342,Mb(this,"INT 0x41 handling enabled",128));break;case 80:wy(this,fy(this,h,k),d+1,e,!(g&1),!!this.F);break;case 82:By(this,null, +d);break;case 127:this.F&&(b.D=b.D&-65536|(this.Aa?0:1));break;case 131:this.F&&(a=fy(this,b.L,e),this.Da++?(this.P("TRAPFAULT failed"),Cy(this,this.B,a,!0,!0),this.Da=0,this.Jb()):(this.P("INT 0x41 TRAPFAULT: fault="+ta(d)+" error="+q(b.K,8,!0)+" addr="+Dy(a)),this.Gd(this.B,a,!0),hy(this,!0)));break;case 141:this.F&&(b.D=b.D&-65536|1);break;case 336:yy(this,fy(this,b.G,f),!g,!!this.F);break;case 338:Ay(this,d,fy(this,b.J,f))}this.Aa=!1;return!this.F}; +l.$m=function(a){var b=this.H,c=b.D&255,d=b.D>>8&255,e=b.G&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.oa.U;if(null==this.O){if(67==d){if(609437257==b.ia((b.Z.U<<4)+10)||1111835735==b.ia((b.Z.U<<4)+95))return!0;Tf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Mb(a,"INT 0x68 handling enabled",128),a.F=a.O=!0):(Mb(a,"INT 0x68 monitoring enabled",128),a.O=!1)}}(this))}return!0}switch(d){case 67:this.O&&(b.D=b.D&-65536|62342);break;case 68:this.O&&(a=Xd(b.Z,this.yl.bind(this)))&& +(b.J=a[0],oe(b,a[1]));break;case 72:By(this,null,e);break;case 80:32==c?wy(this,fy(this,h,k),0,f,!0,!!this.O):128>c?wy(this,fy(this,h,k),e+1,c&64?g:f,!(c&1),!!this.O):yy(this,fy(this,h,k),!(c&1),!!this.O),this.O&&(b.D=b.D&-256|1)}return!this.O};l.yl=function(){var a=this.H;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; +l.Cb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.qa=this.na[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",jy(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.A>>0)+1;a.jb=f;a.type=g;a.ext=k;a.Lb=d;Wd(a,!0,!0,!1)}}return a}l.Sb=function(a,b,c){var d=a&&a.xa;if(null==d&&(d=-1,a)){var e=oy(this,a.U,a.type);e&&(b=a.Ja||0,c=c||1,d=e=-1===e.Lb||e.Oc&&(b>>>0)+c>e.Nb||!e.Oc&&(b>>>0)+c<=e.Nb?e.ua+b|0:-1,a.xa=d)}return d};l.Ia=function(a,b){var c=255,d=this.Sb(a,!1,1);-1!==d&&(c=yg(this.H,d,1,a.type==Hy)|0,b&&Iy(this,a,b));return c}; +l.hb=function(a,b){return a.Hb?zy(this,a,b?4:0):this.Yc(a,b?2:0)};l.Yc=function(a,b){var c=65535,d=this.Sb(a,!1,2);-1!==d&&(c=yg(this.H,d,2,a.type==Hy)|0,b&&Iy(this,a,b));return c};function zy(a,b,c){var d=-1,e=a.Sb(b,!1,4);-1!==e&&(d=yg(a.H,e,4,b.type==Hy)|0,c&&Iy(a,b,c));return d}l.fc=function(a,b,c,d){var e=this.Sb(a,!0,1);if(-1!==e){if(a.type!=Hy)this.H.fc(e,b);else{var f=this.ka;f.aa[(e&f.C)>>>f.A].bf(e&f.D,b&255,e)}c&&Iy(this,a,c);d||Cd(this.H,!0)}}; +l.il=function(a,b,c){var d=this.Sb(a,!0,2);-1!==d&&(a.type!=Hy?this.H.fb(d,b):Kc(this.ka,d,b),c&&Iy(this,a,c),Cd(this.H,!0))};function fy(a,b,c,d,e,f,g){return Jy(a,{},b,c,d,e,f,g)}function Jy(a,b,c,d,e,f,g,h){b.Ja=c||0;b.U=d;b.xa=e;b.type=f||(Fy(a)?py:Gy);b.Hb=null!=g?g:!(!a.H||4!=a.H.Z.V);b.dc=null!=h?h:!(!a.H||4!=a.H.Z.Jc);b.Jd=!1;return b}function Ky(a){return[a.Ja,a.U,a.xa,a.Jd,a.Hb,a.dc,a.Fe,a.bh]}function Ly(a){return{Ja:a[0],U:a[1],xa:a[2],Jd:a[3],Hb:a[4],dc:a[5],Fe:a[6],bh:a[7]}} +function My(a,b,c){if(null!=b.U&&(a=oy(a,b.U,b.type))){var d=b.Ja&a.wa;if(!a.Oc){if(d>>>0>=a.Nb)return!1}else if(d>>>0f?null!=h?(g=Yx(a,b,void 0),f=null):(f=Yx(a,b,void 0),null==f&&(g=null)):(h=Yx(a,b.substring(0,f),void 0),g=Yx(a,b.substring(f+1),void 0),f=null)}null!=g&&(e=fy(a,g,h,f,c),d||My(a,e,!0)||(a.P("invalid offset: "+Dy(e)),e=null));return e}function Qy(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.sl=a.Cg(b.Yk=c[2]))}l.Pk=function(a,b){var c=Ny(this,b);return a.replace("["+b+"]",c?q(this.hb(c),c.Hb?8:4):"undefined")}; +function Iy(a,b,c){c=c||1;null!=b.xa&&(b.xa+=c);null!=b.U&&(b.Ja+=c,My(a,b)||(b.Ja=0,b.xa=null))}function sy(a,b,c){return null!=b?q(b,4)+":"+q(a,a&-65536||c?8:4):q(a)}function Dy(a){var b;switch(a.type){case Gy:case Ry:b="&";break;case py:b="#";break;case Py:b="%";break;case Hy:b="%%";break;default:b=a.U?"":"%"}return a.type>=Py||null==a.U?b+q(a.xa):b+sy(a.Ja,a.U,a.dc)} +function ty(a,b,c){var d="";for(c=c||256;d.length>>a.H.qb;g=1}a.P("blockid "+(d?"linear ":"physical")+" blockaddr used size type");a.P("-------- --------- ---------- ------ ------ ----");c=-1;for(var h=0;g--;)(d=b[f])&&d.type==cd&&(d=td(a.H,e,!1,!0)),d.type==c?h++||a.P("..."):(c=d.type,h=vc[c],c==ed&&(d=d.pd,h+=" -> "+vc[d.type]),d&&a.P(q(d.id,8)+" %"+q(f<c&&(c=Ia(Ty,a.substr(b,2))));return c}; +function Uy(a,b){var c=0,d=a.hh(b);if(null!=d)switch(b){case Vy:case Wy:case Xy:case Yy:case Zy:case $y:case az:case bz:c=2;break;case cz:case dz:case ez:case fz:case gz:case hz:case iz:case jz:case kz:case lz+mz:case lz+nz:case lz+oz:case lz+pz:case lz+qz:case lz+rz:c=4;break;case sz:case tz:case uz:case vz:case wz:case xz:case yz:case zz:case Az:case Bz:case Cz:case Dz:case Ez:c=8;break;case Fz:c=a.oa}return c?q(d,c):"??"} +l.hh=function(a){var b;if(0<=a){var c=this.H;switch(a){case Vy:b=c.D&255;break;case Wy:b=c.I&255;break;case Xy:b=c.L&255;break;case Yy:b=c.G&255;break;case Zy:b=c.D>>8&255;break;case $y:b=c.I>>8&255;break;case az:b=c.L>>8&255;break;case bz:b=c.G>>8&255;break;case cz:b=c.D&65535;break;case dz:b=c.I&65535;break;case ez:b=c.L&65535;break;case fz:b=c.G&65535;break;case gz:b=z(c)&65535;break;case hz:b=c.M&65535;break;case iz:b=c.K&65535;break;case jz:b=c.J&65535;break;case kz:b=A(c)&65535;break;case Fz:b= +re(c);break;case lz+mz:b=c.oa.U;break;case lz+nz:b=c.Z.U;break;case lz+oz:b=c.Y.U;break;case lz+pz:b=c.Ca.U;break;default:if(80286==this.H.ca)a==Az&&(b=c.qa);else if(80386<=this.H.ca)switch(a){case sz:b=c.D;break;case tz:b=c.I;break;case uz:b=c.L;break;case vz:b=c.G;break;case wz:b=z(c);break;case xz:b=c.M;break;case yz:b=c.K;break;case zz:b=c.J;break;case Az:b=c.qa;break;case Bz:b=c.Og;break;case Cz:b=c.Cd;break;case Dz:b=c.Wc;break;case lz+qz:b=c.Ga.U;break;case lz+rz:b=c.Ha.U;break;case Ez:b=A(c)}}}return b}; +function Gz(a,b){b=Zx(a,b);for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.gh(b,c+1),0<=e&&(b=b.substr(0,c)+Uy(a,e)+b.substr(c+1+Ty[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=oa(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=Ny(a,e))?(d=e+' "'+ty(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=Ny(a,e))?(Iy(a,d),d= +e+' "'+ty(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+Dy(fy(this,A(this.H),this.H.Z.U))+" (%"+q(this.H.da)+")");this.va&&a==this.va||(this.va=a,this.ic&-2147483648&&(this.Jb(),a+=" (cpu halted)"),this.P(a),this.H&&(a=this.H,a.zc-=a.A,a.A=0,a.T.Ve=0,Cd(a)))}; +function Wk(a,b,c,d){var e,f;if(!d&&(d=t(a,1)&&0>Hz.indexOf(b),!d)){var g=Iz[b];g&&(d=t(a,g)?!0:524288==g&&t(a,g=1048576))}d&&(e=a.H.D>>8&255,f=a.H.L&255,33==b&&11==e||524288==g&&128<=f||1048576==g&&128>f)&&(d=!1);d&&((g=(g=Rb[b])&&g[e]||"")&&(g=" "+Gz(a,g)),a.message("INT "+r(b)+": AH="+r(e)+" at "+sy(c-2-a.H.Z.ua,a.H.Z.U)+g));return d} +function Nb(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.ic&h)==h)h=null,null!=e&&(h=a.H.Z.U,e-=a.H.Z.ua),a.message(b.be+"."+(null!=d?"outPort":"inPort")+"("+ta(c)+","+(f?f:"unknown")+(null!=d?","+r(d):"")+")"+(null!=g?": "+r(g):"")+(null!=e?" at "+sy(e,h):""))}l.ih=function(){this.P("Type ? for help with PCx86 Debugger commands");Jz(this);if(this.Ca){var a=this.Ca;this.Ca=null;jy(this,a)}}; +function hy(a,b){var c;if(Jg(a)){if(!a.N||!a.N.length){a.N=Array(Kz);for(c=0;c>>f.qb].Gd(e&f.Db,a==this.M);g&&tc(f)}}d&&(a.push(b),c?(null!=b.xa&&(b.U=null),b.Jd=!0):(Rz(this,a,a.length-1,"set"),hy(this)));return d}; +function Cy(a,b,c,d,e){for(var f=!1,g=Sz(a,a.Sb(c)),h=1;h>3&7,F=(3>(g>>6&3)?0:48)+u;(217==f||219==f)&&52<=F&&(F=u<<4|g&7);(u=$z[f])&&(w=u[F]);w&&(p=aA,k=w,m=k[0])}m>=p.length&&(g=a.Ia(b,1),k=bA[m-p.length][g>>3&7],m=k[0]);p=p[m];u=k.length-1;w="";b.Hb&&(m==cA? +p="CWDE":m==dA?p="CDQ":m>=eA&&m<=fA&&(p+="D"));if(164<=f&&167>=f||170<=f&&175>=f)u=0,b.Hb&&"W"==p.slice(-1)&&(p=p.slice(0,-1)+"D");for(var f=-1,F=!0,K=1;K<=u;K++){var H,I;H="";I=k[K];if(void 0!==I){0>f&&(f=I>>gA);m==hA&&(f==iA?w="[%800]":f==jA&&(w="ES:["+(b.dc?"E":"")+"DI]"));var T=I&kA;if(T!=lA)if(T==mA)F=!1;else{var L=I&nA;if(L>=R)if(0>g&&(g=a.Ia(b,1)),L>6,za=g&7;if(3>xb){T=!p.indexOf("FI");if(!xb&&(!I.dc&&6==za||I.dc&&5==za))xb=2;else{if(I.dc)if(4!=za)za+= +8;else{var ca=L,cb=xb,Sa=I,rb=ca.Ia(Sa,1),db=rb>>6,rc=rb>>3&7,rb=rb&7,ib="";if(cb||5!=rb)ib=pA[rb+8];4!=rc&&(ib&&(ib+="+"),ib+=pA[rc+8],db&&(ib+="*"+(1<>24),2)):ca+("+"+q(L,2))):2==xb&&(ca&&(ca+="+"),I.dc?(L=zy(L,I,4),ca+=q(L)):(L=L.Yc(I,2),ca+=q(L,4)));ca="["+ca+"]";if(1==ua){L="";H&=kA;H==S&&(H=I.Hb?qA:U);switch(H){case rA:L="FAR";break;case V:L="BYTE";break;case U:if(T){L="INT16"; +break}L="WORD";break;case qA:L="DWORD";break;case sA:if(T){L="INT32";break}case tA:L="REAL32";break;case uA:if(T){L="INT64";break}case vA:L="REAL64";break;case wA:L="REAL80";break;case xA:L="BCD80"}L&&(ca=L+" "+ca)}}else ca=yA(L,za,H,I);H=ca}else H=L==oA?yA(a,g&7,I,b):yA(a,g>>3&7,I,b);else if(L==zA)H="1";else if(L==W){H=a;T=I;L=b;I=" ";switch(T&kA){case V:T&X&&(I=q(H.Ia(L,1),2));break;case AA:I=q(H.Ia(L,1)<<24>>24,L.Hb?8:4);break;case S:if(L.Hb){I=q(zy(H,L,4));break}case U:I=q(H.Yc(L,2),4);break; +case rA:L=fy(H,H.hb(L,!0),H.Yc(L,2),null,L.type,L.Hb,L.dc);I=Dy(L);H=BA(H,L);H[0]&&(I+=" ("+H[0]+")");break;default:I="imm("+ta(T)+")"}H=I}else L==CA?(b.dc?(H=8,I=zy(a,b,4)):(H=4,I=a.Yc(b,2)),H="["+q(I,H)+"]"):L==DA?(H=T==V?a.Ia(b,1)<<24>>24:a.hb(b,!0),I=b.Ja+H&(b.Hb?-1:65535),H=q(I,b.Hb?8:4),I=BA(a,fy(a,I,b.U)),I[0]&&(H+=" ("+I[0]+")")):L==Y?H=T==EA?"ST":T==FA?"ST("+(g&7)+")":yA(a,(I&GA)>>8,I,b):L==HA?H=yA(a,(I&GA)>>8,IA,b):L==JA?H="DS:[SI]":L==KA&&(H="ES:[DI]");if(!H||!H.length){w="INVALID";break}0< +w.length&&(w+=",");w+=H||"???"}}}g="";k=Dy(e)+" ";if(-1!==e.xa&&-1!==b.xa){do if(g+=q(a.Ia(e,1),2),null==e.xa)break;while(e.xa!=b.xa)}k+=Ba(g,e.dc?24:16);k+=Ba(p,8);w&&(k+=" "+w);a.H.carz||b>=qz&&80386>a.H.ca)return"??";b+=lz}else if(e==NA)b+=Az;else if(e==OA)b+=PA;else if(e==QA)b+=RA;else if(a=c&kA,a>=U&&(b=cz&&b<=jz&&4a.H.ca&&(d="\n"+d,c+=e,e="");c+="\n"+UA(a,a.H.Z,b)+" ";80386<=a.H.ca&&(e+="\n",c+=UA(a,a.H.Ga,b)+" "+UA(a,a.H.Ha,b)+"\n");c+=VA(a,"LD",a.H.Eb.U,a.H.Eb.ua,a.H.Eb.ua+a.H.Eb.Ka)+" "+VA(a,"GD",null,a.H.Kb,a.H.Pc)+" "+VA(a,"ID", +null,a.H.Pb,a.H.cd)+" ";c=c+(d+" "+e)+TA(a,Az);80386<=a.H.ca&&(c+=TA(a,Cz)+TA(a,Dz))}else 80386<=a.H.ca&&(c+=UA(a,a.H.Ga,b)+" "+UA(a,a.H.Ha,b)+" ");return c+=TA(a,Fz)+SA(a,"V")+SA(a,"D")+SA(a,"I")+SA(a,"T")+SA(a,"S")+SA(a,"Z")+SA(a,"A")+SA(a,"P")+SA(a,"C")}l.gj=function(a,b){return a[0]>b[0]?1:a[0]>>0,p],H=Ea(F,u,a.gj);0>H&&F.splice(-(H+1),0,u)}K&&(w.a=K.replace(/''/g,'"'))}a.D.push({Rf:b,pn:c,U:d,Ja:e,xa:f,en:g,Fd:h,Pi:m})} +function By(a,b,c){for(var d=0;d>>0,f=a.Sb(b)>>>0,g=0;g>>0,p=h.xa;null!=p&&(p>>>=0);var w=h.en;48==k&&(k=40);if(k==b.U&&e>=m&&e=p&&fc?(a.P("out of data at address "+Dy(b)),p=!0):(a.fc(b,c,1,!0),m++)})})(a,g);Cd(a.H, !0);a.P(m+" bytes read at "+b)}else a.P("sector "+e+" request out of range");else a.P("drive "+d+" not loaded");else a.P("invalid drive: "+d)}else a.P("disk controller not present")}}else a.P("load commands:"),a.P("\tl [address] [drive #] [sector #] [# sectors]")} -function Ez(a,b){var c;if(b&&"?"==b[1])a.P("register commands:"),a.P("\tr\tdump registers"),a.Tc&&a.P("\trfp\tdump floating-point registers"),a.P("\trp\tdump all registers"),a.P("\trx [#]\tset flag or register x to [#]");else{var d;null==c&&(c=!0);if(b&&1f;f++){var g=c,e=null;if(f=a.oa&&(h=null);switch(h){case "AL":a.H.D= -a.H.D&-256|g&255;break;case "AH":a.H.D=a.H.D&-65281|g<<8&255;break;case "AX":a.H.D=a.H.D&-65536|g&65535;break;case "BL":a.H.G=a.H.G&-256|g&255;break;case "BH":a.H.G=a.H.G&-65281|g<<8&255;break;case "BX":a.H.G=a.H.G&-65536|g&65535;break;case "CL":a.H.I=a.H.I&-256|g&255;break;case "CH":a.H.I=a.H.I&-65281|g<<8&255;break;case "CX":a.H.I=a.H.I&-65536|g&65535;break;case "DL":a.H.L=a.H.L&-256|g&255;break;case "DH":a.H.L=a.H.L&-65281|g<<8&255;break;case "DX":a.H.L=a.H.L&-65536|g&65535;break;case "SP":Zd(a.H, -z(a.H)&-65536|g&65535);break;case "BP":a.H.M=a.H.M&-65536|g&65535;break;case "SI":a.H.K=a.H.K&-65536|g&65535;break;case "DI":a.H.J=a.H.J&-65536|g&65535;break;case "DS":ee(a.H,g);break;case "ES":fe(a.H,g);break;case "SS":Yd(a.H,g);break;case "CS":Qf(a.H,g);a.K=Xx(a,A(a.H),a.H.Z.U);break;case "IP":case "EIP":C(a.H,g);a.K=Xx(a,A(a.H),a.H.Z.U);break;case "PC":case "PS":je(a.H,g);break;case "C":g?bg(a.H):cg(a.H);break;case "P":g?(e=a.H,e.resultType&=-3,e.O|=4):(e=a.H,e.resultType&=-3,e.O&=-5);break;case "A":g? -jg(a.H):hg(a.H);break;case "Z":g?kg(a.H):ig(a.H);break;case "S":g?(e=a.H,e.resultType&=-17,e.O|=128):(e=a.H,e.resultType&=-17,e.O&=-129);break;case "I":g?(e=a.H,e.O|=512):(e=a.H,e.O&=-513);break;case "D":g?(e=a.H,e.O|=1024):(e=a.H,e.O&=-1025);break;case "V":g?dg(a.H):eg(a.H);break;default:var k=!0;if(80286<=a.H.ca)switch(k=!1,h){case "MS":lg(a.H,g);break;case "TR":-1===a.H.la.load(g)&&(f=!1);break;default:if(k=!0,80386<=a.H.ca)switch(k=!1,h){case "EAX":a.H.D=g;break;case "EBX":a.H.G=g;break;case "ECX":a.H.I= -g;break;case "EDX":a.H.L=g;break;case "ESP":Zd(a.H,g);break;case "EBP":a.H.M=g;break;case "ESI":a.H.K=g;break;case "EDI":a.H.J=g;break;case "FS":a.H.Ga.load(g);break;case "GS":a.H.Ha.load(g);break;case "CR0":a.H.qa=g;Sj.call(a.H,g);break;case "CR2":a.H.Cd=g;break;case "CR3":a.H.Wc=g;le.call(a.H,g);break;default:k=!0}}if(k){a.P("unknown register: "+e);return}}if(!f){a.P("invalid value: "+b);return}td(a.H);a.P("updated registers:")}}a.P(NA(a,d));c&&(a.K=Xx(a,A(a.H),a.H.Z.U),Fz(a,uy(a.K)))}} -function VA(a,b){b=ra(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.P(xz(a,c[2])):Px(a,b,!0)}function WA(a,b,c){for(var d=null,e=b.Ja,f=e,g=1;6>=g&&e;g++){if(2h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.P(m)}h[3]&&(g=h[3],f=null);f=Mz(a,b,g,f);b.bh||d||d++;a.P(f);a.K=b;e-=b.xa-k;c++}}} -l.Cg=function(a,b,c){if(b)if(a){0>this.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else a=this.C[this.A+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(ra(a.substring(d,f))),d=f+1}}return b}; -function Lz(a,b,c){var d=!0;try{if(!b.length||"end"==b)a.aa&&(a.P("ended assemble at "+uy(a.Z)),a.K=a.Z,a.aa=!1),b="";else if(!c){var e=">> ";a.H.qa&1&&(e=a.H.O&131072?"-- ":"## ");a.P(e+b)}var f=b.charAt(0);if('"'==f||"'"==f)return!0;a.va=null;if(yb(a)&&0p||"z">>20;Qa.Ti=a.H.Wc+Qa.Jk;Qa.lb=nf.aa[(Qa.Ti&nf.C)>>>nf.A];Qa.Aj=Qa.lb.Nd(Qa.Jk);Qa.Kk=(Mg&4190208)>>>10;Qa.Ui=(Qa.Aj&-4096)+Qa.Kk;Qa.mb=nf.aa[(Qa.Ui&nf.C)>>>nf.A];Qa.Bj=Qa.mb.Nd(Qa.Kk);Qa.ul=(Qa.Bj&-4096)+(Mg&4095)}if(mf=Qa){a.P("linear PDE addr PDE PTE addr PTE physical");a.P("--------- ---------- -------- ---------- -------- ----------");var ve="%"+q(Mg),ve=ve+(" %%"+Jy(mf.Ti,mf.Aj)),ve= -ve+(" %%"+Jy(mf.Ui,mf.Bj,!0)),ve=ve+(" %%"+q(mf.ul));a.P(ve)}else a.P("unsupported operation")}}else a.P("missing address")}else{if("d"==za){if("disk"==cb){ca[0]="l";ca[1]="json";TA(a,ca);break a}for(xb in Jb)if(ca[1]==xb){var lt=a.za[xb];lt?(ca.shift(),ca.shift(),lt(ca)):a.P("no dump registered for "+cb);break a}cb||(za=a.eb||"db")}else a.eb=za;if("dh"==za){var mt=cb,nt=Sa,ot="",pt=0,Mc=a.la,jd=a.N;if(jd.length){var uc=+mt||a.Ma,Ng=+nt||10;isNaN(uc)?uc=Ng:ot="more ";uc>jd.length&&(a.P("note: only "+ -jd.length+" available"),uc=jd.length);Mc-=uc;0>Mc&&(null==jd[jd.length-1].U?(uc=Mc+uc,Mc=0):Mc+=jd.length);var km=[];"call"==nt&&(Ng=1E5,km=["CALL"]);for(void 0!==mt&&a.P(uc+" instructions earlier:");0=jd.length&&(Mc=0);a.Ma=uc;pt++;Ng--}}pt||(a.P("no "+ot+"history available"),a.Ma= -void 0)}else if("di"==za){ca.shift();var lm=ca[0];if(lm){var Pg=Rx(a,lm);if(void 0===Pg||0>Pg||255>>0,65536>4||1;QB--&&0Ui?String.fromCharCode(Ui):".";Ti--}Qg&&(Qg+="\n");Qg+=cb+" "+nm+(Sg?"":" "+vt)}Qg&&a.P(Qg);a.Ga=of}}}}}break;case "e":if("else"==g[0])break;var Vi= -1,wt=255,xt=a.Ia,yt=a.fc;"ew"==g[0]&&(Vi=2,wt=65535,xt=a.Yc,yt=a.il);var zt=Vi<<1,At=g[1];if(null==At)a.P("edit memory commands:"),a.P("\teb [a] [...] edit bytes at address a"),a.P("\tew [a] [...] edit words at address a");else{var Wi=Ey(a,At);if(Wi)for(var Xi=2;Xitm;){for(var kd=null,VB=256;Sd.Ja>>>0>>0;){Vg.Ja=a.hb(Sd,!0);if(null==Sd.xa||!VB--)break;Vg.U=Ct;if(kd=WA(a,Vg))break;Vg.U=a.hb(Sd);if(kd=WA(a,Vg,!0)){Ct=a.hb(Sd,!0);0\nLicense: GPL version 3 or later ");for(b=0;bsB){if(d.load(this.L)){this.F=new Of(this,"1.34.0",CB);this.F.load()&&(DB(this,d),a=EB,FB(this.F));this.F.set(zB,va());GB(this.F);var e=this.A&&!this.I;if(a==AB||hb("Click OK to restore the previous PCx86 machine state, or CANCEL to reset the machine.")){if(c=yB(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= -g?(this.Fa("Error: "+g),"unable to verify user"==g&&(Ia(HB,""),this.B=null)):this.P(f+": "+g),FB(d),d.load()?(c=yB(d),e=!0):c=!1))}e&&wB(this,c?d:null)}else a==EB&&d.clear()}else wB(this);delete this.L;delete this.M}e=jb(this.id);for(f=0;fa[1];a=a[2];this.ga=!0;this.ea.Yb=!0;var d=this.na.power;d&&(d.textContent="Shutdown");this.H&&(IB(this,this.H,b,c,a),this.H.lf());this.Y&&(DB(this,b),b.clear());!c&&this.F&&(this.F.clear(),delete this.F);this.C=0}; -function DB(a,b){if(hb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.34.0"};d.url=a.da;d.user=c;d.type="bug";d.data=b;Ca("http://www.pcjs.org/api/v1/report",d,!0)}} -function YA(a,b,c){var d,e="none";if(a.C)return null;a.C--;var f=new Of(a,"1.34.0"),g=new Of(a,"1.34.0",xB),h=va();g.set(zB,h);f.set(zB,h);f.set(JB,"1.34.0");f.set(KB,window?window.location.href:null);f.set(LB,Ea());a.H&&a.H.Wb&&(c&&a.H.Jb(),d=a.H.Wb(b,c),"object"===typeof d&&f.set(a.H.id,d),c&&(a.H.ea.Yb=!1,!1===d&&(e=null)));for(var h=jb(a.id),k=0;k>>b.A;d=d+e-1>>>b.A;c.ah=0;for(c.Hd=0;f<=d;)e=b.aa[f],c.ah+=e.size,e.size&&(c.Rg.push(wa(Ub,f,0,0,e.type)),c.Hd++),f++;a.A=c;a.da=a.A.Hd*a.ka.B/(Tb*cc);d=0;a.A.$i=0;a.A.kf||(a.A.kf=[]);e=-1;b=0;for(var g=-1,c=0;c>1),g=f.y+(f.A>>1),h=f.A,f.Nc>1,b.I+=(b.J>>1)-2,$b(b,e),b.Y&&(b.D.restore(),b.Y=!1)}}else $b(a,"This space intentionally left blank");a.context.drawImage(a.K,0,0,a.K.width,a.K.height,a.Ga,a.Ma,a.ya,a.Aa);a.oa=!1}}var CB="failsafe",xB="validate",zB="timestamp",JB="version",KB="url",LB="browser",HB="user",BB=-1,sB=0,AB=1,EB=2,NB=3; -Ra(function(){for(var a=pb(document,"pcx86-machine"),b=0;bf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PCx86$2"), -a=a.replace(/().*?(<\/xsl:variable>)/,"$1pcx86$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Ca(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, -"");a=a.replace(d[0],g);dC(a,b,c)}})}else c(a,null)} -function eC(a,b,c,d){function e(a){if(void 0===h){var b=g&&pb(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=oa(a))}function f(a){e("Error: "+a);k&&(--aC||Xa(!0));k=!1}var g,h,k=!0;aC++;gb[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],w=document.createElement("style");w.type="text/css";w.styleSheet?w.styleSheet.cssText=m:w.appendChild(document.createTextNode(m));p.appendChild(w)}c|| -(c="/versions/pcx86/1.34.0/components.xsl");m=function(d,h){h?bC(c,null,null,!1,e,function(d,k){k?(eb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--aC||Xa(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--aC||Xa(!0)):f("invalid machine element: "+ -a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?bC(b,a,d,!0,e,m):cC(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(u){f(u.message)}return k}function fC(a,b,c,d){Xa(!1);return eC(a,b,c,d)}window.embedPC=fC;window.embedPCx86=fC;window.findMachineComponent=function(a,b){return lb(b,a+".machine")}; -window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!sb[a]){for(var c=!0,d=sb,e=a,f=b.length,g=[],h=[],k="",m=null,p=0;p]*path=(['"])(.*?)\1.*?<\/disk>\n?/g;d=w.exec(h[m]);){var u=d[2];u&&(h[u]||(p=p.replace(d[0],"")))}d=m=la(m)}else"xsl"==w&&(e=m=la(m));k[m]=p}a&&(k[m="css"]=a);b[2]&&(k[m="parms"]=b[2]);b[3]&&(k[m="state"]=b[3]);d&&e?(a=JSON.stringify(k),g+=".js",c=c[1]+"var resources="+a+";"+c[2]+c[3],c=c.replace(/\u00A9/g, -"©"),a=Ma(c,"javascript",!1,g),a=a+(', copy it to your web server as "'+g+'", and then add the following to your web page:\n\n')+('
\n')+"...\n",a=a+(' + + + + + + + + + + + + + + +
+ + + + js + , + + +
+
+ + + + + + + + + + + + + , + + + + + + + + + + + + .machine + . + + + + + + + + + + + + + + border:1px solid black;border-radius:10px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + position:; + position:absolute; + + + + + overflow:auto;width:100%; + background-color:; + + + + - -component + +
+ + + + + + +
+ +
+
+ +
+ +
+
+ +
+ + +
[XML]
+ +
+ +
+
+
+
+ + + + + text-align:center; + + + +

+
+ + +
+
+ + + + type:'' + + + binding:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + position:absolute; + float:left; + float:right; + margin:0 auto; + ; + float:left; + + + + + + + + +
+ + + font-size:; + + + + + -label + + + width:; + + + + + + +
+
+
+ + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+
+
+ +
+
+ +

+
+ +
+
+
+ + +
+
+
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + null + + + + + + ,autoStart: + + + + + + + + + + + + + + + 600 + + + + + keyboard + ,model: + + + + + + + + + + + + + + + false + + + + + serial + ,demo: + + + + + + + + + + + + + + disk + + + + + + + + + + + + + + + 0 + + + + + + + + + + + rom + ,size:,image:'' + + + + + + + + + + + + + + + 0 + + + + + ram + ,size: + + + + + + + + + + + + + + + 600 + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 32 + + + + + + 32 + + + + + + + 0 + + + + + + + 0 + + + + + + + + + + + + + + null + + + + + video + ,model:,screenWidth:,screenHeight:,charCols:,charRows:,charWidth:,charHeight:,charSet:'',screenColor:'',smoothing: + + + + + + + + + + + + + + debugger + + + + + + + + + + + + + + panel + + + + + + + + + + + + + [ + {} + , + ] + + + + computer + ,modules: + + + + + type:'',refID:'',start:,end: + + + diff --git a/versions/c1pjs/1.34.1/document.css b/versions/c1pjs/1.34.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/c1pjs/1.34.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/c1pjs/1.34.1/document.xsl b/versions/c1pjs/1.34.1/document.xsl new file mode 100644 index 000000000..37b060a19 --- /dev/null +++ b/versions/c1pjs/1.34.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

+
+ + + + + + + +

+
+ +

+
+
+
+ + + + + + +
+
+ + +
+ +   + + +
+
+ +
+
+ + + + + + + + + + + + + + + + +

+
+ + +

+
+ + +

+
+ + +
+
+ + +
+
+ + + + + + + + + + + + + + +
+
+ + +
+
+ + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/c1pjs/1.34.1/machine.xsl b/versions/c1pjs/1.34.1/machine.xsl new file mode 100644 index 000000000..fdf1b9cb6 --- /dev/null +++ b/versions/c1pjs/1.34.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/c1pjs/1.34.1/manifest.xsl b/versions/c1pjs/1.34.1/manifest.xsl new file mode 100644 index 000000000..5b947a6d8 --- /dev/null +++ b/versions/c1pjs/1.34.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/c1pjs/1.34.1/outline.xsl b/versions/c1pjs/1.34.1/outline.xsl new file mode 100644 index 000000000..25dbe80f7 --- /dev/null +++ b/versions/c1pjs/1.34.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.34.1/common.css b/versions/pc8080/1.34.1/common.css new file mode 100644 index 000000000..a569abc64 --- /dev/null +++ b/versions/pc8080/1.34.1/common.css @@ -0,0 +1,278 @@ +@CHARSET "UTF-8"; +/** + @author Jeff Parsons (@jeffpar) + @website http://www.pcjs.org/ + @created 2013-05-05 + @modified 2014-02-23 + @license http://www.gnu.org/licenses/gpl.html + */ +body { + margin: 0; + background: #202020; +} +h1, h2 { + margin-top: 0; + color: #cccccc; +} +h1, h2, h3, h4 { + word-wrap: break-word; +} + +h4 a { + color: #cccccc !important; +} +p { + line-height: 1.5em; +} +img { + max-width: 100%; +} +a img { + vertical-align: bottom; +} +pre, code { + color: #000000; + background-color: #cccccc; + font-family: Monaco, Consolas, "Lucida Console", monospace; + font-size: 12px; +} +pre { + margin: 1em 2em; + padding: 1em; + border-radius: 5px; + overflow: auto; +} +code { + padding: 1px; +} +pre a, code a { + color: #006400 !important; +} +.common { + width: 100%; + margin: 0 auto; + color: #cccccc; +} +.common a { + + color: #7fc07f; + text-decoration: none; +} +.common hr { + border-color: #808080; +} +.common a:hover { + text-decoration: underline; +} +.common, .machine { + font-family: "Helvetica Neue", Helvetica, Arial, Geneva, sans-serif; + font-size: 15px; +} +.machine { + + overflow: hidden; +} +.c1pjs { + overflow: visible; +} +.machine-placeholder { + text-align: center; + font-weight: bold; +} +.machine-floating { + position: relative; + z-index: auto; + background-color: transparent; + padding-right: 0; +} +.machine-sticky { + position: fixed !important; + z-index: 1 !important; + background-color: #404040 !important; + padding-right: 16px !important; + top: 0 !important; +} +.common-top { + background: #202020; + font-size: small; +} +.common-top-left { + float: left; + width: 60%; +} +.common-top-left ul { + line-height: 1.5em; + list-style-type: none; + margin: 0; + padding: 1em 1em 1em 9px; + overflow: hidden; +} +.common-top-left ul li { + display: block; + float: left; +} +.common-top-left ul li a { + border-right: 1px solid #6f6f6f; + padding: 2px 6px 2px 6px; +} +.common-top-left ul li:last-child a { + border-right: none; +} +.common-top-right { + float: right; + width: 40%; +} +.common-top-right p { + float: right; + margin: 0; + padding: 1em; +} +.common-middle { + clear: both; + padding: 1px 1em 1px 1em; + background: #404040; +} +.common-sidebar { + float: left; + font-size: small; + width: 140px; + padding-bottom: 20px; + overflow: hidden; + white-space: nowrap; + word-wrap: break-word; +} +.common-list { + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 0; +} +.common-list li { + + padding-bottom: 7px; +} +.common-list-data { + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 0; +} +.common-list-data li { + line-height: 1.5em; +} +.common-list-data-items, .common-list-data-subitems { + font-size: x-small; + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 2em; +} +.common-list-data-items li, .common-list-data-subitems li { + padding-bottom: 0; +} +.common-main { + margin-left: 150px; + +} +.common-main blockquote { + text-align: justify; +} +.common-image-gallery { + margin: 0 auto; + text-align: center; +} +.common-image-gallery:after { + content: ''; + display: block; +} +.common-image-frame { + display: inline-block; + margin: 8px; + text-align: center; +} +.common-image-link { + padding: 5px; + border: 1px solid black; + border-radius: 5px; + background-color: #FAEBD7; +} +.common-image-label { + font-size: x-small; +} +.common-bottom { + clear: both; + padding-top: 1em; +} +.common-bottom:after { + content: ''; + display: block; + clear: both; +} +.common-reference { + float: left; + font-size: x-small; +} +.common-reference a { + text-decoration: none; +} +.common-copyright { + float: right; + font-size: x-small; +} +.common-copyright a { + text-decoration: none; +} +.md-list { +} +.md-list li { + line-height: 1.5em; + margin-bottom: 1em; +} +.md-list li p { + padding-left: 2em; +} +.md-list-compact { +} +.md-list-compact li { + margin-bottom: 0; +} +.md-list-none { + list-style-type: none; + padding-left: 2em; +} +.md-list-none li { + margin-bottom: 0; +} +@media screen and (max-width: 900px) { + + .common-sidebar { + width: 100%; + white-space: normal; + } + .common-list { + padding-left: 0; + } + .common-list-data { + padding-left: 0; + } + .common-sidebar h4, .common-list li, .common-list-data li, .common-list-data-items li { + width: 130px; + float: left; + overflow: hidden; + vertical-align: top; + padding-right: 1em; + margin-top: 0; + } + .common-list-data-subitems { + display: none; + } + .common-main { + clear: both; + margin-left: 0; + padding-left: 0; + padding-right: 0; + } + .md-list-none { + padding-left: 1em; + } +} diff --git a/versions/pc8080/1.34.1/common.xsl b/versions/pc8080/1.34.1/common.xsl new file mode 100644 index 000000000..4307de847 --- /dev/null +++ b/versions/pc8080/1.34.1/common.xsl @@ -0,0 +1,56 @@ + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    +

    Powered by JavaScript, Vanilla JS, and GitHub

    +
    +
    +
    + + +
    +

    + +
    +
    + +
    diff --git a/versions/pc8080/1.34.1/components.css b/versions/pc8080/1.34.1/components.css new file mode 100644 index 000000000..4b9429040 --- /dev/null +++ b/versions/pc8080/1.34.1/components.css @@ -0,0 +1,257 @@ +@CHARSET "UTF-8"; + + +*:not(input,textarea) { + -webkit-user-select: none; +} +.pcjs-embed { +} +.pcjs-embed:after { + clear:both; +} +.pcjs-machine { +} +.pcjs-name, .pcjs-menu { + clear: both; + font-weight: bold; + padding-bottom: 4px; +} +.pcjs-menu { + float: left; +} +.pcjs-canvas { + width: 100%; + height: auto; +} +.pcjs-container { + color: #000000; + position: relative; +} +.pcjs-label { + font-size: small; + line-height: 20px; + vertical-align: middle; + float: left; + font-family: Monaco, "Lucida Console", monospace; +} +.pcjs-controls textarea { + font-family: Monaco, "Lucida Console", monospace; + font-size: x-small; +} +.pcjs-fieldset { + border: none; + margin: 0; + padding: 0; +} +.pcjs-flag { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; +} +.pcjs-progress { + height: 20px; + width: 200px; + margin-top: 8px; + border: 1px solid black; + position: relative; +} +.pcjs-progress-bar { + height: 20px; + width: 0; + background-color: gold; + position: absolute; + top: 0; +} +.pcjs-progress-text { + height: 20px; + width: 200px; + font-size: small; + line-height: 20px; + text-align: center; + position: absolute; + top: 0; + z-index: 1; +} +.pcjs-register { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; + border: 1px solid black; +} +.pcjs-switches { + float: left; +} +.pcjs-bitBucket { + float: left; + width: 19px; + height: 38px; +} +.pcjs-bitCell { + float: left; + width: 19px; + height: 19px; + margin-right: -1px; + margin-bottom: -1px; + border: 1px solid black; + text-align: center; + line-height: 19px; +} +.pcjs-bitCellLeft { + border-left: 1px solid black; +} +.pcjs-bitLabel { + font-size: xx-small; + text-align: center; +} +.pcjs-description, .pcjs-status { + font-size: x-small; + line-height: 2.0em; +} +.pcjs-key { + border: 1px solid black; + font-size: x-small; + text-align: center; + position: absolute; + height: 34px; + line-height: 34px; + background-color: #ffffff; +} +.pcjs-panel-group { + color: #ffffff; + background-color: #404040; +} +.pcjs-triplet { + padding: 1px; +} +.pcjs-ledlbl { + text-align: center; + font-size: 40%; + background-color: #000000; +} +.pcjs-ledlbl0 { + text-align: right; + font-size: 50%; + background-color: #8d4076; +} +.pcjs-ledlbl1 { + text-align: right; + font-size: 50%; + background-color: #d83662; +} +.pcjs-ledpad { + text-align: center; + font-size: x-small; + line-height: 32px; + background-color: #000000; + border-bottom-left-radius: 20%; + border-bottom-right-radius: 20%; +} +.pcjs-led { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + text-align: center; + vertical-align: middle; + background-color: #000000; +} +.pcjs-rled { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + border-radius: 50%; + text-align: center; + vertical-align: middle; + background-color: #ff0000; + max-width: 50%; + max-height: 50%; +} +.pcjs-swlbl { + text-align: center; + font-size: 40%; + line-height: 16px; + background-color: #000000; + border-top-left-radius: 20%; + border-top-right-radius: 20%; +} +.pcjs-swpad { + height: 32px; + background-color: #000000; +} +.pcjs-switch { + height: 10px; + width: 28px; + margin-top: 0; + max-width: 90%; + background-color: #00ff00; +} +.pcjs-screen { + clear: both; + height: auto; + position: relative; + line-height: 0; +} +.pcjs-screen textarea { + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + opacity: 0; + border: 0; + padding: 0; + line-height: 0; +} +.pcjs-reference { + float: left; + font-size: x-small; +} +.pcjs-reference a { + text-decoration: none; +} +.pcjs-copyright { + float: right; + font-size: x-small; +} +.pcjs-copyright a { + text-decoration: none; +} +@media screen and (max-width: 800px) { + .pcjs-textarea { + width: 100% !important; + } + .pcjs-registers { + width: 100% !important; + max-width: none !important; + padding-left: 0 !important; + padding-right: 0 !important; + } + .pdp11-device { + width: 98% !important; + max-width: none !important; + margin-left: 8px !important; + padding-left: 0 !important; + padding-right: 0 !important; + } +} +@media screen and (min-width: 1200px) { + .machine-left { + max-width: 48%; + float: left; + } + .machine-right { + max-width: 48%; + float: left; + margin-left: 30px; + } + .machine-right + * { + clear: both; + } +} diff --git a/versions/pc8080/1.34.1/components.xsl b/versions/pc8080/1.34.1/components.xsl new file mode 100644 index 000000000..ce4cfbe1b --- /dev/null +++ b/versions/pc8080/1.34.1/components.xsl @@ -0,0 +1,1383 @@ + + + +]> + + + + + + + + pc + pcjs + pc8080 + PC8080 + 1.34.1 + www.pcjs.org + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + float: + + + + + + + js + + + +
    + + + + + + + + + + js + + + "" + + + + + +
    +
    + + + + + + + + + + + + + + + , + + + + + + + + + + + + + .machine + . + . + + + + + + + + + + + + + + + + + + + + ,comment:'' + + + + + + border:1px solid black;border-radius:15px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:;max-width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto;clear:both; + position:; + position:relative; + + + + + overflow:auto;width:100%; + background-color:; + + + + - -component + +
    + + + + + + +
    + + + + + + + + --object -screen + + +
    +
    + +
    + +
    +
    + + + + +
    + + +
    [XML]
    + +
    + + +
    +
    +
    +
    + + + + + text-align:center; + + + +

    +
    + + +
    +
    + + + + + + +
    +
    + + + + type:'' + + + binding:'' + + + value:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + clear:both; + position:; + position:relative; + text-align:; + float:left; + + + + + + + + + + + + + + + + + + +
    + + + font-size:; + + + + + -label + + + + width:; + width:; + + + + + + + + text-align:right; + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    +
    + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',rtcDate:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + + + + + + mouse + ,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + xt + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + +
    diff --git a/versions/pc8080/1.34.1/document.css b/versions/pc8080/1.34.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pc8080/1.34.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pc8080/1.34.1/document.xsl b/versions/pc8080/1.34.1/document.xsl new file mode 100644 index 000000000..da194a8fa --- /dev/null +++ b/versions/pc8080/1.34.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pc8080/1.34.1/machine.xsl b/versions/pc8080/1.34.1/machine.xsl new file mode 100644 index 000000000..cbdeff378 --- /dev/null +++ b/versions/pc8080/1.34.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.34.1/manifest.xsl b/versions/pc8080/1.34.1/manifest.xsl new file mode 100644 index 000000000..d9dd0399f --- /dev/null +++ b/versions/pc8080/1.34.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pc8080/1.34.1/outline.xsl b/versions/pc8080/1.34.1/outline.xsl new file mode 100644 index 000000000..7bdc4821d --- /dev/null +++ b/versions/pc8080/1.34.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.34.1/pc8080-dbg.js b/versions/pc8080/1.34.1/pc8080-dbg.js new file mode 100644 index 000000000..0780f2858 --- /dev/null +++ b/versions/pc8080/1.34.1/pc8080-dbg.js @@ -0,0 +1,302 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpudef.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpustate.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpuops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/chipset.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/keyboard.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/video.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/computer.js (C) Jeff Parsons 2012-2017 +*/ +var l;function aa(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]} +for(var ca="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},da="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this,ea=["Math","trunc"],fa=0;faa?-b:b};ka!=ia&&null!=ka&&ca(da,ha,{configurable:!0,writable:!0,value:ka}); +var m={Be:0,Ee:1,Fe:2,Ge:3,He:4,Ie:5,Je:6,Ke:7,Le:8,Me:9,Ne:10,Oe:11,Pe:12,Qe:13,Re:14,Se:15,Te:16,Ue:17,Ve:18,We:19,Xe:20,Ye:21,Ze:22,$e:23,af:24,bf:25,cf:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,ab:65,Ub:66,Vb:67,Fb:68,E:69,Yb:70,Zb:71,$b:72,ac:73,bc:74,cc:75,Hb:76,gc:77,hc:78,lc:79,mc:80,Q:81,nc:82,pc:83,qc:84,rc:85,tc:86,uc:87, +wc:88,xc:89,wb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,yc:97,ud:98,xd:99,d:100,e:101,Bd:102,Dd:103,Ed:104,Fd:105,Od:106,k:107,Pd:108,Rd:109,n:110,Sd:111,p:112,q:113,r:114,oe:115,t:116,pe:117,qe:118,re:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,df:127},la={59:186,61:187,173:189,224:91}; +function n(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.vc=b.comment;this.Ad=b;this.exports={};this.P=this.bindings={};a=this.id.indexOf(".");0>a?this.cb=this.id:(this.eb=this.id.substr(0,a),this.cb=this.id.substr(a+1));this.G={ready:!1,mb:!1,Ib:!1,ja:!1,error:!1};this.zb=null;this.G.error=!1;this.ha=c||0;this.K=this.u=this.H=this.R=this.ta=null;ma.push(this)}function oa(a,b,c){pa[a]&&b&&(pa[a][b]=c)}function qa(){return Date.now()||+new Date} +function ra(a,b,c){b||q((c?c+": ":"")+a)}function q(a){window&&window.alert(a)}function sa(a){var b=!1;window&&(b=window.confirm(a));return b}function ta(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function Ta(a,b,c){b?12"']/g,function(a){return cb[a]})}function db(a,b){return(a+" ").slice(0,b)} +function eb(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var cb={"&":"&","<":"<",">":">",'"':""","'":"'"},fb={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function gb(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function ib(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Qa=g.load;d.Ia=g.exec;if(e=g.bytes)d.ka=e;else if(e=g.words)for(d.ka=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.ka=Array(4*e.length),f=c=0;c>8&255,d.ka[f++]=e[c]>>16&255,d.ka[f++]=e[c]>>24&255;else(e=g.data)?d.Mf=e:d.ka=g;d.ka&&(d.ka.length?1==d.ka.length&&(q(d.ka[0]),d=null):(q("Empty resource: "+a),d=null));d.ra=g.symbols}catch(h){q("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c>1)+2;10>this.g&&(this.g=10);15>2;this.j=this.w-1;this.L=this.N/this.w|0;this.I=this.L-1;this.A=[];this.B=[];this.D=this.F=!1;this.S=[];this.T=[];a=new z;Pb(a,this.K);this.b=Array(this.L);for(b=0;b>>a.g;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.J)return h.pb+=h.J-e,h.J=e,!0;if(e>=h.J+h.pb){p=h.size-(e-k);p>f&&(p=f);h.pb=e-h.J+p;e=k+a.w;f-=p;g++;continue}}return Rb(Sb,e,f)}e=new z(e,p,a.w,d);Pb(e,a.K,h);a.b[g++]=e;e=k+a.w;f-=p}return 0>=f?(a.status(Math.floor(c/1024)+"Kb "+Tb[d]+" at "+x(b)),!0):Rb(Ub,b,c)} +function Vb(a,b){return a.b[(b&a.C)>>>a.g].ob(b&a.j,b)}function Wb(a,b){var c=b&a.j,d=(b&a.C)>>>a.g;return c!=a.j?a.b[d].Hc(c,b):a.b[d++].Ya(c,b)|a.b[d&a.I].Ya(0,b+1)<<8}function Xb(a,b){var c=b&a.j,d=(b&a.C)>>>a.g;return c!=a.j?a.b[d].Nb(c,b):a.b[d++].ob(c,b)|a.b[d&a.I].ob(0,b+1)<<8}function Yb(a,b,c){a.b[(b&a.C)>>>a.g].qb(b&a.j,c&255,b)}function Zb(a,b,c){var d=b&a.j,e=(b&a.C)>>>a.g;d!=a.j?a.b[e].Kc(d,c&65535,b):(a.b[e++].$a(d,c&255,b),a.b[e&a.I].$a(0,c>>8&255,b+1))} +function $b(a){for(var b=0,c=[],d=0;d>>=f)&k;if(void 0!==g){if(g[0])g[0](b,k,d);a.K&&a.F!=g[1]&&ic(a.K,b,k)}else a.K&&(Qa(a.K,a,b,k,d),a.F&&ic(a.K,b,k));f+=h<<3;b+=h;e-=h}}function Rb(a,b,c){q("Memory block error ("+a+": "+t(b)+","+t(c)+")");return!1}var Sb=1,Ub=2,jc;if(Gb){var tc=new ArrayBuffer(2);(new DataView(tc)).setUint16(0,256,!0);jc=256===(new Uint16Array(tc))[0]}else jc=!1;var uc=jc; +function z(a,b,c,d){this.id=vc+=2;this.b=null;this.J=a;this.pb=b;this.size=c||0;this.type=d||wc;this.u=d==xc;Pb(this);this.Ca=this.Dc=!1;if(c)if(Gb)this.j=new ArrayBuffer(c),this.R=new DataView(this.j,0,c),this.g=new Uint8Array(this.j,0,c),this.w=new Uint16Array(this.j,0,c>>1),this.b=new Int32Array(this.j,0,c>>2),yc(this,uc?zc:Ac);else{this.b=Array(c>>2);for(a=0;a>2),b=0;b>8,c)};l.ie=function(a){return this.b[a>>2]>>>((a&3)<<3)&255};l.me=function(a){var b=a>>2;a=(a&3)<<3;var c=this.b[b]>>a;return 24>a?c&65535:c&255|(this.b[b+1]&255)<<8};l.ve=function(a,b){var c=a>>2;a=(a&3)<<3;this.b[c]=this.b[c]&~(255<>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.Ca=!0};l.ge=function(a,b){if(this.K&&null!=this.J){var c=this.K;Hc(c,this.J+a,1,c.I)&&c.da(!0)}return this.ob(a,b)};l.ke=function(a,b){if(this.K&&null!=this.J){var c=this.K;Hc(c,this.J+a,2,c.I)&&c.da(!0)}return this.Nb(a,b)}; +l.te=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;Hc(d,this.J+a,1,d.w)&&d.da(!0)}this.u?this.rb(0,b):this.qb(a,b,c)};l.xe=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;Hc(d,this.J+a,2,d.w)&&d.da(!0)}this.u?this.rb(0,b):this.Sb(a,b,c)};l.fe=function(a){return this.g[a]};l.he=function(a){return this.g[a]};l.je=function(a){return this.R.getUint16(a,!0)};l.le=function(a){return a&1?this.g[a]|this.g[a+1]<<8:this.w[a>>1]};l.se=function(a,b){this.g[a]=b;this.Ca=!0}; +l.ue=function(a,b){this.g[a]=b;this.Ca=!0};l.we=function(a,b){this.R.setUint16(a,b,!0);this.Ca=!0};l.ye=function(a,b){a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.w[a>>1]=b;this.Ca=!0};var wc=0,xc=2,Tb=["NONE","RAM","ROM","VID","H/W"],vc=0,Cc=[],Bc=[z.prototype.ie,z.prototype.ve,z.prototype.me,z.prototype.ze],Fc=[z.prototype.ge,z.prototype.te,z.prototype.ke,z.prototype.xe];if(Gb)var Ac=[z.prototype.fe,z.prototype.se,z.prototype.je,z.prototype.we],zc=[z.prototype.he,z.prototype.ue,z.prototype.le,z.prototype.ye]; +function Ic(a,b){n.call(this,"CPU",a,1);var c=a.multiplier||1;this.Fa=a.cycles||b;this.U=c;this.Ta=Math.round(this.Fa/1E4)/100;this.Z=this.Ta*this.U;this.G.la=!1;this.G.Qb=!1;this.G.lb=a.autoStart;this.G.Bc=!1;this.G.Wa=!1;this.ya=this.oa=0;this.za=a.csStart;this.na=a.csInterval;this.sa=a.csStop;this.T=[];this.Db=this.tb.bind(this);Ja(this)}aa(Ic,n);l=Ic.prototype; +l.Ea=function(a,b,c,d){this.R=a;this.H=b;this.K=d;for(b=0;b=a.oa&&(a.oa+=a.na,c=!0);0<=a.sa&&a.sa<=Rc(a)&&(a.na=a.sa=-1,Mc(a),a.da(),c=!0);c&&a.i(Rc(a)+" cycles: checksum="+t(a.ya))}} +l.ca=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.P[b]=c;a=!0;break;case "run":this.P[b]=c;c.onclick=function(){var a;if(a=d.R)if(a=d.R,a.G.ja)a=!0;else{var b=null,c,h=ta(a.id);for(c=0;ca.Y/a.Z?b=1:d=!0;a.U=b;b=a.Ta*a.U;if(a.Z!=b){a.Z=b;b=a.Z.toFixed(2)+"Mhz";var e=a.P.setSpeed;e&&(e.textContent=b);a.i("target speed: "+b)}c&&a.R&&a.R.Za()}Tc(a,a.X);a.X=0;a.V=qa();a.ea=0;Uc(a);return d}function Wc(a,b){var c=a.T.length;a.T.push([-1,b]);return c}function Xc(a,b,c){0<=b&&ba.T[b][0]&&(c*=a.Fa*a.U/1E3,a.T[b][0]=c+Yc(a))}function Yc(a,b){var c=a.ga-=a.b;a.b=0;b&&(a.ga=0);return c} +l.tb=function(a){if(La(this,!0)){if(!this.G.la){Sc(this);this.R&&this.R.start(this.V,Rc(this));this.G.la=!0;this.G.Qb=!0;this.W&&this.W.start();var b=this.P.run;b&&(b.textContent="Halt");this.R&&(Zc(this.R,!0),a&&this.R.Za(!0))}this.Va>=this.Fa&&Uc(this,!0);this.Ha=0;this.Ma=qa();this.ea&&(a=this.Ma-this.ea,a>this.jb&&(this.V+=a,this.V>this.Ma&&(this.V=this.Ma)));try{do{for(var c,d=this.G.Wa?1:this.Na,e=this.T.length-1;0<=e;e--){var f=this.T[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.Eb(c);c=Yc(this,!0); +this.Ha+=c;this.X+=c;Qc(this,c);a=c;for(var g=this.T.length-1;0<=g;g--){var h=this.T[g];0>h[0]||(h[0]-=a,0>=h[0]&&(h[0]=-1,h[1]()))}this.wa-=c;if(0>=this.wa){this.wa+=this.Na;++this.kb>=ld&&(this.R&&Zc(this.R),this.kb=0);break}}while(this.G.la)}catch(k){this.da();Pc(this);this.R&&this.R.stop(qa(),Rc(this));La(this,!1);Ha(this,k.stack||k.message);return}c=setTimeout;d=this.Db;this.ea=qa();e=this.jb;this.Ha&&(e=Math.round(e*this.Ha/this.Na));e-=this.ea-this.Ma;if(f=this.ea-this.V)this.Y=Math.round(this.X/ +(10*f))/100,864E5<=f&&(this.ma=0,Sc(this));if(0>e||this.Ye&&(this.V-=e),e=0;this.Va+=this.Ha;this.ea+=e;c(d,e)}else Pc(this),this.R&&this.R.stop(qa(),Rc(this))};l.Eb=function(){return 0};l.da=function(a){Ka(this,!0);Yc(this);Tc(this,this.X);this.X=0;if(this.G.la){this.G.la=!1;this.W&&this.W.stop();var b=this.P.run;b&&(b.textContent="Run")}this.G.complete=a};function Pc(a,b){if(a.R){for(var c=a.R,d=0;d>8&255;a.A=b&255}function xd(a){return a.B<<8|a.C}function yd(a,b){a.B=b>>8&255;a.C=b&255}function D(a){return a.D<<8|a.F} +function zd(a,b){a.D=b>>8&255;a.F=b&255}function A(a,b){a.j=b&65535}function Ad(a){return a.I&256?1:0}function Bd(a,b){a.I=a.I&255|b}function Cd(a){return Hb[a.L&255]?4:0}function Dd(a){return(a.L^a.O)&16?16:0}function Ed(a){return a.I&255?0:64}function Fd(a){return a.L&128?128:0}function td(a){return a.N&-214|Fd(a)|Ed(a)|Dd(a)|Cd(a)|Ad(a)}function rd(a,b){a.I=a.L=a.O=0;b&1&&(a.I|=256);b&4||(a.L|=1);b&16&&(a.O|=16);b&64||(a.I|=255);b&128&&(a.L^=192);a.N=a.N&-726|b&512|2} +function Gd(a,b){a.O=a.g^b;return a.L=(a.I=a.g+b)&255}function Hd(a,b){a.O=a.g^b;return a.L=(a.I=a.g+b+(a.I&256?1:0))&255}function Id(a,b){a.I=a.L=a.O=a.g&b;(a.g|b)&8&&(a.O^=16);return a.I}function Jd(a,b){a.O=b^255;b=a.L=b+255&255;a.I=a.I&-256|b;return b}function Kd(a,b){a.O=b;b=a.L=b+1&255;a.I=a.I&-256|b;return b}function Ld(a,b){return a.L=a.I=a.O=a.g|b}function Md(a,b){b^=255;a.O=a.g^b;return a.L=(a.I=a.g+b+1^256)&255} +function Nd(a,b){b^=255;a.O=a.g^b;return a.L=(a.I=a.g+b+(a.I&256?0:1)^256)&255}function Od(a,b){return a.L=a.I=a.O=a.g^b}function E(a,b){a=a.H;return a.b[(b&a.C)>>>a.g].Ya(b&a.j,b)}function Pd(a,b,c){a=a.H;a.b[(b&a.C)>>>a.g].$a(b&a.j,c&255,b)}function F(a){var b=E(a,a.j);A(a,a.j+1);return b}function G(a){var b=Wb(a.H,a.j);A(a,a.j+2);return b}function Qd(a){var b=Wb(a.H,a.M);a.M=a.M+2&65535;return b}function H(a,b){a.M=a.M-2&65535;Zb(a.H,a.M,b)} +function Rd(a){if(a.b&&a.S&255&&a.N&512){for(var b=0;8>b&&!(a.S&1<b?255:1<>8;Bd(this,a&256);this.b-=4},Vd,function(){var a;zd(this,a=D(this)+vd(this));Bd(this,a>>8&256);this.b-=10},function(){this.g=E(this,vd(this));this.b-=7},function(){wd(this,vd(this)-1);this.b-= +5},function(){this.A=Kd(this,this.A);this.b-=5},function(){this.A=Jd(this,this.A);this.b-=5},function(){this.A=F(this);this.b-=7},function(){var a=this.g<<8&256;this.g=(a|this.g)>>1;Bd(this,a);this.b-=4},Vd,function(){yd(this,G(this));this.b-=10},function(){Pd(this,xd(this),this.g);this.b-=7},function(){yd(this,xd(this)+1);this.b-=5},function(){this.B=Kd(this,this.B);this.b-=5},function(){this.B=Jd(this,this.B);this.b-=5},function(){this.B=F(this);this.b-=7},function(){var a=this.g<<1;this.g=a&255| +Ad(this);Bd(this,a&256);this.b-=4},Vd,function(){var a;zd(this,a=D(this)+xd(this));Bd(this,a>>8&256);this.b-=10},function(){this.g=E(this,xd(this));this.b-=7},function(){yd(this,xd(this)-1);this.b-=5},function(){this.C=Kd(this,this.C);this.b-=5},function(){this.C=Jd(this,this.C);this.b-=5},function(){this.C=F(this);this.b-=7},function(){var a=this.g<<8;this.g=(Ad(this)<<8|this.g)>>1;Bd(this,a&256);this.b-=4},Vd,function(){zd(this,G(this));this.b-=10},function(){var a=G(this);Zb(this.H,a,D(this)); +this.b-=16},function(){zd(this,D(this)+1);this.b-=5},function(){this.D=Kd(this,this.D);this.b-=5},function(){this.D=Jd(this,this.D);this.b-=5},function(){this.D=F(this);this.b-=7},function(){var a=0,b=Ad(this);if(Dd(this)||9<(this.g&15))a|=6;if(b||154<=this.g)a|=96,b=1;this.g=Gd(this,a);Bd(this,b?256:0);this.b-=4},Vd,function(){var a;zd(this,a=D(this)+D(this));Bd(this,a>>8&256);this.b-=10},function(){var a;a=G(this);a=Wb(this.H,a);zd(this,a);this.b-=16},function(){zd(this,D(this)-1);this.b-=5},function(){this.F= +Kd(this,this.F);this.b-=5},function(){this.F=Jd(this,this.F);this.b-=5},function(){this.F=F(this);this.b-=7},function(){this.g=~this.g&255;this.b-=4},Vd,function(){this.M=G(this)&65535;this.b-=10},function(){Pd(this,G(this),this.g);this.b-=13},function(){this.M=this.M+1&65535;this.b-=5},function(){var a=D(this);Pd(this,a,Kd(this,E(this,a)));this.b-=10},function(){var a=D(this);Pd(this,a,Jd(this,E(this,a)));this.b-=10},function(){Pd(this,D(this),F(this));this.b-=10},function(){this.I|=256;this.b-= +4},Vd,function(){var a;zd(this,a=D(this)+this.M);Bd(this,a>>8&256);this.b-=10},function(){this.g=E(this,G(this));this.b-=13},function(){this.M=this.M-1&65535;this.b-=5},function(){this.g=Kd(this,this.g);this.b-=5},function(){this.g=Jd(this,this.g);this.b-=5},function(){this.g=F(this);this.b-=7},function(){Bd(this,Ad(this)?0:256);this.b-=4},function(){this.b-=5},function(){this.w=this.A;this.b-=5},function(){this.w=this.B;this.b-=5},function(){this.w=this.C;this.b-=5},function(){this.w=this.D;this.b-= +5},function(){this.w=this.F;this.b-=5},function(){this.w=E(this,D(this));this.b-=7},function(){this.w=this.g;this.b-=5},function(){this.A=this.w;this.b-=5},function(){this.b-=5},function(){this.A=this.B;this.b-=5},function(){this.A=this.C;this.b-=5},function(){this.A=this.D;this.b-=5},function(){this.A=this.F;this.b-=5},function(){this.A=E(this,D(this));this.b-=7},function(){this.A=this.g;this.b-=5},function(){this.B=this.w;this.b-=5},function(){this.B=this.A;this.b-=5},function(){this.b-=5},function(){this.B= +this.C;this.b-=5},function(){this.B=this.D;this.b-=5},function(){this.B=this.F;this.b-=5},function(){this.B=E(this,D(this));this.b-=7},function(){this.B=this.g;this.b-=5},function(){this.C=this.w;this.b-=5},function(){this.C=this.A;this.b-=5},function(){this.C=this.B;this.b-=5},function(){this.b-=5},function(){this.C=this.D;this.b-=5},function(){this.C=this.F;this.b-=5},function(){this.C=E(this,D(this));this.b-=7},function(){this.C=this.g;this.b-=5},function(){this.D=this.w;this.b-=5},function(){this.D= +this.A;this.b-=5},function(){this.D=this.B;this.b-=5},function(){this.D=this.C;this.b-=5},function(){this.b-=5},function(){this.D=this.F;this.b-=5},function(){this.D=E(this,D(this));this.b-=7},function(){this.D=this.g;this.b-=5},function(){this.F=this.w;this.b-=5},function(){this.F=this.A;this.b-=5},function(){this.F=this.B;this.b-=5},function(){this.F=this.C;this.b-=5},function(){this.F=this.D;this.b-=5},function(){this.b-=5},function(){this.F=E(this,D(this));this.b-=7},function(){this.F=this.g; +this.b-=5},function(){Pd(this,D(this),this.w);this.b-=7},function(){Pd(this,D(this),this.A);this.b-=7},function(){Pd(this,D(this),this.B);this.b-=7},function(){Pd(this,D(this),this.C);this.b-=7},function(){Pd(this,D(this),this.D);this.b-=7},function(){Pd(this,D(this),this.F);this.b-=7},function(){var a=this.j-1;if(this.La.length)for(var b=0;b>8;this.b-=10},function(){var a=G(this);Fd(this)||A(this,a);this.b-=10},function(){this.N&=-513;this.b-=4},function(){var a=G(this);Fd(this)||(H(this,this.j),A(this,a),this.b-=6);this.b-=11},function(){H(this,td(this)&255|this.g<<8);this.b-=11},function(){this.g=Ld(this,F(this));this.b-=7},function(){H(this,this.j);A(this,48);this.b-=11},function(){Fd(this)&& +(A(this,Qd(this)),this.b-=6);this.b-=5},function(){this.M=D(this)&65535;this.b-=5},function(){var a=G(this);Fd(this)&&A(this,a);this.b-=10},function(){this.N|=512;this.b-=4;Rd(this)},function(){var a=G(this);Fd(this)&&(H(this,this.j),A(this,a),this.b-=6);this.b-=11},Yd,function(){Md(this,F(this));this.b-=7},function(){H(this,this.j);A(this,56);this.b-=11}]; +function Zd(a){n.call(this,"ChipSet",a,32768);var b=a.model;b&&!$d[b]&&ra("Unrecognized ChipSet model: "+b);this.g=$d[b]||{};a.sound&&(this.U=null,window&&(this.U=window.AudioContext||window.webkitAudioContext),this.U&&new this.U);Ja(this)}aa(Zd,n);l=Zd.prototype;l.ca=function(){return!1}; +l.Ea=function(a,b,c,d){this.H=b;this.u=c;this.K=d;this.R=a;this.B=Kb(a,"Keyboard");this.C=Kb(a,"SerialPort");this.video=Kb(a,"Video");bc(b,this,this.g.Bb);gc(b,this,this.g.Cb);if(d){var e=this;ae(d,16384,function(){for(var a="",b=0;b>8-this.T&255;r(this,a,null,b,"SHIFT.RESULT",c,!0);return c};l.Wd=function(a,b,c){r(this,a,b,c,"SHIFT.COUNT",null,!0);this.T=b};l.Yd=function(a,b,c){r(this,a,b,c,"SOUND1",null,!0);this.Y=b};l.Xd=function(a,b,c){r(this,a,b,c,"SHIFT.DATA",null,!0);this.N=b<<8|this.N>>8}; +l.Zd=function(a,b,c){r(this,a,b,c,"SOUND2",null,!0);this.Z=b};l.$d=function(a,b,c){r(this,a,b,c,"WATCHDOG",null,!0)};function ce(a){var b=0,c=0,d=~a.M;for(a=0;10>a;a++)d&1&&(b=9-a),d>>=1;for(a=0;10>a;a++)d&1&&(c=9-a),d>>=1;return 10*b+c} +l.Md=function(a,b){var c=this.D,c=c&~J.xa.jc;if((Rc(this.u)&64)<<1&&(c|=J.xa.jc,c!=this.D)){var d,e;d=this.L&1;e=this.L>>1&7;switch(e){case J.Aa.Ja.nd:break;case J.Aa.Ja.Lc:this.M=this.M<<1|d;break;case J.Aa.Ja.Rc:d=ce(this);this.j[d]=J.Aa.vb;Pa(this,"doNVRCommand(): erase data at addr "+x(d));break;case J.Aa.Ja.Mc:this.b=this.b<<1|d;break;case J.Aa.Ja.rd:d=ce(this);e=this.b&J.Aa.vb;this.j[d]=e;Pa(this,"doNVRCommand(): write data "+x(e)+" to addr "+x(d));break;case J.Aa.Ja.ld:d=ce(this);e=this.j[d]; +null==e&&(e=J.Aa.vb);this.b=e;Pa(this,"doNVRCommand(): read data "+x(e)+" from addr "+x(d));break;case J.Aa.Ja.md:this.b<<=1;this.S=this.b&J.Aa.vb+1;break;default:Pa(this,"doNVRCommand(): unrecognized command "+Ua(e))}}c&=~J.xa.kc;this.S&&(c|=J.xa.kc);c&=~J.xa.dc;if(d=this.B){d=this.B;if(e=d.A)e=d.u,e=Rc(d.u)>=d.F+e.Fa*e.U/1E3*1.2731488;e&&(d.A=!1);d=!d.A}d&&(c|=J.xa.dc);c&=~J.xa.sc;this.C&&this.C.ia&de&&(c|=J.xa.sc);this.D=c;r(this,a,null,b,"FLAGS",c);return c}; +l.ae=function(a,b,c){r(this,a,b,c,"BRIGHTNESS");this.W=b};l.de=function(a,b,c){r(this,a,b,c,"NVR.LATCH");this.L=b};l.ce=function(a,b,c){r(this,a,b,c,"DC012");a=b&3;switch(b>>2&3){case 0:this.w=this.w&-4|a;break;case 1:this.w=this.w&-13|a<<2;this.video&&(b=this.video,a=this.w,Pa(b,"updateScrollOffset("+a+")"),b.sa!==a&&((b.sa=a)?md(b,!0):b.ya=!0));break;case 2:switch(a){case 0:this.O=~this.O;break;case 2:case 3:this.X=3-a}break;case 3:this.V=a}}; +l.be=function(a,b,c){r(this,a,b,c,"DC011");b&J.Ka.kd?(b&=J.Ka.oc,this.I!=b&&(this.I=b,this.video&&(a=this.video,b=this.I==J.Ka.oc?50:60,Pa(a,"updateRate("+b+")"),a.jb=b))):(b&=J.Ka.Wb,this.F!=b&&(this.F=b,this.video&&(a=this.F==J.Ka.Wb?132:80,b=this.video,Pa(b,"updateDimensions("+a+","+(80>>0,g],v=gb(u,k,a.Ac);0>v&&u.splice(-(v+1),0,k)}p&&(h.a=p.replace(/''/g,'"'))}a.A.push({Nf:b,J:c,Qd:d,ra:e,zc:f})}delete this.ra}return!0};ge.prototype.ua=function(){return!0}; +function he(a,b,c,d){if(d)a.aa("Unable to load system ROM (error "+d+": "+b+")");else{oa(a.eb,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.b=f;else if(g)for(a.b=Array(4*g.length),d=c=0;c>8&255,a.b[d++]=g[c]>>16&255,a.b[d++]=g[c]>>24&255;else a.b=e;a.ra=e.symbols;if(!a.b.length){q("Empty ROM: "+b);return}if(1==a.b.length){q(a.b[0]);return}}catch(h){a.aa("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.b=Array(b.length),e=0;e>>f.g;0>>= +f.g;0=m.ab&&a<=m.wb?d.g&(Re|Se)||(d.g|=Se,Oe(d,20,!0),Te(d)):a>=m.yc&&a<=m.z&&d.g&Se&&(d.g&=~Se,Oe(d,20,!1),Te(d));return!0}),c.onpaste=function(a){a:{if(d.C&&d.C.Ra&&(a.stopPropagation&&a.stopPropagation(),a.preventDefault&&a.preventDefault(),a=a.clipboardData||window.clipboardData)){Ue(d.C,a.getData("Text"));a=!1;break a}a=!0}return a},!0;default:if(this.b.Ua&&void 0!==this.b.Ua[b])return this.P[e]=c,c.onclick= +function(a,b){return function(d){d.preventDefault&&d.preventDefault();d=!0;var e=0;17==b?e=Ve:20==b&&(e=Se);if(e){c.style.fontWeight="normal";if(d=!(a.g&e))c.style.fontWeight="bold";We(a,b,d)}Oe(a,b,d,!e);a.R&&a.R.Za()}}(this,this.b.Ua[b]),!0}}return!1};l.Ea=function(a,b,c,d){this.R=a;this.u=c;this.K=d;var e=this;this.L=Wc(this.u,function(){Xe(e)});this.W=Kb(a,"ChipSet");this.C=Kb(a,"SerialPort");bc(b,this,this.b.Bb);gc(b,this,this.b.Cb)}; +l.va=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};l.ua=function(a){return a?this.save():!0};l.reset=function(){this.j=[];this.g=0;this.b.INIT&&!this.restore(this.b.INIT)&&this.aa("reset error")};l.save=function(){var a=new ud(this);switch(this.b.pa){case K.pa:a.set(0,[this.D,this.B,this.A,this.F,-1])}return a.data()}; +l.restore=function(a){var b;if(a&&(b=a[0])&&b.length)switch(this.b.pa){case Ye.pa:return!0;case K.pa:return this.D=b[0],Te(this,this.D&K.Ba.ec),this.B=b[1],this.A=b[2],this.F=b[3],this.w=b[4],!0}return!1};function Te(a,b){var c;null!=b?a.I=b:b=a.I;for(var d in a.b.fb)if(c="led-"+d,c=a.P[c]){var e=a.b.fb[d],f=!!(b&e);e&e-1&&(f=!(b&~e));c.style.backgroundColor=f?"#"+t(16711680,6):"#000000"}if(c=a.P["led-caps-lock"])c.style.backgroundColor=a.g&Se?"#"+t(65280,6):"#000000"} +function We(a,b,c,d){var e=0;switch(b){case 16:e=d?Ze:$e;break;case 17:e=d?af:Ve;break;case 18:e=d?bf:cf;break;case 91:e=d?df:ef;break;case 20:e=Se,c=!(a.g&e)}e&&(a.g=c?a.g|e:a.g&~e);return c} +function Qe(a,b,c){var d=!0,e=b.keyCode,e=la[e]||e;c=We(a,e,c,2==b.location);var f;a:if(e=a.b.Tb[e]||e,a.b.Sa[e])f=e;else{for(f in a.b.Ua)if(a.b.Ua[f]===e)break a;f=null}f&&!b.metaKey&&(d=!1,a.g&(ff|gf)&&(13==f?(f=118,d=!0):8==f&&(f=46,d=!0),d&&(a.g=c?a.g|gf:a.g&~gf)),d=Oe(a,f,c),(!(f>=m.ab&&f<=m.wb)||a.g|hf)&&b.preventDefault&&b.preventDefault());return d} +function Pe(a,b,c){var d=!0;if(c){var e=b.keyCode,f=a.b.Sa[e],g;if(g=f){a:{for(var h in a.b.sb)if(a.b.sb[h]==f){f=+h;break a}f=0}g=!f}g&&(d=Oe(a,e,c,!0),b.preventDefault&&b.preventDefault())}return d} +function Oe(a,b,c,d){var e;a:{for(e=0;ee?a.j.push({Pb:b,Mb:Date.now(),yb:d||!1}):(a.j[e].Mb=Date.now(),a.j[e].yb=d||!1),d&&Xe(a);else if(0<=e){if(!a.j[e].yb&&(d=a.j[e].Mb)&&Date.now()-dc||c>e)c=e}else{Oe(a,d,!1);b=0;continue}}b++}0<=c&&Xc(a.u,a.L,c)}l.Nd=function(a,b){var c=this.B;0<=this.w&&(this.w"]]= +229,N[m["<"]]=230,N[m.hc]=231,N[m.Ub]=232,N[m.wc]=233,N[m["?"]]=245,N[m.gc]=246,N[m.tc]=248,N[m.Vb]=249,N[m.wb]=250,N),Tb:{},fb:{},Ua:{"caps-lock":20,ctrl:17,esc:27,tab:9,"num-comma":116,"break":117,"line-feed":118,"no-scroll":119,setup:120},Nc:{qa:130,INIT:127},Ba:{qa:130,bd:1,ad:2,$c:4,Zc:8,cd:16,fc:32,ec:63,od:64,Ce:128,INIT:0},Yc:127};K.fb={l4:K.Ba.bd,l3:K.Ba.ad,l2:K.Ba.$c,l1:K.Ba.Zc,locked:K.Ba.cd,local:K.Ba.fc,online:~K.Ba.fc,"caps-lock":Se};var Ne={SI1978:Ye,VT100:K}; +K.INIT=[[K.Ba.INIT,K.Nc.INIT,!1,0,-1]];K.Bb={130:Me.prototype.Nd};K.Cb={130:Me.prototype.ee};yb(function(){for(var a=Aa(document,"pc8080","keyboard"),b=0;b>3)*a.N,!Qb(a.H,a.ma,a.L,3)))return!1;a.L?(a.Va=a.j.createImageData(b,c),a.hb=16/a.na|0,qf(a,a.L>>1)):qf(a,(a.O+1)*a.Z);a.D=document.createElement("canvas");a.D.width=b;a.D.height=c;a.wa=a.D.getContext("2d");a.T={};a.X=1<=a.Ha?8:16,f=8>(7>4)*c)}return k}l.va=function(a,b){return b||!a||this.restore(a)?!0:!1};l.ua=function(a){return!a||this.save()};l.save=function(){var a=new ud(this);a.set(0,[]);return a.data()};l.restore=function(){return!0}; +l.Xa=function(){var a=!1;if(this.b){if(this.b.Xa){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.M/this.I;b>c&&(a=Math.round(c/b*100)+"%")}this.Ta?(this.F.style.width=a,this.F.style.width=a,this.F.style.display="block",this.F.style.margin="auto"):(this.b.style.width=a,this.b.style.height="auto");this.b.style.backgroundColor="black";this.b.Xa();a=!0}this.V&&this.V.focus()}return a}; +function of(a,b){!b&&a.b&&(a.Ta?a.F.style.width=a.F.style.height="":a.b.style.width=a.b.style.height="");Pa(a,"notifyFullScreen("+b+")")}function qf(a,b){a.gb=b;a.W=!1;if(void 0===a.A||a.A.length!=a.gb)a.A=Array(a.gb)}function Bf(a,b,c,d,e){d=a.g?(b.height-c-1)*b.width+d:c+d*b.width;e&&a.Y==sf&&(208<=c&&236>c?e=a.X+tf:28<=c&&72>c&&(e=a.X+uf));a=a.U[e];d*=a.length;b.data[d]=a[0];b.data[d+1]=a[1];b.data[d+2]=a[2];b.data[d+3]=a[3]} +function md(a,b){var c=!0;if(!b){a.oa&&(120==a.oa?a.ib&1?(Sd(a.u,2),c=!1):Sd(a.u,1):Sd(a.u,4));if(c&&a.W&&a.L){for(var d=a.H,e=a.L,f=!0,g=a.ma>>>d.g;0>=1);;){var y=Vb(a.H,u++);if((y&Cf)==Cf){var w=Vb(a.H,u++),d=w&Df,c=(w&Ef)<<8|Vb(a.H,u),c=c+(w&Ff? +Gf:Hf);break}if(p>4)*y.ba,L,ja,ua,na,Ma=y.fa,fc=y.ba;C?(L=B*w.fa,ja=e*w.ba,ua=w.fa,na=w.ba):(L=B*w.La,ja=e*w.Ma,ua=w.La,na=w.Ma);y.fa>w.fa&&(L*=2,ua*=2);y.ba>w.ba&&(v==Af&&(T+=w.ba),fc=w.ba);C?C.drawImage(y.canvas,za,T,Ma,fc,L,ja,ua,na):(L+=0,ja+=0,w.j.drawImage(y.canvas, +za,T,Ma,fc,L,ja,ua,na))}h++}g++}e++}}a.W=!0;!b&&a.ya&&1==h&&(a.A[k]=-1,h=0);a.ya=!1;(h||b)&&a.wa&&a.j.drawImage(a.D,0,a.sa,a.C,a.N-a.ba,0,0,a.Db,a.td)}else{e=a.ma;f=e+a.L;k=h=g=0;b=a.C;p=0;c=a.N;v=d=0;u=a.na;B=(1<>8|(w&255)<<8);h>C&B,Bf(a,a.Va,h++,k,za),C+=u;h>p&&(p=h);k=d&&(d=k+1)}e+=2;g++;if(h>=a.C&&(h=0,k++,k>a.N))break}a.W=!0;bMissing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=lb().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= +(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||sb("aspect"));f&&.3<=f&&3.33>=f&&(xb("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");rb("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new lf(d,e,g,f,c);ya(d,c)}}); +function If(a){n.call(this,"SerialPort",a,8388608);this.T=+a.adapter;switch(this.T){case 0:this.U=0;this.X=2;break;default:q("Unrecognized serial adapter #"+this.T);return}this.g=this.j=null;this.V=a.tabSize;this.S=a.charBOL;this.w=0;this.N=!1;this.D=!0;var b=a.binding;if("console"==b)this.j="";else{var c;a=Jf;b&&(void 0===c&&(c="Panel"),(c=wa(c,this.id))&&(b=c.P[b])&&this.ca(null,a,b))}this.A="";this.b=this.Ra=this.I=null;this.exports={connect:this.Fc,receiveData:this.Ob,receiveStatus:this.ne}} +aa(If,n);l=If.prototype;l.ca=function(a,b,c,d){var e=this;switch(b){case Jf:return this.P[b]=this.g=c,c.onkeydown=function(a){a=a||window.event;var b=a.keyCode;if(8===b||a.ctrlKey&&65<=b&&90>=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=eb(c[0]);if(d!=this.cb)return;c=eb(c[1]);if(this.b=va(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.D);if(this.Ra=e.receiveData){this.D=a;this.I=e.receiveStatus;this.status("Connected "+this.eb+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.va=function(a,b){if(!b)if(this.Fc(this.D),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.ua=function(a){return a?this.save():!0};l.reset=function(){Nf(this)};l.save=function(){var a=new ud(this),b=0,c=[];c[b++]=this.F;c[b++]=this.M;c[b++]=this.O;c[b++]=this.ia;c[b++]=this.B;c[b++]=this.C;c[b]=this.L;a.set(0,c);return a.data()};l.restore=function(a){return Nf(this,a[0])}; +function Nf(a,b){var c=0;b||(b=Of);a.F=b[c++];a.M=b[c++];a.O=b[c++];a.ia=b[c++];a.B=b[c++];a.C=b[c++];a.L=b[c];return!0}function Pf(a,b){var c=a.L&b;b&15||(c>>=4);b=Qf[c];c=((a.B&Rf)>>2)+6;a.B&Sf&&c++;c+=((a.B&Tf)>>6)+1>>1;return 1E3/Math.round(b/c)}function Kf(a,b){Pa(a,"receiveByte("+Ua(b)+"), status="+Ua(a.ia));return a.N||a.ia&Uf?!1:(a.M=b,a.ia|=Uf,Sd(a.u,a.X),!0)} +l.Ob=function(a){null!=a&&(this.A="number"!=typeof a?a:this.A+String.fromCharCode(a));this.A&&(Kf(this,this.A.charCodeAt(0))&&(this.A=this.A.substr(1)),this.A&&this.u&&Xc(this.u,this.Y,Pf(this,Vf)));return!0};l.ne=function(a){this.ia&=~Wf;a&64&&(this.ia|=Wf)};function Ue(a,b){a.ia=a.ia|de|Xf;b&&a.Ra&&a.Ra.call(a.b,b)}l.Hd=function(a,b){var c=this.M;r(this,a,null,b,"DATA",c);this.ia&=~Uf;return c};l.Gd=function(a,b){var c=this.ia;r(this,a,null,b,"STATUS",c);return c}; +l.Vd=function(a,b,c){r(this,a,b,c,"DATA");this.O=b;this.ia&=~(de|Xf);Pa(this,"transmitByte("+Ua(b)+")");if(19==b)this.N=!0;else if(17==b)this.N=!1;else if(this.Ra&&this.Ra.call(this.b,b),this.g)if(8==b)this.g.value=this.g.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;9==b?(b=this.V||8,c=b-this.w%b,this.V&&(a=db("",c))):13==b&&(this.w=c=0,a="\n");this.S&&!this.w&&c&&(a=String.fromCharCode(this.S)+a);this.g.value+=a;this.g.scrollTop= +this.g.scrollHeight;this.w+=c}else if(null!=this.j){if(10==b||1024<=this.j.length)this.i(this.j),this.j="";10!=b&&(this.j+=String.fromCharCode(b))}this.u&&Xc(this.u,this.Z,Pf(this,Yf))};l.Ud=function(a,b,c){r(this,a,b,c,"CONTROL");this.F?(this.I&&(b^this.C)&(Zf|$f)&&(a=0,this.D?(a|=b&Zf?32:0,a|=b&$f?320:0):(a|=b&Zf?16:0,a|=b&$f?1048576:0),this.I.call(this.b,a)),this.C=b,this.C&ag&&(this.F=!1)):(this.B=b,this.F=!0)};l.Td=function(a,b,c){r(this,a,b,c,"BAUDRATES");this.L=b}; +var Rf=12,Sf=16,Tf=192,$f=2,Zf=32,ag=64,de=1,Uf=2,Xf=4,Wf=128,Vf=15,Yf=240,Qf=[50,75,110,134.5,150,200,300,600,1200,1800,2E3,2400,3600,4800,9600,19200],Of=[!1,0,0,133,142,39,238],Jf="buffer",Lf={0:If.prototype.Hd,1:If.prototype.Gd},Mf={0:If.prototype.Vd,1:If.prototype.Ud,2:If.prototype.Td};yb(function(){for(var a=Aa(document,"pc8080","serial"),b=0;bthis.b&&this.g.length&&(this.b=0);if(0>this.b||a!=this.g[this.b])this.g.splice(0,0,a),this.b=0;this.b--}else this.L?a="end":a=this.g[this.b+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(eb(a.substring(d,f))),d=f+1}}return b}; +function cg(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function dg(a,b,c){var d;if(b){b=eg(a,b);for(var e=0,f=!1,g=b,h=[],k=[],p=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,y--;g=v+g;d>>=8}d=t(c,0,!0)+" "+c+". "+Ta(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.i((null!=b?b+": ":"")+d);return e} +function jg(a,b){if(b)return hg(a,b,a.S[b]);var c=0;for(b in a.S)hg(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c}var gg={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function kg(a){bg.call(this,a);this.style=lg;this.F=mg();this.ma=mg();this.O=mg();this.A=[];this.j=this.I=this.w=[];ng(this);this.W=0;og(this);this.Z={};pg(this,a.messages);this.ea=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return Oc(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return Oc(b,a)})}aa(kg,bg);l=kg.prototype; +l.Ea=function(a,b,c,d){this.H=b;this.u=c;this.R=a;(a=Kc(a,"messages"))&&pg(this,a);this.ga=qg;ae(this,64,function(a){a:{var b=d.H.b,c=a[0],e=a=0,k=b.length;if(c){a=rg(sg(d,c));if(-1===a){d.i("invalid address: "+c);break a}e=a>>>d.H.g;k=1}d.i("blockid physical blockaddr used size type");d.i("-------- --------- ---------- ------ ------ ----");for(var c=-1,p=0;k--;){var u=b[e];u.type==c?p++||d.i("..."):(c=u.type,p=Tb[c],u&&d.i(t(u.id)+" %"+t(e<>>e.g;f!=e.j?e.b[g].Sb(f,b&65535,d):(e.b[g++].qb(f,b&255,d),e.b[g&e.I].qb(0,b>>8&255,d+1));c&&ug(a,c);Pc(this.u,!0)}};function mg(a){return{J:a,Da:!1}}function vg(a){return[a.J,a.Da]}function Tg(a){return{J:a[0],Da:a[1]}} +function sg(a,b,c){var d;c=(c?a.F:a.ma).J;if(void 0!==b){d=b=eg(a,b);var e;if(d.match(/^[a-z_][a-z0-9_]*$/i))for(d=d.toUpperCase(),c=0;cc&&(c=ib(Yg,a.substr(b,1))));return c};function Zg(a,b){var c=0;a=a.Lb(b);if(void 0!==a)switch(b){case $g:case ah:case bh:case ch:case dh:case eh:case fh:case gh:c=2;break;case hh:case ih:case jh:case kh:case lh:case mh:case nh:c=4}return c?t(a,c):"??"} +l.Lb=function(a){var b;if(0<=a){var c=this.u;switch(a){case $g:b=c.g;break;case ah:b=c.w;break;case bh:b=c.A;break;case hh:b=vd(c);break;case ch:b=c.B;break;case dh:b=c.C;break;case ih:b=xd(c);break;case eh:b=c.D;break;case fh:b=c.F;break;case jh:b=D(c);break;case gh:b=E(c,D(c));break;case kh:b=c.M;break;case lh:b=c.j;break;case mh:b=td(c);break;case nh:b=td(c)&255|c.g<<8}}return b}; +function oh(a,b){b=eg(a,b);for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.Kb(b,c+1),0<=e&&(b=b.substr(0,c)+Zg(a,e)+b.substr(c+1+Yg[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=Ra(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=sg(a,e))?(d=e+' "'+Xg(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=sg(a,e))?(ug(d),d=e+ +' "'+Xg(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+Wg(mg(this.u.j).J));this.ha&1073741824?this.X.push(a):this.V&&a==this.V||(this.V=a,this.ha&-2147483648&&(this.da(),a+=" (cpu halted)"),this.i(a),this.u&&(a=this.u,Yc(a),a.wa=0,Pc(a)))}; +function Qa(a,b,c,d,e,f,g,h){h|=256;null!=f&&(a.ha&h)!=h||a.message(b.cb+"."+(null!=d?"outPort":"inPort")+"("+x(c)+","+(f?f:"unknown")+(null!=d?","+Ua(d):"")+")"+(null!=g?": "+Ua(g):"")+(null!=e?" at "+Wg(e):""))} +function og(a){var b;if(Td(a)){if(!a.D||!a.D.length){a.D=Array(ph);for(b=0;b>>d.g],!1)}a.I=["br"];if(a.w)for(b=1;b>>d.g],!0);a.w=["bw"];a.oa=0}l.Pa=function(a,b,c){var d=!0;c||vh(this,a,b,!1,!0);if(a!=this.j){var e=rg(b);if(-1===e)this.i("invalid address: "+Wg(b.J)),d=!1;else{var f=this.H;f.b[e>>>f.g].Pa(e&f.j,a==this.w)}}d&&(a.push(b),c?b.Da=!0:(wh(this,a,a.length-1,"set"),og(this)));return d}; +function vh(a,b,c,d,e){var f=!1;c=rg(c);for(var g=1;g>>d.g],b==a.w));h.Da||og(a);break}}return f}function xh(a,b){for(var c=1;c>24,4);break;case Kh:C=t(y.Gb(C,2),4);break;default:y="imm("+x(w)+")";break a}y.style==Ah&&w&Lh?C="["+C+"]":w&Mh||(C=(y.style==lg?"$":"0x")+C);y=C}else w&Mh?(y=(v&Nh)>>8, +w=Yg[y],a.style==Ah&&v&Lh&&(y==gh&&(w="HL"),w="["+w+"]"),y=w):w&Oh&&(y=(f>>3&7).toString());if(!y||!y.length){h="INVALID";break}0b[0]?1:a[0]>>0;for(b=0;b>>0,h=f.Qd;if(e>=g&&e>8&255;case "C":d.A=f&255;break;case "D":d.B=f&255;break; +case "DE":d.B=f>>8&255;case "E":d.C=f&255;break;case "H":d.D=f&255;break;case "HL":d.D=f>>8&255;case "L":d.F=f&255;break;case "SP":d.M=f&65535;break;case "PC":A(d,f);a.F=mg(d.j);break;case "PS":rd(d,f);break;case "PSW":rd(d,f&255|d.N&-256);d.g=f>>8;break;case "CF":d.I=f?d.I|256:d.I&255;break;case "PF":f?Cd(d)||(d.L^=1):Cd(d)&&(d.L^=1);break;case "AF":d.O=f?~d.L&16|d.O&-17:d.L&16|d.O&-17;break;case "ZF":d.I=f?d.I&-256:d.I|255;break;case "SF":f?Fd(d)||(d.L^=192):Fd(d)&&(d.L^=192);break;case "IF":d.N= +f?d.N|512:d.N&-513;break;default:a.i("unknown register: "+e);return}Pc(d);a.i("updated registers:")}a.i(Sh(a));c&&(a.F=mg(d.j),th(a,Wg(a.F.J)))}}function Zh(a,b){b=eb(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.i(oh(a,c[2])):dg(a,b,!0)}function $h(a,b,c){var d="t"!=b;c=fg(a,c,null,!0)||1;var e=1==c?0:1;"tc"==b&&(e=c,c=1);vb(c,function(){return La(a,!0)&&tg(a,e,d,!1)},function(){Pc(a.u);La(a,!1)})} +function th(a,b,c,d){if(b=sg(a,b,!0)){void 0===d&&(d=1);var e=256;if(void 0!==c){d=sg(a,c,!0);if(!d||d.Jh[0].indexOf("+"))){var p=h[0]+":";h[2]&&(p+=" "+h[2]);a.i(p)}h[3]&&(g=h[3],f=null);f=zh(a,b,g,f);a.i(f);a.F=b;e-=b.J-k;c++}}} +l.Ab=function(a,b,c){if(b)if(a){0>this.b&&this.g.length&&(this.b=0);if(0>this.b||a!=this.g[this.b])this.g.splice(0,0,a),this.b=0;this.b--}else this.L?a="end":a=this.g[this.b+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(eb(a.substring(d,f))),d=f+1}}return b}; +function yh(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.i(">> "+b):(a.L&&(a.i("ended assemble at "+Wg(a.O.J)),a.F=a.O,a.L=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.V=null;if(Ia(a)&&0p||"z"Za.length&&(a.i("note: only "+Za.length+" available"),Ba=Za.length);Na-=Ba;0>Na&&(null==Za[Za.length-1].J?(Ba=Na+Ba,Na=0):Na+=Za.length);var te=[];"call"==Ag&&(kc=1E5,te=["CALL"]);for(void 0!==zg&&a.i(Ba+" instructions earlier:");0< +kc&&Na!=a.T;){var Dg=Za[Na++];if(null==Dg.J)break;var lc=mg(Dg.J),Ei=Ba--,Eg=zh(a,lc,"history",Ei);(!te.length||0<=Eg.indexOf(te[0]))&&a.i(Eg);lc.Jb&&(Na+=lc.Jb,kc-=lc.Jb,Ba-=lc.Jb);Na>=Za.length&&(Na=0);a.sa=Ba;Cg++;kc--}}Cg||(a.i("no "+Bg+"history available"),a.sa=void 0)}else{var $c=sg(a,na);if($c){var ad=0;Ma&&("l"==Ma.charAt(0)&&(Ma=Ma.substr(1)||fc),ad=fg(a,Ma)>>>0,65536>4||1;Fi--&&0ed?String.fromCharCode(ed):".";cd--}mc&&(mc+="\n");mc+=na+" "+ve+(nc?"":" "+Fg)}mc&&a.i(mc);a.ma=$c}}}}break;case "e":if("else"==f[0])break;var fd=1,Gg=255,Hg=a.Ga,Ig=a.Xb;"ew"==f[0]&&(fd=2,Gg=65535,Hg=a.Gb,Ig=a.Qc);var Jg=fd<<1,Kg=f[1];if(null==Kg)a.i("edit memory commands:"),a.i("\teb [a] [...] edit bytes at address a"),a.i("\tew [a] [...] edit words at address a"); +else{var gd=sg(a,Kg);if(gd)for(var hd=2;hdCe;){for(var ub=null,Li=256;65536>qc.J>>>0;){Mg.J=a.Gb(qc,2);if(null==qc.J||!Li--)break;for(var Mi=a,jd=Mg, +Ng=null,rc=jd.J,Og=rc,De=1;6>=De&&rc;De++){if(2\nLicense: GPL version 3 or later ");for(b=0;bji){if(li(d,this.F)){this.w=new ud(this,"1.34.1",ui);li(this.w)&&(vi(this,d),a=wi,xi(this.w));this.w.set(ri,hb());yi(this.w);var e=this.b&&!this.C;if(a==si||sa("Click OK to restore the previous PC8080 machine state, or CANCEL to reset the machine.")){if(c=qi(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?li(d,g):("error"==f&&"no machine state"!= +g?(this.aa("Error: "+g),"unable to verify user"==g&&(qb(zi,""),this.g=null)):this.i(f+": "+g),xi(d),li(d)?(c=qi(d),e=!0):c=!1))}e&&oi(this,c?d:null)}else a==wi&&d.clear()}else oi(this);delete this.F;delete this.I}e=ta(this.id);for(f=0;fa[1];a=a[2];this.W=!0;this.G.ja=!0;var d=this.P.power;d&&(d.textContent="Shutdown");this.u&&(Ai(this,this.u,b,c,a),this.u.lb());this.N&&(vi(this,b),b.clear());!c&&this.w&&(this.w.clear(),delete this.w);this.j=0}; +function vi(a,b){if(sa("There may be a problem with your PC8080 machine.\n\nTo help us diagnose it, click OK to send this PC8080 machine state to http://www.pcjs.org.")){var c=a.g||"";b=b.toString();var d={app:"PC8080",ver:"1.34.1"};d.url=a.U;d.user=c;d.type="bug";d.data=b;jb("http://www.pcjs.org/api/v1/report",d,!0)}} +function ai(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new ud(a,"1.34.1"),g=new ud(a,"1.34.1",pi),h=hb();g.set(ri,h);f.set(ri,h);f.set(Bi,"1.34.1");f.set(Ci,window?window.location.href:null);f.set(Di,lb());a.u&&a.u.ua&&(c&&a.u.da(),d=a.u.ua(b,c),"object"===typeof d&&f.set(a.u.id,d),c&&(a.u.G.ja=!1,!1===d&&(e=null)));for(var h=ta(a.id),k=0;kf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PC8080$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1pc8080$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(u){f=null,a=u.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");jb(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],p,u=/( [a-z]+=)(['"])(.*?)\2/g;p=u.exec(f);)k=0>k.indexOf(p[1])?k.replace(">",p[0]+">"):k.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,""); +a=a.replace(d[0],g);Yi(a,b,c)}})}else c(a,null)} +function Zi(a,b,c,d){function e(a){if(void 0===h){var b=g&&Aa(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=bb(a))}function f(a){e("Error: "+a);k&&(--Vi||Cb(!0));k=!1}var g,h,k=!0;Vi++;pa[a]={};try{if(g=document.getElementById(a)){var p;if("object"==typeof resources&&(p=resources.css)){var u=document.head||document.getElementsByTagName("head")[0],v=document.createElement("style");v.type="text/css";v.styleSheet?v.styleSheet.cssText=p:v.appendChild(document.createTextNode(p));u.appendChild(v)}c|| +(c="/versions/pc8080/1.34.1/components.xsl");p=function(d,h){h?Wi(c,null,null,!1,e,function(d,k){k?(oa(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--Vi||Cb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--Vi||Cb(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?Wi(b,a,d,!0,e,p):Xi(b,null,a,d,!1,e,p)}else f("missing machine element: "+a)}catch(B){f(B.message)}return k}window.embedPC8080=function(a,b,c,d){Cb(!1);return Zi(a,b,c,d)};window.findMachineComponent=function(a,b){return wa(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Da[a]){for(var c=!0,d=Da,e=a,f=b.length,g=[],h=[],k="",p=null,u=0;ua?-b:b};ia!=ha&&null!=ia&&aa(ba,ga,{configurable:!0,writable:!0,value:ia}); +var n={Yd:0,ae:1,be:2,ce:3,de:4,ee:5,fe:6,ge:7,he:8,ie:9,je:10,ke:11,le:12,me:13,ne:14,oe:15,pe:16,qe:17,re:18,se:19,te:20,ue:21,ve:22,we:23,xe:24,ye:25,ze:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,sb:66,tb:67,kb:68,E:69,wb:70,xb:71,yb:72,zb:73,Ab:74,Bb:75,lb:76,Fb:77,Gb:78,Jb:79,Kb:80,Q:81,Lb:82,Nb:83,Ob:84,Pb:85,Rb:86,Sb:87, +Ub:88,Vb:89,$a:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Wb:97,Rc:98,Tc:99,d:100,e:101,Xc:102,Yc:103,Zc:104,$c:105,jd:106,k:107,kd:108,ld:109,n:110,md:111,p:112,q:113,r:114,Kd:115,t:116,Ld:117,Md:118,Nd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ae:127},ja={59:186,61:187,173:189,224:91}; +function p(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Tb=b.comment;this.Uc=b;this.exports={};this.w=this.bindings={};a=this.id.indexOf(".");0>a?this.Ya=this.id:(this.Ka=this.id.substr(0,a),this.Ya=this.id.substr(a+1));this.i={ready:!1,ab:!1,nb:!1,V:!1,error:!1};this.eb=null;this.i.error=!1;this.J=this.m=this.u=this.D=this.pa=null;r.push(this)}function ka(a,b,c){la[a]&&b&&(la[a][b]=c)}function ma(){return Date.now()||+new Date} +function na(a,b,c){b||t((c?c+": ":"")+a)}function t(a){window&&window.alert(a)}function oa(a){var b=!1;window&&(b=window.confirm(a));return b}function pa(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=e?48:55),d=String.fromCharCode(e)+d;a=Math.trunc(a/16)}return(void 0===c?"":c)+d}function Ca(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ha[a]})}function Ia(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Ha={"&":"&","<":"<",">":">",'"':""","'":"'"},Ja={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function Ka(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function La(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var m="",q;for(q in b)b.hasOwnProperty(q)&&(m&&(m+="&"),m+=q+"="+encodeURIComponent(b[q]));m=m.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(m)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function Ma(a,b){var c,d={T:null,sa:null,Aa:null,ta:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Aa=g.load;d.ta=g.exec;if(e=g.bytes)d.T=e;else if(e=g.words)for(d.T=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.T=Array(4*e.length),f=c=0;c>8&255,d.T[f++]=e[c]>>16&255,d.T[f++]=e[c]>>24&255;else(e=g.data)?d.hf=e:d.T=g;d.T&&(d.T.length?1==d.T.length&&(t(d.T[0]),d=null):(t("Empty resource: "+a),d=null));d.sa=g.symbols}catch(h){t("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;c>1)+2;10>this.b&&(this.b=10);15>2;this.f=this.c-1;this.h=this.v/this.c|0;this.o=this.h-1;this.j=[];this.l=[];this.B=[];this.C=[];a=new C;jb(a,this.J);this.a=Array(this.h);for(b=0;b>>a.b;0f&&(q=f);if(h&&h.size){if(h.type==d){if(e+f<=h.Ra)return h.ib+=h.Ra-e,h.Ra=e,!0;if(e>=h.Ra+h.ib){q=h.size-(e-m);q>f&&(q=f);h.ib=e-h.Ra+q;e=m+a.c;f-=q;g++;continue}}return lb(mb,e,f)}e=new C(e,q,a.c,d);jb(e,a.J,h);a.a[g++]=e;e=m+a.c;f-=q}return 0>=f?(a.status(Math.floor(c/1024)+"Kb "+nb[d]+" at "+B(b,4,!0)),!0):lb(ob,b,c)}function qb(a,b){return a.a[(b&a.g)>>>a.b].hb(b&a.f,b)} +function rb(a,b){var c=b&a.f,d=(b&a.g)>>>a.b;return c!=a.f?a.a[d].Ed(c,b):a.a[d++].Ua(c,b)|a.a[d&a.o].Ua(0,b+1)<<8}function sb(a,b,c){a.a[(b&a.g)>>>a.b].gc(b&a.f,c&255,b)}function tb(a,b,c){var d=b&a.f,e=(b&a.g)>>>a.b;d!=a.f?a.a[e].Sd(d,c&65535,b):(a.a[e++].Va(d,c&255,b),a.a[e&a.o].Va(0,c>>8&255,b+1))} +function ub(a){for(var b=0,c=[],d=0;d>1),this.a=new Int32Array(this.m,0,c>>2),Db(this,zb?Eb:Fb);else{this.a=Array(c>>2);for(a=0;a>2),b=0;b>8,c)};k.Dd=function(a){return this.a[a>>2]>>>((a&3)<<3)&255}; +k.Id=function(a){var b=a>>2;a=(a&3)<<3;var c=this.a[b]>>a;return 24>a?c&65535:c&255|(this.a[b+1]&255)<<8};k.Rd=function(a,b){var c=a>>2;a=(a&3)<<3;this.a[c]=this.a[c]&~(255<>2;a=(a&3)<<3;24>a?this.a[c]=this.a[c]&~(65535<>8);this.ja=!0};k.Bd=function(a,b){return this.hb(a,b)};k.Gd=function(a,b){return this.ec(a,b)};k.Pd=function(a,b,c){this.w||this.gc(a,b,c)}; +k.Ud=function(a,b,c){this.w||this.h(a,b,c)};k.Ad=function(a){return this.b[a]};k.Cd=function(a){return this.b[a]};k.Fd=function(a){return this.u.getUint16(a,!0)};k.Hd=function(a){return a&1?this.b[a]|this.b[a+1]<<8:this.g[a>>1]};k.Od=function(a,b){this.b[a]=b;this.ja=!0};k.Qd=function(a,b){this.b[a]=b;this.ja=!0};k.Td=function(a,b){this.u.setUint16(a,b,!0);this.ja=!0};k.Vd=function(a,b){a&1?(this.b[a]=b,this.b[a+1]=b>>8):this.g[a>>1]=b;this.ja=!0}; +var Bb=0,Cb=2,nb=["NONE","RAM","ROM","VID","H/W"],Ab=0,Hb=[],Gb=[C.prototype.Dd,C.prototype.Rd,C.prototype.Id,C.prototype.Wd],Kb=[C.prototype.Bd,C.prototype.Pd,C.prototype.Gd,C.prototype.Ud];if(db)var Fb=[C.prototype.Ad,C.prototype.Od,C.prototype.Fd,C.prototype.Td],Eb=[C.prototype.Cd,C.prototype.Qd,C.prototype.Hd,C.prototype.Vd]; +function Lb(a,b){p.call(this,"CPU",a);var c=a.multiplier||1;this.na=a.cycles||b;this.O=c;this.Ea=Math.round(this.na/1E4)/100;this.X=this.Ea*this.O;this.i.ka=!1;this.i.fc=!1;this.i.Sa=a.autoStart;this.i.Xb=!1;this.i.bb=!1;this.wa=this.ea=0;this.xa=a.csStart;this.ha=a.csInterval;this.la=a.csStop;this.H=[];this.mb=this.jb.bind(this);A(this)}l(Lb,p);k=Lb.prototype; +k.qa=function(a,b,c,d){this.D=a;this.u=b;this.J=d;for(b=0;ba.R/a.X&&(b=1);a.O=b;b=a.Ea*a.O;if(a.X!=b){a.X=b;b=a.X.toFixed(2)+"Mhz";var d=a.w.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.D&&Wb(a.D)}a.I+=a.P;a.P=0;a.L=ma();a.W=0;Tb(a)}function Xb(a,b){var c=a.H.length;a.H.push([-1,b]);return c}function Yb(a,b,c){0<=b&&ba.H[b][0]&&(c*=a.na*a.O/1E3,a.H[b][0]=c+Zb(a))}function Zb(a,b){var c=a.da-=a.a;a.a=0;b&&(a.da=0);return c} +k.jb=function(a){if(Aa(this,!0)){if(!this.i.ka){Sb(this);this.D&&this.D.start(this.L,Vb(this));this.i.ka=!0;this.i.fc=!0;this.N&&this.N.start();var b=this.w.run;b&&(b.textContent="Halt");this.D&&($b(this.D,!0),a&&Wb(this.D,!0))}this.Ga>=this.na&&Tb(this,!0);this.oa=0;this.va=ma();this.W&&(a=this.va-this.W,a>this.Pa&&(this.L+=a,this.L>this.va&&(this.L=this.va)));try{do{for(var c,d=this.i.bb?1:this.ya,e=this.H.length-1;0<=e;e--){var f=this.H[e];0>f[0]||d>f[0]&&(d=f[0])}c=d;this.vb(c);c=Zb(this,!0); +this.oa+=c;this.P+=c;a=c;this.i.bb&&(b=!1,this.wa=this.wa+this.$b()|0,this.ea-=a,0>=this.ea&&(this.ea+=this.ha,b=!0),0<=this.la&&this.la<=Vb(this)&&(this.ha=this.la=-1,Pb(this),Rb(this),b=!0),b&&this.aa(Vb(this)+" cycles: checksum="+B(this.wa)));a=c;for(var g=this.H.length-1;0<=g;g--){var h=this.H[g];0>h[0]||(h[0]-=a,0>=h[0]&&(h[0]=-1,h[1]()))}this.ma-=c;if(0>=this.ma){this.ma+=this.ya;++this.Qa>=ac&&(this.D&&$b(this.D),this.Qa=0);break}}while(this.i.ka)}catch(m){Rb(this);Qb(this);this.D&&this.D.stop(ma(), +Vb(this));Aa(this,!1);c=m.stack||m.message;this.i.error=!0;this.G(c);return}c=setTimeout;d=this.mb;this.W=ma();e=this.Pa;this.oa&&(e=Math.round(e*this.oa/this.ya));e-=this.W-this.va;if(f=this.W-this.L)this.R=Math.round(this.P/(10*f))/100,864E5<=f&&(this.I=0,Sb(this));if(0>e||this.Re&&(this.L-=e),e=0;this.Ga+=this.oa;this.W+=e;c(d,e)}else Qb(this),this.D&&this.D.stop(ma(),Vb(this))};k.vb=function(){return 0}; +function Rb(a){a.i.ab&&(a.i.nb=!0);Zb(a);a.I+=a.P;a.P=0;if(a.i.ka){a.i.ka=!1;a.N&&a.N.stop();var b=a.w.run;b&&(b.textContent="Run")}a.i.complete=void 0}function Qb(a){if(a.D){for(var b=a.D,c=0;c>8&255;a.c=b&255}function mc(a){return a.h<<8|a.f}function nc(a,b){a.h=b>>8&255;a.f=b&255}function G(a){return a.j<<8|a.l} +function H(a,b){a.j=b>>8&255;a.l=b&255}function D(a,b){a.s=b&65535}function I(a){return a.o&256?1:0}function oc(a,b){a.o=a.o&255|b}function pc(a){return eb[a.v&255]?4:0}function jc(a){return a.F&-214|(a.v&128?128:0)|(a.o&255?0:64)|((a.v^a.B)&16?16:0)|pc(a)|I(a)}function hc(a,b){a.o=a.v=a.B=0;b&1&&(a.o|=256);b&4||(a.v|=1);b&16&&(a.B|=16);b&64||(a.o|=255);b&128&&(a.v^=192);a.F=a.F&-726|b&512|2}function qc(a,b){a.B=a.b^b;return a.v=(a.o=a.b+b)&255} +function rc(a,b){a.B=a.b^b;return a.v=(a.o=a.b+b+(a.o&256?1:0))&255}function sc(a,b){a.o=a.v=a.B=a.b&b;(a.b|b)&8&&(a.B^=16);return a.o}function tc(a,b){a.B=b^255;b=a.v=b+255&255;a.o=a.o&-256|b;return b}function uc(a,b){a.B=b;b=a.v=b+1&255;a.o=a.o&-256|b;return b}function vc(a,b){return a.v=a.o=a.B=a.b|b}function J(a,b){b^=255;a.B=a.b^b;return a.v=(a.o=a.b+b+1^256)&255}function wc(a,b){b^=255;a.B=a.b^b;return a.v=(a.o=a.b+b+(a.o&256?0:1)^256)&255}function xc(a,b){return a.v=a.o=a.B=a.b^b} +function K(a,b){a=a.u;return a.a[(b&a.g)>>>a.b].Ua(b&a.f,b)}function M(a,b,c){a=a.u;a.a[(b&a.g)>>>a.b].Va(b&a.f,c&255,b)}function N(a){var b=K(a,a.s);D(a,a.s+1);return b}function O(a){var b=rb(a.u,a.s);D(a,a.s+2);return b}function P(a){var b=rb(a.u,a.A);a.A=a.A+2&65535;return b}function Q(a,b){a.A=a.A-2&65535;tb(a.u,a.A,b)}function yc(a){if(a.a&&a.C&255&&a.F&512){for(var b=0;8>b&&!(a.C&1<b?255:1<>8;oc(this,a&256);this.a-=4},Ac,function(){var a;H(this,a=G(this)+kc(this));oc(this,a>>8&256);this.a-=10},function(){this.b=K(this,kc(this));this.a-=7},function(){lc(this,kc(this)-1);this.a-=5}, +function(){this.c=uc(this,this.c);this.a-=5},function(){this.c=tc(this,this.c);this.a-=5},function(){this.c=N(this);this.a-=7},function(){var a=this.b<<8&256;this.b=(a|this.b)>>1;oc(this,a);this.a-=4},Ac,function(){nc(this,O(this));this.a-=10},function(){M(this,mc(this),this.b);this.a-=7},function(){nc(this,mc(this)+1);this.a-=5},function(){this.h=uc(this,this.h);this.a-=5},function(){this.h=tc(this,this.h);this.a-=5},function(){this.h=N(this);this.a-=7},function(){var a=this.b<<1;this.b=a&255|I(this); +oc(this,a&256);this.a-=4},Ac,function(){var a;H(this,a=G(this)+mc(this));oc(this,a>>8&256);this.a-=10},function(){this.b=K(this,mc(this));this.a-=7},function(){nc(this,mc(this)-1);this.a-=5},function(){this.f=uc(this,this.f);this.a-=5},function(){this.f=tc(this,this.f);this.a-=5},function(){this.f=N(this);this.a-=7},function(){var a=this.b<<8;this.b=(I(this)<<8|this.b)>>1;oc(this,a&256);this.a-=4},Ac,function(){H(this,O(this));this.a-=10},function(){var a=O(this);tb(this.u,a,G(this));this.a-=16}, +function(){H(this,G(this)+1);this.a-=5},function(){this.j=uc(this,this.j);this.a-=5},function(){this.j=tc(this,this.j);this.a-=5},function(){this.j=N(this);this.a-=7},function(){var a=0,b=I(this);if((this.v^this.B)&16||9<(this.b&15))a|=6;if(b||154<=this.b)a|=96,b=1;this.b=qc(this,a);oc(this,b?256:0);this.a-=4},Ac,function(){var a;H(this,a=G(this)+G(this));oc(this,a>>8&256);this.a-=10},function(){var a;a=O(this);a=rb(this.u,a);H(this,a);this.a-=16},function(){H(this,G(this)-1);this.a-=5},function(){this.l= +uc(this,this.l);this.a-=5},function(){this.l=tc(this,this.l);this.a-=5},function(){this.l=N(this);this.a-=7},function(){this.b=~this.b&255;this.a-=4},Ac,function(){this.A=O(this)&65535;this.a-=10},function(){M(this,O(this),this.b);this.a-=13},function(){this.A=this.A+1&65535;this.a-=5},function(){var a=G(this);M(this,a,uc(this,K(this,a)));this.a-=10},function(){var a=G(this);M(this,a,tc(this,K(this,a)));this.a-=10},function(){M(this,G(this),N(this));this.a-=10},function(){this.o|=256;this.a-=4},Ac, +function(){var a;H(this,a=G(this)+this.A);oc(this,a>>8&256);this.a-=10},function(){this.b=K(this,O(this));this.a-=13},function(){this.A=this.A-1&65535;this.a-=5},function(){this.b=uc(this,this.b);this.a-=5},function(){this.b=tc(this,this.b);this.a-=5},function(){this.b=N(this);this.a-=7},function(){oc(this,I(this)?0:256);this.a-=4},function(){this.a-=5},function(){this.g=this.c;this.a-=5},function(){this.g=this.h;this.a-=5},function(){this.g=this.f;this.a-=5},function(){this.g=this.j;this.a-=5},function(){this.g= +this.l;this.a-=5},function(){this.g=K(this,G(this));this.a-=7},function(){this.g=this.b;this.a-=5},function(){this.c=this.g;this.a-=5},function(){this.a-=5},function(){this.c=this.h;this.a-=5},function(){this.c=this.f;this.a-=5},function(){this.c=this.j;this.a-=5},function(){this.c=this.l;this.a-=5},function(){this.c=K(this,G(this));this.a-=7},function(){this.c=this.b;this.a-=5},function(){this.h=this.g;this.a-=5},function(){this.h=this.c;this.a-=5},function(){this.a-=5},function(){this.h=this.f; +this.a-=5},function(){this.h=this.j;this.a-=5},function(){this.h=this.l;this.a-=5},function(){this.h=K(this,G(this));this.a-=7},function(){this.h=this.b;this.a-=5},function(){this.f=this.g;this.a-=5},function(){this.f=this.c;this.a-=5},function(){this.f=this.h;this.a-=5},function(){this.a-=5},function(){this.f=this.j;this.a-=5},function(){this.f=this.l;this.a-=5},function(){this.f=K(this,G(this));this.a-=7},function(){this.f=this.b;this.a-=5},function(){this.j=this.g;this.a-=5},function(){this.j= +this.c;this.a-=5},function(){this.j=this.h;this.a-=5},function(){this.j=this.f;this.a-=5},function(){this.a-=5},function(){this.j=this.l;this.a-=5},function(){this.j=K(this,G(this));this.a-=7},function(){this.j=this.b;this.a-=5},function(){this.l=this.g;this.a-=5},function(){this.l=this.c;this.a-=5},function(){this.l=this.h;this.a-=5},function(){this.l=this.f;this.a-=5},function(){this.l=this.j;this.a-=5},function(){this.a-=5},function(){this.l=K(this,G(this));this.a-=7},function(){this.l=this.b; +this.a-=5},function(){M(this,G(this),this.g);this.a-=7},function(){M(this,G(this),this.c);this.a-=7},function(){M(this,G(this),this.h);this.a-=7},function(){M(this,G(this),this.f);this.a-=7},function(){M(this,G(this),this.j);this.a-=7},function(){M(this,G(this),this.l);this.a-=7},function(){var a=this.s-1;if(this.ra.length)for(var b=0;b>>=f)&m;if(void 0!==g&&g[0])g[0](a,m,d);f+=h<<3;a+=h;e-=h}this.a-=10},function(){var a=O(this);I(this)||(Q(this,this.s),D(this,a),this.a-=6);this.a-=11},function(){Q(this,mc(this));this.a-=11},function(){this.b=J(this,N(this));this.a-=7},function(){Q(this,this.s);D(this,16);this.a-=11},function(){I(this)&&(D(this,P(this)),this.a-=6);this.a-=5},Cc,function(){var a=O(this);I(this)&&D(this,a);this.a-=10},function(){for(var a= +N(this),b=this.u,c=this.s+-2&65535,d=1,e=0,f=0;0>8;this.a-=10},function(){var a=O(this);this.v&128||D(this,a);this.a-=10},function(){this.F&=-513;this.a-=4},function(){var a=O(this);this.v&128||(Q(this,this.s), +D(this,a),this.a-=6);this.a-=11},function(){Q(this,jc(this)&255|this.b<<8);this.a-=11},function(){this.b=vc(this,N(this));this.a-=7},function(){Q(this,this.s);D(this,48);this.a-=11},function(){this.v&128&&(D(this,P(this)),this.a-=6);this.a-=5},function(){this.A=G(this)&65535;this.a-=5},function(){var a=O(this);this.v&128&&D(this,a);this.a-=10},function(){this.F|=512;this.a-=4;yc(this)},function(){var a=O(this);this.v&128&&(Q(this,this.s),D(this,a),this.a-=6);this.a-=11},Dc,function(){J(this,N(this)); +this.a-=7},function(){Q(this,this.s);D(this,56);this.a-=11}];function S(a){p.call(this,"ChipSet",a);var b=a.model;b&&!Ec[b]&&na("Unrecognized ChipSet model: "+b);this.b=Ec[b]||{};a.sound&&(this.I=null,window&&(this.I=window.AudioContext||window.webkitAudioContext),this.I&&new this.I);A(this)}l(S,p);k=S.prototype;k.S=function(){return!1}; +k.qa=function(a,b,c,d){this.u=b;this.m=c;this.J=d;this.D=a;this.h=gb(a,"Keyboard");this.g=gb(a,"SerialPort");this.video=gb(a,"Video");vb(b,this,this.b.fb);wb(b,this,this.b.gb)};k.ca=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};k.ba=function(a){return a?this.save():!0};k.reset=function(){this.b.INIT&&!this.restore(this.b.INIT)&&this.G("reset error")}; +k.save=function(){var a=new E(this);switch(this.b.Y){case T.Y:a.set(0,[this.W,this.f,this.X,this.B,this.H,this.P,this.R]);break;case V.Y:a.set(0,[this.N,this.s]),a.set(1,[this.l,this.o]),a.set(2,[this.c,this.C,this.O,this.L]),a.set(3,[this.A,this.a,this.v,this.F,this.j])}return a.data()}; +k.restore=function(a){var b;if(a&&(b=a[0])&&b.length)switch(this.b.Y){case T.Y:return this.W=b[0],this.f=b[1],this.X=b[2],this.B=b[3],this.H=b[4],this.P=b[5],this.R=b[6],!0;case V.Y:return this.N=b[0],this.s=b[1],b=a[1],this.l=b[0],this.o=b[1],b=a[2],this.c=b[0],this.C=b[1],this.O=b[2],this.L=b[3],b=a[3],this.A=b[0],this.a=b[1],this.v=b[2],this.F=b[3],this.j=b[4],!0}return!1};k.start=function(){};k.stop=function(){};k.dd=function(){return this.W};k.ed=function(){return this.f};k.fd=function(){return this.X}; +k.cd=function(){return this.B>>8-this.H&255};k.qd=function(a,b){this.H=b};k.sd=function(a,b){this.P=b};k.rd=function(a,b){this.B=b<<8|this.B>>8};k.td=function(a,b){this.R=b};k.ud=function(){};function Fc(a){var b=0,c=0,d=~a.A;for(a=0;10>a;a++)d&1&&(b=9-a),d>>=1;for(a=0;10>a;a++)d&1&&(c=9-a),d>>=1;return 10*b+c} +k.gd=function(){var a=this.s,a=a&~V.ga.Hb;if((Vb(this.m)&64)<<1&&(a|=V.ga.Hb,a!=this.s)){var b,c;b=this.v&1;switch(this.v>>1&7){case V.ia.Ca.kc:this.A=this.A<<1|b;break;case V.ia.Ca.pc:b=Fc(this);this.j[b]=V.ia.Za;break;case V.ia.Ca.lc:this.a=this.a<<1|b;break;case V.ia.Ca.Pc:b=Fc(this);c=this.a&V.ia.Za;this.j[b]=c;break;case V.ia.Ca.Kc:b=Fc(this);c=this.j[b];null==c&&(c=V.ia.Za);this.a=c;break;case V.ia.Ca.Lc:this.a<<=1,this.F=this.a&V.ia.Za+1}}a&=~V.ga.Ib;this.F&&(a|=V.ga.Ib);a&=~V.ga.Cb;if(b=this.h){b= +this.h;if(c=b.h)c=b.m,c=Vb(b.m)>=b.o+c.na*c.O/1E3*1.2731488;c&&(b.h=!1);b=!b.h}b&&(a|=V.ga.Cb);a&=~V.ga.Qb;this.g&&this.g.U&Gc&&(a|=V.ga.Qb);return this.s=a};k.vd=function(a,b){this.N=b};k.yd=function(a,b){this.v=b};k.xd=function(a,b){a=b&3;switch(b>>2&3){case 0:this.c=this.c&-4|a;break;case 1:this.c=this.c&-13|a<<2;this.video&&(b=this.video,a=this.c,b.la!==a&&((b.la=a)?bc(b,!0):b.na=!0));break;case 2:switch(a){case 0:this.C=~this.C;break;case 2:case 3:this.O=3-a}break;case 3:this.L=a}}; +k.wd=function(a,b){b&V.ua.Jc?(b&=V.ua.Mb,this.o!=b&&(this.o=b,this.video&&(this.video.bc=this.o==V.ua.Mb?50:60))):(b&=V.ua.ub,this.l!=b&&(this.l=b,this.video&&(a=this.video,b=this.l==V.ua.ub?132:80,a.C=b,a.M=a.va,80>8&255,a.a[d++]=g[c]>>16&255,a.a[d++]=g[c]>>24&255;else a.a=e;a.sa=e.symbols;if(!a.a.length){t("Empty ROM: "+b);return}if(1==a.a.length){t(a.a[0]);return}}catch(h){a.G("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.a=Array(b.length),e=0;e>>f.b;0>>=f.b;0=n.Ia&&a<=n.$a?d.b&(Zc|$c)||(d.b|=$c,Wc(d,20,!0),ad(d)):a>=n.Wb&&a<=n.z&&d.b&$c&&(d.b&=~$c,Wc(d,20,!1),ad(d));return!0}),c.onpaste=function(a){a:{if(d.g&&d.g.Ba&&(a.stopPropagation&&a.stopPropagation(),a.preventDefault&&a.preventDefault(),a=a.clipboardData||window.clipboardData)){bd(d.g,a.getData("Text"));a=!1;break a}a=!0}return a},!0;default:if(this.a.Fa&&void 0!==this.a.Fa[b])return this.w[e]=c,c.onclick= +function(a,b){return function(d){d.preventDefault&&d.preventDefault();d=!0;var e=0;17==b?e=cd:20==b&&(e=$c);if(e){c.style.fontWeight="normal";if(d=!(a.b&e))c.style.fontWeight="bold";dd(a,b,d)}Wc(a,b,d,!e);a.D&&Wb(a.D)}}(this,this.a.Fa[b]),!0}}return!1};k.qa=function(a,b,c,d){this.D=a;this.m=c;this.J=d;var e=this;this.v=Xb(this.m,function(){ed(e)});this.N=gb(a,"ChipSet");this.g=gb(a,"SerialPort");vb(b,this,this.a.fb);wb(b,this,this.a.gb)}; +k.ca=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};k.ba=function(a){return a?this.save():!0};k.reset=function(){this.c=[];this.b=0;this.a.INIT&&!this.restore(this.a.INIT)&&this.G("reset error")};k.save=function(){var a=new E(this);switch(this.a.Y){case W.Y:a.set(0,[this.l,this.j,this.h,this.o,-1])}return a.data()}; +k.restore=function(a){var b;if(a&&(b=a[0])&&b.length)switch(this.a.Y){case fd.Y:return!0;case W.Y:return this.l=b[0],ad(this,this.l&W.fa.Db),this.j=b[1],this.h=b[2],this.o=b[3],this.f=b[4],!0}return!1};function ad(a,b){var c;null!=b?a.s=b:b=a.s;for(var d in a.a.La)if(c="led-"+d,c=a.w[c]){var e=a.a.La[d],f=!!(b&e);e&e-1&&(f=!(b&~e));c.style.backgroundColor=f?"#"+B(16711680,6):"#000000"}if(c=a.w["led-caps-lock"])c.style.backgroundColor=a.b&$c?"#"+B(65280,6):"#000000"} +function dd(a,b,c,d){var e=0;switch(b){case 16:e=d?gd:id;break;case 17:e=d?jd:cd;break;case 18:e=d?kd:ld;break;case 91:e=d?md:nd;break;case 20:e=$c,c=!(a.b&e)}e&&(a.b=c?a.b|e:a.b&~e);return c} +function Yc(a,b,c){var d=!0,e=b.keyCode,e=ja[e]||e;c=dd(a,e,c,2==b.location);var f;a:if(e=a.a.rb[e]||e,a.a.Da[e])f=e;else{for(f in a.a.Fa)if(a.a.Fa[f]===e)break a;f=null}f&&!b.metaKey&&(d=!1,a.b&(od|pd)&&(13==f?(f=118,d=!0):8==f&&(f=46,d=!0),d&&(a.b=c?a.b|pd:a.b&~pd)),d=Wc(a,f,c),(!(f>=n.Ia&&f<=n.$a)||a.b|qd)&&b.preventDefault&&b.preventDefault());return d} +function Xc(a,b,c){var d=!0;if(c){var e=b.keyCode,f=a.a.Da[e],g;if(g=f){a:{for(var h in a.a.Wa)if(a.a.Wa[h]==f){f=+h;break a}f=0}g=!f}g&&(d=Wc(a,e,c,!0),b.preventDefault&&b.preventDefault())}return d} +function Wc(a,b,c,d){var e;a:{for(e=0;ee?a.c.push({qb:b,ob:Date.now(),cb:d||!1}):(a.c[e].ob=Date.now(),a.c[e].cb=d||!1),d&&ed(a);else if(0<=e){if(!a.c[e].cb&&(d=a.c[e].ob)&&Date.now()-dc||c>e)c=e}else{Wc(a,d,!1);b=0;continue}}b++}0<=c&&Yb(a.m,a.v,c)}k.hd=function(){var a=this.j;0<=this.f&&(this.f"]]= +229,Y[n["<"]]=230,Y[n.Gb]=231,Y[n.sb]=232,Y[n.Ub]=233,Y[n["?"]]=245,Y[n.Fb]=246,Y[n.Rb]=248,Y[n.tb]=249,Y[n.$a]=250,Y),rb:{},La:{},Fa:{"caps-lock":20,ctrl:17,esc:27,tab:9,"num-comma":116,"break":117,"line-feed":118,"no-scroll":119,setup:120},mc:{Z:130,INIT:127},fa:{Z:130,Ac:1,zc:2,yc:4,xc:8,Bc:16,Eb:32,Db:63,Mc:64,Zd:128,INIT:0},wc:127};W.La={l4:W.fa.Ac,l3:W.fa.zc,l2:W.fa.yc,l1:W.fa.xc,locked:W.fa.Bc,local:W.fa.Eb,online:~W.fa.Eb,"caps-lock":$c};var Vc={SI1978:fd,VT100:W}; +W.INIT=[[W.fa.INIT,W.mc.INIT,!1,0,-1]];W.fb={130:Uc.prototype.hd};W.gb={130:Uc.prototype.zd};Va(function(){for(var a=y(document,"pc8080","keyboard"),b=0;b>3)*a.B,!kb(a.u,a.da,a.v,3)))return!1;a.v?(a.Ga=a.c.createImageData(b,c),a.Na=16/a.ea|0,yd(a,a.v>>1)):yd(a,(a.C+1)*a.R);a.l=document.createElement("canvas");a.l.width=b;a.l.height=c;a.ma=a.l.getContext("2d");a.H={};a.O=1<=a.va?8:16,f=8>(7>4)*c)}return m}k.ca=function(a,b){return b||!a||this.restore(a)?!0:!1};k.ba=function(a){return!a||this.save()};k.save=function(){var a=new E(this);a.set(0,[]);return a.data()};k.restore=function(){return!0}; +k.Ha=function(){var a=!1;if(this.a){if(this.a.Ha){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.A/this.s;b>c&&(a=Math.round(c/b*100)+"%")}this.Ea?(this.o.style.width=a,this.o.style.width=a,this.o.style.display="block",this.o.style.margin="auto"):(this.a.style.width=a,this.a.style.height="auto");this.a.style.backgroundColor="black";this.a.Ha();a=!0}this.L&&this.L.focus()}return a}; +function wd(a,b){!b&&a.a&&(a.Ea?a.o.style.width=a.o.style.height="":a.a.style.width=a.a.style.height="")}function yd(a,b){a.Ma=b;a.N=!1;if(void 0===a.g||a.g.length!=a.Ma)a.g=Array(a.Ma)}function Jd(a,b,c,d,e){d=a.b?(b.height-c-1)*b.width+d:c+d*b.width;e&&a.P==Ad&&(208<=c&&236>c?e=a.O+Bd:28<=c&&72>c&&(e=a.O+Cd));a=a.I[e];d*=a.length;b.data[d]=a[0];b.data[d+1]=a[1];b.data[d+2]=a[2];b.data[d+3]=a[3]} +function bc(a,b){var c=!0;if(!b){a.ha&&(120==a.ha?a.Oa&1?(zc(a.m,2),c=!1):zc(a.m,1):zc(a.m,4));if(c&&a.N&&a.v){for(var d=a.u,e=a.v,f=!0,g=a.da>>>d.b;0>=1);;){var z=qb(a.u,x++);if((z&Kd)==Kd){var v=qb(a.u,x++),d=v&Ld,c=(v&Md)<<8|qb(a.u,x),c=c+(v&Nd?Od: +Pd);break}if(q>4)*z.K,da,xa,Wa,pb,hd=z.M,ec=z.K;F?(da=L*v.M,xa=e*v.K,Wa=v.M,pb=v.K):(da=L*v.wa,xa=e*v.xa,Wa=v.wa,pb=v.xa);z.M>v.M&&(da*=2,Wa*=2);z.K>v.K&&(w==Id&&(U+=v.K),ec=v.K);F?F.drawImage(z.canvas,Z,U,hd,ec,da,xa,Wa,pb):(da+=0,xa+=0,v.c.drawImage(z.canvas,Z,U,hd,ec, +da,xa,Wa,pb))}h++}g++}e++}}a.N=!0;!b&&a.na&&1==h&&(a.g[m]=-1,h=0);a.na=!1;(h||b)&&a.ma&&a.c.drawImage(a.l,0,a.la,a.j,a.B-a.K,0,0,a.mb,a.jc)}else{e=a.da;f=e+a.v;m=h=g=0;b=a.j;q=0;c=a.B;w=d=0;x=a.ea;L=(1<>>v.b;v=z!=v.f?v.a[Z].ec(z,F):v.a[Z++].hb(z,F)|v.a[Z&v.o].hb(0,F+1)<<8;if(a.N&&v===a.g[g])h+=a.Na;else{a.g[g]=v;(F=w)&&(v=v>>8|(v&255)<<8);h>F&L,Jd(a,a.Ga,h++,m,Z),F+=x;h>q&&(q=h);m=d&&(d=m+1)}e+= +2;g++;if(h>=a.j&&(h=0,m++,m>a.B))break}a.N=!0;bMissing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=(window?window.navigator.userAgent:"").indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= +(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||Sa("aspect"));f&&.3<=f&&3.33>=f&&(Ua("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ra("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new td(d,e,g,f,c);sa(d,c)}}); +function Qd(a){p.call(this,"SerialPort",a);this.H=+a.adapter;switch(this.H){case 0:this.I=0;this.O=2;break;default:t("Unrecognized serial adapter #"+this.H);return}this.b=this.c=null;this.L=a.tabSize;this.F=a.charBOL;this.f=0;this.B=!1;this.l=!0;var b=a.binding;if("console"==b)this.c="";else{var c;a=Rd;b&&(void 0===c&&(c="Panel"),(c=ra(c,this.id))&&(b=c.w[b])&&this.S(null,a,b))}this.g="";this.a=this.Ba=this.s=null;this.exports={connect:this.ac,receiveData:this.pb,receiveStatus:this.Jd}}l(Qd,p); +k=Qd.prototype;k.S=function(a,b,c,d){var e=this;switch(b){case Rd:return this.w[b]=this.b=c,c.onkeydown=function(a){a=a||window.event;var b=a.keyCode;if(8===b||a.ctrlKey&&65<=b&&90>=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Ia(c[0]);if(d!=this.Ya)return;c=Ia(c[1]);if(this.a=qa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.l);if(this.Ba=e.receiveData){this.l=a;this.s=e.receiveStatus;this.status("Connected "+this.Ka+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +k.ca=function(a,b){if(!b)if(this.ac(this.l),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};k.ba=function(a){return a?this.save():!0};k.reset=function(){Vd(this)};k.save=function(){var a=new E(this),b=0,c=[];c[b++]=this.o;c[b++]=this.A;c[b++]=this.C;c[b++]=this.U;c[b++]=this.h;c[b++]=this.j;c[b]=this.v;a.set(0,c);return a.data()};k.restore=function(a){return Vd(this,a[0])}; +function Vd(a,b){var c=0;b||(b=Wd);a.o=b[c++];a.A=b[c++];a.C=b[c++];a.U=b[c++];a.h=b[c++];a.j=b[c++];a.v=b[c];return!0}function Xd(a,b){var c=a.v&b;b&15||(c>>=4);b=Yd[c];c=((a.h&Zd)>>2)+6;a.h&$d&&c++;c+=((a.h&ae)>>6)+1>>1;return 1E3/Math.round(b/c)}function Sd(a,b){return a.B||a.U&be?!1:(a.A=b,a.U|=be,zc(a.m,a.O),!0)} +k.pb=function(a){null!=a&&(this.g="number"!=typeof a?a:this.g+String.fromCharCode(a));this.g&&(Sd(this,this.g.charCodeAt(0))&&(this.g=this.g.substr(1)),this.g&&this.m&&Yb(this.m,this.P,Xd(this,ce)));return!0};k.Jd=function(a){this.U&=~de;a&64&&(this.U|=de)};function bd(a,b){a.U=a.U|Gc|ee;b&&a.Ba&&a.Ba.call(a.a,b)}k.bd=function(){var a=this.A;this.U&=~be;return a};k.ad=function(){return this.U}; +k.pd=function(a,b){this.C=b;this.U&=~(Gc|ee);if(19==b)this.B=!0;else if(17==b)this.B=!1;else if(this.Ba&&this.Ba.call(this.a,b),this.b)if(8==b)this.b.value=this.b.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;9==b?(b=this.L||8,c=b-this.f%b,this.L&&(a=" ".slice(0,c))):13==b&&(this.f=c=0,a="\n");this.F&&!this.f&&c&&(a=String.fromCharCode(this.F)+a);this.b.value+=a;this.b.scrollTop=this.b.scrollHeight; +this.f+=c}else if(null!=this.c){if(10==b||1024<=this.c.length)this.aa(this.c),this.c="";10!=b&&(this.c+=String.fromCharCode(b))}this.m&&Yb(this.m,this.R,Xd(this,fe))};k.od=function(a,b){this.o?(this.s&&(b^this.j)&(ge|he)&&(a=0,this.l?(a|=b&ge?32:0,a|=b&he?320:0):(a|=b&ge?16:0,a|=b&he?1048576:0),this.s.call(this.a,a)),this.j=b,this.j&ie&&(this.o=!1)):(this.h=b,this.o=!0)};k.nd=function(a,b){this.v=b}; +var Zd=12,$d=16,ae=192,he=2,ge=32,ie=64,Gc=1,be=2,ee=4,de=128,ce=15,fe=240,Yd=[50,75,110,134.5,150,200,300,600,1200,1800,2E3,2400,3600,4800,9600,19200],Wd=[!1,0,0,133,142,39,238],Rd="buffer",Td={0:Qd.prototype.bd,1:Qd.prototype.ad},Ud={0:Qd.prototype.pd,1:Qd.prototype.od,2:Qd.prototype.nd};Va(function(){for(var a=y(document,"pc8080","serial"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;ble){if(ne(d,this.o)){this.f=new E(this,"1.34.1",we);ne(this.f)&&(xe(this,d),a=ye,ze(this.f));this.f.set(te,Ka());Ae(this.f);var e=this.a&&!this.j;if(a==ue||oa("Click OK to restore the previous PC8080 machine state, or CANCEL to reset the machine.")){if(c=se(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?ne(d,g):("error"==f&&"no machine state"!= +g?(this.G("Error: "+g),"unable to verify user"==g&&(Qa(Be,""),this.b=null)):this.aa(f+": "+g),ze(d),ne(d)?(c=se(d),e=!0):c=!1))}e&&qe(this,c?d:null)}else a==ye&&d.clear()}else qe(this);delete this.o;delete this.s}e=pa(this.id);for(f=0;fa[1];a=a[2];this.N=!0;this.i.V=!0;var d=this.w.power;d&&(d.textContent="Shutdown");this.m&&(Ce(this,this.m,b,c,a),this.m.Sa());this.B&&(xe(this,b),b.clear());!c&&this.f&&(this.f.clear(),delete this.f);this.c=0}; +function xe(a,b){if(oa("There may be a problem with your PC8080 machine.\n\nTo help us diagnose it, click OK to send this PC8080 machine state to http://www.pcjs.org.")){var c=a.b||"";b=b.toString();var d={app:"PC8080",ver:"1.34.1"};d.url=a.I;d.user=c;d.type="bug";d.data=b;La("http://www.pcjs.org/api/v1/report",d,!0)}} +function De(a,b,c){var d,e="none";if(a.c)return null;a.c--;var f=new E(a,"1.34.1"),g=new E(a,"1.34.1",re),h=Ka();g.set(te,h);f.set(te,h);f.set(Ee,"1.34.1");f.set(Fe,window?window.location.href:null);f.set(Ge,window?window.navigator.userAgent:"");a.m&&a.m.ba&&(c&&Rb(a.m),d=a.m.ba(b,c),"object"===typeof d&&f.set(a.m.id,d),c&&(a.m.i.V=!1,!1===d&&(e=null)));for(var h=pa(a.id),m=0;mf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PC8080$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1pc8080$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(x){f=null,a=x.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");La(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var m=h[0],q,x=/( [a-z]+=)(['"])(.*?)\2/g;q=x.exec(f);)m=0>m.indexOf(q[1])?m.replace(">",q[0]+">"):m.replace(new RegExp(q[1]+"(['\"])(.*?)\\1"),q[0]);h[0]!=m&&(g=g.replace(h[0],m))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,""); +a=a.replace(d[0],g);Oe(a,b,c)}})}else c(a,null)} +function Pe(a,b,c,d){function e(a){if(void 0===h){var b=g&&y(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=Ga(a))}function f(a){e("Error: "+a);m&&(--Le||$a(!0));m=!1}var g,h,m=!0;Le++;la[a]={};try{if(g=document.getElementById(a)){var q;if("object"==typeof resources&&(q=resources.css)){var x=document.head||document.getElementsByTagName("head")[0],w=document.createElement("style");w.type="text/css";w.styleSheet?w.styleSheet.cssText=q:w.appendChild(document.createTextNode(q));x.appendChild(w)}c|| +(c="/versions/pc8080/1.34.1/components.xsl");q=function(d,h){h?Me(c,null,null,!1,e,function(d,m){m?(ka(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(m=h.transformNode(m))?(g.outerHTML=m,--Le||$a(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(m),(m=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(m,g),--Le||$a(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?Me(b,a,d,!0,e,q):Ne(b,null,a,d,!1,e,q)}else f("missing machine element: "+a)}catch(L){f(L.message)}return m}window.embedPC8080=function(a,b,c,d){$a(!1);return Pe(a,b,c,d)};window.findMachineComponent=function(a,b){return ra(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!ua[a]){for(var c=!0,d=ua,e=a,f=b.length,g=[],h=[],m="",q=null,x=0;x + + + + +]> + + + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    +

    Powered by JavaScript, Vanilla JS, and GitHub

    +
    +
    +
    + + +
    +

    + +
    +
    + +
    diff --git a/versions/pcx86/1.34.1/components.css b/versions/pcx86/1.34.1/components.css new file mode 100644 index 000000000..4b9429040 --- /dev/null +++ b/versions/pcx86/1.34.1/components.css @@ -0,0 +1,257 @@ +@CHARSET "UTF-8"; + + +*:not(input,textarea) { + -webkit-user-select: none; +} +.pcjs-embed { +} +.pcjs-embed:after { + clear:both; +} +.pcjs-machine { +} +.pcjs-name, .pcjs-menu { + clear: both; + font-weight: bold; + padding-bottom: 4px; +} +.pcjs-menu { + float: left; +} +.pcjs-canvas { + width: 100%; + height: auto; +} +.pcjs-container { + color: #000000; + position: relative; +} +.pcjs-label { + font-size: small; + line-height: 20px; + vertical-align: middle; + float: left; + font-family: Monaco, "Lucida Console", monospace; +} +.pcjs-controls textarea { + font-family: Monaco, "Lucida Console", monospace; + font-size: x-small; +} +.pcjs-fieldset { + border: none; + margin: 0; + padding: 0; +} +.pcjs-flag { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; +} +.pcjs-progress { + height: 20px; + width: 200px; + margin-top: 8px; + border: 1px solid black; + position: relative; +} +.pcjs-progress-bar { + height: 20px; + width: 0; + background-color: gold; + position: absolute; + top: 0; +} +.pcjs-progress-text { + height: 20px; + width: 200px; + font-size: small; + line-height: 20px; + text-align: center; + position: absolute; + top: 0; + z-index: 1; +} +.pcjs-register { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; + border: 1px solid black; +} +.pcjs-switches { + float: left; +} +.pcjs-bitBucket { + float: left; + width: 19px; + height: 38px; +} +.pcjs-bitCell { + float: left; + width: 19px; + height: 19px; + margin-right: -1px; + margin-bottom: -1px; + border: 1px solid black; + text-align: center; + line-height: 19px; +} +.pcjs-bitCellLeft { + border-left: 1px solid black; +} +.pcjs-bitLabel { + font-size: xx-small; + text-align: center; +} +.pcjs-description, .pcjs-status { + font-size: x-small; + line-height: 2.0em; +} +.pcjs-key { + border: 1px solid black; + font-size: x-small; + text-align: center; + position: absolute; + height: 34px; + line-height: 34px; + background-color: #ffffff; +} +.pcjs-panel-group { + color: #ffffff; + background-color: #404040; +} +.pcjs-triplet { + padding: 1px; +} +.pcjs-ledlbl { + text-align: center; + font-size: 40%; + background-color: #000000; +} +.pcjs-ledlbl0 { + text-align: right; + font-size: 50%; + background-color: #8d4076; +} +.pcjs-ledlbl1 { + text-align: right; + font-size: 50%; + background-color: #d83662; +} +.pcjs-ledpad { + text-align: center; + font-size: x-small; + line-height: 32px; + background-color: #000000; + border-bottom-left-radius: 20%; + border-bottom-right-radius: 20%; +} +.pcjs-led { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + text-align: center; + vertical-align: middle; + background-color: #000000; +} +.pcjs-rled { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + border-radius: 50%; + text-align: center; + vertical-align: middle; + background-color: #ff0000; + max-width: 50%; + max-height: 50%; +} +.pcjs-swlbl { + text-align: center; + font-size: 40%; + line-height: 16px; + background-color: #000000; + border-top-left-radius: 20%; + border-top-right-radius: 20%; +} +.pcjs-swpad { + height: 32px; + background-color: #000000; +} +.pcjs-switch { + height: 10px; + width: 28px; + margin-top: 0; + max-width: 90%; + background-color: #00ff00; +} +.pcjs-screen { + clear: both; + height: auto; + position: relative; + line-height: 0; +} +.pcjs-screen textarea { + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + opacity: 0; + border: 0; + padding: 0; + line-height: 0; +} +.pcjs-reference { + float: left; + font-size: x-small; +} +.pcjs-reference a { + text-decoration: none; +} +.pcjs-copyright { + float: right; + font-size: x-small; +} +.pcjs-copyright a { + text-decoration: none; +} +@media screen and (max-width: 800px) { + .pcjs-textarea { + width: 100% !important; + } + .pcjs-registers { + width: 100% !important; + max-width: none !important; + padding-left: 0 !important; + padding-right: 0 !important; + } + .pdp11-device { + width: 98% !important; + max-width: none !important; + margin-left: 8px !important; + padding-left: 0 !important; + padding-right: 0 !important; + } +} +@media screen and (min-width: 1200px) { + .machine-left { + max-width: 48%; + float: left; + } + .machine-right { + max-width: 48%; + float: left; + margin-left: 30px; + } + .machine-right + * { + clear: both; + } +} diff --git a/versions/pcx86/1.34.1/components.xsl b/versions/pcx86/1.34.1/components.xsl new file mode 100644 index 000000000..9b977cfb0 --- /dev/null +++ b/versions/pcx86/1.34.1/components.xsl @@ -0,0 +1,1383 @@ + + + +]> + + + + + + + + pc + pcjs + pcx86 + PCx86 + 1.34.1 + www.pcjs.org + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + float: + + + + + + + js + + + +
    + + + + + + + + + + js + + + "" + + + + + +
    +
    + + + + + + + + + + + + + + + , + + + + + + + + + + + + + .machine + . + . + + + + + + + + + + + + + + + + + + + + ,comment:'' + + + + + + border:1px solid black;border-radius:15px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:;max-width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto;clear:both; + position:; + position:relative; + + + + + overflow:auto;width:100%; + background-color:; + + + + - -component + +
    + + + + + + +
    + + + + + + + + --object -screen + + +
    +
    + +
    + +
    +
    + + + + +
    + + +
    [XML]
    + +
    + + +
    +
    +
    +
    + + + + + text-align:center; + + + +

    +
    + + +
    +
    + + + + + + +
    +
    + + + + type:'' + + + binding:'' + + + value:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + clear:both; + position:; + position:relative; + text-align:; + float:left; + + + + + + + + + + + + + + + + + + +
    + + + font-size:; + + + + + -label + + + + width:; + width:; + + + + + + + + text-align:right; + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    +
    + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',rtcDate:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + + + + + + mouse + ,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + xt + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + +
    diff --git a/versions/pcx86/1.34.1/document.css b/versions/pcx86/1.34.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pcx86/1.34.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pcx86/1.34.1/document.xsl b/versions/pcx86/1.34.1/document.xsl new file mode 100644 index 000000000..b240ba5b1 --- /dev/null +++ b/versions/pcx86/1.34.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pcx86/1.34.1/machine.xsl b/versions/pcx86/1.34.1/machine.xsl new file mode 100644 index 000000000..292453cfb --- /dev/null +++ b/versions/pcx86/1.34.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pcx86/1.34.1/manifest.xsl b/versions/pcx86/1.34.1/manifest.xsl new file mode 100644 index 000000000..0b58fdccc --- /dev/null +++ b/versions/pcx86/1.34.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pcx86/1.34.1/outline.xsl b/versions/pcx86/1.34.1/outline.xsl new file mode 100644 index 000000000..55faf1c15 --- /dev/null +++ b/versions/pcx86/1.34.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pcx86/1.34.1/pcx86-dbg.js b/versions/pcx86/1.34.1/pcx86-dbg.js new file mode 100644 index 000000000..065c0cfa0 --- /dev/null +++ b/versions/pcx86/1.34.1/pcx86-dbg.js @@ -0,0 +1,888 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/diskapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/interrupts.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86seg.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86fpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86func.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86help.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86mods.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86ops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86op0f.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/chipset.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/hdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/computer.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/save.js (C) Jeff Parsons 2012-2017 +*/ +var l,aa;function ba(a,b){function c(){}c.prototype=b.prototype;a.prototype=new c;a.prototype.constructor=a;for(var d in b)if(Object.defineProperties){var e=Object.getOwnPropertyDescriptor(b,d);e&&Object.defineProperty(a,d,e)}else a[d]=b[d]} +for(var da="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ea="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this,fa=["Math","trunc"],ga=0;gaa?-b:b};ka!=ja&&null!=ka&&da(ea,ia,{configurable:!0,writable:!0,value:ka}); +var la={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[40,2,9,,253],737280:[80,2,9,,249],1228800:[80,2,15,,249],1474560:[80,2,18,,240],2949120:[80,2,36,,240],21368320:[615,4,17],256256:[77,1,26,128],2494464:[203,2,12,512],5242880:[256,2,40,256],10485760:[512,2,40,256]},n={lp:0,np:1,op:2,hl:3,pp:4,qp:5,rp:6,sp:7,tp:8,up:9,vp:10,wp:11,xp:12,yp:13,zp:14,Ap:15,Bp:16,Cp:17,Dp:18,Ep:19,Fp:20,Gp:21,Hp:22,Ip:23,Jp:24,Kp:25,Lp:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39, +"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,ce:65,ti:66,ui:67,vi:68,E:69,wi:70,xi:71,yi:72,zi:73,Ai:74,Bi:75,Ci:76,Di:77,Ei:78,Fi:79,Gi:80,Q:81,Hi:82,Ii:83,Ji:84,Ki:85,Li:86,Mi:87,Ni:88,Oi:89,eg:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,de:97,vl:98,xl:99,d:100,e:101,Hl:102,Il:103,Jl:104,Kl:105,an:106,k:107,dn:108,hn:109,n:110,qn:111,p:112,q:113,r:114,No:115,t:116,Qo:117,Ro:118,So:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,Mp:127},ma={};ma[173]=n["-"];ma[186]=n[";"];ma[187]=n["="];ma[189]=n["-"];ma[188]=n[","];ma[190]=n["."];ma[191]=n["/"];ma[192]=n["`"];ma[219]=n["["];ma[220]=n["\\"];ma[221]=n["]"];ma[222]=n["'"];var na={};na[n["1"]]=n["!"];na[n["2"]]=n["@"];na[n["3"]]=n["#"];na[n["4"]]=n.$;na[n["5"]]=n["%"];na[n["6"]]=n["^"];na[n["7"]]=n["&"];na[n["8"]]=n["*"];na[n["9"]]=n["("];na[n["0"]]=n[")"];na[186]=n[":"];na[187]=n["+"];na[188]=n["<"];na[189]=n._;na[190]=n[">"]; +na[191]=n["?"];na[192]=n["~"];na[219]=n["{"];na[220]=n["|"];na[221]=n["}"];na[222]=n['"'];na[173]=n._;na[61]=n["+"];na[59]=n[":"]; +function oa(a,b){var c;if(a){b||(b=10);var d=a.charAt(0),e=0a&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function qa(a,b){var c,d="";b?32>=1,f--;return d} +function ra(a,b,c){var d="";if(!b||4>=8;return(c?"0b":"")+d}function sa(a,b,c){b?12"']/g,function(a){return Aa[a]})} +function Ba(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function Ca(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Aa={"&":"&","<":"<",">":">",'"':""","'":"'"},Da={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function Ea(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())}function Ga(a,b){var c=0,d=1,e;for(e in a){if(d>=arguments.length)break;var f=a[e],g=arguments[d++],c=c&~f.nh|g<>a.shift} +function Ia(a,b){var c;if(Array.prototype.indexOf)return a.indexOf(b,c);c=c||0;0>c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;ca?this.be=this.id:(this.xe=this.id.substr(0,a),this.be=this.id.substr(a+1));this.ea={ready:!1,pf:!1,$g:!1,Yb:!1,error:!1};this.pg=null;this.ea.error=!1;this.ic=c||0;this.ba=this.H=this.ka=this.pa=this.Ie=null;ob.push(this)} +function pb(a,b,c){qb[a]&&b&&(qb[a][b]=c)}function hb(a){window&&window.alert(a)}function sb(a){var b=!1;window&&(b=window.confirm(a));return b}function tb(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b=this.x&&a=this.y&&b=c>>2);d?(b=new Ub(a.x,a.y,a.Nc,a.A*b/c|0),a.y+=b.A,a.A-=b.A):(b=new Ub(a.x,a.y,a.Nc*b/c|0,a.A),a.x+=b.Nc,a.Nc-=b.Nc);return b}function Wb(a){nb.call(this,"Panel",a);this.F=this.G=this.L=-1}ba(Wb,nb);l=Wb.prototype;l.Cb=function(a,b,c,d){return this.pa&&this.pa.Cb(a,b,c,d)||this.H&&this.H.Cb(a,b,c,d)||this.B&&this.B.Cb(a,b,c,d)||this.ba&&this.ba.Cb(a,b,c,d)?!0:nb.prototype.Cb.call(this,a,b,c,d)}; +l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.B=Xb(a,"Keyboard")};l.Xb=function(a,b){b||Yb();return!0};l.Wb=function(){return!0};l.Vd=function(a,b){a.button||(this.L=b?0:-1,Zb(this,a,b))};l.tf=function(a){Zb(this,a)}; +function Zb(a,b,c){var d=$b/null.offsetWidth,e=ac/null.offsetHeight,f=null.getBoundingClientRect(),d=(b.clientX-f.left)*d|0;b=(b.clientY-f.top)*e|0;null==c&&(a.L||(a.L=Math.abs(a.F-d)>Math.abs(a.G-b)?1:2),1==a.L?b=a.G:2==a.L&&(d=a.F));a.F=d;a.G=b;if(0<=d&&d<$b&&0<=b&&bd&&(f=d);c= +f;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.ga)){b=c;if(a.context&&a.N&&a.O){e=dc-ec;f=a.N.width;a.O.fillStyle=fc;a.O.fillRect(0,e,f,ec);gc(a,e+hc,a.N,a.O);a.W=a.ha.width/24|0;if(null==b)ic(a,"Mouse over memory to dump");else for(ic(a,q(b,8,!0),null,0,1),d=1;16>=d;d++){for(var g="",h=1;8>=h;h++){var k;k=a.ka;var m=b++;k=k.aa[(m&k.C)>>>k.A].Zd(m&k.D,m);ic(a,q(k,2),null,1);g+=32<=k&&128>k?String.fromCharCode(k):"."}ic(a,g,null,0,1)}a.context.drawImage(a.N,0,e,f,ec,a.Da,a.Ha,a.va,a.za)}a.ga=c}}} +function jc(a,b,c,d){a.A.kf[a.A.$i++]={Ll:b,Hd:c,type:d};return Ga(cc,b,c,0,d)}function gc(a,b,c,d){var e,f=null.style.color,g=a.ta=10;a.C=g;a.I=b;a.J=a.aa=hc;e||(e=a.Z||a.aa+"px "+kc);a.M=a.Z=e;c&&(a.ha=c);d&&(a.D=d,a.la=f||"white")}function ic(a,b,c,d,e){a.D.font=a.M;a.D.fillStyle=a.la;a.D.fillText(b,a.C,a.I);a.C+=a.W;null!=c&&(16!=a.Ca?b=c.toString():(b=8>a.qa?"0x":"",b+=q(c,a.qa)),a.D.fillText(b,a.C,a.I),a.C+=a.W);d&&(a.C+=a.W*d);e&&(a.C=a.ta,a.I+=(a.J+2)*(e||1))} +function Yb(){for(var a=!1,b=Ab(document,"pcx86","panel"),c=0;c>2,lc=ac,dc=ac,fc="black",ec=ac>>1;ab(Yb); +function mc(a,b,c){nb.call(this,"Bus",a);this.H=b;this.ba=c;this.I=a.busWidth||20;this.O=Math.pow(2,this.I);this.N=this.C=this.O-1|0;this.A=32==this.I||20>=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.O/this.B|0;this.W=this.M-1;this.F=[];this.G=[];this.K=this.L=!1;this.Y=[];this.Z=[];a=new x;nc(a,this.ba);this.aa=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.xa)return k.ve+=k.xa-f,k.xa=f,!0;if(f>=k.xa+k.ve){p=k.size-(f-m);p>g&&(p=g);k.ve=f-k.xa+p;f=m+a.B;g-=p;h++;continue}}return qc(a,sc,f,g)}f=new x(f,p,a.B,d,e);nc(f,a.ba,k);a.aa[h++]=f;f=m+a.B;g-=p}return 0>=g?(tc(a.H),a.H.ea.vb||a.status(Math.floor(c/1024)+"Kb "+vc[d]+" at "+q(b)),!0):qc(a,wc,b,c)} +function oc(a,b){32==a.I?b?a.J&&(xc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=yc(a,1048576,1048576),xc(a,1048576,1048576,yc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Bc(a&this.D,a)};function Jc(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.aa[d].Nf(c,b):a.aa[d++].Zd(c,b)|a.aa[d&a.W].Zd(0,b+1)<<8} +l.fc=function(a,b){this.aa[(a&this.C)>>>this.A].Dc(a&this.D,b&255,a)};function Kc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.aa[e].ri(d,c&65535,b):(a.aa[e++].bf(d,c&255,b),a.aa[e&a.W].bf(0,c>>8&255,b+1))}l.wj=function(){return null}; +function Lc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||oc(a,!0);for(var f=0;f>>=f)&k;if(void 0!==g){if(g[0])g[0](b,k,e);a.ba&&a.L!=g[1]&&Uc(a.ba,b,k)}else a.ba&&(Nb(a.ba,a,b,k,e),a.L&&Uc(a.ba,b,k));f+=h<<3;b+=h;c-=h}}function qc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ba?a.ba.message(b):a.log(b):hb(b);return!1}var cc,Vc={Hk:20,count:8,aq:1,type:3},Wc=0,Xc;for(Xc in Vc){var Yc=Vc[Xc];Vc[Xc]={nh:(1<>1),this.X=new Int32Array(this.I,0,c>>2),Ac(this,Fc?Gc:Hc);else{this.X=Array(c>>2);for(e=0;e>2),b=0;b>8,c)};l.oi=function(a,b,c){this.Dc(a++,b&255,c++);this.Dc(a++,b>>8&255,c++);this.Dc(a++,b>>16&255,c++);this.Dc(a,b>>>24,c)};l.xo=function(a){return this.X[a>>2]>>>((a&3)<<3)&255}; +l.Jo=function(a){var b=a>>2;a=(a&3)<<3;var c=this.X[b]>>a;return 24>a?c&65535:c&255|(this.X[b+1]&255)<<8};l.Do=function(a){var b=a>>2;a=(a&3)<<3;var c=this.X[b];a&&(c=c>>>a|this.X[b+1]<<32-a);return c};l.Vo=function(a,b){var c=a>>2;a=(a&3)<<3;this.X[c]=this.X[c]&~(255<>2;a=(a&3)<<3;24>a?this.X[c]=this.X[c]&~(65535<>8);this.Oa=!0}; +l.ap=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.X[c]=b;this.Oa=!0};l.wo=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a)||this.C&&rd(this.C,b,1,!1);return this.Zd(a,b)};l.Io=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a,2)||this.C&&rd(this.C,b,2,!1);return this.Nf(a,b)};l.Co=function(a,b){this.ba&&null!=this.xa&&qd(this.ba,this.xa+a,4)||this.C&&rd(this.C,b,4,!1);return this.ji(a,b)}; +l.Uo=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a)||this.C&&rd(this.C,c,1,!0);this.D?this.cf(0,b,c):this.bf(a,b,c)};l.gp=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a,2)||this.C&&rd(this.C,c,2,!0);this.D?this.cf(0,b,c):this.ri(a,b,c)};l.$o=function(a,b,c){this.ba&&null!=this.xa&&sd(this.ba,this.xa+a,4)||this.C&&rd(this.C,c,4,!0);this.D?this.cf(0,b,c):this.K(a,b,c)};l.zo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Bc(a,b)}; +l.Lo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Mf(a,b)};l.Fo=function(a,b){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.F;return this.pd.Nd(a,b)};l.Xo=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Dc(a,b,c)};l.jp=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Tf(a,b,c)};l.cp=function(a,b,c){this.lb.X[this.A]|=this.F;this.mb.X[this.B]|=this.J;this.pd.Sf(a,b,c)}; +l.Ao=function(a,b){return td(this.C,b,!1).Bc(a,b)};l.Mo=function(a,b){return td(this.C,b,!1).Mf(a,b)};l.Go=function(a,b){return td(this.C,b,!1).Nd(a,b)};l.Yo=function(a,b,c){td(this.C,c,!0).Dc(a,b,c)};l.kp=function(a,b,c){td(this.C,c,!0).Tf(a,b,c)};l.ep=function(a,b,c){td(this.C,c,!0).Sf(a,b,c)};l.vo=function(a){return this.Pa[a]};l.Qk=function(a){return this.Pa[a]};l.yo=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Bc=this.Qk;return this.Pa[a]}; +l.Ho=function(a){return this.G.getUint16(a,!0)};l.Vk=function(a){return a&1?this.Pa[a]|this.Pa[a+1]<<8:this.Rd[a>>1]};l.Ko=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Mf=this.Vk;return a&1?this.Pa[a]|this.Pa[a+1]<<8:this.Rd[a>>1]};l.Bo=function(a){return this.G.getInt32(a,!0)};l.Sk=function(a){return a&3?this.Pa[a]|this.Pa[a+1]<<8|this.Pa[a+2]<<16|this.Pa[a+3]<<24:this.X[a>>2]}; +l.Eo=function(a){this.lb.X[this.A]|=32;this.mb.X[this.B]|=32;this.Nd=this.Sk;return a&3?this.Pa[a]|this.Pa[a+1]<<8|this.Pa[a+2]<<16|this.Pa[a+3]<<24:this.X[a>>2]};l.To=function(a,b){this.Pa[a]=b;this.Oa=!0};l.el=function(a,b){this.Pa[a]=b;this.Oa=!0};l.Wo=function(a,b){this.Pa[a]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Dc=this.el;this.pd.Oa=!0};l.fp=function(a,b){this.G.setUint16(a,b,!0);this.Oa=!0};l.gl=function(a,b){a&1?(this.Pa[a]=b,this.Pa[a+1]=b>>8):this.Rd[a>>1]=b;this.Oa=!0}; +l.ip=function(a,b){a&1?(this.Pa[a]=b,this.Pa[a+1]=b>>8):this.Rd[a>>1]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Tf=this.gl;this.pd.Oa=!0};l.Zo=function(a,b){this.G.setInt32(a,b,!0);this.Oa=!0};l.fl=function(a,b){a&3?(this.Pa[a]=b,this.Pa[a+1]=b>>8,this.Pa[a+2]=b>>16,this.Pa[a+3]=b>>24):this.X[a>>2]=b;this.Oa=!0}; +l.bp=function(a,b){a&3?(this.Pa[a]=b,this.Pa[a+1]=b>>8,this.Pa[a+2]=b>>16,this.Pa[a+3]=b>>24):this.X[a>>2]=b;this.lb.X[this.A]|=32;this.mb.X[this.B]|=96;this.Sf=this.fl;this.pd.Oa=!0};function ud(a){Ob&&!Fc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} +var bd=0,Ec=2,cd=5,ed=6,vd=["black","blue","green","cyan"],vc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),ad=0,gd=[],Ic=[x.prototype.xo,x.prototype.Vo,x.prototype.Jo,x.prototype.hp,x.prototype.Do,x.prototype.ap],pd=[x.prototype.wo,x.prototype.Uo,x.prototype.Io,x.prototype.gp,x.prototype.Co,x.prototype.$o],fd=[x.prototype.zo,x.prototype.Xo,x.prototype.Lo,x.prototype.jp,x.prototype.Fo,x.prototype.cp],dd=[x.prototype.Ao,x.prototype.Yo,x.prototype.Mo,x.prototype.kp,x.prototype.Go,x.prototype.ep]; +if(Ob)var Hc=[x.prototype.vo,x.prototype.To,x.prototype.Ho,x.prototype.fp,x.prototype.Bo,x.prototype.Zo],Gc=[x.prototype.Qk,x.prototype.el,x.prototype.Vk,x.prototype.gl,x.prototype.Sk,x.prototype.fl],wd=[x.prototype.yo,x.prototype.Wo,x.prototype.Ko,x.prototype.ip,x.prototype.Eo,x.prototype.bp]; +function xd(a,b){nb.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.T={};this.T.sd=b;this.T.Kd=c;this.T.rg=Math.round(this.T.sd/1E4)/100;this.T.oe=this.T.rg*this.T.Kd;this.ea.vb=!1;this.ea.ni=!1;this.ea.lf=a.autoStart;this.ea.kj=!1;this.ea.He=!1;this.T.uf=this.T.Te=0;this.T.wf=a.csStart;this.T.Se=a.csInterval;this.T.Ue=a.csStop;this.Ql=this.Uf.bind(this);Jb(this)}ba(xd,nb);l=xd.prototype; +l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.ba=d;for(b=0;b=a.T.Te&&(a.T.Te+=a.T.Se,c=!0);0<=a.T.Ue&&a.T.Ue<=Ed(a)&&(a.T.Se=a.T.Ue=-1,Bd(a),a.Jb(),c=!0);c&&a.P(Ed(a)+" cycles: checksum="+q(a.T.uf))}} +l.Cb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.na[b]=c;a=!0;break;case "run":this.na[b]=c;c.onclick=function(){var a;if(a=d.pa)if(a=d.pa,a.ea.Yb)a=!0;else{var b=null,c,h=tb(a.id);for(c=0;ca.T.rg&&(c=Math.round(c/a.T.Kd));return c}function Ad(a){a.T.Wd=0;a.Dd=a.md=a.zc=a.A=0;Bd(a);Fd(a,1)} +function Fd(a,b,c){var d=!1;if(void 0!==b){.8>a.T.Wd/a.T.oe?b=1:d=!0;a.T.Kd=b;b=a.T.rg*a.T.Kd;if(a.T.oe!=b){a.T.oe=b;b=a.T.oe.toFixed(2)+"Mhz";var e=a.na.setSpeed;e&&(e.textContent=b);a.P("target speed: "+b)}c&&a.pa&&a.pa.ld()}Hd(a,a.md);a.md=0;a.T.Xd=Ka();a.T.pe=0;Id(a);return d} +l.Uf=function(a){if(Lb(this,!0)){if(!this.ea.vb){Fd(this);this.pa&&this.pa.start(this.T.Xd,Ed(this));this.ea.vb=!0;this.ea.ni=!0;this.W&&this.W.start();var b=this.na.run;b&&(b.textContent="Halt");this.pa&&(Nd(this.pa,!0),a&&this.pa.ld(!0))}this.T.th>=this.T.sd&&Id(this,!0);this.T.zf=0;this.T.sg=Ka();this.T.pe&&(a=this.T.sg-this.T.pe,a>this.T.Dj&&(this.T.Xd+=a,this.T.Xd>this.T.sg&&(this.T.Xd=this.T.sg)));try{do{var c=this.ea.He?1:this.T.nn;if(this.W){Od(this.W);var d=this.W;a=c;var e=d.G[0];if(e.le){var f= +(Ed(d.H,d.O)-e.jd)/d.Ba|0,g=Pd(d,0)-f;e.mode==Qd&&(g-=f);var h=g*d.Ba|0;e.mode==Qd&&(h>>=1);a>h&&(a=h)}var c=a,k=this.W;a=c;if(k.A&&k.A[Rd]&Td){var m=k.Z-Ed(k.H,k.O);0m&&(a=m)}c=a}try{this.Lg(c)}catch(w){if("number"!=typeof w)throw w;}var p=this.zc-this.A;this.md+=p;this.T.zf+=p;Hd(this,0,!0);Dd(this,p);this.T.yf-=p;0>=this.T.yf&&(this.T.yf+=this.T.Fj,this.pa&&Ud(this.pa));this.T.xf-=p;0>=this.T.xf&&(this.T.xf+=this.T.Ej,this.pa&&Nd(this.pa));this.T.Ve-=p;if(0>=this.T.Ve){this.T.Ve+=this.T.sh; +break}}while(this.ea.vb)}catch(w){this.Jb();Cd(this);this.pa&&this.pa.stop(Ka(),Ed(this));Lb(this,!1);Gb(this,w.stack||w.message);return}c=setTimeout;d=this.Ql;this.T.pe=Ka();e=this.T.Dj;this.T.zf&&(e=Math.round(e*this.T.zf/this.T.sh));e-=this.T.pe-this.T.sg;if(f=this.T.pe-this.T.Xd)this.T.Wd=Math.round(this.md/(10*f))/100,864E5<=f&&(this.Dd=0,this.W&&Od(this.W,!0),Fd(this));if(0>e||this.T.Wde&&(this.T.Xd-=e),e=0;this.T.th+=this.T.zf;this.T.pe+=e;c(d,e)}else Cd(this),this.pa&&this.pa.stop(Ka(), +Ed(this))};l.Lg=function(){return 0};l.Jb=function(a){Kb(this,!0);this.zc-=this.A;this.A=0;Hd(this,this.md);this.md=0;if(this.ea.vb){this.ea.vb=!1;this.W&&this.W.stop();var b=this.na.run;b&&(b.textContent="Run")}this.ea.complete=a};function Cd(a,b){a.pa&&(Ud(a.pa,b),Nd(a.pa,b))}var Jd=30,Kd=60,Md=2,yd=["power","reset"]; +function Vd(a,b,c,d){this.gc=a;this.ba=a.ba;this.id=b;this.$b=c||"";this.U=0;this.Ka=65535;this.Nb=this.Ka+1;this.Ab=this.qc=this.ext=this.jb=this.type=this.ua=0;this.Lb=-1;this.V=this.Jc=2;this.R=this.wa=65535;this.G=this.mh;this.D=this.dj;this.F=this.fj;this.A={U:-1,ua:0,Ka:0,jb:0,type:0,ext:0,Lb:-1};1==this.id&&(this.Jf=0,this.C=null,this.Pe=!1,this.H=Array(32),this.B=[]);Wd(this,!0,d)}function Xd(a,b){a.B.push(b);return[a.B.length,Yd]}l=Vd.prototype; +l.mh=function(a){this.U=a&65535;return this.ua=this.U<<4};l.qg=function(a,b){var c,d,e=this.gc;a&=65535;a&4?(c=e.Eb.ua,d=c+e.Eb.Ka|0):(c=e.Kb,d=e.Pc);if(c){c=c+(a&65528)|0;if(d-c|0)return e.A-=15,Zd(this,c,a,b);this.id<$d&&y.call(e,b&&this.id==ae?10:13,a&65532)}return-1};l.gn=function(a){var b=this.gc;a=b.Pb+(a<<2);var c=b.ja(a);b.O&=-769;return this.load(b.ja(a+2))+c|0}; +l.fn=function(a){var b=this.gc;a<<=3;var c=b.Pb+a|0;if(7<=(b.cd-c|0))return this.C=!0,a=Zd(this,c,a),-1!==a&&(a+=this.Jf),a;y.call(b,13,a|2);return-1};l.dj=function(a){return this.ua+a|0};l.fj=function(a){return this.ua+a|0};l.cj=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.kg()};l.zl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.kg()};l.kg=function(){y.call(this.gc,13,0);return-1};l.ej=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.lg()}; +l.Al=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.lg()};l.lg=function(){y.call(this.gc,13,0);return-1};function be(a,b,c,d,e){a.U=b;a.ua=d;a.Ka=e;a.Nb=(e>>>0)+1;a.jb=c;a.type=c&7936;a.ext=c>>16&192;a.Lb=(b&4?a.gc.Eb.ua:a.gc.Kb)+(b&65528)|0;a.id>>0)+1;a.jb=e;a.type=e&7936;a.ext=0;a.Lb=b;a.id>>0)+1,a.jb=a.A.jb,a.type=a.A.type,a.ext=a.A.ext,a.Lb=a.A.Lb,a.A.U=-1,Wd(a,!0,!0,!1),a.ua;a.A.U=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.ca){var w=f,k=k|(m&65280)<<16,f=f|(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case ee:var u=a.C;a.Pe=!1;if(u&&c==Yd&&a.B.length){var F=a.B[a.Jf-1];if(F&&!F())return-1}var K=c&3,H=(g&24576)>>13,F=-1,I,T;p||b>= +e.Kb&&b=a.Ab&&(K>a.Ab&&(F=fe(e),ge(e,fe(e),!0),he(e,F),a.Pe=!0),F=0);else{if(256==h||2304==h)return ie(a,c,u)?a.ua:-1;if(1024==h)F=2,T=0,Kh||2048==(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,11,c&65532),-1}break;case ae:if(!p||4096>h||512!=(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,12,c&65532), +-1;break;case ce:u=h&-513;if(!p||256!=u&&2304!=u)return y.call(e,13,c&65532),-1;2304==u&&(a.Si=k+e.ja(k+102)|0,a.tl=k+a.Ka|0);break;case $d:if(!(h&4096)&&768>>0)+1,a.jb=g,a.type=h,a.ext=m,a.Lb=b,Wd(a,!0,!0,!1));return k} +function ie(a,b,c){var d=a.gc,e=a.Ab,f=d.la.U,g=d.la.ua;if(!c){if(!(d.la.type&512))return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb&=-513)}if(-1===d.la.load(b))return!1;var h=d.la.ua;if(!1!==c){if(d.la.type&512)return y.call(d,13,b&65532),!1;d.fb(d.la.Lb+4,d.la.jb|=512)}d.la.type=d.la.type&-513|d.la.jb&512;256==d.la.type||768==d.la.type?(d.fb(g+14,A(d)),d.fb(g+16,re(d)),d.fb(g+18,d.D),d.fb(g+20,d.I),d.fb(g+22,d.L),d.fb(g+24,d.G),d.fb(g+26,z(d)),d.fb(g+28,d.M),d.fb(g+30,d.K),d.fb(g+32,d.J),d.fb(g+ +34,d.oa.U),d.fb(g+36,d.Z.U),d.fb(g+38,d.Y.U),d.fb(g+40,d.Ca.U),d.Eb.load(d.ja(h+42)),se(d,d.ja(h+16)|(c?16384:0)),d.D=d.ja(h+18),d.I=d.ja(h+20),d.L=d.ja(h+22),d.G=d.ja(h+24),d.M=d.ja(h+28),d.K=d.ja(h+30),d.J=d.ja(h+32),d.oa.load(d.ja(h+34)),d.Ca.load(d.ja(h+40)),te(d,d.ja(h+14),d.ja(h+36)),b=38,g=26,a.Ab>>0)+1)}; +function Wd(a,b,c,d){void 0===c&&(c=!!(a.gc.qa&1));a.Oc=!1;if(c)if(a.load=a.qg,a.Cj=a.fn,a.bc=a.cj,a.cc=a.ej,void 0===d&&(d=!!(a.gc.O&131072)),d)a.load=a.G,a.bc=a.D,a.cc=a.F,a.Ab=a.qc=3,a.V=2,a.R=a.wa=65535,a.Ka=65535,a.Nb=a.Ka+1,a.Jc=a.V,a.Lb=-1,a.Pe=!1;else{if(!(a.U&-4))a.bc=a.kg,a.cc=a.lg;else if(a.type&4096){6144==(a.type&6656)&&(a.bc=a.kg);if(a.type&2048||!(a.type&512))a.cc=a.lg;1024==(a.type&3072)&&(a.bc==a.cj&&(a.bc=a.zl),a.cc==a.ej&&(a.cc=a.Al),a.Oc=!0);b&&a.id<$d&&a.U&-4&&-1!==a.Lb&&(c=a.Lb+ +5,d=a.gc.Ia(c),d&1||a.gc.fc(c,d|1))}b&&(a.Ab=a.U&3,a.qc=(a.jb&24576)>>13,80386>a.gc.ca||!(a.ext&64)?(a.V=2,a.R=65535):(a.V=4,a.R=-1),a.Jc=a.V,a.wa=a.R)}else a.load=a.mh,a.Cj=a.gn,a.bc=a.dj,a.cc=a.fj,a.Ab=a.qc=0,a.Lb=-1,a.Pe=!1}var ee=1,qe=2,ae=3,ce=4,$d=6,Yd=1; +function ze(a){var b=+a.model||8088,c;switch(b){default:c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}xd.call(this,a,c);this.ca=b;a=a.stepping;this.we=b+(a?oa(a,16):0);this.Ri=61442;this.Qd=1792;this.si=28672;this.Vf=4;this.Ta=255;this.B=80286<=this.ca?Qb:Pb;this.va=Ae;this.bj=Be;this.ij=Ce;this.nj=De;if(80186<=this.ca&&(this.va=Ae.slice(),this.bj=Be.slice(),this.ij=Ce.slice(),this.Ta=31,this.va[15]=Ee,this.va[96]=Fe,this.va[97]=Ge,this.va[98]=He,this.va[99]=Ee,this.va[100]=Ee,this.va[101]= +Ee,this.va[102]=Ee,this.va[103]=Ee,this.va[104]=Ie,this.va[105]=Je,this.va[106]=Ke,this.va[107]=Le,this.va[108]=Me,this.va[109]=Ne,this.va[110]=Oe,this.va[111]=Pe,this.va[192]=Qe,this.va[193]=Re,this.va[200]=Se,this.va[201]=Te,this.va[241]=Ue,this.bj[7]=Ve,this.ij[7]=Ve,80286<=this.ca)){this.Ri=2;this.Qd|=28672;this.Vf=0;this.va[15]=We;this.Pd=Xe.slice();for(b=0;b=this.we&&(this.Pd[166]=hf,this.Pd[167]=jf)}}this.Yf=[];this.Zf=[];this.ag=0;Ad(this);this.ea.complete=this.ea.jj=!1;this.tj=0;this.sc=this.aa=[];this.qb=this.Ng=this.Db=this.Wf=this.df=this.ef=this.ed=0;kf(this)}ba(ze,xd);function lf(a,b,c,d){b=(d?a.sc:a.aa)[b>>>a.qb];c?--b.ie||od(b):--b.he||nd(b);d&&tc(a)} +function mf(a){var b;if(a.aa===a.sc){a.aa=Array(a.Wf);a.$f=new x(null,0,0,cd,null,a);nc(a.$f,a.ba);for(b=0;b>>20,f=a.sc[(a.Wc+e&a.ef)>>>a.qb],g=f.Nd(e);if(!(g&1))return d||tf.call(a,b,!1,c),a.ff;if(!(g&4)&&3==a.Ma)return d||tf.call(a,b,!0,c),a.ff;var h=(b&4190208)>>>10,g=a.sc[((g&-4096)+h&a.ef)>>>a.qb],k=g.Nd(h);if(!(k&1))return d||tf.call(a,b,!1,c),a.ff;if(!(k&4)&&3==a.Ma)return d||tf.call(a,b,!0,c),a.ff;c=a.sc[((k&-4096)+(b&4095)&a.ef)>>>a.qb];if(d)return c;d=b>>>a.qb;k=a.aa[d];b&=-4096;var m;0>2;b.mb=g;b.B=h>>2;Ob&&Fc&&c.X&&!c.controller&&!c.he&&!c.ie?(b.Pa=c.Pa,b.Rd=c.Rd,b.X=c.X,Ac(b,wd)):(b.F=c?ud(32):0,b.J=c?ud(96):0,Ac(b,fd));nc(b,a.ba,k);a.aa[d]=b;a.Xf.push(d);return b}function uf(a){a.aa!==a.sc&&(a.aa=a.sc,a.$f=null,a.Xf=null,a.ff=null)}l=ze.prototype;l.reset=function(){this.ea.vb&&this.Jb();kf(this);Ad(this);this.ea.error=!1}; +function vf(a,b){var c;switch(b){case 0:c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.G;break;case 4:c=z(a);break;case 5:c=a.M;break;case 6:c=a.K;break;case 7:c=a.J}return c}function wf(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.G=c;break;case 4:he(a,c);break;case 5:a.M=c;break;case 6:a.K=c;break;case 7:a.J=c}} +function kf(a){a.D=0;a.G=0;a.I=0;a.L=0;a.Hc=0;a.M=0;a.K=0;a.J=0;a.vc=!1;a.Ba=a.$a=0;a.bn=[0,0];a.cn=[0,0];a.ya=0;a.sj=0;a.ga=0;a.qa=65520;a.Pb=0;a.cd=1023;a.O=a.lc=0;a.ze=a.hf=a.ye=a.Ae=0;a.Uc=-1;a.Ad=a.Vc=-1;a.Bd=a.ta=-1;a.Z=new Vd(a,ee,"CS");a.Ca=new Vd(a,qe,"DS");a.oa=new Vd(a,qe,"ES");a.Y=new Vd(a,ae,"SS");he(a,0);ge(a,0);if(80386<=a.ca){switch(a.we){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.qa=16;a.Og=0;a.Cd=0;a.Wc=0; +a.Qb=[0,0,0,0,null,null,0,0];a.dg=[null,null,null,null,null,null,0,0];a.Ga=new Vd(a,qe,"FS");a.Ha=new Vd(a,qe,"GS");uf(a)}a.Qg=new Vd(a,0,"NULL");a.Da=a.Ca;a.Rb=a.Y;a.N=a.ha=0;a.C=a.F=-1;a.eb=a.Qg;a.Za=0;if(80286>a.ca)te(a,0,65535);else{a.Kb=0;a.Pc=65535;a.Eb=new Vd(a,5,"LDT",!0);a.la=new Vd(a,ce,"TSS",!0);a.xb=new Vd(a,$d,"VER",!0);te(a,65520,61440);var b,c=A(a);b=a.Z;var d=-65536;80386>b.gc.ca&&(d&=16777215);b=b.ua=d;a.da=b+c|0;a.Pg=(b>>>0)+(a.Z.Ka>>>0)+1}se(a,0);je(a)} +function xf(a){2==a.Jc?(a.Sb=a.ja,a.kc=yf,a.tc=zf,a.kd=Af,2==a.V?(a.ma=Bf,a.za=Cf,a.rb=Df):(a.ma=Ef,a.za=Ff,a.rb=Gf)):(a.Sb=a.ia,a.kc=Hf,a.tc=If,a.kd=Jf,2==a.V?(a.ma=Kf,a.za=Lf,a.rb=Mf):(a.ma=Nf,a.za=Of,a.rb=Pf))}function ke(a,b){a.V!=b&&(a.ha|=1024,a.V=b,a.R=2==b?65535:-1,Qf(a))}function Qf(a){2==a.V?(a.Fb=32768,a.hb=a.ja,a.yb=a.fb,2==a.Jc?(a.ma=Bf,a.za=Cf,a.rb=Df):(a.ma=Kf,a.za=Lf,a.rb=Mf)):(a.Fb=-2147483648,a.hb=a.ia,a.yb=a.ab,2==a.Jc?(a.ma=Ef,a.za=Ff,a.rb=Gf):(a.ma=Nf,a.za=Of,a.rb=Pf))} +function Rf(a){a.Jc=a.Z.Jc;a.wa=a.Z.wa;xf(a);a.V=a.Z.V;a.R=a.Z.R;Qf(a);a.ha&=-3073}l.uj=function(){var a=this.D+this.G+this.I+this.L+z(this)+this.M+this.K+this.J|0;return a=a+A(this)+this.Z.U+this.Ca.U+this.Y.U+this.oa.U+re(this)|0};function Sf(a,b,c){void 0===a.Yf[b]&&(a.Yf[b]=[]);a.Yf[b].push(c)}function Tf(a,b,c){c&&(null==a.Zf[b]&&a.ag++,a.Zf[b]=c)}function Uf(a,b){var c=a.Zf[b];null!=c&&(c(--a.ag),delete a.Zf[b])} +function Vf(a,b){for(var c=a.Qb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Qb[e],g=g&~(d>>2&3);b?a.aa[g>>>a.qb].Gd(g&a.Db,f,a):(g=a.aa[g>>>a.qb],f?--g.ie||od(g):--g.he||nd(g))}c>>=2;d>>=4}}function rd(a,b,c,d){if(!(a.N&8192)&&a.Qb[7]&255){c--;var e=a.Qb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Qb[g]&&b<=a.Qb[g]+h){a.Qb[6]|=1<>=2;f>>=4}}} +function je(a,b,c){void 0===b&&(b=!!(a.qa&1));void 0===c&&(c=!!(a.O&131072));a.nj=b&&!c?Wf:De;Wd(a.Z,!1,b,c);Wd(a.Ca,!1,b,c);Wd(a.Y,!1,b,c);Wd(a.oa,!1,b,c);80386<=a.ca&&(Wd(a.Ga,!1,b,c),Wd(a.Ha,!1,b,c));Rf(a)} +l.save=function(){var a=new Xf(this);a.set(0,[this.D,this.G,this.I,this.L,z(this),this.M,this.K,this.J]);var b=A(this),c=this.Z.save(),d=this.Ca.save(),e=this.Y.save(),f=this.oa.save(),g;null!=this.Kb?(g=[this.qa,this.Kb,this.Pc,this.Pb,this.cd,this.Eb.save(),this.la.save(),this.lc],80386<=this.ca&&(g.push(this.Og),g.push(this.Cd),g.push(this.Wc),g.push(this.Qb),g.push(this.dg))):g=null;b=[b,c,d,e,f,g,re(this)];80386<=this.ca&&(b.push(this.Ga.save()),b.push(this.Ha.save()));a.set(1,b);a.set(2,[this.Da.$b, +this.Rb.$b,this.N,this.ha,this.Za,this.C,this.F]);a.set(3,[0,this.Dd,this.T.Kd]);a.set(4,Lc(this.ka,!!(this.qa&-2147483648)));return a.data()}; +l.restore=function(a){var b=a[0];this.D=b[0];this.G=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.M=b[5];this.K=b[6];this.J=b[7];b=a[1];this.Z.restore(b[1]);this.Ca.restore(b[2]);this.Y.restore(b[3]);this.oa.restore(b[4]);var d=b[5];d&&d.length&&(this.qa=d[0],this.Kb=d[1],this.Pc=d[2],this.Pb=d[3],this.cd=d[4],this.Eb.restore(d[5]),this.la.restore(d[6]),this.lc=d[7],80386<=this.ca&&(this.Og=d[8],this.Cd=d[9],this.Wc=d[10],this.Qb=d[11],this.dg=d[12]),je(this));se(this,b[6]);var d=!1,e;a:{e=this.ka; +var f=a[4],g;for(g=0;g>>0)+(a.Z.Ka>>>0)+1;a.Ma=a.Z.Ab;Rf(a)}function te(a,b,c,d){var e=a.Z;e.Jf=b;e.C=d;b=e.load(c);return-1!==b?($f(a,b+(a.Z.Jf&a.Z.R)),a.Z.Pe):null} +function ag(a,b){b=(a.da>>>0)+b;b>a.Pg&&(8088>=a.ca||a.Z.Ka==a.Z.wa?b=a.Z.ua+(b-a.Pg&a.R):y.call(a,13,0));return b|0}function bg(a){a.da=a.Bd}function z(a){return a.Hc&~a.Y.wa|a.Aa-a.Y.ua}function he(a,b){a.Hc=b;a.Aa=a.Y.ua+(b&a.Y.wa)|0}function cg(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&dg(a),g&2&&eg(a),g&4&&fg(a),g&8&&gg(a),g&16&&hg(a),g&32&&ig(a))}f?(a.ze=d,a.ye=b):(a.ze=b,a.ye=d);a.hf=c;a.Ae=d;a.resultType=e} +function jg(a,b,c,d,e){a.resultType=c|26;a.Ae=b;d?kg(a):lg(a);e?mg(a):ng(a);return b}function og(a,b,c,d){c&d?kg(a):lg(a);(b^c)&d?mg(a):ng(a)}function pg(a){return dg(a)?1:0}function dg(a){a.resultType&1&&(a.O&=-2,(a.ze^(a.ze^a.hf)&(a.hf^a.ye))&a.resultType&-2147450752&&(a.O|=1),a.resultType&=-2);return a.O&1}function eg(a){a.resultType&2&&(a.O&=-5,38505>>((a.Ae^a.Ae>>4)&15)&1&&(a.O|=4),a.resultType&=-3);return a.O&4} +function fg(a){a.resultType&4&&(a.O&=-17,(a.ye^a.ze^a.hf)&16&&(a.O|=16),a.resultType&=-5);return a.O&16}function gg(a){a.resultType&8&&(a.O&=-65,a.Ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.O|=64),a.resultType&=-9);return a.O&64}function hg(a){a.resultType&16&&(a.O&=-129,a.Ae&a.resultType&-2147450752&&(a.O|=128),a.resultType&=-17);return a.O&128} +function ig(a){a.resultType&32&&(a.O&=-2049,(a.ze^a.ye)&(a.hf^a.ye)&a.resultType&-2147450752&&(a.O|=2048),a.resultType&=-33);return a.O&2048}function lg(a){a.resultType&=-2;a.O&=-2}function qg(a){a.resultType&=-5;a.O&=-17}function rg(a){a.resultType&=-9;a.O&=-65}function ng(a){a.resultType&=-33;a.O&=-2049}function kg(a){a.resultType&=-2;a.O|=1}function ug(a){a.resultType&=-5;a.O|=16}function vg(a){a.resultType&=-9;a.O|=64}function mg(a){a.resultType&=-33;a.O|=2048} +function re(a){return a.O&-2262|dg(a)|eg(a)|fg(a)|gg(a)|hg(a)|ig(a)}function wg(a,b){b|=a.qa&1|65520;a.qa=a.qa&-65536|b&65535;a.qa&1&&je(a,!0)}function se(a,b,c){a.qa&1||(b&=~a.si);void 0===c&&(c=a.Ma);c?b=b&-12289|a.O&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.O&512);a.resultType=128;a.O=a.O&~(a.Qd|2261)|b&(a.Qd|2261)|a.Ri;a.O&256&&(a.Za|=2,a.N|=4)} +function xg(a,b,c,d){var e=0;if(a.qa&1&&(a.Ma>a.lc||a.O&131072)&&a.la.Si)for(var f=a.la.Si+(b>>>3),e=(1<>>=8,f++;return e?(t(a,256)&&Mb(a,"checkIOPM("+ta(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),y.call(a,13,0),!1):!0} +l.Cb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.na[b]=c;this.tj++;a=!0;break;default:a=xd.prototype.Cb.call(this,a,b,c)}return a}; +function yg(a,b,c,d){var e=(d?a.sc:a.aa)[(b&a.ed)>>>a.qb];e&&e.type==cd&&(e=td(a,b,!1,!0));if(e){var f=b&a.Db;if(!c||1==c)return e.Zd(f,b);if(2==c)return f>>this.qb].Bc(a&this.Db,a)}; +l.ja=function(a){var b=a&this.Db,c=(a&this.ed)>>>this.qb;this.A-=this.B.zg;if(b>>this.qb;if(b>>this.qb].Dc(a&this.Db,b&255,a)}; +l.fb=function(a,b){var c=a&this.Db,d=(a&this.ed)>>>this.qb;this.A-=this.B.zg;c>8&255,a+1))};l.ab=function(a,b){var c=a&this.Db,d=(a&this.ed)>>>this.qb;this.A-=this.B.zg;if(c>>=8}}; +function zg(a,b,c){a.eb=b;a.wb=c&a.wa;a.C=b.bc(a.wb,1);return a.N&1?0:a.Ia(a.C)}function D(a,b){return zg(a,a.Da,b)}function Ag(a,b){return zg(a,a.Rb,b)}function Bg(a,b,c){a.eb=b;a.wb=c&a.wa;a.C=b.bc(a.wb,a.V);return a.N&1?0:a.hb(a.C)}function E(a,b){a.eb=a.Da;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,2);return a.N&1?0:a.ja(a.C)}function Cg(a,b){a.eb=a.Rb;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,2);return a.N&1?0:a.ja(a.C)}function G(a,b){a.eb=a.Da;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,4);return a.N&1?0:a.ia(a.C)} +function Dg(a,b){a.eb=a.Rb;a.wb=b&a.wa;a.C=a.eb.bc(a.wb,4);return a.N&1?0:a.ia(a.C)}function Eg(a,b){a.N&2||a.fc(a.eb.cc(a.wb,1),b)}function Fg(a,b){a.N&2||a.fb(a.eb.cc(a.wb,2),b)}function Gg(a,b){a.N&2||a.ab(a.eb.cc(a.wb,4),b)}function le(a,b,c){return a.hb(b.bc(c,a.V))}l.ra=function(){var a=ag(this,1),b=this.Ia(this.da);this.da=a;return b};function Hg(a){var b=ag(a,2),c=a.ja(a.da);a.da=b;return c}function J(a){var b=ag(a,a.Jc),c=a.Sb(a.da);a.da=b;return c} +l.Ea=function(){var a=ag(this,this.V),b=this.hb(this.da);this.da=a;return b};l.S=function(){var a=ag(this,1),b=this.Ia(this.da)<<24>>24;this.da=a;return b};function fe(a){var b=a.hb(a.Aa);a.Aa=a.Aa+a.V|0;var c=a.cg-a.Aa|0;0>c&&0<=(a.cg^a.Aa)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?he(a,a.Aa-a.Y.ua&a.Y.wa):-1>c&&y.call(a,12,0));return b} +function me(a,b,c,d){c=a.Aa-c|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(he(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));switch(d){case 1:a.fc(c,b);break;case 2:a.fb(c,b);break;case 4:a.ab(c,b)}a.Aa=c}function pe(a,b){var c=a.Aa-a.V|0;0>(c-a.gf|0)&&0<=(a.gf^c)&&(8088>=a.ca||!a.Y.Oc&&a.Y.Ka==a.Y.wa||a.Y.Oc&&!a.Y.Ka?(he(a,c-a.Y.ua&a.Y.wa),c=a.Aa):y.call(a,12,0));a.yb(c,b);a.Aa=c} +function Ig(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.ca)2this.ca?0:1,e=0;2>e;e++){switch(d){case 0:if(this.Za&1&&this.O&512){var f=Kg(this.W);if(-1<=f&&(this.Za&=-2,0<=f)){this.Za&=-5; +Lg.call(this,f);d=!0;break a}}break;case 1:if(this.Za&2){this.Za&=-3;80386<=this.ca&&(this.Qb[6]|=16384);Lg.call(this,1);d=!0;break a}}d=1-d}d=!1}if(d&&!a){this.P("interrupt dispatched");this.N=0;break}if(this.Za&4){this.N=this.A=0;break}}if(b){if(Mg(this.ba,this.da,c)){this.Jb();break}c=1}this.N=0;this.va[this.ra()].call(this)}while(0>11;ch(this);dh(this,a[b++]);for(c=0;c=eh&&fh(a,gh))}function ch(a){a.fa&=-129;a.fa&~a.Zb&63&&(a.fa|=128);if(a.fa&128&&!(a.Zb&128))return a=a.W,a.ca>=eh?hh(a,gh):a.da&ih||Lg.call(a.H,2),!0;a=a.W;a.ca>=eh&&fh(a,gh);return!1}function jh(a,b){80387<=a.ca||(b&=-65);a.fa|=b;return ch(a)} +function ah(a){return a.fa|a.B<<11}function kh(a,b){return isFinite(b)?!0:!jh(a,Infinity===b?8:16)}function lh(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,kh(a,d)||(d=null));return d}function mh(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,kh(a,d)||(d=null));return d}function nh(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,kh(a,d)||(d=null));return d}function oh(a,b,c){var d=null;null==b||null==c||!c&&jh(a,2)||(d=b/c,kh(a,d)||(d=null));return d} +function ph(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:b||(d=16384));a.fa=a.fa&-18177|d;return!0}return!1}function qh(a,b,c){if(null==b)return null;var d=a.Zb&3072;d?d=1024==d||3072==d&&0=c){if(jh(a,1))return null;d=-c}else if(d<-c){if(jh(a,1))return null;d=-c}a.G[0]=d|0;2147483648d&&(a.G[1]=-1))}return d} +function rh(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function sh(a){var b=a.B+0&7;return a.C&1<>16}function xh(a){return a.H.ia(a.H.C)}function yh(a){a.ha[0]=a.H.ia(a.H.C);return a.Z[0]}function zh(a){a.G[0]=a.H.ia(a.H.C);a.G[1]=a.H.ia(a.H.C+4);return a.K[0]} +function Ah(a){a.D[0]=a.H.ia(a.H.C);a.D[1]=a.H.ia(a.H.C+4);a.D[2]=a.H.ja(a.H.C+8);return a.D}l.mi=function(){this.H.ab(this.H.C,this.G[0])};l.bl=function(){this.H.ab(this.H.C,this.G[0]);this.H.ab(this.H.C+4,this.G[1])};function Bh(a){a.H.ab(a.H.C,a.D[0]);a.H.ab(a.H.C+4,a.D[1]);a.H.fb(a.H.C+8,a.D[2])}function Ch(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.G[0]=b;a.G[1]=c|(d|e)<<20;return a.K[0]} +function vh(a,b,c){var d=c>>20&2047,e=2147483648|(c&1048575)<<11|b>>>21;2047==d?d=32767:d?d+=15360:e&=2147483647;a.D[0]=b<<11;a.D[1]=e;a.D[2]=c>>16&32768|d;return a.D}function Dh(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function Eh(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;ch(a);dh(a,d.hb(b+=d.V));!(d.qa&1)||d.O&131072?(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.O=c&2047,a.I|=(c&-4096)<<4,a.M=-1,a.J=d.hb(b+=d.V),a.J|=(d.hb(b+=d.V)&-4096)<<4,a.N=-1):(a.I=d.hb(b+=d.V),c=d.hb(b+=d.V),a.M=c&65535,a.O=c>>16&2047,a.J=d.hb(b+=d.V),a.N=d.hb(b+=d.V)&65535);return b+d.V} +function Ih(a,b){var c=a.H;c.yb(b,a.Zb);c.yb(b+=c.V,ah(a));c.yb(b+=c.V,bh(a));if(!(c.qa&1)||c.O&131072){var d=(a.M<<4)+a.I;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096|a.O);d=(a.N<<4)+a.J;c.yb(b+=c.V,d);c.yb(b+=c.V,d>>4&-4096)}else c.yb(b+=c.V,a.I),c.yb(b+=c.V,a.M|a.O<<16),c.yb(b+=c.V,a.J),c.yb(b+=c.V,a.N);return b+c.V}function Jh(){this.fa&=-32896;ch(this)}function Kh(){ph(this,M(this,0),M(this,this.A))}function Lh(){ph(this,M(this,0),M(this,this.A))&&Fh(this)}function Mh(){Lh.call(this)} +function Nh(){N(this,0,oh(this,M(this,0),yh(this)))}function Oh(){this.C&=~(1<>20&2047)-1023),this.G[1]=(this.G[1]|1072693248)&-1073741825,Gh(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.fa&=-513},103:function(){this.B= +this.B+1&7;this.fa&=-513},112:function(){N(this,0,M(this,0)%M(this,1))},113:function(){N(this,1,M(this,1)*Math.log(M(this,0)+1)/Math.LN2)&&Fh(this)},114:function(){var a=M(this,0),b=null;if(0<=a||!jh(this,1))b=Math.sqrt(a),kh(this,b)||(b=null);N(this,0,b)},116:function(){N(this,0,qh(this,M(this,0),gi))},117:function(){var a=M(this,0),b=M(this,1);null!=a&&null!=b&&N(this,0,a*Math.pow(2,0>>0);Gh(this,a)},6:function(){var a=qh(this,Fh(this));null!=a&&(this.D[0]=Eh(a,8),this.D[1]=Eh(a/1E8,8),this.D[2]=Eh(a/1E16,2),0>a&&(this.D[2]|=32768),Bh(this))},7:function(){null!=qh(this,M(this,0),gi)&&(this.bl(),Fh(this))},48:function(){Oh.call(this);Fh(this)},49:ai,50:Wh,51:Wh,52:Zh}},ii=[Jh,Ph,Qh,Rh,Sh,Th,Xh,Uh,Yh,Zh];ab(function(){for(var a=Ab(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Ij;(bd)&&y.call(this,5);this.N|=2;return a}function ri(a,b){var c=0;if(b){rg(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else vg(this);this.A-=11+3*c;return a}function si(a,b){var c=0;if(b){rg(this);for(var d=2==this.V?15:31,e=1<>>=1;c++;d--}}else vg(this);this.A-=11+3*c;return a} +function ti(a,b){a&1<<(b&(2==this.V?15:31))?kg(this):lg(this);this.A-=-1===this.C?3:6;this.N|=2;return a}function ui(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a^b}function vi(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a&~b}function wi(a,b){b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=-1===this.C?6:8;return a|b} +function xi(a,b){if(-1===this.C)return ti.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=6;this.N|=2;return a}function yi(a,b){if(-1===this.C)return ui.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a^b} +function zi(a,b){if(-1===this.C)return vi.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a&~b}function Ai(a,b){if(-1===this.C)return wi.call(this,a,b);var c=this.V<<3;if(b>=c||b<-c)a=Bg(this,this.eb,this.wb+(b>>(2==this.V?4:5))*this.V);b=1<<(b&(2==this.V?15:31));a&b?kg(this):lg(this);this.A-=8;return a|b} +function Bi(a,b){cg(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a}function Ci(a,b){cg(this,a,b,a-b|0,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ah:this.B.Ib;this.N|=2;return a} +function Di(a){if(this.Tc){var b=this.Tc,c=this.sj,d=this.ga,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=hi[c][f]){if(0>ii.indexOf(e)){var f=b.H,g=f.Bd;8087==b.ca&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.Z.U;b.I=g-f.Z.ua;-1!==f.C&&(b.N=f.eb.U,b.J=f.C-f.eb.ua);b.O=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function Ei(a){if(80186>this.ca)return Fi.call(this,a);y.call(this,13,0);return a}function Ve(a){y.call(this,6);return a} +function Fi(a){Ye.call(this);return a}function Gi(a,b){a=Hi.call(this,this.S(),b);80386>this.ca&&(this.A-=12);return a}function Ii(a,b){a=this.Ea();a=2==this.V?Hi.call(this,a,b):Ji.call(this,a,b);80386>this.ca&&(this.A-=12);return a}function Ki(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);Li.call(this,a,b);c&&(this.Ba=~this.Ba+1|0,this.$a=~this.$a+(this.Ba?0:1)|0)} +function Hi(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(kg(this),mg(this)):(lg(this),ng(this));this.A-=-1===this.C?9:12;return a&65535}function Ji(a,b){Ki.call(this,a,b);this.$a!=this.Ba>>31?(kg(this),mg(this)):(lg(this),ng(this));this.A-=-1===this.C?9:12;return this.Ba}function Mi(a,b){this.A-=14+(-1===this.C?0:2);rg(this);-1!==this.xb.load(b)&&this.xb.qc>=this.Ma&&this.xb.qc>=(b&3)&&(vg(this),a=this.xb.jb&-256,2=this.Ma)&&this.xb.qc>=(b&3))return vg(this),this.xb.Ka;rg(this);return a}function cj(a,b){if(-1===this.C)return Ye.call(this),a;ge(this,this.ja(this.C+this.V));this.A-=this.B.Xe;return b} +function dj(a,b){this.A-=-1===this.F?-1===this.C?this.B.sk:this.B.rk:this.B.pk;return b}function ej(a,b){switch(this.ga>>3&7){case 4:this.ya=this.D;break;case 5:this.ya=this.I;break;case 6:this.ya=this.L;break;case 7:this.ya=this.G}return b}function fj(a,b){return b} +function gj(a,b){a=this.ga>>3&7;switch(a){case 0:this.ya=this.D;break;case 2:this.ya=this.L;break;case 3:this.ya=this.G;break;default:if(80286==this.ca||80386==this.ca&&4!=a&&5!=a)y.call(this,6);else switch(a){case 1:this.ya=this.I;break;case 4:this.ya=z(this);break;case 5:this.ya=this.M;break;case 6:this.ya=this.K;break;case 7:this.ya=this.J}}return dj.call(this,0,b)} +function hj(a,b){switch(this.ga>>3&7){case 0:b=this.oa.U;break;case 1:b=this.Z.U;break;case 2:b=this.Y.U;break;case 3:b=this.Ca.U;break;case 4:if(80386<=this.ca){b=this.Ga.U;break}y.call(this,6);b=a;break;case 5:if(80386<=this.ca){b=this.Ha.U;break}default:y.call(this,6),b=a}-1!==this.F&&ke(this,2);return dj.call(this,0,b)} +function Li(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d,d=(e>>>16)+b*d,f=d>>>16,d=(d&65535)+c*a;this.Ba=d<<16|e&65535;this.$a=f+((d>>>16)+b*a)|0}else this.Ba=a*b|0,this.$a=0}function ij(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a|b,128)}function jj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a|b,this.Fb)&this.R} +function kj(a,b){var c=a-b-pg(this)|0;cg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255}function lj(a,b){var c=a-b-pg(this)|0;cg(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function mj(){return ig(this)?1:0}function nj(){return dg(this)?1:0}function oj(){return dg(this)?0:1}function pj(){return gg(this)?1:0}function qj(){return gg(this)?0:1}function rj(){return dg(this)||gg(this)?1:0} +function sj(){return dg(this)||gg(this)?0:1}function tj(){return hg(this)?1:0}function uj(){return hg(this)?0:1}function vj(){return eg(this)?1:0}function wj(){return eg(this)?0:1}function xj(){return!hg(this)!=!ig(this)?1:0}function yj(){return!hg(this)!=!ig(this)?0:1}function zj(){return gg(this)||!hg(this)!=!ig(this)?1:0}function Aj(){return gg(this)||!hg(this)!=!ig(this)?0:1}function Bj(a,b){return Cj.call(this,a,b,this.ra())}function Dj(a,b){return Ej.call(this,a,b,this.ra())} +function Fj(a,b){return Cj.call(this,a,b,this.I&31)}function Gj(a,b){return Ej.call(this,a,b,this.I&31)}function Hj(a,b){return Ij.call(this,a,b,this.ra())}function Jj(a,b){return Kj.call(this,a,b,this.ra())}function Lj(a,b){return Ij.call(this,a,b,this.I&31)}function Mj(a,b){return Kj.call(this,a,b,this.I&31)}function Nj(a,b){var c=a-b|0;cg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&255} +function Oj(a,b){var c=a-b|0;cg(this,a,b,c,this.Fb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return c&this.R}function Pj(a,b){jg(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Qj(a,b){jg(this,a&b,this.Fb);this.A-=-1===this.F?-1===this.C?this.B.bi:this.B.Gf:this.B.Gf;this.N|=2;return a}function Rj(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Tj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}this.A-=this.B.di}else this.F=this.C,Eg(this,a),this.A-=this.B.ci;return b} +function Uj(a,b){if(-1===this.C){switch(this.ga&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.G=this.G&~this.R|a;break;case 4:he(this,z(this)&~this.R|a);break;case 5:this.M=this.G&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.di}else this.F=this.C,this.N&2||this.yb(this.eb.cc(this.wb,this.V),a),this.A-=this.B.ci;return b} +function Vj(a,b){a^=b;jg(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return a}function Wj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Ib:this.B.Ac;return jg(this,a^b,this.Fb)&this.R}function Xj(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function Yj(a){var b=a-1|0;cg(this,a,1,b,this.Fb|62,!0);this.A-=2;return a&~this.R|b&this.R} +function Zj(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.bn;f[0]=c>>>0;f[1]=0;c=this.cn;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=Xj(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ba=d;this.$a=c[0];return!0}function ak(a){var b=a+1|0;cg(this,a,1,b,this.Fb|62);this.A-=2;return a&~this.R|b&this.R} +function bk(a){this.qa=a;je(this);this.qa&-2147483648?mf(this):uf(this)}function ue(a){this.Wc=a;tc(this)}function ck(a){this.N|=1;this.tc.call(this,a);this.A-=-1===this.C?4:5}function Cj(a,b,c){if(c){16>>16-c)&65535;jg(this,a,32768,d&32768)}return a}function Ej(a,b,c){if(c){var d=a<>>32-c;jg(this,a,-2147483648,d&-2147483648)}return a} +function Ij(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;jg(this,a,32768,d&1)}return a}function Kj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;jg(this,a,-2147483648,d&1)}return a}function dk(){this.A-=-1===this.C?2:this.B.Fk;return 1}function ek(){var a=this.I&255;this.A-=(-1===this.C?this.B.Vh:this.B.Uh)+(a<this.Uc?(-1!=this.Ad&&(this.Ad!==this.Z.U&&(this.Z.Ab=this.Ad&3,Zf(this,this.Ad)),this.Ad=-1),this.Bd!==this.da&&$f(this,this.Bd),-1!=this.Vc&&(this.Vc!==this.Y.U&&ge(this,this.Vc),this.Vc=-1),-1!==this.ta&&(this.ta!==this.Aa&&he(this,this.Hc&~this.Y.wa|this.ta-this.Y.ua),this.ta=-1)):8!=this.Uc?(b=0,a=8):(b=0,a=-1,kf(this),e=d=!1)):$f(this,this.Bd);var f=a,g=b,h=32,k=yg(this,this.da);204!=k||this.cd||(d=!1);this.O&131072&&(6== +f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.da&&1048575>=this.da&&(d=!1);t(this,h|-2147483648)&&(d=!0);if(t(this,h)||d){var m=this.ea.vb,f="Fault "+r(f)+(null!=g?" ("+ta(g)+")":"")+" on opcode "+r(k);d&&m&&(f+=" (blocked)");this.ba?(Mb(this,f,d||h,!0),d&&(d=m,this.ba.Jb())):(this.Fa(f),this.Jb())}if(d&&e)throw-1;if(e)throw this.Uc=a,jk.call(this,a,b,c),this.Bd=this.da,this.N=1==a?this.N|8192:this.N|4096,a;} +function tf(a,b,c){this.Cd=a;a=0;b&&(a|=1);c&&(a|=2);3==this.Ma&&(a|=4);y.call(this,14,a)}function lk(a){var b=a.jb&7680;a.U&65528&&(6144==b||7168==b||7168>b&&a.qc>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&255;break;case 1:b=this.I&255;break;case 2:b=this.L&255;break;case 3:b=this.G&255;break;case 4:b=this.D>>8&255;break;case 5:b=this.I>>8&255;break;case 6:b=this.L>>8&255;break;case 7:b=this.G>>8&255;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= +this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} +function zf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.G+this.K);this.F=this.C;break;case 1:b=D(this,this.G+this.J);this.F=this.C;break;case 2:b=Ag(this,this.M+this.K);this.F=this.C;break;case 3:b=Ag(this,this.M+this.J);this.F=this.C;break;case 4:b=D(this,this.K);this.F=this.C;break;case 5:b=D(this,this.J);this.F=this.C;break;case 6:b=D(this,J(this));this.F=this.C;break;case 7:b=D(this,this.G);this.F=this.C;break;case 64:b=D(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Ag(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Ag(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=D(this,this.K+this.S());this.F=this.C;break;case 69:b=D(this,this.J+this.S());this.F=this.C;break;case 70:b=Ag(this,this.M+this.S());this.F=this.C;break;case 71:b=D(this,this.G+this.S());this.F=this.C;break;case 128:b=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=D(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Ag(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Ag(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=D(this,this.K+J(this));this.F=this.C;break;case 133:b=D(this,this.J+J(this));this.F=this.C;break;case 134:b=Ag(this,this.M+J(this));this.F=this.C;break;case 135:b=D(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break; +case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.G>>8&255;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&255;break;case 1:c=this.I&255;break;case 2:c=this.L&255;break;case 3:c=this.G&255;break;case 4:c=this.D>>8&255;break;case 5:c=this.I>>8&255;break;case 6:c=this.L>>8&255;break;case 7:c=this.G>>8&255;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Eg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Eg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Eg(this, +a);this.A-=this.B.wc;break;case 6:Eg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Eg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Eg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Eg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= +this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} +function Af(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.G+this.K);this.F=this.C;break;case 1:c=D(this,this.G+this.J);this.F=this.C;break;case 2:c=Ag(this,this.M+this.K);this.F=this.C;break;case 3:c=Ag(this,this.M+this.J);this.F=this.C;break;case 4:c=D(this,this.K);this.F=this.C;break;case 5:c=D(this,this.J);this.F=this.C;break;case 6:c=D(this,J(this));this.F=this.C;break;case 7:c=D(this,this.G);this.F=this.C;break;case 64:c=D(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=D(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Ag(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Ag(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=D(this,this.K+this.S());this.F=this.C;break;case 69:c=D(this,this.J+this.S());this.F=this.C;break;case 70:c=Ag(this,this.M+this.S());this.F=this.C;break;case 71:c=D(this,this.G+this.S());this.F=this.C;break;case 128:c=D(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=D(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Ag(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Ag(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=D(this,this.K+J(this));this.F=this.C;break;case 133:c=D(this,this.J+J(this));this.F=this.C;break;case 134:c=Ag(this,this.M+J(this));this.F=this.C;break;case 135:c=D(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break; +case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Eg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Eg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Eg(this,a);this.A-=this.B.wc;break;case 6:Eg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Eg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Eg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Eg(this, +a);this.A-=this.B.Va;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} +function Bf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=E(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=Cg(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=Cg(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=E(this,this.K);this.A-=this.B.wc;break;case 5:c=E(this,this.J);this.A-=this.B.wc;break;case 6:c=E(this,J(this));this.A-=this.B.td;break;case 7:c=E(this,this.G);this.A-=this.B.wc;break;case 64:c=E(this,this.G+this.K+ +this.S());this.A-=this.B.Tb;break;case 65:c=E(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=Cg(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=Cg(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=E(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=E(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=Cg(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=E(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=E(this,this.G+this.K+J(this)); +this.A-=this.B.Tb;break;case 129:c=E(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=Cg(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=Cg(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=E(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=E(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=Cg(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=E(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D&65535;break;case 193:c=this.I& +65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&65535;break;case 1:b=this.I&65535;break;case 2:b=this.L&65535;break;case 3:b=this.G&65535;break;case 4:b=z(this)&65535;break;case 5:b=this.M&65535;break;case 6:b=this.K&65535;break;case 7:b=this.J&65535;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:he(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Cf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.G+this.K);this.F=this.C;break;case 1:b=E(this,this.G+this.J);this.F=this.C;break;case 2:b=Cg(this,this.M+this.K);this.F=this.C;break;case 3:b=Cg(this,this.M+this.J);this.F=this.C;break;case 4:b=E(this,this.K);this.F=this.C;break;case 5:b=E(this,this.J);this.F=this.C;break;case 6:b=E(this,J(this));this.F=this.C;break;case 7:b=E(this,this.G);this.F=this.C;break;case 64:b=E(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Cg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Cg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=E(this,this.K+this.S());this.F=this.C;break;case 69:b=E(this,this.J+this.S());this.F=this.C;break;case 70:b=Cg(this,this.M+this.S());this.F=this.C;break;case 71:b=E(this,this.G+this.S());this.F=this.C;break;case 128:b=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=E(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Cg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Cg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=E(this,this.K+J(this));this.F=this.C;break;case 133:b=E(this,this.J+J(this));this.F=this.C;break;case 134:b=Cg(this,this.M+J(this));this.F=this.C;break;case 135:b=E(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535; +break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break;case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Fg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Fg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Fg(this, +a);this.A-=this.B.wc;break;case 6:Fg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Fg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Fg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Fg(this,a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break; +case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} +function Df(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.G+this.K);this.F=this.C;break;case 1:c=E(this,this.G+this.J);this.F=this.C;break;case 2:c=Cg(this,this.M+this.K);this.F=this.C;break;case 3:c=Cg(this,this.M+this.J);this.F=this.C;break;case 4:c=E(this,this.K);this.F=this.C;break;case 5:c=E(this,this.J);this.F=this.C;break;case 6:c=E(this,J(this));this.F=this.C;break;case 7:c=E(this,this.G);this.F=this.C;break;case 64:c=E(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=E(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Cg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Cg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=E(this,this.K+this.S());this.F=this.C;break;case 69:c=E(this,this.J+this.S());this.F=this.C;break;case 70:c=Cg(this,this.M+this.S());this.F=this.C;break;case 71:c=E(this,this.G+this.S());this.F=this.C;break;case 128:c=E(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=E(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Cg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Cg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=E(this,this.K+J(this));this.F=this.C;break;case 133:c=E(this,this.J+J(this));this.F=this.C;break;case 134:c=Cg(this,this.M+J(this));this.F=this.C;break;case 135:c=E(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535; +break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Fg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Fg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Fg(this,a);this.A-=this.B.wc;break;case 6:Fg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Fg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Fg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Fg(this, +a);this.A-=this.B.Va;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} +function Ef(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.G+this.K);this.A-=this.B.Rc;break;case 1:c=G(this,this.G+this.J);this.A-=this.B.Sc;break;case 2:c=Dg(this,this.M+this.K);this.A-=this.B.Sc;break;case 3:c=Dg(this,this.M+this.J);this.A-=this.B.Rc;break;case 4:c=G(this,this.K);this.A-=this.B.wc;break;case 5:c=G(this,this.J);this.A-=this.B.wc;break;case 6:c=G(this,J(this));this.A-=this.B.td;break;case 7:c=G(this,this.G);this.A-=this.B.wc;break;case 64:c=G(this,this.G+this.K+ +this.S());this.A-=this.B.Tb;break;case 65:c=G(this,this.G+this.J+this.S());this.A-=this.B.Ub;break;case 66:c=Dg(this,this.M+this.K+this.S());this.A-=this.B.Ub;break;case 67:c=Dg(this,this.M+this.J+this.S());this.A-=this.B.Tb;break;case 68:c=G(this,this.K+this.S());this.A-=this.B.Va;break;case 69:c=G(this,this.J+this.S());this.A-=this.B.Va;break;case 70:c=Dg(this,this.M+this.S());this.A-=this.B.Va;break;case 71:c=G(this,this.G+this.S());this.A-=this.B.Va;break;case 128:c=G(this,this.G+this.K+J(this)); +this.A-=this.B.Tb;break;case 129:c=G(this,this.G+this.J+J(this));this.A-=this.B.Ub;break;case 130:c=Dg(this,this.M+this.K+J(this));this.A-=this.B.Ub;break;case 131:c=Dg(this,this.M+this.J+J(this));this.A-=this.B.Tb;break;case 132:c=G(this,this.K+J(this));this.A-=this.B.Va;break;case 133:c=G(this,this.J+J(this));this.A-=this.B.Va;break;case 134:c=Dg(this,this.M+J(this));this.A-=this.B.Va;break;case 135:c=G(this,this.G+J(this));this.A-=this.B.Va;break;case 192:c=this.D;break;case 193:c=this.I;break; +case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:he(this, +a);break;case 5:this.M=a;break;case 6:this.K=a;break;case 7:this.J=a}} +function Ff(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.G+this.K);this.F=this.C;break;case 1:b=G(this,this.G+this.J);this.F=this.C;break;case 2:b=Dg(this,this.M+this.K);this.F=this.C;break;case 3:b=Dg(this,this.M+this.J);this.F=this.C;break;case 4:b=G(this,this.K);this.F=this.C;break;case 5:b=G(this,this.J);this.F=this.C;break;case 6:b=G(this,J(this));this.F=this.C;break;case 7:b=G(this,this.G);this.F=this.C;break;case 64:b=G(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:b=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:b=Dg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:b=Dg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:b=G(this,this.K+this.S());this.F=this.C;break;case 69:b=G(this,this.J+this.S());this.F=this.C;break;case 70:b=Dg(this,this.M+this.S());this.F=this.C;break;case 71:b=G(this,this.G+this.S());this.F=this.C;break;case 128:b=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:b=G(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:b=Dg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:b=Dg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:b=G(this,this.K+J(this));this.F=this.C;break;case 133:b=G(this,this.J+J(this));this.F=this.C;break;case 134:b=Dg(this,this.M+J(this));this.F=this.C;break;case 135:b=G(this,this.G+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break; +case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 0:case 3:Gg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Gg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Gg(this,a);this.A-=this.B.wc;break;case 6:Gg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Gg(this, +a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Gg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Gg(this,a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Gf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.G+this.K);this.F=this.C;break;case 1:c=G(this,this.G+this.J);this.F=this.C;break;case 2:c=Dg(this,this.M+this.K);this.F=this.C;break;case 3:c=Dg(this,this.M+this.J);this.F=this.C;break;case 4:c=G(this,this.K);this.F=this.C;break;case 5:c=G(this,this.J);this.F=this.C;break;case 6:c=G(this,J(this));this.F=this.C;break;case 7:c=G(this,this.G);this.F=this.C;break;case 64:c=G(this,this.G+this.K+this.S());this.F=this.C;break; +case 65:c=G(this,this.G+this.J+this.S());this.F=this.C;break;case 66:c=Dg(this,this.M+this.K+this.S());this.F=this.C;break;case 67:c=Dg(this,this.M+this.J+this.S());this.F=this.C;break;case 68:c=G(this,this.K+this.S());this.F=this.C;break;case 69:c=G(this,this.J+this.S());this.F=this.C;break;case 70:c=Dg(this,this.M+this.S());this.F=this.C;break;case 71:c=G(this,this.G+this.S());this.F=this.C;break;case 128:c=G(this,this.G+this.K+J(this));this.F=this.C;break;case 129:c=G(this,this.G+this.J+J(this)); +this.F=this.C;break;case 130:c=Dg(this,this.M+this.K+J(this));this.F=this.C;break;case 131:c=Dg(this,this.M+this.J+J(this));this.F=this.C;break;case 132:c=G(this,this.K+J(this));this.F=this.C;break;case 133:c=G(this,this.J+J(this));this.F=this.C;break;case 134:c=Dg(this,this.M+J(this));this.F=this.C;break;case 135:c=G(this,this.G+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break; +case 198:c=this.K;break;case 199:c=this.J}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 0:case 3:Gg(this,a);this.A-=this.B.Rc;break;case 1:case 2:Gg(this,a);this.A-=this.B.Sc;break;case 4:case 5:case 7:Gg(this,a);this.A-=this.B.wc;break;case 6:Gg(this,a);this.A-=this.B.td;break;case 64:case 67:case 128:case 131:Gg(this,a);this.A-=this.B.Tb;break;case 65:case 66:case 129:case 130:Gg(this,a);this.A-=this.B.Ub;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Gg(this, +a);this.A-=this.B.Va;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Hf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=D(this,this.D);break;case 1:c=D(this,this.I);break;case 2:c=D(this,this.L);break;case 3:c=D(this,this.G);break;case 4:c=D(this,nk.call(this,0));break;case 5:c=D(this,J(this));break;case 6:c=D(this,this.K);break;case 7:c=D(this,this.J);break;case 64:c=D(this,this.D+this.S());break;case 65:c=D(this,this.I+this.S());break;case 66:c=D(this,this.L+this.S());break;case 67:c=D(this,this.G+this.S());break;case 68:c=D(this,nk.call(this,1)+this.S()); +break;case 69:c=Ag(this,this.M+this.S());break;case 70:c=D(this,this.K+this.S());break;case 71:c=D(this,this.J+this.S());break;case 128:c=D(this,this.D+J(this));break;case 129:c=D(this,this.I+J(this));break;case 130:c=D(this,this.L+J(this));break;case 131:c=D(this,this.G+J(this));break;case 132:c=D(this,nk.call(this,2)+J(this));break;case 133:c=Ag(this,this.M+J(this));break;case 134:c=D(this,this.K+J(this));break;case 135:c=D(this,this.J+J(this));break;case 192:c=this.D&255;break;case 193:c=this.I& +255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&255;break;case 1:b=this.I&255;break;case 2:b=this.L&255;break;case 3:b=this.G&255;break;case 4:b=this.D>>8&255;break;case 5:b=this.I>>8&255;break;case 6:b=this.L>>8&255;break;case 7:b=this.G>>8&255;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= +this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} +function If(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=D(this,this.D);this.F=this.C;break;case 1:b=D(this,this.I);this.F=this.C;break;case 2:b=D(this,this.L);this.F=this.C;break;case 3:b=D(this,this.G);this.F=this.C;break;case 4:b=D(this,nk.call(this,0));this.F=this.C;break;case 5:b=D(this,J(this));this.F=this.C;break;case 6:b=D(this,this.K);this.F=this.C;break;case 7:b=D(this,this.J);this.F=this.C;break;case 64:b=D(this,this.D+this.S());this.F=this.C;break;case 65:b=D(this,this.I+this.S()); +this.F=this.C;break;case 66:b=D(this,this.L+this.S());this.F=this.C;break;case 67:b=D(this,this.G+this.S());this.F=this.C;break;case 68:b=D(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Ag(this,this.M+this.S());this.F=this.C;break;case 70:b=D(this,this.K+this.S());this.F=this.C;break;case 71:b=D(this,this.J+this.S());this.F=this.C;break;case 128:b=D(this,this.D+J(this));this.F=this.C;break;case 129:b=D(this,this.I+J(this));this.F=this.C;break;case 130:b=D(this,this.L+J(this));this.F= +this.C;break;case 131:b=D(this,this.G+J(this));this.F=this.C;break;case 132:b=D(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Ag(this,this.M+J(this));this.F=this.C;break;case 134:b=D(this,this.K+J(this));this.F=this.C;break;case 135:b=D(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&255;break;case 193:b=this.I&255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.D>>8&255;break;case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b= +this.G>>8&255;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&255;break;case 1:c=this.I&255;break;case 2:c=this.L&255;break;case 3:c=this.G&255;break;case 4:c=this.D>>8&255;break;case 5:c=this.I>>8&255;break;case 6:c=this.L>>8&255;break;case 7:c=this.G>>8&255;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= +this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:Eg(this,a)}} +function Jf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=D(this,this.D);this.F=this.C;break;case 1:c=D(this,this.I);this.F=this.C;break;case 2:c=D(this,this.L);this.F=this.C;break;case 3:c=D(this,this.G);this.F=this.C;break;case 4:c=D(this,nk.call(this,0));this.F=this.C;break;case 5:c=D(this,J(this));this.F=this.C;break;case 6:c=D(this,this.K);this.F=this.C;break;case 7:c=D(this,this.J);this.F=this.C;break;case 64:c=D(this,this.D+this.S());this.F=this.C;break;case 65:c=D(this,this.I+this.S()); +this.F=this.C;break;case 66:c=D(this,this.L+this.S());this.F=this.C;break;case 67:c=D(this,this.G+this.S());this.F=this.C;break;case 68:c=D(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Ag(this,this.M+this.S());this.F=this.C;break;case 70:c=D(this,this.K+this.S());this.F=this.C;break;case 71:c=D(this,this.J+this.S());this.F=this.C;break;case 128:c=D(this,this.D+J(this));this.F=this.C;break;case 129:c=D(this,this.I+J(this));this.F=this.C;break;case 130:c=D(this,this.L+J(this));this.F= +this.C;break;case 131:c=D(this,this.G+J(this));this.F=this.C;break;case 132:c=D(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Ag(this,this.M+J(this));this.F=this.C;break;case 134:c=D(this,this.K+J(this));this.F=this.C;break;case 135:c=D(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c= +this.G>>8&255;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:Eg(this,a)}} +function Kf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=E(this,this.D);break;case 1:c=E(this,this.I);break;case 2:c=E(this,this.L);break;case 3:c=E(this,this.G);break;case 4:c=E(this,nk.call(this,0));break;case 5:c=E(this,J(this));break;case 6:c=E(this,this.K);break;case 7:c=E(this,this.J);break;case 64:c=E(this,this.D+this.S());break;case 65:c=E(this,this.I+this.S());break;case 66:c=E(this,this.L+this.S());break;case 67:c=E(this,this.G+this.S());break;case 68:c=E(this,nk.call(this,1)+this.S()); +break;case 69:c=Cg(this,this.M+this.S());break;case 70:c=E(this,this.K+this.S());break;case 71:c=E(this,this.J+this.S());break;case 128:c=E(this,this.D+J(this));break;case 129:c=E(this,this.I+J(this));break;case 130:c=E(this,this.L+J(this));break;case 131:c=E(this,this.G+J(this));break;case 132:c=E(this,nk.call(this,2)+J(this));break;case 133:c=Cg(this,this.M+J(this));break;case 134:c=E(this,this.K+J(this));break;case 135:c=E(this,this.J+J(this));break;case 192:c=this.D&65535;break;case 193:c=this.I& +65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D&65535;break;case 1:b=this.I&65535;break;case 2:b=this.L&65535;break;case 3:b=this.G&65535;break;case 4:b=z(this)&65535;break;case 5:b=this.M&65535;break;case 6:b=this.K&65535;break;case 7:b=this.J&65535;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D= +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:he(this,z(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Lf(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=E(this,this.D);this.F=this.C;break;case 1:b=E(this,this.I);this.F=this.C;break;case 2:b=E(this,this.L);this.F=this.C;break;case 3:b=E(this,this.G);this.F=this.C;break;case 4:b=E(this,nk.call(this,0));this.F=this.C;break;case 5:b=E(this,J(this));this.F=this.C;break;case 6:b=E(this,this.K);this.F=this.C;break;case 7:b=E(this,this.J);this.F=this.C;break;case 64:b=E(this,this.D+this.S());this.F=this.C;break;case 65:b=E(this,this.I+this.S()); +this.F=this.C;break;case 66:b=E(this,this.L+this.S());this.F=this.C;break;case 67:b=E(this,this.G+this.S());this.F=this.C;break;case 68:b=E(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Cg(this,this.M+this.S());this.F=this.C;break;case 70:b=E(this,this.K+this.S());this.F=this.C;break;case 71:b=E(this,this.J+this.S());this.F=this.C;break;case 128:b=E(this,this.D+J(this));this.F=this.C;break;case 129:b=E(this,this.I+J(this));this.F=this.C;break;case 130:b=E(this,this.L+J(this));this.F= +this.C;break;case 131:b=E(this,this.G+J(this));this.F=this.C;break;case 132:b=E(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Cg(this,this.M+J(this));this.F=this.C;break;case 134:b=E(this,this.K+J(this));this.F=this.C;break;case 135:b=E(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=z(this)&65535;break;case 197:b=this.M&65535;break;case 198:b=this.K&65535;break; +case 199:b=this.J&65535;break;default:b=0}switch(this.ga>>3&7){case 0:c=this.D&65535;break;case 1:c=this.I&65535;break;case 2:c=this.L&65535;break;case 3:c=this.G&65535;break;case 4:c=z(this)&65535;break;case 5:c=this.M&65535;break;case 6:c=this.K&65535;break;case 7:c=this.J&65535;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)& +-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Fg(this,a)}} +function Mf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=E(this,this.D);this.F=this.C;break;case 1:c=E(this,this.I);this.F=this.C;break;case 2:c=E(this,this.L);this.F=this.C;break;case 3:c=E(this,this.G);this.F=this.C;break;case 4:c=E(this,nk.call(this,0));this.F=this.C;break;case 5:c=E(this,J(this));this.F=this.C;break;case 6:c=E(this,this.K);this.F=this.C;break;case 7:c=E(this,this.J);this.F=this.C;break;case 64:c=E(this,this.D+this.S());this.F=this.C;break;case 65:c=E(this,this.I+this.S()); +this.F=this.C;break;case 66:c=E(this,this.L+this.S());this.F=this.C;break;case 67:c=E(this,this.G+this.S());this.F=this.C;break;case 68:c=E(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Cg(this,this.M+this.S());this.F=this.C;break;case 70:c=E(this,this.K+this.S());this.F=this.C;break;case 71:c=E(this,this.J+this.S());this.F=this.C;break;case 128:c=E(this,this.D+J(this));this.F=this.C;break;case 129:c=E(this,this.I+J(this));this.F=this.C;break;case 130:c=E(this,this.L+J(this));this.F= +this.C;break;case 131:c=E(this,this.G+J(this));this.F=this.C;break;case 132:c=E(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Cg(this,this.M+J(this));this.F=this.C;break;case 134:c=E(this,this.K+J(this));this.F=this.C;break;case 135:c=E(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=z(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.K&65535;break; +case 199:c=this.J&65535;break;default:c=0}a=a[this.ga>>3&7].call(this,c,b.call(this));switch(d){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:he(this,z(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Fg(this,a)}} +function Nf(a){var b,c;switch((this.ga=this.ra())&199){case 0:c=G(this,this.D);break;case 1:c=G(this,this.I);break;case 2:c=G(this,this.L);break;case 3:c=G(this,this.G);break;case 4:c=G(this,nk.call(this,0));break;case 5:c=G(this,J(this));break;case 6:c=G(this,this.K);break;case 7:c=G(this,this.J);break;case 64:c=G(this,this.D+this.S());break;case 65:c=G(this,this.I+this.S());break;case 66:c=G(this,this.L+this.S());break;case 67:c=G(this,this.G+this.S());break;case 68:c=G(this,nk.call(this,1)+this.S()); +break;case 69:c=Dg(this,this.M+this.S());break;case 70:c=G(this,this.K+this.S());break;case 71:c=G(this,this.J+this.S());break;case 128:c=G(this,this.D+J(this));break;case 129:c=G(this,this.I+J(this));break;case 130:c=G(this,this.L+J(this));break;case 131:c=G(this,this.G+J(this));break;case 132:c=G(this,nk.call(this,2)+J(this));break;case 133:c=Dg(this,this.M+J(this));break;case 134:c=G(this,this.K+J(this));break;case 135:c=G(this,this.J+J(this));break;case 192:c=this.D;break;case 193:c=this.I;break; +case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}var d=this.ga>>3&7;switch(d){case 0:b=this.D;break;case 1:b=this.I;break;case 2:b=this.L;break;case 3:b=this.G;break;case 4:b=z(this);break;case 5:b=this.M;break;case 6:b=this.K;break;case 7:b=this.J;break;default:b=0}a=a.call(this,b,c);switch(d){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:he(this, +a);break;case 5:this.M=a;break;case 6:this.K=a;break;case 7:this.J=a}} +function Of(a){var b,c,d=(this.ga=this.ra())&199;switch(d){case 0:b=G(this,this.D);this.F=this.C;break;case 1:b=G(this,this.I);this.F=this.C;break;case 2:b=G(this,this.L);this.F=this.C;break;case 3:b=G(this,this.G);this.F=this.C;break;case 4:b=G(this,nk.call(this,0));this.F=this.C;break;case 5:b=G(this,J(this));this.F=this.C;break;case 6:b=G(this,this.K);this.F=this.C;break;case 7:b=G(this,this.J);this.F=this.C;break;case 64:b=G(this,this.D+this.S());this.F=this.C;break;case 65:b=G(this,this.I+this.S()); +this.F=this.C;break;case 66:b=G(this,this.L+this.S());this.F=this.C;break;case 67:b=G(this,this.G+this.S());this.F=this.C;break;case 68:b=G(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:b=Dg(this,this.M+this.S());this.F=this.C;break;case 70:b=G(this,this.K+this.S());this.F=this.C;break;case 71:b=G(this,this.J+this.S());this.F=this.C;break;case 128:b=G(this,this.D+J(this));this.F=this.C;break;case 129:b=G(this,this.I+J(this));this.F=this.C;break;case 130:b=G(this,this.L+J(this));this.F= +this.C;break;case 131:b=G(this,this.G+J(this));this.F=this.C;break;case 132:b=G(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:b=Dg(this,this.M+J(this));this.F=this.C;break;case 134:b=G(this,this.K+J(this));this.F=this.C;break;case 135:b=G(this,this.J+J(this));this.F=this.C;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=z(this);break;case 197:b=this.M;break;case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}switch(this.ga>> +3&7){case 0:c=this.D;break;case 1:c=this.I;break;case 2:c=this.L;break;case 3:c=this.G;break;case 4:c=z(this);break;case 5:c=this.M;break;case 6:c=this.K;break;case 7:c=this.J;break;default:c=0}a=a.call(this,b,c);switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Gg(this,a)}} +function Pf(a,b){var c,d=(this.ga=this.ra())&199;switch(d){case 0:c=G(this,this.D);this.F=this.C;break;case 1:c=G(this,this.I);this.F=this.C;break;case 2:c=G(this,this.L);this.F=this.C;break;case 3:c=G(this,this.G);this.F=this.C;break;case 4:c=G(this,nk.call(this,0));this.F=this.C;break;case 5:c=G(this,J(this));this.F=this.C;break;case 6:c=G(this,this.K);this.F=this.C;break;case 7:c=G(this,this.J);this.F=this.C;break;case 64:c=G(this,this.D+this.S());this.F=this.C;break;case 65:c=G(this,this.I+this.S()); +this.F=this.C;break;case 66:c=G(this,this.L+this.S());this.F=this.C;break;case 67:c=G(this,this.G+this.S());this.F=this.C;break;case 68:c=G(this,nk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Dg(this,this.M+this.S());this.F=this.C;break;case 70:c=G(this,this.K+this.S());this.F=this.C;break;case 71:c=G(this,this.J+this.S());this.F=this.C;break;case 128:c=G(this,this.D+J(this));this.F=this.C;break;case 129:c=G(this,this.I+J(this));this.F=this.C;break;case 130:c=G(this,this.L+J(this));this.F= +this.C;break;case 131:c=G(this,this.G+J(this));this.F=this.C;break;case 132:c=G(this,nk.call(this,2)+J(this));this.F=this.C;break;case 133:c=Dg(this,this.M+J(this));this.F=this.C;break;case 134:c=G(this,this.K+J(this));this.F=this.C;break;case 135:c=G(this,this.J+J(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=z(this);break;case 197:c=this.M;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}a=a[this.ga>> +3&7].call(this,c,b.call(this));switch(d){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:he(this,a);break;case 197:this.M=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Gg(this,a)}} +function nk(a){var b=this.ra(),c=b>>6,d,e;switch(b>>3&7){case 0:d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=0;break;case 5:d=this.M;break;case 6:d=this.K;break;case 7:d=this.J}switch(b&7){case 0:e=this.D;break;case 1:e=this.I;break;case 2:e=this.L;break;case 3:e=this.G;break;case 4:e=z(this);this.Da=this.Rb;break;case 5:a?(e=this.M,this.Da=this.Rb):e=J(this);break;case 6:e=this.K;break;case 7:e=this.J}return(d<>8&255;9<(c&15)||fg(this)?(c+=6,80286<=this.ca&&255>8&255;9<(c&15)||fg(this)?(c=c-6&15,d=d-1&255,a=b=1):a=b=0;this.D=this.D&-65536|d<<8|c;a?kg(this):lg(this);b?ug(this):qg(this);this.A-=this.B.qe},function(){this.D=ak.call(this,this.D)},function(){this.I=ak.call(this,this.I)},function(){this.L=ak.call(this,this.L)},function(){this.G=ak.call(this,this.G)},function(){he(this, +ak.call(this,z(this)))},function(){this.M=ak.call(this,this.M)},function(){this.K=ak.call(this,this.K)},function(){this.J=ak.call(this,this.J)},function(){this.D=Yj.call(this,this.D)},function(){this.I=Yj.call(this,this.I)},function(){this.L=Yj.call(this,this.L)},function(){this.G=Yj.call(this,this.G)},function(){he(this,Yj.call(this,z(this)))},function(){this.M=Yj.call(this,this.M)},function(){this.K=Yj.call(this,this.K)},function(){this.J=Yj.call(this,this.J)},function(){pe(this,this.D&this.R); +this.A-=this.B.Ic},function(){pe(this,this.I&this.R);this.A-=this.B.Ic},function(){pe(this,this.L&this.R);this.A-=this.B.Ic},function(){pe(this,this.G&this.R);this.A-=this.B.Ic},function(){pe(this,z(this)-2&65535);this.A-=this.B.Ic},function(){pe(this,this.M&this.R);this.A-=this.B.Ic},function(){pe(this,this.K&this.R);this.A-=this.B.Ic},function(){pe(this,this.J&this.R);this.A-=this.B.Ic},function(){this.D=this.D&~this.R|fe(this);this.A-=this.B.nc},function(){this.I=this.I&~this.R|fe(this);this.A-= +this.B.nc},function(){this.L=this.L&~this.R|fe(this);this.A-=this.B.nc},function(){this.G=this.G&~this.R|fe(this);this.A-=this.B.nc},function(){he(this,z(this)&~this.R|fe(this));this.A-=this.B.nc},function(){this.M=this.M&~this.R|fe(this);this.A-=this.B.nc},function(){this.K=this.K&~this.R|fe(this);this.A-=this.B.nc},function(){this.J=this.J&~this.R|fe(this);this.A-=this.B.nc},ok,pk,qk,rk,sk,tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,ok,pk,qk,rk,sk,tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,Ek,function(){this.rb.call(this, +Tk,this.Ea);this.A-=-1===this.F?1:this.B.yg},Ek,function(){this.rb.call(this,Tk,this.S);this.A-=-1===this.F?1:this.B.yg},function(){this.tc.call(this,Pj)},function(){this.za.call(this,Qj)},function(){this.kc.call(this,Tj)},function(){this.ma.call(this,Uj)},Gk,Hk,Ik,Jk,function(){this.N|=1;this.za.call(this,hj)},function(){this.N|=1;this.Da=this.Rb=this.Qg;this.ma.call(this,Oi)},function(){var a;this.ma.call(this,gj);switch(this.ga>>3&7){case 0:a=this.D;this.D=this.ya;oe(this,a);break;case 1:a=this.I; +this.I=this.ya;Zf(this,a);break;case 2:a=this.L;this.L=this.ya;ge(this,a);break;case 3:a=this.G;this.G=this.ya;ne(this,a);break;case 4:a=z(this);he(this,this.ya);80386<=this.ca?this.Ga.load(a):oe(this,a);break;case 5:a=this.M;this.M=this.ya;80386<=this.ca?this.Ha.load(a):Zf(this,a);break;case 6:a=this.K;this.K=this.ya;ge(this,a);break;case 7:a=this.J,this.J=this.ya,ne(this,a)}},function(){this.N|=1;this.ta=this.Aa;this.ya=fe(this);this.rb.call(this,Uk,hk);this.ta=-1},function(){this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.I&this.R;this.I=this.I&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.L&this.R;this.L=this.L&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.G&this.R;this.G=this.G&~this.R|a&this.R;this.A-=3},function(){var a=this.D,b=z(this);this.D=this.D&~this.R|b&this.R;he(this,b&~this.R|a&this.R);this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.M&this.R;this.M=this.M&~this.R|a&this.R;this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.V?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.V?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Kj},function(){ik.call(this,this.Ea(),Hg(this));this.A-=this.B.Nj},function(){this.A-=3},function(){var a=re(this);a&131072&& +3>this.lc?y.call(this,13,0):(pe(this,a&-196609),this.A-=this.B.Ic)},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var a=fe(this),a=a&65535|this.O&-65536;se(this,a);this.A-=this.B.nc}},function(){var a=this.D>>8&255;a&1?kg(this):lg(this);a&4?(this.resultType&=-3,this.O|=4):(this.resultType&=-3,this.O&=-5);a&16?ug(this):qg(this);a&64?vg(this):rg(this);a&128?(this.resultType&=-17,this.O|=128):(this.resultType&=-17,this.O&=-129);this.A-=this.B.Vb},function(){this.D=this.D&-65281|(re(this)& +213)<<8;this.A-=this.B.Vb},function(){var a=this.D&-256,b;b=J(this);b=this.Ia(this.Da.bc(b,1));this.D=a|b;this.A-=this.B.Kh},function(){this.D=this.D&~this.R|le(this,this.Da,J(this));this.A-=this.B.Kh},function(){var a=J(this),b=this.D;this.fc(this.Da.cc(a,1),b);this.A-=this.B.Lh},function(){var a=J(this),b=this.D;this.yb(this.Da.cc(a,this.V),b);this.A-=this.B.Lh},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e= +this.Ia(this.Da.bc(this.K&c,1));this.fc(this.oa.cc(this.J&c,1),e);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e=le(this,this.Da,this.K&c);this.yb(this.oa.cc(this.J&c,this.V),e);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d; +this.I=this.I&~c|this.I-b&c;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=zg(this,this.Da,this.K),f=zg(this,this.oa,this.J);this.F=this.C;Bi.call(this,e,f);e=this.O&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.xh;this.ha&192&& +(a=this.I&c,b=1,d=this.B.zh,this.ha&256||(this.A-=this.B.yh));if(a--){var e=Bg(this,this.Da,this.K&c),f=Bg(this,this.oa,this.J&c);this.F=this.C;Ci.call(this,e,f);e=this.O&1024?-this.V:this.V;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){jg(this,this.D&this.ra(),128);this.A-=this.B.qe},function(){jg(this,this.D&this.Ea(),this.Fb);this.A-=this.B.qe},function(){var a=1,b=0,c=this.wa, +d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.fc(this.oa.cc(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.we&&80564>=this.we&&!(this.ha&2048)!=(103!=this.Ia(this.da))&&(c^=-65536);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Xh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Zh,this.ha&256||(this.A-=this.B.Yh));if(a--){var e=this.D;this.yb(this.oa.cc(this.J& +c,this.V),e);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=this.Ia(this.Da.bc(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Eh;this.ha&192&&(a=this.I&c, +b=1,d=this.B.Gh,this.ha&256||(this.A-=this.B.Fh));if(a--){var e=le(this,this.Da,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&255,f=zg(this,this.oa,this.J);this.F=this.C;Bi.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-1:1)&c;this.I=this.I&~c|this.I- +b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){var a=1,b=0,c=this.wa,d=this.B.Rh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Th,this.ha&256||(this.A-=this.B.Sh));if(a--){var e=this.D&this.R,f=Bg(this,this.oa,this.J&c);this.F=this.C;Ci.call(this,e,f);this.J=this.J&~c|this.J+(this.O&1024?-this.V:this.V)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Ib;a&&gg(this)==(this.ha&64)&&(bg(this),this.N|=256)}},function(){this.D=this.D&-256|this.ra();this.A-=this.B.Vb},function(){this.I= +this.I&-256|this.ra();this.A-=this.B.Vb},function(){this.L=this.L&-256|this.ra();this.A-=this.B.Vb},function(){this.G=this.G&-256|this.ra();this.A-=this.B.Vb},function(){this.D=this.D&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.I=this.I&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.L=this.L&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.G=this.G&-65281|this.ra()<<8;this.A-=this.B.Vb},function(){this.D=this.D&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.I=this.I& +~this.R|this.Ea();this.A-=this.B.Vb},function(){this.L=this.L&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.G=this.G&~this.R|this.Ea();this.A-=this.B.Vb},function(){he(this,z(this)&~this.R|this.Ea());this.A-=this.B.Vb},function(){this.M=this.M&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.K=this.K&~this.R|this.Ea();this.A-=this.B.Vb},function(){this.J=this.J&~this.R|this.Ea();this.A-=this.B.Vb},Nk,Ok,Nk,Ok,function(){this.ma.call(this,Pi)},function(){this.ma.call(this,Ni)},function(){this.N|= +1;this.kd.call(this,Vk,this.ra)},function(){this.N|=1;this.rb.call(this,Vk,this.Ea)},Pk,Qk,Pk,Qk,function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var a=this.B.dk;this.Uc=-1;jk.call(this,3,null,a)}},function(){var a=this.ra();if(this.O&131072&&3>this.lc)y.call(this,13,0);else{var b;a:{b=this.Yf[a];if(void 0!==b)for(var c=0;cthis.lc)y.call(this,13,0);else{var a=this.B.ek;this.Uc=-1;jk.call(this,4,null,a)}else this.A-=this.B.fk},function(){if(this.O&131072&&3>this.lc)y.call(this,13,0);else{this.Vc=this.Y.U;this.ta=this.Aa;this.A-=this.B.bk;if(this.qa&1&&this.O&16384){var a=this.ja(this.la.ua+0);ie(this.Z,a,!1)}else{var a=this.Ma,b=fe(this),c=fe(this),d=fe(this);if(this.O&131072)d=d&131071|this.O&-131072;else if(d&131072){var e=fe(this),f=fe(this),g=fe(this),h=fe(this),k=fe(this),m=fe(this);je(this,!0,!0);ge(this, +f);he(this,e);oe(this,g);ne(this,h);this.Ga.load(k);this.Ha.load(m)}null!=te(this,b,c,!1)&&(se(this,d,a),this.ag&&Uf(this,this.da))}this.Vc=this.ta=-1}},function(){this.kd.call(this,Kk,dk)},function(){this.rb.call(this,2==this.V?Lk:Mk,dk)},function(){this.kd.call(this,Kk,ek)},function(){this.rb.call(this,2==this.V?Lk:Mk,ek)},function(){var a=this.ra();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;jg(this,this.D,128);this.A-=this.B.Hj}else mk.call(this)},function(){var a=this.D&255,b=(this.D>> +8&255)*this.ra()|0,c=a+b|0;this.D=this.D&-65536|c&255;cg(this,a,b,c,191);this.A-=this.B.Gj},function(){this.D=this.D&-256|(dg(this)?255:0);this.A-=2},function(){this.D=this.D&-256|zg(this,this.Da,this.G+(this.D&255));this.A-=this.B.Gk},function(){Rk.call(this,216)},function(){Rk.call(this,217)},function(){Rk.call(this,218)},function(){Rk.call(this,219)},function(){Rk.call(this,220)},function(){Rk.call(this,221)},function(){Rk.call(this,222)},function(){Rk.call(this,223)},function(){var a=this.S(), +b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&!gg(this)?(C(this,A(this)+a),this.A-=this.B.mk):this.A-=this.B.Hh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b&&gg(this)?(C(this,A(this)+a),this.A-=this.B.Ih):this.A-=this.B.Jh},function(){var a=this.S(),b=this.I-1&this.wa;this.I=this.I&~this.wa|b;b?(C(this,A(this)+a),this.A-=this.B.lk):this.A-=this.B.Hh},function(){var a=this.S();this.I&this.wa?this.A-=this.B.Jh:(C(this,A(this)+a),this.A-=this.B.Ih)},function(){var a=this.ra(); +xg(this,a,1,!0)&&(this.D=this.D&-256|Pc(this.ka,a,1,this.da-2)&255,this.A-=this.B.Ch)},function(){var a=this.ra();xg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Pc(this.ka,a,this.V,this.da-2)&this.R,this.A-=this.B.Ch)},function(){var a=this.ra();xg(this,a,1,!1)&&(Tc(this.ka,a,1,this.D&255,this.da-2),this.A-=this.B.Qh)},function(){var a=this.ra();xg(this,a,this.V,!1)&&(Tc(this.ka,a,this.V,this.D&this.R,this.da-2),this.A-=this.B.Qh)},function(){var a=this.Ea(),b=A(this),a=b+a;pe(this,b);C(this,a);this.A-= +this.B.Lj},function(){var a=this.Ea();C(this,A(this)+a);this.A-=this.B.Dh},function(){te(this,this.Ea(),Hg(this));this.A-=this.B.hk},function(){var a=this.S();C(this,A(this)+a);this.A-=this.B.Dh},function(){var a=this.L&65535;xg(this,a,1,!0)&&(this.D=this.D&-256|Pc(this.ka,a,1,this.da-1)&255,this.A-=this.B.Bh)},function(){var a=this.L&65535;xg(this,a,this.V,!0)&&(this.D=this.D&~this.R|Pc(this.ka,a,this.V,this.da-1)&this.R,this.A-=this.B.Bh)},function(){var a=this.L&65535;xg(this,a,1,!1)&&(Tc(this.ka, +a,1,this.D&255,this.da-1),this.A-=this.B.Ph)},function(){var a=this.L&65535;xg(this,a,2,!1)&&(Tc(this.ka,a,this.V,this.D&this.R,this.da-1),this.A-=this.B.Ph)},Sk,Sk,function(){this.N|=132;this.A-=this.B.bd},function(){this.N|=68;this.A-=this.B.bd},function(){this.O&131072?y.call(this,13,0):(this.Za|=4,this.A-=2,this.ba&&t(this,-2147483648)?(bg(this),this.ba.Jb()):this.O&512||(this.ba&&bg(this),this.Jb()))},function(){dg(this)?lg(this):kg(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,Xk, +gk);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R)},function(){this.vc=!1;this.rb.call(this,Yk,gk);this.vc&&(this.D=this.D&~this.R|this.Ba&this.R,this.L=this.L&~this.R|this.$a&this.R)},function(){lg(this);this.A-=2},function(){kg(this);this.A-=2},function(){this.Ma>this.lc?y.call(this,13,0):(this.O&=-513,this.A-=this.B.Jj)},function(){this.Ma>this.lc?y.call(this,13,0):(this.O|=512,this.N|=4,this.A-=2)},function(){this.O&=-1025;this.A-=2},function(){this.O|=1024;this.A-=2},function(){this.kd.call(this, +Be,gk)},function(){this.rb.call(this,Ce,gk)}],Fk=[li,ij,ji,kj,ni,Nj,Vj,Bi],Tk=[mi,jj,ki,lj,oi,Oj,Wj,Ci],Uk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.yk;return b},Ei,Ei,Ei,Ei,Ei,Ei,Ei],Vk=[function(a,b){this.A-=-1===this.F?this.B.qk:this.B.nk;return b},Fi,Fi,Fi,Fi,Fi,Fi,Fi],Kk=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<>8-b)&255):d=a<<7;og(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=7)?(d=a<<8-b,c=(a>>>b|d)&255):d=a;og(this,c,d,128)}return c}, +function(a,b){var c=a;if(b&=this.Ta){var d=pg(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<<8-b|a<<9-b)&255,d=a<<8-b):d<<=7;og(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;8>>b-1,a=b>>>1&255,jg(this,a,128,b&1,a&128);return a},Fi,function(a,b){if(b&=this.Ta)9>24>>b-1,a=b>>1&255,jg(this,a,128,b&1);return a}],Lk=[function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<>16-b)&65535):d=a<<15;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d;(b&=15)?(d=a<<16-b,c=(a>>>b|d)&65535):d=a;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=pg(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<<16-b):d<<=15;og(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ta){var d=0;16>>b-1,a=b>>>1&65535,jg(this,a,32768,b&1,a&32768);return a},Fi,function(a,b){if(b&=this.Ta)17>16>>b-1,a=b>>1&65535,jg(this,a,32768,b&1);return a}],Mk=[function(a,b){var c=a;if(b&=this.Ta)c=a<>>32-b,og(this,c,a<>>b|d;og(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ta)c=pg(this),c=a<>>32-b>>>1,og(this,c,a<>>b|c<<32-b|a<<32-b<<1,og(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ta)a<<=b-1,c=a<<1,jg(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ta)b=a>>>b-1,a=b>>>1,jg(this,a,-2147483648, +b&1,a&-2147483648);return a},Fi,function(a,b){if(b&=this.Ta)b=a>>b-1,a=b>>1,jg(this,a,-2147483648,b&1);return a}],Xk=[function(a,b){b=this.ra();jg(this,a&b,128);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},Fi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^255},function(a){var b=-a|0;cg(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&255},function(a){this.Ba=(this.D&255)*a&65535;this.Ba&65280?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-= +-1===this.C?this.B.uk:this.B.tk;this.N|=2;return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ba=b&65535;127b?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C?this.B.Zj:this.B.Yj;this.N|=2;return a},function(a,b){if(!a)return mk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d= +(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086==this.ca&&-128==d)return mk.call(this),a;this.Ba=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Vj:this.B.Uj;this.N|=2;return a}],Yk=[function(a,b){b=this.Ea();jg(this,a&b,this.Fb);this.A-=-1===this.C?this.B.ai:this.B.$h;this.N|=2;return a},Fi,function(a){this.A-=-1===this.C?this.B.Ff:this.B.Ef;return a^this.R},function(a){var b=-a|0;cg(this,0,a,b,this.Fb|63,!0);this.A-=-1===this.C?this.B.Ff:this.B.Ef;return b&this.R},function(a,b){2==this.V? +(b=this.D&65535,b=b*a|0,this.Ba=b&65535,this.$a=b>>16&65535):(Li.call(this,a,this.D),80563==this.we&&68657152==this.D&&129==a&&(this.$a=0));this.$a?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C?this.B.wk:this.B.vk;this.N|=2;return a},function(a,b){2==this.V?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ba=b&65535,this.$a=b>>16&65535,b=32767b):(Ki.call(this,a,this.D),b=this.$a!=this.Ba>>31);b?(kg(this),mg(this)):(lg(this),ng(this));this.vc=!0;this.A-=-1===this.C? +this.B.ak:this.B.$j;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return mk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return mk.call(this),a;this.Ba=c&65535;this.$a=b%a&65535}else{if(!Zj.call(this,this.D,this.L,a))return mk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Tj:this.B.Sj;this.N|=2;return a},function(a,b){if(2==this.V){if(!a)return mk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.ca&& +-32768==d)return mk.call(this),a;this.Ba=d&65535;this.$a=b%c&65535}else{b=this.D;var c=this.L,d=a,e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!Zj.call(this,b,c,d)||this.Ba>2147483647+e||this.$a>2147483647+f?b=!1:(e&&(this.Ba=-this.Ba),f&&(this.$a=-this.$a),b=!0);if(!b)return mk.call(this),a;this.Ba|=0;this.$a|=0}this.vc=!0;this.A-=-1===this.C?this.B.Xj:this.B.Wj;this.N|=2;return a}],Be=[function(a){var b=a+1|0;cg(this,a,1,b,190);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b& +255},function(a){var b=a-1|0;cg(this,a,1,b,190,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&255},Fi,Fi,Fi,Fi,Fi,Fi],Ce=[function(a){var b=a+1|0;cg(this,a,1,b,this.Fb|62);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){var b=a-1|0;cg(this,a,1,b,this.Fb|62,!0);this.A-=-1===this.C?this.B.Df:this.B.Cf;return b&this.R},function(a){pe(this,A(this));C(this,a);this.A-=-1===this.C?this.B.Pj:this.B.Oj;this.N|=2;return a},function(a){if(-1===this.C)return Fi.call(this,a);this.ta= +this.Aa;ik.call(this,a,this.ja(this.C+this.V));this.A-=this.B.Mj;this.N|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.jk:this.B.ik;this.N|=2;return a},function(a){if(-1===this.C)return Fi.call(this,a);te(this,a,this.ja(this.C+this.V));this.A-=this.B.gk;this.N|=2;return a},function(a){var b=a;this.N&512&&(a=a-2&65535,80286>this.ca&&(b=a));pe(this,b);this.A-=-1===this.C?this.B.Ic:this.B.Ak;this.N|=2;return a},Fi]; +function hf(){this.ma.call(this,Sj);this.A-=-1===this.C?6:13}function jf(){this.za.call(this,Rj);this.A-=-1===this.C?12:19}var Xe=Array(256);Xe[0]=function(){16>(this.Ia(this.da)&56)&&(this.N|=1);this.rb.call(this,this.nj,gk)};Xe[1]=function(){this.Ia(this.da)&16||(this.N|=1);this.rb.call(this,Zk,gk)};Xe[2]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Mi)};Xe[3]=function(){!(this.qa&1)||this.O&131072?y.call(this,6):this.ma.call(this,Si)}; +Xe[5]=function(){this.Ma?y.call(this,13,0,0,!0):(wg(this,this.ja(2054)),this.J=this.ja(2086),this.K=this.ja(2088),this.M=this.ja(2090),this.G=this.ja(2094),this.L=this.ja(2096),this.I=this.ja(2098),this.D=this.ja(2100),de(this.oa,2102,this.ja(2084)),de(this.Z,2108,this.ja(2082)),de(this.Y,2114,this.ja(2080)),de(this.Ca,2120,this.ja(2078)),se(this,this.ja(2072)),C(this,this.ja(2074)),he(this,this.ja(2092)),this.Kb=this.ja(2126)|this.Ia(2128)<<16,this.Pc=this.Kb+this.ja(2130),this.Pb=this.ja(2138)| +this.Ia(2140)<<16,this.cd=this.Pb+this.ja(2142),de(this.Eb,2132,this.ja(2076)),de(this.la,2144,this.ja(2070)),this.A-=195)};Xe[6]=function(){this.Ma?y.call(this,13,0):(this.qa&=-9,this.A-=2)};Xe[11]=Ee;Xe[166]=Ee;Xe[255]=Ee;var B=[];B[5]=Ee; +B[7]=function(){if(this.Ma)y.call(this,13,0,0,!0);else{var a=this.oa.bc(this.J&this.wa,204);if(-1!==a){bk.call(this,this.ia(a));var b=this.ia(a+168),c=(b&24576)>>13;se(this,this.ia(a+4),c);this.Kb=this.ia(a+112);this.Pc=this.Kb+this.ia(a+116);this.Pb=this.ia(a+100);this.cd=this.Pb+this.ia(a+104);be(this.Eb,this.ia(a+56),this.ia(a+120),this.ia(a+124),this.ia(a+128));be(this.la,this.ia(a+52),this.ia(a+84),this.ia(a+88),this.ia(a+92));this.J=this.ia(a+12);this.K=this.ia(a+16);this.M=this.ia(a+20);this.G= +this.ia(a+28);this.L=this.ia(a+32);this.I=this.ia(a+36);this.D=this.ia(a+40);be(this.Ha,this.ia(a+60),this.ia(a+132),this.ia(a+136),this.ia(a+140));be(this.Ga,this.ia(a+64),this.ia(a+144),this.ia(a+148),this.ia(a+152));be(this.Ca,this.ia(a+68),this.ia(a+156),this.ia(a+160),this.ia(a+164));be(this.Y,this.ia(a+72),b,this.ia(a+172),this.ia(a+176));be(this.Z,this.ia(a+76),this.ia(a+180),this.ia(a+184),this.ia(a+188));be(this.oa,this.ia(a+80),this.ia(a+192),this.ia(a+196),this.ia(a+200));C(this,this.ia(a+ +8));he(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=Gk;B[17]=Hk;B[18]=Ik;B[19]=Jk;B[32]=function(){if(this.Ma)y.call(this,13,0);else{var a,b=this.ra();switch((b&56)>>3){case 0:a=this.qa;break;case 2:a=this.Cd;break;case 3:a=this.Wc;break;default:Ye.call(this);return}wf(this,b&7,a);this.A-=6}};B[33]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Ye.call(this):(wf(this,a&7,this.Qb[b]),this.A-=22)}}; +B[34]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=vf(this,a&7);switch((a&56)>>3){case 0:bk.call(this,b);this.A-=10;break;case 2:this.Cd=b;this.A-=4;break;case 3:ue.call(this,b);this.A-=5;break;default:Ye.call(this)}}};B[35]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;4==b||5==b?Ye.call(this):(a=vf(this,a&7),a!=this.Qb[b]&&(Vf(this,!1),this.Qb[b]=a,Vf(this,!0)),this.A-=4>b?22:14)}}; +B[36]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Ye.call(this):(wf(this,a&7,this.dg[b]),this.A-=12)}};B[38]=function(){if(this.Ma)y.call(this,13,0);else{var a=this.ra(),b=(a&56)>>3;6>b?Ye.call(this):(this.dg[b]=vf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ea();ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[129]=function(){var a=this.Ea();ig(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; +B[130]=function(){var a=this.Ea();dg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[131]=function(){var a=this.Ea();dg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[132]=function(){var a=this.Ea();gg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[133]=function(){var a=this.Ea();gg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[134]=function(){var a=this.Ea();dg(this)||gg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra}; +B[135]=function(){var a=this.Ea();dg(this)||gg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[136]=function(){var a=this.Ea();hg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[137]=function(){var a=this.Ea();hg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[138]=function(){var a=this.Ea();eg(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[139]=function(){var a=this.Ea();eg(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)}; +B[140]=function(){var a=this.Ea();!hg(this)!=!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[141]=function(){var a=this.Ea();!hg(this)==!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[142]=function(){var a=this.Ea();gg(this)||!hg(this)!=!ig(this)?(C(this,A(this)+a),this.A-=this.B.Qa):this.A-=this.B.Ra};B[143]=function(){var a=this.Ea();gg(this)||!hg(this)!=!ig(this)?this.A-=this.B.Ra:(C(this,A(this)+a),this.A-=this.B.Qa)};B[144]=function(){ck.call(this,mj)}; +B[145]=function(){ck.call(this,mj)};B[146]=function(){ck.call(this,nj)};B[147]=function(){ck.call(this,oj)};B[148]=function(){ck.call(this,pj)};B[149]=function(){ck.call(this,qj)};B[150]=function(){ck.call(this,rj)};B[151]=function(){ck.call(this,sj)};B[152]=function(){ck.call(this,tj)};B[153]=function(){ck.call(this,uj)};B[154]=function(){ck.call(this,vj)};B[155]=function(){ck.call(this,wj)};B[156]=function(){ck.call(this,xj)};B[157]=function(){ck.call(this,yj)};B[158]=function(){ck.call(this,zj)}; +B[159]=function(){ck.call(this,Aj)};B[160]=function(){me(this,this.Ga.U,this.V,2);this.A-=this.B.re};B[161]=function(){this.ta=this.Aa;var a=fe(this);this.Ga.load(a);this.A-=this.B.nc;this.ta=-1};B[163]=function(){this.za.call(this,xi);-1!==this.C&&(this.A-=6)};B[164]=function(){this.za.call(this,2==this.V?Bj:Dj);this.A-=-1===this.C?3:7};B[165]=function(){this.za.call(this,2==this.V?Fj:Gj);this.A-=-1===this.C?3:7};B[168]=function(){me(this,this.Ha.U,this.V,2);this.A-=this.B.re}; +B[169]=function(){this.ta=this.Aa;var a=fe(this);this.Ha.load(a);this.A-=this.B.nc;this.ta=-1};B[171]=function(){this.za.call(this,Ai);-1!==this.C&&(this.A-=5)};B[172]=function(){this.za.call(this,2==this.V?Hj:Jj);this.A-=-1===this.C?3:7};B[173]=function(){this.za.call(this,2==this.V?Lj:Mj);this.A-=-1===this.C?3:7};B[175]=function(){this.ma.call(this,2==this.V?Hi:Ji)};B[178]=function(){this.ma.call(this,cj)};B[179]=function(){this.za.call(this,zi);-1!==this.C&&(this.A-=5)}; +B[180]=function(){this.ma.call(this,Qi)};B[181]=function(){this.ma.call(this,Ri)}; +B[182]=function(){this.kc.call(this,ej);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|this.D&255;break;case 1:this.I=this.I&~this.R|this.I&255;break;case 2:this.L=this.L&~this.R|this.L&255;break;case 3:this.G=this.G&~this.R|this.G&255;break;case 4:this.Hc=this.Hc&~this.R|this.D>>8&255;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I>>8&255;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L>>8&255;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G>>8&255,this.G=this.ya}this.A-= +-1===this.C?3:6};B[183]=function(){ke(this,2);this.ma.call(this,fj);switch(this.ga>>3&7){case 0:this.D=this.D&65535;break;case 1:this.I=this.I&65535;break;case 2:this.L=this.L&65535;break;case 3:this.G=this.G&65535;break;case 4:this.Hc=this.Hc&65535;break;case 5:this.M=this.M&65535;break;case 6:this.K=this.K&65535;break;case 7:this.J=this.J&65535}this.A-=-1===this.C?3:6};B[186]=function(){this.rb.call(this,$k,this.ra)};B[187]=function(){this.za.call(this,yi);-1!==this.C&&(this.A-=5)}; +B[188]=function(){this.ma.call(this,ri)};B[189]=function(){this.ma.call(this,si)}; +B[190]=function(){this.kc.call(this,ej);switch(this.ga>>3&7){case 0:this.D=this.D&~this.R|(this.D&255)<<24>>24&this.R;break;case 1:this.I=this.I&~this.R|(this.I&255)<<24>>24&this.R;break;case 2:this.L=this.L&~this.R|(this.L&255)<<24>>24&this.R;break;case 3:this.G=this.G&~this.R|(this.G&255)<<24>>24&this.R;break;case 4:this.Hc=this.Hc&~this.R|this.D<<16>>24&this.R;this.D=this.ya;break;case 5:this.M=this.M&~this.R|this.I<<16>>24&this.R;this.I=this.ya;break;case 6:this.K=this.K&~this.R|this.L<<16>>24& +this.R;this.L=this.ya;break;case 7:this.J=this.J&~this.R|this.G<<16>>24&this.R,this.G=this.ya}this.A-=-1===this.C?3:6};B[191]=function(){ke(this,2);this.ma.call(this,fj);switch(this.ga>>3&7){case 0:this.D=this.D<<16>>16;break;case 1:this.I=this.I<<16>>16;break;case 2:this.L=this.L<<16>>16;break;case 3:this.G=this.G<<16>>16;break;case 4:this.Hc=this.Hc<<16>>16;break;case 5:this.M=this.M<<16>>16;break;case 6:this.K=this.K<<16>>16;break;case 7:this.J=this.J<<16>>16}this.A-=-1===this.C?3:6}; +var Wf=[function(){this.A-=2+(-1===this.C?0:1);return this.Eb.U},function(){this.A-=2+(-1===this.C?0:1);return this.la.U},function(a){this.N|=2;this.Eb.load(a);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;-1!==this.la.load(a)&&(this.fb(this.la.Lb+4,this.la.jb|=512),this.la.type|=512);this.A-=17+(-1===this.C?0:2);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&2048!=(this.xb.jb&2560)&&(this.xb.qc>=this.Ma&&this.xb.qc>=(a&3)||7168==(this.xb.jb&7168)))return vg(this), +a;rg(this);return a},function(a){this.N|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.xb.load(a)&&512==(this.xb.jb&2560)&&this.xb.qc>=this.Ma&&this.xb.qc>=(a&3))return vg(this),a;rg(this);return a},Fi,Fi],De=[Ve,Ve,Ve,Ve,Ve,Ve,Fi,Fi],Zk=[function(a){if(-1===this.C)y.call(this,6);else{a=this.Pc-this.Kb;var b=this.Kb;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=11}return a},function(a){if(-1===this.C)y.call(this,6);else{a=this.cd-this.Pb;var b=this.Pb; +80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.V&&(a|=b<<16);this.ab(this.C+2,b);this.A-=12}return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Kb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.Pc=this.Kb+a,this.N|=2,this.A-=11);return a},function(a){-1===this.C||this.O&131072?y.call(this,6):(this.Pb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.cd=this.Pb+a,this.N|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.C?0:1);return this.qa},Fi,function(a){this.O& +131072?y.call(this,6):(wg(this,a),this.A-=-1===this.C?3:6,this.N|=2);return a},Fi],$k=[Fi,Fi,Fi,Fi,ti,wi,vi,ui]; +function al(a){nb.call(this,"ChipSet",a,32768);var b=a.model;b&&!bl[b]&&hb("Unrecognized ChipSet model: "+b);this.ca=bl[b]||cl;this.C=[];b=dl(a[el]);this.C[0]=[b,b];null==b&&(this.N=[360,360],(b=a.floppies)&&b.length&&(this.N=b),fl(this,gl,this.N.length),fl(this,hl,a.monitor||(this.ca=eh&&(this.za=this.ha=2);this.O=a.scaleTimers||!1;this.Ma=a.rtcDate;this.Ga=!1;a.sound&&(this.Da=this.la=null,window&&(this.Da=window.AudioContext|| +window.webkitAudioContext),this.Da&&(this.la=new this.Da));this.reset(!0);Jb(this)}ba(al,nb);l=al.prototype;l.Cb=function(a,b,c){switch(b){case el:return this.na[b]=c,jl(this,0,b),!0;case il:if((this.ca|0)==kl||this.ca==ll)return this.na[b]=c,jl(this,1,b),!0;break;case ml:return this.na[b]=c,!0}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.Tc=Xb(a,"FPU");fl(this,nl,this.Tc?1:0,!0);this.B=Xb(a,"Keyboard");this.Ba=c.T.sd/ol;Oc(b,this,pl);Sc(b,this,ql);this.ca=eh){this.D=Nl;this.L=0;this.K=Ol;this.oa=0;this.M=Pl|Ql;512<=Rl(this)&&(this.M|=Sl);+Tl(this,hl,void 0)==Ul&&(this.M|=Vl);(this.ca|0)==xl&&(this.M=this.M|Wl|Xl);this.qa= +Yl|Zl;this.Y=Array(8);this.W=0;a&&(this.A=Array(Cl));$l(this,this.Ma);for(a=am;a<=bm;a++)this.A[a]=0;for(a=cm;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Rd]&Rm||(d&&128>8} +l.save=function(){var a=new Xf(this);a.set(0,[this.C]);for(var b=[],c=0;c=eh&&(a.set(5,[this.D,this.L,this.K,this.oa,this.M,this.qa]),a.set(6,[this.Y[7],this.Y,this.W,this.A,this.ma,this.Z]));return a.data()}; +l.restore=function(a){var b,c;b=a[0];Array.isArray(b[0])?this.C=b[0]:(this.C[0][0]=b[0],this.C[1][0]=b[1]&15,this.C[0][1]=b[2],this.C[1][1]=b[3]&15);Fl(this);b=a[1];for(c=0;c=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
    '+f+"
    \n"}e.innerHTML=d;bn(a,b,c,!0)}function cn(a,b,c){if(b=(a=dn[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.yc&1<g.nb[0]&&(g.nb[0]=255,g.nb[1]--,0>g.nb[1]&&(g.nb[1]=255)));return h}function sn(a,b,c,d,e,f){var g=a.F[b];t(a,768)&&v(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.zb+"]",null,!0);a=g.oc[c];a.nb[g.zb]=a.pc[g.zb]=e;g.zb^=1}function tn(a,b,c,d){var e=a.F[b],f=e.Mb|un;e.Mb&=~vn;t(a,768)&&v(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} +function wn(a,b,c,d,e){var f=a.F[b];t(a,768)&&v(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Mb=f.Mb&~(16<>2].oc[b&3],c,d,e)}function An(a,b,c){b=a.F[b>>2].oc[b&3];b.mg&&b.eh&&b.Ag?(c&&(b.done=c),b.ne||Kn(a,b,!0)):c&&c(!0)} +function Kn(a,b,c){c&&(b.count=b.nb[1]<<8|b.nb[0],b.type=b.mode&Ln,b.rj=b.ng=!1);for(var d=!1;0<=b.count&&(c=b.hg<<16|b.sb[1]<<8|b.sb[0],b.type==Mn?(d=!0,function(c){b.eh.call(b.mg,b.Ag,-1,function(e,g){0>e&&(b.rj||(b.rj=!0),e=255);b.ne||a.ka.fc(c,e);(d=g)&&setTimeout(function(){Nn(b)||Kn(a,b)},0)})}(c)):b.type==On?(c=a.ka.Ia(c),0>b.eh.call(b.mg,b.Ag,c)&&(b.ng=!0)):b.type!=Pn&&(b.ng=!0)),!d&&!Nn(b););} +function Nn(a){if(!a.ng&&0<=--a.count&&(a.mode&Qn?(a.sb[0]--,0>a.sb[0]&&(a.sb[0]=255,a.sb[1]--,0>a.sb[1]&&(a.sb[1]=255))):(a.sb[0]++,255>3];b=1<<(b&7);d.ac&b||(d.ac|=b,d.We=c||0,fo(a))}function fh(a,b){var c=a.hc[b>>3];b=1<<(b&7);c.ac&b&&(c.ac&=~b,fo(a))}function fo(a,b){var c,d=-1;1>=1),Gd(a.H,e))),b==so&&c==wo&&Vm(a))}function xo(a,b,c,d){v(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.va:a.ta} +function yo(a,b,c,d,e){v(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&zo;b?(e=3,a.va=d):a.ta=d;if(c==Ao){if(!(d&Bo))for(c=0;2>=c;c++)if(d&Co<=c;c++)d&Co<>=Ho;var f=d&Io,g=d&Jo;d&=Ko;if(d==Lo)Go(a,e+c);else{e+=c;var h=a.G[e];h.Qf=d;h.mode=g;h.Zg=f;h.pc=[0,0];h.nb=[0,0];h.je=[0,0];h.gd=!1;h.Me=!1;h.le=!1;h.Qe=!1;oo(a,e);b==so&&c==to&&fh(a,uo);b==so&&c==wo&&255==a.hc[0].od&& +a.J==(Mo|No|Oo|Po)&&(b=a.G[0],b.Mc[0]=b.pc[0],b.Mc[1]=b.pc[1],b.jd=Ed(a.H,a.O))}}}function vo(a,b){a=a.G[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.ad?256:65536);return b}function Pd(a,b){a=a.G[b];(b=a.Mc[1]<<8|a.Mc[0])||(b=1==a.ad?256:65536);return b}function Go(a,b){Bl(a,b);var c=a.G[b];c.je[0]=c.nb[0];c.je[1]=c.nb[1];c.Me=!0;oo(a,b)}function oo(a,b){a=a.G[b];a.rd=a.Qf==Qo?1:0;a.ad=a.Qf==Ro?2:1} +function Bl(a,b,c){var d=a.G[b];if(d.le&&(b!=wo||a.J&Mo)){var e=Ed(a.H,a.O),f=(e-d.jd)/a.Ba|0;0>f&&(d.jd=e,f=0);var g=vo(a,b),h=Pd(a,b)-f;d.mode==qo?(0>=h&&(h=0),h||(d.gd=!0,d.le=!1,b||hh(a,uo))):d.mode==So?(d.gd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&hh(a,uo))):d.mode==Qd&&(h-=f,0>=h&&(d.gd=!d.gd,h=g+h,0>=h&&(h=g),d.Mc[0]=h&255,d.Mc[1]=h>>8&255,d.jd=e,!b&&d.gd&&hh(a,uo)));d.nb[0]=h&255;d.nb[1]=h>>8&255;c&&(a.jd=0)}return d} +function Od(a,b){for(var c=0;c=eh){b=a.H.T.sd;c=Ed(a.H,a.O);null==a.Aa&&(a.ma=Ed(a.H,a.O),a.Ha=1024,a.Aa=Math.floor(a.H.T.sd/a.Ha),Tm(a));c>=a.Z&&(a.A[Pm]|=To,a.A[Rd]&Td&&(a.A[Pm]|=Uo,hh(a,Vo)),a.Z=c+a.Aa);a.A[lm]==a.A[mm]&&a.A[nm]==a.A[om]&&a.A[pm]==a.A[Hm]&&(a.A[Pm]|=Wo,a.A[Rd]&Xo&&(a.A[Pm]|=Uo,hh(a,Vo)));var d=c-a.ma,e=Math.floor(d/b);if(e&&!(a.A[Rd]&Yo)){for(;e--;)if(60<=++a.A[lm]&&(a.A[lm]=0,60<=++a.A[nm]&&(a.A[nm]=0,24<=++a.A[pm]))){a.A[pm]=0;a.A[Im]=a.A[Im]% +7+1;var f;f=a.A[Lm];var g=Ja[a.A[Km]-1];28==g&&(f%4||!(f%100)&&f%400||g++);f=g;++a.A[Jm]>f&&(a.A[Jm]=1,12<++a.A[Km]&&(a.A[Km]=1,a.A[Lm]=(a.A[Lm]+1)%100))}a.A[Pm]|=Zo;a.A[Rd]&$o&&(a.A[Pm]|=Uo,hh(a,Vo))}a.ma=c-d%b}}l.Gm=function(a,b){var c=this.ya;this.ga&ap&&(this.J&bp?c=this.C[0][1]:this.B&&(c=cp(this.B)));v(this,a,null,b,"PPI_A",c);return c};l.jo=function(a,b,c){v(this,a,b,c,"PPI_A");this.ya=b};l.Hm=function(a,b){var c=this.J;v(this,a,null,b,"PPI_B",c);return c}; +l.ko=function(a,b,c){v(this,a,b,c,"PPI_B");dp(this,b)};function dp(a,b){var c=!!(b&ep),d=!!(a.J&ep);a.J=b;a.B&&fp(a.B,!(b&bp),!!(b&Po));c!=d&&Vm(a,c)}l.Im=function(a,b){var c=0,c=(this.ca|0)==kl?this.J&No?c|this.C[1][1]&gp:c|this.C[1][1]>>4&1:this.J&hp?c|this.C[0][1]>>4:c|this.C[0][1]&15;this.J&Mo&&Bl(this,wo).gd&&(c=this.J&ep?c|ip:c|jp);v(this,a,null,b,"PPI_C",c,32896);return c};l.lo=function(a,b,c){v(this,a,b,c,"PPI_C");this.Ca=b};l.Jm=function(a,b){var c=this.ga;v(this,a,null,b,"PPI_CTRL",c);return c}; +l.mo=function(a,b,c){v(this,a,b,c,"PPI_CTRL");this.ga=b};l.Sl=function(a,b){var c=this.B?cp(this.B):0;v(this,a,null,b,"8041_KBD",c);this.aa&=~kp;return c};l.tn=function(a,b,c){v(this,a,b,c,"8041_KBD")};l.Rl=function(a,b){var c=this.J;v(this,a,null,b,"8041_CTRL",c);return c};l.sn=function(a,b,c){v(this,a,b,c,"8041_CTRL");dp(this,b)};l.Tl=function(a,b){var c=this.aa;v(this,a,null,b,"8041_STATUS",c);return c}; +l.Ul=function(a,b){var c=this.oa;v(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(kp|lp);this.B&&mp(this.B);return c}; +l.vn=function(a,b,c){v(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&np)switch(this.L){case op:pp(this,b);break;case qp:rp(this,b);break;default:if(pp(this,this.K&~Ol),this.B){a=this.B;c=b;var d=-1;t(a)&&Mb(a,"sendCmd("+r(c)+")");switch(a.F||c){case sp:d=tp;up(a);break;case vp:a.F&&(c=0);wp(a,tp);a.F=c;break;case xp:a.F&&(c=0);wp(a,tp);a.F=c;break;default:Mb(a,"sendCmd(): unrecognized command")}yp(this,d)}}this.L=b;this.D&=~np}; +l.Vl=function(a,b){var c=this.J&~(zp|Ap)|(Ed(this.H)&64?Ap:0);v(this,a,null,b,"8042_RWREG",c,16384);return c};l.wn=function(a,b,c){v(this,a,b,c,"8042_RWREG",null,16384);dp(this,b)};l.Wl=function(a,b){v(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&lp&&(this.D|=kp,this.D&=~lp);return a}; +l.un=function(a,b,c){v(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.L=b;this.D|=np;a=0;this.L>=Bp&&(a=this.L^15,this.L=Bp);switch(this.L){case Cp:yp(this,this.K);break;case Dp:pp(this,this.K|Ol);break;case Ep:pp(this,this.K&~Ol);this.B&&mp(this.B);break;case Fp:this.B&&(a=this.B,a.A=[],t(a)&&Mb(a,"scan codes flushed"));pp(this,this.K|Ol);yp(this,Gp);rp(this,Yl|Zl);break;case Hp:yp(this,Ip);break;case Jp:yp(this,this.M);break;case Kp:yp(this,this.qa);break;case Lp:yp(this,this.K&Ol?0:Mp);break;case Bp:a& +1&&kf(this.H)}};function pp(a,b){a.K=b;a.D=a.D&~Np|b&Op;a.B&&fp(a.B,!!(b&Pp),!(b&Ol))}function yp(a,b,c){0<=b&&(a.oa=b,c?a.D|=kp:(a.D&=~kp,a.D|=lp))}function rp(a,b){a.qa=b;oc(a.ka,!!(b&Zl));b&Yl||kf(a.H)}function Qp(a,b){a.ca>4)+(c&15),e=!0);if(d==pm||d==Hm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Rd&&a&Td&&b&Td&&Tm(this)};l.Nk=function(a,b,c){v(this,a,b,c,"NMI");this.da=b};l.Vn=function(a,b,c){v(this,a,b,c,"FPU.CLEAR")};l.Wn=function(a,b,c){v(this,a,b,c,"FPU.RESET");this.Tc&&$g(this.Tc)}; +l.Xm=function(a){if(t(this,16)&&Wk(this.ba,26,a)){var b=this.H.D>>8;Tf(this.H,a,function(a,d){return function(c){d=Ed(a.H)-d;var e,g=a.H.L&255,h=a.H.L>>8,k=a.H.L&255,m=a.H.L>>8;if(2==b||3==b)e=" CH(hour)="+ta(h)+" CL(min)="+r(g)+" DH(sec)="+r(m);else if(4==b||5==b)e=" CX(year)="+ta(a.H.I)+" DH(month)="+r(m)+" DL(day)="+r(k);g=a.ba;h=d;g.message("INT "+r(26)+": C="+(dg(g.H)?1:0)+(e||"")+" (cycles="+h+(c?",level="+(c+1):"")+")")}}(this,Ed(this.H)))}return!0}; +function Vm(a,b){if(a.la)try{void 0!==b?a.Ga=b:b=!!(a.Ga&&a.H&&a.H.ea.vb);var c=Math.round(ol/vo(a,wo));if(20>c||2E4>>4,0,this.F,this.C,this.Fd),delete this.Fd);return!0};Yp.prototype.Wb=function(){return!0}; +function Zp(a,b,c,d){if(d)a.Fa("Unable to load system ROM (error "+d+": "+b+")");else{pb(a.xe,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.Fd=e.symbols;if(!a.A.length){hb("Empty ROM: "+b);return}if(1==a.A.length){hb(a.A[0]);return}}catch(h){a.Fa("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.A].bf(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.D?b.push(a.D):null!=a.D&&a.D.length&&(b=a.D);for(c=0;cthis.B?am:23,c=a.A[b]|a.A[b+1]<<8,c=c+(this.A>>10);a.A[b]=c&255;a.A[b+1]=c>>8;km(a)}}else hb("No RAM allocated")}; +l.save=function(){var a=new Xf(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function fq(a){this.D=a;this.C=hq;this.H=iq;this.B=jq;this.A=null}l=fq.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.fc(0,a[0]&255);this.fc(2,a[1]&255);return!0};l.Ia=function(a){var b=255;2>a?b=a&1?this.H>>8:this.H&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; +l.fc=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.D.ka;if(b&kq)this.A&&(xc(a,lq,mq,this.A),this.A=null);else{this.A||(this.A=yc(a,lq,mq));var c=yc(a,nq,mq);xc(a,lq,mq,c,b&oq?1:Ec)}this.C=this.C&-256|b}};l.vj=function(){return pq};l.fh=function(){return qq};var gq=-2134900736,nq=16646144,lq=917504,mq=131072,kq=1,oq=2,hq=65535,iq=2575,jq=2,pq=[null,0],qq=[function(a){return this.controller.Ia(a)},null,null,function(a,b){this.controller.fc(a,b)},null,null]; +ab(function(){for(var a=Ab(document,"pcx86","ram"),b=0;b=n.de&&d<=n.z&&(d-=n.de-n.ce),d=Bq[e]==d),d){(a=a.na["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.uc=function(a,b,c,d){this.pa=a;this.ka=b;this.H=c;this.ba=d;this.W=Xb(a,"ChipSet")}; +function sq(a,b){var c=0;a.ca=null;"string"==typeof b&&(a.ca=b.toUpperCase(),c=Fq.indexOf(a.ca),0>c&&(c=0));if(b=Fq[c])a.Y=parseInt(b.substr(2),10)}function up(a){Mb(a,"keyboard reset",65792);a.A=[];wp(a,Gq)}function fp(a,b,c){a.J!==c&&(a.J=a.K=c)&&(a.G=!0);a.I!==b&&(a.I=b)&&!a.K&&Sp(a,!0);a.I&&a.K&&(up(a),a.K=!1)}function wp(a,b){a.W&&(a.A.unshift(b),a.G=!0,Qp(a.W,b))} +function mp(a){var b=0;a.A.length&&a.G&&(b=a.A[0],a.W&&Qp(a.W,b));t(a)&&Mb(a,b?"scan code "+r(b)+" available":"no scan codes available")}function cp(a){var b=0;a.A.length&&(b=a.A[0]);t(a)&&Mb(a,"scan code "+r(b)+" delivered");return b}function Sp(a,b){0>=1);if(b&Kq){if(!1===d)return!0;d=null}null==d?d=!((c?a.C:a.jc)&b):d||b&Lq&&(b=Lq);if(c){a.C&=~b;d&&(a.C|=b);c=b;var f,g;for(g in Mq)d="led-"+g,e=Mq[g],c&&c!=e||!(f=a.na[d])||(f.style.backgroundColor=a.C&e?"#00ff00":"#000000")}else a.jc&=~b,d&&(a.jc|=b);return!0}}return!1} +function vq(a,b,c){if(O[b]&&a.H&&a.H.ea.vb){Iq[b]&&a.B.length&&0e||(e==a.B.length&&(d={},d.ue=b,d.jc=a.jc,Eq(a,b,!0),e++),0b.ud){if(!b.qf){Cq(a,b.ue);return}b.qf=!1;c=a.Z}else c=1==b.ud++?500:100;b.cl=setTimeout(function(a){return function(){Nq(a,b)}}(a),c)}} +function Pq(a,b,c){var d=b;if(b>=n.ce&&b<=n.eg)!(a.jc&(Qq|Rq|Sq))==c&&(d=b+(n.de-n.ce));else if(b>=n.de&&b<=n.z)!!(a.jc&(Qq|Rq|Sq))==c&&(d=b-(n.de-n.ce));else if(!!(a.jc&(Qq|Rq))==c){if(a=na[b])d=a}else if(a=ma[b])d=a;return d}l.Bg=function(a){a||(this.jc&=~Lq)}; +function tq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode,h=Pq(a,g,!0);a.dh&&h==n["`"]&&(g=h=27);if(O[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),Aq(a,h,!1,c)){if(20==g||144==g||145==g)a.O||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.ce&&b<=n.eg||b>=n.de&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==br||f==cr?d.push(f|(c?0:ar)):(h==P?a.C&(Qq|Rq)||a.C&Sq&&b||(g=h):h==dr?a.C&(Tq|er)||(g=h):h==fr?a.C&(Uq|gr)||(g=h):d.push(f|(c?0:ar)),g&&(c?d.unshift(g):d.push(g|ar)))}for(c=0;c"]]=52|P<<8;O[n["/"]]=53; +O[n["?"]]=53|P<<8;O[3016]=54;O[1044]=55;O[1018]=fr;O[1032]=57;O[wq]=58;O[1112]=59;O[1113]=60;O[1114]=61;O[1115]=62;O[1116]=63;O[1117]=64;O[1118]=65;O[1119]=66;O[1120]=67;O[1121]=68;O[xq]=69;O[yq]=70;O[1036]=71;O[1038]=72;O[1033]=73;O[1109]=74;O[1037]=75;O[1101]=76;O[1039]=77;O[1107]=78;O[1035]=79;O[1040]=80;O[1034]=81;O[1045]=82;O[1046]=$q;O[4027]=84;O[1122]=87;O[1123]=88;O[1091]=91;O[1093]=93;O[1224]=91;O[jr]=46|dr<<8;O[Vq]=70|dr<<8;O[4046]=$q|dr<<8|fr<<16;O[4045]=82|dr<<8|fr<<16; +O[4013]=28|dr<<8|fr<<16;var sp=255,vp=243,xp=237,Gq=170,tp=250,ir=255,hr=20;ab(function(){for(var a=Ab(document,"pcx86","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Xc=c[1];this.Ze=c[2];this.fa=c[3];this.ec=c[4]&255;this.Fg=c[4]>>8&255;this.Wa=c[5];this.oh=mr;this.gg=or;if(b>=bq){this.oh=nr;this.gg=pr;(b=c[6])||(b=[!1,0,Array(qr),0,f== +Ul?0:rr,0,0,Array(sr),0,0,0,Array(tr),0,[this.bb,this.Ob,this.qd],Array(this.qd>>2),ur|vr|wr|xr|yr,0,-1,0,-1,0,-1,0,0,0,0,zr,Ar,0,0,Br,Array(Cr)]);this.Ke=b[0];this.wd=b[1];this.Cc=b[2];this.Tg=Dr;this.Ig=b[3];this.af=b[4];this.Pf=b[5];this.zd=b[6];this.$d=b[7];this.Vg=Er;this.Wk=b[8];this.Xk=b[9];this.yd=b[10];this.xd=b[11];this.Ug=Fr;this.tb=b[12];d=b[13];"number"==typeof d&&(d=[this.bb,this.Ob,d]);this.bb=d[0];this.Ob=d[1];d=this.qd>>2;if((this.fd=b[14])&&this.fd.length=bq){var c=[];c[0]=a.Ke;c[1]=a.wd;c[2]=a.Cc;c[3]=a.Ig;c[4]=a.af;c[5]=a.Pf;c[6]=a.zd;c[7]=a.$d;c[8]=a.Wk;c[9]=a.Xk;c[10]=a.yd;c[11]=a.xd;c[12]=a.tb;c[13]=[a.bb,a.Ob,a.qd];var d;if(d=a.fd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=bq){var d=0,e=0,f=0;switch(b){case Or:d=Pr;a.La==dq&&(e=Qr);break;case Rr:a.La==bq&&(d=Sr);break;case Tr:d=Ur;a.La==dq&&(e=Vr);break;case Wr:d=Xr;a.La==dq&&(e=Yr);break;case Zr:d=$r;a.La==dq&&(f=as);break;case bs:d=cs,a.La==dq&&(f=ds)}d&&(c|=a.Wa[es]&d?256:0,c|=a.Wa[es]&e?512:0,c|=a.Wa[fs]&f?512:0)}return c} +var mr=18,Or=6,es=7,Pr=1,Xr=2,Ur=4,$r=8,cs=16,Sr=32,Qr=32,Yr=64,Vr=128,fs=9,as=32,ds=64,Rr=10,Tr=16,Wr=18,Zr=21,bs=24,nr=25,or="HTOTAL HDISP HSYNC_POS HSYNC_WIDTH VTOTAL VTOTAL_ADJ VDISP VSYNC_POS INTERLACE_POS MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO LIGHT_PEN_HI LIGHT_PEN_LO".split(" "),pr="HTOTAL HDISP_END HBLANK_START HBLANK_END HRETRACE_START HRETRACE_END VTOTAL OVERFLOW PRESET_SCAN MAX_SCAN CURSOR_START CURSOR_END START_ADDR_HI START_ADDR_LO CURSOR_ADDR_HI CURSOR_ADDR_LO VRETRACE_START VRETRACE_END VDISP_END OFFSET UNDERLINE VBLANK_START VBLANK_END MODE_CTRL LINE_COMPARE".split(" "), +qr=20,Dr="PAL00 PAL01 PAL02 PAL03 PAL04 PAL05 PAL06 PAL07 PAL08 PAL09 PAL0A PAL0B PAL0C PAL0D PAL0E PAL0F MODE OVERSCAN PLANES HPAN".split(" "),rr=1,zr=1,sr=5,Er=["RESET","CLOCKING","MAPMASK","CHARMAP","MEMMODE"],Ar=255,Br=0,Cr=256,tr=9,Fr="SRESET ESRESET COLORCMP DATAROT READMAP MODE MISC COLORDC BITMASK".split(" "),ur=1024,vr=4096,Lr=65280,wr=0,xr=16,Nr=255,yr=-2147483648,Gr=[];Gr[2]=ur;Gr[3]=ur|vr;Gr[16]=1280;Gr[512]=wr;Gr[1024]=wr|32;Gr[1536]=wr|96;Gr[2560]=wr|160;Gr[3584]=wr|224;Gr[768]=wr|xr; +Gr[4096]=1;Gr[8192]=2;Gr[24576]=98;Gr[40960]=162;Gr[57344]=226;var Mr=[];Mr[ur]=function(a){a+=this.H;return(this.controller.tb=this.X[a])>>this.controller.ei&255};Mr[ur|16384]=function(a){return(this.controller.tb=this.X[(a&-4)+this.H])>>((a&3)<<3)&255};Mr[ur|vr]=function(a){a+=this.H;var b=this.controller.tb=this.X[a&-2];return(a&1?b>>8:b)&255}; +Mr[1280]=function(a){a+=this.H;a=this.controller.tb=this.X[a];for(var b=this.controller.qh,c=this.controller.ph&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Mr[wr]=function(a,b){a+=this.H;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|32]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|96]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b&=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|160]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b|=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +Mr[wr|224]=function(a,b){a+=this.H;b=b>>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Yd;b^=this.controller.tb;b=b&this.controller.Bb|this.controller.tb&~this.controller.Bb;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)};Mr[wr|4]=function(a,b){var c=(a&-4)+this.H;a=(a&3)<<3;b=b<>this.controller.Qc|b<<8-this.controller.Qc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Bb;b=this.controller.Hf&b|this.controller.tb&~b;b=b&this.controller.gb|this.X[a]&~this.controller.gb;this.X[a]!=b&&(this.X[a]=b,this.Oa=!0)}; +function Q(a,b,c,d,e){nb.call(this,"Video",a,262144);var f=this;this.Tc=Ua("Gecko/");var g=["","moz","ms","webkit"];this.ca=a.model;var h=hs[this.ca]||hs.mda;this.La=h[0];this.qd=a.memory||0;this.cd=a.switches;this.da=a.mode;if(null==this.da||null==is[this.da])this.da=h[1];this.Fb=a.charCols;this.sc=a.charRows;if(void 0===this.Fb||void 0===this.sc)this.Fb=is[this.da][0],this.sc=is[this.da][1];this.Z=a.screenWidth;this.la=a.screenHeight;this.Uc=a.scale;this.Cd=12<=Math.round(this.Z/this.Fb);this.O= +b;this.L=c;this.D=(this.Qd=d)||b||null;b=a.smoothing;(c=Va("smoothing"))&&(b="true"==c);if(null!=b)for(c=0;c=bq&&(Oc(b,this,ss),Sc(b,this,ts));this.La==dq&&(Oc(b,this,us),Sc(b,this,vs));if(d){var e=this;Al(d,262144,function(a){if(e.C)if(a[0]){var b=e.C;if(b.fd){var c,d,f,g=!1,u=8,F=8,K=-1,H=b.video.F>>3;for(c=0;c=d&&(F=d,g=!0);break; +case "p":0<=d&&3>=d&&(K=d);break;case "w":d=b.bb&&(f-=b.bb);a="";for(c=0;cK?q(T):qa(T>>(K<<3),8));g&&(f+=H-F);a&&(a+="\n");a+=I}a&&b.ba.P(a);b.B=f}else b.ba.P("no buffer")}else e.ba.P("BIOSMODE: "+r(e.oa)),b=e.C,Jr(b,"CRTC",b.ec,b.Wa,b.gg),b.La>=bq&&(Jr(b," GRC",b.yd,b.xd,b.Ug),Jr(b," SEQ",b.zd,b.$d,b.Vg),Jr(b," ATC",b.wd,b.Cc, +b.Tg),Jr(b," ATCINDX",b.wd),b.ba.P(" ATCDATA: "+b.Ke),Jr(b," FEAT",b.Pf),Jr(b," MISC",b.af),Jr(b," STATUS0",b.Ig)),Jr(b," STATUS1",b.fa),b.La!=ps&&b.La!=ms||Jr(b," MODEREG",b.Xc),b.La==ms&&Jr(b," COLOR",b.Ze),b.La>=bq&&(b.ba.P(" LATCHES: "+q(b.tb)),b.ba.P(" ACCESS: "+q(b.tg,4)),b.ba.P("Use 'dump video [addr]' to dump video memory"));else e.ba.P("no active video card")})}if((this.B=Xb(a,"Keyboard"))&&this.O){for(var f in this.na)0c&&(a=Math.round(c/b*100)+"%")}this.Tc?(this.O.style.width=a,this.O.style.width=a,this.O.style.display="block",this.O.style.margin="auto"):(this.N.style.width=a,this.N.style.height="auto");this.N.style.backgroundColor="black";this.N.Je();a=!0}this.D&&this.D.focus()}return a}; +function ks(a,b){!b&&a.N&&(a.Tc?a.O.style.width=a.O.style.height="":a.N.style.width=a.N.style.height="");Mb(a,"notifyFullScreen("+b+")",!0);a.B&&(a.B.dh=b)}l.me=function(a){var b=!1;this.D&&(a?this.D.me&&(this.D.me(),this.G&&this.G.If(!0),b=!0):this.D.dl&&(this.D.dl(),this.G&&this.G.If(!1),b=!0),this.D&&this.D.focus());return b};l.If=function(a){this.G&&(this.G.If(a),this.B&&(this.B.dh=a));var b=this.na.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Dd)}; +function ws(a,b){var c=a.D;c&&!a.tc&&(c.addEventListener("touchstart",function(b){As(a,b,!0)},!1),c.addEventListener("touchmove",function(b){As(a,b)},!0),c.addEventListener("touchend",function(b){As(a,b,!1)},!1),a.tc=b,a.qb=a.rb=a.kd=-1,a.lc=!1,a.Db=null,a.kc=!1,a.Pd=function(){a.kc=!0;a.G.Vd(Bs,!0)})}l.Bg=function(a){this.B&&this.B.Bg(a)}; +function As(a,b,c){var d,e,f=0,g=0;e=a.O;do isNaN(e.offsetLeft)||(f+=e.offsetLeft,g+=e.offsetTop);while(e=e.offsetParent);var h=a.Z/a.O.offsetWidth,k=a.la/a.O.offsetHeight;b.targetTouches&&b.targetTouches.length?(d=b.targetTouches[0].pageX,e=b.targetTouches[0].pageY):(d=b.pageX,e=b.pageY);d=(d-f)*h;e=(e-g)*k;if(a.tc==ys)d=d/(a.Z/3)|0,e=e/(a.la/3)|0,1!=e?e?vq(a.B,1040,!0):vq(a.B,1038,!0):1!=d&&(d?vq(a.B,1039,!0):vq(a.B,1037,!0));else if(a.G){g=a.lc;f=b.timeStamp-a.kd;!0===c?(a.lc=500f){a.G.Vd(Bs,!0);a.G.Vd(Bs,!1);return}}if(c||0>a.qb||0>a.rb)a.qb=d,a.rb=e;c=Math.round(d-a.qb);b=Math.round(e-a.rb);a.qb=d;a.rb=e;a.G.tf(c,b,a.qb,a.rb)}}l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0}; +l.reset=function(){var a=!0,b=0;this.W&&(b=+Tl(this.W,hl,void 0));this.ca||(this.La=b==Ul?ps:ms);this.da=Cs;switch(this.La){case dq:b=7;break;case bq:var c=Ds[this.xb];c&&(b=c[0]);b||(b=4);break;case ps:b=Ul;this.da=Es;break;default:b=2}this.ga!==b&&(this.ga=b,a=!0);this.C=null;this.Y=this.Kb=new kr(this,ps);this.K=this.yb=new kr(this,ms);this.La>1&255,d=d>>8&~Is,d>>4==(d&15)&&(d^=15)):(c=d&255,d=(d&256?Js|Ks:Ls|Ms)|Ns&d>>8);Kc(this.ka,b,c|d<<8)}zs(this,!0)}};function Fs(a){a.A.af&rr?(a.Y=a.Kb,a.K=a.A):(a.Y=a.A,a.K=a.yb)}l.save=function(){var a=new Xf(this);a.set(0,Ir(this.Kb));a.set(1,Ir(this.yb));a.set(2,[this.ga,this.da,this.oa]);a.set(3,Ir(this.A));return a.data()}; +l.restore=function(a){var b=a[2];this.ga=b[0];this.da=b[1];this.oa=b[2];this.C=null;this.Y=this.Kb=new kr(this,ps,a[0]);this.K=this.yb=new kr(this,ms,a[1]);this.A=new kr(this,this.La,a[3],this.qd);this.A.rc&&Fs(this);Gs(this);if(!Os(this))return!1;Ps(this);return!0}; +function ls(a,b,c,d){if(d)a.Fa("Unable to load font ROM (error "+d+": "+b+")");else{pb(a.xe,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){hb("Empty font ROM: "+b);return}if(1==f.length){hb(f[0]);return}if(8192==f.length)cq(a,f,[6144,0]);else if(2048==f.length)cq(a,f,[0]);else{a.Fa("Unrecognized font data length ("+f.length+")");return}}catch(g){a.Fa("Font ROM data error: "+g.message);return}(a.L||a.ba)&&Jb(a)}} +function Qs(a,b){if(1==b)return a.ha[0]=Rs[Ls],a.ha[1]=Rs[Js],a.ha;if(2==b){var c=a.C.Ze;if(a.C===a.A){var d=a.A.Cc[0],c=d&7;d&16&&(c|=8);18!=a.A.Cc[1]&&(c|=32)}a.ha[0]=Rs[c&15];c=c&32?Ss:Ts;for(d=0;de;e++)f=d[e]||0,g=f<<2&252,h=f>>4&252,f=f>>10&252,a.ha[e]=[g,h,f,255];else{var k=d&&d[255];b=null!=c.Cc[15]?c.Cc:Us;for(e=0;16>e;e++)f=b[e]&63,k?(f|= +(c.Cc[20]&12)<<4,c.Cc[16]&128&&(f&=-49,f|=(c.Cc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.ha[e]=[g,h,f,255]}a.Ga=!0}return a.ha}function cq(a,b,c,d){a.wb=b;a.Ta=c;a.Da=d} +function Gs(a,b){var c=!1;if(window&&a.wb&&(!b||a.I)){b=0;var d=a.Da?a.Da:8,e=Qs(a);null!=a.Ta[0]&&Vs(a,Ws,a.Ta[0],b,d,8,a.wb,e)&&(c=!0);b=a.Da?0:2048;d=a.Da?a.Da:9;null!=a.Ta[1]&&(Vs(a,Xs,a.Ta[1],b,d,14,a.wb,Ys,Zs)&&(c=!0),a.Da&&Vs(a,a.La,a.Ta[1],0,a.Da,14,a.wb,e)&&(c=!0))}return c}function Vs(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&($s(a,b,c,d,e,f,g,h,k)&&(m=!0),a.Cd&&$s(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} +function $s(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,w=a.va[b],u=16>h.length?h.length:16;w||(w={Fc:e<ua||!T?ua:8,ib=cb.createImageData(m.Fc,m.Gc);for(Sa=0;256>Sa;Sa++){for(db=0;db=ua-2,Ld=ca[db>(8<=rb&&192<=Sa&&223>=Sa?7:rb)?F:xb;at(ib,sg,ef,tg);H&&at(ib,sg+1,ef,tg)}cb.putImageData(ib,(Sa&15)*m.Fc,(Sa>>4)*m.Gc)}m.Be[K]="#"+q(F[0],2)+q(F[1],2)+q(F[2],2);m.Qi[K]=F;m.Sg[K]=za;m=!0}}a.va[b]=w;return m}function bt(a){0a.Aa&&(a.Aa=0):a.Aa=-1} +function Ps(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.C.Wa[b])return;var c=a.C.Wa[10],b=c&31,d=a.C.Wa[11]&31,e=a.C.Wa[9]&31,f=!1;a.C===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ct(a);else{c=a.C.Wa[15]+((a.C.Wa[14]&63)<<8);a.aa!=c&&(ct(a),a.aa=c);d=d-b+1;if(a.md!=b||a.Hc!=d)a.md=b,a.Hc=d;a.za=e+1;bt(a)}}} +function ct(a){if(0<=a.aa){if(void 0!==a.M){var b=dt<<8,c=a.M[a.aa];if(c&b){var c=c&~b,b=a.aa%a.F,d=a.aa/a.F|0;a.I&&a.va[a.I]&&(a.Ca&&et(a,b,d,c,a.Ca),et(a,b,d,c));a.M[a.aa]=c}}a.aa=-1}} +function ft(a){var b,c=a.C;a.Pc=!1;var d=c.xd[5];if(null!=d){b=ur;var e=wr,f=c.xd[3]&31;switch(d&3){case 0:if(f){e=wr|32;switch(f&24){case 8:e=wr|96;break;case 16:e=wr|160;break;case 24:e=wr|224}c.Qc=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.La==dq&&(e=3,c.Qc=f&7)}d&8&&(b=1280);c=c.$d[4];null!=c&&(c&4||(b|=vr,e|=xr),d&64&&(c&8&&(b|=16384,e|=4),a.Pc=!0));b|=e}return b} +function gt(a,b){var c=a.C;return c&&null!=b&&b!=c.tg?(c.Kg(b),a.ka.Kg(c.bb,c.Ob,c.fh(),!0),!0):!1} +function Os(a,b){var c,d=a.oa,e=a.C;if(e)if(e.La==ps)d=Es;else if(e.La>=bq){var d=null,f=e.qd>>2,g=32768=e.Wa[Wr]?lt:mt:nt:g&128|| +350>f?d=m?ot:pt:480<=f&&(d=a.ga==Ul?qt:rt):d=m?7-d:st:d-=m?2:0);c=ft(a)}}else e.Xc&8&&(e.Xc&2?(d=e.Xc&16?st:Rt,e.Xc&4||--d):(d=e.Xc&1?Cs:Tt,e.Xc&4&&--d));else a.oa=null,null==d&&(d=a.da);if(!Hs(a,d,b))return!1;gt(a,c);return!0} +function Hs(a,b,c){if(null!=b&&(b!=a.oa||c)){a.Ad=0;a.oa=b;a.Ga=!1;b=a.C||(b==Es?a.Y:a.K);if(b!=a.C||b.bb!=a.bb||b.Ob!=a.Ob){ct(a);if(a.bb){if(!Cc(a.ka,a.bb,a.Ob))return!1;a.C&&(a.C.rc=!1)}a.C=b;b.rc=!0;a.bb=b.bb;a.Ob=b.Ob;if(!pc(a.ka,b.bb,b.Ob,3,b===a.A?b:null))return!1}a:{a.I=0;a.F=a.Fb;a.J=a.sc;a.Ma=a.F;a.Eb=is[Es][2];b=0;if(c=is[a.oa])a.F=c[0],a.J=c[1],a.Eb=c[2],b=c[3],a.I=c[4],4!=a.ga&&7!=a.ga||a.C!==a.A||a.I!=Ws||(7==(a.A.Wa[fs]&31)?a.J=350>Kr(a.A,Wr)?43:50:a.I=a.La);a.Wc=a.F*a.J|0;a.Vc=a.Wc/ +a.Eb|0;a.Za=a.Vc;a.Pb=0;void 0!==b&&(a.Za=(a.Za<<1)+b|0,a.Pb=a.Za+b>>1);if(a.va.length){a.qa=a.Z/a.F|0;a.ta=a.la/a.J|0;if(a.I){b=a.va[a.I];if(!b)break a;c=a.va[a.I<<1];a.Uc&&80==a.F?c&&a.qa>=3*c.Fc>>2&&(a.I<<=1,b=c):(c&&a.qa>=c.Fc&&(a.I<<=1,b=c),a.Uc||(a.qa=b.Fc,a.ta=b.Gc));a.$a=a.eb=0;b&&(a.$a=a.F*b.Fc,a.eb=a.J*b.Gc)}else a.qa=a.ta=1,a.$a=a.F,a.eb=a.J;a.Ha=a.L.createImageData(a.$a,a.eb);a.Ba=document.createElement("canvas");a.Ba.width=a.$a;a.Ba.height=a.eb;a.Ca=a.Ba.getContext("2d");a.vc=a.zc=0; +a.Qb=a.Z;a.Rb=a.la;b=a.Z-a.F*a.qa;c=a.la-a.J*a.ta;0>1,a.Qb-=b);0>1,a.Rb-=c);if(b||c)a.L.fillStyle=a.O.style.backgroundColor,a.L.fillRect(0,0,a.Z,a.la)}}Ut(a,!0);zs(a)}return!0}function at(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function Vt(a){a.ya=-1;a.ma=!1;var b=a.Vc;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function Ut(a,b){b||(a.Ga=!1);Vt(a)} +function et(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.va[a.I];h.jf&&(d=h.jf[d]);var k=g>>4&15;h.jf&&(k=h.jf[k]);e?(b*=h.Fc,c*=h.Gc,e.fillStyle=h.Be[k],e.fillRect(b,c,h.Fc,h.Gc)):(b=b*a.qa+a.vc,c=c*a.ta+a.zc,a.L.fillStyle=h.Be[k],a.L.fillRect(b,c,a.qa,a.ta));g&Wt&&(k=(f&15)*h.Fc,f=(f>>4)*h.Gc,e?e.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,h.Fc,h.Gc):a.L.drawImage(h.Sg[d],k,f,h.Fc,h.Gc,b,c,a.qa,a.ta));g&dt&&(f=a.md,g=a.Hc,e?(a.za&&a.za!==h.Gc&&(f=f*h.Gc/a.za|0,g=g*h.Gc/a.za|0),e.fillStyle=h.Be[d],e.fillRect(b, +c+f,h.Fc,g)):(a.za&&a.za!==a.ta&&(f=f*a.ta/a.za|0,g=g*a.ta/a.za|0),a.L.fillStyle=h.Be[d],a.L.fillRect(b,c+f,a.qa,g)))} +function zs(a,b){if(a.ea.Yb){var c=!1,d=a.C;d&&(d!==a.A?d.Xc&8&&(c=!0):d.wd&32&&(c=!0));if(c||b){if(b)Vt(a);else if(void 0===a.M)return;var e=!1;!(b||++a.Ad&15)&&0<=a.Aa&&(a.Aa++,e=!0);var f=0,g=a.Wc,h=a.bb,c=h,k=c+a.Ob;a.oa>=lt&&(h=c=655360,k=c+65536);if(Xt(a,d)&8||d.Ye&&d.Ye=bq&&d.Wa[19]&&d.Wa[19]<<1!=d.Wa[1]+1&&(a.Ma=d.Wa[19]<<(a.I?1:d.Wa[20]&64?3:4),m=(a.Ma*(a.J-1)+a.F)/a.Eb|0,a.oa<=Es&& +(m<<=1));c+m>k&&(m=k-c,0>m&&(m=0));k=c+m;if(b=!b&&a.ma){b=a.ka;for(var p=!0,w=c>>>b.A;0f)return;g=f+1}}if(a.I){if(a.va[a.I]){d=f;f=0;e=a.ya=0;h=Wt<<8;b=1048575;p=a.C.Xc&32;a.La>=bq&&(p=a.C.Cc[16]&8);m=a.aa-a.C.vd;p&&(e=Is<<8,b&=~e,a.Aa&2||(b&=~h));for(c+=d<<1;c>8|(u&255)<<8;var I=e,T=16;m>=h))>>(T-=h);at(a.Ha,m++,p,b[ua])}m>F&&(F=m);p=H&&(H=p+1)}k+=2;d++;if(m>=a.F){m=0;p+=2;if(p>a.J)break;p==a.J&&(p=1,k=c+a.Pb)}}a.ma=!0; +wa.F?a.Ma-a.F-u>>3:0;c>=8;b>w&&(w=b);m=K&&(K=m+1)}c+=H;if(b>=a.F){b=0;if(++m>a.J)break;c+=I}}u||(a.ma=!0);pa.F?a.Ma-a.F-K>>3:0;cI&&(T=I)):(u<<=K,T-=K,a.ma=!1):(a.ma&&u===a.M[d]?(h+=T,T=0):a.M[d]=u,d++);if(T){hp&&(p=h);b=F&&(F=b+1)}if(h>=a.F){h=0;if(++b>a.J)break;c+=H}}K||(a.ma=!0);ma&&(b.wh=a,a=-a|0);a%b.rh>b.mn&&(c|=1);a%b.uh>b.on&&(c|=9);b.fi=a/b.uh|0;return c}l.Cm=function(a,b){return Zt(this,this.Y,a,b)};l.fo=function(a,b,c){var d=this.Y;d.Fg=d.ec;d.ec=b&31;v(this,a,b,c,"CRTC.INDX")};l.Bm=function(a,b){return $t(this,this.Y,a,b)};l.eo=function(a,b,c){au(this,this.Y,a,b,c)};l.Dm=function(a,b){return bu(this,this.Y,b)};l.ho=function(a,b,c){a=this.Y;v(this,a.port+4,b,c,"MODE");a.Xc=b;Os(this,!1)}; +l.Em=function(a,b){return cu(this,this.Y,b)};l.Mk=function(a,b,c){this.A.Pf=this.A.Pf&-4|b&3;v(this,a,b,c,"FEAT")};l.am=function(a,b){a=this.A.wd;b&&!t(this)||v(this,960,null,b,"ATC.INDX",a);return a};l.rl=function(a,b){a=this.A.Cc[this.A.wd&31];b&&!t(this)||v(this,960,null,b,"ATC."+this.A.Tg[this.A.wd&31],a);return a}; +l.Lk=function(a,b,c){var d=this.A,e=d.wd&32;if(d.Ke){d.Ke=!1;var f=d.wd&31;if(16<=f||!e)if(du||d.Cc[f]!==b)c&&!t(this)||v(this,a,b,c,"ATC."+d.Tg[f]),d.Cc[f]=b,Ut(this,!1)}else d.wd=b,v(this,a,b,c,"ATC.INDX"),d.Ke=!0,b&32&&!e&&Gs(this,!0)&&zs(this,!0),a=(d.Wa[12]<<8)+d.Wa[13]|0,d.vd!=a&&(d.vd=a,Ut(this)),d.Ye=0}; +l.Om=function(a,b){a=0;if(this.La==bq)a=3-((this.A.af&12)>>2),a=(this.xb&1<>this.A.xc&63;b&&!t(this)||v(this,969,null,b,"DAC.DATA["+r(this.A.dd)+"]["+r(this.A.xc)+"]",a);this.A.xc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=Na().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= +(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||Va("aspect"));f&&.3<=f&&3.33>=f&&($a("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ua("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d"),d=new Q(d,e,g,f,c);zb(d,c)}}); +function eu(a){nb.call(this,"ParallelPort",a,4194304);this.G=a.adapter;switch(this.G){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:hb("Unrecognized parallel adapter #"+this.G);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":yb(this,a,fu)}ba(eu,nb);l=eu.prototype;l.Cb=function(a,b,c){switch(b){case fu:return this.na[b]=this.A=c,!0}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.W=Xb(a,"ChipSet");Oc(b,this,gu,this.D);Sc(b,this,hu,this.D);Jb(this)};l.Xb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){iu(this)};l.save=function(){var a=new Xf(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Mb;c[b]=this.mf;a.set(0,c);return a.data()};l.restore=function(a){return iu(this,a[0])}; +function iu(a,b){var c=0;b||(b=[0,0,0]);a.F=b[c++];a.Mb=b[c++];a.mf=b[c];return!0}l.pm=function(a,b){var c=this.F;v(this,a,null,b,"DATA",c);return c};l.Nm=function(a,b){var c=this.Mb;v(this,a,null,b,"STAT",c);return c};l.lm=function(a,b){var c=this.mf;v(this,a,null,b,"CTRL",c);return c}; +l.Rn=function(a,b,c){v(this,a,b,c,"DATA");this.F=b;this.Mb|=ju;a=!1;Mb(this,"transmitByte("+r(b)+")");this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.P(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Mb&=~ju);ku(this)};l.Mn=function(a,b,c){v(this,a,b,c,"CTRL");this.mf=b;ku(this)}; +function ku(a){a.W&&a.C&&(a.mf&lu&&!(a.Mb&ju)?hh(a.W,a.C):fh(a.W,a.C))}var fu="buffer",ju=64,lu=16,gu={0:eu.prototype.pm,1:eu.prototype.Nm,2:eu.prototype.lm},hu={0:eu.prototype.Rn,2:eu.prototype.Mn};ab(function(){for(var a=Ab(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Ca(c[0]);if(d!=this.be)return;c=Ca(c[1]);if(this.D=ub(c)){var e=this.D.exports;if(e){var f=e.connect;f&&f.call(this.D,this.O);if(this.aa=e.receiveData){this.O=a;this.Y=e.receiveStatus;this.status("Connected "+this.xe+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.Xb=function(a,b){if(!b)if(this.zj(this.O),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Wb=function(a){return a?this.save():!0};l.reset=function(){su(this)};l.save=function(){var a=new Xf(this),b=0,c=[];c[b++]=this.ga;c[b++]=this.la;c[b++]=this.L;c[b++]=this.N;c[b++]=this.G;c[b++]=this.C;c[b++]=this.Z;c[b++]=this.B;c[b++]=this.A;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return su(this,a[0])}; +function su(a,b){var c=0;b||(b=[0,0,tu,0,uu,0,0,vu|wu,a.qa,[]]);a.ga=b[c++];a.la=b[c++];a.L=b[c++];a.N=b[c++];a.G=b[c++];a.C=b[c++];a.Z=b[c++];a.B=b[c++];a.A=b[c++];a.J=b[c];return!0}l.Of=function(a){if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.N;v(this,a,null,b,this.C&Cu?"DLM":"IER",c);return c};l.xm=function(a,b){var c=this.G;v(this,a,null,b,"IIR",c);return c};l.ym=function(a,b){var c=this.C;v(this,a,null,b,"LCR",c);return c};l.Am=function(a,b){var c=this.Z;v(this,a,null,b,"MCR",c);return c}; +l.zm=function(a,b){var c=this.B;v(this,a,null,b,"LSR",c);return c};l.Fm=function(a,b){var c=this.A;this.A&=~(yu|zu);v(this,a,null,b,"MSR",c);return c}; +l.po=function(a,b,c){v(this,a,b,c,this.C&Cu?"DLL":"THR");if(this.C&Cu)this.L=this.L&-256|b;else{this.la=b;this.B&=~(vu|wu);a=!1;Mb(this,"transmitByte("+r(b)+")");this.aa&&this.aa.call(this.D,b)&&(a=!0);if(this.F){if(13==b)this.K=0;else if(8==b)this.F.value=this.F.value.slice(0,-1),0":String.fromCharCode(b);a=d.length;32>b&&1==a&&(a=0);9==b&&(b=this.oa||8,a=b-this.K%b,this.oa&&(d=Ba("",a)));this.ma&&!this.K&&a&&(d=String.fromCharCode(this.ma)+ +d);this.F.value+=d;this.F.scrollTop=this.F.scrollHeight;this.K+=a}a=!0}else if(null!=this.I){if(10==b||1024<=this.I.length)this.P(this.I),this.I="";10!=b&&(this.I+=String.fromCharCode(b));a=!0}a&&(this.B=this.B|vu|wu)}};l.ao=function(a,b,c){v(this,a,b,c,this.C&Cu?"DLM":"IER");this.C&Cu?this.L=this.L&255|b<<8:this.N=b};l.bo=function(a,b,c){v(this,a,b,c,"LCR");this.C=b}; +l.co=function(a,b,c){var d=b^this.Z;v(this,a,b,c,"MCR");this.Z=b;d&(Du|Eu)&&this.Y&&(a=0,this.O?(a|=b&Eu?32:0,a|=b&Du?320:0):(a|=b&Eu?16:0,a|=b&Du?1048576:0),this.Y.call(this.D,a))};function Au(a){var b=-1;a.B&Bu&&a.N&Fu?b=Gu:a.A&(yu|zu)&&a.N&Hu&&(b=Iu);0<=b?(a.G&=~(uu|Ju),a.G|=b,a.W&&a.M&&hh(a.W,a.M,100)):(a.G|=uu,a.W&&a.M&&fh(a.W,a.M))} +var pu="buffer",tu=384,Fu=1,Hu=8,uu=1,Gu=4,Iu=0,Ju=6,Cu=128,Du=1,Eu=2,Bu=1,vu=32,wu=64,yu=1,zu=2,nu=16,ou=32,qu={0:mu.prototype.Km,1:mu.prototype.wm,2:mu.prototype.xm,3:mu.prototype.ym,4:mu.prototype.Am,5:mu.prototype.zm,6:mu.prototype.Fm},ru={0:mu.prototype.po,1:mu.prototype.ao,3:mu.prototype.bo,4:mu.prototype.co};ab(function(){for(var a=Ab(document,"pcx86","serial"),b=0;ba.F||0>a.G)a.F=b.clientX,a.G=b.clientY;a.M?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.clientX-a.F,d=b.clientY-a.G);a.F=b.clientX;a.G=b.clientY;a.tf(c,d,a.F,a.G)}} +l.Vd=function(a,b){if(this.rc&&this.H&&this.H.ea.vb){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case Bs:if(this.K!=b){this.K=b;Qu(this,c);return}break;case Ru:if(this.L!=b){this.L=b;Qu(this,c);return}}Mb(this,c+": ignored")}};l.tf=function(a,b,c,d){this.rc&&this.H&&this.H.ea.vb&&(a||b)&&(this.I=a,this.J=b,Qu(this,null,c,d))}; +function Qu(a,b,c,d){var e=64|(a.K?32:0)|(a.L?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;t(a,8388608)&&Mb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+r(e)+","+r(f)+","+r(g)+"]",0,!0);a.D.Of([e,f,g]);a.I=a.J=0} +l.pl=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.A&16||(this.reset(),Mb(this,"serial mouse reset"),c=!0);this.A&1048576||(Mb(this,"serial mouse ID requested"),c=!0);c&&(this.D.Of([Su,Su]),Mb(this,"serial mouse ID sent"));Lu(this);this.rc=b}}else this.rc&&(Mb(this,"serial mouse inactive"),Mu(this),this.rc=b);this.A=a};var Su=77,Bs=0,Ru=2;ab(function(){for(var a=Ab(document,"pcx86","mouse"),b=0;b>2;var e=d=0,a=new DataView(a,0,c);g.A=Array(g.ob);for(c=0;cb.indexOf("/api/v1/dump")&&(a=wa(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=$u(this,b),this.og=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"):xa(b, +"/")&&(c="dir"),f=Ma()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Oe?"":d)+"&format=json"));return!!La(f,null,!0,function(a,b,c){av(g,a,b,c)})}; +function av(a,b,c,d){var e=null;a.Re=!1;var f=!(!(0>d&&a.pa)||a.pa.ea.Yb);if(a.og)d?a.controller.Fa('Unable to connect to disk "'+a.I+'" (error '+d+": "+c+")",f):(a.D=!0,bv(a),e=a);else if(d)a.controller.Fa('Unable to load disk "'+a.F+'" (error '+d+": "+b+")",f);else{pb(a.controller.xe,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)hb(h[0]);else{a.ob=h.length;a.ib=h[0].length;a.Ya=h[0][0].length;var k=h[0][0][0];a.Na=k&&k.length||512;for(d=c=0;d>2,p=k.pattern;void 0===p&&(p=k.pattern=0);var w=k.data;if(void 0===w){var u=k.bytes;if(void 0!==u&&u.length){for(var F= +m<<2,K=u.length;Kb;b++){if(128==ev(a,e,c+0,1)){d.Kf=ev(a,e,c+8,4);(e=dv(a,d.Kf))&&(f=!0);break}c+=16}if(!f)return}d.sf||(d.sf=ev(a,e,19,2)||ev(a,e,32,4),d.rf=ev(a,e,14,2),d.lh=d.rf+ev(a,e,22,2)*ev(a,e,16,1),d.vh=ev(a,e,17,2),d.vf=ev(a,e,13,1));d.jh=d.lh+((32*d.vh+(d.Na-1))/d.Na|0);d.kn=(d.sf-d.jh)/d.vf|0;d.vg=4084>=d.kn?12:16;d.Nl=12==d.vg?4086:65526;b=[];for(e=d.lh;e>=8;f+=2;if(k)for(;m--;)sv(d,f,1),254>=k?(p=k,w=sv(d,f+1),f+=3):(p=sv(d,f+3,1),w=sv(d,f+4),f+=6),d.nd[p]&&(d.nd[p].ee[h]=[w]),d.A[h]=[p,w],h++;else h+=m}(g=hv(e,vv,c))&&wv(e,g+c);g=hv(e,xv,c);h=hv(e,yv,c);g&&h&&wv(e,g,g+h)}}}} +function gv(a,b,c,d,e){var f,g=a.C.length,h=b.Na/32|0;b.cq=d+"\\";for(var k=0;kK)break;for(var H=u.jh+(K-2)*u.vf,I=0;I>3,1),d?e=16==b.vg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} +function dv(a,b){var c=a.ib*a.Ya,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function Zu(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Ol=b;a.Pl=c;a.hd=a.Lc=0;a.Oa=!1;return a} +function $u(a,b){b="action=open&volume="+b+("&mode="+a.mode);b+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;b+="&machine="+Xu(a.controller);b+="&user="+Yu(a.controller);return Ma()+"/api/v1/disk?"+b} +function Bv(a,b,c,d,e,f,g){if(a.D){var h;h="action=read&volume="+a.I;h+="&chs="+a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h=h+("&addr="+b+":"+c+":"+d+":"+e)+("&machine="+Xu(a.controller));h+="&user="+Yu(a.controller);La(Ma()+"/api/v1/disk?"+h,null,f,function(h,m,p){h=[b,c,d,e,f,g];var k=!1,u=h[0],F=h[1],K=h[2],H=h[3];if(!p){m=JSON.parse(m);for(k=0;H--;){var I=a.seek(u,F,K,!0);if(!I)break;cv(I,m,k);k+=I.length;K++}k=h[4]}(h=h[5])&&h(p,k)})}else g&&g(-1,!1)} +function Cv(a,b,c,d,e,f,g){if(a.D){var h={};a.N=!0;h.action="write";h.volume=a.I;h.chs=a.ob+":"+a.ib+":"+a.Ya+":"+a.Na;h.addr=b+":"+c+":"+d+":"+e;h.machine=Xu(a.controller);h.user=Yu(a.controller);h.data=JSON.stringify(f);La(Ma()+"/api/v1/disk",h,g,function(f,h,p){var k=[b,c,d,e,g];f=k[0];h=k[1];var m=k[2],F=k[3],k=k[4];a.N=!1;if(0<=f&&fb&&(b=0);2E3>2,e=Array(d),f=0;f>2,e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2,c=(d>((b&3)<<3)&255;return c}; +l.write=function(a,b,c){if(this.Re)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Lc?f=a.hd+a.Lc&&(a.Lc+=f-(a.hd+a.Lc)+1):(a.hd=f,a.Lc=1);d[f]=d[f]&~(255<=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+m+") out of range ("+ +b+" changes applied)";b=-1;break}if(this.Re){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.controller.Fa("Unable to restore disk '"+this.F+": "+c):bv(this);return b}; +l.toJSON=function(){var a;a=0;for(var b;b=dv(this,a++);)Hv(b);a=JSON.stringify(this.A,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; +function Hv(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var Uu=0;function Av(a,b,c,d,e,f){this.sa=a;this.$b=c;this.Wg=d;this.aj=e;this.fe=f}function sv(a,b,c){var d;c=c||2;var e=b&511,f=dv(a.sa,a.fe[b>>9]);if(f){if(e+c<=f.length)return ev(a.sa,f,e,c);for(e=d=0;c--;)d|=sv(a,b++,1)<=e.gi&&a<=e.Ik){d=a-=e.gi;var f,g;for(g in e.ee){var h=e.ee[g],k=a-h[0];if(!k){c=this.Rf+"!"+h[1];break}b&&0'+b+"");a.innerHTML=b}};return!0;case "descDisk":case "listDrives":return this.na[b]=c,c.onchange=function(){var a=oa(c.value,10);null!=a&&Jv(d,a)},!0;case "loadDisk":return this.na[b]=c,c.onclick=function(){var a=d.na.listDisks;a&&Kv(d,a.options[a.selectedIndex].text,a.value)},!0;case "saveDisk":if(!this.M){c.parentNode.removeChild(c);break}this.na[b]=c;c.onclick=function(){var a=d.na.listDrives;a&&a.options&&d.A&&((a=d.A[oa(a.value, +10)||0])?(a=a.sa)?(a=Xa(Gv(a),"octet-stream",!0,a.Jg.replace(".json",".img")),hb(a)):d.Fa("No diskette loaded in drive."):d.Fa("No diskette drive selected."))};return!0;case "mountDisk":if(this.M)return this.na[b]=c,c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length}),c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Kv(d,va(b,!0),b,a)}return!1},!0;c.parentNode.removeChild(c)}return!1}; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.ba=d;this.pa=a;this.W=Xb(a,"ChipSet");if((this.G=zd(this.pa,"autoMount")||this.G)&&"string"==typeof this.G)try{this.G=eval("("+this.G+")")}catch(e){hb("FDC auto-mount error: "+e.message+" ("+this.G+")"),this.G=null}Lv(this);Oc(b,this,Mv);Sc(b,this,Nv);Ov(this,"None","",!0);this.M&&Ov(this,"Local Disk","?");Ov(this,"Remote Disk","??");Pv(this)||Jb(this)}; +l.Xb=function(a,b){if(!b){if(!a){if(this.reset(),this.pa.O){this.B=[];for(a=0;ag.sa.restore(F)&&(h=!1);h&&g.sa&&void 0!==g.Sa&&(g.cb=g.sa.seek(g.Gb,g.Xa,g.kb));h||(e=!1)}a.I=b[c++]||0;a.Zb=b[c]||Xv;return e} +function Rv(a){var b=0,c=[];c[b++]=a.Ua;c[b++]=0;c[b++]=a.fa;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.J;for(var d=b++,e=0,f=[],g=0;gVv(a,e,b,c,!1,d)&&window.confirm("Click OK to reload the original disk.\n(WARNING: All disk changes will be discarded)");){var f=a,g=c,h;for(h=0;ha.ob||f[1]>a.ib)&&(this.Fa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ua)),b=null);b?(a.sa=b,a.Zk=c,a.te=d,Wv(this,c,d,b),f=b.info(),this.I|=$v,this.Fa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ua),a.ke||e),a.ug=f[0],a.Af=f[1],a.Bf=f[2],this.pa&&this.pa.ld()):a.Ne=!1;a.ke&&(a.ke=!1,--this.K||Jb(this));Jv(this,a.Ua)}; +function Ov(a,b,c,d){if((a=a.na.listDisks)&&a.options){for(var e=0;e=this.C&&(this.fa&=~(cw|dw),this.D=this.C=0);return c}; +l.Tn=function(a,b,c){t(this)&&v(this,a,b,c,"DATA["+this.C+"]");this.C=fw[a].Id){b=!1;this.D=0;a=gw(this);var d,e,f,g,h=a&ew;switch(h){case hw:gw(this);gw(this);iw(this);break;case jw:c=gw(this);this.Ua=c&3;d=this.A[this.Ua];iw(this);kw(this,(d.pb&lw)>>>24);break;case mw:case nw:c=gw(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];d.Xa=b;c=d.Gb=gw(this);e=gw(this);f=d.kb=gw(this);g=gw(this);d.ub=128<>2&1;this.Ua= +c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=d.kb=1;g=0;d.pb=Zv;d.sa&&(d.cb=d.sa.seek(d.Gb,d.Xa,d.kb))?g=d.cb.length>>8:d.pb=ow|pw;rw(this,d,a,b,c,e,f,g);b=!0;break;case yw:c=gw(this);b=c>>2&1;this.Ua=c&3;d=this.A[this.Ua];c=d.Gb;e=d.Xa=b;f=1;g=gw(this);d.ub=128<>2&1,c=gw(this),d.Gb+=c-d.Sd,0>d.Gb&&(d.Gb=0),d.Gb>=d.ob&&(d.Gb=d.ob-1),d.Sd=c,d.pb=tw,d.Gb||(d.pb|=uw),iw(this),b=!0}0>>8);kw(a,(b.pb&Bw)>>>16);var k=0;if(e!=b.Gb||f!=b.Xa)k=g=1;c&Cw&&(f^=k,d||(k=0));kw(a,e+k);kw(a,f);kw(a,g);kw(a,h)}function gw(a){var b=a.F[a.D];a.D++;return b}function iw(a){a.D=a.C=0}function kw(a,b){a.F[a.C++]=b}l.jl=function(a,b,c){void 0===b||0>b?this.se(a,c):c(-1,!1)};l.kl=function(a,b){return void 0!==b&&0<=b?Dw(a,b):-1}; +l.Cl=function(a,b){if(void 0!==b&&0<=b)a:if(a.pb)a=-1;else{a.$c[a.Ge++]=b;if(a.Ge==a.$c.length){a.Gb=a.$c[0];a.Xa=a.$c[1];a.kb=a.$c[2];a.ub=128<Dw(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a};l.se=function(a,b){var c=-1,d=null,e=0;if(!a.pb&&a.sa){do{if(a.cb&&(e=a.Sa,0<=(c=a.sa.read(a.cb,a.Sa++)))){d=a.cb;break}a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=Ew|pw;break}a.Sa=0;Fw(a)}while(1)}b(c,!1,d,e)}; +function Dw(a,b){if(a.pb||!a.sa)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.cb=a.sa.seek(a.Gb,a.Xa,a.kb);if(!a.cb){a.pb=Gw|pw;b=-1;break}a.Sa=0;Fw(a)}while(1);return b}function Fw(a){a.kb++;a.kb>=a.Bf+1&&(a.kb=1,a.Xa++,a.Xa>=a.Af&&(a.Xa=0,a.Gb++))}var Uv="Floppy Drive",aw=4,bw=8,dw=16,cw=64,Sv=128,hw=3,jw=4,mw=5,nw=6,sw=7,vw=8,xw=10,yw=13,zw=15,ew=31,Cw=128,Zv=0,ow=8,tw=32,pw=64,Tv=192,ww=255,qw=512,Ew=1024,Gw=8192,Aw=65280,Bw=16711680,uw=268435456,lw=-16777216,$v=128,Xv=0;aa={}; +var fw={3:{Id:3,Ud:0,name:aa.Wp},4:{Id:2,Ud:1,name:aa.Up},5:{Id:9,Ud:7,name:aa.$p},6:{Id:9,Ud:7,name:aa.Qp},7:{Id:2,Ud:0,name:aa.Sp},8:{Id:1,Ud:2,name:aa.Vp},10:{Id:2,Ud:7,name:aa.Rp},13:{Id:6,Ud:7,name:aa.Np},15:{Id:3,Ud:0,name:aa.Tp}},Mv={1009:Iv.prototype.rm,1012:Iv.prototype.tm,1013:Iv.prototype.qm,1015:Iv.prototype.sm},Nv={1010:Iv.prototype.Un,1013:Iv.prototype.Tn,1015:Iv.prototype.Sn}; +ab(function(){for(var a=Ab(document,"pcx86","fdc"),b=0;bk.sa.restore(g)&&(F=!1),F&&void 0!==k.Sa&&(k.cb=k.sa.seek(k.Od,k.Xa,k.kb+k.ig)));F||(e=!1);null!=a.O&&1>=d&&(a.O|=(f.type&3)<<(1-d<< +1))}0<=a.Ua&&(a.B=a.A[a.Ua]);return e} +function Pw(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.va,c[b++]=a.J,c[b++]=a.ga,c[b++]=a.da,c[b++]=a.aa,c[b++]=a.Y,c[b++]=a.fa,c[b++]=a.ha,c[b++]=[a.L,a.Ua]):(c[b++]=a.O,c[b++]=a.fa,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ta,c[b++]=a.qa,c[b++]=a.oa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.fa&=~(Yw|Zw|$w));return c};l.ro=function(a,b,c){v(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.fa|=Yw,this.fa&=~bx,cx(this))};l.Um=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.fa=ex,a.se(a.B,function(b){0<=b?(fx(a),a.W&&a.W.ca==xl&&(a.fa=0),a.fa=a.fa|Qw|gx|hx):(a.fa=ix,a.I=jx)},!1)):a.fa=Qw|gx));return d}l.nl=function(a,b){return dx(this,a,b)|dx(this,a,b)<<8}; +function kx(a,b,c,d){if(a.B&&a.B.ub>=a.B.Na)if(0>lx(a.B,c))a.fa=ix,a.I=jx;else if(1==a.B.Sa||a.B.Sa==a.B.Na)t(a,1048832)&&v(a,b,c,d,"DATA["+a.B.Sa+"]"),1=a.B.Na&&(a.fa|=hx))}l.An=function(a,b,c){kx(this,a,b&255,c);kx(this,a,b>>8&255,c)};l.$l=function(a,b){var c=this.I;v(this,a,null,b,"ERROR",c);return c};l.Fn=function(a,b,c){v(this,a,b,c,"WPREC");this.va=b};l.bm=function(a,b){var c=this.J;v(this,a,null,b,"SECCNT",c);return c}; +l.Dn=function(a,b,c){v(this,a,b,c,"SECCNT");this.J=b};l.cm=function(a,b){var c=this.ga;v(this,a,null,b,"SECNUM",c);return c};l.En=function(a,b,c){v(this,a,b,c,"SECNUM");this.ga=b};l.Yl=function(a,b){var c=this.da;v(this,a,null,b,"CYLLO",c);return c};l.zn=function(a,b,c){v(this,a,b,c,"CYLLO");this.da=b};l.Xl=function(a,b){var c=this.aa;v(this,a,null,b,"CYLHI",c);return c};l.yn=function(a,b,c){v(this,a,b,c,"CYLHI");this.aa=b};l.Zl=function(a,b){var c=this.Y;v(this,a,null,b,"DRVHD",c);return c}; +l.Bn=function(a,b,c){v(this,a,b,c,"DRVHD");this.Y=b;this.fa=this.A[this.Y&mx?1:0]?this.fa|Qw|gx:this.fa&~Qw};l.dm=function(a,b){var c=this.fa;v(this,a,null,b,"STATUS",c);this.fa&Qw&&(this.fa&=~ex);return c};l.xn=function(a,b,c){v(this,a,b,c,"COMMAND");this.ha=b;this.W&&fh(this.W,14);nx(this)};l.Cn=function(a,b,c){v(this,a,b,c,"FDR");this.L&ox&&!(b&ox)&&(this.I=px);this.L=b}; +function nx(a){var b=!1,c=a.ha,d=a.Y&mx?1:0,e=a.Y&qx,f=a.da|(a.aa&rx)<<8,g=a.ga,h=a.J||256;a.Ua=-1;a.B=null;a.I=sx;a.fa=Qw|gx;var k=a.A[d];k?(k.Od=f,k.Xa=e,k.kb=g,k.ub=h*k.Na,c=c>=tx?c:c&ux,k.cb=null,k.Sa=0,k.errorCode=0,a.Ua=d,a.B=k):c=-1;switch(c&ux){case vx:b=!0;break;case wx:a.fa=ex;a.se(k,function(b){0<=b&&a.W?(fx(a),a.fa=Qw|gx|hx):(a.fa=ix,a.I=jx)},!1);break;case xx:a.fa=hx;break;case yx:b=!0;break;case zx:b=!0;break;case tx:a.I=px;b=!0;break;case Ax:k.ib=e+1,k.Ya=h,b=!0}b&&fx(a)} +function fx(a){!a.W||a.L&Bx||hh(a.W,14,120)} +function cx(a){a.D=0;var b=Cx(a),c=Cx(a),d=c&32,e=d>>5,f=c&31,g=Cx(a),h=Cx(a),k=g<<2&768|h,m=g&63,p=Cx(a),w=Cx(a),u=a.A[e];u&&(u.Od=k,u.Xa=f,u.kb=m,u.ub=p*u.Na);switch(b){case Dx:Ex(a,u?u.errorCode:Fx);Gx(a,c);Gx(a,g);Gx(a,h);Gx(a,Hx|d);b=-1;break;case ax:for(c=0;0<=(b=Cx(a));)u&&cb?this.se(a,c):c(-1,!1)};l.ml=function(a,b){return void 0!==b&&0<=b?lx(a,b):-1}; +l.Dl=function(a,b){void 0!==b&&0<=b?(a.Salx(a,a.Wi)){a=-1;break a}a.jg++}a.jg>=a.Td&&(b=-1);a=b}else a=-1;return a}; +function Px(a,b,c){b.errorCode=Fx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Sw;Jn(a.W,3,a,"dmaRead",b);An(a.W,3,function(a){a||b.errorCode!=Sw||(b.errorCode=Fx);c(b.errorCode?Ix:Hx)});return}c(b.errorCode?Ix:Hx)}function Rx(a,b,c){b.errorCode=Fx;if(b.sa&&(b.cb=null,a.W)){b.errorCode=Sw;Jn(a.W,3,a,"dmaWrite",b);An(a.W,3,function(a){a||(b.errorCode==Sw&&(b.errorCode=Fx),b.errorCode==Ux&&(b.errorCode=Sw));c(b.errorCode?Ix:Hx)});return}c(b.errorCode?Ix:Hx)} +function Tx(a,b,c){b.errorCode=Fx;b.Ee&&b.Ee.length==b.ub||(b.Ee=Array(b.ub));b.Sa=0;a.W?(b.errorCode=Sw,Jn(a.W,3,a,"dmaWriteBuffer",b),An(a.W,3,function(a){a||b.errorCode!=Sw||(b.errorCode=Fx);c(b.errorCode?Ix:Hx)})):c(b.errorCode?Ix:Hx)} +l.se=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.cb&&(f=a.Sa,d=a.sa.read(a.cb,a.Sa),a.Sa+=g,0<=d))return e=a.cb,b&&b(d,!1,e,f),d;if(b){if(a.sa)return a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!1,function(c,k){(a.cb=c)?(e=c,f=a.Sa=0,Vx(a),d=a.sa.read(a.cb,a.Sa),a.Sa+=g):a.errorCode=Ux;b(d,k,e,f)}),d;a.errorCode=Ux;b(d,!1,e,f)}return d}; +function lx(a,b){if(a.errorCode)return-1;do{if(a.cb&&a.sa.write(a.cb,a.Sa++,b))break;a.sa&&a.sa.seek(a.Od,a.Xa,a.kb+a.ig,!0,function(b){a.cb=b});if(!a.cb){a.errorCode=Ux;b=-1;break}a.Sa=0;Vx(a)}while(1);return b}function Vx(a){a.kb++;var b=1-a.ig;a.kb>=a.Ya+b&&(a.kb=b,a.Xa++,a.Xa>=a.ib&&(a.Xa=0,a.Od++))}l.Vm=function(){var a=this.H.L&255;!(this.H.D>>8)&&128>8||!this.W)||(a=!(this.W.hc[0].od&64));return a?!0:!1}; +var Tw="Hard Drive",Ww=["XTC","ATC","COMPAQ"],Uw=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, +6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],Mw=496,px=1,sx=0,jx=16,rx=3,qx=15,mx=16,ix=1,hx=8,gx=16,Qw=64,ex=128,vx=16,wx=32,xx=48,yx=64,zx= +112,tx=144,Ax=145,ux=240,Bx=2,ox=4,Hx=0,Ix=2,Lx=0,Mx=1,Dx=3,Nx=5,Ox=8,Qx=10,ax=12,Sx=15,Jx=224,Kx=228,Sw=0,Fx=4,Ux=20,Rw=0,bx=1,Yw=2,Zw=4,$w=8,Xw=32,Jw={800:Hw.prototype.Tm,801:Hw.prototype.Um,802:Hw.prototype.Sm},Iw={496:Hw.prototype.nl,497:Hw.prototype.$l,498:Hw.prototype.bm,499:Hw.prototype.cm,500:Hw.prototype.Yl,501:Hw.prototype.Xl,502:Hw.prototype.Zl,503:Hw.prototype.dm},Lw={800:Hw.prototype.ro,801:Hw.prototype.uo,802:Hw.prototype.to,803:Hw.prototype.so,807:Hw.prototype.hi,811:Hw.prototype.hi, +815:Hw.prototype.hi},Kw={496:Hw.prototype.An,497:Hw.prototype.Fn,498:Hw.prototype.Dn,499:Hw.prototype.En,500:Hw.prototype.zn,501:Hw.prototype.yn,502:Hw.prototype.Bn,503:Hw.prototype.xn,1014:Hw.prototype.Cn};ab(function(){for(var a=Ab(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.aa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Ca(a.substring(d,f))),d=f+1}}return b}; +function Xx(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function Yx(a,b,c){var d;if(b){b=Zx(a,b);for(var e=0,f=!1,g=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);ec&&(d+=" '"+String.fromCharCode(c)+"'"));a.P((null!=b?b+": ":"")+d);return e}function dy(a,b){if(b)return by(a,b,a.da[b]);var c=0;for(b in a.da)by(a,b,a.da[b]),c++;return 0>2:0)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c}var ay={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function ey(a){Wx.call(this,a);this.oa=4;this.ha=5;this.wa=1048575;this.K=fy(this);this.Ga=fy(this);this.Z=fy(this);this.D=[];this.B=this.Y=this.M=[];gy(this);this.ta=0;hy(this);this.za={};iy(this,a.messages);this.Ca=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return jy(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return jy(b,a)})}ba(ey,Wx);l=ey.prototype; +l.uc=function(a,b,c,d){this.ka=b;this.H=c;this.pa=a;this.Za=Xb(a,"FDC");this.Ha=Xb(a,"HDC");this.Tc=Xb(a,"FPU");this.G=Xb(a,"Mouse");(a=zd(a,"messages"))&&iy(this,a);this.ha=b.I>>2;this.wa=b.N;this.Ta=new Vd(this.H,7,"DBG");this.ma=ky;80186<=this.H.ca&&(this.ma=ky.slice(),this.ma[15]=ly,80286<=this.H.ca&&(this.ma[15]=my,80386<=this.H.ca&&(this.oa=8)));Al(this,64,function(a){ny(d,d.H.sc,a[0])});Al(this,4,function(a){if(a=a[0]){var b=$x(d,a);if(void 0===b)d.P("invalid selector: "+a);else if(a=oy(d, +b,py),d.P("dumpSel("+ta(a?a.U:b)+"): %"+q(a?a.Lb:null,d.ha)),a){var c,b=!1;if(a.type&4096)a.type&2048?(c="code"+(a.type&512?",readable":",execonly"),a.type&1024&&(c+=",conforming")):(c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown")),a.type&256&&(c+=",accessed");else{var e=qy[a.type];e&&(c=e[0],b=e[1])}!c||a.jb&32768||(c+=",not present");d.P((b?"seg="+ta(a.ua&65535)+" off="+ta(a.Ka):"base="+q(a.ua,d.ha)+" limit="+ry(a.Ka))+" type="+r(a.type>>8)+" ("+c+") ext="+ta(a.ext&-65296)+ +" dpl="+r(a.qc))}}else d.P("no selector")});Al(this,134217728,function(a){var b;(a=a[0])&&(b=$x(d,a));if(void 0===b)d.P("invalid MCB");else for(d.P("dumpMCB("+ta(b)+")");b;){a=fy(d,0,b);var c=d.Ia(a,1),e=d.Yc(a,2),k=d.Yc(a,5);if(77!=c&&90!=c)break;d.P(sy(0,b)+": '"+String.fromCharCode(c)+"' PID="+ta(e)+" LEN="+ta(k)+' "'+ty(d,a,8)+'"');b+=1+k}});Al(this,128,function(a){ny(d,d.H.aa,a[0],d.H.aa!==d.H.sc)});Al(this,8,function(a){a:{if(a=a[0]){var b=$x(d,a);if(void 0===b){d.P("invalid task selector: "+ +a);break a}a=oy(d,b,py)}else a=d.H.la;d.P("dumpTSS("+ta(a?a.U:b)+"): %"+q(a?a.ua:null,d.ha));if(a){var b="",c=a.type&-513,e=256==c?4:8,k=256==c?uy:vy,m,p,w,u;for(u in k)m=k[u],p=a.ua+m,w=yg(d.H,p,2),2304==c&&(w|=yg(d.H,p+2,2)<<16),b&&(b+="\n"),b+=ta(m)+" "+Ba(u+":",11)+q(w,e);if(2304==c)for(u=0,m=w>>>16;mu;)p=a.ua+m,w=yg(d.H,p,2),b+="\n"+ta(m)+" ports "+ta(u)+"-"+ta(u+15)+": "+ra(w,2),u+=16,m+=2;d.P(b)}}});this.F=null;this.Da=0;this.Aa=!1;Sf(this.H,48,this.Ym.bind(this));Sf(this.H,65, +this.Zm.bind(this));this.O=null;Sf(this.H,104,this.$m.bind(this));Jb(this)};function wy(a,b,c,d,e,f){b=ty(a,b);var g=oy(a,d),g=g?g.Ka+1:0,h=(e?"_CODE":"_DATA")+q(c,2);f&&t(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=xy(a,b,c);e[b+h]=0;aq(a,b,c,d,0,null,g,e)} +function yy(a,b,c,d){var e=a.Yc(b,2),f=a.Yc(b,2),g=zy(a,b,4),h=zy(a,b,4),k=fy(a,zy(a,b,4),a.Yc(b,2));b=fy(a,zy(a,b,4),a.Yc(b,2));b=ty(a,b).toUpperCase();var k=ty(a,k).toUpperCase(),m=(c?"_CODE":"_DATA")+q(e,2);d&&t(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+q(e,4)+")="+q(f,4)+":"+q(g)+" len "+q(h));c=xy(a,k,e);c[k+m]=g;aq(a,k,e,f,g,null,h,c)}function Ay(a,b,c){c=ty(a,c).toUpperCase();By(a,c,b)} +l.Ym=function(){var a=this.H;if(null!=this.F&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=fy(this,z(a)+12,a.Y.U);switch(zy(this,d)){case 336:yy(this,fy(this,a.G,b),!c,!!this.F)}}return!0}; +l.Zm=function(a){var b=this.H,c=b.D&65535,d=b.G&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.oa.U;if(null==this.F)return 79==c&&Tf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Mb(a,"INT 0x41 handling enabled",128),a.F=!0):(Mb(a,"INT 0x41 monitoring enabled",128),a.F=!1)}}(this)),!0;switch(c){case 79:this.F&&(b.D=b.D&-65536|62342,Mb(this,"INT 0x41 handling enabled",128));break;case 80:wy(this,fy(this,h,k),d+1,e,!(g&1),!!this.F);break;case 82:By(this,null, +d);break;case 127:this.F&&(b.D=b.D&-65536|(this.Aa?0:1));break;case 131:this.F&&(a=fy(this,b.L,e),this.Da++?(this.P("TRAPFAULT failed"),Cy(this,this.B,a,!0,!0),this.Da=0,this.Jb()):(this.P("INT 0x41 TRAPFAULT: fault="+ta(d)+" error="+q(b.K,8,!0)+" addr="+Dy(a)),this.Gd(this.B,a,!0),hy(this,!0)));break;case 141:this.F&&(b.D=b.D&-65536|1);break;case 336:yy(this,fy(this,b.G,f),!g,!!this.F);break;case 338:Ay(this,d,fy(this,b.J,f))}this.Aa=!1;return!this.F}; +l.$m=function(a){var b=this.H,c=b.D&255,d=b.D>>8&255,e=b.G&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.oa.U;if(null==this.O){if(67==d){if(609437257==b.ia((b.Z.U<<4)+10)||1111835735==b.ia((b.Z.U<<4)+95))return!0;Tf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Mb(a,"INT 0x68 handling enabled",128),a.F=a.O=!0):(Mb(a,"INT 0x68 monitoring enabled",128),a.O=!1)}}(this))}return!0}switch(d){case 67:this.O&&(b.D=b.D&-65536|62342);break;case 68:this.O&&(a=Xd(b.Z,this.yl.bind(this)))&& +(b.J=a[0],oe(b,a[1]));break;case 72:By(this,null,e);break;case 80:32==c?wy(this,fy(this,h,k),0,f,!0,!!this.O):128>c?wy(this,fy(this,h,k),e+1,c&64?g:f,!(c&1),!!this.O):yy(this,fy(this,h,k),!(c&1),!!this.O),this.O&&(b.D=b.D&-256|1)}return!this.O};l.yl=function(){var a=this.H;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; +l.Cb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.qa=this.na[b]=c,c.onkeydown=function(a){var b;if(13==a.keyCode)b=c.value,c.value="",jy(d,b,!0);else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.A>>0)+1;a.jb=f;a.type=g;a.ext=k;a.Lb=d;Wd(a,!0,!0,!1)}}return a}l.Sb=function(a,b,c){var d=a&&a.xa;if(null==d&&(d=-1,a)){var e=oy(this,a.U,a.type);e&&(b=a.Ja||0,c=c||1,d=e=-1===e.Lb||e.Oc&&(b>>>0)+c>e.Nb||!e.Oc&&(b>>>0)+c<=e.Nb?e.ua+b|0:-1,a.xa=d)}return d};l.Ia=function(a,b){var c=255,d=this.Sb(a,!1,1);-1!==d&&(c=yg(this.H,d,1,a.type==Hy)|0,b&&Iy(this,a,b));return c}; +l.hb=function(a,b){return a.Hb?zy(this,a,b?4:0):this.Yc(a,b?2:0)};l.Yc=function(a,b){var c=65535,d=this.Sb(a,!1,2);-1!==d&&(c=yg(this.H,d,2,a.type==Hy)|0,b&&Iy(this,a,b));return c};function zy(a,b,c){var d=-1,e=a.Sb(b,!1,4);-1!==e&&(d=yg(a.H,e,4,b.type==Hy)|0,c&&Iy(a,b,c));return d}l.fc=function(a,b,c,d){var e=this.Sb(a,!0,1);if(-1!==e){if(a.type!=Hy)this.H.fc(e,b);else{var f=this.ka;f.aa[(e&f.C)>>>f.A].bf(e&f.D,b&255,e)}c&&Iy(this,a,c);d||Cd(this.H,!0)}}; +l.il=function(a,b,c){var d=this.Sb(a,!0,2);-1!==d&&(a.type!=Hy?this.H.fb(d,b):Kc(this.ka,d,b),c&&Iy(this,a,c),Cd(this.H,!0))};function fy(a,b,c,d,e,f,g){return Jy(a,{},b,c,d,e,f,g)}function Jy(a,b,c,d,e,f,g,h){b.Ja=c||0;b.U=d;b.xa=e;b.type=f||(Fy(a)?py:Gy);b.Hb=null!=g?g:!(!a.H||4!=a.H.Z.V);b.dc=null!=h?h:!(!a.H||4!=a.H.Z.Jc);b.Jd=!1;return b}function Ky(a){return[a.Ja,a.U,a.xa,a.Jd,a.Hb,a.dc,a.Fe,a.bh]}function Ly(a){return{Ja:a[0],U:a[1],xa:a[2],Jd:a[3],Hb:a[4],dc:a[5],Fe:a[6],bh:a[7]}} +function My(a,b,c){if(null!=b.U&&(a=oy(a,b.U,b.type))){var d=b.Ja&a.wa;if(!a.Oc){if(d>>>0>=a.Nb)return!1}else if(d>>>0f?null!=h?(g=Yx(a,b,void 0),f=null):(f=Yx(a,b,void 0),null==f&&(g=null)):(h=Yx(a,b.substring(0,f),void 0),g=Yx(a,b.substring(f+1),void 0),f=null)}null!=g&&(e=fy(a,g,h,f,c),d||My(a,e,!0)||(a.P("invalid offset: "+Dy(e)),e=null));return e}function Qy(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.sl=a.Cg(b.Yk=c[2]))}l.Pk=function(a,b){var c=Ny(this,b);return a.replace("["+b+"]",c?q(this.hb(c),c.Hb?8:4):"undefined")}; +function Iy(a,b,c){c=c||1;null!=b.xa&&(b.xa+=c);null!=b.U&&(b.Ja+=c,My(a,b)||(b.Ja=0,b.xa=null))}function sy(a,b,c){return null!=b?q(b,4)+":"+q(a,a&-65536||c?8:4):q(a)}function Dy(a){var b;switch(a.type){case Gy:case Ry:b="&";break;case py:b="#";break;case Py:b="%";break;case Hy:b="%%";break;default:b=a.U?"":"%"}return a.type>=Py||null==a.U?b+q(a.xa):b+sy(a.Ja,a.U,a.dc)} +function ty(a,b,c){var d="";for(c=c||256;d.length>>a.H.qb;g=1}a.P("blockid "+(d?"linear ":"physical")+" blockaddr used size type");a.P("-------- --------- ---------- ------ ------ ----");c=-1;for(var h=0;g--;)(d=b[f])&&d.type==cd&&(d=td(a.H,e,!1,!0)),d.type==c?h++||a.P("..."):(c=d.type,h=vc[c],c==ed&&(d=d.pd,h+=" -> "+vc[d.type]),d&&a.P(q(d.id,8)+" %"+q(f<c&&(c=Ia(Ty,a.substr(b,2))));return c}; +function Uy(a,b){var c=0,d=a.hh(b);if(null!=d)switch(b){case Vy:case Wy:case Xy:case Yy:case Zy:case $y:case az:case bz:c=2;break;case cz:case dz:case ez:case fz:case gz:case hz:case iz:case jz:case kz:case lz+mz:case lz+nz:case lz+oz:case lz+pz:case lz+qz:case lz+rz:c=4;break;case sz:case tz:case uz:case vz:case wz:case xz:case yz:case zz:case Az:case Bz:case Cz:case Dz:case Ez:c=8;break;case Fz:c=a.oa}return c?q(d,c):"??"} +l.hh=function(a){var b;if(0<=a){var c=this.H;switch(a){case Vy:b=c.D&255;break;case Wy:b=c.I&255;break;case Xy:b=c.L&255;break;case Yy:b=c.G&255;break;case Zy:b=c.D>>8&255;break;case $y:b=c.I>>8&255;break;case az:b=c.L>>8&255;break;case bz:b=c.G>>8&255;break;case cz:b=c.D&65535;break;case dz:b=c.I&65535;break;case ez:b=c.L&65535;break;case fz:b=c.G&65535;break;case gz:b=z(c)&65535;break;case hz:b=c.M&65535;break;case iz:b=c.K&65535;break;case jz:b=c.J&65535;break;case kz:b=A(c)&65535;break;case Fz:b= +re(c);break;case lz+mz:b=c.oa.U;break;case lz+nz:b=c.Z.U;break;case lz+oz:b=c.Y.U;break;case lz+pz:b=c.Ca.U;break;default:if(80286==this.H.ca)a==Az&&(b=c.qa);else if(80386<=this.H.ca)switch(a){case sz:b=c.D;break;case tz:b=c.I;break;case uz:b=c.L;break;case vz:b=c.G;break;case wz:b=z(c);break;case xz:b=c.M;break;case yz:b=c.K;break;case zz:b=c.J;break;case Az:b=c.qa;break;case Bz:b=c.Og;break;case Cz:b=c.Cd;break;case Dz:b=c.Wc;break;case lz+qz:b=c.Ga.U;break;case lz+rz:b=c.Ha.U;break;case Ez:b=A(c)}}}return b}; +function Gz(a,b){b=Zx(a,b);for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.gh(b,c+1),0<=e&&(b=b.substr(0,c)+Uy(a,e)+b.substr(c+1+Ty[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=oa(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=Ny(a,e))?(d=e+' "'+ty(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=Ny(a,e))?(Iy(a,d),d= +e+' "'+ty(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+Dy(fy(this,A(this.H),this.H.Z.U))+" (%"+q(this.H.da)+")");this.va&&a==this.va||(this.va=a,this.ic&-2147483648&&(this.Jb(),a+=" (cpu halted)"),this.P(a),this.H&&(a=this.H,a.zc-=a.A,a.A=0,a.T.Ve=0,Cd(a)))}; +function Wk(a,b,c,d){var e,f;if(!d&&(d=t(a,1)&&0>Hz.indexOf(b),!d)){var g=Iz[b];g&&(d=t(a,g)?!0:524288==g&&t(a,g=1048576))}d&&(e=a.H.D>>8&255,f=a.H.L&255,33==b&&11==e||524288==g&&128<=f||1048576==g&&128>f)&&(d=!1);d&&((g=(g=Rb[b])&&g[e]||"")&&(g=" "+Gz(a,g)),a.message("INT "+r(b)+": AH="+r(e)+" at "+sy(c-2-a.H.Z.ua,a.H.Z.U)+g));return d} +function Nb(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.ic&h)==h)h=null,null!=e&&(h=a.H.Z.U,e-=a.H.Z.ua),a.message(b.be+"."+(null!=d?"outPort":"inPort")+"("+ta(c)+","+(f?f:"unknown")+(null!=d?","+r(d):"")+")"+(null!=g?": "+r(g):"")+(null!=e?" at "+sy(e,h):""))}l.ih=function(){this.P("Type ? for help with PCx86 Debugger commands");Jz(this);if(this.Ca){var a=this.Ca;this.Ca=null;jy(this,a)}}; +function hy(a,b){var c;if(Jg(a)){if(!a.N||!a.N.length){a.N=Array(Kz);for(c=0;c>>f.qb].Gd(e&f.Db,a==this.M);g&&tc(f)}}d&&(a.push(b),c?(null!=b.xa&&(b.U=null),b.Jd=!0):(Rz(this,a,a.length-1,"set"),hy(this)));return d}; +function Cy(a,b,c,d,e){for(var f=!1,g=Sz(a,a.Sb(c)),h=1;h>3&7,F=(3>(g>>6&3)?0:48)+u;(217==f||219==f)&&52<=F&&(F=u<<4|g&7);(u=$z[f])&&(w=u[F]);w&&(p=aA,k=w,m=k[0])}m>=p.length&&(g=a.Ia(b,1),k=bA[m-p.length][g>>3&7],m=k[0]);p=p[m];u=k.length-1;w="";b.Hb&&(m==cA? +p="CWDE":m==dA?p="CDQ":m>=eA&&m<=fA&&(p+="D"));if(164<=f&&167>=f||170<=f&&175>=f)u=0,b.Hb&&"W"==p.slice(-1)&&(p=p.slice(0,-1)+"D");for(var f=-1,F=!0,K=1;K<=u;K++){var H,I;H="";I=k[K];if(void 0!==I){0>f&&(f=I>>gA);m==hA&&(f==iA?w="[%800]":f==jA&&(w="ES:["+(b.dc?"E":"")+"DI]"));var T=I&kA;if(T!=lA)if(T==mA)F=!1;else{var L=I&nA;if(L>=R)if(0>g&&(g=a.Ia(b,1)),L>6,za=g&7;if(3>xb){T=!p.indexOf("FI");if(!xb&&(!I.dc&&6==za||I.dc&&5==za))xb=2;else{if(I.dc)if(4!=za)za+= +8;else{var ca=L,cb=xb,Sa=I,rb=ca.Ia(Sa,1),db=rb>>6,rc=rb>>3&7,rb=rb&7,ib="";if(cb||5!=rb)ib=pA[rb+8];4!=rc&&(ib&&(ib+="+"),ib+=pA[rc+8],db&&(ib+="*"+(1<>24),2)):ca+("+"+q(L,2))):2==xb&&(ca&&(ca+="+"),I.dc?(L=zy(L,I,4),ca+=q(L)):(L=L.Yc(I,2),ca+=q(L,4)));ca="["+ca+"]";if(1==ua){L="";H&=kA;H==S&&(H=I.Hb?qA:U);switch(H){case rA:L="FAR";break;case V:L="BYTE";break;case U:if(T){L="INT16"; +break}L="WORD";break;case qA:L="DWORD";break;case sA:if(T){L="INT32";break}case tA:L="REAL32";break;case uA:if(T){L="INT64";break}case vA:L="REAL64";break;case wA:L="REAL80";break;case xA:L="BCD80"}L&&(ca=L+" "+ca)}}else ca=yA(L,za,H,I);H=ca}else H=L==oA?yA(a,g&7,I,b):yA(a,g>>3&7,I,b);else if(L==zA)H="1";else if(L==W){H=a;T=I;L=b;I=" ";switch(T&kA){case V:T&X&&(I=q(H.Ia(L,1),2));break;case AA:I=q(H.Ia(L,1)<<24>>24,L.Hb?8:4);break;case S:if(L.Hb){I=q(zy(H,L,4));break}case U:I=q(H.Yc(L,2),4);break; +case rA:L=fy(H,H.hb(L,!0),H.Yc(L,2),null,L.type,L.Hb,L.dc);I=Dy(L);H=BA(H,L);H[0]&&(I+=" ("+H[0]+")");break;default:I="imm("+ta(T)+")"}H=I}else L==CA?(b.dc?(H=8,I=zy(a,b,4)):(H=4,I=a.Yc(b,2)),H="["+q(I,H)+"]"):L==DA?(H=T==V?a.Ia(b,1)<<24>>24:a.hb(b,!0),I=b.Ja+H&(b.Hb?-1:65535),H=q(I,b.Hb?8:4),I=BA(a,fy(a,I,b.U)),I[0]&&(H+=" ("+I[0]+")")):L==Y?H=T==EA?"ST":T==FA?"ST("+(g&7)+")":yA(a,(I&GA)>>8,I,b):L==HA?H=yA(a,(I&GA)>>8,IA,b):L==JA?H="DS:[SI]":L==KA&&(H="ES:[DI]");if(!H||!H.length){w="INVALID";break}0< +w.length&&(w+=",");w+=H||"???"}}}g="";k=Dy(e)+" ";if(-1!==e.xa&&-1!==b.xa){do if(g+=q(a.Ia(e,1),2),null==e.xa)break;while(e.xa!=b.xa)}k+=Ba(g,e.dc?24:16);k+=Ba(p,8);w&&(k+=" "+w);a.H.carz||b>=qz&&80386>a.H.ca)return"??";b+=lz}else if(e==NA)b+=Az;else if(e==OA)b+=PA;else if(e==QA)b+=RA;else if(a=c&kA,a>=U&&(b=cz&&b<=jz&&4a.H.ca&&(d="\n"+d,c+=e,e="");c+="\n"+UA(a,a.H.Z,b)+" ";80386<=a.H.ca&&(e+="\n",c+=UA(a,a.H.Ga,b)+" "+UA(a,a.H.Ha,b)+"\n");c+=VA(a,"LD",a.H.Eb.U,a.H.Eb.ua,a.H.Eb.ua+a.H.Eb.Ka)+" "+VA(a,"GD",null,a.H.Kb,a.H.Pc)+" "+VA(a,"ID", +null,a.H.Pb,a.H.cd)+" ";c=c+(d+" "+e)+TA(a,Az);80386<=a.H.ca&&(c+=TA(a,Cz)+TA(a,Dz))}else 80386<=a.H.ca&&(c+=UA(a,a.H.Ga,b)+" "+UA(a,a.H.Ha,b)+" ");return c+=TA(a,Fz)+SA(a,"V")+SA(a,"D")+SA(a,"I")+SA(a,"T")+SA(a,"S")+SA(a,"Z")+SA(a,"A")+SA(a,"P")+SA(a,"C")}l.gj=function(a,b){return a[0]>b[0]?1:a[0]>>0,p],H=Ea(F,u,a.gj);0>H&&F.splice(-(H+1),0,u)}K&&(w.a=K.replace(/''/g,'"'))}a.D.push({Rf:b,pn:c,U:d,Ja:e,xa:f,en:g,Fd:h,Pi:m})} +function By(a,b,c){for(var d=0;d>>0,f=a.Sb(b)>>>0,g=0;g>>0,p=h.xa;null!=p&&(p>>>=0);var w=h.en;48==k&&(k=40);if(k==b.U&&e>=m&&e=p&&fc?(a.P("out of data at address "+Dy(b)),p=!0):(a.fc(b,c,1,!0),m++)})})(a,g);Cd(a.H, +!0);a.P(m+" bytes read at "+b)}else a.P("sector "+e+" request out of range");else a.P("drive "+d+" not loaded");else a.P("invalid drive: "+d)}else a.P("disk controller not present")}}else a.P("load commands:"),a.P("\tl [address] [drive #] [sector #] [# sectors]")} +function Nz(a,b){var c;if(b&&"?"==b[1])a.P("register commands:"),a.P("\tr\tdump registers"),a.Tc&&a.P("\trfp\tdump floating-point registers"),a.P("\trp\tdump all registers"),a.P("\trx [#]\tset flag or register x to [#]");else{var d;null==c&&(c=!0);if(b&&1f;f++){var g=c,e=null;if(f=a.oa&&(h=null);switch(h){case "AL":a.H.D= +a.H.D&-256|g&255;break;case "AH":a.H.D=a.H.D&-65281|g<<8&255;break;case "AX":a.H.D=a.H.D&-65536|g&65535;break;case "BL":a.H.G=a.H.G&-256|g&255;break;case "BH":a.H.G=a.H.G&-65281|g<<8&255;break;case "BX":a.H.G=a.H.G&-65536|g&65535;break;case "CL":a.H.I=a.H.I&-256|g&255;break;case "CH":a.H.I=a.H.I&-65281|g<<8&255;break;case "CX":a.H.I=a.H.I&-65536|g&65535;break;case "DL":a.H.L=a.H.L&-256|g&255;break;case "DH":a.H.L=a.H.L&-65281|g<<8&255;break;case "DX":a.H.L=a.H.L&-65536|g&65535;break;case "SP":he(a.H, +z(a.H)&-65536|g&65535);break;case "BP":a.H.M=a.H.M&-65536|g&65535;break;case "SI":a.H.K=a.H.K&-65536|g&65535;break;case "DI":a.H.J=a.H.J&-65536|g&65535;break;case "DS":ne(a.H,g);break;case "ES":oe(a.H,g);break;case "SS":ge(a.H,g);break;case "CS":Zf(a.H,g);a.K=fy(a,A(a.H),a.H.Z.U);break;case "IP":case "EIP":C(a.H,g);a.K=fy(a,A(a.H),a.H.Z.U);break;case "PC":case "PS":se(a.H,g);break;case "C":g?kg(a.H):lg(a.H);break;case "P":g?(e=a.H,e.resultType&=-3,e.O|=4):(e=a.H,e.resultType&=-3,e.O&=-5);break;case "A":g? +ug(a.H):qg(a.H);break;case "Z":g?vg(a.H):rg(a.H);break;case "S":g?(e=a.H,e.resultType&=-17,e.O|=128):(e=a.H,e.resultType&=-17,e.O&=-129);break;case "I":g?(e=a.H,e.O|=512):(e=a.H,e.O&=-513);break;case "D":g?(e=a.H,e.O|=1024):(e=a.H,e.O&=-1025);break;case "V":g?mg(a.H):ng(a.H);break;default:var k=!0;if(80286<=a.H.ca)switch(k=!1,h){case "MS":wg(a.H,g);break;case "TR":-1===a.H.la.load(g)&&(f=!1);break;default:if(k=!0,80386<=a.H.ca)switch(k=!1,h){case "EAX":a.H.D=g;break;case "EBX":a.H.G=g;break;case "ECX":a.H.I= +g;break;case "EDX":a.H.L=g;break;case "ESP":he(a.H,g);break;case "EBP":a.H.M=g;break;case "ESI":a.H.K=g;break;case "EDI":a.H.J=g;break;case "FS":a.H.Ga.load(g);break;case "GS":a.H.Ha.load(g);break;case "CR0":a.H.qa=g;bk.call(a.H,g);break;case "CR2":a.H.Cd=g;break;case "CR3":a.H.Wc=g;ue.call(a.H,g);break;default:k=!0}}if(k){a.P("unknown register: "+e);return}}if(!f){a.P("invalid value: "+b);return}Cd(a.H);a.P("updated registers:")}}a.P(WA(a,d));c&&(a.K=fy(a,A(a.H),a.H.Z.U),Oz(a,Dy(a.K)))}} +function dB(a,b){b=Ca(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.P(Gz(a,c[2])):Yx(a,b,!0)}function eB(a,b,c){for(var d=null,e=b.Ja,f=e,g=1;6>=g&&e;g++){if(2h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.P(m)}h[3]&&(g=h[3],f=null);f=Vz(a,b,g,f);b.bh||d||d++;a.P(f);a.K=b;e-=b.xa-k;c++}}} +l.Cg=function(a,b,c){if(b)if(a){0>this.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else a=this.C[this.A+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Ca(a.substring(d,f))),d=f+1}}return b}; +function Uz(a,b,c){var d=!0;try{if(!b.length||"end"==b)a.aa&&(a.P("ended assemble at "+Dy(a.Z)),a.K=a.Z,a.aa=!1),b="";else if(!c){var e=">> ";a.H.qa&1&&(e=a.H.O&131072?"-- ":"## ");a.P(e+b)}var f=b.charAt(0);if('"'==f||"'"==f)return!0;a.va=null;if(Ib(a)&&0p||"z">>20;Qa.Ti=a.H.Wc+Qa.Jk;Qa.lb=of.aa[(Qa.Ti&of.C)>>>of.A];Qa.Aj=Qa.lb.Nd(Qa.Jk);Qa.Kk=(Ng&4190208)>>>10;Qa.Ui=(Qa.Aj&-4096)+Qa.Kk;Qa.mb=of.aa[(Qa.Ui&of.C)>>>of.A];Qa.Bj=Qa.mb.Nd(Qa.Kk);Qa.ul=(Qa.Bj&-4096)+(Ng&4095)}if(nf=Qa){a.P("linear PDE addr PDE PTE addr PTE physical");a.P("--------- ---------- -------- ---------- -------- ----------");var ve="%"+q(Ng),ve=ve+(" %%"+Sy(nf.Ti,nf.Aj)),ve= +ve+(" %%"+Sy(nf.Ui,nf.Bj,!0)),ve=ve+(" %%"+q(nf.ul));a.P(ve)}else a.P("unsupported operation")}}else a.P("missing address")}else{if("d"==za){if("disk"==cb){ca[0]="l";ca[1]="json";bB(a,ca);break a}for(xb in Sb)if(ca[1]==xb){var tt=a.za[xb];tt?(ca.shift(),ca.shift(),tt(ca)):a.P("no dump registered for "+cb);break a}cb||(za=a.eb||"db")}else a.eb=za;if("dh"==za){var ut=cb,vt=Sa,wt="",xt=0,Mc=a.la,jd=a.N;if(jd.length){var uc=+ut||a.Ma,Og=+vt||10;isNaN(uc)?uc=Og:wt="more ";uc>jd.length&&(a.P("note: only "+ +jd.length+" available"),uc=jd.length);Mc-=uc;0>Mc&&(null==jd[jd.length-1].U?(uc=Mc+uc,Mc=0):Mc+=jd.length);var rm=[];"call"==vt&&(Og=1E5,rm=["CALL"]);for(void 0!==ut&&a.P(uc+" instructions earlier:");0=jd.length&&(Mc=0);a.Ma=uc;xt++;Og--}}xt||(a.P("no "+wt+"history available"),a.Ma= +void 0)}else if("di"==za){ca.shift();var sm=ca[0];if(sm){var Qg=$x(a,sm);if(void 0===Qg||0>Qg||255>>0,65536>4||1;ZB--&&0Wi?String.fromCharCode(Wi):".";Vi--}Rg&&(Rg+="\n");Rg+=cb+" "+um+(Tg?"":" "+Dt)}Rg&&a.P(Rg);a.Ga=pf}}}}}break;case "e":if("else"==g[0])break;var Xi= +1,Et=255,Ft=a.Ia,Gt=a.fc;"ew"==g[0]&&(Xi=2,Et=65535,Ft=a.Yc,Gt=a.il);var Ht=Xi<<1,It=g[1];if(null==It)a.P("edit memory commands:"),a.P("\teb [a] [...] edit bytes at address a"),a.P("\tew [a] [...] edit words at address a");else{var Yi=Ny(a,It);if(Yi)for(var Zi=2;ZiAm;){for(var kd=null,dC=256;Sd.Ja>>>0>>0;){Wg.Ja=a.hb(Sd,!0);if(null==Sd.xa||!dC--)break;Wg.U=Kt;if(kd=eB(a,Wg))break;Wg.U=a.hb(Sd);if(kd=eB(a,Wg,!0)){Kt=a.hb(Sd,!0);0\nLicense: GPL version 3 or later ");for(b=0;bBB){if(d.load(this.L)){this.F=new Xf(this,"1.34.1",LB);this.F.load()&&(MB(this,d),a=NB,OB(this.F));this.F.set(IB,Fa());PB(this.F);var e=this.A&&!this.I;if(a==JB||sb("Click OK to restore the previous PCx86 machine state, or CANCEL to reset the machine.")){if(c=HB(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= +g?(this.Fa("Error: "+g),"unable to verify user"==g&&(Ta(QB,""),this.B=null)):this.P(f+": "+g),OB(d),d.load()?(c=HB(d),e=!0):c=!1))}e&&FB(this,c?d:null)}else a==NB&&d.clear()}else FB(this);delete this.L;delete this.M}e=tb(this.id);for(f=0;fa[1];a=a[2];this.ga=!0;this.ea.Yb=!0;var d=this.na.power;d&&(d.textContent="Shutdown");this.H&&(RB(this,this.H,b,c,a),this.H.lf());this.Y&&(MB(this,b),b.clear());!c&&this.F&&(this.F.clear(),delete this.F);this.C=0}; +function MB(a,b){if(sb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.34.1"};d.url=a.da;d.user=c;d.type="bug";d.data=b;La("http://www.pcjs.org/api/v1/report",d,!0)}} +function gB(a,b,c){var d,e="none";if(a.C)return null;a.C--;var f=new Xf(a,"1.34.1"),g=new Xf(a,"1.34.1",GB),h=Fa();g.set(IB,h);f.set(IB,h);f.set(SB,"1.34.1");f.set(TB,window?window.location.href:null);f.set(UB,Na());a.H&&a.H.Wb&&(c&&a.H.Jb(),d=a.H.Wb(b,c),"object"===typeof d&&f.set(a.H.id,d),c&&(a.H.ea.Yb=!1,!1===d&&(e=null)));for(var h=tb(a.id),k=0;k>>b.A;d=d+e-1>>>b.A;c.ah=0;for(c.Hd=0;f<=d;)e=b.aa[f],c.ah+=e.size,e.size&&(c.Rg.push(Ga(cc,f,0,0,e.type)),c.Hd++),f++;a.A=c;a.da=a.A.Hd*a.ka.B/(bc*lc);d=0;a.A.$i=0;a.A.kf||(a.A.kf=[]);e=-1;b=0;for(var g=-1,c=0;c>1),g=f.y+(f.A>>1),h=f.A,f.Nc>1,b.I+=(b.J>>1)-2,ic(b,e),b.Y&&(b.D.restore(),b.Y=!1)}}else ic(a,"This space intentionally left blank");a.context.drawImage(a.K,0,0,a.K.width,a.K.height,a.Ga,a.Ma,a.ya,a.Aa);a.oa=!1}}var LB="failsafe",GB="validate",IB="timestamp",SB="version",TB="url",UB="browser",QB="user",KB=-1,BB=0,JB=1,NB=2,WB=3; +ab(function(){for(var a=Ab(document,"pcx86-machine"),b=0;bf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PCx86$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1pcx86$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");La(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);mC(a,b,c)}})}else c(a,null)} +function nC(a,b,c,d){function e(a){if(void 0===h){var b=g&&Ab(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=ya(a))}function f(a){e("Error: "+a);k&&(--jC||jb(!0));k=!1}var g,h,k=!0;jC++;qb[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],w=document.createElement("style");w.type="text/css";w.styleSheet?w.styleSheet.cssText=m:w.appendChild(document.createTextNode(m));p.appendChild(w)}c|| +(c="/versions/pcx86/1.34.1/components.xsl");m=function(d,h){h?kC(c,null,null,!1,e,function(d,k){k?(pb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--jC||jb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--jC||jb(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?kC(b,a,d,!0,e,m):lC(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(u){f(u.message)}return k}function oC(a,b,c,d){jb(!1);return nC(a,b,c,d)}window.embedPC=oC;window.embedPCx86=oC;window.findMachineComponent=function(a,b){return vb(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Cb[a]){for(var c=!0,d=Cb,e=a,f=b.length,g=[],h=[],k="",m=null,p=0;p]*path=(['"])(.*?)\1.*?<\/disk>\n?/g;d=w.exec(h[m]);){var u=d[2];u&&(h[u]||(p=p.replace(d[0],"")))}d=m=va(m)}else"xsl"==w&&(e=m=va(m));k[m]=p}a&&(k[m="css"]=a);b[2]&&(k[m="parms"]=b[2]);b[3]&&(k[m="state"]=b[3]);d&&e?(a=JSON.stringify(k),g+=".js",c=c[1]+"var resources="+a+";"+c[2]+c[3],c=c.replace(/\u00A9/g, +"©"),a=Xa(c,"javascript",!1,g),a=a+(', copy it to your web server as "'+g+'", and then add the following to your web page:\n\n')+('
    \n')+"...\n",a=a+(' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + float: + + + + + + + js + + + +
    + + + + + + + + + + js + + + "" + + + + + +
    +
    + + + + + + + + + + + + + + + , + + + + + + + + + + + + + .machine + . + . + + + + + + + + + + + + + + + + + + + + ,comment:'' + + + + + + border:1px solid black;border-radius:15px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:;max-width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto;clear:both; + position:; + position:relative; + + + + + overflow:auto;width:100%; + background-color:; + + + + - -component + +
    + + + + + + +
    + + + + + + + + --object -screen + + +
    +
    + +
    + +
    +
    + + + + +
    + + +
    [XML]
    + +
    + + +
    +
    +
    +
    + + + + + text-align:center; + + + +

    +
    + + +
    +
    + + + + + + +
    +
    + + + + type:'' + + + binding:'' + + + value:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + clear:both; + position:; + position:relative; + text-align:; + float:left; + + + + + + + + + + + + + + + + + + +
    + + + font-size:; + + + + + -label + + + + width:; + width:; + + + + + + + + text-align:right; + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    +
    + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',rtcDate:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + + + + + + mouse + ,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + xt + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + + diff --git a/versions/pdpjs/1.34.1/document.css b/versions/pdpjs/1.34.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pdpjs/1.34.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pdpjs/1.34.1/document.xsl b/versions/pdpjs/1.34.1/document.xsl new file mode 100644 index 000000000..a563d5a2a --- /dev/null +++ b/versions/pdpjs/1.34.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pdpjs/1.34.1/machine.xsl b/versions/pdpjs/1.34.1/machine.xsl new file mode 100644 index 000000000..bc7635ed3 --- /dev/null +++ b/versions/pdpjs/1.34.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pdpjs/1.34.1/manifest.xsl b/versions/pdpjs/1.34.1/manifest.xsl new file mode 100644 index 000000000..ee3e50cbf --- /dev/null +++ b/versions/pdpjs/1.34.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pdpjs/1.34.1/outline.xsl b/versions/pdpjs/1.34.1/outline.xsl new file mode 100644 index 000000000..c0f614b25 --- /dev/null +++ b/versions/pdpjs/1.34.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pdpjs/1.34.1/pdp10-dbg.js b/versions/pdpjs/1.34.1/pdp10-dbg.js new file mode 100644 index 000000000..2e0707e56 --- /dev/null +++ b/versions/pdpjs/1.34.1/pdp10-dbg.js @@ -0,0 +1,226 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/diskapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/device.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/computer.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/int36.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpustate.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpuops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 +*/ +var l,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(c.get||c.set)throw new TypeError("ES3 does not support getters and setters.");a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var ea=0;function da(a){return"jscomp_symbol_"+(a||"")+ea++} +function fa(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ga(this)}});fa=function(){}}function ga(a){var b=0;return ha(function(){return ba?-b:b}});ia("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var ja=Math.pow(2,36),ma=-Math.pow(2,35),q={Xb:0,ob:1,Zb:2,$b:3,ac:4,bc:5,cc:6,dc:7,Za:8,ec:9,pb:10,fc:11,gc:12,qb:13,hc:14,ic:15,jc:16,kc:17,lc:18,mc:19,nc:20,oc:21,pc:22,qc:23,rc:24,sc:25,tc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,Wb:66,Yb:67,uc:68,E:69,vc:70,wc:71,xc:72,yc:73,zc:74,Ac:75,Bc:76,Cc:77,Dc:78,Ec:79,Fc:80,Q:81, +Gc:82,Hc:83,Ic:84,Jc:85,Kc:86,Lc:87,Mc:88,Nc:89,ub:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Oc:97,Pc:98,Qc:99,d:100,e:101,Rc:102,Sc:103,Tc:104,Uc:105,Vc:106,k:107,Wc:108,Xc:109,n:110,Yc:111,p:112,q:113,r:114,Zc:115,t:116,ad:117,bd:118,cd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,rb:127}; +function t(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.cb=b.comment;this.tb=b;this.exports={};this.G=this.bindings={};a=this.id.indexOf(".");0>a?this.Ka=this.id:(this.La=this.id.substr(0,a),this.Ka=this.id.substr(a+1));this.j={ready:!1,Fa:!1,Ta:!1,V:!1,error:!1};this.Ma=null;this.j.error=!1;this.X=c||0;this.A=this.g=this.D=this.C=this.ma=null;u.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)}function pa(){return Date.now()||+new Date} +function v(a){window&&window.alert(a)}function qa(a){var b=!1;window&&(b=window.confirm(a));return b}function xa(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=g?48:55),e=String.fromCharCode(g)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function Wa(a,b,c){b?12"']/g,function(a){return bb[a]})}function cb(a,b){return(a+" ").slice(0,b)} +function db(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var bb={"&":"&","<":"<",">":">",'"':""","'":"'"};function eb(a,b,c){var d=0,e=a.length,g=0;for(c||(c=function(a,b){return a>b?1:a>1,h;h=c(b,a[f]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function pb(a,b,c,d){c=void 0===c?!1:c;var e=0,g=null,f=null;if("object"==typeof resources&&(g=resources[a]))return d&&d(a,g,e),[g,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),f;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(g=h.responseText,200==h.status||!h.status&&g.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +g,e))});if(b&&"object"==typeof b){var k="",m;for(m in b)b.hasOwnProperty(m)&&(k&&(k+="&"),k+=m+"="+encodeURIComponent(b[m]));k=k.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(k)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(g=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,g,e),f=[g,e]);return f} +function qb(a,b){var c,d={Y:null,U:null,la:null,ka:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,g,f;if("<"==b.substr(0,1))throw Error(b);f=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.la=f.load;d.ka=f.exec;if(e=f.bytes)d.Y=e;else if(e=f.words)for(d.Y=Array(2*e.length),g=c=0;c>8&255;else if(e=f.longs)for(d.Y=Array(4*e.length),g=c=0;c>8&255,d.Y[g++]=e[c]>>16&255,d.Y[g++]=e[c]>>24&255;else(e=f.data)?d.Aa=e:d.Y=f;d.Y&&(d.Y.length?1==d.Y.length&&(v(d.Y[0]),d=null):(v("Empty resource: "+a),d=null));d.U=f.symbols}catch(h){v("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Gb,a];this.A=this.g=this.D=this.C=null;this.exports={hold:this.yb,toggle:this.Rb,reset:this.Nb, +set:this.Qb};C(this)}p(Sb,t);l=Sb.prototype;l.reset=function(a){this.stop();a&&Ub(this,this.v=0)}; +l.ga=function(a,b,c,d){if(this.C&&this.C.ga(a,b,c,d)||this.g&&this.g.ga(a,b,c,d)||this.A&&this.A.ga(a,b,c,d))return!0;switch(b){case "PC":return this.G[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.G[b]=c,this.B[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.G[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){Vb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Wb(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){Vb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Wb(a,b)}}(this,b),!0):t.prototype.ga.call(this,a,b,c,d)}};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;Xb(this);Yb(this)};l.na=function(a,b){if(!b)if(this.T&&Zb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};l.fa=function(a){return a?this.save():!0};l.save=function(){var a=new H(this);a.set(0,[this.i,this.v,this.u]);return a.data()}; +l.restore=function(a){if(a=a[0])$b(this,this.i=a[0]),Ub(this,this.v=a[1]),ac(this,a[2]);return!0};l.Nb=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}Yb(this);return!0};function bc(a,b,c){if(a=a.G[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function Xb(a,b){for(var c in a.B)bc(a,c,null!=b?b:a.B[c])}function jc(a,b,c){if(a=a.G[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function Yb(a){for(var b in a.b)jc(a,b,a.b[b][1])} +l.yb=function(a,b,c){if(Vb(this,b)){if(c){var d=this;setTimeout(function(){Wb(d,b);a&&a()},+c);return!1}Wb(this,b)}return!0};l.Qb=function(a,b){if("SR"==a)return ac(this,Ua(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,jc(this,a,c[1]),!0):!1};l.Rb=function(a){return Vb(this,a)?(Wb(this,a),!0):!1};function Vb(a,b){var c=a.b[b];return c?(jc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=kc&&(a.P=b==lc,a.R=b==mc),!0):!1} +function Wb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(jc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}l.Hb=function(a){a||this.g.j.K||(this.g.u=this.i%Kb,this.b[nc]&&this.b[nc][1]&&oc(this.g))};l.Ib=function(){};l.Cb=function(a){a||this.g.W()}; +l.Ab=function(a){if(!a&&!this.g.j.K)if(this.b[nc]&&this.b[nc][1])oc(this.g);else{if((a=this.A)&&!Qa(a,!0))Ra(a,!0),pc(a,0,null),Ra(a,!1);else try{var b=this.g.Ja(1);0c;c++){var d=a,e="A"+c,g=b&1<c;c++){var d=a,e="D"+c,g=b&1<b;b++)a.b["S"+b][1]=a.u&1<d.length){for(var e=0,g=Array(4096),f=0;f>>a.i;0g&&(m=g);if(h&&h.size){if(h.type==d){if(e+g<=h.w)return h.Ha+=h.w-e,h.w=e,!0;if(e>=h.w+h.Ha){m=h.size-(e-k);m>g&&(m=g);h.Ha=e-h.w+m;e=k+16384;g-=m;f++;continue}}return Bc(Cc,e,g)}e=new xc(a,e,m,16384,d);yc(e,a.A,h);a.b[f++]=e;e=k+16384;g-=m}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+Dc[d]+" at "+Wa(b)),!0):Bc(Ec,b,c)} +function vc(a,b){var c=a.b[(b&a.u)>>>a.i];a.v++;b=c.G(b&16383,b);a.v--;return b}function uc(a,b,c){var d=a.b[(b&a.u)>>>a.i];a.v++;d.D(c,b&16383,b);a.v--}function zc(a){for(var b=0,c=[],d=0;d=a.ha&&(a.ha+=a.da,c=!0);0<=a.ia&&a.ia<=sd(a)&&(a.da=a.ia=-1,Vc(a),a.W(),c=!0);c&&a.f(sd(a)+" cycles: checksum="+E(a.sa))}} +l.ga=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.G[b]=c,!0;case "run":return this.G[b]=c,c.onclick=function(){var a;if(a=d.C)if(a=d.C,a.j.V)a=!0;else{var b=null,c,h=xa(a.id);for(c=0;ca.R/a.S?b=1:d=!0;a.T=b;b=a.Da*a.T;if(a.S!=b){a.S=b;b=a.S.toFixed(2)+"Mhz";var e=a.G.setSpeed;e&&(e.textContent=b);a.f("target speed: "+b)}c&&a.C&&wd(a.C)}rc(a,a.F);a.F=0;a.B=pa();a.J=0;ud(a);return d}function xd(a,b){for(var c=a.I.length-1;0<=c;c--){var d=a.I[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function yd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function zd(a,b){var c=a.L-=a.M;a.M=0;b&&(a.L=0);return c} +l.Ob=function(){if(this.j.K){this.ya>=this.Ra&&ud(this,!0);this.ja=0;this.ra=pa();if(this.J){var a=this.ra-this.J;a>this.Qa&&(this.B+=a,this.B>this.ra&&(this.B=this.ra))}try{do{var b=xd(this,this.j.Ea?1:this.ua);try{this.Ja(b)}catch(e){if("number"!=typeof e)throw e;}b=zd(this,!0);this.ja+=b;this.F+=b;sc(this,b);qc(this,b);this.aa-=b;if(0>=this.aa){this.aa+=this.ua;++this.Sa>=Ad&&(this.C&&I(this.C,void 0),this.Sa=0);break}}while(this.j.K)}catch(e){this.W();this.C&&this.C.stop(pa(),sd(this));Ga(this, +e.stack||e.message);return}if(this.j.K){a=setTimeout;b=this.fb;this.J=pa();var c=this.Qa;this.ja&&(c=Math.round(c*this.ja/this.ua));var c=c-(this.J-this.ra),d=this.J-this.B;d&&(this.R=Math.round(this.F/(10*d))/100,864E5<=d&&(this.O=0,td(this)));if(0>c||this.Rc&&(this.B-=c),c=0;this.ya+=this.ja;this.J+=c;a(b,c)}}}; +function oc(a,b){if(!Ha(a))if(a.j.K)a.f(a.toString()+" busy");else{td(a);a.j.K=!0;a.j.Pa=!0;var c=a.G.run;c&&(c.textContent="Halt");a.C&&(b&&wd(a.C,!0),a.C.start(a.B,sd(a)));a.A||a.status("Started");setTimeout(a.fb,0)}}l.Ja=function(){return 0};l.W=function(a){var b=!1;if(this.j.K){zd(this);rc(this,this.F);this.F=0;this.j.K=!1;if(b=this.G.run)b.textContent="Run";this.C&&this.C.stop(pa(),sd(this));b=!0;this.A||this.status("Stopped")}this.j.complete=a;return b};var vd=30,Ad=15,Sc=["power","reset"]; +function Bd(a){var b=+a.model||1001;Rc.call(this,a,1E6);this.eb=b;this.bb=+a.addrReset||0;this.sb=Cd.bind(this);this.b=L.bind(this);this.oa=null;this.ab=[];this.j.complete=!1}p(Bd,Rc);l=Bd.prototype;l.reset=function(){this.status("Model "+this.eb);this.j.K&&this.W();this.i=this.P=this.za=0;this.pa=this.u=this.qa=this.bb;this.v=0;this.H=this.Kb;this.N=this.Vb;this.oa=null;Uc(this);this.j.error=!1;Rc.prototype.reset.call(this)};l.lb=function(){return 0}; +l.save=function(){var a=new H(this);a.set(0,[this.i,this.P,this.za,this.u,this.qa,this.pa,this.v]);a.set(1,[]);a.set(2,[this.O,this.T,this.j.Z]);a.set(3,Dd(this));a.set(4,yd(this));return a.data()}; +l.restore=function(a){var b;b=a[0];fa();ca();fa();var c=b[Symbol.iterator];b=c?c.call(b):ga(b);this.i=b.next().value;this.P=b.next().value;this.za=b.next().value;this.u=b.next().value;this.qa=b.next().value;this.pa=b.next().value;this.v=b.next().value;b=a[2];this.O=b[0];td(this,b[1]);this.j.Z=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].H(a&16383,a)};l.Vb=function(a,b){var c=this.D;a=this.pa=a;c.b[(a&c.u)>>>c.i].N(b,a&16383,a)}; +l.Ja=function(a){this.j.complete=!0;var b=this.A?Fd(this.A)?1:this.j.Pa?-1:0:0,c=a?this.j.Pa?0:1:-1;this.j.Pa=!1;this.L=this.M=a;this.v=this.v&-5|(b?4:0);do{if(this.v){if(this.v&4){if(Gd(this.A,this.u,c)){this.W();break}++b||(this.v&=-5);c||c++}if(a=this.v&11)this.v&2?this.oa||(this.v&=-3):this.v&1&&this.v++,a=!1;if(a){if(this.v&4&&Gd(this.A,this.u,c)){this.W();break}if(0>c)break}}this.v&=15;this.P=this.P&4194304?this.H(this.i)&8388607:(this.za=this.H(this.qa=this.u))&8388607;this.i=this.P&262143; +if(a=this.P>>18&15)this.i=this.i+this.H(a)&Lb;this.P&4194304?a=-1:(this.u=(this.u+1)%Kb,a=this.za/Rb|0);0<=a&&this.sb(a)}while(0>4].call(this,a)}function M(a){this.b(a)}function Id(a){this.b(a)}function Jd(a){this.b(a)} +function Kd(a){var b=a&15,c=this.H(this.i),d=this.H(b);this.N(b,Ld(a,d,c)+(c-(c&262143)))}function Md(a){var b=a&15,c=this.H(b);this.N(b,Ld(a,c,0))}function Nd(a){var b=this.H(a&15),c=this.H(this.i);this.N(this.i,Ld(a,c,b)+(b-(b&262143)))}function Od(a){var b=this.H(this.i);this.N(this.i,Pd(a,b,b));var c=a&15;c&&(b=this.H(c),this.N(c,Pd(a,b,b)))}function Qd(a){var b=a&15,c=(this.H(this.i)&262143)*F,d=this.H(b);this.N(b,Ld(a,d,c)+c)} +function Rd(a){var b=a&15,c=this.i*F,d=this.H(b);this.N(b,Ld(a,d,c)+c)}function Sd(a){var b=(this.H(a&15)&262143)*F,c=this.H(this.i);this.N(this.i,Ld(a,c,b)+b)}function Td(a){var b=this.H(this.i),c=(b&262143)*F;this.N(this.i,Ld(a,b,c)+c);var d=a&15;d&&(b=this.H(d),c=(b&262143)*F,this.N(d,Ld(a,b,c)+c))}function Ud(a){var b=a&15,c=this.H(this.i)&262143,d=this.H(b);this.N(b,Vd(a,d,c)+c)}function Wd(a){var b=a&15,c=this.H(b);this.N(b,Vd(a,c,this.i)+this.i)} +function Xd(a){var b=this.H(a&15)&262143,c=this.H(this.i);this.N(this.i,Vd(a,c,b)+b)}function Yd(a){var b=this.H(this.i);this.N(this.i,Zd(a,b,b));var c=a&15;c&&(b=this.H(c),this.N(c,Zd(a,b,b)))}function $d(a){var b=a&15,c=this.H(this.i)/F|0,d=this.H(b);this.N(b,Vd(a,d,c)+c)}function ae(a){var b=a&15,c=this.H(b);this.N(b,Vd(a,c,0))}function be(a){var b=this.H(a&15)/F|0,c=this.H(this.i);this.N(this.i,Vd(a,c,b)+b)} +function ce(a){var b=this.H(this.i),c=b/F|0;this.N(this.i,Vd(a,b,c)+c);var d=a&15;d&&(b=this.H(d),c=b/F|0,this.N(d,Vd(a,b,c)+c))}function O(a){this.b(a)}function L(a){this.f("undefined opcode: "+Wa(a));Ed(this,-1);this.W()}function Vd(a,b,c){switch(a&384){case 0:b-=b&262143;break;case 128:b=0;break;case 256:b=262143*F;break;case 384:b=c>Nb?262143*F:0}return b}function Zd(a,b,c){if(a&=384)switch(b&=262143,a){case 256:b+=262143*F;break;case 384:b+=c>Nb?262143*F:0}return b} +function Ld(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Ob?262143:0}return b}function Pd(a,b,c){if(a&=384)switch(b-=b&262143,a){case 256:b+=262143;break;case 384:b+=c>Ob?262143:0}return b} +var Hd=[M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Id,Jd,Jd,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Id,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},L,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},L,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},Kd,Md,Nd,Od,Qd,Rd,Sd,Td,Kd,Md,Nd,Od,Qd,Rd,Sd,Td,Kd,Md,Nd,Od,Qd,Rd,Sd,Td,Kd,Md,Nd,Od,Qd,Rd,Sd,Td,Ud,Wd,Xd,Yd,$d,ae,be,ce,Ud,Wd,Xd,Yd,$d,ae,be,ce,Ud,Wd,Xd,Yd,$d,ae,be,ce,Ud,Wd,Xd,Yd, +$d,ae,be,ce,function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)}, +function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},function(a){this.b(a)},O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O, +O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O]; +function de(a){t.call(this,"ROM",a,128);this.U=this.b=null;this.B=+a.addr;this.u=+a.size;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.v=a.file;this.F=Xa(this.v);if(this.v){a=this.v;var b=Ya(this.F);"json"!=b&&"hex"!=b&&(a=$a()+"/api/v1/dump?file="+this.v+"&format=bytes&decimal=true");var c=this;pb(a,null,!0,function(a,b,g){g?(c.ca("Unable to load ROM resource (error "+g+": "+a+")"),c.v=null):(na(c.La,a,b),(a=qb(a,b))?(c.b=a.Y,c.U=a.U):c.v=null);ee(c)})}}p(de,t); +de.prototype.va=function(a,b,c,d){this.D=b;this.g=c;this.A=d;ee(this)};de.prototype.na=function(){this.U&&(this.A&&fe(this.A,this.id,this.B,this.u,this.U),delete this.U);return!0};de.prototype.fa=function(){return!0}; +function ee(a){if(!Ia(a)){if(a.v){if(!a.b||!a.D)return;a.u||(a.u=a.b.length);if(a.b.length!=a.u)Ga(a,"ROM size ("+E(a.b.length,8,!0)+") does not match specified size ("+E(a.u,8,!0)+")");else{var b;b=a.B;if(Ac(a.D,b,a.u,Ic)){var c;for(c=0;c>>g.i;0>>= +g.i;0>>a.i;0f&&f>=ma&&(f+=ja);f=Math.trunc(Math.abs(f))%ja;void 0===g&&(g=e.size);for(h=d;g--&&h=q.Ya&&c<=q.ub&&(b=c-(q.Ya-q.ob));b&&(a.preventDefault&&a.preventDefault(),d.Na(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.qb&&(b=q.pb);d.Na(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Na(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};l.va=function(a,b,c,d){this.C=a;this.D=b;this.g=c;this.A=d;C(this)}; +l.nb=function(a){if(!this.b){var b=Tc(this.C,"connection");if(b){var c=b.split("->");if(2==c.length){var d=db(c[0]);if(d!=this.Ka)return;c=db(c[1]);if(this.b=ya(c)){var e=this.b.exports;if(e){var g=e.connect;g&&g.call(this.b,this.u);if(this.B=e.receiveData){this.u=a;this.status("Connected "+this.La+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};l.na=function(a,b){if(!b)if(this.nb(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +l.fa=function(a){return a?this.save():!0};l.reset=function(){};l.save=function(){var a=new H(this);a.set(0,[]);return a.data()};l.restore=function(){return!0};l.Na=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.v&&a.u.length&&(a.v=0);if(0>a.v||b!=a.u[a.v])a.u.splice(0,0,b),a.v=0;a.v--}else a.R?b="end":b=a.u[a.v+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var g=0;g<=b.length;g++){var f=b.charAt(g);if('"'==f||"'"==f)e?f==e&&(e=null):e=f;else if(f==d&&!e||!f)a.push(db(b.substring(c,g))),c=g+1}}return a} +function ne(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),g=a.pop();switch(d){case "*":d=g*e;break;case "/":if(!e)return!1;d=g/e;break;case "%":if(!e)return!1;d=g%e;break;case "+":d=g+e;break;case "-":d=g-e;break;case "<<":d=g<>":d=g>>e;break;case ">>>":d=g>>>e;break;case "<":d=g":d=g>e?1:0;break;case ">=":d=g>=e?1:0;break;case "==":d=g==e?1:0;break;case "!=":d=g!=e?1:0;break;case "&":d=g&e;break; +case "^":d=g^e;break;case "|":d=g|e;break;case "&&":d=g&&e?1:0;break;case "||":d=g||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function P(a,b,c){var d;if(b){b=oe(a,b);for(var e=0,g=!1,f=b,h=[],k=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1,U--;f=r+f;d>>=8}d=E(c,0,!0)+" "+c+". "+Wa(c,0,!0)+" "+("0b"+f);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.f((null!=b?b+": ":"")+d);return e} +function se(a,b){if(b)return re(a,b,a.aa[b]);var c=0;for(b in a.aa)re(a,b,a.aa[b]),c++;return 0>2:0)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c}var qe={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function te(a){le.call(this,a);this.ya=!1;this.oa=!0;this.ua=Q();this.J=Q();this.xa=Q();this.P=Q();this.F=[];this.b=this.L=this.I=[];ue(this);this.S=this.ja=0;this.i=[];this.ra=void 0;ve(this);this.A=this;this.pa={};this.X=this.ib=0;this.T=null;this.O=[];we(this,a.messages);this.ta=a.commands;this.M=0;this.Da=this.sa=null;this.B=this.Ca=this.za=this.ia=this.qa=0;this.ha=this.da=null;var b=this;window?void 0===window[A]&&(window[A]=function(a){return rd(b,a)}):void 0===global[A]&&(global[A]=function(a){return rd(b, +a)})}p(te,le);function S(a){a=a&&a.w;null==a&&(a=-1);return a}function Q(a,b,c){return{w:void 0===a?null:a,wb:void 0===b?!1:b,ea:!1,ba:c}}function xe(a,b){a.w=b.w;a.ea=b.ea;a.ba=b.ba}function ye(a,b){a.w=b;a.ea=!1;a.ba=void 0}function ze(a){return[a.w,a.wb,a.ba,a.ea,a.Oa]}function Ae(a,b){var c=Q(b[0],b[1],b[2]);c.ea=b[3];b[4]&&(c.gb=me(a,c.Oa=b[4]));return c}l=te.prototype; +l.va=function(a,b,c,d){this.D=b;this.C=a;this.g=c;this.ha=a.u;(a=Tc(a,"messages"))&&we(this,a);Be(this,function(a){a:{var b=d.D.b,c=a[0],e=a=0,k=b.length;if(c){a=S(T(d,c));if(-1===a){d.f("invalid address: "+c);break a}e=a>>>d.D.i;k=1}d.f("blockid physical blockaddr used size type");d.f("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;k--;){var n=b[e];n.type==c?m++||d.f("..."):(c=n.type,m=Dc[c],n&&d.f(E(n.id,8)+" %"+E(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.g.qa==b&&(b=Ed(a.g,1)));if(0d&&(d=a.g.H(b)),0<=d&&(ye(a.i[a.S],b),++a.S==a.i.length&&(a.S=0)));return!1} +function Pe(a,b,c,d){var e=Q(b.w),g=a.wa(b,1),f,h,k,m=0,n=g/Pb|0,r;for(r in Qe)if(f=Qe[r][n&r]){h=+r;n>>=6;switch(h){case 32512:k=wf;m=n&3;break;case 32256:k=yf;m=n&7;break;case 29248:k=zf,m=(n&48)>>2|(n&6)>>1}break}k=k&&k[m]||"";"S"==k&&f>Af&&(k="B");k=Bf[f||0]+k;k=cb(k,8);f?(k=28700==h?k+K(a,g/Qb&127,-1):k+K(a,g>>23&15,-1),k+=",",g&4194304&&(k+="@"),k+=K(a,g&262143,-1),(g=g>>18&15)&&(k+="("+K(a,g,-1)+")")):k+=De(g);g=k;f="";h=K(a,e.w)+":";if(-1!==e.w&&-1!==b.w){do if(k=a.wa(e,1),f+=" "+De(k),null== +e.w)break;while(e.w!=b.w)}h+=cb(f,16)+g;c&&(h=cb(h,48)+";"+(c||""),h=a.g.j.Ea?h+("cycles="+sd(a.g).toString()+" cs="+E(a.g.sa)):h+(null!=d?"="+d.toString():""));return h}function ue(a){var b,c;a.b=["bp"];if(a.L)for(b=1;b>>d.i],!1)}a.L=["br"];if(a.I)for(b=1;b>>d.i],!0);a.I=["bw"];a.qa=0;a.ja=0} +l.Ba=function(a,b,c){var d=!0;c||Cf(this,a,b,!1,!0);if(a!=this.b){var e=S(b);if(-1===e)this.f("invalid address: "+K(this,b.w)),d=!1;else{var g=this.D;g.b[e>>>g.i].Ba(e&16383,a==this.I)}}d&&(a.push(b),c?b.ea=!0:(Df(this,a,a.length-1,"set"),ve(this)));return d};function Cf(a,b,c,d,e){var g=!1;c=S(c);for(var f=1;f>>d.i],b==a.I));h.ea||ve(a);break}}return g} +function Ef(a,b){for(var c=1;cd;d++){!d||d&3||(c+="\n");var e=a,g=Wa(d,2);ye(e.ua,d);g+="="+K(e,e.wa(e.ua),36)+" ";c+=g}b&&(c+="\n"+(Gf(a,Fe)+Gf(a,Ge)+Gf(a,He)));return c}l.jb=function(a,b){return a[0]>b[0]?1:a[0]>>0,f],r=eb(n,k,a.jb);0>r&&n.splice(-(r+1),0,k)}m&&(h.a=m.replace(/''/g,'"'))}a.F.push({$c:b,w:c,zb:d,U:e,hb:g})}function If(a,b,c){var d=[],e=S(b)>>>0;for(b=0;b>>0,h=g.zb;if(e>=f&&eh[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.f(m)}h[3]&&(f=h[3],g=null);g=Pe(a,b,f,g);a.f(g);xe(a.J,b);e-=b.w-k;c++}}} +function Ff(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.f(Le+b):(a.R&&(a.f("ended assemble at "+K(a,a.P.w)),xe(a.J,a.P),a.R=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.T=null;if(Ia(a)&&0n||"z"Af&&($c="B");if(og==Bf[Ue]+$c){Te=29248!=cc?Ka:(Ka&3)<<1|(Ka&12)<<2;x=(Zc|Te<<6)*Pb;break}}if(0<= +x)break}if(0<=x)break}if(0<=x)if(Re)for(var ad=Re.split(","),fb=0;fbD||127D||15D||262143< +D){a.f("memory address out of range: "+V[2]);x=-1;break}x+=D;if(V[3]){D=P(a,V[3]);if(void 0==D){x=-1;break}if(0>D||15X.length&&(a.f("note: only "+X.length+" available"),N=X.length);R-=N;0>R&&(null==X[X.length-1].w?(N=R+N,R=0):R+=X.length);var fd=[];"call"==$e&&(hb=1E5,fd=["CALL"]);for(void 0!==Ze&&a.f(N+" instructions earlier:");0=X.length&&(R=0);a.ra=N;bf++;hb--}}bf||(a.f("no "+af+"history available"),a.ra=void 0)}else{var sa=T(a,W);if(sa){var ta=0,ef="ds"==Na;if(ka){if("l"==ka.charAt(0))ka=ka.substr(1)||rg,ta=pe(a,ka);else{var ff=T(a,ka);ff&&(ta=ff.w-sa.w)}0>ta&&(ta=0);65536kf;kf++)hf+=String.fromCharCode((ec%64|0)+32),ec/=64}ua&&(ua+="\n");ua=ef?ua+(va+","):ua+(W+": "+va+(0>jf?" "+hf:""))}ua&&a.f(ua);xe(a.xa,sa);a.ba=tg}}}}break;case "e":if("else"==f[0])break;var lf,mf,nf=f[0],id=f[1];"e"==nf||"ew"==nf?(lf=a.wa,mf=a.$a):id=null;if(null==id)a.f("edit memory commands:"),a.f("\tew [a] [...] edit words at address a");else{var fc=T(a,id);if(fc)for(var gc=2;gcmd;){for(var wa=null,xg=256;65536>kb.w>>>0;){nd.w=a.wa(kb,2);if(null==kb.w||!xg--)break;if(!(nd.w&1)){for(var yg=a,hc=nd,pf=null,lb=hc.w,qf=lb,od=1;6>=od&&lb;od++){if(2> ";Bb(function(){for(var a=B(document,A,"debugger"),b=0;b\nLicense: GPL version 3 or later ");for(b=0;bUf){if(Vf(d,this.L)){this.B=new H(this,"1.34.1",dg);Vf(this.B)&&(eg(this,d),a=fg,gg(this.B));this.B.set(ag,gb());hg(this.B);var e=this.b&&!this.J;if(a==bg||qa("Click OK to restore the previous "+Jb+" machine state, or CANCEL to reset the machine.")){if(c=$f(d)){var g=d.get("code"),f=d.get("data");g&&("ok"==g?Vf(d,f):("error"==g&&"no machine state"!= +f?(this.ca("Error: "+f),"unable to verify user"==f&&(ub(ig,""),this.i=null)):this.f(g+": "+f),gg(d),Vf(d)?(c=$f(d),e=!0):c=!1))}e&&Yf(this,c?d:null)}else a==fg&&d.clear()}else Yf(this);delete this.L;delete this.I}e=xa(this.id);for(g=0;ga[1];a=a[2];this.S=!0;this.j.V=!0;var d=this.G.power;d&&(d.textContent="Shutdown");this.g&&(jg(this,this.g,b,c,a),I(this,-2),this.g.Z());this.P&&(eg(this,b),b.clear());!c&&this.B&&(this.B.clear(),delete this.B);this.v=0}; +function eg(a,b){if(qa("There may be a problem with your "+Jb+" machine.\n\nTo help us diagnose it, click OK to send this "+Jb+" machine state to http://www.pcjs.org.")){var c=a.da;a=a.i||"";b=b.toString();var d={};d.app=Jb;d.ver="1.34.1";d.url=c;d.user=a;d.type="bug";d.data=b;pb("http://www.pcjs.org/api/v1/report",d,!0)}} +function Of(a,b,c){var d,e="none";if(a.v)return null;a.v--;var g=new H(a,"1.34.1"),f=new H(a,"1.34.1",Zf),h=gb();f.set(ag,h);g.set(ag,h);g.set(kg,"1.34.1");g.set(lg,window?window.location.href:null);g.set(mg,window?window.navigator.userAgent:"");a.g&&a.g.fa&&(c&&(b&&(a.g.j.Z=a.g.j.K),a.g.W()),d=a.g.fa(b,c),"object"===typeof d&&g.set(a.g.id,d),c&&(a.g.j.V=!1,!1===d&&(e=null)));for(var h=xa(a.id),k=0;k=d||30<=(c.Ca+=d))&&(e.textContent=c.j.K?c.R.toFixed(2)+"Mhz":"Stopped",c.Ca=0)}if(a.u&&(a=a.u,b=b||0,a.L)){c=a.g.j.K;d=!!(a.g.v&8);if(0>=b||60<=(a.J+=b)){e=a.g.u;if(a.G.PC){var g=a.A&&a.A.ba||8,e=e||0,e=8==g?Wa(e,void 0):E(e,void 0);a.G.PC.textContent!=e&&(a.G.PC.textContent=e)}a.J=0}-1>b?a.i=a.g.u:0f.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(f?' url="'+f+'"':"")));g||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));f=null;if("<"==a.charAt(0))try{g||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");pb(e,null,!0,function(g,f,h){if(h||!f)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(g=d[3])if(h=f.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(g);)k=0>k.indexOf(m[1])?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(f=f.replace(h[0],k))}else{c(a,"missing <"+d[1]+"> in "+e);return}f=f.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],f);Jg(a,b,c)}})}else c(a,null)} +function Kg(a,b,c,d,e){function g(a){if(void 0===k){var b=h&&B(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=ab(a))}function f(a){g("Error: "+a);m&&(--Gg||Fb(!0));m=!1}var h,k,m=!0;Gg++;oa[b]={};try{if(h=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],y=document.createElement("style");y.type="text/css";y.styleSheet?y.styleSheet.cssText=n:y.appendChild(document.createTextNode(n));r.appendChild(y)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.1/components.xsl");n=function(e,k){k?Hg(d,null,a,null,!1,g,function(a,e){e?(na(b,d,a),g("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Gg||Fb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Gg|| +Fb(!0)):f("invalid machine element: "+b):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(a)}):f(e)};"<"!=c.charAt(0)?Hg(c,b,a,e,!0,g,n):Ig(c,null,b,a,e,!1,g,n)}else f("missing machine element: "+b)}catch(U){f(U.message)}return m}window.embedPDP10=function(a,b,c,d){Fb(!1);return Kg("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){Fb(!1);return Kg("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return za(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!Ca[a]){for(var c=!0,d=Ca,e=a,g=b.length,f=[],h=[],k="",m=null,n=0;na?-b:b}});ha("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var ia=Math.pow(2,36),ja=-Math.pow(2,35),q={yb:0,Ra:1,Ab:2,Bb:3,Cb:4,Db:5,Eb:6,Fb:7,Ja:8,Gb:9,Sa:10,Hb:11,Ib:12,Ta:13,Jb:14,Kb:15,Lb:16,Mb:17,Nb:18,Ob:19,Pb:20,Qb:21,Rb:22,Sb:23,Tb:24,Ub:25,Vb:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ia:65,xb:66,zb:67,Wb:68,E:69,Xb:70,Yb:71,Zb:72,$b:73,ac:74,bc:75,cc:76,dc:77,ec:78,fc:79,gc:80,Q:81, +hc:82,ic:83,jc:84,kc:85,lc:86,mc:87,nc:88,oc:89,Ya:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pc:97,qc:98,rc:99,d:100,e:101,sc:102,tc:103,uc:104,vc:105,wc:106,k:107,xc:108,yc:109,n:110,zc:111,p:112,q:113,r:114,Ac:115,t:116,Bc:117,Cc:118,Dc:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Ua:127}; +function t(a,b){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Ma=b.comment;this.Xa=b;this.exports={};this.i=this.bindings={};a=this.id.indexOf(".");0>a?this.la=this.id:(this.ma=this.id.substr(0,a),this.la=this.id.substr(a+1));this.c={ready:!1,ra:!1,Da:!1,B:!1,error:!1};this.ta=null;this.c.error=!1;this.u=this.f=this.m=this.o=this.ba=null;u.push(this)}function la(a,b,c){ma[a]&&b&&(ma[a][b]=c)}function w(){return Date.now()||+new Date} +function x(a){window&&window.alert(a)}function na(a){var b=!1;window&&(b=window.confirm(a));return b}function y(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function xa(a,b){b?12"']/g,function(a){return Ca[a]})}function Da(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ca={"&":"&","<":"<",">":">",'"':""","'":"'"}; +function Ea(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function H(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var h=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(h.onreadystatechange=function(){4===h.readyState&&(f=h.responseText,200==h.status||!h.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=h.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var l="",p;for(p in b)b.hasOwnProperty(p)&&(l&&(l+="&"),l+=p+"="+encodeURIComponent(b[p]));l=l.replace(/%20/g,"+");h.open("POST",a,c);h.setRequestHeader("Content-type","application/x-www-form-urlencoded");h.send(l)}else h.open("GET",a,c),"bytes"==b&&h.overrideMimeType("text/plain; charset=x-user-defined"),h.send();c||(f=h.responseText,200!=h.status&&(e=h.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function Fa(a,b){var c,d={H:null,N:null,T:null,S:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.T=g.load;d.S=g.exec;if(e=g.bytes)d.H=e;else if(e=g.words)for(d.H=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.H=Array(4*e.length),f=c=0;c>8&255,d.H[f++]=e[c]>>16&255,d.H[f++]=e[c]>>24&255;else(e=g.data)?d.Y=e:d.H=g;d.H&&(d.H.length?1==d.H.length&&(x(d.H[0]),d=null):(x("Empty resource: "+a),d=null));d.N=g.symbols}catch(h){x("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.hb,a];this.u=this.f=this.m=this.o=null;this.exports={hold:this.$a,toggle:this.sb,reset:this.ob, +set:this.rb};E(this)}n(Za,t);k=Za.prototype;k.reset=function(a){this.stop();a&&N(this,this.h=0)}; +k.U=function(a,b,c,d){if(this.o&&this.o.U(a,b,c,d)||this.f&&this.f.U(a,b,c,d))return!0;switch(b){case "PC":return this.i[b]=c,this.D++,!0;default:return"led"==a||"rled"==a?(this.i[b]=c,this.j[b]=d?1:0,this.D++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.i[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){ab(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){bb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){ab(a, +b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){bb(a,b)}}(this,b),!0):t.prototype.U.call(this,a,b,c,d)}};k.Z=function(a,b,c,d){this.o=a;this.m=b;this.f=c;this.u=d;cb(this);db(this)};k.V=function(a,b){if(!b)if(this.R&&eb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};k.P=function(a){return a?this.save():!0};k.save=function(){var a=new O(this);a.set(0,[this.b,this.h,this.g]);return a.data()}; +k.restore=function(a){if(a=a[0])fb(this,this.b=a[0]),N(this,this.h=a[1]),gb(this,a[2]);return!0};k.ob=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}db(this);return!0};function hb(a,b,c){if(a=a.i[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function cb(a,b){for(var c in a.j)hb(a,c,null!=b?b:a.j[c])}function ib(a,b,c){if(a=a.i[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function db(a){for(var b in a.a)ib(a,b,a.a[b][1])} +k.$a=function(a,b,c){if(ab(this,b)){if(c){var d=this;setTimeout(function(){bb(d,b);a&&a()},+c);return!1}bb(this,b)}return!0}; +k.rb=function(a,b){if("SR"==a){a=b;b=8;var c;if(a){b||(b=10);var d=a.charAt(0),e=0>>a.b];a.h++;b=c.m(b&16383,b);a.h--;a=b}else a=this.f.l(this.b);N(this,this.h=a)}};k.gb=function(a){a||this.f.c.A||fb(this,this.g)};k.fb=function(a){a?(this.s=!0,cb(this,!0)):(this.s=!1,cb(this),gb(this,0))};k.hb=function(a,b){this.g=a?this.g|1<c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.a["S"+b][1]=a.g&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.b;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.aa)return h.va+=h.aa-e,h.aa=e,!0;if(e>=h.aa+h.va){p=h.size-(e-l);p>f&&(p=f);h.va=e-h.aa+p;e=l+16384;f-=p;g++;continue}}return xb(yb,e,f)}e=new R(a,e,p,16384,d);ub(e,h);a.a[g++]=e;e=l+16384;f-=p}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+zb[d]+" at "+xa(b)),!0):xb(Ab,b,c)}function sb(a,b,c){var d=a.a[(b&a.g)>>>a.b];a.h++;d.b(c,b&16383,b);a.h--} +function vb(a){for(var b=0,c=[],d=0;d=a.R&&(a.R+=a.da,c=!0);0<=a.ea&&a.ea<=Pb(a)&&(a.da=a.ea=-1,Ob(a),P(a),c=!0);c&&a.K(Pb(a)+" cycles: checksum="+F(a.na))}} +k.U=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.i[b]=c,!0;case "run":return this.i[b]=c,c.onclick=function(){var a;if(a=d.o)if(a=d.o,a.c.B)a=!0;else{var b=null,c,h=y(a.id);for(c=0;ca.L/a.O&&(b=1);a.W=b;b=a.za*a.W;if(a.O!=b){a.O=b;b=a.O.toFixed(2)+"Mhz";var d=a.i.setSpeed;d&&(d.textContent=b);a.K("target speed: "+b)}c&&a.o&&(c=a.o,c.ba&&(d=b=0,window&&(b=window.scrollX,d=window.scrollY),c.ba.focus(),window&&window.scrollTo(b,d)))}pb(a,a.s);a.s=0;a.j=w();a.C=0;Rb(a)}function Tb(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Ub(a,b){var c=a.D-=a.G;a.G=0;b&&(a.D=0);return c} +k.pb=function(){if(this.c.A){this.pa>=this.Ba&&Rb(this,!0);this.ca=0;this.ja=w();if(this.C){var a=this.ja-this.C;a>this.Aa&&(this.j+=a,this.j>this.ja&&(this.j=this.ja))}try{do{for(var b,c=this.c.sa?1:this.fa,d=this.w.length-1;0<=d;d--){var e=this.w[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.wa(b)}catch(f){if("number"!=typeof f)throw f;}b=Ub(this,!0);this.ca+=b;this.s+=b;qb(this,b);ob(this,b);this.X-=b;if(0>=this.X){this.X+=this.fa;++this.Ca>=Vb&&(this.o&&Q(this.o,void 0),this.Ca=0);break}}while(this.c.A)}catch(f){P(this); +this.o&&this.o.stop(w(),Pb(this));a=f.stack||f.message;this.c.error=!0;this.F(a);return}if(this.c.A){a=setTimeout;b=this.Na;this.C=w();c=this.Aa;this.ca&&(c=Math.round(c*this.ca/this.fa));c-=this.C-this.ja;if(d=this.C-this.j)this.L=Math.round(this.s/(10*d))/100,864E5<=d&&(this.I=0,Qb(this));if(0>c||this.Lc&&(this.j-=c),c=0;this.pa+=this.ca;this.C+=c;a(b,c)}}}; +function nb(a){var b;a.c.error?(a.K(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.c.A)a.K(a.toString()+" busy");else{Qb(a);a.c.A=!0;a.c.Ga=!0;if(b=a.i.run)b.textContent="Halt";a.o&&a.o.start(a.j,Pb(a));a.u||a.status("Started");setTimeout(a.Na,0)}}k.wa=function(){return 0};function P(a){var b=!1;if(a.c.A){Ub(a);pb(a,a.s);a.s=0;a.c.A=!1;if(b=a.i.run)b.textContent="Run";a.o&&a.o.stop(w(),Pb(a));b=!0;a.u||a.status("Stopped")}a.c.complete=void 0;return b}var Sb=30,Vb=15,Mb=["power","reset"]; +function Wb(a){var b=+a.model||1001;Lb.call(this,a,1E6);this.Va=b;this.La=+a.addrReset||0;this.Wa=Xb.bind(this);this.a=T.bind(this);this.ha=null;this.Ka=[];this.c.complete=!1}n(Wb,Lb);k=Wb.prototype;k.reset=function(){this.status("Model "+this.Va);this.c.A&&P(this);this.b=this.M=this.qa=0;this.ia=this.h=this.ya=this.La;this.g=0;this.l=this.lb;this.v=this.wb;this.ha=null;Nb(this);this.c.error=!1;Lb.prototype.reset.call(this)};k.Pa=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[this.b,this.M,this.qa,this.h,this.ya,this.ia,this.g]);a.set(1,[]);a.set(2,[this.I,this.W,this.c.J]);a.set(3,Yb(this));a.set(4,Tb(this));return a.data()}; +k.restore=function(a){var b;b=a[0];ea();ba();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.b=b.next().value;this.M=b.next().value;this.qa=b.next().value;this.h=b.next().value;this.ya=b.next().value;this.ia=b.next().value;this.g=b.next().value;b=a[2];this.I=b[0];Qb(this,b[1]);this.c.J=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.b].l(a&16383,a)};k.wb=function(a,b){var c=this.m;a=this.ia=a;c.a[(a&c.g)>>>c.b].v(b,a&16383,a)}; +k.wa=function(a){this.c.complete=!0;var b=a?this.c.Ga?0:1:-1;this.c.Ga=!1;this.D=this.G=a;this.g=this.g&-5|0;do{if(a=this.g)if(a=this.g&11)this.g&2?this.ha||(this.g&=-3):this.g&1&&this.g++,a=!1;if(a){if(this.g&4&&this.u.h(this.h,b)){P(this);break}if(0>b)break}this.g&=15;this.M=this.M&4194304?this.l(this.b)&8388607:(this.qa=this.l(this.ya=this.h))&8388607;this.b=this.M&262143;if(a=this.M>>18&15)this.b=this.b+this.l(a)&Ua;this.M&4194304?a=-1:(this.h=(this.h+1)%Ta,a=this.qa/Ya|0);0<=a&&this.Wa(a)}while(0< +this.G);return this.c.complete?this.D-this.G:!1===this.c.complete?-1:0};I(function(){for(var a=D(document,C,"cpu"),b=0;b>4].call(this,a)}function U(a){this.a(a)}function $b(a){this.a(a)}function ac(a){this.a(a)}function bc(a){var b=a&15,c=this.l(this.b),d=this.l(b);this.v(b,V(a,d,c)+(c-(c&262143)))}function cc(a){var b=a&15,c=this.l(b);this.v(b,V(a,c,0))} +function dc(a){var b=this.l(a&15),c=this.l(this.b);this.v(this.b,V(a,c,b)+(b-(b&262143)))}function ec(a){var b=this.l(this.b);this.v(this.b,fc(a,b,b));var c=a&15;c&&(b=this.l(c),this.v(c,fc(a,b,b)))}function gc(a){var b=a&15,c=(this.l(this.b)&262143)*M,d=this.l(b);this.v(b,V(a,d,c)+c)}function hc(a){var b=a&15,c=this.b*M,d=this.l(b);this.v(b,V(a,d,c)+c)}function ic(a){var b=(this.l(a&15)&262143)*M,c=this.l(this.b);this.v(this.b,V(a,c,b)+b)} +function jc(a){var b=this.l(this.b),c=(b&262143)*M;this.v(this.b,V(a,b,c)+c);var d=a&15;d&&(b=this.l(d),c=(b&262143)*M,this.v(d,V(a,b,c)+c))}function kc(a){var b=a&15,c=this.l(this.b)&262143,d=this.l(b);this.v(b,W(a,d,c)+c)}function lc(a){var b=a&15,c=this.l(b);this.v(b,W(a,c,this.b)+this.b)}function mc(a){var b=this.l(a&15)&262143,c=this.l(this.b);this.v(this.b,W(a,c,b)+b)}function nc(a){var b=this.l(this.b);this.v(this.b,oc(a,b,b));var c=a&15;c&&(b=this.l(c),this.v(c,oc(a,b,b)))} +function pc(a){var b=a&15,c=this.l(this.b)/M|0,d=this.l(b);this.v(b,W(a,d,c)+c)}function qc(a){var b=a&15,c=this.l(b);this.v(b,W(a,c,0))}function rc(a){var b=this.l(a&15)/M|0,c=this.l(this.b);this.v(this.b,W(a,c,b)+b)}function sc(a){var b=this.l(this.b),c=b/M|0;this.v(this.b,W(a,b,c)+c);var d=a&15;d&&(b=this.l(d),c=b/M|0,this.v(d,W(a,b,c)+c))}function X(a){this.a(a)}function T(a){this.K("undefined opcode: "+xa(a));this.h=(this.h+-1)%Ta;P(this)} +function W(a,b,c){switch(a&384){case 0:b-=b&262143;break;case 128:b=0;break;case 256:b=262143*M;break;case 384:b=c>Wa?262143*M:0}return b}function oc(a,b,c){if(a&=384)switch(b&=262143,a){case 256:b+=262143*M;break;case 384:b+=c>Wa?262143*M:0}return b}function V(a,b,c){switch(a&384){case 0:b&=262143;break;case 128:b=0;break;case 256:b=262143;break;case 384:b=c>Xa?262143:0}return b}function fc(a,b,c){if(a&=384)switch(b-=b&262143,a){case 256:b+=262143;break;case 384:b+=c>Xa?262143:0}return b} +var Zb=[U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,U,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},$b,ac,ac,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},$b,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},T,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},T,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},bc,cc,dc,ec,gc,hc,ic,jc,bc,cc,dc,ec,gc,hc,ic,jc,bc,cc,dc,ec,gc,hc,ic,jc,bc,cc,dc,ec,gc,hc,ic,jc,kc,lc,mc,nc,pc,qc,rc,sc,kc,lc,mc,nc,pc,qc,rc,sc,kc,lc,mc,nc,pc,qc,rc,sc,kc,lc,mc,nc, +pc,qc,rc,sc,function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)}, +function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},function(a){this.a(a)},X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X, +X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X]; +function tc(a){t.call(this,"ROM",a);this.N=this.a=null;this.j=+a.addr;this.g=+a.size;this.b=a.alias;"string"==typeof this.b&&(this.b=eval(this.b));this.h=a.file;this.s=ya(this.h);if(this.h){a=this.h;var b=za(this.s);"json"!=b&&"hex"!=b&&(a=G()+"/api/v1/dump?file="+this.h+"&format=bytes&decimal=true");var c=this;H(a,null,!0,function(a,b,f){f?(c.F("Unable to load ROM resource (error "+f+": "+a+")"),c.h=null):(la(c.ma,a,b),(a=Fa(a,b))?(c.a=a.H,c.N=a.N):c.h=null);uc(c)})}}n(tc,t); +tc.prototype.Z=function(a,b,c,d){this.m=b;this.f=c;this.u=d;uc(this)};tc.prototype.V=function(){this.N&&(this.u&&this.u.a(this.id,this.j,this.g,this.N),delete this.N);return!0};tc.prototype.P=function(){return!0}; +function uc(a){if(!ua(a)){if(a.h){if(!a.a||!a.m)return;a.g||(a.g=a.a.length);if(a.a.length!=a.g){var b="ROM size ("+F(a.a.length,8,!0)+") does not match specified size ("+F(a.g,8,!0)+")";a.c.error=!0;a.F(b)}else{b=a.j;if(wb(a.m,b,a.g,Eb)){var c;for(c=0;c>>f.b;0>>=f.b;0>>a.b;0g&&g>=ja&&(g+=ia);g=Math.trunc(Math.abs(g))%ia;void 0===f&&(f=e.size);for(h=d;f--&&h=q.Ia&&c<=q.Ya&&(b=c-(q.Ia-q.Ra));b&&(a.preventDefault&&a.preventDefault(),d.ua(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==q.Ta&&(b=q.Sa);d.ua(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.ua(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};k.Z=function(a,b,c,d){this.o=a;this.m=b;this.f=c;this.u=d;E(this)}; +k.Qa=function(a){if(!this.a){var b=S(this.o,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Da(c[0]);if(d!=this.la)return;c=Da(c[1]);if(this.a=oa(c)){var e=this.a.exports;if(e){var f=e.connect;f&&f.call(this.a,this.g);if(this.j=e.receiveData){this.g=a;this.status("Connected "+this.ma+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};k.V=function(a,b){if(!b)if(this.Qa(this.g),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +k.P=function(a){return a?this.save():!0};k.reset=function(){};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return!0};k.ua=function(a){if("number"==typeof a)this.b.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d\nLicense: GPL version 3 or later ");for(b=0;bCc){if(Z(d,this.D)){this.j=new O(this,"1.34.1",Lc);Z(this.j)&&(Mc(this,d),a=Nc,Oc(this.j));this.j.set(Ic,Ea());Pc(this.j);var e=this.a&&!this.C;if(a==Jc||na("Click OK to restore the previous "+L+" machine state, or CANCEL to reset the machine.")){if(c=Hc(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Z(d,g):("error"==f&&"no machine state"!= +g?(this.F("Error: "+g),"unable to verify user"==g&&(Ja(Qc,""),this.b=null)):this.K(f+": "+g),Oc(d),Z(d)?(c=Hc(d),e=!0):c=!1))}e&&Fc(this,c?d:null)}else a==Nc&&d.clear()}else Fc(this);delete this.D;delete this.w}e=y(this.id);for(f=0;fa[1];a=a[2];this.O=!0;this.c.B=!0;var d=this.i.power;d&&(d.textContent="Shutdown");this.f&&(Rc(this,this.f,b,c,a),Q(this,-2),this.f.J());this.L&&(Mc(this,b),b.clear());!c&&this.j&&(this.j.clear(),delete this.j);this.h=0}; +function Mc(a,b){if(na("There may be a problem with your "+L+" machine.\n\nTo help us diagnose it, click OK to send this "+L+" machine state to http://www.pcjs.org.")){var c=a.X;a=a.b||"";b=b.toString();var d={};d.app=L;d.ver="1.34.1";d.url=c;d.user=a;d.type="bug";d.data=b;H("http://www.pcjs.org/api/v1/report",d,!0)}} +function Sc(a,b,c){var d,e="none";if(a.h)return null;a.h--;var f=new O(a,"1.34.1"),g=new O(a,"1.34.1",Gc),h=Ea();g.set(Ic,h);f.set(Ic,h);f.set(Tc,"1.34.1");f.set(Uc,window?window.location.href:null);f.set(Vc,window?window.navigator.userAgent:"");a.f&&a.f.P&&(c&&(b&&(a.f.c.J=a.f.c.A),P(a.f)),d=a.f.P(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.c.B=!1,!1===d&&(e=null)));for(var h=y(a.id),l=0;l=d||30<=(c.xa+=d))&&(e.textContent=c.c.A?c.L.toFixed(2)+"Mhz":"Stopped",c.xa=0)}if(a.g&&(a=a.g,b=b||0,a.D)){c=a.f.c.A;d=!!(a.f.g&8);if(0>=b||60<=(a.C+=b)){e=a.f.h;if(a.i.PC){var f=a.u&&a.u.j||8,e=e||0,e=8==f?xa(e,void 0):F(e,void 0);a.i.PC.textContent!=e&&(a.i.PC.textContent=e)}a.C=0}-1>b?a.b=a.f.h:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){g=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");H(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=h[0],p,r=/( [a-z]+=)(['"])(.*?)\2/g;p=r.exec(f);)l=0>l.indexOf(p[1])?l.replace(">",p[0]+">"):l.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=l&&(g=g.replace(h[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);cd(a,b,c)}})}else c(a,null)} +function dd(a,b,c,d,e){function f(a){if(void 0===l){var b=h&&D(h,"machine-warning");l=b&&b[0]||h}l&&(l.innerHTML=Ba(a))}function g(a){f("Error: "+a);p&&(--$c||K(!0));p=!1}var h,l,p=!0;$c++;ma[b]={};try{if(h=document.getElementById(b)){var r;if("object"==typeof resources&&(r=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],ka=document.createElement("style");ka.type="text/css";ka.styleSheet?ka.styleSheet.cssText=r:ka.appendChild(document.createTextNode(r));v.appendChild(ka)}d|| +(r=a,"pdp"==a.substr(0,3)&&(r="pdpjs"),d="/versions/"+r+"/1.34.1/components.xsl");r=function(e,l){l?ad(d,null,a,null,!1,f,function(a,e){e?(la(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(h.outerHTML=e,--$c||K(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--$c|| +K(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?ad(c,b,a,e,!0,f,r):bd(c,null,b,a,e,!1,f,r)}else g("missing machine element: "+b)}catch(ed){g(ed.message)}return p}window.embedPDP10=function(a,b,c,d){K(!1);return dd("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){K(!1);return dd("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return z(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!qa[a]){for(var c=!0,d=qa,e=a,f=b.length,g=[],h=[],l="",p=null,r=0;ra?-b:b}});ja("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}});ja("Array.prototype.fill",function(a){return a?a:function(a,c,d){var b=this.length||0;0>c&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,Jd:65,wi:66,Ci:67,cj:68,E:69,ij:70,lj:71,xj:72,zj:73,Aj:74,Bj:75,Cj:76,Fj:77,Hj:78,Nj:79,Qj:80,Q:81,Sj:82,Vj:83,dk:84,fk:85,hk:86,ik:87,mk:88,nk:89,xf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,pk:97,rk:98,uk:99,d:100,e:101,vk:102,wk:103,xk:104,yk:105,Ck:106,k:107,Dk:108,Ek:109,n:110,Fk:111,p:112,q:113,r:114,Gk:115,t:116,Jk:117,Kk:118,Lk:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,cc:127};function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Vd=b.comment;this.vf=b;this.exports={};this.H=this.bindings={};a=this.id.indexOf(".");0>a?this.Mb=this.id:(this.vb=this.id.substr(0,a),this.Mb=this.id.substr(a+1));this.A={ready:!1,eb:!1,wd:!1,ba:!1,error:!1};this.Nc=null;this.A.error=!1;this.ha=c||0;this.D=this.f=this.F=this.J=this.Ta=null;ma.push(this)}function na(a,b,c){pa[a]&&b&&(pa[a][b]=c)} +function qa(){return Date.now()||+new Date}function v(a){window&&window.alert(a)}function ra(a){var b=!1;window&&(b=window.confirm(a));return b}function ta(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function Ma(a,b,c){var d="";b?32>=1,f--;return d} +function E(a,b,c){b?12"']/g,function(a){return Xa[a]})}function Ya(a,b){return(a+" ").slice(0,b)}function Za(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Xa={"&":"&","<":"<",">":">",'"':""","'":"'"},$a={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"};function ab(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1,k;k=c(b,a[g]);0a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function cb(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var k=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(k.onreadystatechange=function(){4===k.readyState&&(f=k.responseText,200==k.status||!k.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=k.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");k.open("POST",a,c);k.setRequestHeader("Content-type","application/x-www-form-urlencoded");k.send(l)}else k.open("GET",a,c),"bytes"==b&&k.overrideMimeType("text/plain; charset=x-user-defined"),k.send();c||(f=k.responseText,200!=k.status&&(e=k.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function db(a,b){var c,d={Z:null,ga:null,ya:null,xa:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ya=g.load;d.xa=g.exec;if(e=g.bytes)d.Z=e;else if(e=g.words)for(d.Z=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.Z=Array(4*e.length),f=c=0;c>8&255,d.Z[f++]=e[c]>>16&255,d.Z[f++]=e[c]>>24&255;else(e=g.data)?d.qk=e:d.Z=g;d.Z&&(d.Z.length?1==d.Z.length&&(v(d.Z[0]),d=null):(v("Empty resource: "+a),d=null));d.ga=g.symbols}catch(k){v("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.b["S"+a]=[0,0,!1,!1,this.Sf,a];this.D=this.f=this.F=this.J=null;this.exports={hold:this.Hf,toggle:this.lh, +reset:this.gh,set:this.kh};y(this)}p(Sb,u);function Ub(a,b){return Vb(a,a.Eb=b)}h=Sb.prototype;h.reset=function(a){this.stop();a&&Ub(this,0)}; +h.va=function(a,b,c,d){if(this.J&&this.J.va(a,b,c,d)||this.f&&this.f.va(a,b,c,d)||this.D&&this.D.va(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.H[b]=c,this.u++,!0;default:return"led"==a||"rled"==a?(this.H[b]=c,this.i[b]=d?1:0,this.u++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.H[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a, +b){return function(){Wb(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){Xb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){Wb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){Xb(a,b)}}(this,b),!0):u.prototype.va.call(this,a,b,c,d)}};h.za=function(a,b,c,d){this.J=a;this.F=b;this.f=c;this.D=d;dc(b,this,ec);fc(b,this.reset.bind(this));gc(this);hc(this)}; +h.Ca=function(a,b){if(!b)if(this.M&&ic(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.save=function(){var a=new G(this);a.set(0,[this.fa,this.Eb,this.Wa]);return a.data()};h.restore=function(a){if(a=a[0])jc(this,this.fa=a[0]),Ub(this,a[1]),kc(this,a[2]);return!0};h.gh=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}hc(this);return!0};function lc(a,b,c){if(a=a.H[b])a.style.backgroundColor=c?"#ff0000":"#000000"} +function gc(a,b){for(var c in a.i)lc(a,c,null!=b?b:a.i[c])}function mc(a,b,c){if(a=a.H[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function hc(a){for(var b in a.b)mc(a,b,a.b[b][1])}function nc(a,b,c,d){if(a.H[b]){var e=a.D&&a.D.Aa||8;c=c||0;c=8==e?E(c,d):F(c,d);a.H[b].textContent!=c&&(a.H[b].textContent=c)}}h.Hf=function(a,b,c){if(Wb(this,b)){if(c){var d=this;setTimeout(function(){Xb(d,b);a&&a()},+c);return!1}Xb(this,b)}return!0}; +h.kh=function(a,b){if("SR"==a)return kc(this,Ka(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,mc(this,a,c[1]),!0):!1};h.lh=function(a){return Wb(this,a)?(Xb(this,a),!0):!1};function Wb(a,b){var c=a.b[b];return c?(mc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=oc&&(a.G=b==pc,a.I=b==qc),!0):!1}function Xb(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(mc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} +h.Tf=function(a){a||this.f.A.V||(rc(this.f,this.fa),a=this.f,a.F.reset(),sc(a),this.b[tc]&&this.b[tc][1]&&uc(this.f))};h.Uf=function(){};h.Of=function(a){a||this.f.ca()};h.Mf=function(a){if(!a&&!this.f.A.V)if(this.b[tc]&&this.b[tc][1])uc(this.f);else{if((a=this.D)&&!Ha(a,!0))Ja(a,!0),vc(a,0,null),Ja(a,!1);else try{var b=this.f.Cc(1);0=a.f.ka?8:16,c=65472<=a.fa&&a.fa<65472+b,b=c?1:2,c=c?15:a.F.I;a.b[oc]&&a.b[oc][1]||(b=-b);jc(a,a.fa&~c|a.fa+b&c)}function jc(a,b){a.fa=b&a.F.I;if(a.B!==a.fa){a.B=a.fa;b=a.B;for(var c=0;22>c;c++)Ec(a,"A"+c,b&1<c;c++)Ec(a,"D"+c,b&1<b;b++)a.b["S"+b][1]=a.Wa&1<>2;this.i=this.j-1;this.G=this.M/this.j|0;this.S=this.G-1;this.Pa=[];this.na=0;this.C=!1;this.N=[];this.yf=[Ic,Jc,Kc,Wc];this.b=this.u=[];this.B=this.L=this.w=this.O=this.P=0;a=new I(this);Xc(a,this.D);this.b=Array(this.G);this.u=Array(this.G);for(b=0;b>>this.g;this.L=0;this.w=this.I;y(this)}p(Gc,u);function $c(a,b){if(b!=a.L){for(var c=0;c>>a.g,a.u[a.P]=a.b[a.O])}}h=Gc.prototype;h.reset=function(){for(var a=0;a>>a.g;0g&&(n=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.K)return l.Xb+=l.K-f,l.K=f,!0;if(f>=l.K+l.Xb){n=l.size-(f-m);n>g&&(n=g);l.Xb=f-l.K+n;f=m+a.j;g-=n;k++;continue}}return bd(cd,f,g)}f=new I(a,f,n,a.j,d,e);Xc(f,a.D,l);a.b[k++]=f;f=m+a.j;g-=n}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+dd[d]+" at "+E(b)),!0):bd(ed,b,c)}h.Kd=function(a){return this.u[(a&this.w)>>>this.g].Db(a&this.i,a)}; +h.Bc=function(a){var b=a&this.i,c=(a&this.w)>>>this.g;return Lb||b!=this.i?this.u[c].oa(b,a):this.u[c++].Db(b,a)|this.u[c&this.S].Db(0,a+1)<<8};h.Ld=function(a,b){this.u[(a&this.w)>>>this.g].Gb(a&this.i,b,a)};h.ac=function(a,b){var c=a&this.i,d=(a&this.w)>>>this.g;Lb||c!=this.i?this.u[d].Hb(c,b,a):(this.u[d++].Gb(c,b&255,a),this.u[d&this.S].Gb(0,b>>8&255,a+1))};function fd(a,b){return a.b[(b&a.I)>>>a.g]} +function Cc(a,b){var c;a.C=!1;a.na++;var d=b&a.i,e=fd(a,b);Lb||d!=a.i?c=e.B(d,b):c=e.J(d,b)|fd(a,b+1).J(0,b+1)<<8;a.na--;return c}function gd(a,b,c){a.C=!1;a.na++;fd(a,b).F(b&a.i,c&255,b);a.na--}function Ac(a,b,c){a.C=!1;a.na++;var d=b&a.i,e=fd(a,b);Lb||d!=a.i?e.C(d,c&65535,b):(e.F(d,c&255,b),fd(a,b+1).F(0,c>>8&255,b+1));a.na--} +function ad(a){for(var b=0,c=[],d=0;da.f.ka)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,n=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&n&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(n)));for(var q=g[4],t=g[5]||1,r=0;r>8:e[2](f)&255):f&1&&(e=d.Pa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return this.f&&z(this.f,16|e[5])&&C(this.f,e[4]+".readByte("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,3);c=255;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to byte @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} +function Jc(a,b,c){var d=!1,e=this.controller,f=e.Pa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Pa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d?this.f&&z(this.f,16|f[5])&&C(this.f,f[4]+".writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,5),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to byte @"+K(this.f,c)+": "+K(this.f, +b),!0,!e.na))}function Kc(a,b){var c=-1,d=this.controller;a=d.Pa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".readWord("+K(this.f,b)+"): "+K(this.f,c),!0,!d.na),c;d.Na(b,16,2);c=65535;this.f&&z(this.f,16)&&C(this.f,"warning: unconverted read access to word @"+K(this.f,b)+": "+K(this.f,c),!0,!d.na);return c} +function Wc(a,b,c){var d=!1,e=this.controller;a=e.Pa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d?this.f&&z(this.f,16|a[5])&&C(this.f,a[4]+".writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0,!e.na):(e.Na(c,16,4),this.f&&z(this.f,16)&&C(this.f,"warning: unconverted write access to word @"+K(this.f,c)+": "+K(this.f,b),!0,!e.na))}function L(a){u.call(this,"Device",a,256);this.b={gb:128,Hd:-1}}p(L,u);h=L.prototype; +h.za=function(a,b,c,d){this.F=b;this.J=a;this.f=c;this.D=d;var e=this;this.b.Hd=md(c,function(){e.b.gb|=128;e.b.gb&64&&nd(e.f,e.b.Qa);e.J&&H(e.J,1);od(e.f,e.b.Hd,1E3/60)});this.b.Qa=pd(c,64,6,2097152);dc(b,this,qd);fc(b,this.reset.bind(this));d&&rd(d,64,function(a){var b=e.f;sd(e,"KIPDR",b.B[0],0,a[0]);sd(e,"KDPDR",b.B[0],8,a[0]);sd(e,"KIPAR",b.M[0],0,a[0]);sd(e,"KDPAR",b.M[0],8,a[0],!0);sd(e,"SIPDR",b.B[1],0,a[0]);sd(e,"SDPDR",b.B[1],8,a[0]);sd(e,"SIPAR",b.M[1],0,a[0]);sd(e,"SDPAR",b.M[1],8,a[0], +!0);sd(e,"UIPDR",b.B[3],0,a[0]);sd(e,"UDPDR",b.B[3],8,a[0]);sd(e,"UIPAR",b.M[3],0,a[0]);sd(e,"UDPAR",b.M[3],8,a[0],!0);b.W&32&&sd(e,"UNIMAP",b.Ha,-1,a[0])});y(this)};function sd(a,b,c,d,e,f){a=a.D;if(!(e&&0>b.indexOf(e.toUpperCase()))){e=0;var g=8,k="",l=!1,m=8;0>d&&(e=22,g=c.length,d=0,l=!0,m=4);for(var n=0;n>1&63;var b=this.f.Ha[a>>1];return a&1?b>>16:b&65535};h.mi=function(a,b){b=b>>1&63;var c=b>>1;this.f.Ha[c]=b&1?this.f.Ha[c]&65535|(a&63)<<16:this.f.Ha[c]&-65536|a&65534};h.Pg=function(a){return this.f.B[1][a>>1&7]};h.fi=function(a,b){this.f.B[1][b>>1&7]=a&65295};h.Ng=function(a){return this.f.B[1][(a>>1&7)+8]};h.di=function(a,b){this.f.B[1][(b>>1&7)+8]=a&65295};h.Og=function(a){return this.f.M[1][a>>1&7]}; +h.ei=function(a,b){b=b>>1&7;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.Mg=function(a){return this.f.M[1][(a>>1&7)+8]};h.ci=function(a,b){b=(b>>1&7)+8;this.f.M[1][b]=a;this.f.B[1][b]&=65295};h.eg=function(a){return this.f.B[0][a>>1&7]};h.xh=function(a,b){this.f.B[0][b>>1&7]=a&65295};h.cg=function(a){return this.f.B[0][(a>>1&7)+8]};h.vh=function(a,b){this.f.B[0][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.f.M[0][a>>1&7]};h.wh=function(a,b){b=b>>1&7;this.f.M[0][b]=a;this.f.B[0][b]&=65295}; +h.bg=function(a){return this.f.M[0][(a>>1&7)+8]};h.uh=function(a,b){b=(b>>1&7)+8;this.f.M[0][b]=a;this.f.B[0][b]&=65295};h.Vg=function(a){return this.f.B[3][a>>1&7]};h.li=function(a,b){this.f.B[3][b>>1&7]=a&65295};h.Tg=function(a){return this.f.B[3][(a>>1&7)+8]};h.ji=function(a,b){this.f.B[3][(b>>1&7)+8]=a&65295};h.Ug=function(a){return this.f.M[3][a>>1&7]};h.ki=function(a,b){b=b>>1&7;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Sg=function(a){return this.f.M[3][(a>>1&7)+8]}; +h.ii=function(a,b){b=(b>>1&7)+8;this.f.M[3][b]=a;this.f.B[3][b]&=65295};h.Vb=function(a){a&=7;return this.f.w&2048?this.f.ta[a]:this.f.g[a]};h.Zb=function(a,b){b&=7;this.f.w&2048?this.f.ta[b]=a:this.f.g[b]=a};h.rg=function(){return this.f.w&49152?this.f.X[0]:this.f.g[6]};h.Ih=function(a){this.f.w&49152?this.f.X[0]=a:this.f.g[6]=a};h.ug=function(){return this.f.g[7]};h.Lh=function(a){this.f.g[7]=a};h.Wb=function(a){a&=7;return this.f.w&2048?this.f.g[a]:this.f.ta[a]}; +h.$b=function(a,b){b&=7;this.f.w&2048?this.f.g[b]=a:this.f.ta[b]=a};h.sg=function(){return 1==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[1]};h.Jh=function(a){1==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[1]=a};h.tg=function(){return 3==(this.f.w&49152)>>14?this.f.g[6]:this.f.X[3]};h.Kh=function(a){3==(this.f.w&49152)>>14?this.f.g[6]=a:this.f.X[3]=a};h.ag=function(a){return this.f.xc[a-65504>>1]};h.th=function(a,b){this.f.xc[b-65504>>1]=a};h.xe=function(a){return 65520==a?(hd(this.F)>>6)-1:0}; +h.Ce=function(){};h.Rg=function(){return 1};h.hi=function(){};h.$f=function(){return this.f.P};h.sh=function(){this.f.P=0};h.gg=function(){return this.f.uc};h.zh=function(a,b){b&1||(a&=255);this.f.uc=a};h.lg=function(a,b){return b?0:this.f.ob};h.Ch=function(a){zd(this.f,a)};h.Qg=function(a,b){return b?0:this.f.Ga&65280};h.gi=function(a){this.f.Ga=a|255};h.qg=function(){return Ad(this.f)};h.Hh=function(a){Bd(this.f,a)};h.Be=function(a,b){z(this)&&C(this,"writeIgnored("+E(b)+"): "+E(a),!0,!0)}; +var M={},qd=(M[61568]=[null,null,L.prototype.Wg,L.prototype.mi,"UNIMAP",64,1170],M[62592]=[null,null,L.prototype.Pg,L.prototype.fi,"SIPDR",8,1145,64],M[62608]=[null,null,L.prototype.Ng,L.prototype.di,"SDPDR",8,1145,64],M[62624]=[null,null,L.prototype.Og,L.prototype.ei,"SIPAR",8,1145,64],M[62640]=[null,null,L.prototype.Mg,L.prototype.ci,"SDPAR",8,1145,64],M[62656]=[null,null,L.prototype.eg,L.prototype.xh,"KIPDR",8,1140,64],M[62672]=[null,null,L.prototype.cg,L.prototype.vh,"KDPDR",8,1145,64],M[62688]= +[null,null,L.prototype.dg,L.prototype.wh,"KIPAR",8,1140,64],M[62704]=[null,null,L.prototype.bg,L.prototype.uh,"KDPAR",8,1145,64],M[62798]=[null,null,L.prototype.kg,L.prototype.Bh,"MMR3",1,1145,64],M[65382]=[null,null,L.prototype.fg,L.prototype.yh,"LKS"],M[65402]=[null,null,L.prototype.hg,L.prototype.Ah,"MMR0",1,1140,64],M[65404]=[null,null,L.prototype.ig,L.prototype.Be,"MMR1",1,1145,64],M[65406]=[null,null,L.prototype.jg,L.prototype.Be,"MMR2",1,1140,64],M[65408]=[null,null,L.prototype.Vg,L.prototype.li, +"UIPDR",8,1140,64],M[65424]=[null,null,L.prototype.Tg,L.prototype.ji,"UDPDR",8,1145,64],M[65440]=[null,null,L.prototype.Ug,L.prototype.ki,"UIPAR",8,1140,64],M[65456]=[null,null,L.prototype.Sg,L.prototype.ii,"UDPAR",8,1145,64],M[65472]=[null,null,L.prototype.Vb,L.prototype.Zb,"R0SET0"],M[65473]=[null,null,L.prototype.Vb,L.prototype.Zb,"R1SET0"],M[65474]=[null,null,L.prototype.Vb,L.prototype.Zb,"R2SET0"],M[65475]=[null,null,L.prototype.Vb,L.prototype.Zb,"R3SET0"],M[65476]=[null,null,L.prototype.Vb, +L.prototype.Zb,"R4SET0"],M[65477]=[null,null,L.prototype.Vb,L.prototype.Zb,"R5SET0"],M[65478]=[null,null,L.prototype.rg,L.prototype.Ih,"R6KERNEL"],M[65479]=[null,null,L.prototype.ug,L.prototype.Lh,"R7KERNEL"],M[65480]=[null,null,L.prototype.Wb,L.prototype.$b,"R0SET1",1,1145],M[65481]=[null,null,L.prototype.Wb,L.prototype.$b,"R1SET1",1,1145],M[65482]=[null,null,L.prototype.Wb,L.prototype.$b,"R2SET1",1,1145],M[65483]=[null,null,L.prototype.Wb,L.prototype.$b,"R3SET1",1,1145],M[65484]=[null,null,L.prototype.Wb, +L.prototype.$b,"R4SET1",1,1145],M[65485]=[null,null,L.prototype.Wb,L.prototype.$b,"R5SET1",1,1145],M[65486]=[null,null,L.prototype.sg,L.prototype.Jh,"R6SUPER",1,1145],M[65487]=[null,null,L.prototype.tg,L.prototype.Kh,"R6USER",1,1145],M[65504]=[null,null,L.prototype.ag,L.prototype.th,"CTRL",8,1170],M[65520]=[null,null,L.prototype.xe,L.prototype.Ce,"LSIZE",1,1170],M[65522]=[null,null,L.prototype.xe,L.prototype.Ce,"HSIZE",1,1170],M[65524]=[null,null,L.prototype.Rg,L.prototype.hi,"SYSID",1,1170],M[65526]= +[null,null,L.prototype.$f,L.prototype.sh,"ERR",1,1170],M[65528]=[null,null,L.prototype.gg,L.prototype.zh,"MBR",1,1170],M[65530]=[null,null,L.prototype.lg,L.prototype.Ch,"PIR"],M[65532]=[null,null,L.prototype.Qg,L.prototype.gi,"SLR"],M[65534]=[null,null,L.prototype.qg,L.prototype.Hh,"PSW"],M); +sb(function(){for(var a=x(document,w,"device"),b=0;b>1),this.b=new Int32Array(this.u,0,this.size>>2),Jd(this,Kd?Td:Ud);else{a=this.b=Array(this.size>>2);for(f=0;f>2),b=0;b>8,c)};h.Yf=function(a){return this.b[a>>2]>>>((a&3)<<3)&255};h.bh=function(a,b){Kb&&a&1&&this.D.Na(b,64,2);b=a>>2;a=(a&3)<<3;var c=this.b[b]>>a;return 24>a?c&65535:c&255|(this.b[b+1]&255)<<8}; +h.qh=function(a,b){var c=a>>2;a=(a&3)<<3;this.b[c]=this.b[c]&~(255<>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.fb=!0};h.Wf=function(a,b){this.f&&null!=this.K&&ae(this.f,this.K+a);return this.J(a,b)};h.Yg=function(a,b){this.f&&null!=this.K&&ae(this.f,this.K+a,2);return this.B(a,b)}; +h.oh=function(a,b,c){this.f&&null!=this.K&&be(this.f,this.K+a);this.j?this.Yb(0,b,c):this.F(a,b,c)};h.oi=function(a,b,c){this.f&&null!=this.K&&be(this.f,this.K+a,2);this.j?this.Yb(0,b,c):this.C(a,b,c)};h.Vf=function(a){return this.g[a]};h.Xf=function(a,b){a=this.g[a];this.f&&z(this.f,32)&&C(this.f,"Memory.readByte("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.Xg=function(a,b){Kb&&a&1&&this.D.Na(b,64,2);return this.w.getUint16(a,!0)}; +h.ah=function(a,b){Kb&&a&1&&this.D.Na(b,64,2);a=!Lb&&a&1?this.g[a]|this.g[a+1]<<8:this.G[a>>1];this.f&&z(this.f,32)&&C(this.f,"Memory.readWord("+K(this.f,b)+"): "+K(this.f,a),!0);return a};h.nh=function(a,b){this.g[a]=b;this.fb=!0};h.ph=function(a,b,c){this.g[a]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeByte("+K(this.f,c)+","+K(this.f,b)+")",!0)};h.ni=function(a,b,c){Kb&&a&1&&this.D.Na(c,64,4);this.w.setUint16(a,b,!0);this.fb=!0}; +h.pi=function(a,b,c){Kb&&a&1&&this.D.Na(c,64,4);!Lb&&a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.G[a>>1]=b;this.fb=!0;this.f&&z(this.f,32)&&C(this.f,"Memory.writeWord("+K(this.f,c)+","+K(this.f,b)+")",!0)};var Hd=0,id=1,Id=2,Zc=4,dd=["NONE","RAM","ROM","VID","H/W"],Gd=0,Wd=[],Vd=[I.prototype.Yf,I.prototype.qh,I.prototype.bh,I.prototype.ri],Zd=[I.prototype.Wf,I.prototype.oh,I.prototype.Yg,I.prototype.oi]; +if(Gb)var Ud=[I.prototype.Vf,I.prototype.nh,I.prototype.Xg,I.prototype.ni],Td=[I.prototype.Xf,I.prototype.ph,I.prototype.ah,I.prototype.pi];var ce;if(Gb){var de=new ArrayBuffer(2);(new DataView(de)).setUint16(0,256,!0);ce=256===(new Uint16Array(de))[0]}else ce=!1;var Kd=ce; +function ee(a,b){u.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.$c=0;this.Xc=b;this.mb=c;this.ld=Math.round(this.Xc/1E4)/100;this.xb=this.ld*this.mb;this.md=this.qc=this.Ab=this.Yc=0;this.A.V=this.A.Sc=!1;this.A.qa=a.autoStart;"string"==typeof this.A.qa&&(this.A.qa="true"==this.A.qa);this.A.Nb=!1;this.oc=this.Qb=0;this.pc=+a.csStart;this.Ob=+a.csInterval;this.Rb=+a.csStop;this.ia=[];this.Zd=this.hh.bind(this);this.nb=this.Ka=this.lb=this.b=this.la=this.Ja=this.nc=this.kb=this.Sb= +this.nd=this.wb=0;this.sa=null;y(this)}p(ee,u);h=ee.prototype;h.za=function(a,b,c,d){this.J=a;this.F=b;this.D=d;this.sa=a.i;for(a=0;a=a.Qb&&(a.Qb+=a.Ob,c=!0);0<=a.Rb&&a.Rb<=me(a)&&(a.Ob=a.Rb=-1,ie(a),a.ca(),c=!0);c&&a.v(me(a)+" cycles: checksum="+F(a.oc))}} +h.va=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.H[b]=c,!0;case "run":return this.H[b]=c,c.onclick=function(){var a;if(a=d.J)if(a=d.J,a.A.ba)a=!0;else{var b=null,c,k=ta(a.id);for(c=0;ca.wb/a.xb?b=1:d=!0;a.mb=b;b=a.ld*a.mb;if(a.xb!=b){a.xb=b;b=a.xb.toFixed(2)+"Mhz";var e=a.H.setSpeed;e&&(e.textContent=b);a.v("target speed: "+b)}c&&a.J&&qe(a.J)}xc(a,a.Ka);a.Ka=0;a.Ja=qa();a.kb=0;oe(a);return d}function md(a,b){var c=a.ia.length;a.ia.push([-1,b]);return c}function od(a,b,c,d){0<=b&&ba.ia[b][0])&&(c=a.Xc*a.mb/1E3*c|0,a.A.V&&(c+=re(a)),a.ia[b][0]=c)} +function se(a,b){for(var c=a.ia.length-1;0<=c;c--){var d=a.ia[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function te(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function re(a,b){var c=a.lb-=a.b;a.b=a.la=0;b&&(a.lb=0);return c} +h.hh=function(){if(this.A.V){this.Yc>=this.Xc&&oe(this,!0);this.Sb=0;this.nc=qa();if(this.kb){var a=this.nc-this.kb;a>this.md&&(this.Ja+=a,this.Ja>this.nc&&(this.Ja=this.nc))}try{do{var b=se(this,this.A.Nb?1:this.qc);try{this.Cc(b)}catch(e){if("number"!=typeof e)throw e;}b=re(this,!0);this.Sb+=b;this.Ka+=b;yc(this,b);wc(this,b);this.Ab-=b;if(0>=this.Ab){this.Ab+=this.qc;++this.nd>=ue&&(this.J&&H(this.J,void 0),this.nd=0);break}}while(this.A.V)}catch(e){this.ca();this.J&&this.J.stop(qa(),me(this)); +Ea(this,e.stack||e.message);return}if(this.A.V){a=setTimeout;b=this.Zd;this.kb=qa();var c=this.md;this.Sb&&(c=Math.round(c*this.Sb/this.qc));var c=c-(this.kb-this.nc),d=this.kb-this.Ja;d&&(this.wb=Math.round(this.Ka/(10*d))/100,864E5<=d&&(this.nb=0,ne(this)));if(0>c||this.wbc&&(this.Ja-=c),c=0;this.Yc+=this.Sb;this.kb+=c;a(b,c)}}}; +function uc(a,b){if(!Fa(a))if(a.A.V)a.v(a.toString()+" busy");else{ne(a);a.A.V=!0;a.A.Sc=!0;var c=a.H.run;c&&(c.textContent="Halt");a.J&&(b&&qe(a.J,!0),a.J.start(a.Ja,me(a)));a.D||a.status("Started");setTimeout(a.Zd,0)}}h.Cc=function(){return 0};h.ca=function(a){var b=!1;if(this.A.V){re(this);xc(this,this.Ka);this.Ka=0;this.A.V=!1;if(b=this.H.run)b.textContent="Run";this.J&&this.J.stop(qa(),me(this));b=!0;this.D||this.status("Stopped")}this.A.complete=a;return b};var pe=30,ue=15,fe=["power","reset"]; +function ve(a){var b=+a.model||1170;ee.call(this,a,6666667);this.ka=b;this.Td=+a.addrReset||0;this.bb=this.w=this.N=this.C=this.G=this.L=this.I=0;this.g=this.ta=this.X=[];this.M=this.B=this.Ha=this.xc=[];this.ib=this.O=this.Sd=this.yb=this.zb=this.rb=this.jb=this.P=this.uc=this.ob=this.Ga=this.S=this.vc=this.wc=this.W=this.i=0;this.Wd=[4,2,0,1];this.zc=0;this.Yd=255;1120>=this.ka?(this.be=we.bind(this),this.Lb=this.Cf,this.zc=8,this.Yd=-1,this.fe=255,this.ee=0):(this.be=xe.bind(this),this.Lb=this.Df, +this.fe=~(1792|(1140>=this.ka?2048:0))&65535,this.ee=1140e.Fb&&(e.Fb=c,c+=4)}return ee.prototype.Ca.call(this,a,b)}; +h.reset=function(){this.status("Model "+this.ka);this.A.V&&this.ca();this.C=65536;this.G=32768;this.L=65535;this.I=32768;this.w=15;this.g=[0,0,0,0,0,0,0,this.Td,-1,-2,-3,-4,-5,-6,-7,-8];this.ta=[0,0,0,0,0,0];this.X=[0,0,0,0];this.M=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.B=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Ha=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.xc=[0,0,0,0,0,0,0,0];this.N=0;this.bb=-1;this.u=this.j=this.Wc=this.U=this.Y=this.i=this.uc=0;sc(this);he(this);this.A.error=!1;ee.prototype.reset.call(this)};function sc(a){a.S=0;a.vc=0;a.wc=0;a.W=0;a.P=0;a.ob=0;a.Ga=255;a.yb=0;a.zb=0;a.rb=0;a.jb=262143;a.ib=a.g[7];a.O=0;a.R=null;a.F&&(ye(a),a.Sd=hd(a.F))} +function ye(a){a.jc=a.ad;a.kc=a.cd;a.Tc=a.dd;a.lc=a.jd;a.sc&&(a.jc=a.pe,a.kc=a.te);a.tc&&(a.Tc=a.ze,a.lc=a.Ae);a.yb?(a.Ia=65536,a.ub=a.W&16?4186112:253952,a.Fa=a.se,a.oa=a.sc?a.$g:a.Ed,a.Hb=a.tc?a.ti:a.Id,$c(a.F,a.W&16?22:18)):(a.Ia=0,a.ub=57344,a.Fa=a.Gf,a.oa=a.sc?a.Zg:a.ye,a.Hb=a.tc?a.si:a.De,$c(a.F,16))}function ud(a){var b=a.S;b&57344||(b=b&-3199|a.zb<<5|a.rb<<1);return b} +function vd(a,b){b&=-3073;if(a.S!=b){b&57344&&!(a.S&57344)&&(a.vc=a.O>>16&65535,a.wc=a.O&65535);a.S=b;a.zb=(b&96)>>5;a.rb=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.yb!=c&&(a.yb=c,ye(a))}}function wd(a){a.S&57344||(a.vc=a.O>>16&65535);a=a.vc;a&65280&&(a=(a<<8|a>>8)&65535);return a}function xd(a){a.S&57344||(a.wc=a.O&65535);return a.wc}function yd(a,b){1170>a.ka&&(b&=-49);a.W!=b&&(a.W=b,a.jb=b&16?4194303:262143,ye(a))} +function ze(a,b,c,d){a.Td=b;rc(a,b);Bd(a,0);a.F.reset();sc(a);if(c){a.g[0]=d||0;for(b=1;5>=b;b++)a.g[b]=0;a.g[6]=1024;a.A.ba?a.A.V||uc(a):a.A.qa=!0}else a.D&&a.A.ba?a.ca()||a.J.A.reset||(je(a.D),H(a.J,-1)):!1===c&&a.ca();!a.A.V&&a.sa&&a.sa.stop()}h.qe=function(){return 0}; +h.save=function(){var a=new G(this);a.set(0,[this.g,this.ta,this.X,this.M,this.B,this.Ha,this.xc,this.P,this.uc,this.ob,this.Ga,this.zb,this.rb,this.ib,this.i,this.O,this.bb,this.Ac,this.Dc]);a.set(1,[Ad(this),ud(this),wd(this),xd(this),this.W]);a.set(2,[this.nb,this.mb,this.A.qa]);a.set(3,Ae(this));a.set(4,te(this));return a.data()}; +h.restore=function(a){var b=ia(a[0]);this.g=b.next().value;this.ta=b.next().value;this.X=b.next().value;this.M=b.next().value;this.B=b.next().value;this.Ha=b.next().value;this.xc=b.next().value;this.P=b.next().value;this.uc=b.next().value;this.ob=b.next().value;this.Ga=b.next().value;this.zb=b.next().value;this.rb=b.next().value;this.ib=b.next().value;this.i=b.next().value;this.O=b.next().value;this.bb=b.next().value;this.Ac=b.next().value;this.Dc=b.next().value;b=a[1];Bd(this,b[0]);vd(this,b[1]); +this.vc=b[2];this.wc=b[3];yd(this,b[4]);b=a[2];this.nb=b[0];ne(this,b[1]);this.A.qa=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>23)),a.b-=2);a.b-=3}function rc(a,b){a.g[7]=b&65535}function pd(a,b,c,d){b={Fb:b,pb:c,message:d||0,name:Qb[b],next:null};a.mc.push(b);return b}function He(a,b){var c=a.R;if(c==b)a.R=b.next;else for(;c;){var d=c.next;if(d==b){c.next=d.next;break}c=d}a.R&&(a.i|=1)} +function nd(a,b){if(b){if(b!=a.R){var c=a.R;if(!c||c.pb<=b.pb)b.next=c,a.R=b;else{do{var d=c.next;if(!d||d.pb<=b.pb){b.next=d;c.next=b;break}c=d}while(c)}}a.i|=1;b.message&&z(a,b.message|8)&&C(a,"setIRQ(vector="+E(b.Fb)+",priority="+b.pb+")",!0,!0)}}function td(a,b){b&&(He(a,b),b.message&&z(a,b.message|8)&&C(a,"clearIRQ(vector="+E(b.Fb)+",priority="+b.pb+")",!0,!0))}function Ae(a){var b=[];for(a=a.R;a;)b.push(a.Fb),a=a.next;return b} +function Ie(a){return a.i&64?(a.ra(168,64,-6),!0):a.i&32?(a.ra(4,32,-5),!0):a.i&16?(a.ra(12,16,-7),!0):!1}function Ad(a){return a.w=a.w&63728|Ee(a)|De(a)|Ce(a)|Be(a)}function Bd(a,b){b&=a.fe;a.I=b<<12;a.L=~b&4;a.G=b<<14;a.C=b<<16;if((b^a.w)&a.ee)for(var c=a.ta.length;0<=--c;){var d=a.g[c];a.g[c]=a.ta[c];a.ta[c]=d}a.N=b>>14&3;c=a.w>>14&3;a.N!=c&&(a.X[c]=a.g[6],a.g[6]=a.X[a.N]);a.w=b;a.i&=-3;a.i|=a.R?2:1}function zd(a,b){if(b&=65024){var c=b>>9;do b+=34;while(c>>=1);a.i|=1}a.ob=b} +h.Da=function(a){this.I=this.L=a;this.G=0};h.qb=function(a,b){this.I=this.L=this.C=a;this.G=b||0};function Je(a,b){a.I=a.L=a.C=b;a.G=a.I^a.C>>1}function Ke(a,b,c,d){a.I=a.L=a.C=b;a.G=(c^d)&(d^b)} +h.ra=function(a,b,c){if(!this.pa){0>this.bb?this.bb=Ad(this):this.N||(c=-4);-4==c&&(this.i&256&&(c=-1),this.i|=256,this.P|=4,this.g[6]=a=4);if(-1!=c){this.O=a|4143316992;this.N=0;var d=this.oa(a|this.Ia),e=this.oa(a+2&65535|this.Ia);Bd(this,e&-12289|this.bb>>2&12288);Le(this,this.bb);Le(this,this.g[7]);rc(this,d)}this.b-=5;this.i&=~(b|19);this.i|=129;this.bb=-1;this.Ac=c;this.Dc=a;-1==c&&this.ca();if(-4<=c)throw a;}}; +function Me(a){var b=Ne(a),c=Ne(a);a.w&49152&&(c=c&-225|a.w&63712);rc(a,b);Bd(a,c);a.i&=-17}function Oe(a,b){var c=b>>13&31;31>c&&(b=a.W&32?a.Ha[c]+(b&8191)&4194303:b&-3932161);return b} +function Pe(a,b,c){var d=[];if(c){c=Oe(a,b);var e=b>>13&31;d.push(c);d.push(e);a.W&32&&(d.push(a.Ha[e]),d.push(b&8191))}else if(a.yb){var e=a.N<<1,f=b>>13;7>13;a.W&a.Wd[a.N]||(d&=7);e=a.B[a.N][d];f=(a.M[a.N][d]<<6)+(b&8191)&a.jb;3932160<=f&&(f=Oe(a,f));if(a.pa)return f;f>=a.Sd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& +(g|=16384));a.B[a.N][d]=e;if(f!=(4194170&a.jb)||a.N)a.zb=a.N,a.rb=d;g&&(g&57344&&(0<=a.bb&&(g|=128),a.S&57344||(g|=a.S&4096|a.zb<<5|a.rb<<1,vd(a,a.S&-61695|g&61694)),a.ra(168,64,-2)),a.S&61440||!(f<(4191360&a.jb)||f>(4194239&a.jb))||(a.S|=4096,a.S&512&&(a.i|=64)));return f}function Ne(a){var b=a.oa(a.g[6]|a.Ia);a.g[6]=a.g[6]+2&65535;return b}function Le(a,b){var c=a.g[6]-2&65535;a.g[6]=c;a.O=a.O&65535|(a.O&-65536)<<8|16121856;a.i&256||a.Lb(4,-2,c);a.Hb(c,b)} +function Qe(a,b,c,d){var e,f,g=d&8?0:a.Ia;switch(b){case 0:return a.ra(4,0,-3),0;case 1:return 6==c&&a.Lb(d,0,a.g[6]),a.b-=3,7==c?a.g[c]:a.g[c]|g;case 2:f=2;e=a.g[c];6==c&&a.Lb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.g[c];7!=c&&(e|=g);e=a.oa(e);e|=g;a.b-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.g[c]+f&65535;6==c&&a.Lb(d,f,e);7!=c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.g[c]-2&65535;7!=c&&(e|=g);e=a.oa(e)|g;a.b-=8;break;case 6:return e=a.oa(Fe(a,2)),e=e+a.g[c]&65535,6==c&&a.Lb(d, +0,e),a.b-=6,e|g;case 7:return e=a.oa(Fe(a,2)),e=e+a.g[c]&65535,e=a.oa(e|a.Ia),a.b-=10,e|g}a.g[c]=a.g[c]+f&65535;a.O=a.O&65535|(a.O&-65536)<<8|(f<<3&248|c)<<16;return e}h.Cf=function(a,b,c){!this.N&&0>=b&&c<=this.Ga&&(this.i|=32)};h.Df=function(a,b,c){this.N||(65534<=c&&(c|=-65536),a&4&&c<=this.Ga&&(c<=this.Ga-32?this.ra(4,0,-4):(this.P|=8,this.i|=32)))};h.pe=function(a){this.D&&ae(this.D,a,1);return this.ad(a)};h.te=function(a){this.D&&ae(this.D,a,2);return this.cd(a)}; +h.ze=function(a,b){this.D&&be(this.D,a,1);this.dd(a,b)};h.Ae=function(a,b){this.D&&be(this.D,a,2);this.jd(a,b)};function Dc(a,b){a.pa++;b=a.F.Bc(Bc(a,b,2));a.pa--;return b}function Re(a,b){(b?--a.tc:--a.sc)||ye(a)}h.Gf=function(a,b,c){return Qe(this,a,b,c)};h.se=function(a,b,c){return Bc(this,Qe(this,a,b,c),c)};h.ye=function(a){return this.F.Bc(this.ib=a)};h.Zg=function(a){this.D&&ae(this.D,a,2);return this.ye(a)};h.Ed=function(a){return this.F.Bc(this.ib=Bc(this,a,2))}; +h.$g=function(a){this.D&&ae(this.D,a,2);return this.Ed(a)};h.De=function(a,b){this.F.ac(this.ib=a,b)};h.si=function(a,b){this.D&&be(this.D,a,2);this.De(a,b)};h.Id=function(a,b){this.F.ac(this.ib=Bc(this,a,4),b)};h.ti=function(a,b){this.D&&be(this.D,a,2);this.Id(a,b)};function Se(a,b,c){var d=a.j=b&7;(b=a.u=(b&56)>>3)?(d=Qe(a,b,d,2),c&65536||61440!==(a.w&61440)&&(d&=65535),a.N=a.w>>12&3,c=a.oa(d|c&a.Ia),a.N=a.w>>14&3):c=6!=d||(a.w>>2&12288)===(a.w&12288)?a.g[d]:a.X[a.w>>12&3];return c} +function Te(a,b,c,d){a.O=a.O&65535|1441792;var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=Qe(a,b,e,4),c&65536||(e&=65535),a.N=a.w>>12&3,e=Bc(a,e|c&65536,4),a.N=a.w>>14&3,a.lc(e,d)):6!=e||(a.w>>2&12288)===(a.w&12288)?a.g[e]=d:a.X[a.w>>12&3]=d}function Ue(a,b){b>>=6;var c=a.Y=b&7;return(b=a.U=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c+a.zc]&a.Yd}function Ve(a,b){var c;b>>=6;var d=a.Y=b&7;(b=a.U=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d+a.zc];return c}function We(a,b){var c=a.j=b&7;b=a.u=(b&56)>>3;return Qe(a,b,c,8)} +function Xe(a,b){var c=a.j=b&7;return(b=a.u=(b&56)>>3)?a.jc(a.Fa(b,c,3)):a.g[c]&255}function Ye(a,b){var c,d=a.j=b&7;(b=a.u=(b&56)>>3)?c=a.kc(a.Fa(b,d,2)):c=a.g[d];return c}function Ze(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Wc=a.Fa(b,e,7),c=0>c?a.g[-c-1]&255:c,a.Tc(e,d.call(a,c,a.jc(e))),e&1&&a.b--):(b=a.g[e],c=0>c?a.g[-c-1]&255:c,a.g[e]=b&65280|d.call(a,c,b&255))} +function P(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,6),a.lc(e,d.call(a,0>c?a.g[-c-1]:c,a.kc(e)))):a.g[e]=d.call(a,0>c?a.g[-c-1]:c,a.g[e])}function $e(a,b,c,d,e){var f=a.j=b&7;(b=a.u=(b&56)>>3)?(d=a.Fa(b,f,5),e.call(a,(c=0>c?a.g[-c-1]&255:c)<<8),a.Tc(d,c),d&1&&a.b--):(c?(c=0>c?a.g[-c-1]&255:c,a.g[f]=a.g[f]&~d|c<<24>>24&d):a.g[f]&=~d,e.call(a,c<<8))} +function af(a,b,c,d){var e=a.j=b&7;(b=a.u=(b&56)>>3)?(e=a.Fa(b,e,4),d.call(a,c=0>c?a.g[-c-1]:c),a.lc(e,c)):(a.g[e]=c=0>c?a.g[-c-1]:c,d.call(a,c))} +h.Cc=function(a){this.A.complete=!0;var b=this.D?bf(this.D)?1:this.A.Sc?-1:0:0,c=a?this.A.Sc?0:1:-1;this.A.Sc=!1;this.lb=this.b=a;this.i=this.i&-5|(b?4:0);do{if(this.i){if(this.i&4){if(cf(this.D,this.g[7],c)){this.ca();break}++b||(this.i&=-5);c||c++}if(a=this.i&11)if(a=!1,this.i&2){var d=160,e=(this.ob&224)>>5,f=this.R&&this.R.pb>e?this.R:null;f&&(d=f.Fb,e=f.pb);e>(this.w&224)>>5?(this.i&8&&(Fe(this,2),this.i&=-9),this.ra(d,0,-10),e=!0):e=!1;e&&(f&&He(this,f),a=!0);this.R||this.ob||(this.i&=-3)}else this.i& +1&&this.i++;if(a){if(this.i&4&&cf(this.D,this.g[7],c)){this.ca();break}if(0>c)break}if(this.i&112&&Ie(this)){if(this.i&4&&cf(this.D,this.g[7],c)){this.ca();break}if(0>c)break}}this.i=this.i&15|this.w&16;a=this.O=this.g[7];f=this.oa(a);this.g[7]=a+2&65535;this.be(f)}while(0>1|b<<16;Je(this,a);return a&65535}function Ef(a,b){a=b&128|b>>1|b<<8;Je(this,a<<8);return a&255}function Ff(a,b){a=b&~a;this.Da(a);return a}function Gf(a,b){a=b&~a;this.Da(a<<8);return a} +function Hf(a,b){a|=b;this.Da(a);return a}function If(a,b){a|=b;this.Da(a<<8);return a}function Jf(a,b){a=~b|65536;this.qb(a);return a&65535}function Kf(a,b){a=~b|256;this.qb(a<<8);return a&255}function Lf(a,b){this.I=this.L=a=b-a;this.G=b&(b^a);return a&65535}function Mf(a,b){a=b-a;var c=a<<8;b<<=8;this.I=this.L=c;this.G=b&(b^c);return a&255}function Nf(a,b){this.I=this.L=a=b+a;this.G=a&(b^a);return a&65535}function Of(a,b){a=b+a;var c=a<<8;this.I=this.L=c;this.G=c&(b<<8^c);return a&255} +function Pf(a,b){a=-b;this.qb(a,a&b&32768);return a&65535}function Qf(a,b){a=-b;this.qb(a<<8,(a&b&128)<<8);return a&255}function Rf(a,b){a=b<<1|this.C>>16&1;Je(this,a);return a&65535}function Sf(a,b){a=b<<1|this.C>>16&1;Je(this,a<<8);return a&255}function Tf(a,b){a=(this.C&65536|b)>>1|b<<16;Je(this,a);return a&65535}function Uf(a,b){a=((this.C&65536)>>8|b)>>1|b<<8;Je(this,a<<8);return a&255}function Vf(a,b){var c=b-a;Ke(this,c,a,b);return c&65535} +function Wf(a,b){var c=b-a;Ke(this,c<<8,a<<8,b<<8);return c&255}function Xf(a,b){this.I=this.L=b&65280;this.G=this.C=0;return(b<<8|b>>8)&65535}function Yf(a,b){a^=b;this.Da(a);return a&65535}function Zf(a){P(this,a,Ve(this,a),df);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} +function $f(a){var b=Ye(this,a);a=a>>6&7;var c=this.g[a];c&32768&&(c|=4294901760);this.C=this.G=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.G=32768)}this.g[a]=c&65535;this.I=this.L=c;this.b-=(this.u?6:7)+b} +function ag(a){var b=Ye(this,a);a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&=63;if(b&32){b=64-b;32>b-1;this.C=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.g[a|1]=d&65535;this.I=d>>16;this.L=d>>16|d;this.b-=(this.u?6:7)+b}function bg(a){Ge(this,a,!Be(this))}function cg(a){Ge(this,a,Be(this))} +function dg(a){P(this,a,Ve(this,a),Ff);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function eg(a){Ze(this,a,Ue(this,a),Gf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function fg(a){P(this,a,Ve(this,a),Hf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function gg(a){Ze(this,a,Ue(this,a),If);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)} +function hg(a){var b=Ve(this,a);a=Ye(this,a);this.Da((0>b?this.g[-b-1]:b)&a);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function ig(a){var b=Ue(this,a);a=Xe(this,a);this.Da(((0>b?this.g[-b-1]&255:b)&a)<<8);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function jg(a){Ge(this,a,De(this))}function kg(a){Ge(this,a,!Ee(this)==!Ce(this))}function lg(a){Ge(this,a,!De(this)&&!Ee(this)==!Ce(this))}function mg(a){Ge(this,a,!Be(this)&&!De(this))} +function ng(a){Ge(this,a,De(this)||!Ee(this)!=!Ce(this))}function og(a){Ge(this,a,Be(this)||De(this))}function pg(a){Ge(this,a,!Ee(this)!=!Ce(this))}function qg(a){Ge(this,a,Ee(this))}function rg(a){Ge(this,a,!De(this))}function sg(a){Ge(this,a,!Ee(this))}function tg(){this.ra(12,0,-9)}function ug(a){Ge(this,a,!0)}function vg(a){Ge(this,a,!Ce(this))}function wg(a){Ge(this,a,Ce(this))}function xg(a){a&1&&(this.C=0);a&2&&(this.G=0);a&4&&(this.L=1);a&8&&(this.I=0);this.b-=5} +function yg(a){var b=Ve(this,a);a=Ye(this,a);var c=(b=0>b?this.g[-b-1]:b)-a;Ke(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)}function zg(a){var b=Ue(this,a);a=Xe(this,a);var c=(b=(0>b?this.g[-b-1]&255:b)<<8)-(a<<=8);Ke(this,c,a,b);this.b-=this.u?4+(this.Y&&6<=this.j?1:0):(this.U?4:3)+(7==this.j?2:0)} +function Ag(a){var b=Ye(this,a);if(b){a=a>>6&7;var c=this.g[a]<<16|this.g[a|1];this.C=this.G=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.g[a]=d&65535,this.g[a|1]=c-d*b&65535,this.L=d>>16|d,this.I=d>>16):(this.G=32768,this.L=d>>15|d,this.I=c>>16,-1===b&&65534===this.g[a]&&(this.g[a]=this.g[a|1]=1));this.b-=53}else this.L=this.I=0,this.G=32768,this.C=65536,this.b-=7}function Bg(){this.ra(24,0,-9);this.b-=20} +function Cg(){this.w&49152?(this.P|=128,this.ra(4,0,-8)):(this.sa&&1120==this.ka&&this.sa.setData(this.g[0],!0),this.D?Dg(this.D):this.ca());this.b-=7}function Eg(){this.ra(16,0,-9);this.b-=20}var Fg=[0,7,7,10,7,11,9,13];function Gg(a){this.la=this.b;rc(this,We(this,a));this.b=this.la-Fg[this.u]}var Hg=[0,14,14,17,14,18,16,20];function Ig(a){this.la=this.b;var b=We(this,a);a=a>>6&7;Le(this,this.g[a]);this.g[a]=this.g[7];rc(this,b);this.b=this.la-Hg[this.u]} +var Jg=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Kg(a){var b=Ve(this,a);this.la=this.b;af(this,a,b,this.Da);this.b=this.la-Jg[(this.U?8:0)+this.u]+(7!=this.j||this.u?0:2)}function Lg(a){var b=Ue(this,a);$e(this,a,b,65535,this.Da);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}var Mg=[7,13,13,17,14,18,17,21]; +function Ng(a){var b=Ye(this,a);a=a>>6&7;b=(b<<16>>16)*(this.g[a]<<16>>16);this.g[a]=b>>16&65535;this.g[a|1]=b&65535;b|=0;this.I=b>>16;this.L=this.I|b;this.G=0;this.C=-32768>b||32767>6;if(this.g[b]=this.g[b]-1&65535)rc(this,this.g[7]-((a&63)<<1)),this.b+=1;this.b-=6}function Ug(a){P(this,a,Ve(this,a),Vf);this.b-=this.u?9+(this.Y&&6<=this.j?1:0):(this.U?5:3)+(7==this.j?2:0)}function Vg(a){P(this,a,0,Xf);this.b-=this.u?9:3+(7==this.j?2:0)}function Wg(){this.ra(28,0,-9)} +function Xg(){this.sa&&(this.sa.Gd(this.g[7],!0),this.sa.setData(this.g[0],!0));this.i|=8;Fe(this,-2);this.b-=3}function Yg(a){P(this,a,this.g[(a>>6&7)+this.zc],Yf);this.b-=this.u?9:3+(7==this.j?2:0)}function Q(a){var b;if(b=this.D)b=this.D,z(b,1)?(C(b,"undefined opcode "+K(b,a),!0,!0),b=Dg(b)):b=!1;b||this.ra(8,0,-9)}function we(a){Zg[a>>12].call(this,a)}function $g(a){ah[a>>6&3].call(this,a)}function bh(a){ch[a>>6&3].call(this,a)}function dh(a){eh[a>>6&3].call(this,a)} +function fh(a){gh[a&15].call(this,a)}function hh(a){ih[a&15].call(this,a)}function jh(a){kh[a>>6&3].call(this,a)}function lh(a){mh[a>>6&3].call(this,a)}function nh(a){oh[a>>6&3].call(this,a)} +var Zg=[function(a){ph[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Zf,Q,function(a){qh[a>>8&15].call(this,a)},Lg,zg,ig,eg,gg,Ug,Q],ph=[function(a){rh[a>>4&15].call(this,a)},ug,rg,jg,kg,pg,lg,ng,Ig,Ig,$g,bh,dh,Q,Q,Q],ah=[function(a){af(this,a,0,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Jf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Nf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,1,Lf);this.b-=this.u?9:3+(7==this.j?2:0)}],ch=[function(a){P(this,a,0,Pf); +this.b-=this.u?11:6},function(a){P(this,a,Be(this)?1:0,df);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,Be(this)?1:0,Vf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Ye(this,a);this.qb(a);this.b-=this.u?4:3+(7==this.j?2:0)}],eh=[function(a){P(this,a,0,Tf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Rf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Df);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){P(this,a,0,Bf);this.b-=this.u?9:3+(7==this.j?2:0)}],rh= +[function(a){sh[a&15].call(this,a)},Q,Q,Q,Gg,Gg,Gg,Gg,Qg,Q,fh,hh,Vg,Vg,Vg,Vg],sh=[Cg,Xg,Rg,tg,Eg,Pg,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q],gh=[Og,function(){this.C=0;this.b-=5},function(){this.G=0;this.b-=5},xg,function(){this.L=1;this.b-=5},xg,xg,xg,function(){this.I=0;this.b-=5},xg,xg,xg,xg,xg,xg,xg],ih=[Og,function(){this.C=65536;this.b-=5},function(){this.G=32768;this.b-=5},Sg,function(){this.L=0;this.b-=5},Sg,Sg,Sg,function(){this.I=32768;this.b-=5},Sg,Sg,Sg,Sg,Sg,Sg,Sg],qh=[sg,qg,mg,og,vg,wg,bg,cg,Bg,Wg,jh,lh, +nh,Q,Q,Q],kh=[function(a){$e(this,a,0,255,this.qb);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ze(this,a,0,Kf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ze(this,a,1,Of);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ze(this,a,1,Mf);this.b-=this.u?9:3+(7==this.j?2:0)}],mh=[function(a){Ze(this,a,0,Qf);this.b-=this.u?11:6},function(a){Ze(this,a,Be(this)?1:0,ef);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ze(this,a,Be(this)?1:0,Wf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){a=Xe(this, +a);this.qb(a<<8);this.b-=this.u?4:3+(7==this.j?2:0)}],oh=[function(a){Ze(this,a,0,Uf);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ze(this,a,0,Sf);this.b-=this.u?9:3+(7==this.j?2:0)},function(a){Ze(this,a,0,Ef);this.b-=this.u?9+(this.Wc&1):3+(7==this.j?2:0)},function(a){Ze(this,a,0,Cf);this.b-=this.u?9:3+(7==this.j?2:0)}];function xe(a){th[a>>12].call(this,a)} +var th=[function(a){uh[a>>8&15].call(this,a)},Kg,yg,hg,dg,fg,Zf,function(a){vh[a>>8&15].call(this,a)},function(a){wh[a>>8&15].call(this,a)},Lg,zg,ig,eg,gg,Ug,Q],uh=[function(a){xh[a>>4&15].call(this,a)},ug,rg,jg,kg,pg,lg,ng,Ig,Ig,$g,bh,dh,function(a){yh[a>>6&3].call(this,a)},Q,Q],yh=[function(a){a=this.g[7]+((a&63)<<1)&65535;var b=this.oa(a|this.Ia);rc(this,this.g[5]);this.g[6]=a+2&65535;this.g[5]=b;this.b-=8},function(a){a=Se(this,a,0);this.Da(a);Le(this,a);this.b-=11},function(a){var b=Ne(this); +this.la=this.b;this.Da(b);Te(this,a,0,b);this.b=this.la-Mg[this.u]},function(a){af(this,a,Ee(this)?65535:0,this.Da);this.b-=this.u?9:3+(7==this.j?2:0)}],xh=[function(a){zh[a&15].call(this,a)},Q,Q,Q,Gg,Gg,Gg,Gg,Qg,function(a){!(a&8)||1145>this.ka?Q.call(this,a):(this.w&49152||(this.w=this.w&-225|(a&7)<<5,this.i|=1,this.i&=-3),this.b-=5)},fh,hh,Vg,Vg,Vg,Vg],zh=[Cg,Xg,function(){Me(this);this.i|=this.w&16;this.b-=13},tg,Eg,Pg,Rg,function(a){Q.call(this,a)},Q,Q,Q,Q,Q,Q,Q,Q],vh=[Ng,Ng,Ag,Ag,$f,$f,ag,ag, +Yg,Yg,Q,Q,Q,Q,Tg,Tg],wh=[sg,qg,mg,og,vg,wg,bg,cg,Bg,Wg,jh,lh,nh,function(a){1145>this.ka?Q.call(this,a):Ah[a>>6&3].call(this,a)},Q,Q],Ah=[function(a){Q.call(this,a)},function(a){a=Se(this,a,65536);this.Da(a);Le(this,a);this.b-=11},function(a){var b=Ne(this);this.la=this.b;this.Da(b);Te(this,a,65536,b);this.b=this.la-Mg[this.u]},function(a){Q.call(this,a)}]; +function Bh(a){u.call(this,"ROM",a,128);this.ga=this.g=null;this.u=+a.addr;this.b=+a.size;this.w=!1;this.i=a.alias;"string"==typeof this.i&&(this.i=eval(this.i));this.j=a.file;this.B=Pa(this.j);if(this.j){a=this.j;var b=Qa(this.B);"json"!=b&&"hex"!=b&&(a=eb()+"/api/v1/dump?file="+this.j+"&format=bytes&decimal=true");var c=this;cb(a,null,!0,function(a,b,f){f?(c.T("Unable to load ROM resource (error "+f+": "+a+")"),c.j=null):(na(c.vb,a,b),(a=db(a,b))?(c.g=a.Z,c.ga=a.ga):c.j=null);Ch(c)})}}p(Bh,u); +h=Bh.prototype;h.za=function(a,b,c,d){this.F=b;this.f=c;this.D=d;Ch(this)};h.Ca=function(){this.ga&&(this.D&&Dh(this.D,this.id,this.u,this.b,this.ga),delete this.ga);return!0};h.Ba=function(){return!0}; +function Ch(a){if(!Ga(a)){if(a.j){if(!a.g||!a.F)return;a.b||(a.b=a.g.length);if(a.g.length!=a.b)Ea(a,"ROM size ("+F(a.g.length,8,!0)+") does not match specified size ("+F(a.b,8,!0)+")");else{var b;a:{b=a.u;if(57344<=b&&b<57344+Hc){var c={},c=(c[b]=[Bh.prototype.Jg,Bh.prototype.$h,null,null,null,a.b>>1],c);if(dc(a.F,a,c)){a.status("Added "+a.b+"-byte ROM at "+E(b));b=a.w=!0;break a}}else if(Yc(a.F,b,a.b,Id)){for(c=0;c>>f.g;0>>=f.g;0>>a.g;0=b.length){C(a,"invalid block at offset "+Oa(n),4096);break}for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,m=m+((q&255)+(q>>8)+(t&255)+(t>>8)),r=l,D=q-=6;0=b.length){C(a,"insufficient data for block at offset "+Oa(n),4096); +break}m+=b[l++]&255;if(m&255){C(a,"invalid checksum ("+F(m,2,!0)+") for block at offset "+Oa(n),4096);break}if(D)for(C(a,"loading "+Oa(D)+" bytes at "+Oa(t)+"-"+Oa(t+D),4096);D--;)gd(a.F,t++,b[r++]&255);else t&1?g=!0:null==d&&(d=t),null!=d&&C(a,"starting address: "+Oa(d),4096);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e=la.Jd&&c<=la.xf&&(b=c-(la.Jd-la.Fe));b&&(a.preventDefault&&a.preventDefault(),d.Oc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.He&&(b=la.Ge);d.Oc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.Oc(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1}; +h.za=function(a,b,c,d){this.J=a;this.F=b;this.f=c;this.D=d;var e=this;this.P=pd(this.f,this.M?-1:48,4,1048576);this.R=md(this.f,function(){var a;a=-1;e.i.length&&(a=e.i.shift()&255,C(e,"receiveByte("+F(a,2,!0)+")"),e.L&&97<=a&&122>a&&(a-=32),od(e.f,e.R,1E3/Math.round(e.S/10)));0<=a&&(e.C=a,e.b&128?e.C|=49152:e.b|=128,e.b&64&&nd(c,e.P))});this.N=pd(this.f,this.M?-1:52,4,1048576);this.X=md(this.f,function(){e.g|=128;e.g&64&&nd(c,e.N)});dc(b,this,Kh,this.M?64832+8*(this.M-1)-65392:0);fc(b,this.reset.bind(this)); +y(this)};h.ue=function(a){if(!this.j){var b=ge(this.J,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Za(c[0]);if(d!=this.Mb)return;c=Za(c[1]);if(this.j=ua(c)){var e=this.j.exports;if(e){var f=e.connect;f&&f.call(this.j,this.I);if(this.G=e.receiveData){this.I=a;this.O=e.receiveStatus;this.status("Connected "+this.vb+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +h.Ca=function(a,b){if(!b)if(this.ue(this.I),!a)this.reset();else if(!this.restore(a))return!1;return!0};h.Ba=function(a){return a?this.save():!0};h.reset=function(){Lh(this)};h.save=function(){var a=new G(this);a.set(0,[this.C,this.b,this.g,this.i]);return a.data()};h.restore=function(a){return Lh(this,a[0])};function Lh(a,b){b||(b=[0,8192,128,a.i]);b=ia(b);a.C=b.next().value;a.b=b.next().value;a.g=b.next().value;a.i=b.next().value;return!0} +h.Oc=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.W||8,c=a-this.B%a,this.W&&(b=Ya("",c)));this.U&&!this.B&&c&&(b=String.fromCharCode(this.U)+b);this.u.value+=b;this.u.scrollTop=this.u.scrollHeight;this.B+=c}}else if(null!=this.w){if(10==a||1024<=this.w.length)this.v(this.w), +this.w="";10!=a&&(this.w+=String.fromCharCode(a))}od(this.f,this.X,1E3/Math.round(this.Y/10));this.g&=-129};var Jh="buffer",Mh={},Kh=(Mh[65392]=[null,null,Ih.prototype.wg,Ih.prototype.Nh,"RCSR"],Mh[65394]=[null,null,Ih.prototype.vg,Ih.prototype.Mh,"RBUF"],Mh[65396]=[null,null,Ih.prototype.eh,Ih.prototype.vi,"XCSR"],Mh[65398]=[null,null,Ih.prototype.dh,Ih.prototype.ui,"XBUF"],Mh);sb(function(){for(var a=x(document,w,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.H[b]=c,!0;case "readTape":e=Qh;case "loadTape":return e||(e=Rh),this.H[b]=c,c.onclick= +function(){var a=d.H.listTapes;a&&Sh(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Sh(d,Pa(b,!0),b,Rh,a)}return!1};return!0;case Th:return this.H[b]=c,!0}return!1}; +h.za=function(a,b,c,d){this.J=a;this.F=b;this.f=c;this.D=d;this.I=Uh(a);var e=this;if(a=Nh(this,ge(this.J,"autoMount")))for(var f in a)"PTR"==f&&(this.N[f]=a[f]);this.G=pd(this.f,56,4,4096);this.S=md(this.f,function(){1!=(e.b&32769)||e.b&128||(e.ic.indexOf("/api/v1/dump")&&(e=Qa(c),f="json"==e||"gz"==e?encodeURI(c):eb()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!cb(f,null,!0,function(e,f,g){var k=0>g&&!!a.J&&!a.J.A.ba;g?a.T('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.vb,e,f),(e=db(e,f))&&ei(a,b,c,d, +e.Z,e.ya,e.xa));a.A.eb=!1;a.g&&(a.g--,a.g||y(a));bi(a)})}function Xh(a,b,c,d){if((a=a.H.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.b=Array(a.aa);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Qa(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Ra(c,"/")&&(d="dir"),f=eb()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.zd?"":e)+"&format=json"));return!!cb(f, +null,!0,function(b,c,d){mi(a,b,c,d)})} +function mi(a,b,c,d){var e=null,f=0>d&&!!a.J&&!a.J.A.ba;a.j=!1;if(d)a.controller.T('Unable to load disk "'+a.Xa+'" (error '+d+": "+b+")",f);else{na(a.controller.vb,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ +c+")");if(k.length)if(1==k.length)v(k[0]);else{a.aa=k.length;a.ja=k[0].length;a.ea=k[0][0].length;var l=k[0][0][0];a.ua=l&&l.length||512;for(d=c=0;d>2,n=l.pattern;void 0===n&&(n=l.pattern=0);var q=l.data;if(void 0===q){var t=l.bytes;if(void 0!==t&&t.length){for(var r=m<<2,D=t.length;D>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.j)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.La?f=a.Va+a.La&&(a.La+=f-(a.Va+a.La)+1):(a.Va=f,a.La=1);d[f]=d[f]&~(255<g)break;e|=g<=this.b.length||l>=this.b[k].length||m>=this.b[k][l].length){c="sector (CHS="+k+":"+l+":"+m+") out of range ("+ +b+" changes applied)";b=-1;break}if(this.j){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.b[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.T("Unable to restore disk '"+this.Xa+": "+c);return b}; +h.toJSON=function(){var a;a=0;for(var b;b=oi(this,a++);)qi(b);a=JSON.stringify(this.b,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; +function qi(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var ii=0;function ri(a,b,c,d,e,f){u.call(this,a,b,c);this.N=si(this,b.autoMount);this.M=0;this.R=d;this.S=e;this.U=f;this.P=d.Zc;this.g=Array(this.P);this.O=!mb("Mobi")&&window&&"FileReader"in window;this.B=[];this.Qa=null;this.exports={bootDisk:this.le,loadDisk:this.Bd,selectDrive:this.ih,wait:this.mh}}p(ri,u); +function si(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){v(a.type+" auto-mount error: "+c.message+" ("+b+")"),b=null}return b||{}}h=ri.prototype; +h.va=function(a,b,c){var d=this;switch(b){case "listDisks":return this.H[b]=c,c.onchange=function(){ti(d)},!0;case "descDisk":case "listDrives":return this.H[b]=c,c.onchange=function(){var a=Ka(c.value,10);null!=a&&ui(d,a)},!0;case "loadDisk":return this.H[b]=c,c.onclick=function(){d.Bd()},!0;case "bootDisk":return this.H[b]=c,c.onclick=function(){d.le()},!0;case "saveDisk":if(!this.O){c.parentNode.removeChild(c);break}this.H[b]=c;c.onclick=function(){var a=d.H.listDrives;if(a&&a.options&&d.g)if(a= +d.g[Ka(a.value,10)||0])if(a=a.da){var b;b="";for(var c=0,k;k=oi(a,c++);)for(var l=0,m=k.length;lg||9d||d>=this.g.length)return this.T("Unable to load the selected drive"),!1;if(!b)return Ui(this,d),!0;if(b==Ri)return this.T('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Si){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Pa(b);this.status("Attempting to load "+b+' as "'+ +a+'"')}Yi(this,d,a,b,!1,c);return!0};h.le=function(){var a,b=this.H.listDrives,b=b&&Ka(b.value,10);if(null==b||0>b||b>=this.g.length||!(a=this.g[b]))return this.T("Unable to boot the selected drive"),!1;if(!a.da)return this.T("Load a disk into the drive first"),!1;ze(this.f,0,!0,b);return(a=this.Ub(a,a.If,a.Jf,a.Kf,a.Bf,0,2))?(this.T("Unable to read the boot sector ("+a+")"),!1):!0}; +function Yi(a,b,c,d,e,f){var g=-1,k=a.g[b];k.Oa.toLowerCase()!=d.toLowerCase()&&(g++,Ui(a,b,!0),k.Mc?a.T(a.type+" busy"):(k.Mc=!0,e&&(k.yd=!0,a.M++,z(a)&&C(a,"auto-loading disk: "+c)),k.Pb=!!f,li(new hi(a,k,"preload"),c,d,f,a.oe)&&g++));return g} +h.oe=function(a,b,c,d,e){a.Mc=!1;b&&(b.aa>a.aa||b.ja>a.ja)&&(this.T('Disk "'+c+'" too large for drive '+(this.g[a.Tb].Qc||"---")),b=null);b?(a.da=b,a.Xa=c,a.Oa=d,this.we(a.Tb),Zi(this,c,d,b),this.T('Loaded disk "'+c+'" in drive '+(this.g[a.Tb].Qc||"---"),a.yd||e),this.J&&qe(this.J)):a.Pb=!1;a.yd&&(a.yd=!1,--this.M||y(this));ui(this,a.Tb);a.ic&&(a.ic(),a.ic=null)}; +function Oi(a,b,c,d){if((a=a.H.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}h.mh=function(a){for(var b=0;b=a.aa){m=S.Ec;break}n=a.seek(b,c,d+1);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}var t,r;if(0>(t=a.read(n,q++))||0>(r=a.read(n,q++))){m=S.Fc;break}if(!k&&(Ac(this.F,Oe(this.f,f),t|r<<8),ld(this.F))){m=S.ec;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Uc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.da;var n=null,q;a||(m=S.Ud,e=0);for(;e;){var t=Cc(this.F,Oe(this.f,f));if(ld(this.F)){m=S.ec;break}if(!n){if(b>=a.aa){m=S.Ec;break}n=a.seek(b,c,d+1,!0);if(!n){m=S.ce;break}q=0;++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b))}if(k){var r,D;if(0>(r=a.read(n,q++))||0>(D=a.read(n,q++))){m=S.Fc;break}if(t!=(r|D<<8)){m=S.ge;break}}else if(!a.write(n,q++,t&255)||!a.write(n,q++,t>>8)){m=S.Fc;break}q>=a.ua&&(n=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.Ze=function(a,b,c,d,e,f){this.u=f&65535;this.b=this.b&~R.Jb|f>>16-R.ma.Jb&R.Jb;this.w=65536-e&65535;this.j=this.j&~cj.rd|d&cj.rd;this.i|=a;dj(this);return!0};function dj(a){a.b&=~R.hb;a.i&&(a.i|=S.Je,a.b|=R.hb,a.i&S.ed&&(a.b|=R.ed),z(a)&&C(a,a.type+": ERROR: "+E(a.i)))}h.Bg=function(){return this.G};h.Sh=function(){};h.Cg=function(){return this.i};h.Th=function(){};h.yg=function(){return this.b&R.fc}; +h.Ph=function(a){this.b=this.b&~R.Sa|a&R.Sa;if(this.b&R.dc){a=!0;var b,c,d="",e=(this.j&cj.sb)>>cj.ma.sb,f=this.g[e],g,k,l,m,n,q;this.b&=~(R.Za|R.sd);this.i&=~S.qf;switch(c=this.b&R.wa){case ej.Ee:z(this)&&C(this,this.type+": CRESET("+e+")",!0);this.i=this.j=0;this.b=R.Za;break;case ej.Ue:d="RCHK";case ej.tb:d||(d="READ"),b=this.Ub;case ej.vd:d||(d="WCHK");case ej.hc:d||(d="WRITE");b||(b=this.Uc);g=(this.j&cj.bc)>>cj.ma.bc;k=(this.j&cj.hd)>>cj.ma.hd;l=this.j&cj.rd;m=65536-this.w&65535;n=(this.b&R.Jb)<< +16-R.ma.Jb|this.u;q=this.b&R.Qe?0:2;z(this)&&C(this,this.type+": "+d+"("+g+":"+k+":"+l+") "+E(n)+"--"+E(n+(m<<1)),!0,!0);if(g>=f.aa){this.i|=S.Ec;break}if(l>=f.ea){this.i|=S.Fc;break}a=b.call(this,f,g,k,l,m,n,q,c>=ej.vd,this.Ze.bind(this));break;case ej.Kc:g=(this.j&cj.bc)>>cj.ma.bc;z(this)&&C(this,this.type+": SEEK("+g+")",!0);g(n=a.read(k,m++))||0>(q=a.read(k,m++))){g=hj.$a;break}Ac(this.F,Oe(this.f,f),n|q<<8);if(ld(this.F)){g=hj.ec;break}f+=2;e--;if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.aa)))){g=hj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.Uc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.da;k=null;var m;a||(g=hj.$a,e=0);for(;e;){var n=Cc(this.F,Oe(this.f,f));if(ld(this.F)){g=hj.ec;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=hj.$a;break}m=0}if(!a.write(k,m++,n&255)||!a.write(k,m++,n>>8)){g=hj.$a;break}if(m>=a.ua&&(k=null,++d>=a.ea&&(d=0,++c>=a.ja&&(c=0,++b>=a.aa)))){g=hj.$a;break}}return l?l(g,b,c,d,e,f):g}; +h.df=function(a,b,c,d,e,f){this.C=f&65535;this.b=this.b&~U.Ya|f>>16-U.ma.Ya&U.Ya;this.u=f>>16&ij.ab;this.j=this.i=b<>U.ma.Ya;if(!(this.b&U.Za)){a=!0;var b,c="",d=this.g[(this.b&U.sb)>>U.ma.sb],e=d.da,f,g,k;this.b&=~U.Ea;switch(this.b&U.wa){case kj.uf:this.w&lj.Rd&&(this.b&=U.Ea|U.wa|U.Ya);this.w=d.status|this.j&jj.Jc|(e&&512==e.aa?lj.Ne:0);break;case kj.Kc:(this.i&jj.Me)==jj.rf&&(b=this.i&jj.gc,c=(this.i&jj.tf)<<2,this.j=this.i&jj.sf?this.j+b:this.j-b,this.i=this.j=this.j&jj.gc|c);break;case kj.Ye:this.w=this.j;break;case kj.Ve:c="READ",b=this.Ub; +case kj.wf:c||(c="WRITE"),b||(b=this.Uc),f=this.i>>jj.ma.gc,g=this.i&jj.Jc?1:0,k=this.i&jj.ae,!e||f>=e.aa||k>=e.ea?this.b=this.b|hj.$a|U.hb:(a=65536-this.w&65535,e=(this.u&ij.ab)<<16|this.C,z(this)&&C(this,this.type+": "+c+"("+f+":"+g+":"+k+") "+E(e)+"--"+E(e+(a<<1)),!0,!0),a=b.call(this,d,f,g,k,a,e,2,!1,this.df.bind(this)))}a&&(this.b=this.b|U.Ea|U.Za,this.b&U.Ib&&nd(this.f,this.Qa))}};h.Eg=function(){return this.C};h.Vh=function(a){this.C=a&mj.Sa};h.Hg=function(){return this.i}; +h.Yh=function(a){this.i=a};h.Ig=function(){return this.w};h.Zh=function(a){this.w=a};h.Fg=function(){return this.u};h.Wh=function(a){this.u=a&ij.ab;this.b=this.b&~U.Ya|(this.u&3)<=m.aa){k=rj.Se;break}n=m.seek(b,c,d+1);if(!n){k=rj.pd;break}q=0;++d>=m.ea&&(d=0,++c>=m.ja&&(c=0,++b))}var t;if(0>(a=m.read(n,q++))||0>(t=m.read(n,q++))){k=rj.od;break}Ac(this.F,Oe(this.f,f),a|t<<8);q>=m.ua&&(n=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +function pj(a){var b=0,c=a.b&W.td?1:0,d=a.g[c],d=d&&d.da,e=a.I&sj.ab,f=a.G&tj.ab;a.i&=~(uj.Md|uj.Xd|uj.cc|uj.Ea);if(d)if(a.i|=uj.Ea,z(a)&&C(a,a.type+".readSector("+e+":0:"+f+")",!0,!0),c=d.seek(e,0,f,!0)){e=0;for(f=a.w.length;eg){b=rj.od;break}a.w[e++]=g}c.Ef&&(a.i|=uj.cc)}else b=rj.pd;else b=c?rj.gd:rj.fd;qj(a,b)} +h.Kg=function(a,b){a=this.b;if(!b)switch(a&=W.fc,this.j){case V.bd:case V.EMPTY:this.uthis.u&&(this.b|=W.cb)}return a}; +h.ai=function(a){this.b=this.b&~W.Sa|a&W.Sa;if(this.b&W.INIT)this.Cb();else if(this.b&W.dc&&this.j==V.Kb)switch(this.j=this.b&W.wa,this.b&=~(W.dc|W.cb|W.DONE|W.hb),td(this.f,this.Qa),z(this)&&C(this,this.type+".processCommand("+vj[this.j>>1]+")",!0,!0),this.j){case V.bd:case V.EMPTY:case V.tb:case V.hc:case V.Lc:this.u=0;break;case V.Xe:a=this.g[this.b&W.td?1:0];this.i&=~uj.Ea;a&&a.da&&(this.i|=uj.Ea);this.C=this.i;qj(this);break;case V.We:this.C=this.L,qj(this)}else this.b&W.Ib?this.b&W.DONE&&nd(this.f, +this.Qa):td(this.f,this.Qa)};h.Lg=function(a,b){if(!b)switch(this.j){case V.EMPTY:this.b&W.cb&&(this.b&=~W.cb,this.C=this.w[this.u]&255,z(this)&&C(this,this.type+".readByte("+this.u+"): "+F(this.C,2,!0),!0,!0),++this.u>=this.w.length&&qj(this))}return this.C}; +h.bi=function(a){switch(this.j){case V.bd:this.b&W.cb&&(this.b&=~W.cb,this.w[this.u]=a&255,z(this)&&C(this,this.type+".writeByte("+this.u+","+F(a,2,!0)+")",!0,!0),++this.u>=this.w.length&&qj(this));break;case V.tb:case V.hc:case V.Lc:if(this.b&W.cb)switch(this.b&=~W.cb,this.u++){case 0:this.G=a;break;case 1:if(this.I=a,this.j==V.tb)pj(this);else{var b=this.j==V.Lc,c=0,d=this.b&W.td?1:0,e=this.g[d],e=e&&e.da,f=this.I&sj.ab,g=this.G&tj.ab;this.i&=~(uj.Md|uj.Xd|uj.cc|uj.Ea);if(e)if(this.i|=uj.Ea,z(this)&& +C(this,this.type+".writeSector("+f+":0:"+g+")",!0,!0),d=e.seek(f,0,g,!0))for(b&&(d.Ef=!0),b=0,f=this.w.length;ba.u&&a.j.length&&(a.u=0);if(0>a.u||b!=a.j[a.u])a.j.splice(0,0,b),a.u=0;a.u--}else a.O?b="end":b=a.j[a.u+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Za(b.substring(c,f))),c=f+1}}return a} +function zj(a,b,c){for(c=c||-1;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop(),f=a.pop();switch(d){case "*":d=f*e;break;case "/":if(!e)return!1;d=f/e;break;case "%":if(!e)return!1;d=f%e;break;case "+":d=f+e;break;case "-":d=f-e;break;case "<<":d=f<>":d=f>>e;break;case ">>>":d=f>>>e;break;case "<":d=f":d=f>e?1:0;break;case ">=":d=f>=e?1:0;break;case "==":d=f==e?1:0;break;case "!=":d=f!=e?1:0;break;case "&":d=f&e;break; +case "^":d=f^e;break;case "|":d=f|e;break;case "&&":d=f&&e?1:0;break;case "||":d=f||e?1:0;break;default:return!1}a.push(d|0)}return!0} +function Aj(a,b,c){var d;if(b){b=Bj(a,b);for(var e=0,f=!1,g=b,k=[],l=[],m=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=8;d=F(c,0,!0)+" "+c+". "+E(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.v((null!=b?b+": ":"")+d);return e} +function Fj(a,b){if(b)return Ej(a,b,a.S[b]);var c=0;for(b in a.S)Ej(a,b,a.S[b]),c++;return 0>2:0)}0>c?c=a.replace(/^0+([0-9A-F]+)$/i,"$1"):c=a;return c}var Dj={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9}; +function Gj(a){xj.call(this,a);this.Ga=!1;this.ia=!0;this.G=X();this.Fa=X();this.N=X();this.B=[];this.b=this.L=this.C=[];Hj(this);this.P=this.Y=0;this.i=[];this.pa=void 0;Ij(this);this.D=this;this.ka={};this.ha=this.ke=0;this.R=null;this.M=[];Jj(this,a.messages);this.ta=a.commands;this.Ja=Kj;this.W=[];this.I=0;this.Ka=this.sa=null;this.w=this.Ia=this.Ha=this.X=this.la=0;this.g=this.U=null;var b=this;window?void 0===window[w]&&(window[w]=function(a){return le(b,a)}):void 0===global[w]&&(global[w]= +function(a){return le(b,a)})}p(Gj,xj);function Lj(a){a=a&&a.K;null==a&&(a=-1);return a}function X(a,b,c){return{K:void 0===a?null:a,Ma:void 0===b?!1:b,Ua:!1,Aa:c}}h=Gj.prototype;h.Gd=function(a,b){a.K=b;a.Ua=!1;a.Aa=void 0;return a};function Mj(a){return[a.K,a.Ma,a.Aa,a.Ua,a.Pc]}function Nj(a,b){var c=X(b[0],b[1],b[2]);c.Ua=b[3];b[4]&&(c.he=yj(a,c.Pc=b[4]));return c} +h.za=function(a,b,c,d){this.F=b;this.J=a;this.f=c;this.g=a.i;(a=ge(a,"messages"))&&Jj(this,a);1140>this.f.ka&&(this.W=this.W.concat(Oj));1145>this.f.ka&&(this.W=this.W.concat(Pj));rd(this,16,function(a){a:{var b=d.F.b,c=a[0],e=a=0,l=b.length;if(c){a=Lj(Qj(d,c));if(-1===a){d.v("invalid address: "+c);break a}e=a>>>d.F.g;l=1}d.v("blockid physical blockaddr used size type");d.v("-------- --------- --------- ------ ------ ----");for(var c=-1,m=0;l--;){var n=b[e];n.type==c?m++||d.v("..."): +(c=n.type,m=dd[c],n&&d.v(F(n.id,8)+" %"+F(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a)b=this.f.g[a];else if(16>a)b=this.f.ta[a-8];else if(20>a)b=this.f.X[a-16];else{var c=this.f,d=this.g;switch(a){case Yj:b=Ad(this.f);break;case Zj:b=c.ob;break;case ak:b=c.P;break;case bk:b=c.Ga&65280;break;case ck:b=ud(c);break;case dk:b=wd(c);break;case ek:b=xd(c);break;case fk:b=c.W;break;case Wj:d&&(b=d.fa);break;case gk:d&&(b=d.Eb);break;case hk:d&&(b=d.Wa)}}return b}; +h.message=function(a,b){b&&(a+=" @"+Tj(this,X(this.f.O&65535)));if(!this.R||a!=this.R)if(this.R=a,this.ha&1073741824)this.M.push(a);else{var c;if(this.ha&-2147483648&&this.f&&(c=this.f.A.V)||Ha(this,!0))this.ca(),c&&(a+=" (cpu halted)");this.v(a);this.f&&(a=this.f,re(a),a.Ab=0,a.J&&H(a.J,void 0))}}; +function Ij(a){var b;if(!bf(a))a.i&&a.i.length&&a.v("instruction history buffer freed"),a.P=0,a.i=[];else if(!a.i||!a.i.length){a.i=Array(ik);for(b=0;b>8;a.v("trapped to "+K(a,c&255,8)+" ("+(0>d?Mb[-d]:K(a,d))+")")}a.G=X(a.f.g[7]);b&&1!=a.I?mk(a):nk(a)}}function kk(a,b){var c;(c=!a.f||!Ga(a.f))||(c=a.f,c.A.ba?c=!0:(c.v(c.toString()+" not powered"),c=!1),c=!c);return c||a.f.A.V?(b||a.v("cpu busy or unavailable, command ignored"),!1):!Fa(a.f)}h.Ca=function(a,b){return!b&&(this.reset(!0),a)?this.restore(a):!0}; +h.Ba=function(a,b){b&&this.v(a?"suspending":"shutting down");return a?this.save():!0};h.reset=function(a){Ij(this);this.X=0;this.R=null;this.w=0;this.G=X(this.f.g[7]);this.A.V=!1;ok(this);a||je(this)};h.save=function(){var a=new G(this);a.set(0,Mj(this.G));a.set(1,Mj(this.N));a.set(2,[this.j,this.O,this.ha]);a.set(3,this.B);return a.data()}; +h.restore=function(a){var b=0;void 0!==a[2]&&(this.G=Nj(this,a[b++]),this.N=Nj(this,a[b++]),this.j=a[b][0],"string"==typeof this.j&&(this.j=[this.j]),this.O=a[b][1],this.ha|=a[b][2]);a[3]&&(this.B=a[3]);return!0};h.start=function(a,b){this.I||this.v("running");this.A.V=!0;this.Ha=a;this.Ia=b}; +h.stop=function(a,b){if(this.A.V){this.A.V=!1;this.w=b-this.Ia;if(!this.I){b="stopped";if(this.w){a-=this.Ha;var c=0d&&(d=Dc(a.f,b)),65535!=(d&65535)&&(a.Gd(a.i[a.P],b),++a.P==a.i.length&&(a.P=0)));return!1}function Dg(a){var b=a.f;if(b.A.V)throw rc(b,a.f.O&65535),a.ca(),-1;return!1}function ae(a,b,c){pk(a,b,c||1,a.L)&&a.ca(!1)}function be(a,b,c){pk(a,b,c||1,a.C)&&a.ca(!1)} +function Hj(a){var b,c,d;a.b=["bp"];if(a.L)for(b=1;b>>c.g],!1)):Re(a.f,!1);a.L=["br"];if(a.C)for(b=1;b>>c.g],!0)):Re(a.f,!0);a.C=["bw"];a.la=0;a.Y=0} +h.Bb=function(a,b,c){var d=!0;c||qk(this,a,b,!1,!0);if(a!=this.b){var e=Lj(b);if(-1===e)this.v("invalid address: "+Tj(this,b)),d=!1;else{var f=a==this.C;65535>>g.g].Bb(e&g.i,f)}else e=this.f,(f?e.tc++:e.sc++)||ye(e)}}d&&(a.push(b),c?b.Ua=!0:(rk(this,a,a.length-1,"set"),Ij(this)));return d}; +function qk(a,b,c,d,e){var f=!1;c=Lj(c);for(var g=1;g>>d.g],b)):Re(a.f,b));k.Ua||Ij(a);break}}return f}function sk(a,b){for(var c=1;c>23)&65535,A=K(r,t);else if(B==yk)t=t.K-((f&63)<<1)&65535,A=K(r,t);else if(B==zk)A=K(r,f&7,3);else if(B==Ak)A=K(r,f&63,6);else if(B==Bk)A=K(r,f&255,8);else if(B=f&D,D&Ck&&(B>>=6,D>>=6),D&Z){var D=null,J=B& +Dk;switch(B&Ek){case 0:A=Vj(r,J);break;case 8:A="@"+Vj(r,J);D=Fk(r,r.f.g[J]);break;case 16:7>J?A="("+Vj(r,J)+")+":(B=r.Ra(t,2),A="#"+K(r,B,-1));break;case 24:7>J?A="@("+Vj(r,J)+")+":(B=r.Ra(t,2),A="@#"+K(r,B,-1),D=Fk(r,B));break;case 32:A="-("+Vj(r,J)+")";break;case 40:A="@-("+Vj(r,J)+")";break;case 48:B=r.Ra(t,2);A=K(r,B,-1)+"("+Vj(r,J)+")";7==J&&(A=K(r,B=B+t.K&65535),D=Fk(r,B));break;case 56:B=r.Ra(t,2),A="@"+K(r,B)+"("+Vj(r,J)+")",7==J&&(A="@"+K(r,B=B+t.K&65535),D=Fk(r,Dc(r.f,B)))}D&&(A=[A,D])}r= +A;if(!r||!r.length){k="INVALID";break}"string"!=typeof r&&(m=r[1],r=r[0]);0=a.f.ub&&b=c.B&&(b=c.Pa[b&kd])&&(a=b[4]);return a}function Gk(a,b){switch(b){case "N":a=Ee(a.f);break;case "Z":a=De(a.f);break;case "V":a=Ce(a.f);break;case "C":a=Be(a.f);break;default:a=0}return b.charAt(0)+(a?"1":"0")+" "}function Hk(a,b){var c=Vj(a,b);c&&(c+="="+K(a,a.Ad(b))+" ");return c} +function Ik(a,b){var c,d="";for(c=0;6>c;c++)d+=Hk(a,c);d=d+"\n"+(Hk(a,6)+Hk(a,7));d+=Hk(a,Yj)+Hk(a,Zj)+Hk(a,bk);d+=Gk(a,"T")+Gk(a,"N")+Gk(a,"Z")+Gk(a,"V")+Gk(a,"C");b&&(b=d,c=""+(Hk(a,ck)+Hk(a,dk)),c+=Hk(a,ek)+Hk(a,fk)+Hk(a,ak),c=c+"\n"+(Hk(a,hk)+Hk(a,Wj)+Hk(a,gk)),d=b+("\n"+c));return d}h.me=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],q=ab(n,l,a.me);0>q&&n.splice(-(q+1),0,l)}m&&(k.a=m.replace(/''/g,'"'))}a.B.push({Hk:b,K:c,Lf:d,ga:e,ie:f})}function Jk(a,b,c){var d=[],e=Lj(b)>>>0;for(b=0;b>>0,k=f.Lf;if(e>=g&&eb)){e.g[b]=g&65535;break}a.v("unknown register: "+ +f);return}H(a.J);a.v("updated registers:")}}a.v(Ik(a,d));c&&(a.G=X(e.g[7]),nk(a,Tj(a,a.G)))}}function Nk(a,b){b=Za(b);var c=b.match(/^(['"])(.*?)\1$/);c?1k[0].indexOf("+"))){var m=k[0]+":";k[2]&&(m+=" "+k[2]);a.v(m)}k[3]&&(g=k[3],f=null);f=uk(a,b,g,f);a.v(f);a.G=b;e-=b.K-l;c++}}} +function tk(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.v(lk+b):(a.O&&(a.v("ended assemble at "+Tj(a,a.N)),a.G=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.R=null;if(Ga(a)&&0n||"z"Ua.length&&(a.v("note: only "+Ua.length+" available"),Ca=Ua.length);Ia-=Ca;0>Ia&&(null==Ua[Ua.length-1].K?(Ca=Ia+Ca,Ia=0):Ia+=Ua.length);var jf=[];"call"==zi&&(Lc=1E5,jf=["CALL"]);for(void 0!==yi&&a.v(Ca+" instructions earlier:");0=Ua.length&&(Ia=0);a.pa=Ca;Bi++;Lc--}}Bi||(a.v("no "+Ai+"history available"),a.pa=void 0)}else{var oa=Qj(a,Ta);if(oa)if("da"==jb){var kf=oa.Ma||65535O.length?(2xb&&(xb=0);65536of?String.fromCharCode(of):"."),Nd=Nd>>8}zb&&(zb+="\n");zb=lf?zb+(Ab+","):zb+(Ta+": "+Ab+(Md?"":" "+nf))}zb&&a.v(zb);a.Fa=oa;a.Aa=ql}}}}break;case "e":if("else"== +g[0])break;var bc,pf,qf,rf,sf=g[0],tf=g[1];"eb"==sf?(bc=1,pf=255,qf=a.Od,rf=a.Pd):"e"==sf||"ew"==sf?(bc=2,pf=65535,qf=a.Ra,rf=a.Le):tf=null;if(null==tf)a.v("edit memory commands:"),a.v("\teb [a] [...] edit bytes at address a"),a.v("\tew [a] [...] edit words at address a");else{var Od=Qj(a,tf);if(Od)for(var Pd=2;Pdwf;){for(var Bb=null,ul=256;65536>Rc.K>>>0;){xf.K=a.Ra(Rc,2);if(null==Rc.K||!ul--)break;if(!(xf.K&1)){for(var vl=a,Qd=xf,Gi=null,Sc=Qd.K,Hi=Sc,yf=1;6>=yf&⪼yf++){if(2> ";sb(function(){for(var a=x(document,w,"debugger"),b=0;b\nLicense: GPL version 3 or later ");this.v("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bVk){if(Wk(d,this.G)){this.u=new G(this,"1.34.1",dl);Wk(this.u)&&(el(this,d),a=fl,gl(this.u));this.u.set(al,bb());hl(this.u);var e=this.b&&!this.C;if(a==bl||ra("Click OK to restore the previous "+Hb+" machine state, or CANCEL to reset the machine.")){if(c=$k(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Wk(d,g):("error"==f&&"no machine state"!= +g?(this.T("Error: "+g),"unable to verify user"==g&&(ib(il,""),this.g=null)):this.v(f+": "+g),gl(d),Wk(d)?(c=$k(d),e=!0):c=!1))}e&&Yk(this,c?d:null)}else a==fl&&d.clear()}else Yk(this);delete this.G;delete this.B}e=ta(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.A.ba=!0;var d=this.H.power;d&&(d.textContent="Shutdown");this.f&&(jl(this,this.f,b,c,a),H(this,-2),this.f.qa());this.N&&(el(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; +function el(a,b){if(ra("There may be a problem with your "+Hb+" machine.\n\nTo help us diagnose it, click OK to send this "+Hb+" machine state to http://www.pcjs.org.")){var c=a.U;a=a.g||"";b=b.toString();var d={};d.app=Hb;d.ver="1.34.1";d.url=c;d.user=a;d.type="bug";d.data=b;cb("http://www.pcjs.org/api/v1/report",d,!0)}} +function Pk(a,b,c){var d,e="none";if(a.j)return null;a.j--;var f=new G(a,"1.34.1"),g=new G(a,"1.34.1",Zk),k=bb();g.set(al,k);f.set(al,k);f.set(kl,"1.34.1");f.set(ll,window?window.location.href:null);f.set(ml,window?window.navigator.userAgent:"");a.f&&a.f.Ba&&(c&&(b&&(a.f.A.qa=a.f.A.V),a.f.ca()),d=a.f.Ba(b,c),"object"===typeof d&&f.set(a.f.id,d),c&&(a.f.A.ba=!1,!1===d&&(e=null)));for(var k=ta(a.id),l=0;l=d||30<=(c.$c+=d))&&(e.textContent=c.A.V?c.wb.toFixed(2)+"Mhz":"Stopped",c.$c=0)}if(a.i&&(a=a.i,b=b||0,a.u)){c=a.f.A.V;d=!!(a.f.i&8);if(0>=b||60<=(a.j+=b)){for(e=0;eb?a.fa=a.f.g[7]:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(q){g=null,a=q.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");cb(e,null,!0,function(f,g,k){if(k||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+k+")");else{if(f=d[3])if(k=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=k[0],m,n=/( [a-z]+=)(['"])(.*?)\2/g;m=n.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);k[0]!=l&&(g=g.replace(k[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Fl(a,b,c)}})}else c(a,null)} +function Gl(a,b,c,d,e){function f(a){if(void 0===l){var b=k&&x(k,"machine-warning");l=b&&b[0]||k}l&&(l.innerHTML=Sa(a))}function g(a){f("Error: "+a);m&&(--Cl||Cb(!0));m=!1}var k,l,m=!0;Cl++;pa[b]={};try{if(k=document.getElementById(b)){var n;if("object"==typeof resources&&(n=resources.css)){var q=document.head||document.getElementsByTagName("head")[0],t=document.createElement("style");t.type="text/css";t.styleSheet?t.styleSheet.cssText=n:t.appendChild(document.createTextNode(n));q.appendChild(t)}d|| +(n=a,"pdp"==a.substr(0,3)&&(n="pdpjs"),d="/versions/"+n+"/1.34.1/components.xsl");n=function(e,l){l?Dl(d,null,a,null,!1,f,function(a,e){e?(na(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(k.outerHTML=e,--Cl||Cb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?k.parentNode?(k.parentNode.replaceChild(e,k),--Cl|| +Cb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Dl(c,b,a,e,!0,f,n):El(c,null,b,a,e,!1,f,n)}else g("missing machine element: "+b)}catch(r){g(r.message)}return m}window.embedPDP10=function(a,b,c,d){Cb(!1);return Gl("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){Cb(!1);return Gl("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return va(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!za[a]){for(var c=!0,d=za,e=a,f=b.length,g=[],k=[],l="",m=null,n=0;na?-b:b}});ja("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}});ja("Array.prototype.fill",function(a){return a?a:function(a,c,d){var b=this.length||0;0>c&&(c=Math.max(0,b+c));if(null==d||d>b)d=b;d=Number(d);0>d&&(d=Math.max(0,b+d));for(c=Number(c||0);c":62,"?":63,"@":64,hd:65,Lh:66,Rh:67,si:68,E:69,yi:70,Bi:71,Ni:72,Pi:73,Qi:74,Ri:75,Si:76,Vi:77,Xi:78,cj:79,fj:80,Q:81,hj:82,kj:83,tj:84,vj:85,xj:86,yj:87,Cj:88,Dj:89,Ke:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Ej:97,Gj:98,Jj:99,d:100,e:101,Kj:102,Lj:103,Mj:104,Nj:105,Rj:106,k:107,Sj:108,Tj:109,n:110,Uj:111,p:112,q:113,r:114,Vj:115,t:116,Xj:117,Yj:118,Zj:119,x:120, +y:121,z:122,"{":123,"|":124,"}":125,"~":126,Cb:127};function r(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.qd=b.comment;this.Ie=b;this.exports={};this.o=this.bindings={};a=this.id.indexOf(".");0>a?this.ib=this.id:(this.Ua=this.id.substr(0,a),this.ib=this.id.substr(a+1));this.j={ready:!1,Ra:!1,Wc:!1,R:!1,error:!1};this.ic=null;this.j.error=!1;this.pd=c||0;this.D=this.c=this.v=this.A=this.ob=null;t.push(this)}function na(a,b,c){oa[a]&&b&&(oa[a][b]=c)} +function pa(){return Date.now()||+new Date}function u(a){window&&window.alert(a)}function qa(a){var b=!1;window&&(b=window.confirm(a));return b}function ra(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;ba&&-1=f?48:55),e=String.fromCharCode(f)+e;a=Math.trunc(a/b)}return(void 0===d?"":d)+e}function Da(a,b){b?12"']/g,function(a){return Ja[a]})}function Ka(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Ja={"&":"&","<":"<",">":">",'"':""","'":"'"},La={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function Ma(){function a(a){return(10>a?"0":"")+a}var b=new Date;return b.getFullYear()+"-"+a(b.getMonth()+1)+"-"+a(b.getDate())+" "+a(b.getHours())+":"+a(b.getMinutes())+":"+a(b.getSeconds())} +function Na(a,b,c,d){c=void 0===c?!1:c;var e=0,f=null,g=null;if("object"==typeof resources&&(f=resources[a]))return d&&d(a,f,e),[f,e];if(c&&"function"==typeof resources)return resources(a,function(b,c){d&&d(a,b,c)}),g;var k=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(k.onreadystatechange=function(){4===k.readyState&&(f=k.responseText,200==k.status||!k.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=k.status||-1),d&&d(a, +f,e))});if(b&&"object"==typeof b){var l="",m;for(m in b)b.hasOwnProperty(m)&&(l&&(l+="&"),l+=m+"="+encodeURIComponent(b[m]));l=l.replace(/%20/g,"+");k.open("POST",a,c);k.setRequestHeader("Content-type","application/x-www-form-urlencoded");k.send(l)}else k.open("GET",a,c),"bytes"==b&&k.overrideMimeType("text/plain; charset=x-user-defined"),k.send();c||(f=k.responseText,200!=k.status&&(e=k.status||-1),d&&d(a,f,e),g=[f,e]);return g} +function Oa(a,b){var c,d={L:null,ia:null,ea:null,da:null};if("["==b.charAt(0)||"{"==b.charAt(0))try{var e,f,g;if("<"==b.substr(0,1))throw Error(b);g=0>b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ea=g.load;d.da=g.exec;if(e=g.bytes)d.L=e;else if(e=g.words)for(d.L=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.L=Array(4*e.length),f=c=0;c>8&255,d.L[f++]=e[c]>>16&255,d.L[f++]=e[c]>>24&255;else(e=g.data)?d.Fj=e:d.L=g;d.L&&(d.L.length?1==d.L.length&&(u(d.L[0]),d=null):(u("Empty resource: "+a),d=null));d.ia=g.symbols}catch(k){u("Resource data error ("+a+"): "+k.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca;a++)this.a["S"+a]=[0,0,!1,!1,this.ff,a];this.D=this.c=this.v=this.A=null;this.exports={hold:this.We,toggle:this.Bg,reset:this.ug, +set:this.zg};B(this)}n(mb,r);h=mb.prototype;h.reset=function(a){this.stop();a&&ob(this,this.b=0)}; +h.ma=function(a,b,c,d){if(this.A&&this.A.ma(a,b,c,d)||this.c&&this.c.ma(a,b,c,d))return!0;switch(b){case "R0":case "R1":case "R2":case "R3":case "R4":case "R5":case "R6":case "R7":case "NF":case "ZF":case "VF":case "CF":case "PS":return this.o[b]=c,this.l++,!0;default:return"led"==a||"rled"==a?(this.o[b]=c,this.h[b]=d?1:0,this.l++,!0):"switch"==a?(void 0===this.a[b]&&(this.a[b]=[d?1:0,d?1:0]),this.o[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){pb(a, +b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){qb(a,b)}}(this,b),a.ontouchstart=function(a,b){return function(c){pb(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){qb(a,b)}}(this,b),!0):r.prototype.ma.call(this,a,b,c,d)}};h.ja=function(a,b,c,d){this.A=a;this.v=b;this.c=c;this.D=d;rb(b,this,sb);tb(b,this.reset.bind(this));ub(this);vb(this)};h.la=function(a,b){if(!b)if(this.F&&wb(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0}; +h.ka=function(a){return a?this.save():!0};h.save=function(){var a=new E(this);a.set(0,[this.U,this.b,this.f]);return a.data()};h.restore=function(a){if(a=a[0])xb(this,this.U=a[0]),ob(this,this.b=a[1]),yb(this,a[2]);return!0};h.ug=function(){for(var a in this.a){var b=this.a[a];b[1]=b[0]}vb(this);return!0};function zb(a,b,c){if(a=a.o[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function ub(a,b){for(var c in a.h)zb(a,c,null!=b?b:a.h[c])} +function Ab(a,b,c){if(a=a.o[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function vb(a){for(var b in a.a)Ab(a,b,a.a[b][1])}function Bb(a,b,c,d){if(a.o[b]){var e=a.D&&a.D.h||8;c=c||0;c=8==e?Da(c,d):Ea(c,d);a.o[b].textContent!=c&&(a.o[b].textContent=c)}}h.We=function(a,b,c){if(pb(this,b)){if(c){var d=this;setTimeout(function(){qb(d,b);a&&a()},+c);return!1}qb(this,b)}return!0}; +h.zg=function(a,b){if("SR"==a)return yb(this,Ba(b,8));var c=this.a[a];return c?(c[1]=+b?1:0,Ab(this,a,c[1]),!0):!1};h.Bg=function(a){return pb(this,a)?(qb(this,a),!0):!1};function pb(a,b){var c=a.a[b];return c?(Ab(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=Cb&&(a.w=b==Db,a.B=b==Eb),!0):!1}function qb(a,b){var c=a.a[b];c&&(c[2]&&c[3]&&(Ab(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)} +h.gf=function(a){a||this.c.j.N||(F(this.c,this.U),a=this.c,a.v.reset(),Fb(a),this.a[Gb]&&this.a[Gb][1]&&Hb(this.c))};h.hf=function(){};h.bf=function(a){a||G(this.c)}; +h.$e=function(a){if(!a&&!this.c.j.N)if(this.a[Gb]&&this.a[Gb][1])Hb(this.c);else{a=this.D;var b;if(b=a)a.j.Ra&&(a.j.Wc=!0),b=!a.j.Ra;if(b)Aa(a,!0),a.f(0,null),Aa(a,!1);else try{var c=this.c.zc(1);0=a.c.sa?8:16,c=65472<=a.U&&a.U<65472+b,b=c?1:2,c=c?15:a.v.u;a.a[Cb]&&a.a[Cb][1]||(b=-b);xb(a,a.U&~c|a.U+b&c)}function xb(a,b){a.U=b&a.v.u;if(a.s!==a.U){a.s=a.U;b=a.s;for(var c=0;22>c;c++)Qb(a,"A"+c,b&1<c;c++)Qb(a,"D"+c,b&1<b;b++)a.a["S"+b][1]=a.f&1<>2;this.f=this.g-1;this.s=this.C/this.g|0;this.K=this.s-1;this.Qa=[];this.l=0;this.m=!1;this.F=[];this.Le=[Ub,Vb,Wb,Xb];this.a=this.b=[];this.B=this.w=this.i=this.H=this.I=0;a=new H(this);Yb(a);this.a=Array(this.s);this.b=Array(this.s);for(b=0;b>>this.h;this.w=0;this.i=this.u;B(this)}n(Sb,r);function ac(a,b){if(b!=a.w){for(var c=0;c>>a.h,a.b[a.I]=a.a[a.H])}}h=Sb.prototype;h.reset=function(){for(var a=0;a>>a.h;0g&&(p=g);if(!e&&l&&l.size){if(l.type==d){if(f+g<=l.ab)return l.Tb+=l.ab-f,l.ab=f,!0;if(f>=l.ab+l.Tb){p=l.size-(f-m);p>g&&(p=g);l.Tb=f-l.ab+p;f=m+a.g;g-=p;k++;continue}}return cc(dc,f,g)}f=new H(a,f,p,a.g,d,e);Yb(f,l);a.a[k++]=f;f=m+a.g;g-=p}return 0>=g?(a.status("Added "+(c>>10)+"Kb "+ec[d]+" at "+Da(b)),!0):cc(fc,b,c)}h.Rd=function(a){return this.b[(a&this.i)>>>this.h].tb(a&this.f,a)}; +h.Xb=function(a){var b=a&this.f,c=(a&this.i)>>>this.h;return jb||b!=this.f?this.b[c].W(b,a):this.b[c++].tb(b,a)|this.b[c&this.K].tb(0,a+1)<<8};h.Sd=function(a,b){this.b[(a&this.i)>>>this.h].xb(a&this.f,b,a)};h.Yb=function(a,b){var c=a&this.f,d=(a&this.i)>>>this.h;jb||c!=this.f?this.b[d].Ab(c,b,a):(this.b[d++].xb(c,b&255,a),this.b[d&this.K].xb(0,b>>8&255,a+1))};function gc(a,b){return a.a[(b&a.u)>>>a.h]} +function Pb(a,b){var c;a.m=!1;a.l++;var d=b&a.f,e=gc(a,b);jb||d!=a.f?c=e.D(d,b):c=e.i(d,b)|gc(a,b+1).i(0,b+1)<<8;a.l--;return c}function hc(a,b,c){a.m=!1;a.l++;gc(a,b).o(b&a.f,c&255,b);a.l--}function Nb(a,b,c){a.m=!1;a.l++;var d=b&a.f,e=gc(a,b);jb||d!=a.f?e.l(d,c&65535,b):(e.o(d,c&255,b),gc(a,b+1).o(0,c>>8&255,b+1));a.l--} +function bc(a){for(var b=0,c=[],d=0;da.c.sa)){var k=g[0]?g[0].bind(b):null,l=g[1]?g[1].bind(b):null,m=g[2]?g[2].bind(b):null,p=g[3]?g[3].bind(b):null;65472<=f&&65487>=f&&(!k&&m&&(k=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!l&&p&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));for(var q=g[4],v=g[5]||1,y=0;y>8:e[2](f)&255):f&1&&(e=d.Qa[a&-2])&&(e[2]?c=e[2](f&-2)>>8:e[0]&&(c=e[0](f)));if(0<=c)return c;I(d,b,16);return 255} +function Vb(a,b,c){var d=!1,e=this.controller,f=e.Qa[a],g=c&65535;if(f)if(f[1])f[1](b,g),d=!0;else{if(f[3]){a=f[2]?f[2](g,!0):0;if(g&1)f[3](a&255|b<<8,g&-2);else f[3](a&-256|b,g);d=!0}}else g&1&&(f=e.Qa[a&-2])&&(f[3]?(g&=-2,a=f[2]?f[2](g,!0):0,f[3](a&255|b<<8,g),d=!0):f[1]&&(f[1](b,g),d=!0));d||I(e,c,16)}function Wb(a,b){var c=-1,d=this.controller;a=d.Qa[a];var e=b&65535;a&&(a[2]?c=a[2](e):a[0]&&(c=a[0](e)|a[0](e+1)<<8));if(0<=c)return c;I(d,b,16);return 65535} +function Xb(a,b,c){var d=!1,e=this.controller;a=e.Qa[a];var f=c&65535;a&&(a[3]?(a[3](b,f),d=!0):a[1]&&(a[1](b&255,f),a[1](b>>8,f+1),d=!0));d||I(e,c,16)}function K(a){r.call(this,"Device",a,256);this.a={Ia:128,dd:-1}}n(K,r);h=K.prototype;h.ja=function(a,b,c,d){this.v=b;this.A=a;this.c=c;this.D=d;var e=this;this.a.dd=nc(c,function(){e.a.Ia|=128;e.a.Ia&64&&oc(e.c,e.a.qa);e.A&&Lb(e.A,1);pc(e.c,e.a.dd,1E3/60)});this.a.qa=qc(c,64,6,2097152);rb(b,this,rc);tb(b,this.reset.bind(this));B(this)}; +h.la=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};h.ka=function(a){return a?this.save():!0};h.reset=function(){this.a.Ia=128;pc(this.c,this.a.dd,1E3/60,!0)};h.save=function(){var a=new E(this);a.set(0,[this.a.Ia]);return a.data()};h.restore=function(a){a=ia(a[0]);this.a.Ia=a.next().value;return!0};h.vf=function(){return this.a.Ia};h.Og=function(a){this.a.Ia=a&192;this.a.Ia&64||(a=this.a.qa)&&sc(this.c,a)};h.xf=function(){return tc(this.c)}; +h.Qg=function(a){uc(this.c,a&-129|this.c.J&128)};h.yf=function(){return vc(this.c)};h.zf=function(){return wc(this.c)};h.Af=function(){return this.c.ta};h.Rg=function(a){xc(this.c,a)};h.lg=function(a){a=a>>1&63;var b=this.c.Pa[a>>1];return a&1?b>>16:b&65535};h.Dh=function(a,b){b=b>>1&63;var c=b>>1;this.c.Pa[c]=b&1?this.c.Pa[c]&65535|(a&63)<<16:this.c.Pa[c]&-65536|a&65534};h.eg=function(a){return this.c.s[1][a>>1&7]};h.wh=function(a,b){this.c.s[1][b>>1&7]=a&65295}; +h.cg=function(a){return this.c.s[1][(a>>1&7)+8]};h.uh=function(a,b){this.c.s[1][(b>>1&7)+8]=a&65295};h.dg=function(a){return this.c.H[1][a>>1&7]};h.vh=function(a,b){b=b>>1&7;this.c.H[1][b]=a;this.c.s[1][b]&=65295};h.bg=function(a){return this.c.H[1][(a>>1&7)+8]};h.th=function(a,b){b=(b>>1&7)+8;this.c.H[1][b]=a;this.c.s[1][b]&=65295};h.uf=function(a){return this.c.s[0][a>>1&7]};h.Ng=function(a,b){this.c.s[0][b>>1&7]=a&65295};h.sf=function(a){return this.c.s[0][(a>>1&7)+8]}; +h.Lg=function(a,b){this.c.s[0][(b>>1&7)+8]=a&65295};h.tf=function(a){return this.c.H[0][a>>1&7]};h.Mg=function(a,b){b=b>>1&7;this.c.H[0][b]=a;this.c.s[0][b]&=65295};h.rf=function(a){return this.c.H[0][(a>>1&7)+8]};h.Kg=function(a,b){b=(b>>1&7)+8;this.c.H[0][b]=a;this.c.s[0][b]&=65295};h.kg=function(a){return this.c.s[3][a>>1&7]};h.Ch=function(a,b){this.c.s[3][b>>1&7]=a&65295};h.ig=function(a){return this.c.s[3][(a>>1&7)+8]};h.Ah=function(a,b){this.c.s[3][(b>>1&7)+8]=a&65295}; +h.jg=function(a){return this.c.H[3][a>>1&7]};h.Bh=function(a,b){b=b>>1&7;this.c.H[3][b]=a;this.c.s[3][b]&=65295};h.hg=function(a){return this.c.H[3][(a>>1&7)+8]};h.zh=function(a,b){b=(b>>1&7)+8;this.c.H[3][b]=a;this.c.s[3][b]&=65295};h.vb=function(a){a&=7;return this.c.i&2048?this.c.ua[a]:this.c.b[a]};h.yb=function(a,b){b&=7;this.c.i&2048?this.c.ua[b]=a:this.c.b[b]=a};h.Hf=function(){return this.c.i&49152?this.c.ga[0]:this.c.b[6]};h.Yg=function(a){this.c.i&49152?this.c.ga[0]=a:this.c.b[6]=a}; +h.Kf=function(){return this.c.b[7]};h.ah=function(a){this.c.b[7]=a};h.wb=function(a){a&=7;return this.c.i&2048?this.c.b[a]:this.c.ua[a]};h.zb=function(a,b){b&=7;this.c.i&2048?this.c.b[b]=a:this.c.ua[b]=a};h.If=function(){return 1==(this.c.i&49152)>>14?this.c.b[6]:this.c.ga[1]};h.Zg=function(a){1==(this.c.i&49152)>>14?this.c.b[6]=a:this.c.ga[1]=a};h.Jf=function(){return 3==(this.c.i&49152)>>14?this.c.b[6]:this.c.ga[3]};h.$g=function(a){3==(this.c.i&49152)>>14?this.c.b[6]=a:this.c.ga[3]=a}; +h.qf=function(a){return this.c.Rb[a-65504>>1]};h.Jg=function(a,b){this.c.Rb[b-65504>>1]=a};h.Md=function(a){return 65520==a?(ic(this.v)>>6)-1:0};h.Pd=function(){};h.gg=function(){return 1};h.yh=function(){};h.pf=function(){return this.c.F};h.Ig=function(){this.c.F=0};h.wf=function(){return this.c.Ob};h.Pg=function(a,b){b&1||(a&=255);this.c.Ob=a};h.Bf=function(a,b){return b?0:this.c.$a};h.Sg=function(a){var b=this.c;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1);b.g|=1}b.$a=a}; +h.fg=function(a,b){return b?0:this.c.Oa&65280};h.xh=function(a){this.c.Oa=a|255};h.Gf=function(){return yc(this.c)};h.Xg=function(a){Ac(this.c,a)};h.Od=function(){}; +var L={},rc=(L[61568]=[null,null,K.prototype.lg,K.prototype.Dh,"UNIMAP",64,1170],L[62592]=[null,null,K.prototype.eg,K.prototype.wh,"SIPDR",8,1145,64],L[62608]=[null,null,K.prototype.cg,K.prototype.uh,"SDPDR",8,1145,64],L[62624]=[null,null,K.prototype.dg,K.prototype.vh,"SIPAR",8,1145,64],L[62640]=[null,null,K.prototype.bg,K.prototype.th,"SDPAR",8,1145,64],L[62656]=[null,null,K.prototype.uf,K.prototype.Ng,"KIPDR",8,1140,64],L[62672]=[null,null,K.prototype.sf,K.prototype.Lg,"KDPDR",8,1145,64],L[62688]= +[null,null,K.prototype.tf,K.prototype.Mg,"KIPAR",8,1140,64],L[62704]=[null,null,K.prototype.rf,K.prototype.Kg,"KDPAR",8,1145,64],L[62798]=[null,null,K.prototype.Af,K.prototype.Rg,"MMR3",1,1145,64],L[65382]=[null,null,K.prototype.vf,K.prototype.Og,"LKS"],L[65402]=[null,null,K.prototype.xf,K.prototype.Qg,"MMR0",1,1140,64],L[65404]=[null,null,K.prototype.yf,K.prototype.Od,"MMR1",1,1145,64],L[65406]=[null,null,K.prototype.zf,K.prototype.Od,"MMR2",1,1140,64],L[65408]=[null,null,K.prototype.kg,K.prototype.Ch, +"UIPDR",8,1140,64],L[65424]=[null,null,K.prototype.ig,K.prototype.Ah,"UDPDR",8,1145,64],L[65440]=[null,null,K.prototype.jg,K.prototype.Bh,"UIPAR",8,1140,64],L[65456]=[null,null,K.prototype.hg,K.prototype.zh,"UDPAR",8,1145,64],L[65472]=[null,null,K.prototype.vb,K.prototype.yb,"R0SET0"],L[65473]=[null,null,K.prototype.vb,K.prototype.yb,"R1SET0"],L[65474]=[null,null,K.prototype.vb,K.prototype.yb,"R2SET0"],L[65475]=[null,null,K.prototype.vb,K.prototype.yb,"R3SET0"],L[65476]=[null,null,K.prototype.vb, +K.prototype.yb,"R4SET0"],L[65477]=[null,null,K.prototype.vb,K.prototype.yb,"R5SET0"],L[65478]=[null,null,K.prototype.Hf,K.prototype.Yg,"R6KERNEL"],L[65479]=[null,null,K.prototype.Kf,K.prototype.ah,"R7KERNEL"],L[65480]=[null,null,K.prototype.wb,K.prototype.zb,"R0SET1",1,1145],L[65481]=[null,null,K.prototype.wb,K.prototype.zb,"R1SET1",1,1145],L[65482]=[null,null,K.prototype.wb,K.prototype.zb,"R2SET1",1,1145],L[65483]=[null,null,K.prototype.wb,K.prototype.zb,"R3SET1",1,1145],L[65484]=[null,null,K.prototype.wb, +K.prototype.zb,"R4SET1",1,1145],L[65485]=[null,null,K.prototype.wb,K.prototype.zb,"R5SET1",1,1145],L[65486]=[null,null,K.prototype.If,K.prototype.Zg,"R6SUPER",1,1145],L[65487]=[null,null,K.prototype.Jf,K.prototype.$g,"R6USER",1,1145],L[65504]=[null,null,K.prototype.qf,K.prototype.Jg,"CTRL",8,1170],L[65520]=[null,null,K.prototype.Md,K.prototype.Pd,"LSIZE",1,1170],L[65522]=[null,null,K.prototype.Md,K.prototype.Pd,"HSIZE",1,1170],L[65524]=[null,null,K.prototype.gg,K.prototype.yh,"SYSID",1,1170],L[65526]= +[null,null,K.prototype.pf,K.prototype.Ig,"ERR",1,1170],L[65528]=[null,null,K.prototype.wf,K.prototype.Pg,"MBR",1,1170],L[65530]=[null,null,K.prototype.Bf,K.prototype.Sg,"PIR"],L[65532]=[null,null,K.prototype.fg,K.prototype.xh,"SLR"],L[65534]=[null,null,K.prototype.Gf,K.prototype.Xg,"PSW"],L); +Za(function(){for(var a=A(document,z,"device"),b=0;b>1),this.c=new Int32Array(this.f,0,this.size>>2),Gc(this,Hc?Ic:Jc);else{a=this.c=Array(this.size>>2);for(f=0;f>2),b=0;b>8,c)};h.mf=function(a){return this.c[a>>2]>>>((a&3)<<3)&255};h.qg=function(a,b){ib&&a&1&&I(this.b,b,64);b=a>>2;a=(a&3)<<3;var c=this.c[b]>>a;return 24>a?c&65535:c&255|(this.c[b+1]&255)<<8}; +h.Gg=function(a,b){var c=a>>2;a=(a&3)<<3;this.c[c]=this.c[c]&~(255<>2;a=(a&3)<<3;24>a?this.c[c]=this.c[c]&~(65535<>8);this.Ha=!0};h.kf=function(a,b){return this.i(a,b)};h.ng=function(a,b){return this.D(a,b)};h.Eg=function(a,b,c){this.A?this.Wb(0,0,c):this.o(a,b,c)};h.Fh=function(a,b,c){this.A?this.Wb(0,0,c):this.l(a,b,c)};h.jf=function(a){return this.a[a]}; +h.lf=function(a){return this.a[a]};h.mg=function(a,b){ib&&a&1&&I(this.b,b,64);return this.v.getUint16(a,!0)};h.pg=function(a,b){ib&&a&1&&I(this.b,b,64);return!jb&&a&1?this.a[a]|this.a[a+1]<<8:this.m[a>>1]};h.Dg=function(a,b){this.a[a]=b;this.Ha=!0};h.Fg=function(a,b){this.a[a]=b;this.Ha=!0};h.Eh=function(a,b,c){ib&&a&1&&I(this.b,c,64);this.v.setUint16(a,b,!0);this.Ha=!0};h.Gh=function(a,b,c){ib&&a&1&&I(this.b,c,64);!jb&&a&1?(this.a[a]=b,this.a[a+1]=b>>8):this.m[a>>1]=b;this.Ha=!0}; +var Ec=0,jc=1,Fc=2,$b=4,ec=["NONE","RAM","ROM","VID","H/W"],Dc=0,Lc=[],Kc=[H.prototype.mf,H.prototype.Gg,H.prototype.qg,H.prototype.Hh],Oc=[H.prototype.kf,H.prototype.Eg,H.prototype.ng,H.prototype.Fh];if(gb)var Jc=[H.prototype.jf,H.prototype.Dg,H.prototype.mg,H.prototype.Eh],Ic=[H.prototype.lf,H.prototype.Fg,H.prototype.pg,H.prototype.Gh];var Pc;if(gb){var Rc=new ArrayBuffer(2);(new DataView(Rc)).setUint16(0,256,!0);Pc=256===(new Uint16Array(Rc))[0]}else Pc=!1;var Hc=Pc; +function Sc(a,b){r.call(this,"CPU",a,1);b=+a.cycles||b;var c=+a.multiplier||1;this.fd=0;this.tc=b;this.Za=c;this.Dc=Math.round(this.tc/1E4)/100;this.jb=this.Dc*this.Za;this.Fc=this.Nb=this.mb=this.uc=0;this.j.N=this.j.cd=!1;this.j.Y=a.autoStart;"string"==typeof this.j.Y&&(this.j.Y="true"==this.j.Y);this.j.gc=!1;this.rc=this.lb=0;this.sc=+a.csStart;this.Lb=+a.csInterval;this.Mb=+a.csStop;this.X=[];this.td=this.vg.bind(this);this.Na=this.Da=this.Ma=this.a=this.ba=this.Ca=this.Kb=this.La=this.nb=this.Gc= +this.Wa=0;this.pa=null;B(this)}n(Sc,r);h=Sc.prototype;h.ja=function(a,b,c,d){this.A=a;this.v=b;this.D=d;this.pa=a.f;for(a=0;a=a.lb&&(a.lb+=a.Lb,c=!0);0<=a.Mb&&a.Mb<=Xc(a)&&(a.Lb=a.Mb=-1,Wc(a),G(a),c=!0);c&&a.aa(Xc(a)+" cycles: checksum="+Ea(a.rc))}} +h.ma=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.o[b]=c,!0;case "run":return this.o[b]=c,c.onclick=function(){var a;if(a=d.A)if(a=d.A,a.j.R)a=!0;else{var b=null,c,k=ra(a.id);for(c=0;ca.Wa/a.jb&&(b=1);a.Za=b;b=a.Dc*a.Za;if(a.jb!=b){a.jb=b;b=a.jb.toFixed(2)+"Mhz";var d=a.o.setSpeed;d&&(d.textContent=b);a.aa("target speed: "+b)}c&&a.A&&ad(a.A)}Jb(a,a.Da);a.Da=0;a.Ca=pa();a.La=0;Zc(a)}function nc(a,b){var c=a.X.length;a.X.push([-1,b]);return c}function pc(a,b,c,d){0<=b&&ba.X[b][0])&&(c=a.tc*a.Za/1E3*c|0,a.j.N&&(c+=bd(a)),a.X[b][0]=c)}function cd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function bd(a,b){var c=a.Ma-=a.a;a.a=a.ba=0;b&&(a.Ma=0);return c} +h.vg=function(){if(this.j.N){this.uc>=this.tc&&Zc(this,!0);this.nb=0;this.Kb=pa();if(this.La){var a=this.Kb-this.La;a>this.Fc&&(this.Ca+=a,this.Ca>this.Kb&&(this.Ca=this.Kb))}try{do{for(var b,c=this.j.gc?1:this.Nb,d=this.X.length-1;0<=d;d--){var e=this.X[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.zc(b)}catch(f){if("number"!=typeof f)throw f;}b=bd(this,!0);this.nb+=b;this.Da+=b;Kb(this,b);Ib(this,b);this.mb-=b;if(0>=this.mb){this.mb+=this.Nb;++this.Gc>=dd&&(this.A&&Lb(this.A,void 0),this.Gc=0);break}}while(this.j.N)}catch(f){G(this); +this.A&&this.A.stop(pa(),Xc(this));a=f.stack||f.message;this.j.error=!0;this.G(a);return}if(this.j.N){a=setTimeout;b=this.td;this.La=pa();c=this.Fc;this.nb&&(c=Math.round(c*this.nb/this.Nb));c-=this.La-this.Kb;if(d=this.La-this.Ca)this.Wa=Math.round(this.Da/(10*d))/100,864E5<=d&&(this.Na=0,Yc(this));if(0>c||this.Wac&&(this.Ca-=c),c=0;this.uc+=this.nb;this.La+=c;a(b,c)}}}; +function Hb(a){var b;a.j.error?(a.aa(a.toString()+" error"),b=!0):b=!1;if(!b)if(a.j.N)a.aa(a.toString()+" busy");else{Yc(a);a.j.N=!0;a.j.cd=!0;if(b=a.o.run)b.textContent="Halt";a.A&&a.A.start(a.Ca,Xc(a));a.D||a.status("Started");setTimeout(a.td,0)}}h.zc=function(){return 0};function G(a){var b=!1;if(a.j.N){bd(a);Jb(a,a.Da);a.Da=0;a.j.N=!1;if(b=a.o.run)b.textContent="Run";a.A&&a.A.stop(pa(),Xc(a));b=!0;a.D||a.status("Stopped")}a.j.complete=void 0;return b}var $c=30,dd=15,Tc=["power","reset"]; +function ed(a){var b=+a.model||1170;Sc.call(this,a,6666667);this.sa=b;this.od=+a.addrReset||0;this.Ea=this.i=this.B=this.u=this.l=this.m=this.w=0;this.b=this.ua=this.ga=[];this.H=this.s=this.Pa=this.Rb=[];this.Ka=this.C=this.nd=this.kb=this.Xa=this.Ya=this.cb=this.F=this.Ob=this.$a=this.Oa=this.J=this.Pb=this.Qb=this.ta=this.g=0;this.He=[4,2,0,1];this.wc=0;this.sd=255;1120>=this.sa?(this.vd=fd.bind(this),this.hb=this.Pe,this.wc=8,this.sd=-1,this.zd=255,this.wd=0):(this.vd=gd.bind(this),this.hb=this.Qe, +this.zd=~(1792|(1140>=this.sa?2048:0))&65535,this.wd=1140e.Ub&&(e.Ub=c,c+=4)}return Sc.prototype.la.call(this,a,b)}; +h.reset=function(){this.status("Model "+this.sa);this.j.N&&G(this);this.u=65536;this.l=32768;this.m=65535;this.w=32768;this.i=15;this.b=[0,0,0,0,0,0,0,this.od,-1,-2,-3,-4,-5,-6,-7,-8];this.ua=[0,0,0,0,0,0];this.ga=[0,0,0,0];this.H=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.s=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[65535,65535,65535,65535,65535,65535,65535,65535,65535,65535, +65535,65535,65535,65535,65535,65535],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];this.Pa=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];this.Rb=[0,0,0,0,0,0,0,0];this.B=0;this.Ea=-1;this.h=this.f=this.qc=this.K=this.S=this.g=this.Ob=0;Fb(this);Vc(this);this.j.error=!1;Sc.prototype.reset.call(this)};function Fb(a){a.J=0;a.Pb=0;a.Qb=0;a.ta=0;a.F=0;a.$a=0;a.Oa=255;a.kb=0;a.Xa=0;a.Ya=0;a.cb=262143;a.Ka=a.b[7];a.C=0;a.I=null;a.v&&(hd(a),a.nd=ic(a.v))} +function hd(a){a.kc=a.gd;a.lc=a.xc;a.yc=a.Ac;a.mc=a.Cc;a.kb?(a.Aa=65536,a.jc=a.ta&16?4186112:253952,a.ra=a.Id,a.W=a.Nd,a.Ab=a.Qd,ac(a.v,a.ta&16?22:18)):(a.Aa=0,a.jc=57344,a.ra=a.Ue,a.W=a.og,a.Ab=a.Ih,ac(a.v,16))}function tc(a){var b=a.J;b&57344||(b=b&-3199|a.Xa<<5|a.Ya<<1);return b}function uc(a,b){b&=-3073;if(a.J!=b){b&57344&&!(a.J&57344)&&(a.Pb=a.C>>16&65535,a.Qb=a.C&65535);a.J=b;a.Xa=(b&96)>>5;a.Ya=(b&30)>>1;var c=0;b&257&&(c=4,b&1&&(c|=2));a.kb!=c&&(a.kb=c,hd(a))}} +function vc(a){a.J&57344||(a.Pb=a.C>>16&65535);a=a.Pb;a&65280&&(a=(a<<8|a>>8)&65535);return a}function wc(a){a.J&57344||(a.Qb=a.C&65535);return a.Qb}function xc(a,b){1170>a.sa&&(b&=-49);a.ta!=b&&(a.ta=b,a.cb=b&16?4194303:262143,hd(a))}function id(a,b,c,d){a.od=b;F(a,b);Ac(a,0);a.v.reset();Fb(a);if(c){a.b[0]=d||0;for(b=1;5>=b;b++)a.b[b]=0;a.b[6]=1024;a.j.R?a.j.N||Hb(a):a.j.Y=!0}else a.D&&a.j.R?G(a)||a.A.j.reset||(a.D.g(),Lb(a.A,-1)):!1===c&&G(a);!a.j.N&&a.pa&&a.pa.stop()}h.Hd=function(){return 0}; +h.save=function(){var a=new E(this);a.set(0,[this.b,this.ua,this.ga,this.H,this.s,this.Pa,this.Rb,this.F,this.Ob,this.$a,this.Oa,this.Xa,this.Ya,this.Ka,this.g,this.C,this.Ea,this.Lc,this.Nc]);a.set(1,[yc(this),tc(this),vc(this),wc(this),this.ta]);a.set(2,[this.Na,this.Za,this.j.Y]);a.set(3,jd(this));a.set(4,cd(this));return a.data()}; +h.restore=function(a){var b=ia(a[0]);this.b=b.next().value;this.ua=b.next().value;this.ga=b.next().value;this.H=b.next().value;this.s=b.next().value;this.Pa=b.next().value;this.Rb=b.next().value;this.F=b.next().value;this.Ob=b.next().value;this.$a=b.next().value;this.Oa=b.next().value;this.Xa=b.next().value;this.Ya=b.next().value;this.Ka=b.next().value;this.g=b.next().value;this.C=b.next().value;this.Ea=b.next().value;this.Lc=b.next().value;this.Nc=b.next().value;b=a[1];Ac(this,b[0]);uc(this,b[1]); +this.Pb=b[2];this.Qb=b[3];xc(this,b[4]);b=a[2];this.Na=b[0];Yc(this,b[1]);this.j.Y=b[2];for(var b=a[3],c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>23)),a.a-=2);a.a-=3}function F(a,b){a.b[7]=b&65535}function qc(a,b,c,d){b={Ub:b,sb:c,message:d||0,name:lb[b],next:null};a.Ib.push(b);return b}function sc(a,b){var c=a.I;if(c==b)a.I=b.next;else for(;c;){var d=c.next;if(d==b){c.next=d.next;break}c=d}a.I&&(a.g|=1)}function oc(a,b){if(b){if(b!=a.I){var c=a.I;if(!c||c.sb<=b.sb)b.next=c,a.I=b;else{do{var d=c.next;if(!d||d.sb<=b.sb){b.next=d;c.next=b;break}c=d}while(c)}}a.g|=1}} +function jd(a){var b=[];for(a=a.I;a;)b.push(a.Ub),a=a.next;return b}function nd(a){return a.g&64?(J(a,168,64,-6),!0):a.g&32?(J(a,4,32,-5),!0):a.g&16?(J(a,12,16,-7),!0):!1}function yc(a){return a.i=a.i&63728|ld(a)|(a.m&65535?0:4)|(a.l&32768?2:0)|kd(a)}function Ac(a,b){b&=a.zd;a.w=b<<12;a.m=~b&4;a.l=b<<14;a.u=b<<16;if((b^a.i)&a.wd)for(var c=a.ua.length;0<=--c;){var d=a.b[c];a.b[c]=a.ua[c];a.ua[c]=d}a.B=b>>14&3;c=a.i>>14&3;a.B!=c&&(a.ga[c]=a.b[6],a.b[6]=a.ga[a.B]);a.i=b;a.g&=-3;a.g|=a.I?2:1} +h.fa=function(a){this.w=this.m=a;this.l=0};h.Sa=function(a,b){this.w=this.m=this.u=a;this.l=b||0};function od(a,b){a.w=a.m=a.u=b;a.l=a.w^a.u>>1}function pd(a,b,c,d){a.w=a.m=a.u=b;a.l=(c^d)&(d^b)} +function J(a,b,c,d){if(!a.pb){0>a.Ea?a.Ea=yc(a):a.B||(d=-4);-4==d&&(a.g&256&&(d=-1),a.g|=256,a.F|=4,a.b[6]=b=4);if(-1!=d){a.C=b|4143316992;a.B=0;var e=a.W(b|a.Aa),f=a.W(b+2&65535|a.Aa);Ac(a,f&-12289|a.Ea>>2&12288);qd(a,a.Ea);qd(a,a.b[7]);F(a,e)}a.a-=5;a.g&=~(c|19);a.g|=129;a.Ea=-1;a.Lc=d;a.Nc=b;-1==d&&G(a);if(-4<=d)throw b;}}function rd(a){var b=sd(a),c=sd(a);a.i&49152&&(c=c&-225|a.i&63712);F(a,b);Ac(a,c);a.g&=-17} +function td(a,b){var c=b>>13&31;31>c&&(b=a.ta&32?a.Pa[c]+(b&8191)&4194303:b&-3932161);return b} +function Ob(a,b,c){var d,e,f;if(!(c&a.kb))return f=b&65535,57344<=f&&(f|=a.jc),f;d=b>>13;a.ta&a.He[a.B]||(d&=7);e=a.s[a.B][d];f=(a.H[a.B][d]<<6)+(b&8191)&a.cb;3932160<=f&&(f=td(a,f));if(a.pb)return f;f>=a.nd&&f>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&& +(g|=16384));a.s[a.B][d]=e;if(f!=(4194170&a.cb)||a.B)a.Xa=a.B,a.Ya=d;g&&(g&57344&&(0<=a.Ea&&(g|=128),a.J&57344||(g|=a.J&4096|a.Xa<<5|a.Ya<<1,uc(a,a.J&-61695|g&61694)),J(a,168,64,-2)),a.J&61440||!(f<(4191360&a.cb)||f>(4194239&a.cb))||(a.J|=4096,a.J&512&&(a.g|=64)));return f}function sd(a){var b=a.W(a.b[6]|a.Aa);a.b[6]=a.b[6]+2&65535;return b}function qd(a,b){var c=a.b[6]-2&65535;a.b[6]=c;a.C=a.C&65535|(a.C&-65536)<<8|16121856;a.g&256||a.hb(4,-2,c);a.Ab(c,b)} +function ud(a,b,c,d){var e,f,g=d&8?0:a.Aa;switch(b){case 0:return J(a,4,0,-3),0;case 1:return 6==c&&a.hb(d,0,a.b[6]),a.a-=3,7==c?a.b[c]:a.b[c]|g;case 2:f=2;e=a.b[c];6==c&&a.hb(d,f,e);7!=c&&(e|=g,6>c&&d&1&&(f=1));a.a-=3;break;case 3:f=2;e=a.b[c];7!=c&&(e|=g);e=a.W(e);e|=g;a.a-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.b[c]+f&65535;6==c&&a.hb(d,f,e);7!=c&&(e|=g);a.a-=4;break;case 5:f=-2;e=a.b[c]-2&65535;7!=c&&(e|=g);e=a.W(e)|g;a.a-=8;break;case 6:return e=a.W(md(a,2)),e=e+a.b[c]&65535,6==c&&a.hb(d,0, +e),a.a-=6,e|g;case 7:return e=a.W(md(a,2)),e=e+a.b[c]&65535,e=a.W(e|a.Aa),a.a-=10,e|g}a.b[c]=a.b[c]+f&65535;a.C=a.C&65535|(a.C&-65536)<<8|(f<<3&248|c)<<16;return e}h.Pe=function(a,b,c){!this.B&&0>=b&&c<=this.Oa&&(this.g|=32)};h.Qe=function(a,b,c){this.B||(65534<=c&&(c|=-65536),a&4&&c<=this.Oa&&(c<=this.Oa-32?J(this,4,0,-4):(this.F|=8,this.g|=32)))};h.Te=function(a){return this.gd(a)};h.Ve=function(a){return this.xc(a)};h.xg=function(a,b){this.Ac(a,b)};h.Ag=function(a,b){this.Cc(a,b)}; +h.Ue=function(a,b,c){return ud(this,a,b,c)};h.Id=function(a,b,c){return Ob(this,ud(this,a,b,c),c)};h.og=function(a){return this.v.Xb(this.Ka=a)};h.Nd=function(a){return this.v.Xb(this.Ka=Ob(this,a,2))};h.Ih=function(a,b){this.v.Yb(this.Ka=a,b)};h.Qd=function(a,b){this.v.Yb(this.Ka=Ob(this,a,4),b)}; +function vd(a,b,c){var d=a.f=b&7;(b=a.h=(b&56)>>3)?(d=ud(a,b,d,2),c&65536||61440!==(a.i&61440)&&(d&=65535),a.B=a.i>>12&3,c=a.W(d|c&a.Aa),a.B=a.i>>14&3):c=6!=d||(a.i>>2&12288)===(a.i&12288)?a.b[d]:a.ga[a.i>>12&3];return c}function wd(a,b,c,d){a.C=a.C&65535|1441792;var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=ud(a,b,e,4),c&65536||(e&=65535),a.B=a.i>>12&3,e=Ob(a,e|c&65536,4),a.B=a.i>>14&3,a.mc(e,d)):6!=e||(a.i>>2&12288)===(a.i&12288)?a.b[e]=d:a.ga[a.i>>12&3]=d} +function xd(a,b){b>>=6;var c=a.S=b&7;return(b=a.K=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c+a.wc]&a.sd}function yd(a,b){var c;b>>=6;var d=a.S=b&7;(b=a.K=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d+a.wc];return c}function zd(a,b){var c=a.f=b&7;b=a.h=(b&56)>>3;return ud(a,b,c,8)}function Ad(a,b){var c=a.f=b&7;return(b=a.h=(b&56)>>3)?a.kc(a.ra(b,c,3)):a.b[c]&255}function Bd(a,b){var c,d=a.f=b&7;(b=a.h=(b&56)>>3)?c=a.lc(a.ra(b,d,2)):c=a.b[d];return c} +function P(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.qc=a.ra(b,e,7),c=0>c?a.b[-c-1]&255:c,a.yc(e,d.call(a,c,a.kc(e))),e&1&&a.a--):(b=a.b[e],c=0>c?a.b[-c-1]&255:c,a.b[e]=b&65280|d.call(a,c,b&255))}function Q(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,6),a.mc(e,d.call(a,0>c?a.b[-c-1]:c,a.lc(e)))):a.b[e]=d.call(a,0>c?a.b[-c-1]:c,a.b[e])} +function Cd(a,b,c,d,e){var f=a.f=b&7;(b=a.h=(b&56)>>3)?(d=a.ra(b,f,5),e.call(a,(c=0>c?a.b[-c-1]&255:c)<<8),a.yc(d,c),d&1&&a.a--):(c?(c=0>c?a.b[-c-1]&255:c,a.b[f]=a.b[f]&~d|c<<24>>24&d):a.b[f]&=~d,e.call(a,c<<8))}function Dd(a,b,c,d){var e=a.f=b&7;(b=a.h=(b&56)>>3)?(e=a.ra(b,e,4),d.call(a,c=0>c?a.b[-c-1]:c),a.mc(e,c)):(a.b[e]=c=0>c?a.b[-c-1]:c,d.call(a,c))} +h.zc=function(a){this.j.complete=!0;var b=a?this.j.cd?0:1:-1;this.j.cd=!1;this.Ma=this.a=a;this.g=this.g&-5|0;do{if(this.g){if(a=this.g&11)if(a=!1,this.g&2){var c=160,d=(this.$a&224)>>5,e=this.I&&this.I.sb>d?this.I:null;e&&(c=e.Ub,d=e.sb);d>(this.i&224)>>5?(this.g&8&&(md(this,2),this.g&=-9),J(this,c,0,-10),d=!0):d=!1;d&&(e&&sc(this,e),a=!0);this.I||this.$a||(this.g&=-3)}else this.g&1&&this.g++;if(a){if(this.g&4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}if(this.g&112&&nd(this)){if(this.g& +4&&this.D.b(this.b[7],b)){G(this);break}if(0>b)break}}this.g=this.g&15|this.i&16;a=this.C=this.b[7];e=this.W(a);this.b[7]=a+2&65535;this.vd(e)}while(0>1|b<<16;od(this,a);return a&65535}function Jd(a,b){a=b&128|b>>1|b<<8;od(this,a<<8);return a&255}function Kd(a,b){a=b&~a;this.fa(a);return a}function Ld(a,b){a=b&~a;this.fa(a<<8);return a}function Md(a,b){a|=b;this.fa(a);return a}function Nd(a,b){a|=b;this.fa(a<<8);return a} +function Od(a,b){a=~b|65536;this.Sa(a);return a&65535}function Pd(a,b){a=~b|256;this.Sa(a<<8);return a&255}function Qd(a,b){this.w=this.m=a=b-a;this.l=b&(b^a);return a&65535}function Rd(a,b){a=b-a;var c=a<<8;b<<=8;this.w=this.m=c;this.l=b&(b^c);return a&255}function Sd(a,b){this.w=this.m=a=b+a;this.l=a&(b^a);return a&65535}function Td(a,b){a=b+a;var c=a<<8;this.w=this.m=c;this.l=c&(b<<8^c);return a&255}function Ud(a,b){a=-b;this.Sa(a,a&b&32768);return a&65535} +function Vd(a,b){a=-b;this.Sa(a<<8,(a&b&128)<<8);return a&255}function Wd(a,b){a=b<<1|this.u>>16&1;od(this,a);return a&65535}function Xd(a,b){a=b<<1|this.u>>16&1;od(this,a<<8);return a&255}function Yd(a,b){a=(this.u&65536|b)>>1|b<<16;od(this,a);return a&65535}function Zd(a,b){a=((this.u&65536)>>8|b)>>1|b<<8;od(this,a<<8);return a&255}function $d(a,b){var c=b-a;pd(this,c,a,b);return c&65535}function ae(a,b){var c=b-a;pd(this,c<<8,a<<8,b<<8);return c&255} +function be(a,b){this.w=this.m=b&65280;this.l=this.u=0;return(b<<8|b>>8)&65535}function ce(a,b){a^=b;this.fa(a);return a&65535}function de(a){Q(this,a,yd(this,a),Ed);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)} +function ee(a){var b=Bd(this,a);a=a>>6&7;var c=this.b[a];c&32768&&(c|=4294901760);this.u=this.l=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.l=32768)}this.b[a]=c&65535;this.w=this.m=c;this.a-=(this.h?6:7)+b} +function fe(a){var b=Bd(this,a);a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.u=this.l=0;b&=63;if(b&32){b=64-b;32>b-1;this.u=d<<16;d>>=1;c&2147483648&&(d|=4294967295<<32-b)}else b?(d=c<>15,d<<=1,32>=32-b)&&4294967295!==(c|4294967295<>16&65535;this.b[a|1]=d&65535;this.w=d>>16;this.m=d>>16|d;this.a-=(this.h?6:7)+b}function ge(a){O(this,a,!kd(this))}function he(a){O(this,a,kd(this))} +function ie(a){Q(this,a,yd(this,a),Kd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function je(a){P(this,a,xd(this,a),Ld);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function ke(a){Q(this,a,yd(this,a),Md);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function le(a){P(this,a,xd(this,a),Nd);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)} +function me(a){var b=yd(this,a);a=Bd(this,a);this.fa((0>b?this.b[-b-1]:b)&a);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function ne(a){var b=xd(this,a);a=Ad(this,a);this.fa(((0>b?this.b[-b-1]&255:b)&a)<<8);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function oe(a){O(this,a,this.m&65535?0:4)}function pe(a){O(this,a,!ld(this)==!(this.l&32768))}function qe(a){O(this,a,!!(this.m&65535)&&!ld(this)==!(this.l&32768))} +function re(a){O(this,a,!kd(this)&&!!(this.m&65535))}function se(a){O(this,a,(this.m&65535?0:4)||!ld(this)!=!(this.l&32768))}function te(a){O(this,a,kd(this)||(this.m&65535?0:4))}function ue(a){O(this,a,!ld(this)!=!(this.l&32768))}function ve(a){O(this,a,ld(this))}function we(a){O(this,a,!!(this.m&65535))}function xe(a){O(this,a,!ld(this))}function ye(){J(this,12,0,-9)}function ze(a){O(this,a,!0)}function Ae(a){O(this,a,!(this.l&32768))}function Be(a){O(this,a,this.l&32768?2:0)} +function Ce(a){a&1&&(this.u=0);a&2&&(this.l=0);a&4&&(this.m=1);a&8&&(this.w=0);this.a-=5}function De(a){var b=yd(this,a);a=Bd(this,a);var c=(b=0>b?this.b[-b-1]:b)-a;pd(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)}function Ee(a){var b=xd(this,a);a=Ad(this,a);var c=(b=(0>b?this.b[-b-1]&255:b)<<8)-(a<<=8);pd(this,c,a,b);this.a-=this.h?4+(this.S&&6<=this.f?1:0):(this.K?4:3)+(7==this.f?2:0)} +function Fe(a){var b=Bd(this,a);if(b){a=a>>6&7;var c=this.b[a]<<16|this.b[a|1];this.u=this.l=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.b[a]=d&65535,this.b[a|1]=c-d*b&65535,this.m=d>>16|d,this.w=d>>16):(this.l=32768,this.m=d>>15|d,this.w=c>>16,-1===b&&65534===this.b[a]&&(this.b[a]=this.b[a|1]=1));this.a-=53}else this.m=this.w=0,this.l=32768,this.u=65536,this.a-=7}function Ge(){J(this,24,0,-9);this.a-=20} +function He(){this.i&49152?(this.F|=128,J(this,4,0,-8)):(this.pa&&1120==this.sa&&this.pa.setData(this.b[0],!0),this.D?this.D.i():G(this));this.a-=7}function Ie(){J(this,16,0,-9);this.a-=20}var Je=[0,7,7,10,7,11,9,13];function Ke(a){this.ba=this.a;F(this,zd(this,a));this.a=this.ba-Je[this.h]}var Le=[0,14,14,17,14,18,16,20];function Me(a){this.ba=this.a;var b=zd(this,a);a=a>>6&7;qd(this,this.b[a]);this.b[a]=this.b[7];F(this,b);this.a=this.ba-Le[this.h]} +var Ne=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17];function Oe(a){var b=yd(this,a);this.ba=this.a;Dd(this,a,b,this.fa);this.a=this.ba-Ne[(this.K?8:0)+this.h]+(7!=this.f||this.h?0:2)}function Pe(a){var b=xd(this,a);Cd(this,a,b,65535,this.fa);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}var Qe=[7,13,13,17,14,18,17,21]; +function Re(a){var b=Bd(this,a);a=a>>6&7;b=(b<<16>>16)*(this.b[a]<<16>>16);this.b[a]=b>>16&65535;this.b[a|1]=b&65535;b|=0;this.w=b>>16;this.m=this.w|b;this.l=0;this.u=-32768>b||32767>6;if(this.b[b]=this.b[b]-1&65535)F(this,this.b[7]-((a&63)<<1)),this.a+=1;this.a-=6}function Ye(a){Q(this,a,yd(this,a),$d);this.a-=this.h?9+(this.S&&6<=this.f?1:0):(this.K?5:3)+(7==this.f?2:0)}function Ze(a){Q(this,a,0,be);this.a-=this.h?9:3+(7==this.f?2:0)}function $e(){J(this,28,0,-9)} +function af(){this.pa&&(this.pa.U=this.b[7],this.pa.setData(this.b[0],!0));this.g|=8;md(this,-2);this.a-=3}function bf(a){Q(this,a,this.b[(a>>6&7)+this.wc],ce);this.a-=this.h?9:3+(7==this.f?2:0)}function R(){J(this,8,0,-9)}function fd(a){cf[a>>12].call(this,a)}function df(a){ef[a>>6&3].call(this,a)}function ff(a){gf[a>>6&3].call(this,a)}function hf(a){jf[a>>6&3].call(this,a)}function kf(a){lf[a&15].call(this,a)}function mf(a){nf[a&15].call(this,a)}function of(a){pf[a>>6&3].call(this,a)} +function qf(a){rf[a>>6&3].call(this,a)}function sf(a){tf[a>>6&3].call(this,a)} +var cf=[function(a){uf[a>>8&15].call(this,a)},Oe,De,me,ie,ke,de,R,function(a){vf[a>>8&15].call(this,a)},Pe,Ee,ne,je,le,Ye,R],uf=[function(a){wf[a>>4&15].call(this,a)},ze,we,oe,pe,ue,qe,se,Me,Me,df,ff,hf,R,R,R],ef=[function(a){Dd(this,a,0,this.Sa);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Od);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,Sd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,Qd);this.a-=this.h?9:3+(7==this.f?2:0)}],gf=[function(a){Q(this,a,0,Ud); +this.a-=this.h?11:6},function(a){Q(this,a,kd(this)?1:0,Ed);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,kd(this)?1:0,$d);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){a=Bd(this,a);this.Sa(a);this.a-=this.h?4:3+(7==this.f?2:0)}],jf=[function(a){Q(this,a,0,Yd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Wd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Id);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,Gd);this.a-=this.h?9:3+(7==this.f?2:0)}],wf= +[function(a){xf[a&15].call(this,a)},R,R,R,Ke,Ke,Ke,Ke,Ue,R,kf,mf,Ze,Ze,Ze,Ze],xf=[He,af,Ve,ye,Ie,Te,R,R,R,R,R,R,R,R,R,R],lf=[Se,function(){this.u=0;this.a-=5},function(){this.l=0;this.a-=5},Ce,function(){this.m=1;this.a-=5},Ce,Ce,Ce,function(){this.w=0;this.a-=5},Ce,Ce,Ce,Ce,Ce,Ce,Ce],nf=[Se,function(){this.u=65536;this.a-=5},function(){this.l=32768;this.a-=5},We,function(){this.m=0;this.a-=5},We,We,We,function(){this.w=32768;this.a-=5},We,We,We,We,We,We,We],vf=[xe,ve,re,te,Ae,Be,ge,he,Ge,$e,of,qf, +sf,R,R,R],pf=[function(a){Cd(this,a,0,255,this.Sa);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,0,Pd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,1,Td);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,1,Rd);this.a-=this.h?9:3+(7==this.f?2:0)}],rf=[function(a){P(this,a,0,Vd);this.a-=this.h?11:6},function(a){P(this,a,kd(this)?1:0,Fd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,kd(this)?1:0,ae);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){a=Ad(this,a); +this.Sa(a<<8);this.a-=this.h?4:3+(7==this.f?2:0)}],tf=[function(a){P(this,a,0,Zd);this.a-=this.h?9+(this.qc&1):3+(7==this.f?2:0)},function(a){P(this,a,0,Xd);this.a-=this.h?9:3+(7==this.f?2:0)},function(a){P(this,a,0,Jd);this.a-=this.h?9+(this.qc&1):3+(7==this.f?2:0)},function(a){P(this,a,0,Hd);this.a-=this.h?9:3+(7==this.f?2:0)}];function gd(a){yf[a>>12].call(this,a)} +var yf=[function(a){zf[a>>8&15].call(this,a)},Oe,De,me,ie,ke,de,function(a){Af[a>>8&15].call(this,a)},function(a){Bf[a>>8&15].call(this,a)},Pe,Ee,ne,je,le,Ye,R],zf=[function(a){Cf[a>>4&15].call(this,a)},ze,we,oe,pe,ue,qe,se,Me,Me,df,ff,hf,function(a){Df[a>>6&3].call(this,a)},R,R],Df=[function(a){a=this.b[7]+((a&63)<<1)&65535;var b=this.W(a|this.Aa);F(this,this.b[5]);this.b[6]=a+2&65535;this.b[5]=b;this.a-=8},function(a){a=vd(this,a,0);this.fa(a);qd(this,a);this.a-=11},function(a){var b=sd(this);this.ba= +this.a;this.fa(b);wd(this,a,0,b);this.a=this.ba-Qe[this.h]},function(a){Dd(this,a,ld(this)?65535:0,this.fa);this.a-=this.h?9:3+(7==this.f?2:0)}],Cf=[function(a){Ef[a&15].call(this,a)},R,R,R,Ke,Ke,Ke,Ke,Ue,function(a){!(a&8)||1145>this.sa?J(this,8,0,-9):(this.i&49152||(this.i=this.i&-225|(a&7)<<5,this.g|=1,this.g&=-3),this.a-=5)},kf,mf,Ze,Ze,Ze,Ze],Ef=[He,af,function(){rd(this);this.g|=this.i&16;this.a-=13},ye,Ie,Te,Ve,function(){J(this,8,0,-9)},R,R,R,R,R,R,R,R],Af=[Re,Re,Fe,Fe,ee,ee,fe,fe,bf,bf,R, +R,R,R,Xe,Xe],Bf=[xe,ve,re,te,Ae,Be,ge,he,Ge,$e,of,qf,sf,function(a){1145>this.sa?J(this,8,0,-9):Ff[a>>6&3].call(this,a)},R,R],Ff=[function(){J(this,8,0,-9)},function(a){a=vd(this,a,65536);this.fa(a);qd(this,a);this.a-=11},function(a){var b=sd(this);this.ba=this.a;this.fa(b);wd(this,a,65536,b);this.a=this.ba-Qe[this.h]},function(){J(this,8,0,-9)}]; +function Gf(a){r.call(this,"ROM",a,128);this.ia=this.b=null;this.h=+a.addr;this.a=+a.size;this.i=!1;this.f=a.alias;"string"==typeof this.f&&(this.f=eval(this.f));this.g=a.file;this.l=Fa(this.g);if(this.g){a=this.g;var b=Ga(this.l);"json"!=b&&"hex"!=b&&(a=Pa()+"/api/v1/dump?file="+this.g+"&format=bytes&decimal=true");var c=this;Na(a,null,!0,function(a,b,f){f?(c.G("Unable to load ROM resource (error "+f+": "+a+")"),c.g=null):(na(c.Ua,a,b),(a=Oa(a,b))?(c.b=a.L,c.ia=a.ia):c.g=null);Hf(c)})}}n(Gf,r); +h=Gf.prototype;h.ja=function(a,b,c,d){this.v=b;this.c=c;this.D=d;Hf(this)};h.la=function(){this.ia&&(this.D&&this.D.a(this.id,this.h,this.a,this.ia),delete this.ia);return!0};h.ka=function(){return!0}; +function Hf(a){if(!za(a)){if(a.g){if(!a.b||!a.v)return;a.a||(a.a=a.b.length);if(a.b.length!=a.a){var b="ROM size ("+Ea(a.b.length,8,!0)+") does not match specified size ("+Ea(a.a,8,!0)+")";a.j.error=!0;a.G(b)}else{a:{b=a.h;if(57344<=b&&b<57344+Tb){var c={},c=(c[b]=[Gf.prototype.Zf,Gf.prototype.qh,null,null,null,a.a>>1],c);if(rb(a.v,a,c)){a.status("Added "+a.a+"-byte ROM at "+Da(b));b=a.i=!0;break a}}else if(Zb(a.v,b,a.a,Fc)){for(c=0;c>>f.h;0>>=f.h;0>>a.h;0=b.length)break;for(var l=l+2,p=b[l++]&255|(b[l++]&255)<<8,q=b[l++]&255|(b[l++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=l,y=p-=6;0=b.length)break;m+=b[l++]&255;if(m&255)break;if(y)for(;y--;)hc(a.v,q++,b[v++]&255);else q&1?g=!0:null==d&&(d=q);k=!0}else l++;else l+=2}if(!k&&(null==c&&(c=e),null!=c)){for(e=0;e< +b.length;e++)hc(a.v,c+e,b[e]);k=!0}if(k){if(null==d||g)G(a.c),f=!1;null!=d&&id(a.c,d,f)}return k}Za(function(){for(var a=A(document,z,"ram"),b=0;b=la.hd&&c<=la.Ke&&(b=c-(la.hd-la.Ud));b&&(a.preventDefault&&a.preventDefault(),d.nc(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==la.Wd&&(b=la.Vd);d.nc(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.nc(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1}; +h.ja=function(a,b,c,d){this.A=a;this.v=b;this.c=c;this.D=d;var e=this;this.H=qc(this.c,this.B?-1:48,4,1048576);this.I=nc(this.c,function(){var a;a=-1;e.f.length&&(a=e.f.shift()&255,e.w&&97<=a&&122>a&&(a-=32),pc(e.c,e.I,1E3/Math.round(e.J/10)));0<=a&&(e.m=a,e.a&128?e.m|=49152:e.a|=128,e.a&64&&oc(c,e.H))});this.C=qc(this.c,this.B?-1:52,4,1048576);this.X=nc(this.c,function(){e.b|=128;e.b&64&&oc(c,e.C)});rb(b,this,Of,this.B?64832+8*(this.B-1)-65392:0);tb(b,this.reset.bind(this));B(this)}; +h.Jd=function(a){if(!this.g){var b=Uc(this.A,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ka(c[0]);if(d!=this.ib)return;c=Ka(c[1]);if(this.g=sa(c)){var e=this.g.exports;if(e){var f=e.connect;f&&f.call(this.g,this.u);if(this.s=e.receiveData){this.u=a;this.F=e.receiveStatus;this.status("Connected "+this.Ua+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};h.la=function(a,b){if(!b)if(this.Jd(this.u),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +h.ka=function(a){return a?this.save():!0};h.reset=function(){Pf(this)};h.save=function(){var a=new E(this);a.set(0,[this.m,this.a,this.b,this.f]);return a.data()};h.restore=function(a){return Pf(this,a[0])};function Pf(a,b){b||(b=[0,8192,128,a.f]);b=ia(b);a.m=b.next().value;a.a=b.next().value;a.b=b.next().value;a.f=b.next().value;return!0} +h.nc=function(a){if("number"==typeof a)this.f.push(a);else if("string"==typeof a)for(var b=0,c,d=0;d":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.S||8,c=a-this.l%a,this.S&&(b=" ".slice(0,c)));this.K&&!this.l&&c&&(b=String.fromCharCode(this.K)+b);this.h.value+=b;this.h.scrollTop=this.h.scrollHeight;this.l+=c}}else if(null!= +this.i){if(10==a||1024<=this.i.length)this.aa(this.i),this.i="";10!=a&&(this.i+=String.fromCharCode(a))}pc(this.c,this.X,1E3/Math.round(this.ba/10));this.b&=-129};var Nf="buffer",Qf={},Of=(Qf[65392]=[null,null,Mf.prototype.Mf,Mf.prototype.dh,"RCSR"],Qf[65394]=[null,null,Mf.prototype.Lf,Mf.prototype.bh,"RBUF"],Qf[65396]=[null,null,Mf.prototype.sg,Mf.prototype.Kh,"XCSR"],Qf[65398]=[null,null,Mf.prototype.rg,Mf.prototype.Jh,"XBUF"],Qf); +Za(function(){for(var a=A(document,z,"serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.o[b]=c,!0;case "readTape":e=Uf;case "loadTape":return e||(e=Vf),this.o[b]=c,c.onclick= +function(){var a=d.o.listTapes;a&&Wf(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.addEventListener("change",function(){var a=c.children[0];a.children[1].disabled=!a.children[0].files.length});c.onsubmit=function(a){if(a=a.currentTarget[1].files[0]){var b=a.name;Wf(d,Fa(b,!0),b,Vf,a)}return!1};return!0;case Xf:return this.o[b]=c,!0}return!1}; +h.ja=function(a,b,c,d){this.A=a;this.v=b;this.c=c;this.D=d;this.u=Yf(a);var e=this;if(a=Rf(this,Uc(this.A,"autoMount")))for(var f in a)"PTR"==f&&(this.C[f]=a[f]);this.s=qc(this.c,56,4,4096);this.J=nc(this.c,function(){1!=(e.a&32769)||e.a&128||(e.hc.indexOf("/api/v1/dump")&&(e=Ga(c),f="json"==e||"gz"==e?encodeURI(c):Pa()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!Na(f,null,!0,function(e,f,g){var k=0>g&&!!a.A&&!a.A.j.R;g?a.G('Unable to load tape "'+b+'" (error '+g+": "+e+")",k):(na(a.Ua,e,f),(e=Oa(e,f))&&ig(a,b,c,d, +e.L,e.ea,e.da));a.j.Ra=!1;a.b&&(a.b--,a.b||B(a));fg(a)})}function ag(a,b,c,d){if((a=a.o.listTapes)&&a.options){for(var e=0;e>2;var f=e=0,b=new DataView(b,0,d);a.a=Array(a.M);for(d=0;dc.indexOf("/api/v1/dump")&&(b=Ga(c),"json"==b||"gz"==b?f=encodeURI(c):(d="path",e="&mbhd=10",!c.indexOf("http:")||!c.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(b)?(d="disk",e="&mbhd=0"):Ha(c,"/")&&(d="dir"),f=Pa()+"/api/v1/dump?"+d+"="+encodeURIComponent(c)+(a.Yc?"":e)+"&format=json"));return!!Na(f, +null,!0,function(b,c,d){qg(a,b,c,d)})} +function qg(a,b,c,d){var e=null,f=0>d&&!!a.A&&!a.A.j.R;a.g=!1;if(d)a.controller.G('Unable to load disk "'+a.xa+'" (error '+d+": "+b+")",f);else{na(a.controller.Ua,b,c);try{if(0g&&0c.indexOf("0x")&&'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+ +c+")");if(k.length)if(1==k.length)u(k[0]);else{a.M=k.length;a.T=k[0].length;a.P=k[0][0].length;var l=k[0][0][0];a.Z=l&&l.length||512;for(d=c=0;d>2,p=l.pattern;void 0===p&&(p=l.pattern=0);var q=l.data;if(void 0===q){var v=l.bytes;if(void 0!==v&&v.length){for(var y=m<<2,ma=v.length;ma>2,e=Array(d),f=0;f>2,c=(d>((b&3)<<3)&255;return c};h.write=function(a,b,c){if(this.g)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.na?f=a.wa+a.na&&(a.na+=f-(a.wa+a.na)+1):(a.wa=f,a.na=1);d[f]=d[f]&~(255<g)break;e|=g<=this.a.length||l>=this.a[k].length||m>=this.a[k][l].length){c="sector (CHS="+k+":"+l+":"+m+") out of range ("+ +b+" changes applied)";b=-1;break}if(this.g){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(k=this.a[k][l][m]){for(l=k.data.length;lb&&-2!=b&&this.controller.G("Unable to restore disk '"+this.xa+": "+c);return b}; +h.toJSON=function(){var a;a=0;for(var b;b=sg(this,a++);)ug(b);a=JSON.stringify(this.a,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/gm,"").replace(/,"pattern":0/gm,"");a=a.replace(/"(sector|length|data|pattern)":/gm,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/gm,"");a=a.replace(/(sector|length|data|pattern):/gm,'"$1":');return a=a.replace(/([\]}]),/gm,"$1,\n")}; +function ug(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var mg=0;function vg(a,b,c,d,e,f){r.call(this,a,b,c);this.C=wg(this,b.autoMount);this.B=0;this.I=d;this.J=e;this.K=f;this.H=d.Bc;this.b=Array(this.H);this.F=!Va("Mobi")&&window&&"FileReader"in window;this.l=[];this.qa=null;this.exports={bootDisk:this.Ed,loadDisk:this.Zc,selectDrive:this.wg,wait:this.Cg}}n(vg,r); +function wg(a,b){if(b&&"string"==typeof b)try{b=eval("("+b+")")}catch(c){u(a.type+" auto-mount error: "+c.message+" ("+b+")"),b=null}return b||{}}h=vg.prototype; +h.ma=function(a,b,c){var d=this;switch(b){case "listDisks":return this.o[b]=c,c.onchange=function(){xg(d)},!0;case "descDisk":case "listDrives":return this.o[b]=c,c.onchange=function(){var a=Ba(c.value,10);null!=a&&yg(d,a)},!0;case "loadDisk":return this.o[b]=c,c.onclick=function(){d.Zc()},!0;case "bootDisk":return this.o[b]=c,c.onclick=function(){d.Ed()},!0;case "saveDisk":if(!this.F){c.parentNode.removeChild(c);break}this.o[b]=c;c.onclick=function(){var a=d.o.listDrives;if(a&&a.options&&d.b)if(a= +d.b[Ba(a.value,10)||0])if(a=a.O){var b;b="";for(var c=0,k;k=sg(a,c++);)for(var l=0,m=k.length;lg||9d||d>=this.b.length)return this.G("Unable to load the selected drive"),!1;if(!b)return Eg(this,d),!0;if(b==Bg)return this.G('Use "Choose File" and "Mount" to select and load a local disk.'),!1;if(b==Cg){b=window.prompt("Enter the URL of a remote disk image.","")||"";if(!b)return!1;a=Fa(b);this.status("Attempting to load "+b+' as "'+ +a+'"')}Ig(this,d,a,b,!1,c);return!0};h.Ed=function(){var a,b=this.o.listDrives,b=b&&Ba(b.value,10);if(null==b||0>b||b>=this.b.length||!(a=this.b[b]))return this.G("Unable to boot the selected drive"),!1;if(!a.O)return this.G("Load a disk into the drive first"),!1;id(this.c,0,!0,b);return(a=this.ub(a,a.Xe,a.Ye,a.Ze,a.Oe,0,2))?(this.G("Unable to read the boot sector ("+a+")"),!1):!0}; +function Ig(a,b,c,d,e,f){var g=-1,k=a.b[b];k.oa.toLowerCase()!=d.toLowerCase()&&(g++,Eg(a,b,!0),k.hc?a.G(a.type+" busy"):(k.hc=!0,e&&(k.Xc=!0,a.B++),k.qb=!!f,pg(new lg(a,k,"preload"),c,d,f,a.Gd)&&g++));return g} +h.Gd=function(a,b,c,d,e){a.hc=!1;b&&(b.M>a.M||b.T>a.T)&&(this.G('Disk "'+c+'" too large for drive '+(this.b[a.rb].oc||"---")),b=null);b?(a.O=b,a.xa=c,a.oa=d,this.Ld(a.rb),Jg(this,c,d,b),this.G('Loaded disk "'+c+'" in drive '+(this.b[a.rb].oc||"---"),a.Xc||e),this.A&&ad(this.A)):a.qb=!1;a.Xc&&(a.Xc=!1,--this.B||B(this));yg(this,a.rb);a.Jb&&(a.Jb(),a.Jb=null)}; +function zg(a,b,c,d){if((a=a.o.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}h.Cg=function(a){for(var b=0;b=a.M){m=T.Zb;break}p=a.seek(b,c,d+1);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}var v,y;if(0>(v=a.read(p,q++))||0>(y=a.read(p,q++))){m=T.$b;break}if(!k&&(Nb(this.v,td(this.c,f),v|y<<8),mc(this.v))){m=T.Eb;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.vc=function(a,b,c,d,e,f,g,k,l){var m=0;a=a.O;var p=null,q;a||(m=T.rd,e=0);for(;e;){var v=Pb(this.v,td(this.c,f));if(mc(this.v)){m=T.Eb;break}if(!p){if(b>=a.M){m=T.Zb;break}p=a.seek(b,c,d+1,!0);if(!p){m=T.Ad;break}q=0;++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b))}if(k){var y,ma;if(0>(y=a.read(p,q++))||0>(ma=a.read(p,q++))){m=T.$b;break}if(v!=(y|ma<<8)){m=T.Cd;break}}else if(!a.write(p,q++,v&255)||!a.write(p,q++,v>>8)){m=T.$b;break}q>=a.Z&&(p=null);f+=g;e--}return l?l(m,b,c,d,e,f):m}; +h.me=function(a,b,c,d,e,f){this.h=f&65535;this.a=this.a&~S.fb|f>>16-S.V.fb&S.fb;this.i=65536-e&65535;this.g=this.g&~Ng.Rc|d&Ng.Rc;this.f|=a;Og(this);return!0};function Og(a){a.a&=~S.Ja;a.f&&(a.f|=T.Yd,a.a|=S.Ja,a.f&T.Hc&&(a.a|=S.Hc))}h.Rf=function(){return this.s};h.ih=function(){};h.Sf=function(){return this.f};h.jh=function(){};h.Of=function(){return this.a&S.Fb}; +h.fh=function(a){this.a=this.a&~S.va|a&S.va;if(this.a&S.Db){a=!0;var b,c,d=(this.g&Ng.Ta)>>Ng.V.Ta,e=this.b[d],f,g,k,l,m,p;this.a&=~(S.za|S.Sc);this.f&=~T.Ce;switch(c=this.a&S.ca){case Pg.Td:this.f=this.g=0;this.a=S.za;break;case Pg.he:case Pg.Va:b=this.ub;case Pg.Vc:case Pg.Hb:b||(b=this.vc);f=(this.g&Ng.Bb)>>Ng.V.Bb;g=(this.g&Ng.Kc)>>Ng.V.Kc;k=this.g&Ng.Rc;l=65536-this.i&65535;m=(this.a&S.fb)<<16-S.V.fb|this.h;p=this.a&S.de?0:2;if(f>=e.M){this.f|=T.Zb;break}if(k>=e.P){this.f|=T.$b;break}a=b.call(this, +e,f,g,k,l,m,p,c>=Pg.Vc,this.me.bind(this));break;case Pg.ec:f=(this.g&Ng.Bb)>>Ng.V.Bb;f(p=a.read(k,m++))||0>(q=a.read(k,m++))){g=Sg.Ba;break}Nb(this.v,td(this.c,f),p|q<<8);if(mc(this.v)){g=Sg.Eb;break}f+=2;e--;if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.M)))){g=Sg.Ba;break}}return l?l(g,b,c,d,e,f):g}; +h.vc=function(a,b,c,d,e,f,g,k,l){g=0;a=a.O;k=null;var m;a||(g=Sg.Ba,e=0);for(;e;){var p=Pb(this.v,td(this.c,f));if(mc(this.v)){g=Sg.Eb;break}f+=2;e--;if(!k){k=a.seek(b,c,d+1,!0);if(!k){g=Sg.Ba;break}m=0}if(!a.write(k,m++,p&255)||!a.write(k,m++,p>>8)){g=Sg.Ba;break}if(m>=a.Z&&(k=null,++d>=a.P&&(d=0,++c>=a.T&&(c=0,++b>=a.M)))){g=Sg.Ba;break}}return l?l(g,b,c,d,e,f):g}; +h.re=function(a,b,c,d,e,f){this.m=f&65535;this.a=this.a&~U.ya|f>>16-U.V.ya&U.ya;this.h=f>>16&Tg.Fa;this.g=this.f=b<>U.V.ya;if(!(this.a&U.za)){a=!0;var b,c=this.b[(this.a&U.Ta)>>U.V.Ta],d=c.O,e,f,g;this.a&=~U.ha;switch(this.a&U.ca){case Ug.Ge:this.i&Vg.md&&(this.a&=U.ha|U.ca|U.ya);this.i=c.status|this.g&V.dc|(d&&512==d.M?Vg.ae:0);break;case Ug.ec:(this.f&V.$d)==V.De&&(b=this.f&V.Gb,c=(this.f&V.Fe)<<2,this.g=this.f&V.Ee?this.g+b:this.g-b,this.f=this.g=this.g&V.Gb|c);break;case Ug.le:this.i=this.g;break;case Ug.ie:b=this.ub;case Ug.Je:b||(b=this.vc), +e=this.f>>V.V.Gb,f=this.f&V.dc?1:0,g=this.f&V.yd,!d||e>=d.M||g>=d.P?this.a=this.a|Sg.Ba|U.Ja:(a=65536-this.i&65535,d=(this.h&Tg.Fa)<<16|this.m,a=b.call(this,c,e,f,g,a,d,2,!1,this.re.bind(this)))}a&&(this.a=this.a|U.ha|U.za,this.a&U.eb&&oc(this.c,this.qa))}};h.Uf=function(){return this.m};h.lh=function(a){this.m=a&Wg.va};h.Xf=function(){return this.f};h.oh=function(a){this.f=a};h.Yf=function(){return this.i};h.ph=function(a){this.i=a};h.Vf=function(){return this.h}; +h.mh=function(a){this.h=a&Tg.Fa;this.a=this.a&~U.ya|(this.h&3)<=m.M){k=Y.fe;break}p=m.seek(b,c,d+1);if(!p){k=Y.Pc;break}q=0;++d>=m.P&&(d=0,++c>=m.T&&(c=0,++b))}var v;if(0>(a=m.read(p,q++))||0>(v=m.read(p,q++))){k=Y.Oc;break}Nb(this.v,td(this.c,f),a|v<<8);q>=m.Z&&(p=null);f+=g;e--}return l?l(k,b,c,d,e,f):k}; +function Zg(a){var b=0,c=a.a&X.Tc?1:0,d=a.b[c],d=d&&d.O,e=a.u&ah.Fa,f=a.s&bh.Fa;a.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(d)if(a.f|=Z.ha,c=d.seek(e,0,f,!0)){e=0;for(f=a.h.length;eg){b=Y.Oc;break}a.h[e++]=g}c.Re&&(a.f|=Z.Cb)}else b=Y.Pc;else b=c?Y.Jc:Y.Ic;$g(a,b)}h.$f=function(a,b){a=this.a;if(!b)switch(a&=X.Fb,this.g){case W.Ec:case W.EMPTY:this.ithis.i&&(this.a|=X.Ga)}return a}; +h.rh=function(a){this.a=this.a&~X.va|a&X.va;if(this.a&X.INIT)this.bb();else if(this.a&X.Db&&this.g==W.gb)switch(this.g=this.a&X.ca,this.a&=~(X.Db|X.Ga|X.DONE|X.Ja),(a=this.qa)&&sc(this.c,a),this.g){case W.Ec:case W.EMPTY:case W.Va:case W.Hb:case W.fc:this.i=0;break;case W.ke:a=this.b[this.a&X.Tc?1:0];this.f&=~Z.ha;a&&a.O&&(this.f|=Z.ha);this.m=this.f;$g(this);break;case W.je:this.m=this.w,$g(this)}else this.a&X.eb?this.a&X.DONE&&oc(this.c,this.qa):(a=this.qa)&&sc(this.c,a)}; +h.ag=function(a,b){if(!b)switch(this.g){case W.EMPTY:this.a&X.Ga&&(this.a&=~X.Ga,this.m=this.h[this.i]&255,++this.i>=this.h.length&&$g(this))}return this.m}; +h.sh=function(a){switch(this.g){case W.Ec:this.a&X.Ga&&(this.a&=~X.Ga,this.h[this.i]=a&255,++this.i>=this.h.length&&$g(this));break;case W.Va:case W.Hb:case W.fc:if(this.a&X.Ga)switch(this.a&=~X.Ga,this.i++){case 0:this.s=a;break;case 1:if(this.u=a,this.g==W.Va)Zg(this);else{var b=this.g==W.fc,c=0,d=this.a&X.Tc?1:0,e=this.b[d],e=e&&e.O,f=this.u&ah.Fa,g=this.s&bh.Fa;this.f&=~(Z.jd|Z.ud|Z.Cb|Z.ha);if(e)if(this.f|=Z.ha,d=e.seek(f,0,g,!0))for(b&&(d.Re=!0),b=0,f=this.h.length;b\nLicense: GPL version 3 or later ");this.aa("Portions adapted from the PDP-11/70 Emulator by Paul Nankervis ");for(b=0;bgh){if(hh(d,this.s)){this.h=new E(this,"1.34.1",rh);hh(this.h)&&(sh(this,d),a=th,uh(this.h));this.h.set(mh,Ma());vh(this.h);var e=this.a&&!this.m;if(a==nh||qa("Click OK to restore the previous "+hb+" machine state, or CANCEL to reset the machine.")){if(c=lh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?hh(d,g):("error"==f&&"no machine state"!= +g?(this.G("Error: "+g),"unable to verify user"==g&&(Ua(wh,""),this.b=null)):this.aa(f+": "+g),uh(d),hh(d)?(c=lh(d),e=!0):c=!1))}e&&jh(this,c?d:null)}else a==th&&d.clear()}else jh(this);delete this.s;delete this.l}e=ra(this.id);for(f=0;fa[1];a=a[2];this.H=!0;this.j.R=!0;var d=this.o.power;d&&(d.textContent="Shutdown");this.c&&(xh(this,this.c,b,c,a),Lb(this,-2),this.c.Y());this.C&&(sh(this,b),b.clear());!c&&this.h&&(this.h.clear(),delete this.h);this.g=0}; +function sh(a,b){if(qa("There may be a problem with your "+hb+" machine.\n\nTo help us diagnose it, click OK to send this "+hb+" machine state to http://www.pcjs.org.")){var c=a.K;a=a.b||"";b=b.toString();var d={};d.app=hb;d.ver="1.34.1";d.url=c;d.user=a;d.type="bug";d.data=b;Na("http://www.pcjs.org/api/v1/report",d,!0)}} +function yh(a,b,c){var d,e="none";if(a.g)return null;a.g--;var f=new E(a,"1.34.1"),g=new E(a,"1.34.1",kh),k=Ma();g.set(mh,k);f.set(mh,k);f.set(zh,"1.34.1");f.set(Ah,window?window.location.href:null);f.set(Bh,window?window.navigator.userAgent:"");a.c&&a.c.ka&&(c&&(b&&(a.c.j.Y=a.c.j.N),G(a.c)),d=a.c.ka(b,c),"object"===typeof d&&f.set(a.c.id,d),c&&(a.c.j.R=!1,!1===d&&(e=null)));for(var k=ra(a.id),l=0;l=d||30<=(c.fd+=d))&&(e.textContent=c.j.N?c.Wa.toFixed(2)+"Mhz":"Stopped",c.fd=0)}if(a.f&&(a=a.f,b=b||0,a.l)){c=a.c.j.N;d=!!(a.c.g&8);if(0>=b||60<=(a.i+=b)){for(e=0;eb?a.U=a.c.b[7]:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,"$1PDPjs$2"), +a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(q){g=null,a=q.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Na(e,null,!0,function(f,g,k){if(k||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+k+")");else{if(f=d[3])if(k=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var l=k[0],m,p=/( [a-z]+=)(['"])(.*?)\2/g;m=p.exec(f);)l=0>l.indexOf(m[1])?l.replace(">",m[0]+">"):l.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);k[0]!=l&&(g=g.replace(k[0],l))}else{c(a,"missing <"+d[1]+"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/, +"");a=a.replace(d[0],g);Jh(a,b,c)}})}else c(a,null)} +function Kh(a,b,c,d,e){function f(a){if(void 0===l){var b=k&&A(k,"machine-warning");l=b&&b[0]||k}l&&(l.innerHTML=Ia(a))}function g(a){f("Error: "+a);m&&(--Gh||cb(!0));m=!1}var k,l,m=!0;Gh++;oa[b]={};try{if(k=document.getElementById(b)){var p;if("object"==typeof resources&&(p=resources.css)){var q=document.head||document.getElementsByTagName("head")[0],v=document.createElement("style");v.type="text/css";v.styleSheet?v.styleSheet.cssText=p:v.appendChild(document.createTextNode(p));q.appendChild(v)}d|| +(p=a,"pdp"==a.substr(0,3)&&(p="pdpjs"),d="/versions/"+p+"/1.34.1/components.xsl");p=function(e,l){l?Hh(d,null,a,null,!1,f,function(a,e){e?(na(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=l.transformNode(e))?(k.outerHTML=e,--Gh||cb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(l,document))?k.parentNode?(k.parentNode.replaceChild(e,k),--Gh|| +cb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Hh(c,b,a,e,!0,f,p):Ih(c,null,b,a,e,!1,f,p)}else g("missing machine element: "+b)}catch(y){g(y.message)}return m}window.embedPDP10=function(a,b,c,d){cb(!1);return Kh("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){cb(!1);return Kh("pdp11",a,b,c,d)};window.findMachineComponent=function(a,b){return ta(b,a+".machine")}; +window.processMachineScript=function(a,b){var c=!1;a+=".machine";if("string"==typeof b&&!va[a]){for(var c=!0,d=va,e=a,f=b.length,g=[],k=[],l="",m=null,p=0;p