Only proton decay can stop it now.
May 12, 2020 9:33 AM   Subscribe

This chip plays ‘Doom’ and nothing else [Engadget] It’s been over 25 years since Doom was unceremoniously released on a university FTP server. And despite its age, the classic first-person shooter has become a mainstay, not just for gamers, but also for programmers. The game has shown up on a ridiculous amount of hardware, from ATMs to printer screens to iPods. Graphics and game development enthusiast Sylvain Lefebvre [@Sylvain] , though, has created a machine that only plays his custom port of Doom. [Twitter thread linked below.]
The DooM-chip! It will run E1M1 till the end of times (or till power runs out, whichever comes first). Algorithm is burned into wires, LUTs and flip-flops on an #FPGA: no CPU, no opcodes, no instruction counter. Running on Altera CycloneV + SDRAM. Everything is described in a language I am working on: SDRAM controller, divider, BSP traversal, texture unit, etc. Main renderer (w/o data) is 666 lines of code (!). A great test case, made quite a few improvements, fixed some issues, learned a lot on CycloneV + Quartus.
posted by Fizz (14 comments total) 17 users marked this as a favorite
 
This is how we get Skynet, isn’t it? It will accidentally fall into a Boston Dynamics robot, and two weeks later we are all done for.
posted by GenjiandProust at 9:41 AM on May 12, 2020 [7 favorites]


I mean, let's go one step further, this is how we get Doomguy.
posted by Fizz at 9:44 AM on May 12, 2020 [2 favorites]


Looks like the author has also created their own C-like language that transpiles into Verilog. Much less awkward to implement something like this when you have 'while' loops and stuff. Would be interesting to see the tools, and looking forward to the Quake port.
posted by RobotVoodooPower at 9:55 AM on May 12, 2020 [2 favorites]


I'm not sure it passes the "does it run Doom" test if it's only E1M1, which isn't very big and just one of many maps in the original game. Still pretty neat, though.
posted by May Kasahara at 10:12 AM on May 12, 2020 [2 favorites]


So if this is not a stored-program computer but just a very complex arrangement of digital logic, this is, in some ways, DOOM as a pre-microprocessor-age Game & Watch-style electronic game.
posted by acb at 10:27 AM on May 12, 2020 [8 favorites]


Also it doesn't seem to be rendering objects, so there's no real gameplay, it's just rolling through the map file.
posted by SansPoint at 10:33 AM on May 12, 2020 [2 favorites]


Second thought: if you can compile a computer game like DOOM down to an immutable non-programmable machine, could you do the same with any machine? In the light of computer vulnerabilities being found all the time, could we see highly sensitive applications (think banks, identity/authorisation management systems, military systems, order handling systems and so on) being converted from program code running on a potentially vulnerable machine into custom-fabbed circuits, with non-programmable logic handling everything from Ethernet and TCP/IP through to business logic, to interfacing with assumed-dumb storage (ranging from SCSI/IDE to S3 buckets)? That way there'd be no CPU pipeline vulnerabilities or kernel zero-days for an attacker to exploit.
posted by acb at 10:35 AM on May 12, 2020 [4 favorites]


It is pleasing to say "DOOM CHIP" out loud.
posted by doctornemo at 11:00 AM on May 12, 2020 [3 favorites]


That way there'd be no CPU pipeline vulnerabilities or kernel zero-days for an attacker to exploit.

No. That way all your security vulnerabilities would be locked into hardware. Also if any bank has done something like this please let me know. Asking for a friend...
posted by rdr at 11:29 AM on May 12, 2020 [11 favorites]


Is there a way to make a computer that instead of a GPU has a DPU? You load the level into the WAD RAM and the DPU handles it from there.
posted by RobotHero at 12:15 PM on May 12, 2020 [3 favorites]


No. That way all your security vulnerabilities would be locked into hardware.

Though the fewer moving parts there are, or the less flexible the system is, the less hackers could do with it. If it's a state machine without any sort of universal machine language, the attack surface for exploits is a lot smaller.

Of course, if the state machine has a gaping hole, it can be pwned. Hopefully if they start designing tools to compile secure systems to immutable silicon, they'll include some degree of formal verifiability, and the code will look more like Haskell than JavaScript or something.
posted by acb at 1:31 PM on May 12, 2020 [5 favorites]


It is pleasing to say "DOOM CHIP" out loud.

We must secure the Doom Chip.
posted by atoxyl at 1:35 PM on May 12, 2020 [4 favorites]


Even if we imagine a world in which it's possible to write formally verified programs of substantial complexity that operate well under real-world constraints, they're still vulnerable to bugs in the specification.
posted by teh_boy at 5:08 PM on May 12, 2020 [2 favorites]


They are, though the failure modes are gentler when the exploitable environment you're defending does not include a stored-program machine capable of executing arbitrary code, but rather a hardwired state machine narrowly tailored to your business logic. There, successful exploits look more like getting a vending machine to dispense a crisp packet without paying than like pwning an entire server for use as a base to pwn whatever it's connected to.
posted by acb at 9:53 AM on May 14, 2020


« Older Eephus Ain't Nothing   |   SFGate Hot Cake Hot Take Newer »


This thread has been archived and is closed to new comments