First glimpse: 65Org16 (6502 with 32bit addresses)
Posted: Mon May 02, 2011 7:39 pm
Some of you may recall a very long thread which threw up at least a couple of suggestions concrete enough to be named: 65Org16 and 65Org32. (Other ideas for enhanced 6502 are works in progress: 1, 2)
The idea with 65Org16 was that it was the least-effort method of getting a lot of memory easily available on a 6502-like CPU. It wasn't meant to be fast or to have a lot of extra capabilities or denser code.
Well, I finally did some hacking this afternoon, using Arlet's core as a basis, and it does seem to be relatively straightforward to cook up a version of 6502 with 16-bit registers and a 32-bit address space. The way to look at this is as a 6502 where a byte has 16 bits. There is no particular support for an 8-bit data type or peripheral - you roll your own.
This is of course very early - not even proof of concept.
(Edit: this project now on github as a friendly fork of Arlet's project. See also this summary of 65Org16 threads.)
Anyway, here's a trace: the cpu is running from a tiny ROM, hand-assembled into 16-bit opcodes. Mainly a question of zero-padding with a sprinkling of sign-extending. A usable assembler would be one of the things needed.
Question is: who's genuinely interested in a 6502-like CPU, implemented on FPGA, which can address up to 4 gigawords of 16-bit wide memory?
(And who can't wait for André or Ruud to do the job properly... actually they could easily get there before I do as it's taken me a year to do an afternoon's work.)
(A bit of trickery with external latches and you could have 24 bits of address from a 40-pin package: 16 megawords of 16-bit wide memory.)
Cheers
Ed
ps. Big thanks to Arlet for the basis of course. T65 would probably have served but I prefer to work with verilog.
The idea with 65Org16 was that it was the least-effort method of getting a lot of memory easily available on a 6502-like CPU. It wasn't meant to be fast or to have a lot of extra capabilities or denser code.
Well, I finally did some hacking this afternoon, using Arlet's core as a basis, and it does seem to be relatively straightforward to cook up a version of 6502 with 16-bit registers and a 32-bit address space. The way to look at this is as a 6502 where a byte has 16 bits. There is no particular support for an 8-bit data type or peripheral - you roll your own.
This is of course very early - not even proof of concept.
(Edit: this project now on github as a friendly fork of Arlet's project. See also this summary of 65Org16 threads.)
Anyway, here's a trace: the cpu is running from a tiny ROM, hand-assembled into 16-bit opcodes. Mainly a question of zero-padding with a sprinkling of sign-extending. A usable assembler would be one of the things needed.
Question is: who's genuinely interested in a 6502-like CPU, implemented on FPGA, which can address up to 4 gigawords of 16-bit wide memory?
(And who can't wait for André or Ruud to do the job properly... actually they could easily get there before I do as it's taken me a year to do an afternoon's work.)
(A bit of trickery with external latches and you could have 24 bits of address from a 40-pin package: 16 megawords of 16-bit wide memory.)
Cheers
Ed
ps. Big thanks to Arlet for the basis of course. T65 would probably have served but I prefer to work with verilog.