Scroll Top

Another kid just built a fully functional RISC-V computer inside a computer game

WHY THIS MATTERS IN BRIEF

What if the future of computing wasn’t silicon chips but virtual or meta computers within game environments developed and optimised by AI? Hmmm …

 

Love the Exponential Future? Join our XPotential Community, future proof yourself with courses from XPotential University, read about exponential tech and trendsconnect, watch a keynote, or browse my blog.

A while ago I wrote about CHUNGUS-2 – something I called a Meta Computer because there’s no official name yet for the tech – that was a computer that had been built in Minecraft out of Redstone blocks that was capable of running software, such as Artificial Intelligence (AI) and basic games. And now Canadian engineering physics student Xander Naumenko has spent more than half a year in Re-Logic’s action-adventure sandbox Terraria, but not to explore or build a base – he’s spent that time building a functional 32-bit RISC-V processor entirely in-game. And, just as we saw with the CHUNGUS-2 project, people are very impressed.

 

RELATED
Scientists have managed to clone photons using quantum dots

 

“I’ve been working on this for over six months now,” Naumenko explains of his unusual project, “and thought it’s cool enough that other’s might be interested in learning about it. By emulating a complete RV32-I instruction set inside the wiring system of Terraria, we push back speeds to the early ’70s era.”

 

See it in action

 

Terraria is Re-Logic’s popular sandbox game, in which the player is thrown into a procedurally generated world with little more than their wits and a friendly guide and given the job of survival — exploring the planet, researching new technologies, mining for resources, and crafting objects. Those objects, of course, are normally of use in-game — but what Naumenko has crafted is something very different.

“Inside the game there’s a mechanic called ‘wiring’ which lets you trigger certain tiles such as opening doors or activating traps. When I say I’ve ‘created a computer in Terraria’ what I mean is that I’ve completely simulated the inner workings of a regular computer, except instead of electronics I did it inside of a video game world.”

 

RELATED
Microsoft unveils it's new real time AI engine

 

The resulting computer effectively simulates a 32-bit implementation of the free and open source RISC-V instruction set architecture, and is Turing-complete — meaning that, given enough time and resources, it can technically execute any program that a traditional computer can execute. To prove it, Naumenko has written software to run atop his processor — including a simple clone of Atari’s Pong and a 3D rendering engine which, admittedly, takes 45 seconds per frame.

“In real world circuits, when a circuit is on it stays on,” Naumenko explains of one of the biggest challenges faced in the project. “But in Terraria everything is just sent in pulses. This means it behaves completely differently, and a lot of traditional circuits have to be redesigned in this new paradigm.”

This is, of course, not the first time a game has been used to create a functional computer, as well as CHUNGUS-2 late last year Danny Spencer became the first gamer to build a functioning calculator in Id Software’s classic first-person shooter Doom.

 

RELATED
Intel unveils Loihi, a revolutionary new Neuromorphic self-learning processor

 

Compared to a RISC-V core running in a traditional simulator, the Terraria version isn’t exactly a speed demon — even when a game mod vastly accelerates the operation of the wiring system: “Running without the [WireHead] accelerator mod, the computer runs at around 0.1 instructions per second,” Naumenko admits. “When using the mod I get around 5,000 instructions per second.”

More details on the project are available in Naumenko’s video above, while everything you need to replicate the simulator in your own copy of Terraria is available on the Computerraria GitHub repository under an unspecified open source license.

Related Posts

Leave a comment

You have Successfully Subscribed!

Pin It on Pinterest

Share This