Added support for a Debugger "base" option that presets the default base (eg, 8, 10, 16) for most numeric input/output
This commit is contained in:
parent
1df54a338f
commit
a15e222076
4 changed files with 23 additions and 13 deletions
|
|
@ -60,13 +60,17 @@ var DbgAddr;
|
|||
/**
|
||||
* Debugger(parmsDbg)
|
||||
*
|
||||
* @constructor
|
||||
* @extends Component
|
||||
* @param {Object} parmsDbg
|
||||
* The Debugger component supports the following optional (parmsDbg) properties:
|
||||
*
|
||||
* base: the base to use for most numeric input/output (default is 16)
|
||||
*
|
||||
* The Debugger component is a shared component containing a subset of functionality used by
|
||||
* the other CPU-specific Debuggers (eg, DebuggerX86). Over time, the goal is to factor out as
|
||||
* much common debugging support as possible from those components into this one.
|
||||
*
|
||||
* @constructor
|
||||
* @extends Component
|
||||
* @param {Object} parmsDbg
|
||||
*/
|
||||
function Debugger(parmsDbg)
|
||||
{
|
||||
|
|
@ -77,7 +81,7 @@ function Debugger(parmsDbg)
|
|||
/*
|
||||
* Default base used to display all values; modified with the "s base" command.
|
||||
*/
|
||||
this.nBase = 16;
|
||||
this.nBase = parmsDbg['base'] || 16;
|
||||
|
||||
/*
|
||||
* These keep track of instruction activity, but only when tracing or when Debugger checks
|
||||
|
|
|
|||
|
|
@ -1168,6 +1168,12 @@
|
|||
|
||||
<xsl:template match="debugger[not(@ref)]">
|
||||
<xsl:param name="machine" select="''"/>
|
||||
<xsl:variable name="base">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@base"><xsl:value-of select="@base"/></xsl:when>
|
||||
<xsl:otherwise>16</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
<xsl:variable name="commands">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@commands"><xsl:value-of select="@commands"/></xsl:when>
|
||||
|
|
@ -1183,7 +1189,7 @@
|
|||
<xsl:call-template name="component">
|
||||
<xsl:with-param name="machine" select="$machine"/>
|
||||
<xsl:with-param name="class">debugger</xsl:with-param>
|
||||
<xsl:with-param name="parms">,commands:'<xsl:value-of select="$commands"/>',messages:'<xsl:value-of select="$messages"/>'</xsl:with-param>
|
||||
<xsl:with-param name="parms">,base:<xsl:value-of select="$base"/>,commands:'<xsl:value-of select="$commands"/>',messages:'<xsl:value-of select="$messages"/>'</xsl:with-param>
|
||||
</xsl:call-template>
|
||||
</xsl:template>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue