Live data from Hacker News

Cloning a 6502 Apple-1 in just 930 logic gates

obsolescenceguaranteed.blogspot.com

11–20 of 47 posts

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#11
post #7
post #4

"It needs just 930 logic gates (packed into 33 standard 7400-series ICs) to create a computer that beat 'complex' 1980s home computers like the VIC-20 in terms of both CPU power and graphics." Given that 7400 chips existed at the time, why did no contemporary microcomputer go this route? Would it just have been cost prohibitive?

The short answer is that computers with CPUs made from 7400 series TTL existed, but they weren't "micro".

The Kenbak-1 might be considered an exception to the rule: http://www.kenbak-1.net/index.htm

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#12
>"Like the venerable IBM 360/30, the Gigatron uses a form of microcode to elevate its spartan eight hardware instructions into a comfortable instruction set you can live with. Like the 8-bit IBM 360/30 CPU, the Gigatron normally pretends to be a 16-bitter using its microcoded instruction set."

Could someone elaborate on how exactly the IBM 360/3 and Gigatron "elevate" their eight hardware instructions into a larger ISA via microcode?

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#13
post #4

"It needs just 930 logic gates (packed into 33 standard 7400-series ICs) to create a computer that beat 'complex' 1980s home computers like the VIC-20 in terms of both CPU power and graphics." Given that 7400 chips existed at the time, why did no contemporary microcomputer go this route? Would it just have been cost prohibitive?

930 logic gates + 1K of microcode ROM (so how many gate equivalent is 1K of ROM?) and it only runs 1/4 speed of a 6502.

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#14
post #3

TL;DR: this is a very simple computer running an emulator. Cool project! (The approach is similar to the way many of FPGA applications are done these days.)

I don't really see this as similar to the way many of FPGA applications are done these days. The approach in FPGA is more along the lines of implementing the same logic as the original CPU as opposed to microcoding / emulation.

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#15

>"Like the venerable IBM 360/30, the Gigatron uses a form of microcode to elevate its spartan eight hardware instructions into a comfortable instruction set you can live with. Like the 8-bit IBM 360/30 CPU, the Gigatron normally pretends to be a 16-bitter using its microcoded instruction set." Could someone elaborate on how exactly the IBM 360/3 and Gigatron "elevate" their eight hardware instructions into a larger I…

If you want to implement a complicated computer you have two choices: you can create a complicated logic circuit that does what you need (this is called "hardwired") or you can create a far simpler computer and program it to emulate the complicated one (this is called "microcode").

https://en.wikipedia.org/wiki/Microcode

Since the simple computer will only ever run one program, the emulator for the complicated computer, it can be very specialized. That makes a microcoded IBM 360 very efficient compared to a Z80 emulating an IBM 360, for example. Normally microcoded machines have a tiny special memory to hold the microcode program, from less than a hundred to a few thousand words in size. The Gigatron has its "microcode" in the EPROM while the emulated code is in the RAM.

https://gigatron.io/?page_id=482

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#16
post #4

"It needs just 930 logic gates (packed into 33 standard 7400-series ICs) to create a computer that beat 'complex' 1980s home computers like the VIC-20 in terms of both CPU power and graphics." Given that 7400 chips existed at the time, why did no contemporary microcomputer go this route? Would it just have been cost prohibitive?

The simplicity of Gigatron is compensated by the large memory that was extremely expensive.

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#17
post #3

TL;DR: this is a very simple computer running an emulator. Cool project! (The approach is similar to the way many of FPGA applications are done these days.)

It’s worth mentioning how simple the computer is. While the Gigatron is an 8-bit computer running at ~8 MHz (and probably more powerful than an 8086), it only has... seventeen instructions (with a few encodings for different operands). The instruction set is so limited, they created Gigatron Control Language (GCL) to allow you to write in a slightly higher level assembly. So getting an emulator running is quite an ac…

Getting an 6502 emulator up and running is not too difficult and you saw how the author did it "quickly" which I took to mean in a couple of days / a week.

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#18
post #14
post #3

TL;DR: this is a very simple computer running an emulator. Cool project! (The approach is similar to the way many of FPGA applications are done these days.)

I don't really see this as similar to the way many of FPGA applications are done these days. The approach in FPGA is more along the lines of implementing the same logic as the original CPU as opposed to microcoding / emulation.

I guess I could be more clear. In industrial FPGA applications the goal usually isn't the CPU, the goal is to implement the required logic while keeping the number the gates needed for this to a minimum, and implementing a simple CPU (a.k.a. PSM) is what makes it possible. Same here: the CPU only serves as the economical way to implement something else (another CPU, in this case).

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#19
post #15

>"Like the venerable IBM 360/30, the Gigatron uses a form of microcode to elevate its spartan eight hardware instructions into a comfortable instruction set you can live with. Like the 8-bit IBM 360/30 CPU, the Gigatron normally pretends to be a 16-bitter using its microcoded instruction set." Could someone elaborate on how exactly the IBM 360/3 and Gigatron "elevate" their eight hardware instructions into a larger I…

If you want to implement a complicated computer you have two choices: you can create a complicated logic circuit that does what you need (this is called "hardwired") or you can create a far simpler computer and program it to emulate the complicated one (this is called "microcode"). https://en.wikipedia.org/wiki/Microcode Since the simple computer will only ever run one program, the emulator for the complicated comput…

Thanks, I understand that microcode is one of two ways to implement the control unit on a CPU. My question was more of if a CPU only has "a spartan eight hardware instructions" and microcode is used to implement each of those eight hardware instructions how does that allow the ISA to be greater than the original eight instructions?

Re: Cloning a 6502 Apple-1 in just 930 logic gates

#20
post #4

"It needs just 930 logic gates (packed into 33 standard 7400-series ICs) to create a computer that beat 'complex' 1980s home computers like the VIC-20 in terms of both CPU power and graphics." Given that 7400 chips existed at the time, why did no contemporary microcomputer go this route? Would it just have been cost prohibitive?

The simplicity of Gigatron is compensated by the large memory that was extremely expensive.

This is a much more profound insight than is readily apparent. It is really easy to build a Turing machine -- except for the tape. You could probably build a universal TM is a lot less than 930 gates. All hardware design is essentially nothing more than taking common design patterns and moving off the tape and into the engine so that the tape can be more compact and the machine can run faster.

This is the main reason I personally find actual hardware re-implementations of old machines to be fairly uninteresting. There's really very little sport in it once you know the trick.

Post reply on HN