Megalextoria
Retro computing and gaming, sci-fi books, tv and movies and other geeky stuff.

Home » Digital Archaeology » Computer Arcana » Apple » Apple II » 6502bench SourceGen 1.0 released
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
6502bench SourceGen 1.0 released [message #374706] Tue, 16 October 2018 14:05 Go to next message
Anonymous
Karma:
Originally posted by: fadden

Version 1.0 of the SourceGen disassembler is now available. Source and pre-built binaries can be downloaded from github.

Development is ongoing, but I think it's at a point where it's stable and useful. The list of potential features continues to grow.

* Main site: https://6502bench.com/
* Github page: https://github.com/fadden/6502bench/

I want to thank everyone who helped work through the weird Windows and .NET issues. I can now test releases with a virtual Win7 SP1 system, so I have a higher degree of confidence that the binaries will actually work for someone other than me.
6502bench SourceGen 1.0 released [message #374708 is a reply to message #374706] Tue, 16 October 2018 15:01 Go to previous messageGo to next message
Antoine Vignau is currently offline  Antoine Vignau
Messages: 1860
Registered: October 2012
Karma: 0
Senior Member
Comgrats, Andy!
av
Re: 6502bench SourceGen 1.0 released [message #374814 is a reply to message #374706] Thu, 18 October 2018 12:08 Go to previous messageGo to next message
Anonymous
Karma:
Originally posted by: frank_o_rama

Had a chance to play around with it last night. No issues getting it to run.. Really nice program!

Is there a way to export the text from Sourcegen? Or does it always need to be run through one of the 2 compilers? (got both merlin and cc65/cl65 working without issues). Side note: support for ACME compiler?

I did have an issue with a linked data file. I moved it into a folder after I saved the project and couldn't get sourcegen to save the new location (had to relink it on every open--fixed by just creating a new project).

Bytes column would maybe be easier to read if it had an option to add spaces between the bytes. (20 58 FC instead of 2058FC)

Lastly, there's a 'box' character after some of the opcodes. Should that be a character font I don't have installed? Or is that denoting that the disassembler isn't sure what the correct opcode sequence is? (or both). Everything re-assembled without errors either way.

Nice work!

f
Re: 6502bench SourceGen 1.0 released [message #374832 is a reply to message #374814] Thu, 18 October 2018 19:32 Go to previous messageGo to next message
Anonymous
Karma:
Originally posted by: fadden

On Thursday, October 18, 2018 at 9:08:46 AM UTC-7, frank_...@hotmail.com wrote:
> Is there a way to export the text from Sourcegen? Or does it always need to be run through one of the 2 compilers? (got both merlin and cc65/cl65 working without issues). Side note: support for ACME compiler?

Right now your options are assembly generation, and copy & paste (Ctrl-A to select all, Ctrl-C to copy, then paste it somewhere; you can choose whether or not to include the address and byte columns in the settings).

Note generation and cross-assembly are separate steps. Clicking "Generate" generates the source file whether or not the assembler is installed.

There's a feature request (https://github.com/fadden/6502bench/issues/7) for making this easier. I haven't decided what form that will take.


> I did have an issue with a linked data file. I moved it into a folder after I saved the project and couldn't get sourcegen to save the new location (had to relink it on every open--fixed by just creating a new project).

The project and data files really want to live in the same directory. None of the data file is included in the project file, so SourceGen can't do anything useful without both files.


> Bytes column would maybe be easier to read if it had an option to add spaces between the bytes. (20 58 FC instead of 2058FC)

That's easy.


> Lastly, there's a 'box' character after some of the opcodes. Should that be a character font I don't have installed? Or is that denoting that the disassembler isn't sure what the correct opcode sequence is? (or both). Everything re-assembled without errors either way.

What you should be seeing is a fast-forward symbol (⏩). I checked just now on my Win7 virtual machine and I also see an empty box character.

It means there's an "embedded" opcode there. For example, you can find this in the Amper-fdraw example:

1f86: 201c60 jsr f_DrawLine
1f89: 2c bit ⏩ $3be6 ;use BIT to skip the inc
1f8a: e63b skip2 inc PCH
1f8c: a53b skip lda PCH

At $1f89 there's a three-byte BIT instruction, but you'll notice the bytes column only has one byte in it. That's because code elsewhere branched into the middle of the bit instruction at $1f8a.

So if you execute from $1f86, you do the JSR, then the BIT, then the LDA, skipping the INC because it's inside the BIT. If you execute from $1f8a, you do the INC then the LDA.

A simple disassembler (like the Apple II monitor) will just show the BIT followed by the LDA and leave you to figure out that there's a buried branch-target INC in there. SourceGen tries to show you both paths, sticking a symbol after the opcode to alert you to the situation.

I'll need to find a different symbol that works on Win7. It's just using the Consolas font, but for some reason stock Win7 doesn't have that glyph. (It doesn't seem to exist on Linux with DejaVu Sans Mono either.)
Re: 6502bench SourceGen 1.0 released [message #374835 is a reply to message #374832] Thu, 18 October 2018 20:17 Go to previous message
Michael AppleWin Debu is currently offline  Michael AppleWin Debu
Messages: 1262
Registered: March 2013
Karma: 0
Senior Member
> I'll need to find a different symbol that works on Win7.

Which symbols do you need?

This page maybe helpful if you haven't seen it already:

https://en.wikipedia.org/wiki/List_of_typefaces_included_wit h_Microsoft_Windows

For AppleWin's debugger we need up and down arrows (to show branch direction) so we are using the native MouseText texture atlas (CHARSET4.BMP) before we switched from the native "Courier New". I think at one point I also looked into using Web Dings before I realized MouseText had all the glyphs I needed.

Raw debugger source for up/down arrow glyphs:

char * g_sConfigBranchIndicatorUp [ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "^", "\x8B" }; // "`K" 0x4B
char * g_sConfigBranchIndicatorEqual[ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "=", "\x88" }; // "`H" 0x48
char * g_sConfigBranchIndicatorDown [ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "v", "\x8A" }; // "`J" 0x4A

char * g_sConfigBranchIndicatorUp [ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "^", "\x35" };
char * g_sConfigBranchIndicatorEqual[ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "=", "\x33" };
char * g_sConfigBranchIndicatorDown [ NUM_DISASM_BRANCH_TYPES+1 ] = { " ", "v", "\x36" };

Cheers,
Michael
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IIe mobo versions.
Next Topic: Re: Archive of comp.binaries.apple2
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Mar 28 10:50:48 EDT 2024

Total time taken to generate the page: 0.02897 seconds