xasm 3.1.1: First Update in Five Years for the Concise 6502 Cross-Assembler
On 20 November 2019 Piotr Fusik (pfusik) released xasm 3.1.1, a maintenance update to his 6502 cross-assembler for Windows, macOS and Linux and the first new version since 3.1.0 in July 2014. He announced it on AtariAge a week later as a minor release.
What xasm is
xasm produces Atari 8-bit binaries by default, and its syntax extends Quick Assembler, a native Atari assembler from 1991. Its best-known feature is a set of shortcuts for patterns that 6502 code repeats all the time:
MVA/MWAmove a byte or a word in one line instead of anLDA/STApair or four instructions.- Instruction pairs share an operand:
add:sta ptrmeans "add, then store to the same place". - Conditional skip and repeat pseudo-instructions replace short branches.
scc:inc ptr+1increments only if carry is set, andmva:rpl pattern,y (ptr),y-loops a copy until the result goes negative.
In the README's example, a loop that fills 192 screen lines from a 40-byte pattern shrinks from 18 instructions to eight lines. Whitespace matters: it separates an instruction's operand from the comment, so no semicolon is needed. The MADS assembler supports part of this syntax too.
What 3.1.1 changes
The changes came mostly from users' requests:
- A partial object file is removed when assembly fails, so a broken build no longer leaves a misleading output file. This was requested by Bill Kendrick.
- The unused-label warning now names the label, requested by Peter Dell.
a:andf:modifiers are supported onRUNandINI, the directives that set an Atari binary's run and init addresses.- Faster assembly on network drives, after a report by Marek Pavlik.
Notes for users
xasm is written in the D programming language and is distributed for current Windows, macOS and Linux systems. When a user asked in the thread about MS-DOS or Windows 98, nobody could point to a build for them. Editor support is good. The author uses SciTE with a supplied properties file (Ctrl+F7 to assemble, F5 to run in the emulator), and there are syntax extensions for Vim and Visual Studio Code, plus support in the WUDSN IDE for Eclipse.
Where to get it
Downloads, documentation and the full source are at github.com/pfusik/xasm. The project has continued since: version 3.2.0 followed in June 2021 and 3.2.1 in December 2022.
Credits
- AtariAge — xasm 3.1.1 released — AtariAge forum members
- GitHub — pfusik/xasm (README and releases) — GitHub project authors
