{"rewrite":{"id":"r_4aa4cc616f53cfb908047183","clusterId":"c_cc91cbd88eec238a723844fc","slug":"doom-runs-on-regular-expressions-180-seconds-per-frame","model":"deepseek-v4-flash:free","headline":"DOOM Runs on Regular Expressions, 180 Seconds Per Frame","summary":"Programmer Artem Litkin released DOOM on regex, a project that runs the classic FPS using only regular expression search and replace. A 96.6 MB string holds the entire virtual machine, and 544 replacement rules execute the game. Rendering one frame takes about 180 seconds across five machines.","whyItMatters":"The project proves regular expressions are Turing complete in practice, running a full game engine through a 32-bit virtual CPU built from string replacements.","webCardHtml":"\u003cp\u003eArtem Litkin\u0026#39;s DOOM on regex stores the entire virtual computer, including the CPU registers, RAM, framebuffer, the DOOM engine, and WAD data, in one plain-text string of about 96.6 MB. A driver checks 544 replacement rules in fixed order, and each match rewrites part of the string, stepping the virtual machine.\u003c/p\u003e\u003cp\u003eThe virtual CPU, named RVM-1, is a 32-bit design that operates solely on regex search and replace. The DOOM engine itself comes from doomgeneric, converted to RVM-1 instructions using the C compilers 8cc and ELVM. Rendering one frame requires about 13.99 million replacements across five machines, taking roughly 180 seconds.\u003c/p\u003e\u003cp\u003eLitkin notes the iteration of replacements is essentially a Markov algorithm, theoretically Turing complete. He says the real questions were whether it could finish before the heat death of the universe and how to prove no shortcuts were taken.\u003c/p\u003e","blueskyPost":"DOOM now runs on pure regex. A 96.6 MB string, 544 replacement rules, and 180 seconds per frame. The virtual CPU is called RVM-1.","twitterPost":"DOOM on regex: 96.6 MB string, 544 replacement rules, 180 seconds per frame. Programmer Artem Litkin built a virtual CPU from find-and-replace.","threadsPost":null,"newsletterBlurb":"Programmer Artem Litkin released DOOM on regex, running the classic FPS through a virtual CPU built entirely from regular expression replacements. A 96.6 MB string holds the whole machine, and rendering one frame takes about 180 seconds.","attributionJson":"[{\"source\":\"GIGAZINE\",\"url\":\"https://gigazine.net/news/20260729-doom-on-regex/\",\"title\":\"Successfully Running 'DOOM' Using Only Regular Expressions, Taking About 180 Seconds to Render One Frame\"}]","lintFlagsJson":null,"lintHits":0,"costUsd":0,"inputTokens":4654,"outputTokens":565,"status":"published","repairAttempts":0,"nextRepairAt":null,"factsAttemptedAt":1786258913,"createdAt":"2026-08-09T06:54:44.000Z","publishedAt":"2026-08-09T06:56:44.000Z","updatedAt":"2026-08-09T06:54:44.000Z"},"cluster":{"id":"c_cc91cbd88eec238a723844fc","canonicalTitle":"正規表現だけで「DOOM」を動かすことに成功、1フレームの描画に約180秒","representativeArticleId":"a_827d8551cd8958fc79c2ffe6","sourceCount":1,"writtenSourceCount":1,"writeAttempts":0,"isSolo":true,"entitiesJson":"{\"anime_titles\":[],\"manga_titles\":[],\"work_titles\":[\"DOOM\"],\"studios\":[],\"people\":[\"アーテム・リトキン\"],\"type\":\"news\",\"domain\":\"other\",\"is_roundup\":false}","contentType":"news","status":"published","firstSeenAt":"2026-07-29T10:00:00.000Z","lastSeenAt":"2026-07-29T10:00:00.000Z","updatedAt":"2026-08-09T06:56:45.000Z"},"attribution":[{"source":"GIGAZINE","url":"https://gigazine.net/news/20260729-doom-on-regex/","title":"正規表現だけで「DOOM」を動かすことに成功、1フレームの描画に約180秒"}],"entities":{"anime_titles":[],"manga_titles":[],"work_titles":["DOOM"],"studios":[],"people":["アーテム・リトキン"],"type":"news","domain":"other","is_roundup":false},"keyFacts":null}
