diff --git a/modules/pdp11/lib/cpu.js b/modules/pdp11/lib/cpu.js index d7b77c4b7..19f43c6b9 100644 --- a/modules/pdp11/lib/cpu.js +++ b/modules/pdp11/lib/cpu.js @@ -530,7 +530,7 @@ CPUPDP11.prototype.addCycles = function(nCycles, fEndStep) { this.nTotalCycles += nCycles; if (fEndStep) { - this.nBurstCycles = this.nStepCycles = 0; + this.nBurstCycles = this.nStepCycles = this.nSnapCycles = 0; } }; @@ -643,7 +643,7 @@ CPUPDP11.prototype.resetCycles = function() { this.mhz = 0; this.nYieldsSinceStatusUpdate = 0; - this.nTotalCycles = this.nRunCycles = this.nBurstCycles = this.nStepCycles = 0; + this.nTotalCycles = this.nRunCycles = this.nBurstCycles = this.nStepCycles = this.nSnapCycles = 0; this.resetChecksum(); this.setSpeed(1); }; @@ -1019,7 +1019,13 @@ CPUPDP11.prototype.updateTimers = function(nCycles) CPUPDP11.prototype.endBurst = function(fReset) { var nCycles = this.nBurstCycles -= this.nStepCycles; - this.nStepCycles = 0; + /* + * In addition to zeroing nStepCycles, it's important that we also zero nSnapCycles, because if a CPU + * burst is being ended after nStepCycles has been "snapped" (because a certain opcode has an unusual timing + * calculation that must be based on a "snapped" cycle count rather the opcode's starting cycle count), we + * could inadvertently undo the endBurst() if the original "snapped" value was used to update nStepCycles. + */ + this.nStepCycles = this.nSnapCycles = 0; if (fReset) this.nBurstCycles = 0; return nCycles; }; @@ -1190,7 +1196,6 @@ CPUPDP11.prototype.yieldCPU = function() { this.endBurst(); // this will break us out of stepCPU() this.nCyclesNextYield = 0; // this will break us out of runCPU(), once we break out of stepCPU() - // if (DEBUG) this.nSnapCycles = this.nBurstCycles; /* * The Debugger calls yieldCPU() after every message() to ensure browser responsiveness, but it looks * odd for those messages to show CPU state changes if the Control Panel, Video display, etc, does not, diff --git a/modules/pdp11/lib/cpuops.js b/modules/pdp11/lib/cpuops.js index a4981ddc8..8ed5ddac6 100644 --- a/modules/pdp11/lib/cpuops.js +++ b/modules/pdp11/lib/cpuops.js @@ -1191,9 +1191,9 @@ PDP11.opJMP = function(opCode) * Since JMP and JSR opcodes have their own unique timings for the various dst modes, we must snapshot * nStepCycles before decoding the mode, and then use that to update nStepCycles. */ - var nSnapCycles = this.nStepCycles; + this.nSnapCycles = this.nStepCycles; this.setPC(this.readDstAddr(opCode)); - this.nStepCycles = nSnapCycles - PDP11.JMP_CYCLES[this.dstMode]; + this.nStepCycles = this.nSnapCycles - PDP11.JMP_CYCLES[this.dstMode]; }; PDP11.JSR_CYCLES = [ @@ -1212,7 +1212,7 @@ PDP11.opJSR = function(opCode) * Since JMP and JSR opcodes have their own unique timings for the various dst modes, we must snapshot * nStepCycles before decoding the mode, and then use that to update nStepCycles. */ - var nSnapCycles = this.nStepCycles; + this.nSnapCycles = this.nStepCycles; /* * TODO: Determine whether or not the SRCMODE operand (regsGen[reg]) should be snapped BEFORE or AFTER we * decode the DSTMODE operand. Doing it AFTER seems a bit risky. @@ -1222,7 +1222,7 @@ PDP11.opJSR = function(opCode) this.pushWord(this.regsGen[reg]); this.regsGen[reg] = this.getPC(); this.setPC(addr); - this.nStepCycles = nSnapCycles - PDP11.JSR_CYCLES[this.dstMode]; + this.nStepCycles = this.nSnapCycles - PDP11.JSR_CYCLES[this.dstMode]; }; /** @@ -1287,9 +1287,9 @@ PDP11.opMOV = function(opCode) * nStepCycles after decoding the src mode, and then use that to update nStepCycles. */ var data = this.readSrcWord(opCode); - var nSnapCycles = this.nStepCycles; + this.nSnapCycles = this.nStepCycles; this.updateNZVFlags(this.writeDstWord(opCode, data)); - this.nStepCycles = nSnapCycles - PDP11.MOV_CYCLES[(this.srcMode? 8 : 0) + this.dstMode] + (this.dstReg == 7 && !this.dstMode? 2 : 0); + this.nStepCycles = this.nSnapCycles - PDP11.MOV_CYCLES[(this.srcMode? 8 : 0) + this.dstMode] + (this.dstReg == 7 && !this.dstMode? 2 : 0); }; /** @@ -1322,10 +1322,10 @@ PDP11.opMTPD = function(opCode) * nStepCycles before decoding the mode, and then use that to update nStepCycles. */ var data = this.popWord(); - var nSnapCycles = this.nStepCycles; + this.nSnapCycles = this.nStepCycles; this.writeWordToPrevSpace(opCode, PDP11.ACCESS.DSPACE, data); this.updateNZVFlags(data); - this.nStepCycles = nSnapCycles - PDP11.MTP_CYCLES[this.dstMode]; + this.nStepCycles = this.nSnapCycles - PDP11.MTP_CYCLES[this.dstMode]; }; /** @@ -1341,10 +1341,10 @@ PDP11.opMTPI = function(opCode) * nStepCycles before decoding the mode, and then use that to update nStepCycles. */ var data = this.popWord(); - var nSnapCycles = this.nStepCycles; + this.nSnapCycles = this.nStepCycles; this.writeWordToPrevSpace(opCode, PDP11.ACCESS.ISPACE, data); this.updateNZVFlags(data); - this.nStepCycles = nSnapCycles - PDP11.MTP_CYCLES[this.dstMode]; + this.nStepCycles = this.nSnapCycles - PDP11.MTP_CYCLES[this.dstMode]; }; /** @@ -1497,7 +1497,7 @@ PDP11.opRTS = function(opCode) var src = this.popWord(); var reg = opCode & PDP11.OPREG.MASK; /* - * When the popular "RTS PC" form is used, we might as well eliminate the useless setting of PC to itself. + * When the popular "RTS PC" form is used, we might as well eliminate the useless setting of PC to */ if (reg == PDP11.REG.PC) { this.setPC(src); diff --git a/modules/pdp11/lib/debugger.js b/modules/pdp11/lib/debugger.js index 7ab98eba1..1caa0a596 100644 --- a/modules/pdp11/lib/debugger.js +++ b/modules/pdp11/lib/debugger.js @@ -2091,7 +2091,8 @@ if (DEBUGGER) { /* * If getOperand() returns an Array rather than a string, then the first element is the original - * operand, and the second element contains an alternate representation of the operand (eg, target address). + * operand, and the second element contains an alternate representation of the operand (eg, target address, + * memory contents, etc). */ if (typeof sOperand != "string") { sTarget = sOperand[1]; @@ -2134,6 +2135,10 @@ if (DEBUGGER) { * 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 an alternate representation of the operand. * + * TODO: For PC-relative addresses, we now return the effective address directly, rather than as the + * second element of an Array; however, I still envision using Array return values to include current + * memory operands, so support for such values is being left in place. + * * @this {DebuggerPDP11} * @param {number} opCode * @param {number} opType @@ -2229,9 +2234,20 @@ if (DEBUGGER) { sOperand = this.toStrBase(wIndex, 0, true) + '(' + this.getRegName(reg) + ')'; if (reg == 7) { /* - * When using R7 (aka PC), INDEX is known as RELATIVE + * When using R7 (aka PC), INDEX is known as RELATIVE. However, instead of displaying + * such an instruction like this: + * + * 016156: 010167 001300 MOV R1,1300(PC) ; @017462 + * + * with the effective address display to the far right, let's display it like this instead: + * + * 016156: 010167 001300 MOV R1,017462 + * + * because you can still clearly see PC-relative offset (eg, 001300) as part of the disassembly. + * + * sOperand = [sOperand, this.toStrBase((wIndex + dbgAddr.addr) & 0xffff)]; */ - sOperand = [sOperand, this.toStrBase((wIndex + dbgAddr.addr) & 0xffff)]; + sOperand = this.toStrBase((wIndex + dbgAddr.addr) & 0xffff); } break; case PDP11.OPMODE.INDEXD: // 0x7: INDEX DEFERRED @@ -2239,9 +2255,12 @@ if (DEBUGGER) { sOperand = '@' + this.toStrBase(wIndex) + '(' + this.getRegName(reg) + ')'; if (reg == 7) { /* - * When using R7 (aka PC), INDEX DEFERRED is known as RELATIVE DEFERRED + * When using R7 (aka PC), INDEX DEFERRED is known as RELATIVE DEFERRED. And for the same + * reasons articulated above, we now display the effective address inline. + * + * sOperand = [sOperand, this.toStrBase((wIndex + dbgAddr.addr) & 0xffff)]; */ - sOperand = [sOperand, this.toStrBase((wIndex + dbgAddr.addr) & 0xffff)]; + sOperand = '@' + this.toStrBase((wIndex + dbgAddr.addr) & 0xffff); } break; default: diff --git a/versions/pdpjs/1.30.1/pdp11-dbg.js b/versions/pdpjs/1.30.1/pdp11-dbg.js index c67fc0eff..9ec798b91 100644 --- a/versions/pdpjs/1.30.1/pdp11-dbg.js +++ b/versions/pdpjs/1.30.1/pdp11-dbg.js @@ -35,220 +35,219 @@ function ua(a,b){return(a+" ").slice(0,b) function ya(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 Ba(a,b,c,d){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="",p;for(p in b)b.hasOwnProperty(p)&&(m&&(m+="&"),m+=p+"="+encodeURIComponent(b[p]));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 Ca(a,b){var c,d={ka:null,fa: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.ka=e;else if(e=g.words)for(d.ka=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)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 d.ka=g;d.fa=g.symbols;d.ka.length?1==d.ka.length&&(n(d.ka[0]),d=null):(n("Empty resource: "+a),d=null)}catch(h){n("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.Ia=g.load;d.Ha=g.exec;if(e=g.bytes)d.la=e;else if(e=g.words)for(d.la=Array(2*e.length),f=c=0;c>8&255;else if(e=g.data)for(d.la=Array(4*e.length),f=c=0;c>8&255,d.la[f++]=e[c]>>16&255,d.la[f++]=e[c]>>24&255;else d.la=g;d.fa=g.symbols;d.la.length?1==d.la.length&&(n(d.la[0]),d=null):(n("Empty resource: "+a),d=null)}catch(h){n("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb?this.Za=this.id:(this.Sa=this.id.substr(0,b),this.Za=this.id.substr(b+1));this[a]=c;this.v={ready:!1,Ja:!1,Kb:!1,ja:!1,error:!1};this.Bb=null;this.v.error=!1;this.I={};this.i=null;this.ma=d||0;t.push(this)}var cb=void 0,db={}; +function r(a,b,c,d){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.Xb=b.comment;this.uc=b;b=this.id.indexOf(".");0>b?this.$a=this.id:(this.Sa=this.id.substr(0,b),this.$a=this.id.substr(b+1));this[a]=c;this.v={ready:!1,Ja:!1,Kb:!1,ja:!1,error:!1};this.Cb=null;this.v.error=!1;this.I={};this.i=null;this.ma=d||0;t.push(this)}var cb=void 0,db={}; if(window){cb||(cb=window.location.search.substr(1));for(var eb,fb=/\+/g,gb=/([^&=]+)=?([^&]*)/g;eb=gb.exec(cb);)db[decodeURIComponent(eb[1].replace(fb," "))]=decodeURIComponent(eb[2].replace(fb," "))}function hb(a){function b(){}if(window){if(!a)throw new TypeError;if(Object.create)return Object.create(a);var c=typeof a;if("object"!==c&&"function"!==c)throw new TypeError;}b.prototype=a;return new b} function u(a,b){b||(b=r);a.prototype=hb(b.prototype);a.prototype.constructor=a;a.prototype.parent=b.prototype}if(window){window.PCjs||(window.PCjs={});var ib=window.PCjs.Machines||(window.PCjs.Machines={}),t=window.PCjs.Components||(window.PCjs.Components=[])}else ib={},t=[];function jb(a,b,c){ib[a]&&b&&(ib[a][b]=c)}function kb(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>2;this.A=this.ta-1;this.D=this.H/this.ta|0;this.Ga=[];this.f=0;this.w=[];this.mc=[Ob,Pb,Qb,Rb];a=new I(this);Sb(a,this.i);this.V=Array(this.D);for(b=0;b>2;this.A=this.ua-1;this.D=this.H/this.ua|0;this.Ga=[];this.f=0;this.w=[];this.nc=[Ob,Pb,Qb,Rb];a=new I(this);Sb(a,this.i);this.V=Array(this.D);for(b=0;b>8:e[2](b)&255):b&1&&(e=d.Ga[a&-2])&&e[2]&&(c=e[2](b&-2)>>8);if(0<=c)return this.i&&E(this.i,64)&&D(this.i,e[4]+".readByte("+J(this.i,b)+"): "+J(this.i,c),!0,!0),c;c=Ub(d,b,!0);this.i&&E(this.i,64)&&D(this.i,"warning: unconverted read access to byte @"+J(this.i,b)+": "+J(this.i,c),!0,!0);return c} function Pb(a,b,c){var d=!1,e=this.controller,f=e.Ga[a];if(f)if(f[1])f[1](b,c),d=!0;else{if(f[3]){a=f[2]?f[2](0):0;if(c&1)f[3](a&255|b<<8,c&-2);else f[3](a&-256|b,c);d=!0}}else c&1&&(f=e.Ga[a&-2])&&f[3]&&(c&=-2,a=f[2]?f[2](0):0,f[3](a&255|b<<8,c),d=!0);d?this.i&&E(this.i,64)&&D(this.i,f[4]+".writeByte("+J(this.i,c)+","+J(this.i,b)+")",!0,!0):(Ub(e,c,!0,b),this.i&&E(this.i,64)&&D(this.i,"warning: unconverted write access to byte @"+J(this.i,c)+": "+J(this.i,b),!0,!0))} function Qb(a,b){var c=-1,d=this.controller;(a=d.Ga[a])&&(a[2]?c=a[2](b):a[0]&&(c=a[0](b)|a[0](b+1)<<8));if(0<=c)return this.i&&E(this.i,64)&&D(this.i,a[4]+".readWord("+J(this.i,b)+"): "+J(this.i,c),!0,!0),c;c=Ub(d,b,!1);this.i&&E(this.i,64)&&D(this.i,"warning: unconverted read access to word @"+J(this.i,b)+": "+J(this.i,c),!0,!0);return c} function Rb(a,b,c){var d=!1,e=this.controller;if(a=e.Ga[a])a[3]?(a[3](b,c),d=!0):a[1]&&(a[1](b&255,c),a[1](b>>8,c+1),d=!0);d?this.i&&E(this.i,64)&&D(this.i,a[4]+".writeWord("+J(this.i,c)+","+J(this.i,b)+")",!0,!0):(Ub(e,c,!1,b),this.i&&E(this.i,64)&&D(this.i,"warning: unconverted write access to word @"+J(this.i,c)+": "+J(this.i,b),!0,!0))} function Vb(a,b){if(b!=a.B){var c;a.B&&(c=(1<>>a.ha;0g&&(q=g);if(!e&&m&&m.size){if(m.type==d){if(f+g<=m.C)return m.xb+=m.C-f,m.C=f,!0;if(f>=m.C+m.xb){q=m.size-(f-p);q>g&&(q=g);m.xb=f-m.C+q;f=p+a.ta;g-=q;h++;continue}}return ac(1,f,g)}f=new I(a,f,q,a.ta,d,e);Sb(f,a.i,m);a.V[h++]=f;f=p+a.ta;g-=q}if(0>=g){c/=1024;var v;e="";v?10>>=a.ha;0>>=a.ha;0>>this.ha].Fb(a&this.A,a)};k.Db=function(a){this.f++;a=this.V[(a&this.g)>>>this.ha].Mb(a&this.A,a);this.f--;return a};k.na=function(a){return this.V[(a&this.g)>>>this.ha].oa(a&this.A,a)}; -k.eb=function(a){var b=a&this.A,c=(a&this.g)>>>this.ha;this.f++;a=this.V[c].Nb(b,a);this.f--;return a};k.Gb=function(a,b){this.V[(a&this.g)>>>this.ha].Ib(a&this.A,b&255,a)};k.Xa=function(a,b){this.f++;this.V[(a&this.g)>>>this.ha].Jb(a&this.A,b&255,a);this.f--};k.Ya=function(a,b){this.V[(a&this.g)>>>this.ha].yb(a&this.A,b&65535,a)};k.Hb=function(a,b){var c=a&this.A,d=(a&this.g)>>>this.ha;this.f++;this.V[d].Sb(c,b&65535,a);this.f--}; -function cc(a){for(var b=0,c=[],d=0;d>>a.ha;0g&&(q=g);if(!e&&m&&m.size){if(m.type==d){if(f+g<=m.C)return m.yb+=m.C-f,m.C=f,!0;if(f>=m.C+m.yb){q=m.size-(f-p);q>g&&(q=g);m.yb=f-m.C+q;f=p+a.ua;g-=q;h++;continue}}return ac(1,f,g)}f=new I(a,f,q,a.ua,d,e);Sb(f,a.i,m);a.V[h++]=f;f=p+a.ua;g-=q}if(0>=g){c/=1024;var v;e="";v?10>>=a.ha;0>>=a.ha;0>>this.ha].Fb(a&this.A,a)};k.Db=function(a){this.f++;a=this.V[(a&this.g)>>>this.ha].Mb(a&this.A,a);this.f--;return a};k.na=function(a){return this.V[(a&this.g)>>>this.ha].oa(a&this.A,a)}; +k.eb=function(a){var b=a&this.A,c=(a&this.g)>>>this.ha;this.f++;a=this.V[c].Nb(b,a);this.f--;return a};k.Gb=function(a,b){this.V[(a&this.g)>>>this.ha].Ib(a&this.A,b&255,a)};k.Ya=function(a,b){this.f++;this.V[(a&this.g)>>>this.ha].Jb(a&this.A,b&255,a);this.f--};k.Za=function(a,b){this.V[(a&this.g)>>>this.ha].zb(a&this.A,b&65535,a)};k.Hb=function(a,b){var c=a&this.A,d=(a&this.g)>>>this.ha;this.f++;this.V[d].Sb(c,b&65535,a);this.f--}; +function cc(a){for(var b=0,c=[],d=0;da.b.fb)){var g=f[0]?f[0].bind(b):null,h=f[1]?f[1].bind(b):null,m=f[2]?f[2].bind(b):null,p=f[3]?f[3].bind(b):null;65472<=e&&65487>=e&&(!g&&m&&(g=function(a){return function(b){return a(b)&255}.bind(b)}(m)),!h&&p&&(h=function(a){return function(b,c){return a(b,c)}.bind(b)}(p)));dc(a,e,e,g,h,m,p,f[4])}}}function fc(a,b){a.w.push(b)} -function gc(a,b){a.f||(a.i&&E(a.i,536870912)&&D(a.i,"memory fault on address "+J(a.i,b),!0,!0),a.b.ga(4,b))}function ac(a,b,c){n("Memory block error ("+a+": "+l(b)+","+l(c)+")");return!1}function K(a){r.call(this,"Device",a,K,256);this.g={data:0,Sd:0,Eb:20,gd:0};this.f={Td:0,Rb:-1}}u(K);k=K.prototype; -k.Ca=function(a,b,c,d){this.A=b;this.b=c;this.i=d;var e=this;this.f.Rb=hc(c,function(){e.f.La|=128;e.f.La&64&&(ic(e.b,e.f.hd),jc(e.b,e.f.Rb,1E3/60))});this.f.hd=kc(64,6);ec(b,this,L);fc(b,this.reset.bind(this));H(this)};k.reset=function(){this.g.Eb=this.g.Eb&-120|20;this.f.La=0};k.Dc=function(){var a=this.f.La;this.f.La&=-129;return a};k.rd=function(a){this.f.La=a;a&64&&jc(this.b,this.f.Rb,1E3/60);this.f.La=a&-129};k.wc=function(a){return(a?this.g.gd:this.g.data)&65535}; -k.kd=function(a){this.g.data=a};k.Fc=function(){var a=this.b;return a.D&62337|a.wa<<5|a.za<<1};k.td=function(a){var b=this.b;a&=62337;if(b.D!=a){b.D=a;b.wa=a>>5&3;b.za=a>>1&15;var c=0;a&257&&(c=4,a&1&&(c|=2));b.Ma!=c&&(b.Ma=c,uc(b))}vc(this)};k.Gc=function(){var a=this.b.Oa;a&65280&&(a=(a<<8|a>>8)&65535);return a};k.Hc=function(){return this.b.wb};k.Ic=function(){return this.b.Pa}; -k.ud=function(a){var b=this.b;1170>b.fb&&(a&=-49);b.Pa!=a&&(b.Pa=a,a&16?(b.qb=4194303,b.Aa=3915776):(b.qb=262143,b.Aa=253952),uc(b));vc(this)};function vc(a){a.g.Eb=a.g.Eb&-8|(a.b.Ma?a.b.Pa&16?1:2:4)}k.Wc=function(a){return this.b.T[1][a>>1&7]};k.Id=function(a,b){this.b.T[1][b>>1&7]=a&65295};k.Uc=function(a){return this.b.T[1][(a>>1&7)+8]};k.Gd=function(a,b){this.b.T[1][(b>>1&7)+8]=a&65295};k.Vc=function(a){return this.b.sa[1][a>>1&7]}; -k.Hd=function(a,b){b=b>>1&7;this.b.sa[1][b]=a;this.b.T[1][b]&=65295};k.Tc=function(a){return this.b.sa[1][(a>>1&7)+8]};k.Fd=function(a,b){b=(b>>1&7)+8;this.b.sa[1][b]=a;this.b.T[1][b]&=65295};k.Cc=function(a){return this.b.T[0][a>>1&7]};k.qd=function(a,b){this.b.T[0][b>>1&7]=a&65295};k.Ac=function(a){return this.b.T[0][(a>>1&7)+8]};k.od=function(a,b){this.b.T[0][(b>>1&7)+8]=a&65295};k.Bc=function(a){return this.b.sa[0][a>>1&7]};k.pd=function(a,b){b=b>>1&7;this.b.sa[0][b]=a;this.b.T[0][b]&=65295}; -k.zc=function(a){return this.b.sa[0][(a>>1&7)+8]};k.nd=function(a,b){b=(b>>1&7)+8;this.b.sa[0][b]=a;this.b.T[0][b]&=65295};k.bd=function(a){return this.b.T[3][a>>1&7]};k.Od=function(a,b){this.b.T[3][b>>1&7]=a&65295};k.$c=function(a){return this.b.T[3][(a>>1&7)+8]};k.Md=function(a,b){this.b.T[3][(b>>1&7)+8]=a&65295};k.ad=function(a){return this.b.sa[3][a>>1&7]};k.Nd=function(a,b){b=b>>1&7;this.b.sa[3][b]=a;this.b.T[3][b]&=65295};k.Zc=function(a){return this.b.sa[3][(a>>1&7)+8]}; -k.Ld=function(a,b){b=(b>>1&7)+8;this.b.sa[3][b]=a;this.b.T[3][b]&=65295};k.jb=function(a){a&=7;return this.b.L&2048?this.b.Fa[a]:this.b.u[a]};k.ob=function(a,b){b&=7;this.b.L&2048?this.b.Fa[b]=a:this.b.u[b]=a};k.Nc=function(){return this.b.L&49152?this.b.va[0]:this.b.u[6]};k.zd=function(a){this.b.L&49152?this.b.va[0]=a:this.b.u[6]=a};k.Qc=function(){return this.b.u[7]};k.Cd=function(a){this.b.u[7]=a};k.kb=function(a){a&=7;return this.b.L&2048?this.b.u[a]:this.b.Fa[a]}; -k.pb=function(a,b){b&=7;this.b.L&2048?this.b.u[b]=a:this.b.Fa[b]=a};k.Oc=function(){return 1==(this.b.L&49152)>>14?this.b.u[6]:this.b.va[1]};k.Ad=function(a){1==(this.b.L&49152)>>14?this.b.u[6]=a:this.b.va[1]=a};k.Pc=function(){return 3==(this.b.L&49152)>>14?this.b.u[6]:this.b.va[3]};k.Bd=function(a){3==(this.b.L&49152)>>14?this.b.u[6]=a:this.b.va[3]=a};k.yc=function(a){return this.b.gc[a-65504>>1]};k.md=function(a,b){this.b.gc[b-65504>>1]=a};k.dc=function(a){return 65520==a?61183:0};k.jc=function(){}; -k.Yc=function(){return 1};k.Kd=function(){};k.xc=function(){return this.b.aa};k.ld=function(){this.b.aa=0};k.Ec=function(){return this.b.fc};k.sd=function(a,b){b&1||(a&=255);this.b.fc=a};k.Jc=function(a){return a?this.b.Pb:0};k.vd=function(a){var b=this.b;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1)}b.Pb=a;b.G|=2};k.Xc=function(a){return a?this.b.Qa&65280:0};k.Jd=function(a){this.b.Qa=a|255};k.Mc=function(){return Lb(this.b)};k.yd=function(a){wc(this.b,a&-1809|Lb(this.b)&1808);this.b.G|=128}; -k.ic=function(a,b){E(this)&&D(this,"writeIgnored("+na(b)+"): "+na(a),!0,!0)}; -var M={},L=(M[62592]=[null,null,K.prototype.Wc,K.prototype.Id,"SISDR",1145],M[62608]=[null,null,K.prototype.Uc,K.prototype.Gd,"SDSDR",1145],M[62624]=[null,null,K.prototype.Vc,K.prototype.Hd,"SISAR",1145],M[62640]=[null,null,K.prototype.Tc,K.prototype.Fd,"SDSAR",1145],M[62656]=[null,null,K.prototype.Cc,K.prototype.qd,"KISDR",1145],M[62672]=[null,null,K.prototype.Ac,K.prototype.od,"KDSDR",1145],M[62688]=[null,null,K.prototype.Bc,K.prototype.pd,"KISAR",1145],M[62704]=[null,null,K.prototype.zc,K.prototype.nd, -"KDSAR",1145],M[62798]=[null,null,K.prototype.Ic,K.prototype.ud,"MMR3",1145],M[65382]=[null,null,K.prototype.Dc,K.prototype.rd,"LKS"],M[65400]=[null,null,K.prototype.wc,K.prototype.kd,"CNSL"],M[65402]=[null,null,K.prototype.Fc,K.prototype.td,"MMR0",1145],M[65404]=[null,null,K.prototype.Gc,K.prototype.ic,"MMR1",1145],M[65406]=[null,null,K.prototype.Hc,K.prototype.ic,"MMR2",1145],M[65408]=[null,null,K.prototype.bd,K.prototype.Od,"UISDR",1145],M[65424]=[null,null,K.prototype.$c,K.prototype.Md,"UDSDR", -1145],M[65440]=[null,null,K.prototype.ad,K.prototype.Nd,"UISAR",1145],M[65456]=[null,null,K.prototype.Zc,K.prototype.Ld,"UDSAR",1145],M[65472]=[null,null,K.prototype.jb,K.prototype.ob,"R0SET0"],M[65473]=[null,null,K.prototype.jb,K.prototype.ob,"R1SET0"],M[65474]=[null,null,K.prototype.jb,K.prototype.ob,"R2SET0"],M[65475]=[null,null,K.prototype.jb,K.prototype.ob,"R3SET0"],M[65476]=[null,null,K.prototype.jb,K.prototype.ob,"R4SET0"],M[65477]=[null,null,K.prototype.jb,K.prototype.ob,"R5SET0"],M[65478]= -[null,null,K.prototype.Nc,K.prototype.zd,"R6KERNEL"],M[65479]=[null,null,K.prototype.Qc,K.prototype.Cd,"R7KERNEL"],M[65480]=[null,null,K.prototype.kb,K.prototype.pb,"R0SET1",1145],M[65481]=[null,null,K.prototype.kb,K.prototype.pb,"R1SET1",1145],M[65482]=[null,null,K.prototype.kb,K.prototype.pb,"R2SET1",1145],M[65483]=[null,null,K.prototype.kb,K.prototype.pb,"R3SET1",1145],M[65484]=[null,null,K.prototype.kb,K.prototype.pb,"R4SET1",1145],M[65485]=[null,null,K.prototype.kb,K.prototype.pb,"R5SET1",1145], -M[65486]=[null,null,K.prototype.Oc,K.prototype.Ad,"R6SUPER",1145],M[65487]=[null,null,K.prototype.Pc,K.prototype.Bd,"R6USER",1145],M[65504]=[null,null,K.prototype.yc,K.prototype.md,"CTRL",1170],M[65520]=[null,null,K.prototype.dc,K.prototype.jc,"LSIZE",1170],M[65522]=[null,null,K.prototype.dc,K.prototype.jc,"HSIZE",1170],M[65524]=[null,null,K.prototype.Yc,K.prototype.Kd,"SYSID",1170],M[65526]=[null,null,K.prototype.xc,K.prototype.ld,"CPUERR",1170],M[65528]=[null,null,K.prototype.Ec,K.prototype.sd, -"MB",1170],M[65530]=[null,null,K.prototype.Jc,K.prototype.vd,"PIR"],M[65532]=[null,null,K.prototype.Xc,K.prototype.Jd,"SL"],M[65534]=[null,null,K.prototype.Mc,K.prototype.yd,"PSW"],M);L[62594]=L[62592];L[62596]=L[62592];L[62598]=L[62592];L[62600]=L[62592];L[62602]=L[62592];L[62604]=L[62592];L[62606]=L[62592];L[62610]=L[62608];L[62612]=L[62608];L[62614]=L[62608];L[62616]=L[62608];L[62618]=L[62608];L[62620]=L[62608];L[62622]=L[62608];L[62626]=L[62624];L[62628]=L[62624];L[62630]=L[62624];L[62632]=L[62624]; +function gc(a,b){a.f||(a.i&&E(a.i,536870912)&&D(a.i,"memory fault on address "+J(a.i,b),!0,!0),a.b.ga(4,b))}function ac(a,b,c){n("Memory block error ("+a+": "+l(b)+","+l(c)+")");return!1}function K(a){r.call(this,"Device",a,K,256);this.g={data:0,Td:0,Eb:20,hd:0};this.f={Ud:0,Rb:-1}}u(K);k=K.prototype; +k.Ca=function(a,b,c,d){this.A=b;this.b=c;this.i=d;var e=this;this.f.Rb=hc(c,function(){e.f.La|=128;e.f.La&64&&(ic(e.b,e.f.jd),jc(e.b,e.f.Rb,1E3/60))});this.f.jd=kc(64,6);ec(b,this,L);fc(b,this.reset.bind(this));H(this)};k.reset=function(){this.g.Eb=this.g.Eb&-120|20;this.f.La=0};k.Ec=function(){var a=this.f.La;this.f.La&=-129;return a};k.sd=function(a){this.f.La=a;a&64&&jc(this.b,this.f.Rb,1E3/60);this.f.La=a&-129};k.xc=function(a){return(a?this.g.hd:this.g.data)&65535}; +k.ld=function(a){this.g.data=a};k.Gc=function(){var a=this.b;return a.D&62337|a.za<<5|a.Aa<<1};k.ud=function(a){var b=this.b;a&=62337;if(b.D!=a){b.D=a;b.za=a>>5&3;b.Aa=a>>1&15;var c=0;a&257&&(c=4,a&1&&(c|=2));b.Ma!=c&&(b.Ma=c,uc(b))}vc(this)};k.Hc=function(){var a=this.b.Oa;a&65280&&(a=(a<<8|a>>8)&65535);return a};k.Ic=function(){return this.b.xb};k.Jc=function(){return this.b.Pa}; +k.vd=function(a){var b=this.b;1170>b.fb&&(a&=-49);b.Pa!=a&&(b.Pa=a,a&16?(b.rb=4194303,b.Ta=3915776):(b.rb=262143,b.Ta=253952),uc(b));vc(this)};function vc(a){a.g.Eb=a.g.Eb&-8|(a.b.Ma?a.b.Pa&16?1:2:4)}k.Xc=function(a){return this.b.U[1][a>>1&7]};k.Jd=function(a,b){this.b.U[1][b>>1&7]=a&65295};k.Vc=function(a){return this.b.U[1][(a>>1&7)+8]};k.Hd=function(a,b){this.b.U[1][(b>>1&7)+8]=a&65295};k.Wc=function(a){return this.b.ta[1][a>>1&7]}; +k.Id=function(a,b){b=b>>1&7;this.b.ta[1][b]=a;this.b.U[1][b]&=65295};k.Uc=function(a){return this.b.ta[1][(a>>1&7)+8]};k.Gd=function(a,b){b=(b>>1&7)+8;this.b.ta[1][b]=a;this.b.U[1][b]&=65295};k.Dc=function(a){return this.b.U[0][a>>1&7]};k.rd=function(a,b){this.b.U[0][b>>1&7]=a&65295};k.Bc=function(a){return this.b.U[0][(a>>1&7)+8]};k.pd=function(a,b){this.b.U[0][(b>>1&7)+8]=a&65295};k.Cc=function(a){return this.b.ta[0][a>>1&7]};k.qd=function(a,b){b=b>>1&7;this.b.ta[0][b]=a;this.b.U[0][b]&=65295}; +k.Ac=function(a){return this.b.ta[0][(a>>1&7)+8]};k.od=function(a,b){b=(b>>1&7)+8;this.b.ta[0][b]=a;this.b.U[0][b]&=65295};k.cd=function(a){return this.b.U[3][a>>1&7]};k.Pd=function(a,b){this.b.U[3][b>>1&7]=a&65295};k.ad=function(a){return this.b.U[3][(a>>1&7)+8]};k.Nd=function(a,b){this.b.U[3][(b>>1&7)+8]=a&65295};k.bd=function(a){return this.b.ta[3][a>>1&7]};k.Od=function(a,b){b=b>>1&7;this.b.ta[3][b]=a;this.b.U[3][b]&=65295};k.$c=function(a){return this.b.ta[3][(a>>1&7)+8]}; +k.Md=function(a,b){b=(b>>1&7)+8;this.b.ta[3][b]=a;this.b.U[3][b]&=65295};k.jb=function(a){a&=7;return this.b.M&2048?this.b.Fa[a]:this.b.u[a]};k.ob=function(a,b){b&=7;this.b.M&2048?this.b.Fa[b]=a:this.b.u[b]=a};k.Oc=function(){return this.b.M&49152?this.b.wa[0]:this.b.u[6]};k.Ad=function(a){this.b.M&49152?this.b.wa[0]=a:this.b.u[6]=a};k.Rc=function(){return this.b.u[7]};k.Dd=function(a){this.b.u[7]=a};k.kb=function(a){a&=7;return this.b.M&2048?this.b.u[a]:this.b.Fa[a]}; +k.pb=function(a,b){b&=7;this.b.M&2048?this.b.u[b]=a:this.b.Fa[b]=a};k.Pc=function(){return 1==(this.b.M&49152)>>14?this.b.u[6]:this.b.wa[1]};k.Bd=function(a){1==(this.b.M&49152)>>14?this.b.u[6]=a:this.b.wa[1]=a};k.Qc=function(){return 3==(this.b.M&49152)>>14?this.b.u[6]:this.b.wa[3]};k.Cd=function(a){3==(this.b.M&49152)>>14?this.b.u[6]=a:this.b.wa[3]=a};k.zc=function(a){return this.b.hc[a-65504>>1]};k.nd=function(a,b){this.b.hc[b-65504>>1]=a};k.ec=function(a){return 65520==a?61183:0};k.kc=function(){}; +k.Zc=function(){return 1};k.Ld=function(){};k.yc=function(){return this.b.aa};k.md=function(){this.b.aa=0};k.Fc=function(){return this.b.gc};k.td=function(a,b){b&1||(a&=255);this.b.gc=a};k.Kc=function(a){return a?this.b.Pb:0};k.wd=function(a){var b=this.b;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1)}b.Pb=a;b.G|=2};k.Yc=function(a){return a?this.b.Qa&65280:0};k.Kd=function(a){this.b.Qa=a|255};k.Nc=function(){return Lb(this.b)};k.zd=function(a){wc(this.b,a&-1809|Lb(this.b)&1808);this.b.G|=128}; +k.jc=function(a,b){E(this)&&D(this,"writeIgnored("+na(b)+"): "+na(a),!0,!0)}; +var M={},L=(M[62592]=[null,null,K.prototype.Xc,K.prototype.Jd,"SISDR",1145],M[62608]=[null,null,K.prototype.Vc,K.prototype.Hd,"SDSDR",1145],M[62624]=[null,null,K.prototype.Wc,K.prototype.Id,"SISAR",1145],M[62640]=[null,null,K.prototype.Uc,K.prototype.Gd,"SDSAR",1145],M[62656]=[null,null,K.prototype.Dc,K.prototype.rd,"KISDR",1145],M[62672]=[null,null,K.prototype.Bc,K.prototype.pd,"KDSDR",1145],M[62688]=[null,null,K.prototype.Cc,K.prototype.qd,"KISAR",1145],M[62704]=[null,null,K.prototype.Ac,K.prototype.od, +"KDSAR",1145],M[62798]=[null,null,K.prototype.Jc,K.prototype.vd,"MMR3",1145],M[65382]=[null,null,K.prototype.Ec,K.prototype.sd,"LKS"],M[65400]=[null,null,K.prototype.xc,K.prototype.ld,"CNSL"],M[65402]=[null,null,K.prototype.Gc,K.prototype.ud,"MMR0",1145],M[65404]=[null,null,K.prototype.Hc,K.prototype.jc,"MMR1",1145],M[65406]=[null,null,K.prototype.Ic,K.prototype.jc,"MMR2",1145],M[65408]=[null,null,K.prototype.cd,K.prototype.Pd,"UISDR",1145],M[65424]=[null,null,K.prototype.ad,K.prototype.Nd,"UDSDR", +1145],M[65440]=[null,null,K.prototype.bd,K.prototype.Od,"UISAR",1145],M[65456]=[null,null,K.prototype.$c,K.prototype.Md,"UDSAR",1145],M[65472]=[null,null,K.prototype.jb,K.prototype.ob,"R0SET0"],M[65473]=[null,null,K.prototype.jb,K.prototype.ob,"R1SET0"],M[65474]=[null,null,K.prototype.jb,K.prototype.ob,"R2SET0"],M[65475]=[null,null,K.prototype.jb,K.prototype.ob,"R3SET0"],M[65476]=[null,null,K.prototype.jb,K.prototype.ob,"R4SET0"],M[65477]=[null,null,K.prototype.jb,K.prototype.ob,"R5SET0"],M[65478]= +[null,null,K.prototype.Oc,K.prototype.Ad,"R6KERNEL"],M[65479]=[null,null,K.prototype.Rc,K.prototype.Dd,"R7KERNEL"],M[65480]=[null,null,K.prototype.kb,K.prototype.pb,"R0SET1",1145],M[65481]=[null,null,K.prototype.kb,K.prototype.pb,"R1SET1",1145],M[65482]=[null,null,K.prototype.kb,K.prototype.pb,"R2SET1",1145],M[65483]=[null,null,K.prototype.kb,K.prototype.pb,"R3SET1",1145],M[65484]=[null,null,K.prototype.kb,K.prototype.pb,"R4SET1",1145],M[65485]=[null,null,K.prototype.kb,K.prototype.pb,"R5SET1",1145], +M[65486]=[null,null,K.prototype.Pc,K.prototype.Bd,"R6SUPER",1145],M[65487]=[null,null,K.prototype.Qc,K.prototype.Cd,"R6USER",1145],M[65504]=[null,null,K.prototype.zc,K.prototype.nd,"CTRL",1170],M[65520]=[null,null,K.prototype.ec,K.prototype.kc,"LSIZE",1170],M[65522]=[null,null,K.prototype.ec,K.prototype.kc,"HSIZE",1170],M[65524]=[null,null,K.prototype.Zc,K.prototype.Ld,"SYSID",1170],M[65526]=[null,null,K.prototype.yc,K.prototype.md,"CPUERR",1170],M[65528]=[null,null,K.prototype.Fc,K.prototype.td, +"MB",1170],M[65530]=[null,null,K.prototype.Kc,K.prototype.wd,"PIR"],M[65532]=[null,null,K.prototype.Yc,K.prototype.Kd,"SL"],M[65534]=[null,null,K.prototype.Nc,K.prototype.zd,"PSW"],M);L[62594]=L[62592];L[62596]=L[62592];L[62598]=L[62592];L[62600]=L[62592];L[62602]=L[62592];L[62604]=L[62592];L[62606]=L[62592];L[62610]=L[62608];L[62612]=L[62608];L[62614]=L[62608];L[62616]=L[62608];L[62618]=L[62608];L[62620]=L[62608];L[62622]=L[62608];L[62626]=L[62624];L[62628]=L[62624];L[62630]=L[62624];L[62632]=L[62624]; L[62634]=L[62624];L[62636]=L[62624];L[62638]=L[62624];L[62642]=L[62640];L[62644]=L[62640];L[62646]=L[62640];L[62648]=L[62640];L[62650]=L[62640];L[62652]=L[62640];L[62654]=L[62640];L[62658]=L[62656];L[62660]=L[62656];L[62662]=L[62656];L[62664]=L[62656];L[62666]=L[62656];L[62668]=L[62656];L[62670]=L[62656];L[62674]=L[62672];L[62676]=L[62672];L[62678]=L[62672];L[62680]=L[62672];L[62682]=L[62672];L[62684]=L[62672];L[62686]=L[62672];L[62690]=L[62688];L[62692]=L[62688];L[62694]=L[62688];L[62696]=L[62688]; L[62698]=L[62688];L[62700]=L[62688];L[62702]=L[62688];L[62706]=L[62704];L[62708]=L[62704];L[62710]=L[62704];L[62712]=L[62704];L[62714]=L[62704];L[62716]=L[62704];L[62718]=L[62704];L[65410]=L[65408];L[65412]=L[65408];L[65414]=L[65408];L[65416]=L[65408];L[65418]=L[65408];L[65420]=L[65408];L[65422]=L[65408];L[65426]=L[65424];L[65428]=L[65424];L[65430]=L[65424];L[65432]=L[65424];L[65434]=L[65424];L[65436]=L[65424];L[65438]=L[65424];L[65442]=L[65440];L[65444]=L[65440];L[65446]=L[65440];L[65448]=L[65440]; L[65450]=L[65440];L[65452]=L[65440];L[65454]=L[65440];L[65458]=L[65456];L[65460]=L[65456];L[65462]=L[65456];L[65464]=L[65456];L[65466]=L[65456];L[65468]=L[65456];L[65470]=L[65456];L[65506]=L[65504];L[65508]=L[65504];L[65510]=L[65504];L[65512]=L[65504];L[65514]=L[65504];L[65516]=L[65504];L[65518]=L[65504];Ta(function(){for(var a=C(document,"pdp11","device"),b=0;b>1),this.b=new Int32Array(this.D,0,this.size>>2),Ec(this,Ac?Fc:Gc);else{a=this.b=Array(this.size>> +function I(a,b,c,d,e,f){this.A=a;this.id=Bc+=2;this.b=null;this.C=b;this.yb=c;this.size=d||0;this.type=e||Cc;this.g=e==Dc;this.controller=null;Sb(this);this.Ka=this.qc=!1;if(this.size)if(f)this.controller=f,a=[null,0],this.b=a[0],Ec(this,f.nc);else if(sb)this.D=new ArrayBuffer(this.size),this.F=new DataView(this.D,0,this.size),this.f=new Uint8Array(this.D,0,this.size),this.J=new Uint16Array(this.D,0,this.size>>1),this.b=new Int32Array(this.D,0,this.size>>2),Ec(this,Ac?Fc:Gc);else{a=this.b=Array(this.size>> 2);for(f=0;f>2),b=0;b>8,c)},U:function(a){return this.b[a>>2]>>>((a&3)<<3)&255},la:function(a,b){a&1&&gc(this.A,b);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},ua: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.Ka=!0},O:function(a,b){if(this.i&&null!=this.C){var c=this.i;Lc(c,this.C+a,1,c.M)&&c.ca(!0)}return this.Mb(a,b)},Y:function(a,b){if(this.i&&null!=this.C){var c=this.i;Lc(c,this.C+a,2,c.M)&&c.ca(!0)}return this.Nb(a,b)},ra:function(a,b,c){if(this.i&&null!=this.C){var d=this.i;Lc(d,this.C+a,1, -d.D)&&d.ca(!0)}this.g?this.w(a,b,c):this.Jb(a,b,c)},Za:function(a,b,c){if(this.i&&null!=this.C){var d=this.i;Lc(d,this.C+a,2,d.D)&&d.ca(!0)}this.g?this.w(a,b,c):this.Sb(a,b,c)},N:function(a){return this.f[a]},P:function(a,b){a=this.f[a];this.i&&E(this.i,128)&&D(this.i,"Memory.readByte("+J(this.i,b)+"): "+J(this.i,a),!0);return a},X:function(a,b){a&1&&gc(this.A,b);return this.F.getUint16(a,!0)},ea:function(a,b){a&1&&gc(this.A,b);a=this.J[a>>1];this.i&&E(this.i,128)&&D(this.i,"Memory.readWord("+J(this.i, -b)+"): "+J(this.i,a),!0);return a},pa:function(a,b){this.f[a]=b;this.Ka=!0},Sa:function(a,b,c){this.f[a]=b;this.Ka=!0;this.i&&E(this.i,128)&&D(this.i,"Memory.writeByte("+J(this.i,c)+","+J(this.i,b)+")",!0)},wa:function(a,b,c){a&1&&gc(this.A,c);this.F.setUint16(a,b,!0);this.Ka=!0},za:function(a,b,c){a&1&&gc(this.A,c);this.J[a>>1]=b;this.Ka=!0;this.i&&E(this.i,128)&&D(this.i,"Memory.writeWord("+J(this.i,c)+","+J(this.i,b)+")",!0)}}; -function Sb(a,b,c){a.i=b;a.I=a.B=0;c&&((a.I=c.I)&&Kc(a,Jc,!1),(a.B=c.B)&&Ic(a,Jc,!1))}function Mc(a,b){b?--a.B||(a.Ib=a.g?a.w:a.Jb,a.yb=a.g?a.H:a.Sb):--a.I||(a.Fb=a.Mb,a.oa=a.Nb)}function Ic(a,b,c){c&&a.B||(a.Ib=!a.g&&b[1]||a.w,a.yb=!a.g&&b[3]||a.H);if(c||void 0===c)a.Jb=b[1]||a.w,a.Sb=b[3]||a.H}function Kc(a,b,c){c&&a.I||(a.Fb=b[0]||a.K,a.oa=b[2]||a.M);if(c||void 0===c)a.Mb=b[0]||a.K,a.Nb=b[2]||a.M}function Ec(a,b){b||(b=Nc);Kc(a,b,void 0);Ic(a,b,void 0)} -var Nc=[],Hc=[I.prototype.U,I.prototype.ua,I.prototype.la,I.prototype.Aa],Jc=[I.prototype.O,I.prototype.ra,I.prototype.Y,I.prototype.Za];if(sb)var Gc=[I.prototype.N,I.prototype.pa,I.prototype.X,I.prototype.wa],Fc=[I.prototype.P,I.prototype.Sa,I.prototype.ea,I.prototype.za]; -function Oc(a,b){r.call(this,"CPU",a,Oc,1);var c=a.multiplier||1;this.Ua=a.cycles||b;this.Na=c;this.bb=Math.round(this.Ua/1E4)/100;this.Wa=this.bb*this.Na;this.v.da=!1;this.v.Qb=!1;this.v.ab=a.autoStart;this.v.cb=!1;this.tb=this.la=0;this.ub=a.csStart;this.gb=a.csInterval;this.hb=a.csStop;this.J=[];this.bc=this.fd.bind(this);H(this)}u(Oc);var Pc=["power","reset"];k=Oc.prototype; +I.prototype={constructor:I,parent:null,save:function(){var a,b;if(this.controller)a=null;else if(sb)for(a=Array(this.size>>2),b=0;b>8,c)},R:function(a){return this.b[a>>2]>>>((a&3)<<3)&255},ka:function(a,b){a&1&&gc(this.A,b);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},Sa: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.Ka=!0},O:function(a,b){if(this.i&&null!=this.C){var c=this.i;Lc(c,this.C+a,1,c.L)&&c.ca(!0)}return this.Mb(a,b)},Y:function(a,b){if(this.i&&null!=this.C){var c=this.i;Lc(c,this.C+a,2,c.L)&&c.ca(!0)}return this.Nb(a,b)},ra:function(a,b,c){if(this.i&&null!=this.C){var d=this.i;Lc(d,this.C+a,1, +d.D)&&d.ca(!0)}this.g?this.w(a,b,c):this.Jb(a,b,c)},$a:function(a,b,c){if(this.i&&null!=this.C){var d=this.i;Lc(d,this.C+a,2,d.D)&&d.ca(!0)}this.g?this.w(a,b,c):this.Sb(a,b,c)},N:function(a){return this.f[a]},P:function(a,b){a=this.f[a];this.i&&E(this.i,128)&&D(this.i,"Memory.readByte("+J(this.i,b)+"): "+J(this.i,a),!0);return a},X:function(a,b){a&1&&gc(this.A,b);return this.F.getUint16(a,!0)},ea:function(a,b){a&1&&gc(this.A,b);a=this.J[a>>1];this.i&&E(this.i,128)&&D(this.i,"Memory.readWord("+J(this.i, +b)+"): "+J(this.i,a),!0);return a},pa:function(a,b){this.f[a]=b;this.Ka=!0},sa:function(a,b,c){this.f[a]=b;this.Ka=!0;this.i&&E(this.i,128)&&D(this.i,"Memory.writeByte("+J(this.i,c)+","+J(this.i,b)+")",!0)},va:function(a,b,c){a&1&&gc(this.A,c);this.F.setUint16(a,b,!0);this.Ka=!0},za:function(a,b,c){a&1&&gc(this.A,c);this.J[a>>1]=b;this.Ka=!0;this.i&&E(this.i,128)&&D(this.i,"Memory.writeWord("+J(this.i,c)+","+J(this.i,b)+")",!0)}}; +function Sb(a,b,c){a.i=b;a.I=a.B=0;c&&((a.I=c.I)&&Kc(a,Jc,!1),(a.B=c.B)&&Ic(a,Jc,!1))}function Mc(a,b){b?--a.B||(a.Ib=a.g?a.w:a.Jb,a.zb=a.g?a.H:a.Sb):--a.I||(a.Fb=a.Mb,a.oa=a.Nb)}function Ic(a,b,c){c&&a.B||(a.Ib=!a.g&&b[1]||a.w,a.zb=!a.g&&b[3]||a.H);if(c||void 0===c)a.Jb=b[1]||a.w,a.Sb=b[3]||a.H}function Kc(a,b,c){c&&a.I||(a.Fb=b[0]||a.K,a.oa=b[2]||a.L);if(c||void 0===c)a.Mb=b[0]||a.K,a.Nb=b[2]||a.L}function Ec(a,b){b||(b=Nc);Kc(a,b,void 0);Ic(a,b,void 0)} +var Nc=[],Hc=[I.prototype.R,I.prototype.Sa,I.prototype.ka,I.prototype.Aa],Jc=[I.prototype.O,I.prototype.ra,I.prototype.Y,I.prototype.$a];if(sb)var Gc=[I.prototype.N,I.prototype.pa,I.prototype.X,I.prototype.va],Fc=[I.prototype.P,I.prototype.sa,I.prototype.ea,I.prototype.za]; +function Oc(a,b){r.call(this,"CPU",a,Oc,1);var c=a.multiplier||1;this.Ra=a.cycles||b;this.Na=c;this.qb=Math.round(this.Ra/1E4)/100;this.Xa=this.qb*this.Na;this.v.da=!1;this.v.Qb=!1;this.v.ab=a.autoStart;this.v.cb=!1;this.ub=this.pa=0;this.vb=a.csStart;this.gb=a.csInterval;this.hb=a.csStop;this.K=[];this.dc=this.gd.bind(this);H(this)}u(Oc);var Pc=["power","reset"];k=Oc.prototype; k.Ca=function(a,b,c,d){this.B=a;this.A=b;this.i=d;for(b=0;b=a.la&&(a.la+=a.gb,c=!0);0<=a.hb&&a.hb<=Vc(a)&&(a.gb=a.hb=-1,Sc(a),a.ca(),c=!0);c&&a.j(Vc(a)+" cycles: checksum="+l(a.tb))}} -k.qa=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.B)if(a=d.B,a.v.ja)a=!0;else{var b=null,c,h=kb(a.id);for(c=0;ca.U/a.Wa?b=1:d=!0;a.Na=b;b=a.bb*a.Na;if(a.Wa!=b){a.Wa=b;b=a.Wa.toFixed(2)+"Mhz";var e=a.I.setSpeed;e&&(e.textContent=b);a.j("target speed: "+b)}c&&a.B&&a.B.lb()}Xc(a,a.O);a.O=0;a.N=za();a.X=0;Yc(a);return d}function hc(a,b){var c=a.J.length;a.J.push([-1,b]);return c}function jc(a,b,c){0<=b&&ba.J[b][0]&&(c=a.Ua*a.Na/1E3*c|0,a.J[b][0]=c+Zc(a))} -function $c(a,b){for(var c=a.J.length-1;0<=c;c--){var d=a.J[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ad(a,b){for(var c=a.J.length-1;0<=c;c--){var d=a.J[c];0>d[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Zc(a,b){var c=a.Y-=a.b;a.b=0;b&&(a.Y=0);return c} -k.fd=function(){if(this.v.da){this.rb>=this.Ua&&Yc(this,!0);this.ua=0;this.Ta=za();if(this.X){var a=this.Ta-this.X;a>this.Cb&&(this.N+=a,this.N>this.Ta&&(this.N=this.Ta))}try{do{var b=$c(this,this.v.cb?1:this.Ra);try{this.nb(b)}catch(e){if("number"!=typeof e)throw e;}b=Zc(this,!0);this.ua+=b;this.O+=b;Uc(this,b);ad(this,b);this.pa-=b;if(0>=this.pa){this.pa+=this.Ra;15<=++this.ac&&(this.B&&this.B.ba(),this.ac=0);break}}while(this.v.da)}catch(e){this.ca();this.B&&this.B.stop(za(),Vc(this));rb(this, -e.stack||e.message);return}if(this.v.da){a=setTimeout;b=this.bc;this.X=za();var c=this.Cb;this.ua&&(c=Math.round(c*this.ua/this.Ra));var c=c-(this.X-this.Ta),d=this.X-this.N;d&&(this.U=Math.round(this.O/(10*d))/100,864E5<=d&&(this.ea=0,Wc(this)));if(0>c||this.Uc&&(this.N-=c),c=0;this.rb+=this.ua;this.X+=c;a(b,c)}}}; -k.mb=function(a){if(qb(this))return!1;if(this.v.da)return this.j(this.toString()+" busy"),!1;Wc(this);this.v.da=!0;this.v.Qb=!0;var b=this.I.run;b&&(b.textContent="Halt");this.B&&(a&&this.B.lb(!0),this.B.start(this.N,Vc(this)));setTimeout(this.bc,0);return!0};k.nb=function(){return 0};k.ca=function(a){if(this.v.da){Zc(this);Xc(this,this.O);this.O=0;this.v.da=!1;var b=this.I.run;b&&(b.textContent="Run");this.B&&this.B.stop(za(),Vc(this))}this.v.complete=a}; -function bd(a){this.fb=+a.model||1170;this.zb=a.addrReset||0;Oc.call(this,a,6666667);this.decode=1120==this.fb?cd.bind(this):dd.bind(this);ed(this);this.K=0;this.P=null;this.v.complete=this.v.oc=!1}u(bd,Oc);k=bd.prototype;k.reset=function(){this.status("model "+this.fb);this.v.da&&this.ca();ed(this);Rc(this);this.v.error=!1;this.parent.reset.call(this)}; -function ed(a){a.R=65536;a.S=32768;a.Z=65535;a.W=32768;a.L=15;a.u=[0,0,0,0,0,0,0,a.zb];a.Fa=[0,0,0,0,0,0];a.va=[0,0,0,0];a.w=0;a.za=0;a.sc=[4,2,0,1];a.T=[[0,0,0,0,0,0,0,0,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],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.sa=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.uc=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, -0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];a.gc=[0,0,0,0,0,0,0,0];a.fc=0;a.G=0;a.F=a.H=0;a.g=a.f=a.$a=0;a.ra=-1;fd(a)}function fd(a){a.Qa=255;a.aa=0;a.Pb=0;a.D=0;a.Oa=0;a.wb=0;a.Pa=0;a.Ma=0;a.wa=0;a.qb=262143;a.Aa=253952;a.G|=2;a.A&&uc(a)}function uc(a){a.Ma?(a.M=65536,a.$=a.rc,a.oa=a.cd,a.yb=a.Pd,Vb(a.A,a.Pa&16?22:18)):(a.M=0,a.$=a.qc,a.oa=a.ec,a.yb=a.kc,Vb(a.A,16))}function gd(a,b,c){a.zb=b;N(a,b);!c&&a.i&&(a.ca(),a.i.ba())}k.Yb=function(){return 0}; -k.save=function(){var a=new O(this);a.set(0,[]);a.set(1,[this.ea,this.Na]);a.set(2,cc(this.A));return a.data()};k.restore=function(a){var b=a[1];this.ea=b[1];Wc(this,b[3]);a:{b=this.A;a=a[2];var c;for(c=0;c>14&3;c=a.L>>14&3;a.w!=c&&(a.va[c]=a.u[6],a.u[6]=a.va[a.w]);a.L=b;a.G|=2}function P(a,b){a.G&128||(a.W=a.Z=b,a.S=0)}function Ed(a,b,c){a.G&128||(a.W=a.Z=a.R=b,a.S=c||0)}function Fd(a,b,c,d){a.G&128||(a.W=a.Z=a.R=b,a.S=(c^b)&(d^b))}function Gd(a,b){a.G&128||(a.W=a.Z=a.R=b,a.S=a.W^a.R>>1)} -function Hd(a,b,c,d){a.G&128||(a.W=a.Z=a.R=b,a.S=(c^d)&(d^b))}k.ga=function(a,b){if(!this.K){var c=!1;0>this.ra?this.ra=Lb(this):this.w||(a=4,c=!0);this.D&57344||(this.Oa=63222,this.wb=a);this.w=0;var d=this.oa(a|this.M),e=this.oa(a+2&65535|this.M);wc(this,e&-12289|this.ra>>2&12288);c&&(this.aa|=4,this.u[6]=4);Id(this,this.ra);Id(this,this.u[7]);N(this,d);this.G&=-113;this.ra=-1;if(26!=b)throw a;}};function Jd(a){var b=Kd(a),c=Kd(a)&-1793;a.L&49152&&(c=c&-225|a.L&63712);N(a,b);wc(a,c);a.G&=-17} -function Ld(a,b,c){var d,e,f,g=0;d=b>>13;a.Pa&a.sc[a.w]||(d&=7);e=a.T[a.w][d];f=(a.sa[a.w][d]<<6)+(b&8191)&a.qb;if(ff){if(3932160<=f){f&=262143;var h=f>>13&31;31>h?a.Pa&32&&(f=a.uc[h]+(f&8190)&4194302,3932160<=f&&4186112>f&&console.log("panic(898)")):f|=4186112}f>=a.Aa&&4186112>f&&(a.aa|=32,a.ga(4,12))}switch(e&7){case 1:g=4096;case 2:e|=128;c&4&&(g=8192);break;case 4:g=4096;case 5:c&4&&(g=4096);case 6:e|=c& -4?192:128;break;default:g=32768}32512!==(e&32520)&&(e&8?e&32512&&(b&8128)<(e>>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&&(g|=16384));a.T[a.w][d]=e;if(4194170!==f||a.w)a.wa=a.w,a.za=d;g&&(g&57344&&(0<=a.ra&&(g|=128),a.D&57344||(a.D=a.D|g|a.wa<<5|a.za<<1),a.ga(168,16)),a.D&61440||!(4191360>f||4194239c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.u[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.u[c]+f&65535;7!==c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.u[c]-2&65535;7!==c&&(e|=g);e=a.oa(e)| -g;a.b-=8;break;case 6:return e=a.oa(ld(a,2)),e=e+a.u[c]&65535|g,a.b-=6,e;case 7:return e=a.oa(ld(a,2)),e=e+a.u[c]&65535,e=a.oa(e|a.M)|g,a.b-=10,e}a.u[c]=a.u[c]+f&65535;!g||a.D&57344||(a.Oa=a.Oa<<8|f<<3&248|c);6==c&&!a.w&&d&4&&0>=f&&(a.u[6]<=a.Qa||65534<=a.u[6])&&(a.u[6]<=a.Qa-32?(a.aa|=4,a.u[6]=4,a.ga(4,24)):(a.aa|=8,a.G|=64));return e}k.Db=function(a){if(!this.Ma)return this.A.Db(a);this.K++;a=Md(this,Ld(this,a,3));this.K--;return a}; -k.eb=function(a){if(!this.Ma)return this.A.eb(a);this.K++;a=this.ec(Ld(this,a,2));this.K--;return a};k.Xa=function(a,b){this.Ma?(this.K++,Nd(this,Ld(this,a,5),b),this.K--):this.A.Xa(a,b)};k.Hb=function(a,b){this.Ma?(this.K++,this.kc(Ld(this,a,4),b),this.K--):this.A.Hb(a,b)};k.qc=function(a,b,c){return Od(this,a,b,c)};k.rc=function(a,b,c){return Ld(this,Od(this,a,b,c),c)};k.ec=function(a){return this.A.na(a)};k.cd=function(a){return this.A.na(Ld(this,a,2))};k.kc=function(a,b){this.A.Ya(a,b&65535)}; -k.Pd=function(a,b){this.A.Ya(Ld(this,a,4),b)};function Pd(a,b,c){var d=a.f=b&7;(b=a.g=(b&56)>>3)?(d=Od(a,b,d,2),c&65536||61440!==(a.L&61440)&&(d&=65535),a.w=a.L>>12&3,c=a.oa(d|c&a.M),a.w=a.L>>14&3):c=6!=d||(a.L>>2&12288)===(a.L&12288)?a.u[d]:a.va[a.L>>12&3];return c}function Qd(a,b,c,d){a.D&57344||(a.Oa=22);var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=Od(a,b,e,4),c&65536||(e&=65535),a.w=a.L>>12&3,e=Ld(a,e|c&65536,4),a.w=a.L>>14&3,a.A.Ya(e,d)):6!=e||(a.L>>2&12288)===(a.L&12288)?a.u[e]=d:a.va[a.L>>12&3]=d} +function Sc(a){void 0===a.vb&&(a.vb=0);void 0===a.gb&&(a.gb=-1);void 0===a.hb&&(a.hb=-1);a.v.cb=0<=a.vb&&0=a.pa&&(a.pa+=a.gb,c=!0);0<=a.hb&&a.hb<=Vc(a)&&(a.gb=a.hb=-1,Sc(a),a.ca(),c=!0);c&&a.j(Vc(a)+" cycles: checksum="+l(a.ub))}} +k.qa=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.B)if(a=d.B,a.v.ja)a=!0;else{var b=null,c,h=kb(a.id);for(c=0;ca.X/a.Xa?b=1:d=!0;a.Na=b;b=a.qb*a.Na;if(a.Xa!=b){a.Xa=b;b=a.Xa.toFixed(2)+"Mhz";var e=a.I.setSpeed;e&&(e.textContent=b);a.j("target speed: "+b)}c&&a.B&&a.B.lb()}Xc(a,a.P);a.P=0;a.O=za();a.Y=0;Yc(a);return d}function hc(a,b){var c=a.K.length;a.K.push([-1,b]);return c}function jc(a,b,c){0<=b&&ba.K[b][0]&&(c=a.Ra*a.Na/1E3*c|0,a.K[b][0]=c+Zc(a))} +function $c(a,b){for(var c=a.K.length-1;0<=c;c--){var d=a.K[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function ad(a,b){for(var c=a.K.length-1;0<=c;c--){var d=a.K[c];0>d[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function Zc(a,b){var c=a.ea-=a.b;a.b=a.J=0;b&&(a.ea=0);return c} +k.gd=function(){if(this.v.da){this.sb>=this.Ra&&Yc(this,!0);this.va=0;this.Ua=za();if(this.Y){var a=this.Ua-this.Y;a>this.ac&&(this.O+=a,this.O>this.Ua&&(this.O=this.Ua))}try{do{var b=$c(this,this.v.cb?1:this.Va);try{this.nb(b)}catch(e){if("number"!=typeof e)throw e;}b=Zc(this,!0);this.va+=b;this.P+=b;Uc(this,b);ad(this,b);this.ra-=b;if(0>=this.ra){this.ra+=this.Va;15<=++this.bc&&(this.B&&this.B.ba(),this.bc=0);break}}while(this.v.da)}catch(e){this.ca();this.B&&this.B.stop(za(),Vc(this));rb(this, +e.stack||e.message);return}if(this.v.da){a=setTimeout;b=this.dc;this.Y=za();var c=this.ac;this.va&&(c=Math.round(c*this.va/this.Va));var c=c-(this.Y-this.Ua),d=this.Y-this.O;d&&(this.X=Math.round(this.P/(10*d))/100,864E5<=d&&(this.ka=0,Wc(this)));if(0>c||this.Xc&&(this.O-=c),c=0;this.sb+=this.va;this.Y+=c;a(b,c)}}}; +k.mb=function(a){if(qb(this))return!1;if(this.v.da)return this.j(this.toString()+" busy"),!1;Wc(this);this.v.da=!0;this.v.Qb=!0;var b=this.I.run;b&&(b.textContent="Halt");this.B&&(a&&this.B.lb(!0),this.B.start(this.O,Vc(this)));setTimeout(this.dc,0);return!0};k.nb=function(){return 0};k.ca=function(a){if(this.v.da){Zc(this);Xc(this,this.P);this.P=0;this.v.da=!1;var b=this.I.run;b&&(b.textContent="Run");this.B&&this.B.stop(za(),Vc(this))}this.v.complete=a}; +function bd(a){this.fb=+a.model||1170;this.Bb=a.addrReset||0;Oc.call(this,a,6666667);this.decode=1120==this.fb?cd.bind(this):dd.bind(this);ed(this);this.L=0;this.R=null;this.v.complete=this.v.pc=!1}u(bd,Oc);k=bd.prototype;k.reset=function(){this.status("model "+this.fb);this.v.da&&this.ca();ed(this);Rc(this);this.v.error=!1;this.parent.reset.call(this)}; +function ed(a){a.S=65536;a.T=32768;a.Z=65535;a.W=32768;a.M=15;a.u=[0,0,0,0,0,0,0,a.Bb];a.Fa=[0,0,0,0,0,0];a.wa=[0,0,0,0];a.w=0;a.Aa=0;a.tc=[4,2,0,1];a.U=[[0,0,0,0,0,0,0,0,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],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.ta=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.wc=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];a.hc=[0,0,0,0,0,0,0,0];a.gc=0;a.G=0;a.F=a.H=0;a.g=a.f=a.bb=0;a.sa=-1;fd(a)}function fd(a){a.Qa=255;a.aa=0;a.Pb=0;a.D=0;a.Oa=0;a.xb=0;a.Pa=0;a.Ma=0;a.za=0;a.rb=262143;a.Ta=253952;a.G|=2;a.A&&uc(a)}function uc(a){a.Ma?(a.N=65536,a.$=a.sc,a.oa=a.dd,a.zb=a.Qd,Vb(a.A,a.Pa&16?22:18)):(a.N=0,a.$=a.rc,a.oa=a.fc,a.zb=a.lc,Vb(a.A,16))}function gd(a,b,c){a.Bb=b;N(a,b);!c&&a.i&&(a.ca(),a.i.ba())}k.Yb=function(){return 0}; +k.save=function(){var a=new O(this);a.set(0,[]);a.set(1,[this.ka,this.Na]);a.set(2,cc(this.A));return a.data()};k.restore=function(a){var b=a[1];this.ka=b[1];Wc(this,b[3]);a:{b=this.A;a=a[2];var c;for(c=0;c>14&3;c=a.M>>14&3;a.w!=c&&(a.wa[c]=a.u[6],a.u[6]=a.wa[a.w]);a.M=b;a.G|=2}function P(a,b){a.G&128||(a.W=a.Z=b,a.T=0)}function Ed(a,b,c){a.G&128||(a.W=a.Z=a.S=b,a.T=c||0)}function Fd(a,b,c,d){a.G&128||(a.W=a.Z=a.S=b,a.T=(c^b)&(d^b))}function Gd(a,b){a.G&128||(a.W=a.Z=a.S=b,a.T=a.W^a.S>>1)} +function Hd(a,b,c,d){a.G&128||(a.W=a.Z=a.S=b,a.T=(c^d)&(d^b))}k.ga=function(a,b){if(!this.L){var c=!1;0>this.sa?this.sa=Lb(this):this.w||(a=4,c=!0);this.D&57344||(this.Oa=63222,this.xb=a);this.w=0;var d=this.oa(a|this.N),e=this.oa(a+2&65535|this.N);wc(this,e&-12289|this.sa>>2&12288);c&&(this.aa|=4,this.u[6]=4);Id(this,this.sa);Id(this,this.u[7]);N(this,d);this.G&=-113;this.sa=-1;if(26!=b)throw a;}};function Jd(a){var b=Kd(a),c=Kd(a)&-1793;a.M&49152&&(c=c&-225|a.M&63712);N(a,b);wc(a,c);a.G&=-17} +function Ld(a,b,c){var d,e,f,g=0;d=b>>13;a.Pa&a.tc[a.w]||(d&=7);e=a.U[a.w][d];f=(a.ta[a.w][d]<<6)+(b&8191)&a.rb;if(ff){if(3932160<=f){f&=262143;var h=f>>13&31;31>h?a.Pa&32&&(f=a.wc[h]+(f&8190)&4194302,3932160<=f&&4186112>f&&console.log("panic(898)")):f|=4186112}f>=a.Ta&&4186112>f&&(a.aa|=32,a.ga(4,12))}switch(e&7){case 1:g=4096;case 2:e|=128;c&4&&(g=8192);break;case 4:g=4096;case 5:c&4&&(g=4096);case 6:e|=c& +4?192:128;break;default:g=32768}32512!==(e&32520)&&(e&8?e&32512&&(b&8128)<(e>>2&8128)&&(g|=16384):(b&8128)>(e>>2&8128)&&(g|=16384));a.U[a.w][d]=e;if(4194170!==f||a.w)a.za=a.w,a.Aa=d;g&&(g&57344&&(0<=a.sa&&(g|=128),a.D&57344||(a.D=a.D|g|a.za<<5|a.Aa<<1),a.ga(168,16)),a.D&61440||!(4191360>f||4194239c&&d&1&&(f=1));a.b-=3;break;case 3:f=2;e=a.u[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.u[c]+f&65535;7!==c&&(e|=g);a.b-=4;break;case 5:f=-2;e=a.u[c]-2&65535;7!==c&&(e|=g);e=a.oa(e)| +g;a.b-=8;break;case 6:return e=a.oa(ld(a,2)),e=e+a.u[c]&65535|g,a.b-=6,e;case 7:return e=a.oa(ld(a,2)),e=e+a.u[c]&65535,e=a.oa(e|a.N)|g,a.b-=10,e}a.u[c]=a.u[c]+f&65535;!g||a.D&57344||(a.Oa=a.Oa<<8|f<<3&248|c);6==c&&!a.w&&d&4&&0>=f&&(a.u[6]<=a.Qa||65534<=a.u[6])&&(a.u[6]<=a.Qa-32?(a.aa|=4,a.u[6]=4,a.ga(4,24)):(a.aa|=8,a.G|=64));return e}k.Db=function(a){if(!this.Ma)return this.A.Db(a);this.L++;a=Md(this,Ld(this,a,3));this.L--;return a}; +k.eb=function(a){if(!this.Ma)return this.A.eb(a);this.L++;a=this.fc(Ld(this,a,2));this.L--;return a};k.Ya=function(a,b){this.Ma?(this.L++,Nd(this,Ld(this,a,5),b),this.L--):this.A.Ya(a,b)};k.Hb=function(a,b){this.Ma?(this.L++,this.lc(Ld(this,a,4),b),this.L--):this.A.Hb(a,b)};k.rc=function(a,b,c){return Od(this,a,b,c)};k.sc=function(a,b,c){return Ld(this,Od(this,a,b,c),c)};k.fc=function(a){return this.A.na(a)};k.dd=function(a){return this.A.na(Ld(this,a,2))};k.lc=function(a,b){this.A.Za(a,b&65535)}; +k.Qd=function(a,b){this.A.Za(Ld(this,a,4),b)};function Pd(a,b,c){var d=a.f=b&7;(b=a.g=(b&56)>>3)?(d=Od(a,b,d,2),c&65536||61440!==(a.M&61440)&&(d&=65535),a.w=a.M>>12&3,c=a.oa(d|c&a.N),a.w=a.M>>14&3):c=6!=d||(a.M>>2&12288)===(a.M&12288)?a.u[d]:a.wa[a.M>>12&3];return c}function Qd(a,b,c,d){a.D&57344||(a.Oa=22);var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=Od(a,b,e,4),c&65536||(e&=65535),a.w=a.M>>12&3,e=Ld(a,e|c&65536,4),a.w=a.M>>14&3,a.A.Za(e,d)):6!=e||(a.M>>2&12288)===(a.M&12288)?a.u[e]=d:a.wa[a.M>>12&3]=d} function Rd(a,b){b>>=6;var c=a.H=b&7;return(b=a.F=(b&56)>>3)?Md(a,a.$(b,c,3)):a.u[c]&255}function Sd(a,b){b>>=6;var c=a.H=b&7;return(b=a.F=(b&56)>>3)?a.A.na(a.$(b,c,2)):a.u[c]}function Td(a,b){var c=a.f=b&7;b=a.g=(b&56)>>3;return Od(a,b,c,8)}function Ud(a,b){var c=a.f=b&7;return(b=a.g=(b&56)>>3)?Md(a,a.$(b,c,3)):a.u[c]&255}function Vd(a,b){var c=a.f=b&7;return(b=a.g=(b&56)>>3)?a.A.na(a.$(b,c,2)):a.u[c]} -function Q(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=a.$a=a.$(b,e,7),Nd(a,e,d.call(a,c,Md(a,e)))):a.u[e]=a.u[e]&65280|d.call(a,c,a.u[e])}function R(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=a.$(b,e,6),a.A.Ya(e,d.call(a,c,a.A.na(e)))):a.u[e]=d.call(a,c,a.u[e])}function Wd(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?Nd(a,a.$(b,e,5),c):a.u[e]=c?d&1?c<<24>>24&65535:a.u[e]&-256|c&255:a.u[e]&-256;return c}function Xd(a,b,c){var d=a.f=b&7;(b=a.g=(b&56)>>3)?a.A.Ya(a.$(b,d,4),c):a.u[d]=c&65535;return c} +function Q(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=a.bb=a.$(b,e,7),Nd(a,e,d.call(a,c,Md(a,e)))):a.u[e]=a.u[e]&65280|d.call(a,c,a.u[e])}function R(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?(e=a.$(b,e,6),a.A.Za(e,d.call(a,c,a.A.na(e)))):a.u[e]=d.call(a,c,a.u[e])}function Wd(a,b,c,d){var e=a.f=b&7;(b=a.g=(b&56)>>3)?Nd(a,a.$(b,e,5),c):a.u[e]=c?d&1?c<<24>>24&65535:a.u[e]&-256|c&255:a.u[e]&-256;return c}function Xd(a,b,c){var d=a.f=b&7;(b=a.g=(b&56)>>3)?a.A.Za(a.$(b,d,4),c):a.u[d]=c&65535;return c} function S(a,b,c){c&&(N(a,a.u[7]+(b<<24>>23)),a.b-=2);a.b-=3} -k.nb=function(a){this.v.complete=!0;var b=this.v.oc=this.i&&Yd(this.i),c=a?this.v.Qb?0:1:-1;this.v.Qb=!1;this.Y=this.b=a;do{if(b){if(Zd(this.i,this.u[7],c)){this.ca();break}c=1}if(this.G&&(this.G&112&&(this.G&32?this.ga(168,28):this.G&64?this.ga(4,30):this.G&16&&this.ga(12,32),this.G&=-113),this.G&7))if(this.G&2){this.G&=-3;var d=160,e=(this.Pb&224)>>5;if(a=this.P&&this.P.ib>e?this.P:null)d=a.jd,e=a.ib;e>(this.L&224)>>5?(this.G&4&&(ld(this,2),this.G&=-5),this.ga(d,26),e=!0):e=!1;if(e&&a)if(e=this.P, -e==a)this.P=a.next;else for(;e;){d=e.next;if(d==a){e.next=d.next;break}e=d}}else this.G&1&&this.G++;this.G=this.G&7|this.L&16;this.decode(kd(this))}while(0>5;if(a=this.R&&this.R.ib>e?this.R:null)d=a.kd,e=a.ib;e>(this.M&224)>>5?(this.G&4&&(ld(this,2),this.G&=-5),this.ga(d,26),e=!0):e=!1;if(e&&a)if(e=this.R, +e==a)this.R=a.next;else for(;e;){d=e.next;if(d==a){e.next=d.next;break}e=d}}else this.G&1&&this.G++;this.G=this.G&7|this.M&16;this.decode(kd(this))}while(0>1|b<<16;Gd(this,a);return a&65535}function ee(a,b){a=b&2048|b>>1|b<<8;Gd(this,a<<8);return a&255}function fe(a,b){a=b&~a;P(this,a);return a}function ge(a,b){a=b&~a;P(this,a<<8);return a}function he(a,b){a|=b;P(this,a);return a}function ie(a,b){a|=b;P(this,a<<8);return a}function je(a,b){a=~b|65536;Ed(this,a);return a&65535} -function ke(a,b){a=~b|256;Ed(this,a<<8);return a&255}function le(a,b){a=b-a;this.G&128||(this.W=this.Z=a,this.S=b&(b^a));return a&65535}function me(a,b){a=b-a;var c=a<<8;b<<=8;this.G&128||(this.W=this.Z=c,this.S=b&(b^c));return a&255}function ne(a,b){a=b+a;this.G&128||(this.W=this.Z=a,this.S=a&(b^a));return a&65535}function oe(a,b){a=b+a;var c=a<<8;this.G&128||(this.W=this.Z=c,this.S=c&(b<<8^c));return a&255}function pe(a,b){a=-b;Ed(this,a,a&b&32768);return a&65535} -function qe(a,b){a=-b;Ed(this,a<<8,(a&b&128)<<8);return a&255}function re(a,b){a=b<<1|this.R>>16&1;Gd(this,a);return a&65535}function se(a,b){a=b<<1|this.R>>16&1;Gd(this,a<<8);return a&255}function te(a,b){a=(this.R&65536|b)>>1|b<<16;Gd(this,a);return a&65535}function ue(a,b){a=((this.R&65536)>>8|b)>>1|b<<8;Gd(this,a<<8);return a&255}function ve(a,b){var c=b-a;Hd(this,c,a,b);return c&65535}function we(a,b){var c=b-a;Hd(this,c<<8,a<<8,b<<8);return c&255} -function xe(a,b){this.G&128||(this.W=this.Z=b&65280,this.S=this.R=0);return(b<<8|b>>8)&65535}function ye(a,b){a^=b;P(this,a);return a&65535}function ze(a){R(this,a,Sd(this,a),$d);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)} -function Ae(a){var b=Vd(this,a);a=a>>6&7;var c=this.u[a];c&32768&&(c|=4294901760);this.R=this.S=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.S=32768)}this.u[a]=c&65535;this.W=this.Z=c;this.b-=(this.g?6:7)+b} -function Be(a){var b=Vd(this,a);a=a>>6&7;var c=this.u[a]<<16|this.u[a|1];this.R=this.S=0;b&=63;if(b&32){b=64-b;32>b-1;this.R=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.u[a|1]=d&65535;this.W=d>>16;this.Z=d>>16|d;this.b-=(this.g?6:7)+b}function Ce(a){S(this,a,!hd(this))}function De(a){S(this,a,hd(this))} +function ke(a,b){a=~b|256;Ed(this,a<<8);return a&255}function le(a,b){a=b-a;this.G&128||(this.W=this.Z=a,this.T=b&(b^a));return a&65535}function me(a,b){a=b-a;var c=a<<8;b<<=8;this.G&128||(this.W=this.Z=c,this.T=b&(b^c));return a&255}function ne(a,b){a=b+a;this.G&128||(this.W=this.Z=a,this.T=a&(b^a));return a&65535}function oe(a,b){a=b+a;var c=a<<8;this.G&128||(this.W=this.Z=c,this.T=c&(b<<8^c));return a&255}function pe(a,b){a=-b;Ed(this,a,a&b&32768);return a&65535} +function qe(a,b){a=-b;Ed(this,a<<8,(a&b&128)<<8);return a&255}function re(a,b){a=b<<1|this.S>>16&1;Gd(this,a);return a&65535}function se(a,b){a=b<<1|this.S>>16&1;Gd(this,a<<8);return a&255}function te(a,b){a=(this.S&65536|b)>>1|b<<16;Gd(this,a);return a&65535}function ue(a,b){a=((this.S&65536)>>8|b)>>1|b<<8;Gd(this,a<<8);return a&255}function ve(a,b){var c=b-a;Hd(this,c,a,b);return c&65535}function we(a,b){var c=b-a;Hd(this,c<<8,a<<8,b<<8);return c&255} +function xe(a,b){this.G&128||(this.W=this.Z=b&65280,this.T=this.S=0);return(b<<8|b>>8)&65535}function ye(a,b){a^=b;P(this,a);return a&65535}function ze(a){R(this,a,Sd(this,a),$d);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)} +function Ae(a){var b=Vd(this,a);a=a>>6&7;var c=this.u[a];c&32768&&(c|=4294901760);this.S=this.T=0;b&=63;if(b&32)b=64-b,16>=b;else if(b)if(16>15&65535;d&&65535!==d&&(this.T=32768)}this.u[a]=c&65535;this.W=this.Z=c;this.b-=(this.g?6:7)+b} +function Be(a){var b=Vd(this,a);a=a>>6&7;var c=this.u[a]<<16|this.u[a|1];this.S=this.T=0;b&=63;if(b&32){b=64-b;32>b-1;this.S=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.u[a|1]=d&65535;this.W=d>>16;this.Z=d>>16|d;this.b-=(this.g?6:7)+b}function Ce(a){S(this,a,!hd(this))}function De(a){S(this,a,hd(this))} function Ee(a){R(this,a,Sd(this,a),fe);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)}function Fe(a){Q(this,a,Rd(this,a),ge);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)}function Ge(a){R(this,a,Sd(this,a),he);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)}function He(a){Q(this,a,Rd(this,a),ie);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)} function Ie(a){P(this,Sd(this,a)&Vd(this,a));this.b-=this.g?4+(this.H&&6<=this.f?1:0):(this.F?4:3)+(7==this.f?2:0)}function Je(a){P(this,(Rd(this,a)&Ud(this,a))<<8);this.b-=this.g?4+(this.H&&6<=this.f?1:0):(this.F?4:3)+(7==this.f?2:0)}function Ke(a){S(this,a,jd(this))}function Le(a){S(this,a,!this.Ea()==!id(this))}function Me(a){S(this,a,!jd(this)&&!this.Ea()==!id(this))}function Ne(a){S(this,a,!hd(this)&&!jd(this))}function Oe(a){S(this,a,jd(this)||!this.Ea()!=!id(this))} -function Pe(a){S(this,a,hd(this)||jd(this))}function Qe(a){S(this,a,!this.Ea()!=!id(this))}function Re(a){S(this,a,this.Ea())}function Se(a){S(this,a,!jd(this))}function Te(a){S(this,a,!this.Ea())}function Ue(){this.ga(12,1);this.b-=5}function Ve(a){S(this,a,!0)}function We(a){S(this,a,!id(this))}function Xe(a){S(this,a,id(this))}function T(a){a&1&&(this.R=0);a&2&&(this.S=0);a&4&&(this.Z=1);a&8&&(this.W=0);this.b-=5} +function Pe(a){S(this,a,hd(this)||jd(this))}function Qe(a){S(this,a,!this.Ea()!=!id(this))}function Re(a){S(this,a,this.Ea())}function Se(a){S(this,a,!jd(this))}function Te(a){S(this,a,!this.Ea())}function Ue(){this.ga(12,1);this.b-=5}function Ve(a){S(this,a,!0)}function We(a){S(this,a,!id(this))}function Xe(a){S(this,a,id(this))}function T(a){a&1&&(this.S=0);a&2&&(this.T=0);a&4&&(this.Z=1);a&8&&(this.W=0);this.b-=5} function Ye(a){var b=Sd(this,a);a=Vd(this,a);Hd(this,b-a,a,b);this.b-=this.g?4+(this.H&&6<=this.f?1:0):(this.F?4:3)+(7==this.f?2:0)}function Ze(a){var b=Rd(this,a)<<8;a=Ud(this,a)<<8;Hd(this,b-a,a,b);this.b-=this.g?4+(this.H&&6<=this.f?1:0):(this.F?4:3)+(7==this.f?2:0)} -function $e(a){var b=Vd(this,a);if(b){a=a>>6&7;var c=this.u[a]<<16|this.u[a|1];this.R=this.S=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.u[a]=d&65535,this.u[a|1]=c-d*b&65535,this.Z=d>>16|d,this.W=d>>16):(this.S=32768,this.Z=d>>15|d,this.W=c>>16,-1===b&&65534===this.u[a]&&(this.u[a]=this.u[a|1]=1));this.b-=53}else this.Z=this.W=0,this.S=32768,this.R=65536,this.b-=7}function af(){this.ga(24,2);this.b-=25} -function bf(){this.L&49152?(this.aa|=128,this.ga(4,3)):this.i?$b(this.i):this.ca();this.b-=7}function cf(){this.ga(16,4);this.b-=25}var df=[0,7,7,10,7,11,9,13];function ef(a){var b=this.b;N(this,Td(this,a));this.b=b-df[this.g]}var ff=[0,14,14,17,14,18,16,20];function gf(a){var b=this.b,c=Td(this,a);a=a>>6&7;Id(this,this.u[a]);this.u[a]=this.u[7];N(this,c);this.b=b-ff[this.g]}var hf=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17]; -function jf(a){var b=Sd(this,a),c=this.b;P(this,Xd(this,a,b));this.b=c-hf[(this.F?8:0)+this.g]+(7!=this.f||this.g?0:2)}function kf(a){var b=Rd(this,a);P(this,Wd(this,a,b,1)<<8);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)}var lf=[7,13,13,17,14,18,17,21]; -function mf(a){var b=Vd(this,a);a=a>>6&7;b&32768&&(b|=-65536);var c=this.u[a];c&32768&&(c|=-65536);b=~~(b*c);this.u[a]=b>>16&65535;this.u[a|1]=b&65535;this.G&128||(this.W=b>>16,this.Z=this.W|b,this.S=0,this.R=-32768>b||32767>6;if(this.u[b]=this.u[b]-1&65535)N(this,this.u[7]-((a&63)<<1)),this.b+=1;this.b-=6}function sf(a){R(this,a,Sd(this,a),ve);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)} +function $e(a){var b=Vd(this,a);if(b){a=a>>6&7;var c=this.u[a]<<16|this.u[a|1];this.S=this.T=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.u[a]=d&65535,this.u[a|1]=c-d*b&65535,this.Z=d>>16|d,this.W=d>>16):(this.T=32768,this.Z=d>>15|d,this.W=c>>16,-1===b&&65534===this.u[a]&&(this.u[a]=this.u[a|1]=1));this.b-=53}else this.Z=this.W=0,this.T=32768,this.S=65536,this.b-=7}function af(){this.ga(24,2);this.b-=25} +function bf(){this.M&49152?(this.aa|=128,this.ga(4,3)):this.i?$b(this.i):this.ca();this.b-=7}function cf(){this.ga(16,4);this.b-=25}var df=[0,7,7,10,7,11,9,13];function ef(a){this.J=this.b;N(this,Td(this,a));this.b=this.J-df[this.g]}var ff=[0,14,14,17,14,18,16,20];function gf(a){this.J=this.b;var b=Td(this,a);a=a>>6&7;Id(this,this.u[a]);this.u[a]=this.u[7];N(this,b);this.b=this.J-ff[this.g]}var hf=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17]; +function jf(a){var b=Sd(this,a);this.J=this.b;P(this,Xd(this,a,b));this.b=this.J-hf[(this.F?8:0)+this.g]+(7!=this.f||this.g?0:2)}function kf(a){var b=Rd(this,a);P(this,Wd(this,a,b,1)<<8);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)}var lf=[7,13,13,17,14,18,17,21]; +function mf(a){var b=Vd(this,a);a=a>>6&7;b&32768&&(b|=-65536);var c=this.u[a];c&32768&&(c|=-65536);b=~~(b*c);this.u[a]=b>>16&65535;this.u[a|1]=b&65535;this.G&128||(this.W=b>>16,this.Z=this.W|b,this.T=0,this.S=-32768>b||32767>6;if(this.u[b]=this.u[b]-1&65535)N(this,this.u[7]-((a&63)<<1)),this.b+=1;this.b-=6}function sf(a){R(this,a,Sd(this,a),ve);this.b-=this.g?9+(this.H&&6<=this.f?1:0):(this.F?5:3)+(7==this.f?2:0)} function tf(a){R(this,a,0,xe);this.b-=this.g?9:3+(7==this.f?2:0)}function uf(){this.ga(28,5);this.b-=5}function vf(){this.G&4||this.B.ba();this.G|=4;ld(this,-2);this.b-=3}function wf(a){R(this,a,Sd(this,a),ye);this.b-=this.g?9:3+(7==this.f?2:0)}function U(a){var b;if(b=this.i)b=this.i,D(b,"undefined opcode "+J(b,a),!0,!0),b=$b(b);b||this.ga(8,6)}function cd(a){xf[a>>12].call(this,a)}function yf(a){zf[a>>6&3].call(this,a)}function Af(a){Bf[a>>6&3].call(this,a)} function Cf(a){Df[a>>6&3].call(this,a)}function Ef(a){Ff[a&15].call(this,a)}function Gf(a){Hf[a&15].call(this,a)}function If(a){Jf[a>>6&3].call(this,a)}function Kf(a){Lf[a>>6&3].call(this,a)}function Mf(a){Nf[a>>6&3].call(this,a)} var xf=[function(a){Of[a>>8&15].call(this,a)},jf,Ye,Ie,Ee,Ge,ze,U,function(a){Pf[a>>8&15].call(this,a)},kf,Ze,Je,Fe,He,sf,U],Of=[function(a){Qf[a>>4&15].call(this,a)},Ve,Se,Ke,Le,Qe,Me,Oe,gf,gf,yf,Af,Cf,U,U,U],zf=[function(a){Ed(this,Xd(this,a,0));this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,0,je);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,1,ne);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,1,le);this.b-=this.g?9:3+(7==this.f?2:0)}],Bf=[function(a){R(this,a,0, pe);this.b-=this.g?11:6},function(a){R(this,a,hd(this)?1:0,$d);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,hd(this)?1:0,ve);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){a=Vd(this,a);Ed(this,a);this.b-=this.g?4:3+(7==this.f?2:0)}],Df=[function(a){R(this,a,0,te);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,0,re);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,0,de);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){R(this,a,0,be);this.b-=this.g?9:3+(7==this.f?2:0)}], -Qf=[function(a){Rf[a&15].call(this,a)},U,U,U,ef,ef,ef,ef,qf,U,Ef,Gf,tf,tf,tf,tf],Rf=[bf,vf,pf,Ue,cf,of,U,U,U,U,U,U,U,U,U,U],Ff=[nf,function(){this.R=0;this.b-=5},function(){this.S=0;this.b-=5},T,function(){this.Z=1;this.b-=5},T,T,T,function(){this.W=0;this.b-=5},T,T,T,T,T,T,T],Hf=[nf,function(){this.R=65536;this.b-=5},function(){this.S=32768;this.b-=5},W,function(){this.Z=0;this.b-=5},W,W,W,function(){this.W=32768;this.b-=5},W,W,W,W,W,W,W],Pf=[Te,Re,Ne,Pe,We,Xe,Ce,De,af,uf,If,Kf,Mf,U,U,U],Jf=[function(a){Ed(this, +Qf=[function(a){Rf[a&15].call(this,a)},U,U,U,ef,ef,ef,ef,qf,U,Ef,Gf,tf,tf,tf,tf],Rf=[bf,vf,pf,Ue,cf,of,U,U,U,U,U,U,U,U,U,U],Ff=[nf,function(){this.S=0;this.b-=5},function(){this.T=0;this.b-=5},T,function(){this.Z=1;this.b-=5},T,T,T,function(){this.W=0;this.b-=5},T,T,T,T,T,T,T],Hf=[nf,function(){this.S=65536;this.b-=5},function(){this.T=32768;this.b-=5},W,function(){this.Z=0;this.b-=5},W,W,W,function(){this.W=32768;this.b-=5},W,W,W,W,W,W,W],Pf=[Te,Re,Ne,Pe,We,Xe,Ce,De,af,uf,If,Kf,Mf,U,U,U],Jf=[function(a){Ed(this, Wd(this,a,0));this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,ke);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,oe);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,1,me);this.b-=this.g?9:3+(7==this.f?2:0)}],Lf=[function(a){Q(this,a,0,qe);this.b-=this.g?11:6},function(a){Q(this,a,hd(this)?1:0,ae);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,hd(this)?1:0,we);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){a=Ud(this,a);Ed(this,a<<8);this.b-=this.g?4:3+(7== -this.f?2:0)}],Nf=[function(a){Q(this,a,0,ue);this.b-=this.g?9+(this.$a&1):3+(7==this.f?2:0)},function(a){Q(this,a,0,se);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,ee);this.b-=this.g?9+(this.$a&1):3+(7==this.f?2:0)},function(a){Q(this,a,0,ce);this.b-=this.g?9:3+(7==this.f?2:0)}];function dd(a){Sf[a>>12].call(this,a)} -var Sf=[function(a){lg[a>>8&15].call(this,a)},jf,Ye,Ie,Ee,Ge,ze,function(a){mg[a>>8&15].call(this,a)},function(a){ng[a>>8&15].call(this,a)},kf,Ze,Je,Fe,He,sf,U],lg=[function(a){og[a>>4&15].call(this,a)},Ve,Se,Ke,Le,Qe,Me,Oe,gf,gf,yf,Af,Cf,function(a){pg[a>>6&3].call(this,a)},U,U],pg=[function(a){a=this.u[7]+((a&63)<<1)&65535;var b=this.oa(a|this.M);N(this,this.u[5]);this.u[6]=a+2&65535;this.u[5]=b;this.b-=8},function(a){a=Pd(this,a,0);Id(this,a);P(this,a);this.b-=11},function(a){var b=Kd(this),c= -this.b;Qd(this,a,0,b);P(this,b);this.b=c-lf[this.g]},function(a){P(this,Xd(this,a,this.Ea?65535:0));this.b-=this.g?9:3+(7==this.f?2:0)}],og=[function(a){qg[a&15].call(this,a)},U,U,U,ef,ef,ef,ef,qf,function(a){a&8?(this.L&49152||(this.L=this.L&-2017|(a&7)<<5,this.G|=1),this.b-=5):U.call(this,a)},Ef,Gf,tf,tf,tf,tf],qg=[bf,vf,pf,Ue,cf,of,function(){Jd(this);this.b-=13},U,U,U,U,U,U,U,U,U],mg=[mf,mf,$e,$e,Ae,Ae,Be,Be,wf,wf,U,U,U,U,rf,rf],ng=[Te,Re,Ne,Pe,We,Xe,Ce,De,af,uf,If,Kf,Mf,function(a){rg[a>>6&3].call(this, -a)},U,U],rg=[U,function(a){a=Pd(this,a,65536);Id(this,a);P(this,a);this.b-=11},function(a){var b=Kd(this),c=this.b;Qd(this,a,65536,b);P(this,b);this.b=c-lf[this.g]},U]; -function sg(a){r.call(this,"ROM",a,sg);this.fa=this.f=null;this.D=a.addr;this.g=a.size;this.w=a.alias;this.B=a.file;this.F=oa(this.B);if(this.B){a=this.B;var b=pa(this.F);"json"!=b&&"hex"!=b&&(a=ra()+"/api/v1/dump?file="+this.B+"&format=bytes&decimal=true");var c=this;Ba(a,null,!0,function(a,b,f){f?c.ia("Unable to load ROM resource (error "+f+": "+a+")"):(jb(c.Sa,a,b),(a=Ca(a,b))?(c.f=a.ka,c.fa=a.fa):c.B=null,tg(c))})}}u(sg);sg.prototype.Ca=function(a,b,c,d){this.A=b;this.b=c;this.i=d;tg(this)}; +this.f?2:0)}],Nf=[function(a){Q(this,a,0,ue);this.b-=this.g?9+(this.bb&1):3+(7==this.f?2:0)},function(a){Q(this,a,0,se);this.b-=this.g?9:3+(7==this.f?2:0)},function(a){Q(this,a,0,ee);this.b-=this.g?9+(this.bb&1):3+(7==this.f?2:0)},function(a){Q(this,a,0,ce);this.b-=this.g?9:3+(7==this.f?2:0)}];function dd(a){Sf[a>>12].call(this,a)} +var Sf=[function(a){lg[a>>8&15].call(this,a)},jf,Ye,Ie,Ee,Ge,ze,function(a){mg[a>>8&15].call(this,a)},function(a){ng[a>>8&15].call(this,a)},kf,Ze,Je,Fe,He,sf,U],lg=[function(a){og[a>>4&15].call(this,a)},Ve,Se,Ke,Le,Qe,Me,Oe,gf,gf,yf,Af,Cf,function(a){pg[a>>6&3].call(this,a)},U,U],pg=[function(a){a=this.u[7]+((a&63)<<1)&65535;var b=this.oa(a|this.N);N(this,this.u[5]);this.u[6]=a+2&65535;this.u[5]=b;this.b-=8},function(a){a=Pd(this,a,0);Id(this,a);P(this,a);this.b-=11},function(a){var b=Kd(this);this.J= +this.b;Qd(this,a,0,b);P(this,b);this.b=this.J-lf[this.g]},function(a){P(this,Xd(this,a,this.Ea?65535:0));this.b-=this.g?9:3+(7==this.f?2:0)}],og=[function(a){qg[a&15].call(this,a)},U,U,U,ef,ef,ef,ef,qf,function(a){a&8?(this.M&49152||(this.M=this.M&-2017|(a&7)<<5,this.G|=1),this.b-=5):U.call(this,a)},Ef,Gf,tf,tf,tf,tf],qg=[bf,vf,pf,Ue,cf,of,function(){Jd(this);this.b-=13},U,U,U,U,U,U,U,U,U],mg=[mf,mf,$e,$e,Ae,Ae,Be,Be,wf,wf,U,U,U,U,rf,rf],ng=[Te,Re,Ne,Pe,We,Xe,Ce,De,af,uf,If,Kf,Mf,function(a){rg[a>> +6&3].call(this,a)},U,U],rg=[U,function(a){a=Pd(this,a,65536);Id(this,a);P(this,a);this.b-=11},function(a){var b=Kd(this);this.J=this.b;Qd(this,a,65536,b);P(this,b);this.b=this.J-lf[this.g]},U]; +function sg(a){r.call(this,"ROM",a,sg);this.fa=this.f=null;this.D=a.addr;this.g=a.size;this.w=a.alias;this.B=a.file;this.F=oa(this.B);if(this.B){a=this.B;var b=pa(this.F);"json"!=b&&"hex"!=b&&(a=ra()+"/api/v1/dump?file="+this.B+"&format=bytes&decimal=true");var c=this;Ba(a,null,!0,function(a,b,f){f?c.ia("Unable to load ROM resource (error "+f+": "+a+")"):(jb(c.Sa,a,b),(a=Ca(a,b))?(c.f=a.la,c.fa=a.fa):c.B=null,tg(c))})}}u(sg);sg.prototype.Ca=function(a,b,c,d){this.A=b;this.b=c;this.i=d;tg(this)}; sg.prototype.ya=function(){this.fa&&(this.i&&ug(this.i,this.id,this.D,this.g,this.fa),delete this.fa);return!0};sg.prototype.xa=function(){return!0}; -function tg(a){if(!pb(a)){if(a.B){if(!a.f||!a.A)return;a.g||(a.g=a.f.length);if(a.f.length!=a.g)rb(a,"ROM size ("+l(a.f.length,8,!0)+") does not match specified size ("+l(a.g,8,!0)+")");else{var b;b=a.D;if(Yb(a.A,b,a.g,Dc)){var c;for(c=0;c>>a.ha;0=b.length)break;for(var h=h+2,p=b[h++]&255|(b[h++]&255)<<8,q=b[h++]&255|(b[h++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=h,w=p-=6;0=b.length)break;m+=b[h++]&255;if(m&255)break;if(w)for(;w--;)a.b.Xa(q++,b[v++]&255);else q&1?a.b.ca():gd(a.b,q,f);g=!0}else h++;else h+=2}if(!g&&(null==c&&(c=e),null!=c)){for(e=0;e>>a.ha;0=b.length)break;for(var h=h+2,p=b[h++]&255|(b[h++]&255)<<8,q=b[h++]&255|(b[h++]&255)<<8,m=m+((p&255)+(p>>8)+(q&255)+(q>>8)),v=h,w=p-=6;0=b.length)break;m+=b[h++]&255;if(m&255)break;if(w)for(;w--;)a.b.Ya(q++,b[v++]&255);else q&1?a.b.ca():gd(a.b,q,f);g=!0}else h++;else h+=2}if(!g&&(null==c&&(c=e),null!=c)){for(e=0;e=b)a.preventDefault&&a.preventDefault(),64");if(2==b.length){var c=va(b[0]);if(c!=this.Za)return;b=va(b[1]);if(this.J=lb(b)){var d=this.J.exports;if(d){var e=d.connect;e&&e.call(this.J);if(this.K=d.receiveData){this.status(this.Sa+"."+c+" connected to "+b);return}}}}this.status("Unable to establish connection: "+a)}}};k.ya=function(a,b){if(!b)if(this.cc(),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0}; -k.xa=function(a){return a?this.save():!0};k.reset=function(){Bg(this)};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return Bg(this)};function Bg(a){a.P=0;a.f=0;a.g=128;a.D=[];return!0}k.Ob=function(a){if("number"==typeof a)this.D.push(a);else if("string"==typeof a)for(var b=0;b":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.U||8,c=a-this.H%a,this.U&&(b=ua("",c)));this.N&&!this.H&&c&&(b=String.fromCharCode(this.N)+b);this.w.value+=b;this.w.scrollTop=this.w.scrollHeight;this.H+=c}else if(null!=this.F){if(10==a||1024<=this.F.length)this.j(this.F), -this.F="";10!=a&&(this.F+=String.fromCharCode(a))}this.g&=-129;jc(this.b,this.Y,1E3/Math.round(this.O/10))}};var Cg={},Ag=(Cg[65392]=[null,null,X.prototype.Sc,X.prototype.Ed,"RCSR"],Cg[65394]=[null,null,X.prototype.Rc,X.prototype.Dd,"RBUF"],Cg[65396]=[null,null,X.prototype.ed,X.prototype.Rd,"XCSR"],Cg[65398]=[null,null,X.prototype.dd,X.prototype.Qd,"XBUF"],Cg);Ta(function(){for(var a=C(document,"pdp11","serial"),b=0;b");if(2==b.length){var c=va(b[0]);if(c!=this.$a)return;b=va(b[1]);if(this.J=lb(b)){var d=this.J.exports;if(d){var e=d.connect;e&&e.call(this.J);if(this.K=d.receiveData){this.status(this.Sa+"."+c+" connected to "+b);return}}}}this.status("Unable to establish connection: "+a)}}};k.ya=function(a,b){if(!b)if(this.cc(),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0}; +k.xa=function(a){return a?this.save():!0};k.reset=function(){Bg(this)};k.save=function(){var a=new O(this);a.set(0,[]);return a.data()};k.restore=function(){return Bg(this)};function Bg(a){a.P=0;a.f=0;a.g=128;a.D=[];return!0}k.Ob=function(a){if("number"==typeof a)this.D.push(a);else if("string"==typeof a)for(var b=0;b":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.R||8,c=a-this.H%a,this.R&&(b=ua("",c)));this.N&&!this.H&&c&&(b=String.fromCharCode(this.N)+b);this.w.value+=b;this.w.scrollTop=this.w.scrollHeight;this.H+=c}else if(null!=this.F){if(10==a||1024<=this.F.length)this.j(this.F), +this.F="";10!=a&&(this.F+=String.fromCharCode(a))}this.g&=-129;jc(this.b,this.Y,1E3/Math.round(this.O/10))}};var Cg={},Ag=(Cg[65392]=[null,null,X.prototype.Tc,X.prototype.Fd,"RCSR"],Cg[65394]=[null,null,X.prototype.Sc,X.prototype.Ed,"RBUF"],Cg[65396]=[null,null,X.prototype.fd,X.prototype.Sd,"XCSR"],Cg[65398]=[null,null,X.prototype.ed,X.prototype.Rd,"XBUF"],Cg);Ta(function(){for(var a=C(document,"pdp11","serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.I[b]=c,!0;case "loadTape":e=2;case "attachTape":return e||(e=1),this.I[b]=c,c.onclick= function(){var a=d.I.listTapes;a&&Fg(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.N){c.parentNode.removeChild(c);break}this.I[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;Fg(d,oa(b,!0),b,1,a)}return!1};return!0;case "readProgress":return this.I[b]=c,!0}return!1}; -k.Ca=function(a,b,c,d){this.B=a;this.A=b;this.b=c;this.i=d;this.P=Gg(a);var e=this;if((this.g=Qc(this.B,"autoMount")||this.g)&&"string"==typeof this.g)try{this.g=eval("("+this.g+")")}catch(f){n("PC11 auto-mount error: "+f.message+" ("+this.g+")"),this.g=null}this.U=kc(56,4);this.Y=hc(this.b,function(){1==(e.f&32769)&&!(e.f&128)&&e.Kc.indexOf("/api/v1/dump")&&(e=pa(c),f="json"==e||"gz"==e?encodeURI(c):ra()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!Ba(f,null,!0,function(e,f,g){var h=0>g&&a.B&&!a.B.v.ja;g?a.ia('Unable to load tape "'+b+'" (error '+g+": "+e+")",h):(jb(a.Sa,e,f),(e=Ca(e,f))&&Pg(a,b,c,d,e.ka,e.Ia, +function Og(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),Pg(a,b,c,d,e),a.H="?");Mg(a)};g.readAsArrayBuffer(e);return!0}0>c.indexOf("/api/v1/dump")&&(e=pa(c),f="json"==e||"gz"==e?encodeURI(c):ra()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!Ba(f,null,!0,function(e,f,g){var h=0>g&&a.B&&!a.B.v.ja;g?a.ia('Unable to load tape "'+b+'" (error '+g+": "+e+")",h):(jb(a.Sa,e,f),(e=Ca(e,f))&&Pg(a,b,c,d,e.la,e.Ia, e.Ha));a.v.Ja=!1;a.D&&(a.D--,a.D||H(a));Mg(a)})}function Jg(a,b,c,d){if((a=a.I.listTapes)&&a.options){for(var e=0;e=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};Rg.prototype.Zb=function(){return-1};Rg.prototype.$b=function(){}; +function Pg(a,b,c,d,e,f,g){a.F=c;a.w=d;2==d?a.P&&xg(a.P,e,f,g)?a.status("tape loaded: "+b):(a.F="",a.H=Dg,a.w=Eg,a.ia("No load address available for tape: "+b)):(a.K=0,a.J=e,a.status("tape attached: "+b),Hg(a,0))}function Ng(a,b){if(a.F||!1===b)a.F="",b||(a.w&&a.status(1==a.w?"tape detached":"tape unloaded"),a.H=Dg,a.w=Eg,Mg(a))}k.save=function(){return(new O(this)).data()};k.restore=function(){return!0};k.Mc=function(){return this.f&65534}; +k.yd=function(a){a&1&&(this.f&32768?(a&=-2,this.f&64&&ic(this.b,this.R)):(this.f&=-129,this.f|=2048,this.L=0,jc(this.b,this.Y,1E3/Math.round(this.X/10))));this.f=this.f&-66|a&65};k.Lc=function(){this.f&=-129;this.f|=2048;return this.L};k.xd=function(){};var Qg={},Ig=(Qg[65384]=[null,null,xc.prototype.Mc,xc.prototype.yd,"PRS"],Qg[65386]=[null,null,xc.prototype.Lc,xc.prototype.xd,"PRB"],Qg); +function Rg(a){r.call(this,"Debugger",a,Rg);this.Y=a.base||16;this.va=!1;this.J=0;this.O=!1;this.w=-1;this.g=[];this.R={}}u(Rg);var Sg={"||":0,"&&":1,"|":2,"^":3,"&":4,"!=":5,"==":5,">=":6,">":6,"<=":6,"<":6,">>>":7,">>":7,"<<":7,"-":8,"+":8,"%":9,"/":9,"*":9};Rg.prototype.Zb=function(){return-1};Rg.prototype.$b=function(){}; function Tg(a,b,c,d){if(c)if(b){0>a.w&&a.g.length&&(a.w=0);if(0>a.w||b!=a.g[a.w])a.g.splice(0,0,b),a.w=0;a.w--}else a.O?b="end":b=a.g[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(va(b.substring(c,f))),c=f+1}}return a} function Ug(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 Vg(a,b,c){var d;if(b){b=Wg(a,b);for(var e=0,f=!1,g=b,h=[],m=[],p=b.split(/(\|\||&&|\||^|&|!=|==|>=|>>>|>>|>|<=|<<|<|-|\+|%|\/|\*)/);e>=1;g=q+g;d>>=8}d=l(c,0,!0)+" "+c+". "+na(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.j((null!=b?b+": ":"")+d);return e}function Zg(a,b){if(b)return Yg(a,b,a.U[b]);var c=0;for(b in a.U)Yg(a,b,a.U[b]),c++;return 0>=1;g=q+g;d>>=8}d=l(c,0,!0)+" "+c+". "+na(c,0,!0)+" "+("0b"+g);32<=c&&127>c&&(d+=" '"+String.fromCharCode(c)+"'")}a.j((null!=b?b+": ":"")+d);return e}function Zg(a,b){if(b)return Yg(a,b,a.R[b]);var c=0;for(b in a.R)Yg(a,b,a.R[b]),c++;return 0this.b.fb?hh:[];ih(this,function(a){a:{var b=d.A.V,c=a[0],e=a=0,m=b.length;if(c){a=d.$(jh(d,c));if(-1===a){d.j("invalid address: "+c);break a}e=a>>>d.A.ha;m=1}d.j("blockid physical blockaddr used size type");d.j("-------- --------- ---------- ------ ------ ----");for(var c=-1,p=0;m--;){var q=b[e];q.type==c?p++||d.j("..."):(c=q.type,p=bc[c],q&&d.j(l(q.id,8)+" %"+l(e<d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a?"R"+a:6==a?"SP":"PC"}k.$b=function(a){var b;0<=a&&(8>a?b=this.b.u[a]:16>a?b=this.b.Fa[a-8]:20>a?b=this.b.va[a-16]:20==a&&(b=Lb(this.b)));return b}; -k.message=function(a,b){b&&(a+=" @"+J(this,Z(this.b.wb).C));this.ma&1073741824?this.ra.push(a):this.pa&&a==this.pa||(this.pa=a,this.ma&-2147483648&&(this.ca(),a+=" (cpu halted)"),this.j(a),this.b&&(a=this.b,Zc(a),a.pa=0,a.B.ba()))};function bh(a){var b;if(!Yd(a))a.F&&a.F.length&&a.j("instruction history buffer freed"),a.X=0,a.F=[];else if(!a.F||!a.F.length){a.F=Array(1E3);for(b=0;bd&&(d+=b.length);0>d&&(d=0);for(var e=b.length;db||7a?"R"+a:6==a?"SP":"PC"}k.$b=function(a){var b;0<=a&&(8>a?b=this.b.u[a]:16>a?b=this.b.Fa[a-8]:20>a?b=this.b.wa[a-16]:20==a&&(b=Lb(this.b)));return b}; +k.message=function(a,b){b&&(a+=" @"+J(this,Z(this.b.xb).C));this.ma&1073741824?this.ra.push(a):this.pa&&a==this.pa||(this.pa=a,this.ma&-2147483648&&(this.ca(),a+=" (cpu halted)"),this.j(a),this.b&&(a=this.b,Zc(a),a.ra=0,a.B.ba()))};function bh(a){var b;if(!Yd(a))a.F&&a.F.length&&a.j("instruction history buffer freed"),a.X=0,a.F=[];else if(!a.F||!a.F.length){a.F=Array(1E3);for(b=0;bd&&(d=a.b.eb(b)),65535!=(d&65535)&&(c=a.F[a.X],c.C=b,c.Ba=!1,++a.X==a.F.length&&(a.X=0)));return!1}function $b(a){var b=a.b;if(b.v.da)throw N(b,a.b.wb),a.ca(),-1;return!1} -function ah(a){var b,c;a.f=["bp"];if(a.M)for(b=1;b>>d.ha],!1)}a.M=["br"];if(a.D)for(b=1;b>>d.ha],!0);a.D=["bw"];a.Ra=0}k.Va=function(a,b,c){var d=!0;c||th(this,a,b,!1,!0);if(a!=this.f){var e=this.$(b);if(-1===e)this.j("invalid address: "+J(this,b.C)),d=!1;else{var f=this.A;f.V[e>>>f.ha].Va(e&f.A,a==this.D)}}d&&(a.push(b),c?b.Ba=!0:(uh(this,a,a.length-1,"set"),bh(this)));return d}; -function th(a,b,c,d,e){var f=!1;c=a.$(c);for(var g=1;g>>d.ha],b==a.D));h.Ba||bh(a);break}}return f}function vh(a,b){for(var c=1;cd&&(d=a.b.eb(b)),65535!=(d&65535)&&(c=a.F[a.X],c.C=b,c.Ba=!1,++a.X==a.F.length&&(a.X=0)));return!1}function $b(a){var b=a.b;if(b.v.da)throw N(b,a.b.xb),a.ca(),-1;return!1} +function ah(a){var b,c;a.f=["bp"];if(a.L)for(b=1;b>>d.ha],!1)}a.L=["br"];if(a.D)for(b=1;b>>d.ha],!0);a.D=["bw"];a.Ra=0}k.Wa=function(a,b,c){var d=!0;c||th(this,a,b,!1,!0);if(a!=this.f){var e=this.$(b);if(-1===e)this.j("invalid address: "+J(this,b.C)),d=!1;else{var f=this.A;f.V[e>>>f.ha].Wa(e&f.A,a==this.D)}}d&&(a.push(b),c?b.Ba=!0:(uh(this,a,a.length-1,"set"),bh(this)));return d}; +function th(a,b,c,d,e){var f=!1;c=a.$(c);for(var g=1;g>>d.ha],b==a.D));h.Ba||bh(a);break}}return f}function vh(a,b){for(var c=1;c>23)&65535,y=J(x,w);else if(8192==B)w=w.C-((f&63)<<1)&65535,y=J(x,w);else if(12288==B)y=J(x,f&7,1);else if(24576==B)y=J(x,f&63,1);else if(32768==B)y=J(x,f&255,1);else if(B=f&F,F&4032&&(B>>=6,F>>=6), -F&63)switch(F=B&7,B&56){case 0:y=oh(F);break;case 8:y="@"+oh(F);break;case 16:7>F?y="("+oh(F)+")+":(B=x.na(w,2),y="#"+J(x,B,0,!0));break;case 24:7>F?y="@("+oh(F)+")+":(B=x.na(w,2),y="@#"+J(x,B,0,!0));break;case 32:y="-("+oh(F)+")";break;case 40:y="@-("+oh(F)+")";break;case 48:B=x.na(w,2);y=J(x,B,0,!0)+"("+oh(F)+")";7==F&&(y=[y,J(x,B+w.C&65535)]);break;case 56:B=x.na(w,2),y="@"+J(x,B)+"("+oh(F)+")",7==F&&(y=[y,J(x,B+w.C&65535)])}x=y;if(!x||!x.length){h="INVALID";break}"string"!=typeof x&&(p=x[1],x= -x[0]);0b?(c=oh(b),c+="="+J(a,d.u[b])):13>b?c="A"+(b-8)+"="+J(a,d.Fa[b-8]):16<=b&&20>b?c="S"+(b-16)+"="+J(a,d.va[b-16]):20==b&&(c="PS="+J(a,Lb(d)));c&&(c+=" ");return c} -function Ah(a){var b,c="";for(b=0;6>b;b++)c+=zh(a,b);c=c+"\n"+(zh(a,6)+zh(a,7)+zh(a,20));return c+=yh(a,"T")+yh(a,"N")+yh(a,"Z")+yh(a,"V")+yh(a,"C")}k.Ub=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],v=ya(q,m,a.Ub);0>v&&q.splice(-(v+1),0,m)}p&&(h.a=p.replace(/''/g,'"'))}a.H.push({Ud:b,C:c,vc:d,fa:e,Tb:f})} -function Bh(a,b,c){var d=[],e=a.$(b)>>>0;for(b=0;b>>0,h=f.vc;if(e>=g&&eF?y="("+oh(F)+")+":(B=x.na(w,2),y="#"+J(x,B,0,!0));break;case 24:7>F?y="@("+oh(F)+")+":(B=x.na(w,2),y="@#"+J(x,B,0,!0));break;case 32:y="-("+oh(F)+")";break;case 40:y="@-("+oh(F)+")";break;case 48:B=x.na(w,2);y=J(x,B,0,!0)+"("+oh(F)+")";7==F&&(y=J(x,B+w.C&65535));break;case 56:B=x.na(w,2),y="@"+J(x,B)+"("+oh(F)+")",7==F&&(y="@"+J(x,B+w.C&65535))}x=y;if(!x||!x.length){h="INVALID";break}"string"!=typeof x&&(p=x[1],x=x[0]); +0b?(c=oh(b),c+="="+J(a,d.u[b])):13>b?c="A"+(b-8)+"="+J(a,d.Fa[b-8]):16<=b&&20>b?c="S"+(b-16)+"="+J(a,d.wa[b-16]):20==b&&(c="PS="+J(a,Lb(d)));c&&(c+=" ");return c}function Ah(a){var b,c="";for(b=0;6>b;b++)c+=zh(a,b);c=c+"\n"+(zh(a,6)+zh(a,7)+zh(a,20));return c+=yh(a,"T")+yh(a,"N")+yh(a,"Z")+yh(a,"V")+yh(a,"C")}k.Ub=function(a,b){return a[0]>b[0]?1:a[0]>>0,g],v=ya(q,m,a.Ub);0>v&&q.splice(-(v+1),0,m)}p&&(h.a=p.replace(/''/g,'"'))}a.H.push({Vd:b,C:c,vc:d,fa:e,Tb:f})}function Bh(a,b,c){var d=[],e=a.$(b)>>>0;for(b=0;b>>0,h=f.vc;if(e>=g&&eb)){d.u[b]=f&65535;break}a.j("unknown register: "+e);return}a.B.ba();a.j("updated registers:")}a.j(Ah(a));c&&(a.K=Z(d.u[7]),rh(a,J(a,a.K.C)))}}function Fh(a,b){b=va(b);var c=b.match(/^(['"])(.*?)\1$/);c?1b)){d.u[b]=f&65535;break}a.j("unknown register: "+e);return}a.B.ba();a.j("updated registers:")}a.j(Ah(a));c&&(a.K=Z(d.u[7]),rh(a,J(a,a.K.C)))}}function Fh(a,b){b=va(b);var c=b.match(/^(['"])(.*?)\1$/);c?1h[0].indexOf("+"))){var p=h[0]+":";h[2]&&(p+=" "+h[2]);a.j(p)}h[3]&&(g=h[3],f=null);f=xh(a,b,g,f);a.j(f);a.K=b;e-=b.C-m;c++}}} function wh(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.j(">> "+b):(a.O&&(a.j("ended assemble at "+J(a,a.N.C)),a.K=a.N,a.O=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.pa=null;if(pb(a)&&0q||"z"ka.length&&(a.j("note: only "+ka.length+" available"),Y=ka.length);ca-=Y;0>ca&&(null==ka[ka.length-1].C?(Y=ca+Y,ca=0):ca+=ka.length);var pd=[];"call"==Yf&&(xb=1E5,pd=["CALL"]);for(void 0!==Xf&&a.j(Y+" instructions earlier:");0=ka.length&&(ca=0);a.$a=Y;$f++;xb--}}$f||(a.j("no "+Zf+"history available"),a.$a=void 0)}else{var zb=jh(a,ja);if(zb){var lc=0;Ha&&("l"==Ha.charAt(0)&&(Ha=Ha.substr(1)||Zh),lc=Xg(a,Ha)>>>0,65536>4||1;ai--&&0pc?String.fromCharCode(pc):".";mc-=oc}Ab&&(Ab+="\n");Ab+=ja+" "+qd+(0==Cb?" "+cg:"")}Ab&&a.j(Ab);a.Ta=zb}}}}break;case "e":if("else"==g[0])break;var bb,rd,sd,td,ud=g[0],vd=g[1];"eb"==ud?(bb=1,rd=255,sd=a.sb,td=a.Gb):"e"==ud||"ew"==ud?(bb=2,rd=65535,sd=a.na,td=a.Ya):vd=null;if(null==vd)a.j("edit memory commands:"),a.j("\teb [a] [...] edit bytes at address a"),a.j("\tew [a] [...] edit words at address a");else{var qc=jh(a,vd);if(qc)for(var rc=2;rcka.length&&(a.j("note: only "+ka.length+" available"),Y=ka.length);ca-=Y;0>ca&&(null==ka[ka.length-1].C?(Y=ca+Y,ca=0):ca+=ka.length);var pd=[];"call"==Yf&&(xb=1E5,pd=["CALL"]);for(void 0!==Xf&&a.j(Y+" instructions earlier:");0=ka.length&&(ca=0);a.Va=Y;$f++;xb--}}$f||(a.j("no "+Zf+"history available"),a.Va=void 0)}else{var zb=jh(a,ja);if(zb){var lc=0;Ha&&("l"==Ha.charAt(0)&&(Ha=Ha.substr(1)||Zh),lc=Xg(a,Ha)>>>0,65536>4||1;ai--&&0pc?String.fromCharCode(pc):".";mc-=oc}Ab&&(Ab+="\n");Ab+=ja+" "+qd+(0==Cb?" "+cg:"")}Ab&&a.j(Ab);a.Ta=zb}}}}break;case "e":if("else"==g[0])break;var bb,rd,sd,td,ud=g[0],vd=g[1];"eb"==ud?(bb=1,rd=255,sd=a.tb,td=a.Gb):"e"==ud||"ew"==ud?(bb=2,rd=65535,sd=a.na,td=a.Za):vd=null;if(null==vd)a.j("edit memory commands:"),a.j("\teb [a] [...] edit bytes at address a"),a.j("\tew [a] [...] edit words at address a");else{var qc=jh(a,vd);if(qc)for(var rc=2;rcyd;){for(var Ia=null,ei=256;65536>Fb.C>>>0;){zd.C=a.na(Fb,2);if(null==Fb.C||!ei--)break;if(!(zd.C&1)){for(var fi=a,sc=zd,eg=null,Gb=sc.C,fg=Gb,Ad=1;6>=Ad&&Gb;Ad++){if(2\nLicense: GPL version 3 or later ");this.j("Portions adapted from the PDP-11/70 Emulator v1.4 by Paul Nankervis ");for(b=0;bKh){if(Mh(d,this.J)){this.D=new O(this,"1.30.1","failsafe");Mh(this.D)&&(Rh(this,d),a=2,Sh(this.D));this.D.set("timestamp",Aa());Th(this.D);var e=this.f&&!this.F;if(1==a||Da("Click OK to restore the previous PDPjs machine state, or CANCEL to reset the machine.")){if(c=Qh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Mh(d,g):("error"== +k.wb=function(a){void 0===a&&(a=this.f||(this.J?1:Kh));if(!this.B){this.B++;var b=!1,c=!1;this.O=!1;var d=this.K||new O(this,"1.30.1");if(-1==a)b=!0;else if(a>Kh){if(Mh(d,this.J)){this.D=new O(this,"1.30.1","failsafe");Mh(this.D)&&(Rh(this,d),a=2,Sh(this.D));this.D.set("timestamp",Aa());Th(this.D);var e=this.f&&!this.F;if(1==a||Da("Click OK to restore the previous PDPjs machine state, or CANCEL to reset the machine.")){if(c=Qh(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Mh(d,g):("error"== f&&"no machine state"!=g?(this.ia("Error: "+g),"unable to verify user"==g&&(Ka("user",""),this.g=null)):this.j(f+": "+g),Sh(d),Mh(d)?(c=Qh(d),e=!0):c=!1))}e&&Ph(this,c?d:null)}else 2==a&&d.clear()}else Ph(this);delete this.J;delete this.K}e=kb(this.id);for(f=0;fa[1];a=a[2];this.ea=!0;this.v.ja=!0;var d=this.I.power;d&&(d.textContent="Shutdown");this.b&&(Uh(this,this.b,b,c,a),this.b.ab());this.O&&(Rh(this,b),b.clear());!c&&this.D&&(this.D.clear(),delete this.D);this.B=0}; @@ -256,13 +255,13 @@ function Rh(a,b){if(Da("There may be a problem with your PDPjs machine.\n\nTo he function Hh(a,b,c){var d,e="none";if(a.B)return null;a.B--;var f=new O(a,"1.30.1"),g=new O(a,"1.30.1","validate"),h=Aa();g.set("timestamp",h);f.set("timestamp",h);f.set("version","1.30.1");f.set("url",window?window.location.href:null);f.set("browser",window?window.navigator.userAgent:"");a.b&&a.b.xa&&(c&&a.b.ca(),d=a.b.xa(b,c),"object"===typeof d&&f.set(a.b.id,d),c&&(a.b.v.ja=!1,!1===d&&(e=null)));for(var h=kb(a.id),m=0;ma?"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 k(a,b,c,d){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 l=window.XMLHttpRequest?new window.XMLHttpRequest:new window.ActiveXObject("Microsoft.XMLHTTP");c&&(l.onreadystatechange=function(){4===l.readyState&&(f=l.responseText,200==l.status||!l.status&&f.length&&"file:"==(window?window.location.protocol:"file:")||(e=l.status||-1),d&&d(a,f,e))});if(b&&"object"== typeof b){var n="",q;for(q in b)b.hasOwnProperty(q)&&(n&&(n+="&"),n+=q+"="+encodeURIComponent(b[q]));n=n.replace(/%20/g,"+");l.open("POST",a,!!c);l.setRequestHeader("Content-type","application/x-www-form-urlencoded");l.send(n)}else l.open("GET",a,!!c),"bytes"==b&&l.overrideMimeType("text/plain; charset=x-user-defined"),l.send();c||(f=l.responseText,200!=l.status&&(e=l.status||-1),d&&d(a,f,e),h=[f,e]);return h} -function ua(a,b){var c,d={N:null,T:null,la:null,ka: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.la=h.load;d.ka=h.exec;if(e=h.bytes)d.N=e;else if(e=h.words)for(d.N=Array(2*e.length),f=c=0;c>8&255;else if(e=h.data)for(d.N=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.ma=h.load;d.la=h.exec;if(e=h.bytes)d.N=e;else if(e=h.words)for(d.N=Array(2*e.length),f=c=0;c>8&255;else if(e=h.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=h;d.T=h.symbols;d.N.length?1==d.N.length&&(m(d.N[0]),d=null):(m("Empty resource: "+a),d=null)}catch(l){m("Resource data error ("+a+"): "+l.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;cb?this.Ka=this.id:(this.sa=this.id.substr(0,b),this.Ka=this.id.substr(b+1));this[a]=c;this.i={ready:!1,Ya:!1,gd:!1,O:!1,error:!1};this.Ua=null;this.i.error=!1;this.u={};this.D=null;v.push(this)}var Ia=void 0,Ja={}; +Ea(Aa("Opera")||Aa("iOS")?"onunload":"onbeforeunload",function(){Fa(p.exit)});function u(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.rb=b.comment;this.Ib=b;b=this.id.indexOf(".");0>b?this.La=this.id:(this.ta=this.id.substr(0,b),this.La=this.id.substr(b+1));this[a]=c;this.i={ready:!1,Za:!1,hd:!1,O:!1,error:!1};this.Va=null;this.i.error=!1;this.u={};this.D=null;v.push(this)}var Ia=void 0,Ja={}; if(window){Ia||(Ia=window.location.search.substr(1));for(var Ka,La=/\+/g,Ma=/([^&=]+)=?([^&]*)/g;Ka=Ma.exec(Ia);)Ja[decodeURIComponent(Ka[1].replace(La," "))]=decodeURIComponent(Ka[2].replace(La," "))}function Na(a){function b(){}if(window){if(!a)throw new TypeError;if(Object.create)return Object.create(a);var c=typeof a;if("object"!==c&&"function"!==c)throw new TypeError;}b.prototype=a;return new b} function w(a,b){b||(b=u);a.prototype=Na(b.prototype);a.prototype.constructor=a;a.prototype.parent=b.prototype}if(window){window.PCjs||(window.PCjs={});var Oa=window.PCjs.Machines||(window.PCjs.Machines={}),v=window.PCjs.Components||(window.PCjs.Components=[])}else Oa={},v=[];function Pa(a,b,c){Oa[a]&&b&&(Oa[a][b]=c)}function x(a){var b,c=[];a&&(a=0<(b=a.indexOf("."))?a.substr(0,b+1):"");for(b=0;b>2;this.g=this.c-1;this.v=this.B/this.c|0;this.ja=[];this.m=0;this.s=[];this.Bb=[ab,bb,cb,db];a=new F(this);eb(a,this.D);this.b=Array(this.v);for(b=0;b>8:e[2](b)&255):b&1&&(e=d.ja[a&-2])&&e[2]&&(c=e[2](b&-2)>>8);return 0<=c?c:c=gb(d,b)}function bb(a,b,c){var d=!1,e=this.controller,f=e.ja[a];if(f)if(f[1])f[1](b,c),d=!0;else{if(f[3]){a=f[2]?f[2](0):0;if(c&1)f[3](a&255|b<<8,c&-2);else f[3](a&-256|b,c);d=!0}}else c&1&&(f=e.ja[a&-2])&&f[3]&&(c&=-2,a=f[2]?f[2](0):0,f[3](a&255|b<<8,c),d=!0);d||gb(e,c)} -function cb(a,b){var c=-1,d=this.controller;(a=d.ja[a])&&(a[2]?c=a[2](b):a[0]&&(c=a[0](b)|a[0](b+1)<<8));return 0<=c?c:c=gb(d,b)}function db(a,b,c){var d=!1,e=this.controller;if(a=e.ja[a])a[3]?(a[3](b,c),d=!0):a[1]&&(a[1](b&255,c),a[1](b>>8,c+1),d=!0);d||gb(e,c)}function hb(a,b){if(b!=a.o){var c;a.o&&(c=(1<>>a.j;0h&&(t=h);if(!e&&n&&n.size){if(n.type==d){if(f+h<=n.ya)return n.Wa+=n.ya-f,n.ya=f,!0;if(f>=n.ya+n.Wa){t=n.size-(f-q);t>h&&(t=h);n.Wa=f-n.ya+t;f=q+a.c;h-=t;l++;continue}}return mb(1,f,h)}f=new F(a,f,t,a.c,d,e);eb(f,a.D,n);a.b[l++]=f;f=q+a.c;h-=t}if(0>=h){c/=1024;var z;e="";z?10>>=a.j;0>>=a.j;0>>a.j].eb(b&a.g,b)}function pb(a,b){return a.b[(b&a.h)>>>a.j].S(b&a.g,b)}$a.prototype.Ia=function(a,b){this.m++;this.b[(a&this.h)>>>this.j].kb(a&this.g,b&255,a);this.m--}; -function qb(a,b,c){a.b[(b&a.h)>>>a.j].Xa(b&a.g,c&65535,b)}function rb(a){for(var b=0,c=[],d=0;da.a.Oa)){var h=f[0]?f[0].bind(b):null,l=f[1]?f[1].bind(b):null,n=f[2]?f[2].bind(b):null,q=f[3]?f[3].bind(b):null;65472<=e&&65487>=e&&(!h&&n&&(h=function(a){return function(b){return a(b)&255}.bind(b)}(n)),!l&&q&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(q)));sb(a,e,e,h,l,n,q,f[4])}}}function ub(a,b){a.s.push(b)}function vb(a,b){a.m||G(a.a,4,b)} -function mb(a,b,c){m("Memory block error ("+a+": "+ja(b)+","+ja(c)+")");return!1}function H(a){u.call(this,"Device",a,H);this.c={data:0,fd:0,Va:20,uc:0};this.b={hd:0,ib:-1}}w(H);g=H.prototype;g.ea=function(a,b,c,d){this.j=b;this.a=c;this.D=d;var e=this;this.b.ib=wb(c,function(){e.b.oa|=128;e.b.oa&64&&(xb(e.a,e.b.vc),yb(e.a,e.b.ib,1E3/60))});this.b.vc=zb(64,6);tb(b,this,I);ub(b,this.reset.bind(this));C(this)};g.reset=function(){this.c.Va=this.c.Va&-120|20;this.b.oa=0}; -g.Qb=function(){var a=this.b.oa;this.b.oa&=-129;return a};g.Ec=function(a){this.b.oa=a;a&64&&yb(this.a,this.b.ib,1E3/60);this.b.oa=a&-129};g.Jb=function(a){return(a?this.c.uc:this.c.data)&65535};g.xc=function(a){this.c.data=a};g.Sb=function(){var a=this.a;return a.w&62337|a.La<<5|a.Ma<<1};g.Gc=function(a){var b=this.a;a&=62337;if(b.w!=a){b.w=a;b.La=a>>5&3;b.Ma=a>>1&15;var c=0;a&257&&(c=4,a&1&&(c|=2));b.Ga!=c&&(b.Ga=c,Ab(b))}Bb(this)}; -g.Tb=function(){var a=this.a.pa;a&65280&&(a=(a<<8|a>>8)&65535);return a};g.Ub=function(){return this.a.gb};g.Vb=function(){return this.a.qa};g.Hc=function(a){var b=this.a;1170>b.Oa&&(a&=-49);b.qa!=a&&(b.qa=a,a&16?(b.ab=4194303,b.Na=3915776):(b.ab=262143,b.Na=253952),Ab(b));Bb(this)};function Bb(a){a.c.Va=a.c.Va&-8|(a.a.Ga?a.a.qa&16?1:2:4)}g.ic=function(a){return this.a.F[1][a>>1&7]};g.Vc=function(a,b){this.a.F[1][b>>1&7]=a&65295};g.gc=function(a){return this.a.F[1][(a>>1&7)+8]}; -g.Tc=function(a,b){this.a.F[1][(b>>1&7)+8]=a&65295};g.hc=function(a){return this.a.U[1][a>>1&7]};g.Uc=function(a,b){b=b>>1&7;this.a.U[1][b]=a;this.a.F[1][b]&=65295};g.fc=function(a){return this.a.U[1][(a>>1&7)+8]};g.Sc=function(a,b){b=(b>>1&7)+8;this.a.U[1][b]=a;this.a.F[1][b]&=65295};g.Pb=function(a){return this.a.F[0][a>>1&7]};g.Dc=function(a,b){this.a.F[0][b>>1&7]=a&65295};g.Nb=function(a){return this.a.F[0][(a>>1&7)+8]};g.Bc=function(a,b){this.a.F[0][(b>>1&7)+8]=a&65295}; -g.Ob=function(a){return this.a.U[0][a>>1&7]};g.Cc=function(a,b){b=b>>1&7;this.a.U[0][b]=a;this.a.F[0][b]&=65295};g.Mb=function(a){return this.a.U[0][(a>>1&7)+8]};g.Ac=function(a,b){b=(b>>1&7)+8;this.a.U[0][b]=a;this.a.F[0][b]&=65295};g.oc=function(a){return this.a.F[3][a>>1&7]};g.ad=function(a,b){this.a.F[3][b>>1&7]=a&65295};g.mc=function(a){return this.a.F[3][(a>>1&7)+8]};g.Zc=function(a,b){this.a.F[3][(b>>1&7)+8]=a&65295};g.nc=function(a){return this.a.U[3][a>>1&7]}; -g.$c=function(a,b){b=b>>1&7;this.a.U[3][b]=a;this.a.F[3][b]&=65295};g.lc=function(a){return this.a.U[3][(a>>1&7)+8]};g.Yc=function(a,b){b=(b>>1&7)+8;this.a.U[3][b]=a;this.a.F[3][b]&=65295};g.Aa=function(a){a&=7;return this.a.A&2048?this.a.xa[a]:this.a.f[a]};g.Ca=function(a,b){b&=7;this.a.A&2048?this.a.xa[b]=a:this.a.f[b]=a};g.$b=function(){return this.a.A&49152?this.a.$[0]:this.a.f[6]};g.Mc=function(a){this.a.A&49152?this.a.$[0]=a:this.a.f[6]=a};g.cc=function(){return this.a.f[7]}; -g.Pc=function(a){this.a.f[7]=a};g.Ba=function(a){a&=7;return this.a.A&2048?this.a.f[a]:this.a.xa[a]};g.Da=function(a,b){b&=7;this.a.A&2048?this.a.f[b]=a:this.a.xa[b]=a};g.ac=function(){return 1==(this.a.A&49152)>>14?this.a.f[6]:this.a.$[1]};g.Nc=function(a){1==(this.a.A&49152)>>14?this.a.f[6]=a:this.a.$[1]=a};g.bc=function(){return 3==(this.a.A&49152)>>14?this.a.f[6]:this.a.$[3]};g.Oc=function(a){3==(this.a.A&49152)>>14?this.a.f[6]=a:this.a.$[3]=a};g.Lb=function(a){return this.a.wb[a-65504>>1]}; -g.zc=function(a,b){this.a.wb[b-65504>>1]=a};g.ub=function(a){return 65520==a?61183:0};g.Ab=function(){};g.kc=function(){return 1};g.Xc=function(){};g.Kb=function(){return this.a.I};g.yc=function(){this.a.I=0};g.Rb=function(){return this.a.vb};g.Fc=function(a,b){b&1||(a&=255);this.a.vb=a};g.Wb=function(a){return a?this.a.hb:0};g.Ic=function(a){var b=this.a;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1)}b.hb=a;b.l|=2};g.jc=function(a){return a?this.a.ra&65280:0};g.Wc=function(a){this.a.ra=a|255}; -g.Zb=function(){return Za(this.a)};g.Lc=function(a){Cb(this.a,a&-1809|Za(this.a)&1808);this.a.l|=128};g.zb=function(){}; -var J={},I=(J[62592]=[null,null,H.prototype.ic,H.prototype.Vc,"SISDR",1145],J[62608]=[null,null,H.prototype.gc,H.prototype.Tc,"SDSDR",1145],J[62624]=[null,null,H.prototype.hc,H.prototype.Uc,"SISAR",1145],J[62640]=[null,null,H.prototype.fc,H.prototype.Sc,"SDSAR",1145],J[62656]=[null,null,H.prototype.Pb,H.prototype.Dc,"KISDR",1145],J[62672]=[null,null,H.prototype.Nb,H.prototype.Bc,"KDSDR",1145],J[62688]=[null,null,H.prototype.Ob,H.prototype.Cc,"KISAR",1145],J[62704]=[null,null,H.prototype.Mb,H.prototype.Ac, -"KDSAR",1145],J[62798]=[null,null,H.prototype.Vb,H.prototype.Hc,"MMR3",1145],J[65382]=[null,null,H.prototype.Qb,H.prototype.Ec,"LKS"],J[65400]=[null,null,H.prototype.Jb,H.prototype.xc,"CNSL"],J[65402]=[null,null,H.prototype.Sb,H.prototype.Gc,"MMR0",1145],J[65404]=[null,null,H.prototype.Tb,H.prototype.zb,"MMR1",1145],J[65406]=[null,null,H.prototype.Ub,H.prototype.zb,"MMR2",1145],J[65408]=[null,null,H.prototype.oc,H.prototype.ad,"UISDR",1145],J[65424]=[null,null,H.prototype.mc,H.prototype.Zc,"UDSDR", -1145],J[65440]=[null,null,H.prototype.nc,H.prototype.$c,"UISAR",1145],J[65456]=[null,null,H.prototype.lc,H.prototype.Yc,"UDSAR",1145],J[65472]=[null,null,H.prototype.Aa,H.prototype.Ca,"R0SET0"],J[65473]=[null,null,H.prototype.Aa,H.prototype.Ca,"R1SET0"],J[65474]=[null,null,H.prototype.Aa,H.prototype.Ca,"R2SET0"],J[65475]=[null,null,H.prototype.Aa,H.prototype.Ca,"R3SET0"],J[65476]=[null,null,H.prototype.Aa,H.prototype.Ca,"R4SET0"],J[65477]=[null,null,H.prototype.Aa,H.prototype.Ca,"R5SET0"],J[65478]= -[null,null,H.prototype.$b,H.prototype.Mc,"R6KERNEL"],J[65479]=[null,null,H.prototype.cc,H.prototype.Pc,"R7KERNEL"],J[65480]=[null,null,H.prototype.Ba,H.prototype.Da,"R0SET1",1145],J[65481]=[null,null,H.prototype.Ba,H.prototype.Da,"R1SET1",1145],J[65482]=[null,null,H.prototype.Ba,H.prototype.Da,"R2SET1",1145],J[65483]=[null,null,H.prototype.Ba,H.prototype.Da,"R3SET1",1145],J[65484]=[null,null,H.prototype.Ba,H.prototype.Da,"R4SET1",1145],J[65485]=[null,null,H.prototype.Ba,H.prototype.Da,"R5SET1",1145], -J[65486]=[null,null,H.prototype.ac,H.prototype.Nc,"R6SUPER",1145],J[65487]=[null,null,H.prototype.bc,H.prototype.Oc,"R6USER",1145],J[65504]=[null,null,H.prototype.Lb,H.prototype.zc,"CTRL",1170],J[65520]=[null,null,H.prototype.ub,H.prototype.Ab,"LSIZE",1170],J[65522]=[null,null,H.prototype.ub,H.prototype.Ab,"HSIZE",1170],J[65524]=[null,null,H.prototype.kc,H.prototype.Xc,"SYSID",1170],J[65526]=[null,null,H.prototype.Kb,H.prototype.yc,"CPUERR",1170],J[65528]=[null,null,H.prototype.Rb,H.prototype.Fc, -"MB",1170],J[65530]=[null,null,H.prototype.Wb,H.prototype.Ic,"PIR"],J[65532]=[null,null,H.prototype.jc,H.prototype.Wc,"SL"],J[65534]=[null,null,H.prototype.Zb,H.prototype.Lc,"PSW"],J);I[62594]=I[62592];I[62596]=I[62592];I[62598]=I[62592];I[62600]=I[62592];I[62602]=I[62592];I[62604]=I[62592];I[62606]=I[62592];I[62610]=I[62608];I[62612]=I[62608];I[62614]=I[62608];I[62616]=I[62608];I[62618]=I[62608];I[62620]=I[62608];I[62622]=I[62608];I[62626]=I[62624];I[62628]=I[62624];I[62630]=I[62624];I[62632]=I[62624]; +Function.prototype.bind||(Function.prototype.bind=function(a){function b(){return e.apply(this instanceof c&&a?this:a,d.concat(Array.prototype.slice.call(arguments)))}function c(){}if("function"!=typeof this)throw new TypeError("Function.prototype.bind: non-callable object");var d=Array.prototype.slice.call(arguments,1),e=this;c.prototype=this.prototype;b.prototype=new c;return b});var Ua="undefined"!==typeof ArrayBuffer;function Va(a){u.call(this,"Panel",a,Va);this.b=0;this.i.mb=!0}w(Va);g=Va.prototype; +g.X=function(a,b,c,d){if(this.o&&this.o.X(a,b,c,d)||this.a&&this.a.X(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.u[b]=c,this.b++,!0;default:return"rled"==a?(this.u[b]=c,this.b++,!0):this.parent.X.call(this,a,b,c,d)}};g.fa=function(a,b,c,d){this.o=a;this.j=b;this.a=c;this.D=d};g.$=function(a,b){b||Wa();return!0};g.Z=function(){return!0}; +function Xa(a,b,c,d){if(a.u[b]){void 0===c&&(a.i.error=!0,a.K("Value for "+b+" is invalid"),D(a.a));var e=a.D&&a.D.b||8;c=!a.a.i.W||a.i.mb?8==e?ia(c,d):ja(c,d):"--------".substr(0,d||4);a.u[b].textContent!=c&&(a.u[b].textContent=c)}}function Ya(a,b,c,d){for(var e=0;e>2;this.g=this.c-1;this.v=this.B/this.c|0;this.ka=[];this.m=0;this.s=[];this.Cb=[ab,bb,cb,db];a=new F(this);eb(a,this.D);this.b=Array(this.v);for(b=0;b>8:e[2](b)&255):b&1&&(e=d.ka[a&-2])&&e[2]&&(c=e[2](b&-2)>>8);return 0<=c?c:c=gb(d,b)}function bb(a,b,c){var d=!1,e=this.controller,f=e.ka[a];if(f)if(f[1])f[1](b,c),d=!0;else{if(f[3]){a=f[2]?f[2](0):0;if(c&1)f[3](a&255|b<<8,c&-2);else f[3](a&-256|b,c);d=!0}}else c&1&&(f=e.ka[a&-2])&&f[3]&&(c&=-2,a=f[2]?f[2](0):0,f[3](a&255|b<<8,c),d=!0);d||gb(e,c)} +function cb(a,b){var c=-1,d=this.controller;(a=d.ka[a])&&(a[2]?c=a[2](b):a[0]&&(c=a[0](b)|a[0](b+1)<<8));return 0<=c?c:c=gb(d,b)}function db(a,b,c){var d=!1,e=this.controller;if(a=e.ka[a])a[3]?(a[3](b,c),d=!0):a[1]&&(a[1](b&255,c),a[1](b>>8,c+1),d=!0);d||gb(e,c)}function hb(a,b){if(b!=a.o){var c;a.o&&(c=(1<>>a.j;0h&&(t=h);if(!e&&n&&n.size){if(n.type==d){if(f+h<=n.ya)return n.Xa+=n.ya-f,n.ya=f,!0;if(f>=n.ya+n.Xa){t=n.size-(f-q);t>h&&(t=h);n.Xa=f-n.ya+t;f=q+a.c;h-=t;l++;continue}}return mb(1,f,h)}f=new F(a,f,t,a.c,d,e);eb(f,a.D,n);a.b[l++]=f;f=q+a.c;h-=t}if(0>=h){c/=1024;var z;e="";z?10>>=a.j;0>>=a.j;0>>a.j].fb(b&a.g,b)}function pb(a,b){return a.b[(b&a.h)>>>a.j].S(b&a.g,b)}$a.prototype.Ja=function(a,b){this.m++;this.b[(a&this.h)>>>this.j].lb(a&this.g,b&255,a);this.m--}; +function qb(a,b,c){a.b[(b&a.h)>>>a.j].Ya(b&a.g,c&65535,b)}function rb(a){for(var b=0,c=[],d=0;da.a.Ka)){var h=f[0]?f[0].bind(b):null,l=f[1]?f[1].bind(b):null,n=f[2]?f[2].bind(b):null,q=f[3]?f[3].bind(b):null;65472<=e&&65487>=e&&(!h&&n&&(h=function(a){return function(b){return a(b)&255}.bind(b)}(n)),!l&&q&&(l=function(a){return function(b,c){return a(b,c)}.bind(b)}(q)));sb(a,e,e,h,l,n,q,f[4])}}}function ub(a,b){a.s.push(b)}function vb(a,b){a.m||G(a.a,4,b)} +function mb(a,b,c){m("Memory block error ("+a+": "+ja(b)+","+ja(c)+")");return!1}function H(a){u.call(this,"Device",a,H);this.c={data:0,gd:0,Wa:20,vc:0};this.b={jd:0,jb:-1}}w(H);g=H.prototype;g.fa=function(a,b,c,d){this.j=b;this.a=c;this.D=d;var e=this;this.b.jb=wb(c,function(){e.b.pa|=128;e.b.pa&64&&(xb(e.a,e.b.wc),yb(e.a,e.b.jb,1E3/60))});this.b.wc=zb(64,6);tb(b,this,I);ub(b,this.reset.bind(this));C(this)};g.reset=function(){this.c.Wa=this.c.Wa&-120|20;this.b.pa=0}; +g.Rb=function(){var a=this.b.pa;this.b.pa&=-129;return a};g.Fc=function(a){this.b.pa=a;a&64&&yb(this.a,this.b.jb,1E3/60);this.b.pa=a&-129};g.Kb=function(a){return(a?this.c.vc:this.c.data)&65535};g.yc=function(a){this.c.data=a};g.Tb=function(){var a=this.a;return a.w&62337|a.Ma<<5|a.Na<<1};g.Hc=function(a){var b=this.a;a&=62337;if(b.w!=a){b.w=a;b.Ma=a>>5&3;b.Na=a>>1&15;var c=0;a&257&&(c=4,a&1&&(c|=2));b.Ha!=c&&(b.Ha=c,Ab(b))}Bb(this)}; +g.Ub=function(){var a=this.a.qa;a&65280&&(a=(a<<8|a>>8)&65535);return a};g.Vb=function(){return this.a.hb};g.Wb=function(){return this.a.ra};g.Ic=function(a){var b=this.a;1170>b.Ka&&(a&=-49);b.ra!=a&&(b.ra=a,a&16?(b.bb=4194303,b.Oa=3915776):(b.bb=262143,b.Oa=253952),Ab(b));Bb(this)};function Bb(a){a.c.Wa=a.c.Wa&-8|(a.a.Ha?a.a.ra&16?1:2:4)}g.jc=function(a){return this.a.F[1][a>>1&7]};g.Wc=function(a,b){this.a.F[1][b>>1&7]=a&65295};g.hc=function(a){return this.a.F[1][(a>>1&7)+8]}; +g.Uc=function(a,b){this.a.F[1][(b>>1&7)+8]=a&65295};g.ic=function(a){return this.a.U[1][a>>1&7]};g.Vc=function(a,b){b=b>>1&7;this.a.U[1][b]=a;this.a.F[1][b]&=65295};g.gc=function(a){return this.a.U[1][(a>>1&7)+8]};g.Tc=function(a,b){b=(b>>1&7)+8;this.a.U[1][b]=a;this.a.F[1][b]&=65295};g.Qb=function(a){return this.a.F[0][a>>1&7]};g.Ec=function(a,b){this.a.F[0][b>>1&7]=a&65295};g.Ob=function(a){return this.a.F[0][(a>>1&7)+8]};g.Cc=function(a,b){this.a.F[0][(b>>1&7)+8]=a&65295}; +g.Pb=function(a){return this.a.U[0][a>>1&7]};g.Dc=function(a,b){b=b>>1&7;this.a.U[0][b]=a;this.a.F[0][b]&=65295};g.Nb=function(a){return this.a.U[0][(a>>1&7)+8]};g.Bc=function(a,b){b=(b>>1&7)+8;this.a.U[0][b]=a;this.a.F[0][b]&=65295};g.pc=function(a){return this.a.F[3][a>>1&7]};g.bd=function(a,b){this.a.F[3][b>>1&7]=a&65295};g.nc=function(a){return this.a.F[3][(a>>1&7)+8]};g.$c=function(a,b){this.a.F[3][(b>>1&7)+8]=a&65295};g.oc=function(a){return this.a.U[3][a>>1&7]}; +g.ad=function(a,b){b=b>>1&7;this.a.U[3][b]=a;this.a.F[3][b]&=65295};g.mc=function(a){return this.a.U[3][(a>>1&7)+8]};g.Zc=function(a,b){b=(b>>1&7)+8;this.a.U[3][b]=a;this.a.F[3][b]&=65295};g.Aa=function(a){a&=7;return this.a.A&2048?this.a.xa[a]:this.a.f[a]};g.Ca=function(a,b){b&=7;this.a.A&2048?this.a.xa[b]=a:this.a.f[b]=a};g.ac=function(){return this.a.A&49152?this.a.aa[0]:this.a.f[6]};g.Nc=function(a){this.a.A&49152?this.a.aa[0]=a:this.a.f[6]=a};g.dc=function(){return this.a.f[7]}; +g.Qc=function(a){this.a.f[7]=a};g.Ba=function(a){a&=7;return this.a.A&2048?this.a.f[a]:this.a.xa[a]};g.Da=function(a,b){b&=7;this.a.A&2048?this.a.f[b]=a:this.a.xa[b]=a};g.bc=function(){return 1==(this.a.A&49152)>>14?this.a.f[6]:this.a.aa[1]};g.Oc=function(a){1==(this.a.A&49152)>>14?this.a.f[6]=a:this.a.aa[1]=a};g.cc=function(){return 3==(this.a.A&49152)>>14?this.a.f[6]:this.a.aa[3]};g.Pc=function(a){3==(this.a.A&49152)>>14?this.a.f[6]=a:this.a.aa[3]=a};g.Mb=function(a){return this.a.xb[a-65504>>1]}; +g.Ac=function(a,b){this.a.xb[b-65504>>1]=a};g.vb=function(a){return 65520==a?61183:0};g.Bb=function(){};g.lc=function(){return 1};g.Yc=function(){};g.Lb=function(){return this.a.I};g.zc=function(){this.a.I=0};g.Sb=function(){return this.a.wb};g.Gc=function(a,b){b&1||(a&=255);this.a.wb=a};g.Xb=function(a){return a?this.a.ib:0};g.Jc=function(a){var b=this.a;if(a&=65024){var c=a>>9;do a+=34;while(c>>=1)}b.ib=a;b.l|=2};g.kc=function(a){return a?this.a.sa&65280:0};g.Xc=function(a){this.a.sa=a|255}; +g.$b=function(){return Za(this.a)};g.Mc=function(a){Cb(this.a,a&-1809|Za(this.a)&1808);this.a.l|=128};g.Ab=function(){}; +var J={},I=(J[62592]=[null,null,H.prototype.jc,H.prototype.Wc,"SISDR",1145],J[62608]=[null,null,H.prototype.hc,H.prototype.Uc,"SDSDR",1145],J[62624]=[null,null,H.prototype.ic,H.prototype.Vc,"SISAR",1145],J[62640]=[null,null,H.prototype.gc,H.prototype.Tc,"SDSAR",1145],J[62656]=[null,null,H.prototype.Qb,H.prototype.Ec,"KISDR",1145],J[62672]=[null,null,H.prototype.Ob,H.prototype.Cc,"KDSDR",1145],J[62688]=[null,null,H.prototype.Pb,H.prototype.Dc,"KISAR",1145],J[62704]=[null,null,H.prototype.Nb,H.prototype.Bc, +"KDSAR",1145],J[62798]=[null,null,H.prototype.Wb,H.prototype.Ic,"MMR3",1145],J[65382]=[null,null,H.prototype.Rb,H.prototype.Fc,"LKS"],J[65400]=[null,null,H.prototype.Kb,H.prototype.yc,"CNSL"],J[65402]=[null,null,H.prototype.Tb,H.prototype.Hc,"MMR0",1145],J[65404]=[null,null,H.prototype.Ub,H.prototype.Ab,"MMR1",1145],J[65406]=[null,null,H.prototype.Vb,H.prototype.Ab,"MMR2",1145],J[65408]=[null,null,H.prototype.pc,H.prototype.bd,"UISDR",1145],J[65424]=[null,null,H.prototype.nc,H.prototype.$c,"UDSDR", +1145],J[65440]=[null,null,H.prototype.oc,H.prototype.ad,"UISAR",1145],J[65456]=[null,null,H.prototype.mc,H.prototype.Zc,"UDSAR",1145],J[65472]=[null,null,H.prototype.Aa,H.prototype.Ca,"R0SET0"],J[65473]=[null,null,H.prototype.Aa,H.prototype.Ca,"R1SET0"],J[65474]=[null,null,H.prototype.Aa,H.prototype.Ca,"R2SET0"],J[65475]=[null,null,H.prototype.Aa,H.prototype.Ca,"R3SET0"],J[65476]=[null,null,H.prototype.Aa,H.prototype.Ca,"R4SET0"],J[65477]=[null,null,H.prototype.Aa,H.prototype.Ca,"R5SET0"],J[65478]= +[null,null,H.prototype.ac,H.prototype.Nc,"R6KERNEL"],J[65479]=[null,null,H.prototype.dc,H.prototype.Qc,"R7KERNEL"],J[65480]=[null,null,H.prototype.Ba,H.prototype.Da,"R0SET1",1145],J[65481]=[null,null,H.prototype.Ba,H.prototype.Da,"R1SET1",1145],J[65482]=[null,null,H.prototype.Ba,H.prototype.Da,"R2SET1",1145],J[65483]=[null,null,H.prototype.Ba,H.prototype.Da,"R3SET1",1145],J[65484]=[null,null,H.prototype.Ba,H.prototype.Da,"R4SET1",1145],J[65485]=[null,null,H.prototype.Ba,H.prototype.Da,"R5SET1",1145], +J[65486]=[null,null,H.prototype.bc,H.prototype.Oc,"R6SUPER",1145],J[65487]=[null,null,H.prototype.cc,H.prototype.Pc,"R6USER",1145],J[65504]=[null,null,H.prototype.Mb,H.prototype.Ac,"CTRL",1170],J[65520]=[null,null,H.prototype.vb,H.prototype.Bb,"LSIZE",1170],J[65522]=[null,null,H.prototype.vb,H.prototype.Bb,"HSIZE",1170],J[65524]=[null,null,H.prototype.lc,H.prototype.Yc,"SYSID",1170],J[65526]=[null,null,H.prototype.Lb,H.prototype.zc,"CPUERR",1170],J[65528]=[null,null,H.prototype.Sb,H.prototype.Gc, +"MB",1170],J[65530]=[null,null,H.prototype.Xb,H.prototype.Jc,"PIR"],J[65532]=[null,null,H.prototype.kc,H.prototype.Xc,"SL"],J[65534]=[null,null,H.prototype.$b,H.prototype.Mc,"PSW"],J);I[62594]=I[62592];I[62596]=I[62592];I[62598]=I[62592];I[62600]=I[62592];I[62602]=I[62592];I[62604]=I[62592];I[62606]=I[62592];I[62610]=I[62608];I[62612]=I[62608];I[62614]=I[62608];I[62616]=I[62608];I[62618]=I[62608];I[62620]=I[62608];I[62622]=I[62608];I[62626]=I[62624];I[62628]=I[62624];I[62630]=I[62624];I[62632]=I[62624]; I[62634]=I[62624];I[62636]=I[62624];I[62638]=I[62624];I[62642]=I[62640];I[62644]=I[62640];I[62646]=I[62640];I[62648]=I[62640];I[62650]=I[62640];I[62652]=I[62640];I[62654]=I[62640];I[62658]=I[62656];I[62660]=I[62656];I[62662]=I[62656];I[62664]=I[62656];I[62666]=I[62656];I[62668]=I[62656];I[62670]=I[62656];I[62674]=I[62672];I[62676]=I[62672];I[62678]=I[62672];I[62680]=I[62672];I[62682]=I[62672];I[62684]=I[62672];I[62686]=I[62672];I[62690]=I[62688];I[62692]=I[62688];I[62694]=I[62688];I[62696]=I[62688]; I[62698]=I[62688];I[62700]=I[62688];I[62702]=I[62688];I[62706]=I[62704];I[62708]=I[62704];I[62710]=I[62704];I[62712]=I[62704];I[62714]=I[62704];I[62716]=I[62704];I[62718]=I[62704];I[65410]=I[65408];I[65412]=I[65408];I[65414]=I[65408];I[65416]=I[65408];I[65418]=I[65408];I[65420]=I[65408];I[65422]=I[65408];I[65426]=I[65424];I[65428]=I[65424];I[65430]=I[65424];I[65432]=I[65424];I[65434]=I[65424];I[65436]=I[65424];I[65438]=I[65424];I[65442]=I[65440];I[65444]=I[65440];I[65446]=I[65440];I[65448]=I[65440]; I[65450]=I[65440];I[65452]=I[65440];I[65454]=I[65440];I[65458]=I[65456];I[65460]=I[65456];I[65462]=I[65456];I[65464]=I[65456];I[65466]=I[65456];I[65468]=I[65456];I[65470]=I[65456];I[65506]=I[65504];I[65508]=I[65504];I[65510]=I[65504];I[65512]=I[65504];I[65514]=I[65504];I[65516]=I[65504];I[65518]=I[65504];r(function(){for(var a=B(document,"pdp11","device"),b=0;b>1),this.a=new Int32Array(this.c,0,this.size>>2),Jb(this,Fb?Kb:Lb);else{a=this.a=Array(this.size>> +function F(a,b,c,d,e,f){this.j=a;this.id=Gb+=2;this.a=null;this.ya=b;this.Xa=c;this.size=d||0;this.type=e||Hb;this.g=e==Ib;this.controller=null;eb(this);this.na=this.Eb=!1;if(this.size)if(f)this.controller=f,a=[null,0],this.a=a[0],Jb(this,f.Cb);else if(Ua)this.c=new ArrayBuffer(this.size),this.u=new DataView(this.c,0,this.size),this.b=new Uint8Array(this.c,0,this.size),this.m=new Uint16Array(this.c,0,this.size>>1),this.a=new Int32Array(this.c,0,this.size>>2),Jb(this,Fb?Kb:Lb);else{a=this.a=Array(this.size>> 2);for(f=0;f>2),b=0;b>8,c)},L:function(a){return this.a[a>>2]>>>((a&3)<<3)&255},ca:function(a,b){a&1&&vb(this.j,b);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},ha: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.ma=!0},G:function(a,b){return this.H(a,b)}, -P:function(a,b){return this.V(a,b)},fa:function(a,b,c){this.g||this.kb(a,b,c)},sa:function(a,b,c){this.g||this.ta(a,b,c)},C:function(a){return this.b[a]},J:function(a){return this.b[a]},M:function(a,b){a&1&&vb(this.j,b);return this.u.getUint16(a,!0)},ba:function(a,b){a&1&&vb(this.j,b);return this.m[a>>1]},da:function(a,b){this.b[a]=b;this.ma=!0},ga:function(a,b){this.b[a]=b;this.ma=!0},ia:function(a,b,c){a&1&&vb(this.j,c);this.u.setUint16(a,b,!0);this.ma=!0},ua:function(a,b,c){a&1&&vb(this.j,c);this.m[a>> -1]=b;this.ma=!0}};function eb(a,b,c){a.D=b;a.h=a.o=0;c&&((a.h=c.h)&&Nb(a,Ob,!1),(a.o=c.o)&&Pb(a,Ob,!1))}function Pb(a,b,c){c&&a.o||(a.jb=!a.g&&b[1]||a.w,a.Xa=!a.g&&b[3]||a.B);if(c||void 0===c)a.kb=b[1]||a.w,a.ta=b[3]||a.B}function Nb(a,b,c){c&&a.h||(a.eb=b[0]||a.s,a.S=b[2]||a.v);if(c||void 0===c)a.H=b[0]||a.s,a.V=b[2]||a.v}function Jb(a,b){b||(b=Qb);Nb(a,b,void 0);Pb(a,b,void 0)} -var Qb=[],Mb=[F.prototype.L,F.prototype.ha,F.prototype.ca,F.prototype.va],Ob=[F.prototype.G,F.prototype.fa,F.prototype.P,F.prototype.sa];if(Ua)var Lb=[F.prototype.C,F.prototype.da,F.prototype.M,F.prototype.ia],Kb=[F.prototype.J,F.prototype.ga,F.prototype.ba,F.prototype.ua]; -function Rb(a,b){u.call(this,"CPU",a,Rb);var c=a.multiplier||1;this.Ra=a.cycles||b;this.da=c;this.$a=Math.round(this.Ra/1E4)/100;this.fa=this.$a*this.da;this.i.W=!1;this.i.xb=!1;this.i.Fa=a.autoStart;this.i.Sa=!1;this.Pa=this.ha=0;this.Qa=a.csStart;this.ta=a.csInterval;this.ua=a.csStop;this.G=[];this.tb=this.tc.bind(this);C(this)}w(Rb);var Sb=["power","reset"];g=Rb.prototype; -g.ea=function(a,b,c,d){this.o=a;this.j=b;this.D=d;for(b=0;ba.ba/a.fa&&(b=1);a.da=b;b=a.$a*a.da;if(a.fa!=b){a.fa=b;b=a.fa.toFixed(2)+"Mhz";var d=a.u.setSpeed;d&&(d.textContent=b);a.R("target speed: "+b)}c&&a.o&&(c=a.o,c.wa&&c.wa.focus())}a.J+=a.P;a.P=0;a.M=sa();a.ca=0;Yb(a)}function wb(a,b){var c=a.G.length;a.G.push([-1,b]);return c}function yb(a,b,c){0<=b&&ba.G[b][0]&&(c=a.Ra*a.da/1E3*c|0,a.G[b][0]=c+$b(a))}function $b(a,b){var c=a.ga-=a.a;a.a=0;b&&(a.ga=0);return c} -g.tc=function(){if(this.i.W){this.bb>=this.Ra&&Yb(this,!0);this.Ea=0;this.Ja=sa();if(this.ca){var a=this.Ja-this.ca;a>this.rb&&(this.M+=a,this.M>this.Ja&&(this.M=this.Ja))}try{do{for(var b,c=this.i.Sa?1:this.Ta,d=this.G.length-1;0<=d;d--){var e=this.G[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.yb(b)}catch(n){if("number"!=typeof n)throw n;}b=$b(this,!0);this.Ea+=b;this.P+=b;a=b;if(this.i.Sa){var f=!1;this.Pa=this.Pa+this.nb()|0;this.ha-=a;0>=this.ha&&(this.ha+=this.ta,f=!0);0<=this.ua&&this.ua<=Zb(this)&& -(this.ta=this.ua=-1,Vb(this),D(this),f=!0);f&&this.R(Zb(this)+" cycles: checksum="+ja(this.Pa))}for(var a=b,h=this.G.length-1;0<=h;h--){var l=this.G[h];0>l[0]||(l[0]-=a,0>=l[0]&&(l[0]=-1,l[1]()))}this.va-=b;if(0>=this.va){this.va+=this.Ta;15<=++this.sb&&(this.o&&this.o.aa(),this.sb=0);break}}while(this.i.W)}catch(n){D(this);this.o&&this.o.stop(sa(),Zb(this));b=n.stack||n.message;this.i.error=!0;this.K(b);return}if(this.i.W){b=setTimeout;c=this.tb;this.ca=sa();d=this.rb;this.Ea&&(d=Math.round(d*this.Ea/ -this.Ta));d-=this.ca-this.Ja;if(e=this.ca-this.M)this.ba=Math.round(this.P/(10*e))/100,864E5<=e&&(this.J=0,Xb(this));if(0>d||this.bad&&(this.M-=d),d=0;this.bb+=this.Ea;this.ca+=d;b(c,d)}}};function Wb(a,b){var c;a.i.error?(a.R(a.toString()+" error"),c=!0):c=!1;if(!c)if(a.i.W)a.R(a.toString()+" busy");else{Xb(a);a.i.W=!0;a.i.xb=!0;if(c=a.u.run)c.textContent="Halt";a.o&&(b&&(b=a.o,b.wa&&b.wa.focus()),a.o.start(a.M,Zb(a)));setTimeout(a.tb,0)}}g.yb=function(){return 0}; -function D(a){if(a.i.W){$b(a);a.J+=a.P;a.P=0;a.i.W=!1;var b=a.u.run;b&&(b.textContent="Run");a.o&&a.o.stop(sa(),Zb(a))}a.i.complete=void 0}function ac(a){this.Oa=+a.model||1170;this.pb=a.addrReset||0;Rb.call(this,a,6666667);this.decode=1120==this.Oa?bc.bind(this):cc.bind(this);dc(this);this.cb=0;this.V=null;this.i.complete=this.i.Cb=!1}w(ac,Rb);g=ac.prototype;g.reset=function(){this.status("model "+this.Oa);this.i.W&&D(this);dc(this);Ub(this);this.i.error=!1;this.parent.reset.call(this)}; -function dc(a){a.m=65536;a.g=32768;a.h=65535;a.s=32768;a.A=15;a.f=[0,0,0,0,0,0,0,a.pb];a.xa=[0,0,0,0,0,0];a.$=[0,0,0,0];a.v=0;a.Ma=0;a.Gb=[4,2,0,1];a.F=[[0,0,0,0,0,0,0,0,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],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.U=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.Ib=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, -0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];a.wb=[0,0,0,0,0,0,0,0];a.vb=0;a.l=0;a.B=a.C=0;a.c=a.b=a.Za=0;a.ia=-1;ec(a)}function ec(a){a.ra=255;a.I=0;a.hb=0;a.w=0;a.pa=0;a.gb=0;a.qa=0;a.Ga=0;a.La=0;a.ab=262143;a.Na=253952;a.l|=2;a.j&&Ab(a)}function Ab(a){a.Ga?(a.L=65536,a.H=a.Fb,a.S=a.qc,a.Xa=a.cd,hb(a.j,a.qa&16?22:18)):(a.L=0,a.H=a.Eb,a.S=a.pc,a.Xa=a.bd,hb(a.j,16))}function fc(a,b,c){a.pb=b;L(a,b);!c&&a.D&&(D(a),a.D.aa())}g.nb=function(){return 0}; -g.save=function(){var a=new M(this);a.set(0,[]);a.set(1,[this.J,this.da]);a.set(2,rb(this.j));return a.data()};g.restore=function(a){var b=a[1];this.J=b[1];Xb(this,b[3]);a:{b=this.j;a=a[2];var c;for(c=0;c>14&3;c=a.A>>14&3;a.v!=c&&(a.$[c]=a.f[6],a.f[6]=a.$[a.v]);a.A=b;a.l|=2}function O(a,b){a.l&128||(a.s=a.h=b,a.g=0)}function P(a,b,c){a.l&128||(a.s=a.h=a.m=b,a.g=c||0)}function ic(a,b,c,d){a.l&128||(a.s=a.h=a.m=b,a.g=(c^b)&(d^b))}function Q(a,b){a.l&128||(a.s=a.h=a.m=b,a.g=a.s^a.m>>1)}function jc(a,b,c,d){a.l&128||(a.s=a.h=a.m=b,a.g=(c^d)&(d^b))} -function G(a,b,c){if(!a.cb){var d=!1;0>a.ia?a.ia=Za(a):a.v||(b=4,d=!0);a.w&57344||(a.pa=63222,a.gb=b);a.v=0;var e=a.S(b|a.L),f=a.S(b+2&65535|a.L);Cb(a,f&-12289|a.ia>>2&12288);d&&(a.I|=4,a.f[6]=4);kc(a,a.ia);kc(a,a.f[7]);L(a,e);a.l&=-113;a.ia=-1;if(26!=c)throw b;}}function lc(a){var b=mc(a),c=mc(a)&-1793;a.A&49152&&(c=c&-225|a.A&63712);L(a,b);Cb(a,c);a.l&=-17} -function nc(a,b,c){var d,e,f,h=0;d=b>>13;a.qa&a.Gb[a.v]||(d&=7);e=a.F[a.v][d];f=(a.U[a.v][d]<<6)+(b&8191)&a.ab;if(ff){if(3932160<=f){f&=262143;var l=f>>13&31;31>l?a.qa&32&&(f=a.Ib[l]+(f&8190)&4194302,3932160<=f&&4186112>f&&console.log("panic(898)")):f|=4186112}f>=a.Na&&4186112>f&&(a.I|=32,G(a,4,12))}switch(e&7){case 1:h=4096;case 2:e|=128;c&4&&(h=8192);break;case 4:h=4096;case 5:c&4&&(h=4096);case 6:e|=c&4?192: -128;break;default:h=32768}32512!==(e&32520)&&(e&8?e&32512&&(b&8128)<(e>>2&8128)&&(h|=16384):(b&8128)>(e>>2&8128)&&(h|=16384));a.F[a.v][d]=e;if(4194170!==f||a.v)a.La=a.v,a.Ma=d;h&&(h&57344&&(0<=a.ia&&(h|=128),a.w&57344||(a.w=a.w|h|a.La<<5|a.Ma<<1),G(a,168,16)),a.w&61440||!(4191360>f||4194239>>a.j].jb(b&a.g,c&255,b)}function mc(a){var b=a.S(a.f[6]|a.L);a.f[6]=a.f[6]+2&65535;return b} -function kc(a,b){var c=a.f[6]-2&65535;a.f[6]=c;a.w&57344||(a.pa=a.pa<<8|246);!a.v&&c<=a.ra&&4c&&d&1&&(f=1));a.a-=3;break;case 3:f=2;e=a.f[c];7!==c&&(e|=h);e=a.S(e);e|=h;a.a-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.f[c]+f&65535;7!==c&&(e|=h);a.a-=4;break;case 5:f=-2;e=a.f[c]-2&65535;7!==c&&(e|=h);e=a.S(e)|h;a.a-= -8;break;case 6:return e=a.S(hc(a,2)),e=e+a.f[c]&65535|h,a.a-=6,e;case 7:return e=a.S(hc(a,2)),e=e+a.f[c]&65535,e=a.S(e|a.L)|h,a.a-=10,e}a.f[c]=a.f[c]+f&65535;!h||a.w&57344||(a.pa=a.pa<<8|f<<3&248|c);6==c&&!a.v&&d&4&&0>=f&&(a.f[6]<=a.ra||65534<=a.f[6])&&(a.f[6]<=a.ra-32?(a.I|=4,a.f[6]=4,G(a,4,24)):(a.I|=8,a.l|=64));return e}g.Ia=function(a,b){this.Ga?(this.cb++,oc(this,nc(this,a,5),b),this.cb--):this.j.Ia(a,b)};g.Eb=function(a,b,c){return pc(this,a,b,c)}; -g.Fb=function(a,b,c){return nc(this,pc(this,a,b,c),c)};g.pc=function(a){return pb(this.j,a)};g.qc=function(a){return pb(this.j,nc(this,a,2))};g.bd=function(a,b){qb(this.j,a,b&65535)};g.cd=function(a,b){qb(this.j,nc(this,a,4),b)};function qc(a,b,c){var d=a.b=b&7;(b=a.c=(b&56)>>3)?(d=pc(a,b,d,2),c&65536||61440!==(a.A&61440)&&(d&=65535),a.v=a.A>>12&3,c=a.S(d|c&a.L),a.v=a.A>>14&3):c=6!=d||(a.A>>2&12288)===(a.A&12288)?a.f[d]:a.$[a.A>>12&3];return c} -function rc(a,b,c,d){a.w&57344||(a.pa=22);var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=pc(a,b,e,4),c&65536||(e&=65535),a.v=a.A>>12&3,e=nc(a,e|c&65536,4),a.v=a.A>>14&3,qb(a.j,e,d)):6!=e||(a.A>>2&12288)===(a.A&12288)?a.f[e]=d:a.$[a.A>>12&3]=d}function sc(a,b){b>>=6;var c=a.C=b&7;(b=a.B=(b&56)>>3)?(c=a.H(b,c,3),a=ob(a.j,c)):a=a.f[c]&255;return a}function R(a,b){b>>=6;var c=a.C=b&7;return(b=a.B=(b&56)>>3)?pb(a.j,a.H(b,c,2)):a.f[c]}function tc(a,b){var c=a.b=b&7;b=a.c=(b&56)>>3;return pc(a,b,c,8)} -function uc(a,b){var c=a.b=b&7;(b=a.c=(b&56)>>3)?(c=a.H(b,c,3),a=ob(a.j,c)):a=a.f[c]&255;return a}function vc(a,b){var c=a.b=b&7;return(b=a.c=(b&56)>>3)?pb(a.j,a.H(b,c,2)):a.f[c]}function S(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=a.Za=a.H(b,e,7),oc(a,e,d.call(a,c,ob(a.j,e)))):a.f[e]=a.f[e]&65280|d.call(a,c,a.f[e])}function T(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=a.H(b,e,6),qb(a.j,e,d.call(a,c,pb(a.j,e)))):a.f[e]=d.call(a,c,a.f[e])} -function wc(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?oc(a,a.H(b,e,5),c):a.f[e]=c?d&1?c<<24>>24&65535:a.f[e]&-256|c&255:a.f[e]&-256;return c}function xc(a,b,c){var d=a.b=b&7;(b=a.c=(b&56)>>3)?qb(a.j,a.H(b,d,4),c):a.f[d]=c&65535;return c}function U(a,b,c){c&&(L(a,a.f[7]+(b<<24>>23)),a.a-=2);a.a-=3} -g.yb=function(a){this.i.complete=!0;this.i.Cb=!1;this.i.xb=!1;this.ga=this.a=a;do{if(this.l&&(this.l&112&&(this.l&32?G(this,168,28):this.l&64?G(this,4,30):this.l&16&&G(this,12,32),this.l&=-113),this.l&7))if(this.l&2){this.l&=-3;var b=160,c=(this.hb&224)>>5;if(a=this.V&&this.V.za>c?this.V:null)b=a.wc,c=a.za;c>(this.A&224)>>5?(this.l&4&&(hc(this,2),this.l&=-5),G(this,b,26),c=!0):c=!1;if(c&&a)if(c=this.V,c==a)this.V=a.next;else for(;c;){b=c.next;if(b==a){c.next=b.next;break}c=b}}else this.l&1&&this.l++; -this.l=this.l&7|this.A&16;this.decode(gc(this))}while(0>2),b=0;b>8,c)},L:function(a){return this.a[a>>2]>>>((a&3)<<3)&255},ca:function(a,b){a&1&&vb(this.j,b);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},ha: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.na=!0},G:function(a,b){return this.H(a,b)}, +P:function(a,b){return this.V(a,b)},ea:function(a,b,c){this.g||this.lb(a,b,c)},ja:function(a,b,c){this.g||this.ta(a,b,c)},C:function(a){return this.b[a]},J:function(a){return this.b[a]},M:function(a,b){a&1&&vb(this.j,b);return this.u.getUint16(a,!0)},Y:function(a,b){a&1&&vb(this.j,b);return this.m[a>>1]},da:function(a,b){this.b[a]=b;this.na=!0},ga:function(a,b){this.b[a]=b;this.na=!0},ia:function(a,b,c){a&1&&vb(this.j,c);this.u.setUint16(a,b,!0);this.na=!0},ua:function(a,b,c){a&1&&vb(this.j,c);this.m[a>> +1]=b;this.na=!0}};function eb(a,b,c){a.D=b;a.h=a.o=0;c&&((a.h=c.h)&&Nb(a,Ob,!1),(a.o=c.o)&&Pb(a,Ob,!1))}function Pb(a,b,c){c&&a.o||(a.kb=!a.g&&b[1]||a.w,a.Ya=!a.g&&b[3]||a.B);if(c||void 0===c)a.lb=b[1]||a.w,a.ta=b[3]||a.B}function Nb(a,b,c){c&&a.h||(a.fb=b[0]||a.s,a.S=b[2]||a.v);if(c||void 0===c)a.H=b[0]||a.s,a.V=b[2]||a.v}function Jb(a,b){b||(b=Qb);Nb(a,b,void 0);Pb(a,b,void 0)} +var Qb=[],Mb=[F.prototype.L,F.prototype.ha,F.prototype.ca,F.prototype.va],Ob=[F.prototype.G,F.prototype.ea,F.prototype.P,F.prototype.ja];if(Ua)var Lb=[F.prototype.C,F.prototype.da,F.prototype.M,F.prototype.ia],Kb=[F.prototype.J,F.prototype.ga,F.prototype.Y,F.prototype.ua]; +function Rb(a,b){u.call(this,"CPU",a,Rb);var c=a.multiplier||1;this.Ta=a.cycles||b;this.ea=c;this.ab=Math.round(this.Ta/1E4)/100;this.ga=this.ab*this.ea;this.i.W=!1;this.i.yb=!1;this.i.Ga=a.autoStart;this.i.Sa=!1;this.Qa=this.ia=0;this.Ra=a.csStart;this.ua=a.csInterval;this.va=a.csStop;this.H=[];this.ub=this.uc.bind(this);C(this)}w(Rb);var Sb=["power","reset"];g=Rb.prototype; +g.fa=function(a,b,c,d){this.o=a;this.j=b;this.D=d;for(b=0;ba.ca/a.ga&&(b=1);a.ea=b;b=a.ab*a.ea;if(a.ga!=b){a.ga=b;b=a.ga.toFixed(2)+"Mhz";var d=a.u.setSpeed;d&&(d.textContent=b);a.R("target speed: "+b)}c&&a.o&&(c=a.o,c.wa&&c.wa.focus())}a.L+=a.V;a.V=0;a.P=sa();a.da=0;Yb(a)}function wb(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.Ta*a.ea/1E3*c|0,a.H[b][0]=c+$b(a))}function $b(a,b){var c=a.ha-=a.a;a.a=a.G=0;b&&(a.ha=0);return c} +g.uc=function(){if(this.i.W){this.cb>=this.Ta&&Yb(this,!0);this.Fa=0;this.Pa=sa();if(this.da){var a=this.Pa-this.da;a>this.sb&&(this.P+=a,this.P>this.Pa&&(this.P=this.Pa))}try{do{for(var b,c=this.i.Sa?1:this.Ua,d=this.H.length-1;0<=d;d--){var e=this.H[d];0>e[0]||c>e[0]&&(c=e[0])}b=c;try{this.zb(b)}catch(n){if("number"!=typeof n)throw n;}b=$b(this,!0);this.Fa+=b;this.V+=b;a=b;if(this.i.Sa){var f=!1;this.Qa=this.Qa+this.ob()|0;this.ia-=a;0>=this.ia&&(this.ia+=this.ua,f=!0);0<=this.va&&this.va<=Zb(this)&& +(this.ua=this.va=-1,Vb(this),D(this),f=!0);f&&this.R(Zb(this)+" cycles: checksum="+ja(this.Qa))}for(var a=b,h=this.H.length-1;0<=h;h--){var l=this.H[h];0>l[0]||(l[0]-=a,0>=l[0]&&(l[0]=-1,l[1]()))}this.Ea-=b;if(0>=this.Ea){this.Ea+=this.Ua;15<=++this.tb&&(this.o&&this.o.ba(),this.tb=0);break}}while(this.i.W)}catch(n){D(this);this.o&&this.o.stop(sa(),Zb(this));b=n.stack||n.message;this.i.error=!0;this.K(b);return}if(this.i.W){b=setTimeout;c=this.ub;this.da=sa();d=this.sb;this.Fa&&(d=Math.round(d*this.Fa/ +this.Ua));d-=this.da-this.Pa;if(e=this.da-this.P)this.ca=Math.round(this.V/(10*e))/100,864E5<=e&&(this.L=0,Xb(this));if(0>d||this.cad&&(this.P-=d),d=0;this.cb+=this.Fa;this.da+=d;b(c,d)}}};function Wb(a,b){var c;a.i.error?(a.R(a.toString()+" error"),c=!0):c=!1;if(!c)if(a.i.W)a.R(a.toString()+" busy");else{Xb(a);a.i.W=!0;a.i.yb=!0;if(c=a.u.run)c.textContent="Halt";a.o&&(b&&(b=a.o,b.wa&&b.wa.focus()),a.o.start(a.P,Zb(a)));setTimeout(a.ub,0)}}g.zb=function(){return 0}; +function D(a){if(a.i.W){$b(a);a.L+=a.V;a.V=0;a.i.W=!1;var b=a.u.run;b&&(b.textContent="Run");a.o&&a.o.stop(sa(),Zb(a))}a.i.complete=void 0}function ac(a){this.Ka=+a.model||1170;this.qb=a.addrReset||0;Rb.call(this,a,6666667);this.decode=1120==this.Ka?bc.bind(this):cc.bind(this);dc(this);this.eb=0;this.Y=null;this.i.complete=this.i.Db=!1}w(ac,Rb);g=ac.prototype;g.reset=function(){this.status("model "+this.Ka);this.i.W&&D(this);dc(this);Ub(this);this.i.error=!1;this.parent.reset.call(this)}; +function dc(a){a.m=65536;a.g=32768;a.h=65535;a.s=32768;a.A=15;a.f=[0,0,0,0,0,0,0,a.qb];a.xa=[0,0,0,0,0,0];a.aa=[0,0,0,0];a.v=0;a.Na=0;a.Hb=[4,2,0,1];a.F=[[0,0,0,0,0,0,0,0,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],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.U=[[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]];a.Jb=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];a.xb=[0,0,0,0,0,0,0,0];a.wb=0;a.l=0;a.B=a.C=0;a.c=a.b=a.$a=0;a.ja=-1;ec(a)}function ec(a){a.sa=255;a.I=0;a.ib=0;a.w=0;a.qa=0;a.hb=0;a.ra=0;a.Ha=0;a.Ma=0;a.bb=262143;a.Oa=253952;a.l|=2;a.j&&Ab(a)}function Ab(a){a.Ha?(a.M=65536,a.J=a.Gb,a.S=a.rc,a.Ya=a.dd,hb(a.j,a.ra&16?22:18)):(a.M=0,a.J=a.Fb,a.S=a.qc,a.Ya=a.cd,hb(a.j,16))}function fc(a,b,c){a.qb=b;L(a,b);!c&&a.D&&(D(a),a.D.ba())}g.ob=function(){return 0}; +g.save=function(){var a=new M(this);a.set(0,[]);a.set(1,[this.L,this.ea]);a.set(2,rb(this.j));return a.data()};g.restore=function(a){var b=a[1];this.L=b[1];Xb(this,b[3]);a:{b=this.j;a=a[2];var c;for(c=0;c>14&3;c=a.A>>14&3;a.v!=c&&(a.aa[c]=a.f[6],a.f[6]=a.aa[a.v]);a.A=b;a.l|=2}function O(a,b){a.l&128||(a.s=a.h=b,a.g=0)}function P(a,b,c){a.l&128||(a.s=a.h=a.m=b,a.g=c||0)}function ic(a,b,c,d){a.l&128||(a.s=a.h=a.m=b,a.g=(c^b)&(d^b))}function Q(a,b){a.l&128||(a.s=a.h=a.m=b,a.g=a.s^a.m>>1)}function jc(a,b,c,d){a.l&128||(a.s=a.h=a.m=b,a.g=(c^d)&(d^b))} +function G(a,b,c){if(!a.eb){var d=!1;0>a.ja?a.ja=Za(a):a.v||(b=4,d=!0);a.w&57344||(a.qa=63222,a.hb=b);a.v=0;var e=a.S(b|a.M),f=a.S(b+2&65535|a.M);Cb(a,f&-12289|a.ja>>2&12288);d&&(a.I|=4,a.f[6]=4);kc(a,a.ja);kc(a,a.f[7]);L(a,e);a.l&=-113;a.ja=-1;if(26!=c)throw b;}}function lc(a){var b=mc(a),c=mc(a)&-1793;a.A&49152&&(c=c&-225|a.A&63712);L(a,b);Cb(a,c);a.l&=-17} +function nc(a,b,c){var d,e,f,h=0;d=b>>13;a.ra&a.Hb[a.v]||(d&=7);e=a.F[a.v][d];f=(a.U[a.v][d]<<6)+(b&8191)&a.bb;if(ff){if(3932160<=f){f&=262143;var l=f>>13&31;31>l?a.ra&32&&(f=a.Jb[l]+(f&8190)&4194302,3932160<=f&&4186112>f&&console.log("panic(898)")):f|=4186112}f>=a.Oa&&4186112>f&&(a.I|=32,G(a,4,12))}switch(e&7){case 1:h=4096;case 2:e|=128;c&4&&(h=8192);break;case 4:h=4096;case 5:c&4&&(h=4096);case 6:e|=c&4?192: +128;break;default:h=32768}32512!==(e&32520)&&(e&8?e&32512&&(b&8128)<(e>>2&8128)&&(h|=16384):(b&8128)>(e>>2&8128)&&(h|=16384));a.F[a.v][d]=e;if(4194170!==f||a.v)a.Ma=a.v,a.Na=d;h&&(h&57344&&(0<=a.ja&&(h|=128),a.w&57344||(a.w=a.w|h|a.Ma<<5|a.Na<<1),G(a,168,16)),a.w&61440||!(4191360>f||4194239>>a.j].kb(b&a.g,c&255,b)}function mc(a){var b=a.S(a.f[6]|a.M);a.f[6]=a.f[6]+2&65535;return b} +function kc(a,b){var c=a.f[6]-2&65535;a.f[6]=c;a.w&57344||(a.qa=a.qa<<8|246);!a.v&&c<=a.sa&&4c&&d&1&&(f=1));a.a-=3;break;case 3:f=2;e=a.f[c];7!==c&&(e|=h);e=a.S(e);e|=h;a.a-=7;break;case 4:f=-2;6>c&&d&1&&(f=-1);e=a.f[c]+f&65535;7!==c&&(e|=h);a.a-=4;break;case 5:f=-2;e=a.f[c]-2&65535;7!==c&&(e|=h);e=a.S(e)|h;a.a-= +8;break;case 6:return e=a.S(hc(a,2)),e=e+a.f[c]&65535|h,a.a-=6,e;case 7:return e=a.S(hc(a,2)),e=e+a.f[c]&65535,e=a.S(e|a.M)|h,a.a-=10,e}a.f[c]=a.f[c]+f&65535;!h||a.w&57344||(a.qa=a.qa<<8|f<<3&248|c);6==c&&!a.v&&d&4&&0>=f&&(a.f[6]<=a.sa||65534<=a.f[6])&&(a.f[6]<=a.sa-32?(a.I|=4,a.f[6]=4,G(a,4,24)):(a.I|=8,a.l|=64));return e}g.Ja=function(a,b){this.Ha?(this.eb++,oc(this,nc(this,a,5),b),this.eb--):this.j.Ja(a,b)};g.Fb=function(a,b,c){return pc(this,a,b,c)}; +g.Gb=function(a,b,c){return nc(this,pc(this,a,b,c),c)};g.qc=function(a){return pb(this.j,a)};g.rc=function(a){return pb(this.j,nc(this,a,2))};g.cd=function(a,b){qb(this.j,a,b&65535)};g.dd=function(a,b){qb(this.j,nc(this,a,4),b)};function qc(a,b,c){var d=a.b=b&7;(b=a.c=(b&56)>>3)?(d=pc(a,b,d,2),c&65536||61440!==(a.A&61440)&&(d&=65535),a.v=a.A>>12&3,c=a.S(d|c&a.M),a.v=a.A>>14&3):c=6!=d||(a.A>>2&12288)===(a.A&12288)?a.f[d]:a.aa[a.A>>12&3];return c} +function rc(a,b,c,d){a.w&57344||(a.qa=22);var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=pc(a,b,e,4),c&65536||(e&=65535),a.v=a.A>>12&3,e=nc(a,e|c&65536,4),a.v=a.A>>14&3,qb(a.j,e,d)):6!=e||(a.A>>2&12288)===(a.A&12288)?a.f[e]=d:a.aa[a.A>>12&3]=d}function sc(a,b){b>>=6;var c=a.C=b&7;(b=a.B=(b&56)>>3)?(c=a.J(b,c,3),a=ob(a.j,c)):a=a.f[c]&255;return a}function R(a,b){b>>=6;var c=a.C=b&7;return(b=a.B=(b&56)>>3)?pb(a.j,a.J(b,c,2)):a.f[c]}function tc(a,b){var c=a.b=b&7;b=a.c=(b&56)>>3;return pc(a,b,c,8)} +function uc(a,b){var c=a.b=b&7;(b=a.c=(b&56)>>3)?(c=a.J(b,c,3),a=ob(a.j,c)):a=a.f[c]&255;return a}function vc(a,b){var c=a.b=b&7;return(b=a.c=(b&56)>>3)?pb(a.j,a.J(b,c,2)):a.f[c]}function S(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=a.$a=a.J(b,e,7),oc(a,e,d.call(a,c,ob(a.j,e)))):a.f[e]=a.f[e]&65280|d.call(a,c,a.f[e])}function T(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?(e=a.J(b,e,6),qb(a.j,e,d.call(a,c,pb(a.j,e)))):a.f[e]=d.call(a,c,a.f[e])} +function wc(a,b,c,d){var e=a.b=b&7;(b=a.c=(b&56)>>3)?oc(a,a.J(b,e,5),c):a.f[e]=c?d&1?c<<24>>24&65535:a.f[e]&-256|c&255:a.f[e]&-256;return c}function xc(a,b,c){var d=a.b=b&7;(b=a.c=(b&56)>>3)?qb(a.j,a.J(b,d,4),c):a.f[d]=c&65535;return c}function U(a,b,c){c&&(L(a,a.f[7]+(b<<24>>23)),a.a-=2);a.a-=3} +g.zb=function(a){this.i.complete=!0;this.i.Db=!1;this.i.yb=!1;this.ha=this.a=a;do{if(this.l&&(this.l&112&&(this.l&32?G(this,168,28):this.l&64?G(this,4,30):this.l&16&&G(this,12,32),this.l&=-113),this.l&7))if(this.l&2){this.l&=-3;var b=160,c=(this.ib&224)>>5;if(a=this.Y&&this.Y.za>c?this.Y:null)b=a.xc,c=a.za;c>(this.A&224)>>5?(this.l&4&&(hc(this,2),this.l&=-5),G(this,b,26),c=!0):c=!1;if(c&&a)if(c=this.Y,c==a)this.Y=a.next;else for(;c;){b=c.next;if(b==a){c.next=b.next;break}c=b}}else this.l&1&&this.l++; +this.l=this.l&7|this.A&16;this.decode(gc(this))}while(0>1|b<<16;Q(this,a);return a&65535}function Dc(a,b){a=b&2048|b>>1|b<<8;Q(this,a<<8);return a&255}function Ec(a,b){a=b&~a;O(this,a);return a}function Fc(a,b){a=b&~a;O(this,a<<8);return a}function Gc(a,b){a|=b;O(this,a);return a}function Hc(a,b){a|=b;O(this,a<<8);return a}function Ic(a,b){a=~b|65536;P(this,a);return a&65535}function Jc(a,b){a=~b|256;P(this,a<<8);return a&255}function Kc(a,b){a=b-a;this.l&128||(this.s=this.h=a,this.g=b&(b^a));return a&65535} function Lc(a,b){a=b-a;var c=a<<8;b<<=8;this.l&128||(this.s=this.h=c,this.g=b&(b^c));return a&255}function Mc(a,b){a=b+a;this.l&128||(this.s=this.h=a,this.g=a&(b^a));return a&65535}function Nc(a,b){a=b+a;var c=a<<8;this.l&128||(this.s=this.h=c,this.g=c&(b<<8^c));return a&255}function Oc(a,b){a=-b;P(this,a,a&b&32768);return a&65535}function Pc(a,b){a=-b;P(this,a<<8,(a&b&128)<<8);return a&255}function Qc(a,b){a=b<<1|this.m>>16&1;Q(this,a);return a&65535} function Rc(a,b){a=b<<1|this.m>>16&1;Q(this,a<<8);return a&255}function Sc(a,b){a=(this.m&65536|b)>>1|b<<16;Q(this,a);return a&65535}function Tc(a,b){a=((this.m&65536)>>8|b)>>1|b<<8;Q(this,a<<8);return a&255}function Uc(a,b){var c=b-a;jc(this,c,a,b);return c&65535}function Vc(a,b){var c=b-a;jc(this,c<<8,a<<8,b<<8);return c&255}function Wc(a,b){this.l&128||(this.s=this.h=b&65280,this.g=this.m=0);return(b<<8|b>>8)&65535}function Xc(a,b){a^=b;O(this,a);return a&65535} function Yc(a){T(this,a,R(this,a),yc);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}function Zc(a){var b=vc(this,a);a=a>>6&7;var c=this.f[a];c&32768&&(c|=4294901760);this.m=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.f[a]=c&65535;this.s=this.h=c;this.a-=(this.c?6:7)+b} function $c(a){var b=vc(this,a);a=a>>6&7;var c=this.f[a]<<16|this.f[a|1];this.m=this.g=0;b&=63;if(b&32){b=64-b;32>b-1;this.m=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.f[a|1]=d&65535;this.s=d>>16;this.h=d>>16|d;this.a-=(this.c?6:7)+b}function ad(a){U(this,a,!N(this))}function bd(a){U(this,a,N(this))} function cd(a){T(this,a,R(this,a),Ec);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}function dd(a){S(this,a,sc(this,a),Fc);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}function ed(a){T(this,a,R(this,a),Gc);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}function fd(a){S(this,a,sc(this,a),Hc);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)} -function gd(a){O(this,R(this,a)&vc(this,a));this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)}function hd(a){O(this,(sc(this,a)&uc(this,a))<<8);this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)}function id(a){U(this,a,this.h&65535?0:4)}function jd(a){U(this,a,!this.na()==!(this.g&32768))}function kd(a){U(this,a,!!(this.h&65535)&&!this.na()==!(this.g&32768))}function ld(a){U(this,a,!N(this)&&!!(this.h&65535))} -function md(a){U(this,a,(this.h&65535?0:4)||!this.na()!=!(this.g&32768))}function nd(a){U(this,a,N(this)||(this.h&65535?0:4))}function od(a){U(this,a,!this.na()!=!(this.g&32768))}function pd(a){U(this,a,this.na())}function qd(a){U(this,a,!!(this.h&65535))}function rd(a){U(this,a,!this.na())}function sd(){G(this,12,1);this.a-=5}function td(a){U(this,a,!0)}function ud(a){U(this,a,!(this.g&32768))}function vd(a){U(this,a,this.g&32768?2:0)} +function gd(a){O(this,R(this,a)&vc(this,a));this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)}function hd(a){O(this,(sc(this,a)&uc(this,a))<<8);this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)}function id(a){U(this,a,this.h&65535?0:4)}function jd(a){U(this,a,!this.oa()==!(this.g&32768))}function kd(a){U(this,a,!!(this.h&65535)&&!this.oa()==!(this.g&32768))}function ld(a){U(this,a,!N(this)&&!!(this.h&65535))} +function md(a){U(this,a,(this.h&65535?0:4)||!this.oa()!=!(this.g&32768))}function nd(a){U(this,a,N(this)||(this.h&65535?0:4))}function od(a){U(this,a,!this.oa()!=!(this.g&32768))}function pd(a){U(this,a,this.oa())}function qd(a){U(this,a,!!(this.h&65535))}function rd(a){U(this,a,!this.oa())}function sd(){G(this,12,1);this.a-=5}function td(a){U(this,a,!0)}function ud(a){U(this,a,!(this.g&32768))}function vd(a){U(this,a,this.g&32768?2:0)} function V(a){a&1&&(this.m=0);a&2&&(this.g=0);a&4&&(this.h=1);a&8&&(this.s=0);this.a-=5}function wd(a){var b=R(this,a);a=vc(this,a);jc(this,b-a,a,b);this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)}function xd(a){var b=sc(this,a)<<8;a=uc(this,a)<<8;jc(this,b-a,a,b);this.a-=this.c?4+(this.C&&6<=this.b?1:0):(this.B?4:3)+(7==this.b?2:0)} function yd(a){var b=vc(this,a);if(b){a=a>>6&7;var c=this.f[a]<<16|this.f[a|1];this.m=this.g=0;b&32768&&(b|=-65536);var d=~~(c/b);-32768<=d&&32767>=d?(this.f[a]=d&65535,this.f[a|1]=c-d*b&65535,this.h=d>>16|d,this.s=d>>16):(this.g=32768,this.h=d>>15|d,this.s=c>>16,-1===b&&65534===this.f[a]&&(this.f[a]=this.f[a|1]=1));this.a-=53}else this.h=this.s=0,this.g=32768,this.m=65536,this.a-=7}function zd(){G(this,24,2);this.a-=25} -function Ad(){this.A&49152?(this.I|=128,G(this,4,3)):this.D?this.D.c():D(this);this.a-=7}function Bd(){G(this,16,4);this.a-=25}var Cd=[0,7,7,10,7,11,9,13];function W(a){var b=this.a;L(this,tc(this,a));this.a=b-Cd[this.c]}var Dd=[0,14,14,17,14,18,16,20];function Ed(a){var b=this.a,c=tc(this,a);a=a>>6&7;kc(this,this.f[a]);this.f[a]=this.f[7];L(this,c);this.a=b-Dd[this.c]}var Fd=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17]; -function Gd(a){var b=R(this,a),c=this.a;O(this,xc(this,a,b));this.a=c-Fd[(this.B?8:0)+this.c]+(7!=this.b||this.c?0:2)}function Hd(a){var b=sc(this,a);O(this,wc(this,a,b,1)<<8);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}var Id=[7,13,13,17,14,18,17,21]; +function Ad(){this.A&49152?(this.I|=128,G(this,4,3)):this.D?this.D.c():D(this);this.a-=7}function Bd(){G(this,16,4);this.a-=25}var Cd=[0,7,7,10,7,11,9,13];function W(a){this.G=this.a;L(this,tc(this,a));this.a=this.G-Cd[this.c]}var Dd=[0,14,14,17,14,18,16,20];function Ed(a){this.G=this.a;var b=tc(this,a);a=a>>6&7;kc(this,this.f[a]);this.f[a]=this.f[7];L(this,b);this.a=this.G-Dd[this.c]}var Fd=[3,9,9,13,10,14,12,16,4,9,9,13,10,14,13,17]; +function Gd(a){var b=R(this,a);this.G=this.a;O(this,xc(this,a,b));this.a=this.G-Fd[(this.B?8:0)+this.c]+(7!=this.b||this.c?0:2)}function Hd(a){var b=sc(this,a);O(this,wc(this,a,b,1)<<8);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)}var Id=[7,13,13,17,14,18,17,21]; function Jd(a){var b=vc(this,a);a=a>>6&7;b&32768&&(b|=-65536);var c=this.f[a];c&32768&&(c|=-65536);b=~~(b*c);this.f[a]=b>>16&65535;this.f[a|1]=b&65535;this.l&128||(this.s=b>>16,this.h=this.s|b,this.g=0,this.m=-32768>b||32767>6;if(this.f[b]=this.f[b]-1&65535)L(this,this.f[7]-((a&63)<<1)),this.a+=1;this.a-=6}function Pd(a){T(this,a,R(this,a),Uc);this.a-=this.c?9+(this.C&&6<=this.b?1:0):(this.B?5:3)+(7==this.b?2:0)} -function Qd(a){T(this,a,0,Wc);this.a-=this.c?9:3+(7==this.b?2:0)}function Rd(){G(this,28,5);this.a-=5}function Sd(){this.l&4||this.o.aa();this.l|=4;hc(this,-2);this.a-=3}function Td(a){T(this,a,R(this,a),Xc);this.a-=this.c?9:3+(7==this.b?2:0)}function Y(){G(this,8,6)}function bc(a){Ud[a>>12].call(this,a)}function Vd(a){Wd[a>>6&3].call(this,a)}function Xd(a){Yd[a>>6&3].call(this,a)}function Zd(a){$d[a>>6&3].call(this,a)}function ae(a){be[a&15].call(this,a)}function ce(a){de[a&15].call(this,a)} +function Qd(a){T(this,a,0,Wc);this.a-=this.c?9:3+(7==this.b?2:0)}function Rd(){G(this,28,5);this.a-=5}function Sd(){this.l&4||this.o.ba();this.l|=4;hc(this,-2);this.a-=3}function Td(a){T(this,a,R(this,a),Xc);this.a-=this.c?9:3+(7==this.b?2:0)}function Y(){G(this,8,6)}function bc(a){Ud[a>>12].call(this,a)}function Vd(a){Wd[a>>6&3].call(this,a)}function Xd(a){Yd[a>>6&3].call(this,a)}function Zd(a){$d[a>>6&3].call(this,a)}function ae(a){be[a&15].call(this,a)}function ce(a){de[a&15].call(this,a)} function ee(a){fe[a>>6&3].call(this,a)}function ge(a){he[a>>6&3].call(this,a)}function ie(a){je[a>>6&3].call(this,a)} var Ud=[function(a){ke[a>>8&15].call(this,a)},Gd,wd,gd,cd,ed,Yc,Y,function(a){le[a>>8&15].call(this,a)},Hd,xd,hd,dd,fd,Pd,Y],ke=[function(a){me[a>>4&15].call(this,a)},td,qd,id,jd,od,kd,md,Ed,Ed,Vd,Xd,Zd,Y,Y,Y],Wd=[function(a){P(this,xc(this,a,0));this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,0,Ic);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,1,Mc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,1,Kc);this.a-=this.c?9:3+(7==this.b?2:0)}],Yd=[function(a){T(this,a,0,Oc); this.a-=this.c?11:6},function(a){T(this,a,N(this)?1:0,yc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,N(this)?1:0,Uc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){a=vc(this,a);P(this,a);this.a-=this.c?4:3+(7==this.b?2:0)}],$d=[function(a){T(this,a,0,Sc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,0,Qc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,0,Cc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){T(this,a,0,Ac);this.a-=this.c?9:3+(7==this.b?2:0)}],me=[function(a){ne[a& 15].call(this,a)},Y,Y,Y,W,W,W,W,Nd,Y,ae,ce,Qd,Qd,Qd,Qd],ne=[Ad,Sd,Md,sd,Bd,Ld,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y],be=[Kd,function(){this.m=0;this.a-=5},function(){this.g=0;this.a-=5},V,function(){this.h=1;this.a-=5},V,V,V,function(){this.s=0;this.a-=5},V,V,V,V,V,V,V],de=[Kd,function(){this.m=65536;this.a-=5},function(){this.g=32768;this.a-=5},X,function(){this.h=0;this.a-=5},X,X,X,function(){this.s=32768;this.a-=5},X,X,X,X,X,X,X],le=[rd,pd,ld,nd,ud,vd,ad,bd,zd,Rd,ee,ge,ie,Y,Y,Y],fe=[function(a){P(this,wc(this,a, 0));this.a-=this.c?9:3+(7==this.b?2:0)},function(a){S(this,a,0,Jc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){S(this,a,1,Nc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){S(this,a,1,Lc);this.a-=this.c?9:3+(7==this.b?2:0)}],he=[function(a){S(this,a,0,Pc);this.a-=this.c?11:6},function(a){S(this,a,N(this)?1:0,zc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){S(this,a,N(this)?1:0,Vc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){a=uc(this,a);P(this,a<<8);this.a-=this.c?4:3+(7==this.b?2:0)}], -je=[function(a){S(this,a,0,Tc);this.a-=this.c?9+(this.Za&1):3+(7==this.b?2:0)},function(a){S(this,a,0,Rc);this.a-=this.c?9:3+(7==this.b?2:0)},function(a){S(this,a,0,Dc);this.a-=this.c?9+(this.Za&1):3+(7==this.b?2:0)},function(a){S(this,a,0,Bc);this.a-=this.c?9:3+(7==this.b?2:0)}];function cc(a){oe[a>>12].call(this,a)} -var oe=[function(a){pe[a>>8&15].call(this,a)},Gd,wd,gd,cd,ed,Yc,function(a){qe[a>>8&15].call(this,a)},function(a){re[a>>8&15].call(this,a)},Hd,xd,hd,dd,fd,Pd,Y],pe=[function(a){se[a>>4&15].call(this,a)},td,qd,id,jd,od,kd,md,Ed,Ed,Vd,Xd,Zd,function(a){te[a>>6&3].call(this,a)},Y,Y],te=[function(a){a=this.f[7]+((a&63)<<1)&65535;var b=this.S(a|this.L);L(this,this.f[5]);this.f[6]=a+2&65535;this.f[5]=b;this.a-=8},function(a){a=qc(this,a,0);kc(this,a);O(this,a);this.a-=11},function(a){var b=mc(this),c=this.a; -rc(this,a,0,b);O(this,b);this.a=c-Id[this.c]},function(a){O(this,xc(this,a,this.na?65535:0));this.a-=this.c?9:3+(7==this.b?2:0)}],se=[function(a){ue[a&15].call(this,a)},Y,Y,Y,W,W,W,W,Nd,function(a){a&8?(this.A&49152||(this.A=this.A&-2017|(a&7)<<5,this.l|=1),this.a-=5):G(this,8,6)},ae,ce,Qd,Qd,Qd,Qd],ue=[Ad,Sd,Md,sd,Bd,Ld,function(){lc(this);this.a-=13},Y,Y,Y,Y,Y,Y,Y,Y,Y],qe=[Jd,Jd,yd,yd,Zc,Zc,$c,$c,Td,Td,Y,Y,Y,Y,Od,Od],re=[rd,pd,ld,nd,ud,vd,ad,bd,zd,Rd,ee,ge,ie,function(a){ve[a>>6&3].call(this,a)}, -Y,Y],ve=[Y,function(a){a=qc(this,a,65536);kc(this,a);O(this,a);this.a-=11},function(a){var b=mc(this),c=this.a;rc(this,a,65536,b);O(this,b);this.a=c-Id[this.c]},Y]; -function we(a){u.call(this,"ROM",a,we);this.T=this.b=null;this.o=a.addr;this.c=a.size;this.h=a.alias;this.g=a.file;this.m=ka(this.g);if(this.g){a=this.g;var b=la(this.m);"json"!=b&&"hex"!=b&&(a=na()+"/api/v1/dump?file="+this.g+"&format=bytes&decimal=true");var c=this;k(a,null,!0,function(a,b,f){f?c.K("Unable to load ROM resource (error "+f+": "+a+")"):(Pa(c.sa,a,b),(a=ua(a,b))?(c.b=a.N,c.T=a.T):c.g=null,xe(c))})}}w(we);we.prototype.ea=function(a,b,c,d){this.j=b;this.a=c;this.D=d;xe(this)}; -we.prototype.Z=function(){this.T&&(this.D&&this.D.a(this.id,this.o,this.c,this.T),delete this.T);return!0};we.prototype.Y=function(){return!0}; -function xe(a){if(!Ta(a)){if(a.g){if(!a.b||!a.j)return;a.c||(a.c=a.b.length);if(a.b.length!=a.c){var b="ROM size ("+ja(a.b.length,8,!0)+") does not match specified size ("+ja(a.c,8,!0)+")";a.i.error=!0;a.K(b)}else{b=a.o;if(kb(a.j,b,a.c,Ib)){var c;for(c=0;c>12].call(this,a)} +var oe=[function(a){pe[a>>8&15].call(this,a)},Gd,wd,gd,cd,ed,Yc,function(a){qe[a>>8&15].call(this,a)},function(a){re[a>>8&15].call(this,a)},Hd,xd,hd,dd,fd,Pd,Y],pe=[function(a){se[a>>4&15].call(this,a)},td,qd,id,jd,od,kd,md,Ed,Ed,Vd,Xd,Zd,function(a){te[a>>6&3].call(this,a)},Y,Y],te=[function(a){a=this.f[7]+((a&63)<<1)&65535;var b=this.S(a|this.M);L(this,this.f[5]);this.f[6]=a+2&65535;this.f[5]=b;this.a-=8},function(a){a=qc(this,a,0);kc(this,a);O(this,a);this.a-=11},function(a){var b=mc(this);this.G= +this.a;rc(this,a,0,b);O(this,b);this.a=this.G-Id[this.c]},function(a){O(this,xc(this,a,this.oa?65535:0));this.a-=this.c?9:3+(7==this.b?2:0)}],se=[function(a){ue[a&15].call(this,a)},Y,Y,Y,W,W,W,W,Nd,function(a){a&8?(this.A&49152||(this.A=this.A&-2017|(a&7)<<5,this.l|=1),this.a-=5):G(this,8,6)},ae,ce,Qd,Qd,Qd,Qd],ue=[Ad,Sd,Md,sd,Bd,Ld,function(){lc(this);this.a-=13},Y,Y,Y,Y,Y,Y,Y,Y,Y],qe=[Jd,Jd,yd,yd,Zc,Zc,$c,$c,Td,Td,Y,Y,Y,Y,Od,Od],re=[rd,pd,ld,nd,ud,vd,ad,bd,zd,Rd,ee,ge,ie,function(a){ve[a>>6&3].call(this, +a)},Y,Y],ve=[Y,function(a){a=qc(this,a,65536);kc(this,a);O(this,a);this.a-=11},function(a){var b=mc(this);this.G=this.a;rc(this,a,65536,b);O(this,b);this.a=this.G-Id[this.c]},Y]; +function we(a){u.call(this,"ROM",a,we);this.T=this.b=null;this.o=a.addr;this.c=a.size;this.h=a.alias;this.g=a.file;this.m=ka(this.g);if(this.g){a=this.g;var b=la(this.m);"json"!=b&&"hex"!=b&&(a=na()+"/api/v1/dump?file="+this.g+"&format=bytes&decimal=true");var c=this;k(a,null,!0,function(a,b,f){f?c.K("Unable to load ROM resource (error "+f+": "+a+")"):(Pa(c.ta,a,b),(a=ua(a,b))?(c.b=a.N,c.T=a.T):c.g=null,xe(c))})}}w(we);we.prototype.fa=function(a,b,c,d){this.j=b;this.a=c;this.D=d;xe(this)}; +we.prototype.$=function(){this.T&&(this.D&&this.D.a(this.id,this.o,this.c,this.T),delete this.T);return!0};we.prototype.Z=function(){return!0}; +function xe(a){if(!Ta(a)){if(a.g){if(!a.b||!a.j)return;a.c||(a.c=a.b.length);if(a.b.length!=a.c){var b="ROM size ("+ja(a.b.length,8,!0)+") does not match specified size ("+ja(a.c,8,!0)+")";a.i.error=!0;a.K(b)}else{b=a.o;if(kb(a.j,b,a.c,Ib)){var c;for(c=0;c>>a.j;0=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,n=n+((q&255)+(q>>8)+(t&255)+(t>>8)),z=l,Ra=q-=6;0=b.length)break;n+=b[l++]&255;if(n&255)break;if(Ra)for(;Ra--;)a.a.Ia(t++,b[z++]&255);else t&1?D(a.a):fc(a.a,t,f);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(e=0;e=b)a.preventDefault&&a.preventDefault(),64");if(2==b.length){var c=qa(b[0]);if(c!=this.Ka)return;b=qa(b[1]);if(this.v=Qa(b)){var d=this.v.exports;if(d){var e=d.connect;e&&e.call(this.v);if(this.w=d.receiveData){this.status(this.sa+"."+c+" connected to "+b);return}}}}this.status("Unable to establish connection: "+a)}}};g.Z=function(a,b){if(!b)if(this.ob(),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0}; -g.Y=function(a){return a?this.save():!0};g.reset=function(){Ee(this)};g.save=function(){var a=new M(this);a.set(0,[]);return a.data()};g.restore=function(){return Ee(this)};function Ee(a){a.H=0;a.b=0;a.c=128;a.h=[];return!0}g.fb=function(a){if("number"==typeof a)this.h.push(a);else if("string"==typeof a)for(var b=0;b":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.J||8,c=a-this.s%a,this.J&&(b=" ".slice(0,c)));this.C&&!this.s&&c&&(b=String.fromCharCode(this.C)+b);this.g.value+=b;this.g.scrollTop=this.g.scrollHeight;this.s+=c}else if(null!=this.m){if(10==a||1024<=this.m.length)this.R(this.m), -this.m="";10!=a&&(this.m+=String.fromCharCode(a))}this.c&=-129;yb(this.a,this.M,1E3/Math.round(this.G/10))}};var Fe={},De=(Fe[65392]=[null,null,Z.prototype.ec,Z.prototype.Rc,"RCSR"],Fe[65394]=[null,null,Z.prototype.dc,Z.prototype.Qc,"RBUF"],Fe[65396]=[null,null,Z.prototype.sc,Z.prototype.ed,"XCSR"],Fe[65398]=[null,null,Z.prototype.rc,Z.prototype.dd,"XBUF"],Fe);r(function(){for(var a=B(document,"pdp11","serial"),b=0;b>>a.j;0=b.length)break;for(var l=l+2,q=b[l++]&255|(b[l++]&255)<<8,t=b[l++]&255|(b[l++]&255)<<8,n=n+((q&255)+(q>>8)+(t&255)+(t>>8)),z=l,Ra=q-=6;0=b.length)break;n+=b[l++]&255;if(n&255)break;if(Ra)for(;Ra--;)a.a.Ja(t++,b[z++]&255);else t&1?D(a.a):fc(a.a,t,f);h=!0}else l++;else l+=2}if(!h&&(null==c&&(c=e),null!=c)){for(e=0;e=b)a.preventDefault&&a.preventDefault(),64");if(2==b.length){var c=qa(b[0]);if(c!=this.La)return;b=qa(b[1]);if(this.v=Qa(b)){var d=this.v.exports;if(d){var e=d.connect;e&&e.call(this.v);if(this.w=d.receiveData){this.status(this.ta+"."+c+" connected to "+b);return}}}}this.status("Unable to establish connection: "+a)}}};g.$=function(a,b){if(!b)if(this.pb(),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0}; +g.Z=function(a){return a?this.save():!0};g.reset=function(){Ee(this)};g.save=function(){var a=new M(this);a.set(0,[]);return a.data()};g.restore=function(){return Ee(this)};function Ee(a){a.H=0;a.b=0;a.c=128;a.h=[];return!0}g.gb=function(a){if("number"==typeof a)this.h.push(a);else if("string"==typeof a)for(var b=0;b":String.fromCharCode(a);var c=b.length;32>a&&1==c&&(c=0);9==a&&(a=this.J||8,c=a-this.s%a,this.J&&(b=" ".slice(0,c)));this.C&&!this.s&&c&&(b=String.fromCharCode(this.C)+b);this.g.value+=b;this.g.scrollTop=this.g.scrollHeight;this.s+=c}else if(null!=this.m){if(10==a||1024<=this.m.length)this.R(this.m), +this.m="";10!=a&&(this.m+=String.fromCharCode(a))}this.c&=-129;yb(this.a,this.M,1E3/Math.round(this.G/10))}};var Fe={},De=(Fe[65392]=[null,null,Z.prototype.fc,Z.prototype.Sc,"RCSR"],Fe[65394]=[null,null,Z.prototype.ec,Z.prototype.Rc,"RBUF"],Fe[65396]=[null,null,Z.prototype.tc,Z.prototype.fd,"XCSR"],Fe[65398]=[null,null,Z.prototype.sc,Z.prototype.ed,"XBUF"],Fe);r(function(){for(var a=B(document,"pdp11","serial"),b=0;b'+b+"");a.innerHTML=b}},!0;case "descTape":return this.u[b]=c,!0;case "loadTape":e=2;case "attachTape":return e||(e=1),this.u[b]=c,c.onclick=function(){var a= d.u.listTapes;a&&Ie(d,a.options[a.selectedIndex].text,a.value,e)},!0;case "mountTape":if(!this.C){c.parentNode.removeChild(c);break}this.u[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;Ie(d,ka(b,!0),b,1,a)}return!1};return!0;case "readProgress":return this.u[b]=c,!0}return!1}; -g.ea=function(a,b,c,d){this.o=a;this.j=b;this.a=c;this.D=d;this.H=Je(a);var e=this;if((this.c=Tb(this.o,"autoMount")||this.c)&&"string"==typeof this.c)try{this.c=eval("("+this.c+")")}catch(f){m("PC11 auto-mount error: "+f.message+" ("+this.c+")"),this.c=null}this.J=zb(56,4);this.M=wb(this.a,function(){1==(e.b&32769)&&!(e.b&128)&&e.wc.indexOf("/api/v1/dump")&&(e=la(c),f="json"==e||"gz"==e?encodeURI(c):na()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!k(f,null,!0,function(e,f,h){var l=0>h&&a.o&&!a.o.i.O;h?a.K('Unable to load tape "'+b+'" (error '+h+": "+e+")",l):(Pa(a.sa,e,f),(e=ua(e,f))&&Se(a,b,c,d,e.N,e.la,e.ka)); -a.i.Ya=!1;a.h&&(a.h--,a.h||C(a));Pe(a)})}function Me(a,b,c,d){if((a=a.u.listTapes)&&a.options){for(var e=0;ec.indexOf("/api/v1/dump")&&(e=la(c),f="json"==e||"gz"==e?encodeURI(c):na()+"/api/v1/dump?path="+encodeURIComponent(c)+"&format=json");return!!k(f,null,!0,function(e,f,h){var l=0>h&&a.o&&!a.o.i.O;h?a.K('Unable to load tape "'+b+'" (error '+h+": "+e+")",l):(Pa(a.ta,e,f),(e=ua(e,f))&&Se(a,b,c,d,e.N,e.ma,e.la)); +a.i.Za=!1;a.h&&(a.h--,a.h||C(a));Pe(a)})}function Me(a,b,c,d){if((a=a.u.listTapes)&&a.options){for(var e=0;e\nLicense: GPL version 3 or later ");this.R("Portions adapted from the PDP-11/70 Emulator v1.4 by Paul Nankervis ");for(b=0;b\nLicense: GPL version 3 or later ");this.R("Portions adapted from the PDP-11/70 Emulator v1.4 by Paul Nankervis ");for(b=0;bWe){if(Ye(d,this.v)){this.o=new M(this,"1.30.1","failsafe");Ye(this.o)&&(cf(this,d),a=2,df(this.o));this.o.set("timestamp",ta());ef(this.o);var e=this.b&&!this.m;if(1==a||va("Click OK to restore the previous PDPjs machine state, or CANCEL to reset the machine.")){if(c=bf(d)){var f=d.get("code"),h=d.get("data");f&&("ok"==f?Ye(d,h):("error"== -f&&"no machine state"!=h?(this.K("Error: "+h),"unable to verify user"==h&&(za("user",""),this.c=null)):this.R(f+": "+h),df(d),Ye(d)?(c=bf(d),e=!0):c=!1))}e&&af(this,c?d:null)}else 2==a&&d.clear()}else af(this);delete this.v;delete this.w}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.O=!0;var d=this.u.power;d&&(d.textContent="Shutdown");this.a&&(ff(this,this.a,b,c,a),this.a.Fa());this.G&&(cf(this,b),b.clear());!c&&this.o&&(this.o.clear(),delete this.o);this.g=0}; +g.Ia=function(a){void 0===a&&(a=this.b||(this.v?1:We));if(!this.g){this.g++;var b=!1,c=!1;this.G=!1;var d=this.w||new M(this,"1.30.1");if(-1==a)b=!0;else if(a>We){if(Ye(d,this.v)){this.o=new M(this,"1.30.1","failsafe");Ye(this.o)&&(cf(this,d),a=2,df(this.o));this.o.set("timestamp",ta());ef(this.o);var e=this.b&&!this.m;if(1==a||va("Click OK to restore the previous PDPjs machine state, or CANCEL to reset the machine.")){if(c=bf(d)){var f=d.get("code"),h=d.get("data");f&&("ok"==f?Ye(d,h):("error"== +f&&"no machine state"!=h?(this.K("Error: "+h),"unable to verify user"==h&&(za("user",""),this.c=null)):this.R(f+": "+h),df(d),Ye(d)?(c=bf(d),e=!0):c=!1))}e&&af(this,c?d:null)}else 2==a&&d.clear()}else af(this);delete this.v;delete this.w}e=x(this.id);for(f=0;fa[1];a=a[2];this.P=!0;this.i.O=!0;var d=this.u.power;d&&(d.textContent="Shutdown");this.a&&(ff(this,this.a,b,c,a),this.a.Ga());this.G&&(cf(this,b),b.clear());!c&&this.o&&(this.o.clear(),delete this.o);this.g=0}; function cf(a,b){if(va("There may be a problem with your PDPjs machine.\n\nTo help us diagnose it, click OK to send this PDPjs machine state to http://www.pcjs.org.")){var c=a.c||"";b=b.toString();var d={app:"PDPjs",ver:"1.30.1"};d.url=a.M;d.user=c;d.type="bug";d.data=b;k("http://www.pcjs.org/api/v1/report",d,!0)}} -function gf(a,b,c){var d,e="none";if(a.g)return null;a.g--;var f=new M(a,"1.30.1"),h=new M(a,"1.30.1","validate"),l=ta();h.set("timestamp",l);f.set("timestamp",l);f.set("version","1.30.1");f.set("url",window?window.location.href:null);f.set("browser",window?window.navigator.userAgent:"");a.a&&a.a.Y&&(c&&D(a.a),d=a.a.Y(b,c),"object"===typeof d&&f.set(a.a.id,d),c&&(a.a.i.O=!1,!1===d&&(e=null)));for(var l=x(a.id),n=0;n