<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Gideon Towolawi </title>
    <description>The latest articles on DEV Community by Gideon Towolawi  (@ayndlr).</description>
    <link>https://dev.to/ayndlr</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3936747%2Fcd705d82-db87-484f-ace1-091badc66800.png</url>
      <title>DEV Community: Gideon Towolawi </title>
      <link>https://dev.to/ayndlr</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ayndlr"/>
    <language>en</language>
    <item>
      <title>I'm Building a Multi-Target Compiler Backend from Scratch — No LLVM, No Crutches</title>
      <dc:creator>Gideon Towolawi </dc:creator>
      <pubDate>Sun, 17 May 2026 20:49:04 +0000</pubDate>
      <link>https://dev.to/ayndlr/im-building-a-multi-target-compiler-backend-from-scratch-no-llvm-no-crutches-57be</link>
      <guid>https://dev.to/ayndlr/im-building-a-multi-target-compiler-backend-from-scratch-no-llvm-no-crutches-57be</guid>
      <description>&lt;p&gt;I'm Gideon. 18. Three years of writing C++ from the ground up — ray tracers, video codecs, and now a compiler. No frameworks. No LLVM. Just me, the hardware manuals, and a lot of wrong turns.&lt;/p&gt;

&lt;p&gt;This post starts a series where I document the build in real time. I'm currently in the parser stage. By the end, I want a compiler that emits x86-64 and SPIR-V from a C++-like language, with SIMD vectorization and security-hardened codegen baked in.&lt;/p&gt;

&lt;p&gt;What I'm Actually Building&lt;/p&gt;

&lt;p&gt;Not a programming language. A compiler backend toolkit — the part that turns intermediate representation into fast machine code across multiple targets.&lt;/p&gt;

&lt;p&gt;The pipeline:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Source → Parser → AST → SSMOL (HIR) → MREL (LIR) → x86-64 / SPIR-V / ARM64 / RISC-V / WASM
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;MREL is my target-agnostic low-level IR. It knows about virtual registers, stack slots, and machine operations — but not physical register names. The backend handles that per-target.&lt;/p&gt;

&lt;p&gt;Why Not Just Use LLVM?&lt;/p&gt;

&lt;p&gt;LLVM is 4 million lines of code. It solves everyone's problem and no one's perfectly. I need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Fine-grained control over SIMD width selection per target&lt;/li&gt;
&lt;li&gt;Constant-time crypto primitive emission with secret register annotations&lt;/li&gt;
&lt;li&gt;Security obfuscation passes (control flow flattening, opaque predicates)&lt;/li&gt;
&lt;li&gt;A codebase I fully understand and can license&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Building from scratch is slower. But I own every decision.&lt;/p&gt;

&lt;p&gt;Where I Am Right Now&lt;/p&gt;

&lt;p&gt;Parser stage. Hand-written recursive descent. C++-like syntax with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Functions, structs, basic types&lt;/li&gt;
&lt;li&gt;Ownership semantics (borrowed from my Rust phase, simplified)&lt;/li&gt;
&lt;li&gt;Explicit SIMD types (&lt;code&gt;v128&lt;/code&gt;, &lt;code&gt;v256&lt;/code&gt;, &lt;code&gt;v512&lt;/code&gt;)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The parser emits an AST that gets lowered to SSMOL — my high-level IR that knows about types, ownership, and semantics.&lt;/p&gt;

&lt;p&gt;What's Next&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;SSMOL → MREL lowering (types to sizes, structs to offsets, control flow to basic blocks)&lt;/li&gt;
&lt;li&gt;MREL → x86-64 backend (register allocation, instruction selection, ELF emission)&lt;/li&gt;
&lt;li&gt;One working program: compile, link, run &lt;code&gt;main()&lt;/code&gt; that returns 42&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Then SPIR-V compute kernels. Then the rest.&lt;/p&gt;

&lt;p&gt;What I'll Write About&lt;/p&gt;

&lt;p&gt;Each stage, when I hit it. The problems that took me three days to solve. The specs I wrote to keep myself honest. The wrong assumptions that cost me a week.&lt;/p&gt;

&lt;p&gt;Not polished tutorials. Build logs from someone actually building.&lt;/p&gt;

&lt;p&gt;Follow This Series If&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You work in systems, compilers, or graphics&lt;/li&gt;
&lt;li&gt;You're curious what "building from scratch" actually looks like&lt;/li&gt;
&lt;li&gt;You want to see if I crash or ship&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;My Specs (For the Curious)&lt;/p&gt;

&lt;p&gt;I write technical specifications to keep the design coherent across months of work. The MREL backend spec covers x86-64, ARM64, RISC-V, SPIR-V, and WebAssembly with calling conventions, opcode tables, and security passes. Link in bio.&lt;/p&gt;

&lt;p&gt;GitHub: (&lt;a href="https://github.com/ayndlr" rel="noopener noreferrer"&gt;https://github.com/ayndlr&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;Closing&lt;/p&gt;

&lt;p&gt;This is post 1 of however many it takes. Next post: parsing expressions with operator precedence and why I gave up on Pratt parsing.&lt;/p&gt;

&lt;p&gt;Follow for the crash or the ship. Either way, it's real.&lt;/p&gt;

</description>
      <category>compilers</category>
      <category>systems</category>
      <category>backend</category>
      <category>simd</category>
    </item>
  </channel>
</rss>
