Virtual CPU Stays on Script

Some will see it as a great thing, and others as an example of how JavaScript is being abused daily, but [Francis Stokes] decided to design his own CPU architecture and implemented a virtual version of it using JavaScript. The CPU is a 16-bit affair and has a simplified assembly language. The code is on GitHub, but the real value is [Francis’] exposition of the design in the original post.

While discussing the design, [Francis] reveals his first pass at the instruction set, discussed what he found wrong about it, and then reveals the final set composed of real instructions and some macros to handle other common cases.

[Francis] got the CPU bug from watching [Ben Eater’s] videos. Of course, [Ben’s] CPU is 8-bit and lives on a breadboard. If we had wanted to test out a new instruction set architecture, we would probably use C or C++ or… well, honestly, anything but JavaScript. But if there’s one thing we’ve learned is that everyone’s tastes are different. We have no doubt, though, there will be some spirited comments on both sides.

Developing CPUs for sport has become almost popular these days. Of course, few have the surrounding environment that A2Z does.

Filed under: computer hacks http://ift.tt/2umbhB5 http://ift.tt/2aM8QhC

Anúncios

Deixe um comentário

Preencha os seus dados abaixo ou clique em um ícone para log in:

Logotipo do WordPress.com

Você está comentando utilizando sua conta WordPress.com. Sair / Alterar )

Imagem do Twitter

Você está comentando utilizando sua conta Twitter. Sair / Alterar )

Foto do Facebook

Você está comentando utilizando sua conta Facebook. Sair / Alterar )

Foto do Google+

Você está comentando utilizando sua conta Google+. Sair / Alterar )

Conectando a %s