| |
Sasq
Registered: Apr 2004 Posts: 155 |
Badass - New 6502 Assembler
The last couple of months I've created a new 6502 Assembler called bass (or Badass).
The basic idea is for it to be as advanced as Kickassembler, but with a less complex, more unified syntax.
And it also has unit tests in an internal emulator.
You can find it at https://github.com/sasq64/bass
I've started a tutorial here: http://apone.org/bass/part1.html
Here is an example C64 source http://apone.org/bass/example.asm.html |
|
... 106 posts hidden. Click here to view all posts.... |
| |
Krill
Registered: Apr 2002 Posts: 2839 |
Quoting JackAsserhashbangs are implemented by the exec() routine in the OS.. Until the interpreter in question chokes on a syntax error. :) |
| |
Sasq
Registered: Apr 2004 Posts: 155 |
@Krill: Done :)
(Just extended the grammar to allow '#' comments if they are whole line comments). |
| |
Krill
Registered: Apr 2002 Posts: 2839 |
Awesome! \=D/ |
| |
Sasq
Registered: Apr 2004 Posts: 155 |
My "vague" plan about sections and linking is not to have linking, but rather something more "javascript" like where you can have sources that "export" symbols and then you can import those sources.
And instead of a link script you can choose to have a top level source file that lays out everything. |
| |
JackAsser
Registered: Jun 2002 Posts: 1989 |
Quote: @Krill: Done :)
(Just extended the grammar to allow '#' comments if they are whole line comments).
Ahh, that little detail! |
| |
JackAsser
Registered: Jun 2002 Posts: 1989 |
Quote: My "vague" plan about sections and linking is not to have linking, but rather something more "javascript" like where you can have sources that "export" symbols and then you can import those sources.
And instead of a link script you can choose to have a top level source file that lays out everything.
I can do a small write up what I personally would need in terms of segments to support building a complex cart like EotB. I had similar chats with Mads when he implemented segments in Kickasm. |
| |
Sasq
Registered: Apr 2004 Posts: 155 |
Quote: I can do a small write up what I personally would need in terms of segments to support building a complex cart like EotB. I had similar chats with Mads when he implemented segments in Kickasm.
That would be great! |
| |
Krill
Registered: Apr 2002 Posts: 2839 |
Quoting SasqMy "vague" plan about sections and linking is not to have linking, but rather something more "javascript" like where you can have sources that "export" symbols and then you can import those sources.
And instead of a link script you can choose to have a top level source file that lays out everything. Sounds like this could be achieved with separate section-declare/collect and section directives, as 64tass does.
These allow the position in the source code to be independent of the position in the output binary.
Rest (splitting up source files) can be done via regular include semantics. |
| |
JackAsser
Registered: Jun 2002 Posts: 1989 |
Quote: Quoting SasqMy "vague" plan about sections and linking is not to have linking, but rather something more "javascript" like where you can have sources that "export" symbols and then you can import those sources.
And instead of a link script you can choose to have a top level source file that lays out everything. Sounds like this could be achieved with separate section-declare/collect and section directives, as 64tass does.
These allow the position in the source code to be independent of the position in the output binary.
Rest (splitting up source files) can be done via regular include semantics.
It's not only that. It's more about the assembler needs to know the bank ID for all labels it has so that bank switch macros knows what bank to switch in when JSRing (via ram trampolines) across different banks.
ca65 solves this by allowing an arbitrary bank-id to be assigned to a memory-directive. Segments emitting code into that memory will have all their labels assigned with that bank ID and other code can resolve it with the .bank(label) operator. |
| |
Krill
Registered: Apr 2002 Posts: 2839 |
Would a .sectionof(label) directive allow for that? Sections are named, of course. |
Previous - 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 - Next |