4 ms·
Slightly off-topic. If you want to learn low level assembly programming in the XXI century, 6502 is still an EXCELLENT choice! Simple architecture and really r
by iberator 11mo ago
Slightly off-topic. If you want to learn low level assembly programming in the XXI century, 6502 is still an EXCELLENT choice!
Simple architecture and really really joyful to use even for casual programmers born a decade, or two later :)
- 1000100_1000101 11mo agoI'd argue that 68K is simpler to learn and use. You get a similar instruction set, but 32-bit registers, many of them. It's even got a relocatable stack so it can handle threading when you get to that point.
- chihuahua 11mo agoI agree, I feel like the 68k architecture was a dream for assembly programming. each register is large enough to store useful values, there are lots of them, there are instructions for multiply and divide. This allows you to focus on the essence of what you want to accomplish, and not have to get side-tracked into how to represent the X-coordinate of some object because it's just over 8 bits wide, or how to multiply to integers. Both of these seemingly trivial things already require thought on the 6502.
- monocasa 11mo agoAnd registers are actually pointer width, so you don't have to go through memory just to do arbitrary pointer arithmetic.
- jacquesm 11mo agoIf 8 bit: 6809. If 32 bit: 68K. Those are miles ahead of the 6502. Otoh if you want to see a fun quirky chip the 6502 is definitely great, and I'd recommend you use a (virtual) BBC Micro to start you off with.
- bsder 11mo agoYeah, the 6809 is just ridiculously good to learn assembly language on. Motorola cleaned up all the idiocies from the 6800 on the 6809. The attention the 6502 get is just because of history. The advantage the 6502 had was that it was cheap--on every other axis the 6502 sucked.
- jacquesm 11mo agoImagine a world where the Apple II had a 6800 later upgraded to 6809...
- hashmash 11mo agoIt wouldn't have happened because the 6809 wasn't binary compatible with the 6800.
- jacquesm 11mo agoSo?
- hashmash 11mo agoBecause none of the existing software would work. The idea of running a Rosetta-like feature on an 8-bit CPU isn't feasible. The Apple II eventually received an upgraded processor, the 65816, which was compatible with the 6502.
- jacquesm 11mo agoIn those days nobody cared about binary compatibility. If you had an assembler and the source code you were all set.
- jecel 11mo agoThough a problem, as you point out, it still happened. The 6800 based SWTPC was followed by 6809 machines what need to have all their software reassembled. On the other side of the cpu wars, all those 8080 machines moving on the Z80s got to keep all their binary software, which happened again for IBM PCs and clones as those evolved. https://en.wikipedia.org/wiki/SWTPC_6800 https://en.wikipedia.org/wiki/SWTPC_6800
- retrac 11mo agoLLVM includes an equivalent to binutils, with a macro assembler, linker, objdump with disassembler, library tools, handling formats like ELF and raw binary etc. LLVM-MOS includes all of that. It is the same process as using LLVM to cross-assemble targeting an embedded ARM board. Same GNU assembler syntax just with 6502 opcodes. This incidentally makes LLVM-MOS one of the best available 6502 assembly development environments, if you like Unix-style cross-assemblers.
- BoredomIsFun 11mo agoI'd argue Atmel AVR is a better choice - this is a very a much alive platform, that did not change much last 30 years.