First stab at factoring some common Debugger functionality into a shared component
This commit is contained in:
parent
5969514c7e
commit
a8bb0c7841
42 changed files with 3721 additions and 4457 deletions
|
|
@ -68,7 +68,7 @@ if (NODE) {
|
|||
* @extends Component
|
||||
* @param {Object} parmsBus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
function Bus(parmsBus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1294,7 +1294,7 @@ ChipSet.prototype.setBinding = function(sHTMLType, sBinding, control, sValue)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
ChipSet.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -182,7 +182,7 @@ function Computer(parmsComputer, parmsMachine, fSuspended) {
|
|||
Component.error("Unable to find CPU component");
|
||||
return;
|
||||
}
|
||||
this.dbg = /** @type {Debugger} */ (Component.getComponentByType("Debugger", this.id));
|
||||
this.dbg = /** @type {DebuggerX86} */ (Component.getComponentByType("Debugger", this.id));
|
||||
|
||||
/*
|
||||
* Enumerate all Video components for future updateVideo() calls.
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ CPU.BUTTONS = ["power", "reset"];
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
CPU.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -34,12 +34,12 @@
|
|||
/**
|
||||
* @define {string}
|
||||
*/
|
||||
var APPCLASS = "pcx86"; // this @define is the default application class (eg, "pcx86", "c1pjs")
|
||||
var APPCLASS = "pcx86"; // this @define is the default application class (eg, "pcx86", "c1pjs")
|
||||
|
||||
/**
|
||||
* @define {string}
|
||||
*/
|
||||
var APPNAME = "PCx86"; // this @define is the default application name (eg, "PCx86", "C1Pjs")
|
||||
var APPNAME = "PCx86"; // this @define is the default application name (eg, "PCx86", "C1Pjs")
|
||||
|
||||
/**
|
||||
* @define {boolean}
|
||||
|
|
|
|||
|
|
@ -811,7 +811,7 @@ var SectorInfo;
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
Disk.prototype.initBus = function(cmp, bus, cpu, dbg) {
|
||||
this.dbg = dbg;
|
||||
|
|
|
|||
|
|
@ -623,7 +623,7 @@ FDC.prototype.setBinding = function(sHTMLType, sBinding, control, sValue)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
FDC.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -594,7 +594,7 @@ HDC.prototype.setBinding = function(sHTMLType, sBinding, control, sValue)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
HDC.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -31,22 +31,6 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
* Components that previously used Debugger interrupt definitions by including:
|
||||
*
|
||||
* var Debugger = require("./debugger");
|
||||
*
|
||||
* and using:
|
||||
*
|
||||
* Debugger.INT.FOO
|
||||
*
|
||||
* must now instead include:
|
||||
*
|
||||
* var Interrupts = require("./interrupts");
|
||||
*
|
||||
* and then replace all occurrences of "Debugger.INT.FOO" with "Interrupts.FOO".
|
||||
*/
|
||||
|
||||
var Interrupts = {
|
||||
VIDEO: 0x10,
|
||||
DISK: 0x13,
|
||||
|
|
@ -184,7 +168,7 @@ if (DEBUGGER) {
|
|||
0x4A8: ["SAVE_PTR",4] // POINTER TO EGA PARAMETER CONTROL BLOCK
|
||||
},
|
||||
/*
|
||||
* See Debugger.prototype.replaceRegs() for the rules governing how register contents are replaced in the strings below.
|
||||
* See DebuggerX86.prototype.replaceRegs() for the rules governing how register contents are replaced in the strings below.
|
||||
*
|
||||
* Replacements occur in the following order:
|
||||
*
|
||||
|
|
@ -1546,7 +1530,7 @@ if (DEBUGGER) {
|
|||
* INT 2E Execute command (*) (2.0+)
|
||||
* Entry: DS:SI->command string-1 followed by a carriage return
|
||||
* Exit: All registers except CS and IP are destroyed
|
||||
* Note: This function is not re-enterant and should not be issued from a
|
||||
* Note: This function is not re-entrant and should not be issued from a
|
||||
* batch file.
|
||||
*
|
||||
* INT 2F Multiplex (3.0+)
|
||||
|
|
@ -1922,7 +1906,7 @@ if (DEBUGGER) {
|
|||
*
|
||||
* Stacks descriptor (8 bytes)
|
||||
* 00 Flag (0=free,1=in use)
|
||||
* 02 Savearea for SS:SP
|
||||
* 02 Save area for SS:SP
|
||||
* 06 Offset of end of stack
|
||||
*
|
||||
* Device driver header (12h bytes)
|
||||
|
|
|
|||
|
|
@ -1324,7 +1324,7 @@ Keyboard.prototype.findBinding = function(simCode, sType, fDown)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
Keyboard.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -288,7 +288,7 @@ Memory.prototype = {
|
|||
* @this {Memory}
|
||||
* @param {Memory} mem
|
||||
* @param {number} [type]
|
||||
* @param {Debugger} [dbg]
|
||||
* @param {DebuggerX86} [dbg]
|
||||
*/
|
||||
clone: function(mem, type, dbg) {
|
||||
/*
|
||||
|
|
@ -620,7 +620,7 @@ Memory.prototype = {
|
|||
* copyBreakpoints(dbg, mem)
|
||||
*
|
||||
* @this {Memory}
|
||||
* @param {Debugger} [dbg]
|
||||
* @param {DebuggerX86} [dbg]
|
||||
* @param {Memory} [mem] (outgoing Memory block to copy breakpoints from, if any)
|
||||
*/
|
||||
copyBreakpoints: function(dbg, mem) {
|
||||
|
|
|
|||
|
|
@ -31,22 +31,6 @@
|
|||
|
||||
"use strict";
|
||||
|
||||
/*
|
||||
* Components that previously used Debugger messages definitions by including:
|
||||
*
|
||||
* var Debugger = require("./debugger");
|
||||
*
|
||||
* and using:
|
||||
*
|
||||
* Debugger.MESSAGE.FOO
|
||||
*
|
||||
* must now instead include:
|
||||
*
|
||||
* var Messages = require("./messages");
|
||||
*
|
||||
* and then replace all occurrences of "Debugger.MESSAGE.FOO" with "Messages.FOO".
|
||||
*/
|
||||
|
||||
var Messages = {
|
||||
CPU: 0x00000001,
|
||||
SEG: 0x00000002,
|
||||
|
|
|
|||
|
|
@ -181,7 +181,7 @@ Mouse.BUTTON = {
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
Mouse.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -341,7 +341,7 @@ Panel.prototype.setBinding = function(sHTMLType, sBinding, control, sValue)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
Panel.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -230,7 +230,7 @@ ParallelPort.prototype.setBinding = function(sHTMLType, sBinding, control, sValu
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
ParallelPort.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ Component.subclass(RAM);
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
RAM.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -162,7 +162,7 @@ ROM.BIOS.RESET_FLAG_WARMBOOT = 0x1234; // value stored at ROM.BIOS.RESET_FLAG t
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
ROM.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -456,7 +456,7 @@ SerialPort.prototype.setBinding = function(sHTMLType, sBinding, control, sValue)
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
SerialPort.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -2899,7 +2899,7 @@ Video.TOUCH = {
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
Video.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -163,7 +163,7 @@ Component.subclass(X86FPU);
|
|||
* @param {Computer} cmp
|
||||
* @param {Bus} bus
|
||||
* @param {X86CPU} cpu
|
||||
* @param {Debugger} dbg
|
||||
* @param {DebuggerX86} dbg
|
||||
*/
|
||||
X86FPU.prototype.initBus = function(cmp, bus, cpu, dbg)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue