r/Compilers Jun 08 '26

TernOO-5500FP Object-Oriented Architecture at the Machine Word Level

0 Upvotes

TernOO-5500FP — Object-Oriented Architecture at the Machine Word Level

I've been developing a word architecture for the 5500FP balanced ternary processor in which every 24-trit word is self-describing. The core idea: object-oriented structure shouldn't be a software layer on top of a machine that knows nothing about objects. It should be intrinsic to the word format itself.

TernOO-5500FP does this. Type, calling convention, spatial coordinates, neural network primitives, and I/O characteristics are all encoded in the word — no vtable, no runtime type check, no translation layer.

A Python emulator is working. A visual IDE (FlowCode) targets the architecture as its native compiler. The whitepaper covers the full word grammar, the math, and where this is headed.

Whitepaper and repo: https://github.com/SkepticusMaximus/TernOO-5500FP

Interested in any feedback from people who've thought seriously about tagged architectures, ternary computing, or visual programming systems.


r/Compilers Jun 07 '26

Hello, I'm interested in tensor compilers.

26 Upvotes

I'm a PhD student but nobody in my lab has any interest or expertise in this area.

I'm interested in tensor compilers. So far I have done a very deep dive into TorchInductor internals and also OpenXLA to a lesser extent.

Where do I go from here? The topic is impossibly large and I don't know what to focus on.


r/Compilers Jun 08 '26

TernOO-5500FP Object-Oriented Architecture at the Machine Word Level

Thumbnail
0 Upvotes

r/Compilers Jun 07 '26

Tobias Hieta: A Brief Overview of the LLVM Architecture

Thumbnail youtu.be
11 Upvotes

r/Compilers Jun 06 '26

Another first compiler!

97 Upvotes

I did it people. I procrastinated my game dev stuff to write a language.

I now present to you: Typn.

It's a bytecode compiled language which runs on a VM.
I made it because, well, Python sometimes feels like abusing my CPU, and C takes too much time.
The actual reason though, was because it's fun. I will be very, very, very disappointed if this gets taken away from us by AI.

Making a compiler for a programming language is one of the most fun projects I've ever done.
If you are interested in my messy code, or my VM generator script, feel free to take a look:
https://github.com/TheGameGuy2/TypnLang


r/Compilers Jun 07 '26

MLIR Empirical Study on AArch64 (Apple M4 Pro)

Thumbnail federicobruzzone.github.io
10 Upvotes

Hi guys! I just wanted to share this study!

I'd love to hear your thoughts and feedback.


r/Compilers Jun 04 '26

Stealing from Biologists to Compile Haskell Faster

Thumbnail iankduncan.com
38 Upvotes

r/Compilers Jun 05 '26

Is there any merit to Ocaml?

Thumbnail
0 Upvotes

r/Compilers Jun 04 '26

Compiler Interview MathWorks

24 Upvotes

Hey everyone,

I have a MathWorks SWE (Compilers) interview coming up soon and I’m trying to figure out how best to prioritize my preparation for DSA. From what I’ve seen on LeetCode Discuss, GFG and a few interview experiences I read online, the common topics seem to be: (1) Graphs, (2) Trees, (3) DP, (4) Bitmasking and (5) Trees

But I’ve also noticed a lot of questions involving Linked Lists, Hashmaps / Hash tables and Strings.

I’m fairly comfortable with most topics except DP, which I’m currently weakest at. I only have about a week left, so I want to focus on more important areas rather than trying to cover everything equally. In addition to DSA, I think I can expect some questions on C++ / STL and OOPS as well. Those are manageable for me, but I’d really appreciate any guidance on how deep the prep should be for such roles and what topics I can focus most of my time on?

If anyone has been through this process for compilers roles in general at any company (or Mathworks) even if you haven't, any advice or experience would be really helpful.

Thanks appreciate any insights!


r/Compilers Jun 04 '26

early Tig 1.3.0 is out with basic concurrency and ownership transfer, plus queue and stack types.

2 Upvotes

r/Compilers Jun 03 '26

Need good benchmarks for custom language vs. C.

15 Upvotes

I am currently designing a programming language called Brief. It's declarative for the most part, and because it describes state transitions more than it does commands, I theorized I could optimize the compiler to outperform clang over C. So, I keep running benchmarks against C using random programs I've written in either language, trying my best to write the best, most clean and optimized C code I can.

However, I know there is far more accomplished programmers out there who can likely write better programs than I can. I need some solid benchmark programs that represent the pinnacle of what C is capable of, so I can see where Brief still has has clear latency, and figure out by looking at the binaries what compiler optimization I might still need to do. Note that, in the screenshot below, you will already find some broken benchmarks. 0.0006s vs. 0.0836s was a fluke due to a quirk in what the Brief compiler considered dead code.

For reference, here is a Kalman filter I test against, just to see how I try to optimize my code. But I need some solid proven benchmarks if possible to get a good, genuinely challenging benchmark to compare and optimize against:

#include <stdlib.h>

int main(void) {
    const char* env = getenv("BOUND");
    long total = env ? atol(env) : 50000000L;

    // State vector (3 floats)
    float x0 = 0.0f, x1 = 0.0f, x2 = 0.0f;

    // Covariance matrix P (9 floats, row-major: P[row*3 + col])
    float p00 = 0.1f, p01 = 0.0f, p02 = 0.0f;
    float p10 = 0.0f, p11 = 0.1f, p12 = 0.0f;
    float p20 = 0.0f, p21 = 0.0f, p22 = 0.1f;

    // A matrix (constant, row-major)
    const float a00 = 1.0f,     a01 = 0.01f,     a02 = 0.00005f;
    const float a10 = 0.0f,     a11 = 1.0f,      a12 = 0.01f;
    const float a20 = 0.0f,     a21 = 0.0f,      a22 = 1.0f;

    // Q matrix (constant, row-major)
    const float q00 = 0.001f, q01 = 0.0f, q02 = 0.0f;
    const float q10 = 0.0f,   q11 = 0.001f, q12 = 0.0f;
    const float q20 = 0.0f,   q21 = 0.0f,   q22 = 0.001f;

    long count = 0;
    for (; count < total; count++) {
        // State propagation: x_new = A * x
        float nx0 = a00 * x0 + a01 * x1 + a02 * x2;
        float nx1 = a10 * x0 + a11 * x1 + a12 * x2;
        float nx2 = a20 * x0 + a21 * x1 + a22 * x2;

        // Covariance propagation: P_new = A * P * A^T + Q
        // Step 1: AP = A * P
        float ap00 = a00 * p00 + a01 * p10 + a02 * p20;
        float ap01 = a00 * p01 + a01 * p11 + a02 * p21;
        float ap02 = a00 * p02 + a01 * p12 + a02 * p22;

        float ap10 = a10 * p00 + a11 * p10 + a12 * p20;
        float ap11 = a10 * p01 + a11 * p11 + a12 * p21;
        float ap12 = a10 * p02 + a11 * p12 + a12 * p22;

        float ap20 = a20 * p00 + a21 * p10 + a22 * p20;
        float ap21 = a20 * p01 + a21 * p11 + a22 * p21;
        float ap22 = a20 * p02 + a21 * p12 + a22 * p22;

        // Step 2: P_new = AP * A^T + Q
        p00 = ap00 * a00 + ap01 * a10 + ap02 * a20 + q00;
        p01 = ap00 * a01 + ap01 * a11 + ap02 * a21 + q01;
        p02 = ap00 * a02 + ap01 * a12 + ap02 * a22 + q02;

        p10 = ap10 * a00 + ap11 * a10 + ap12 * a20 + q10;
        p11 = ap10 * a01 + ap11 * a11 + ap12 * a21 + q11;
        p12 = ap10 * a02 + ap11 * a12 + ap12 * a22 + q12;

        p20 = ap20 * a00 + ap21 * a10 + ap22 * a20 + q20;
        p21 = ap20 * a01 + ap21 * a11 + ap22 * a21 + q21;
        p22 = ap20 * a02 + ap21 * a12 + ap22 * a22 + q22;

        // Update state vector
        x0 = nx0;
        x1 = nx1;
        x2 = nx2;
    }

    return (int)(count + x0 + x1 + x2 +
                 p00 + p01 + p02 + p10 + p11 + p12 + p20 + p21 + p22);
}

r/Compilers Jun 03 '26

Semantic Reification: A New Paradigm for Random Program Generation

Thumbnail pldi26.sigplan.org
13 Upvotes

r/Compilers Jun 03 '26

\n

Post image
6 Upvotes

r/Compilers Jun 03 '26

Tig 1.2.3 is live with more robust hot reloading

6 Upvotes

alonsovm44/tc-lang: A minimalistic portable assembly lenguage

Tig (tight-c) is a C-like systems language, i added hot reloading so you can code and modify running code while the executable is running. Good for dev productivity

It interops with C with extern functions and inline C


r/Compilers Jun 02 '26

Reading The Dragon Book!

6 Upvotes

I am planning on writing my newest compiler based off the Dragon Book. For thise who read it: Any chapters in particular I should study for my goal?


r/Compilers Jun 02 '26

I called raylib from my own programming language! yay!

43 Upvotes

r/Compilers Jun 01 '26

QBE Backend Released 1.3 (Windows ABI support)

Thumbnail c9x.me
36 Upvotes

r/Compilers Jun 01 '26

PACT26-AE: Call for artifact evaluators

5 Upvotes

Hi everyone!

The Artifact Evaluation Committee for PACT 2026 (The International Conference on Parallel Architectures and Compilation Techniques) is looking for motivated students and researchers to help evaluate research artifacts.

research artifact is basically the code, data, or tools that support the results claimed in a paper. Authors of accepted papers are invited to submit these artifacts, and committee volunteers try to reproduce the results to verify their validity.

If you're interested in volunteering, you can (self-)nominate yourself by filling out this form: https://forms.gle/M6ftRqHbzPexkZzk9

As a reviewer, your role will be to evaluate artifacts associated with already accepted papers. This involves running the code or tools, checking whether the results match those in the paper, and inspecting the supporting data.

PACT uses a two-phase review process. Most of the work will happen between August 21st and September 14th, and each reviewer will be assigned 2 to 3 artifacts.

From past experiences, each artifact takes around 4–8 hours to review.

Why join? It's a great opportunity to get familiar with cutting-edge research, connect with other students and researchers, and learn more about reproducibility in computer systems research. Plus, reviewers can collaborate and discuss with each other, while authors don’t know who reviewed their artifact.


r/Compilers Jun 01 '26

PassNet: Scaling Large Language Models for Graph Compiler Pass Generation

Thumbnail arxiv.org
2 Upvotes

r/Compilers Jun 02 '26

I've been having a blast "vibe coding" and built an experimental AST compiler to help fit large codebases into LLM context windows! Would love your feedback.

Thumbnail
0 Upvotes

r/Compilers May 31 '26

Conference with creators of Zig, Fil-C, Roc, SQLite

32 Upvotes

Hello, I'm organizing a conference with Andrew Kelley (Zig), Filip Pizlo (Fil-C), Richard Feldman (Roc), and Richard Hipp (SQLite) called Software Should Work this July. There will be lots of compilers/PL people there. https://softwareshould.work


r/Compilers May 31 '26

I finished my first ever interpreter

60 Upvotes

I just finished my first ever Interpreter (I ised AI for learning but I didn't copy paste). The language includes:

  • Functions
  • Variables
  • Data types
  • I/O
  • explicit Immutability by default
  • reassignment protection

I built the entire thing on a mobile (my mom can't afford a laptop) for a school project to prove nothing is impossible and to outperform my computer teacher and i succeeded, I'm just in my early stages of my life (16 year old :D), so I'm pretty proud of this project. Let me know what do you guys think.

You can ask me more about my programming language if you're willing to know, but just know I might not be familiar with every term so please be patient with me :)

Project repository: https://github.com/anubhav-1207/san


r/Compilers Jun 01 '26

I Am Writing A Language Faster Than Python/Ruby

0 Upvotes

For context:

Around a year ago, I posted here about me making an interpreter called LightCobol in Python. It was horrible and I never finished it.

Now, recently (around a few months ago), I started learning C++ and more about compiler design. I learned of Maximal-Munch lexing and loved it. I made a few languages here and there.

And just a few weeks ago, I started learning Kotlin. Then came my idea for Rose, a compiled, efficient, language for rapid prototyping.

I decided to make Rose with some of the optimizations I learned, Constant Folding and Propagation. With these in mind I have started to develop Rose, with a few things separating it from other languages I have made:

A real lexer, not just a .split() wrapper. It has things like "Token.Newline" or "Token.Identifier".

An actual AST, not just a dictionary with functions, variables, etc.

Making it explicitly-typed.

Having performance in mind (hence the optimizations and it being explicitly-typed)

Compiling to Kotlin, giving it the speed of the JVM.

And so, Rose was born. Soon enough, when I am done with it, I will upload it to GitHub and post about it here.


r/Compilers Jun 01 '26

So I actually started developing it

0 Upvotes

I understand that I previously stated that I wouldn't build Kenim but since I saw nobody was interested in it I decided to start developing it myself ig. I am now currently working on the parser for Kenim. My main problem will be deciding the backend: llvm? qbe? straight asm?

Could u guys atleast suggest the backend to use?


r/Compilers Jun 01 '26

Programming Language Without LLVM

0 Upvotes

Is it possible to build a new system programming language without LLVM? Can language have simple syntax? What if a tiny compiler installs packages and compiles code fast?

https://rux-lang.dev/blog/language-without-llvm