r/programming • • 8h ago

CS Fundamentals are still important

Thumbnail faidi.tech
210 Upvotes

r/programming • • 3h ago

kav: a purely functional systems language with a small & fast compiler implemented in C

Thumbnail srcdump.net
12 Upvotes

i’ve been working on this for a while and i think im ready to show it off a bit :)

i started working on this project after getting excited by functional programming and type systems after learning some haskell, followed by some ATS. kav takes ideas from both but it’s also quite different. the language makes uses of linear and dependent types, compiled with functional purity, which is both safe and fun to program in. however, i won’t go into too much detail about the language design but more about the compiler implementation.

the compiler is fairly compact (about 6000 lines, although liens aren’t everything it gives you a ballpark idea of the scale) and implemented in portable C11, using bidirectional type checking and a small fourier-motzkin solver for proving index constraints. it uses QBE as the backend, which is also fairly compact and implemented in C. this makes the compiler pretty fast, and easy to bootstrap even from one of the more primitive C compilers.

the lexer is generated using re2c, but most of the actual re2c regex is generated using an X-macro of the list of tokens, which makes it very easy to add new keywords to the language.

the languages runtime is also tiny and not dependent on libc or a C compiler, which means the binaries are tiny and linking is quick. it uses a small bump allocator with free-lists for allocation. this is written in C, and ten compiled to qbe using the cproc C compiler. then that generated qbe code is linked into every binary as the runtime allocator.

the compiler is very fast, it takes about 30ms on my machine to compile a fairly substantial amount of kav code (most of that is qbe/assembler/linker which are out of my control, the frontend only takes a few ms)

there is also a standard library, which is not finished, but has enough to write some fun programs (i’m working on a posix make implementation)

i’m pretty excited about this and i’d love more people to get involved or just to try it out.


r/programming • • 2h ago

Pascal Lexical Structure Diagrams

Thumbnail getlazarus.org
8 Upvotes

r/programming • • 1d ago

Google rushed to replace its P-256 signing key in Chrome 11 days before the NSA's AI cryptography warning

Thumbnail xda-developers.com
1.6k Upvotes

r/programming • • 5h ago

How Userspace CUDA Programs Communicate with NVIDIA GPUs on Linux

Thumbnail shubham0204.github.io
3 Upvotes

To check how a simple vector addition CUDA program communicates with the kernel, I started by using the strace utility and found nearly all of them to be ioctl system calls. Being new to ioctl, I dived deeper and ended up learning more about the Nvidia Linux kernel modules and how they communicate with the GPU device via PCIe.

I have included the details in my latest blog 'How Userspace CUDA Programs Communicate with NVIDIA GPUs on Linux'. Do read it and let me know your thoughts!


r/programming • • 13h ago

C++ Dev Reviews Portal Source Code

Thumbnail youtu.be
3 Upvotes

r/programming • • 1d ago

Precision in type system design (or the Option type as an anti-pattern)

Thumbnail dashbit.co
47 Upvotes

r/programming • • 1d ago

Let's Understand Redis Source Code From Scratch

Thumbnail sushantdhiman.dev
40 Upvotes

r/programming • • 1d ago

ASCII Validation from 2.5 to 114 GB/s with SIMD

Thumbnail modulovalue.com
165 Upvotes

r/programming • • 23h ago

Embedded Rust from Scratch

Thumbnail rodrigodd.github.io
4 Upvotes

I recently got a small microcontroller, and I thought it was a good opportunity to learn more about how ARM-based microcontrollers work under the hood and how Rust works on embedded devices. In this blog post, I go over how to implement a very basic example application in Rust from scratch, covering everything from runtime initialization to how to build memory-safe abstractions for peripherals.

Hopefully, preexisting knowledge of Rust or embedded development is not required to follow the post.


r/programming • • 2d ago

Announcing TypeScript 7.1 RC

Thumbnail devblogs.microsoft.com
183 Upvotes

r/programming • • 1d ago

Binary Lifting

Thumbnail emi-h.com
2 Upvotes

r/programming • • 2d ago

Wax: A User-Friendly Syntax for WebAssembly

Thumbnail tarides.com
64 Upvotes

r/programming • • 2d ago

Team Topologies in Enterprise IT: Navigating Cognitive Load, Platform Design, and Team Autonomy

Thumbnail gerlacdt.github.io
27 Upvotes

r/programming • • 1d ago

Tristan Mc Leay - Mutation Testing With Sydtest

Thumbnail youtube.com
6 Upvotes

r/programming • • 2d ago

How a tiny HTTP response preview ended up buffering a 64 MB download

Thumbnail octri.dev
65 Upvotes

r/programming • • 3d ago

How Module Lattice Cryptography Works

Thumbnail phase.dev
147 Upvotes

r/programming • • 2d ago

Heterogeneous collections using compact handles

Thumbnail nukethebees.com
33 Upvotes

r/programming • • 2d ago

SNIA SDC2026 - SMB3 POSIX Extensions: From Plumbing to Flowing

Thumbnail youtube.com
13 Upvotes

r/programming • • 2d ago

A Vision for Pascal 2030 at EKON

Thumbnail blogs.remobjects.com
13 Upvotes

r/programming • • 1d ago

In 1936 a "computer" was a person with a pencil. Ten years later it was a 30-ton machine. I made a 10-minute video on how that happened.

Thumbnail youtu.be
0 Upvotes

I've been making a short video on the decade between Turing's 1936 paper and ENIAC, and the part that surprised me most was how slippery "first computer" is:

- Zuse's Z3 (1941) was program-controlled, but built from relays.

- Colossus (working by the end of 1943) was electronic, but built for one job.

- ENIAC (1945) was electronic and general purpose, but had no stored program. Programming it meant plugging cables by hand.

- The Manchester Baby (21 June 1948) was the first to run a program held in electronic memory.

So the answer depends on which of those properties you count.

The video also walks through a tiny Turing machine that adds one to a number, and the six women who programmed ENIAC. I tried to keep it accurate and listed my sources (Turing's paper, Penn, the Computer History Museum, IEEE Spectrum) in the description.

Full disclosure: this is my own video. I'd really like corrections from people who know this period better than I do, especially on the stored-program credit, which I know historians still argue about.


r/programming • • 3d ago

What to Make of the NSA Advisory

Thumbnail words.filippo.io
202 Upvotes

r/programming • • 2d ago

Java Virtual Threads vs Elixir: Comparing Memory, CPU, Process Termination

Thumbnail youtube.com
6 Upvotes

r/programming • • 3d ago

Our Journey Migrating to AWS IMDSv2

Thumbnail slack.engineering
13 Upvotes