mirror of
https://github.com/fadden/6502bench.git
synced 2025-02-20 06:29:04 +00:00
Various minor changes
- Freeze Note brushes, so HTML export doesn't blow up when it tries to access them. - Add Ctrl+Shift+E as keyboard shortcut for File > Export. - For code/data percentage, count inline data as data. - Tweak code/data percentage text. - Document Merlin32 '{' bug. - Tweak tutorial text.
This commit is contained in:
parent
65b960d78b
commit
5010fbae37
@ -1592,7 +1592,7 @@ namespace SourceGen {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (attr.IsDataStart) {
|
if (attr.IsDataStart || attr.IsInlineDataStart) {
|
||||||
// There shouldn't be data items inside of other data items.
|
// There shouldn't be data items inside of other data items.
|
||||||
offset += attr.Length;
|
offset += attr.Length;
|
||||||
|
|
||||||
|
@ -435,6 +435,7 @@ namespace SourceGen {
|
|||||||
if (color != NoColor) {
|
if (color != NoColor) {
|
||||||
parts.HasBackgroundColor = true;
|
parts.HasBackgroundColor = true;
|
||||||
parts.BackgroundBrush = new SolidColorBrush(color);
|
parts.BackgroundBrush = new SolidColorBrush(color);
|
||||||
|
parts.BackgroundBrush.Freeze(); // export runs on non-UI thread
|
||||||
}
|
}
|
||||||
return parts;
|
return parts;
|
||||||
}
|
}
|
||||||
|
@ -163,7 +163,7 @@ limitations under the License.
|
|||||||
<system:String x:Key="str_ScanC64ScreenCode">C64 Screen Code</system:String>
|
<system:String x:Key="str_ScanC64ScreenCode">C64 Screen Code</system:String>
|
||||||
<system:String x:Key="str_SetupSystemSummaryFmt">{1} CPU @ {2} MHz</system:String>
|
<system:String x:Key="str_SetupSystemSummaryFmt">{1} CPU @ {2} MHz</system:String>
|
||||||
<system:String x:Key="str_ShowCol">Show</system:String>
|
<system:String x:Key="str_ShowCol">Show</system:String>
|
||||||
<system:String x:Key="str_StatusByteCountFmt">{0:F1}KB: {1:F1}% code, {2:F1}% data, {3:F1}% junk</system:String>
|
<system:String x:Key="str_StatusByteCountFmt">{0:F1}KB ({1:F1}% code, {2:F1}% data, {3:F1}% junk)</system:String>
|
||||||
<system:String x:Key="str_StatusReady">Ready</system:String>
|
<system:String x:Key="str_StatusReady">Ready</system:String>
|
||||||
<system:String x:Key="str_StrVfyDciMixedData">DCI string has mixed data</system:String>
|
<system:String x:Key="str_StrVfyDciMixedData">DCI string has mixed data</system:String>
|
||||||
<system:String x:Key="str_StrVfyDciNotTerminated">DCI string not terminated</system:String>
|
<system:String x:Key="str_StrVfyDciNotTerminated">DCI string not terminated</system:String>
|
||||||
|
@ -277,7 +277,7 @@ code, but also needs to know how to handle the corner cases.</p>
|
|||||||
<li>PC relative branches don't wrap around at bank boundaries.</li>
|
<li>PC relative branches don't wrap around at bank boundaries.</li>
|
||||||
<li>For some failures, an exit code of zero is returned.</li>
|
<li>For some failures, an exit code of zero is returned.</li>
|
||||||
<li>Immediate operands with a comma (e.g. <code>LDA #','</code>)
|
<li>Immediate operands with a comma (e.g. <code>LDA #','</code>)
|
||||||
cause an error.</li>
|
or curly braces (e.g. <code>LDA #'{'</code>) cause an error.</li>
|
||||||
<li>Some DP indexed store instructions cause errors if the label isn't
|
<li>Some DP indexed store instructions cause errors if the label isn't
|
||||||
unambiguously DP (e.g. <code>STX $00,X</code> vs.
|
unambiguously DP (e.g. <code>STX $00,X</code> vs.
|
||||||
<code>STX $0000,X</code>). This isn't a problem with project/platform
|
<code>STX $0000,X</code>). This isn't a problem with project/platform
|
||||||
|
@ -36,7 +36,7 @@ The buttons are shortcuts for items in the File menu.</p>
|
|||||||
|
|
||||||
<h3>Create the project</h3>
|
<h3>Create the project</h3>
|
||||||
|
|
||||||
<p>Click "Start new project".</p>
|
<p>Click the "Start new project" button.</p>
|
||||||
|
|
||||||
<p>The New Project window has three parts. The top-left window has a
|
<p>The New Project window has three parts. The top-left window has a
|
||||||
tree of known platforms, arranged by manufacturer. The top-right window
|
tree of known platforms, arranged by manufacturer. The top-right window
|
||||||
@ -460,7 +460,7 @@ to 2 (it's a 2-byte pointer). Click "OK" to create the entry, and then
|
|||||||
"OK" to update the table.</p>
|
"OK" to update the table.</p>
|
||||||
<p>There's now a ".var" statement (similar to a .equ) above line $203d,
|
<p>There's now a ".var" statement (similar to a .equ) above line $203d,
|
||||||
and the stores to $02/$03 have changed to "PTR1" and "PTR1+1".</p>
|
and the stores to $02/$03 have changed to "PTR1" and "PTR1+1".</p>
|
||||||
<p>Double-click on the JSR on line $2045 to jump to L209A. This just
|
<p>Double-click on the JSR on line $2045 to jump to L20A7. This just
|
||||||
loads a value from $3000 into the accumulator and returns, so not much
|
loads a value from $3000 into the accumulator and returns, so not much
|
||||||
to see here. Hit the back-arrow in the toolbar to jump back to the JSR.</p>
|
to see here. Hit the back-arrow in the toolbar to jump back to the JSR.</p>
|
||||||
<p>The next bit of code masks the accumulator so it holds a value between
|
<p>The next bit of code masks the accumulator so it holds a value between
|
||||||
@ -497,7 +497,8 @@ counts are adjusted for everything SourceGen can figure out. For example,
|
|||||||
the BEQ on line $205a shows "2+" cycles, meaning that it takes at least two
|
the BEQ on line $205a shows "2+" cycles, meaning that it takes at least two
|
||||||
cycles but might take more. That's because conditional branches take an
|
cycles but might take more. That's because conditional branches take an
|
||||||
extra cycle if the branch is taken. The BNE on line $2061" shows 3 cycles,
|
extra cycle if the branch is taken. The BNE on line $2061" shows 3 cycles,
|
||||||
because we know that the branch is always taken. (If you want to see why,
|
because we know that the branch is always taken and doesn't cross a page
|
||||||
|
boundary. (If you want to see why it's always taken,
|
||||||
look at the value of the 'Z' flag in the "flags" column. Lower-case 'z'
|
look at the value of the 'Z' flag in the "flags" column. Lower-case 'z'
|
||||||
means the zero-flag is clear. You can see it got set on the
|
means the zero-flag is clear. You can see it got set on the
|
||||||
<code>ORA #$80</code> line.)</p>
|
<code>ORA #$80</code> line.)</p>
|
||||||
@ -588,7 +589,8 @@ on.</p>
|
|||||||
|
|
||||||
<p>Start a new project. Select the Apple //e platform, click Select File
|
<p>Start a new project. Select the Apple //e platform, click Select File
|
||||||
and navigate to the Examples directory. In A2-Amper-fdraw, select
|
and navigate to the Examples directory. In A2-Amper-fdraw, select
|
||||||
<code>AMPERFDRAW#061d60</code>. Click "OK" to create the project.</p>
|
<code>AMPERFDRAW#061d60</code> (ignore the existing .dis65 file). Click
|
||||||
|
"OK" to create the project.</p>
|
||||||
<p>Not a lot to see here -- just half a dozen lines of loads and stores.
|
<p>Not a lot to see here -- just half a dozen lines of loads and stores.
|
||||||
This particular program interfaces with Applesoft BASIC, so we can make it
|
This particular program interfaces with Applesoft BASIC, so we can make it
|
||||||
a bit more meaningful by loading an additional platform
|
a bit more meaningful by loading an additional platform
|
||||||
@ -758,7 +760,7 @@ list of parameters at the bottom. The file offset indicates where in
|
|||||||
the file the bitmap starts; note this is an offset, not an address
|
the file the bitmap starts; note this is an offset, not an address
|
||||||
(that way, if you change the address, your visualizations don't break).
|
(that way, if you change the address, your visualizations don't break).
|
||||||
This is followed by the bitmap's width in bytes, and the bitmap's height.
|
This is followed by the bitmap's width in bytes, and the bitmap's height.
|
||||||
Because we have 8 pixels per byte, we're currently showing a 1x1 image.
|
Because we have 8 pixels per byte, we're currently showing an 8x1 image.
|
||||||
We'll come back to row stride.</p>
|
We'll come back to row stride.</p>
|
||||||
<p>We happen to know (by playing the game and/or reading the fictitious
|
<p>We happen to know (by playing the game and/or reading the fictitious
|
||||||
drawing code) that the image is 8x8, so change the value in the height
|
drawing code) that the image is 8x8, so change the value in the height
|
||||||
@ -775,7 +777,8 @@ Set window as well. You should now see the blue 'X' in the code listing
|
|||||||
above line $100A.</p>
|
above line $100A.</p>
|
||||||
|
|
||||||
<p>Repeat the process at line $1012: select the line, create a visualization
|
<p>Repeat the process at line $1012: select the line, create a visualization
|
||||||
set, create a new bitmap, set the height to 8, click "OK" twice.</p>
|
set, create a new visualization. The height will default to 8 because
|
||||||
|
that's what you used last time. Click "OK" in both dialogs to close them.</p>
|
||||||
|
|
||||||
<p>Repeat the process at line $101A, but this time the image is 40x40
|
<p>Repeat the process at line $101A, but this time the image is 40x40
|
||||||
rather than 8x8. Set the width to 5, and the height to 40. This makes
|
rather than 8x8. Set the width to 5, and the height to 40. This makes
|
||||||
|
@ -113,7 +113,11 @@ limitations under the License.
|
|||||||
</RoutedUICommand.InputGestures>
|
</RoutedUICommand.InputGestures>
|
||||||
</RoutedUICommand>
|
</RoutedUICommand>
|
||||||
<RoutedUICommand x:Key="ExitCmd" Text="Exit"/>
|
<RoutedUICommand x:Key="ExitCmd" Text="Exit"/>
|
||||||
<RoutedUICommand x:Key="ExportCmd" Text="Export..."/>
|
<RoutedUICommand x:Key="ExportCmd" Text="Export...">
|
||||||
|
<RoutedUICommand.InputGestures>
|
||||||
|
<KeyGesture>Ctrl+Shift+E</KeyGesture>
|
||||||
|
</RoutedUICommand.InputGestures>
|
||||||
|
</RoutedUICommand>
|
||||||
<RoutedUICommand x:Key="FindNextCmd" Text="Find Next">
|
<RoutedUICommand x:Key="FindNextCmd" Text="Find Next">
|
||||||
<RoutedUICommand.InputGestures>
|
<RoutedUICommand.InputGestures>
|
||||||
<KeyGesture>F3</KeyGesture>
|
<KeyGesture>F3</KeyGesture>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user