Tag is-blog

57 bookmarks have this tag.

Blog posts.

bun.report is Bun's new crash reporter

bun.sh/blog/bun-report-is-buns-new-crash-reporter

How we built an anonymous Zig/C++ crash reporter that doesn't require debug symbols to be shipped with the application.

Pretty fun and showcases some Zig comtime stuff.

about-langs,about-tools,is-blog,to-show

The little ssh that (sometimes) couldn't

mina.naguib.ca/blog/2012/10/22/the-little-ssh-that-sometimes-couldnt.html

A fascinating tale about network problems.

about-networking,is-blog,to-show

Learning Async Rust With Entirely Too Many Web Servers

ibraheem.ca/posts/too-many-web-servers

A nice explanation of async that’s not about “threads slow”, but rather about how async as an abstraction emerges from sensible design decisions.

about-rust,is-blog,to-show

A universal lowering strategy for control effects in Rust

www.abubalay.com/blog/2024/01/14/rust-effect-lowering

The Rust language has incrementally grown a set of patterns to support control-flow effects including error handling, iteration, and asynchronous I/O. In The registers of Rust, boats lays out four aspects of this pattern shared by Rust’s three effects. Today these effects are typically used in isolation, or at most combined in bespoke ways, but the Rust project has been working on ways to integrate them more deeply with each other, such as async gen blocks.

The theory of algebraic effects and handlers has explored this design space and offers answers to many of the questions that the Rust project has encountered during this work. This post will relate the patterns employed by Rust to the terminology and semantics of effects, to help build a shared vocabulary and understanding of the implications of combining multiple effects.

about-compilers,about-rust,is-blog,to-show

Compromising a Linux desktop using... 6502 processor opcodes on the NES?!

scarybeastsecurity.blogspot.com/2016/11/0day-exploit-compromising-linux-desktop.html

gstreamer-plugins-bad includes a NES 6502 emulator, which was vulnerable to RCE.

about-security,is-blog,to-show

features are faults

flak.tedunangst.com/post/features-are-faults

Review of many different software vulnerabilities caused by obscure undertested (mis-)features.

A modern web browser is the software equivalent of Gabriel’s Horn. Finite volume, but infinite attack surface.

about-security,is-blog,to-show

Speculation in JavaScriptCore

www.webkit.org/blog/10308/speculation-in-javascriptcore

This post is all about speculative compilation, or just speculation for short, in the context of the JavaScriptCore virtual machine.

about-compilers,about-low-level,is-blog,to-show

So you want custom allocator support in your C library

nullprogram.com/blog/2023/12/17

Some thoughts on custom allocator interfaces with nice examples.

about-low-level,is-blog,to-archive,to-show

Performance of WebAssembly (WASM) runtimes in 2023

00f.net/2023/01/04/webassembly-benchmark-2023

Comparison between different runtimes and with native code.

about-compilers,about-tools,is-blog,to-archive,to-show

The Generic Dilemma

research.swtch.com/generic

The generic dilemma is this: do you want slow programmers, slow compilers and bloated binaries, or slow execution times?

No generics / monomorphization / dynamic dispatch

about-compilers,about-langs,is-blog,to-show

Pinning all system calls in OpenBSD

marc.info/?l=openbsd-tech&m=170205367232026&w=2

How OpenBSD prohibited all syscalls from unknown locations.

about-low-level,about-security,is-blog,to-show

Software Transactional Memory: Clojure vs. Haskell

leftfold.tech/posts/pie-a-la-mode/#fnref-2

A nice overview of STM primitives.

about-programming,is-blog,to-read

Execution in the Kingdom of Nouns

steve-yegge.blogspot.com/2006/03/execution-in-kingdom-of-nouns.html

About why free functions are important. I find verb/noun framework from this article quite useful.

about-langs,is-blog,to-show

Designing a SIMD Algorithm from Scratch

mcyoung.xyz/2023/11/27/simd-base64/#fnref:pad-with-A

A nice post about SIMD algorithms using Rust’s portable SIMD as an example.

about-low-level,is-blog,to-read

Friends don't let friends make certain types of data visualization

github.com/cxli233/FriendsDontLetFriends

This is an opinionated essay about good and bad practices in data visualization. Examples and explanations are below.

about-humans,about-math,about-tools,is-blog,to-read,to-show

Linus Torvalds about spinlocks and locking in general

www.realworldtech.com/forum/?threadid=189711&curpostid=189723
about-low-level,for-memequeue,is-blog,to-read

Mutexes Are Faster Than Spinlocks

matklad.github.io/2020/01/04/mutexes-are-faster-than-spinlocks.html

Microbenchmark for futexes + spinlocks and some useful links at the bottom.

about-low-level,about-rust,for-memequeue,is-blog,to-show

Spinlocks Considered Harmful

matklad.github.io/2020/01/02/spinlocks-considered-harmful.html

Because spin locks are so simple and fast, it seems to be a good idea to use them for short-lived critical sections. For example, if you only need to increment a couple of integers, should you really bother with complicated syscalls? In the worst case, the other thread will spin just for a couple of iterations…
Unfortunately, this logic is flawed! A thread can be preempted at any time, including during a short critical section. If it is preempted, that means that all other threads will need to spin until the original thread gets its share of CPU again. And, because a spinning thread looks like a good, busy thread to the OS, the other threads will spin until they exhaust their quants, preventing the unlucky thread from getting back on the processor!

about-low-level,about-rust,is-blog,to-show

Lambda calculus - Combinatory Logic

theory.stanford.edu/~blynn/lambda/cl.html

Variables are the trickiest part of lambda calculus. And naming is the trickiest part of variables: the most complex code in our lambda evaluator is the part that renames variables to perform capture-avoiding substitutions.
Names are artificial tedious tags whose sole purpose is to aid human comprehension. Can we get rid of them? There ought to be a way to study computation without naming names.

about-math,about-programming,is-blog,is-interactive,to-read

Surprisingly Slow

gregoryszorc.com/blog/2021/04/06/surprisingly-slow

This is the closing-file-handles-on-Windows post.

I'm titling this post Surprisingly Slow because the slowness was either surprising to me or the sub-optimal practices leading to slowness are prevalent enough that I think many programmers would be surprised by their existence.

about-programming,about-rust,is-blog,to-show

netaddr.IP: a new IP address type for Go

tailscale.com/blog/netaddr-new-ip-type-for-go

The Go standard library’s net.IP type is problematic for a number of reasons. We wrote a new one.

This post explores some problems with Go’s “simplicity by design”: introducing a better IP type that’s also interoperable with the language proves to be a non-trivial challenge.

about-langs,about-networking,is-blog,to-show

Measuring Mutexes, Spinlocks and how Bad the Linux Scheduler Really is

probablydance.com/2019/12/30/measuring-mutexes-spinlocks-and-how-bad-the-linux-scheduler-really-is

This blog post is one of those things that just blew up. From a tiny observation at work about odd behaviors of spinlocks I spent months trying to find good benchmarks, (still not entirely successful) writing my own spinlocks, mutexes and condition variables and even contributing a patch to the Linux kernel. The main thing I’ll try to answer is to give some more informed guidance on the endless discussion of mutex vs spinlock. Besides that I found that most mutex implementations are really good, that most spinlock implementations are pretty bad, and that the Linux scheduler is OK but far from ideal. The most popular replacement, the MuQSS scheduler has other problems instead. (the Windows scheduler is pretty good though)

about-low-level,for-memequeue,is-blog

how I think when I think about programming

www.alicemaz.com/writing/program.html

a whirlwind tour through the guts of the system

about-programming,is-blog,to-read

Let's Build a Cargo Compatible Build Tool

ductile.systems/freight-part-1

Tutorial about building a self-hosting cargo-compatible build tool. I have many problems with cargo and was interested in nixifying our job builds for eternity, so maybe there’s something useful there.

about-rust,for-job,is-blog,to-read

Bootstrapping with FORTH

compilercrim.es/bootstrap

What if all software suddenly disappeared? What's the minimum you'd need to bootstrap a practical system? I decided to start with a one sector (512-byte) seed and find out how far I can get.

about-compilers,about-low-level,is-blog,to-read

Modeling graphs in Rust using vector indices

smallcultfollowing.com/babysteps/blog/2015/04/06/modeling-graphs-in-rust-using-vector-indices

Niko’s post about using vectors (≈ arenas) instead of reference counters to model graphs. Explains how it relates to ownership and borrowing.

See also: Handles are the better pointers.

about-rust,is-blog,to-show

Handles are the better pointers

floooh.github.io/2018/06/17/handles-vs-pointers.html

A blog post explaining the “single owner of data, everyone has indices instead of pointers” model. Not actually about Rust per se, just happens to be really useful for Rust.

See also: Modeling graphs in Rust using vector indices.

about-programming,about-rust,is-blog,to-show

No Sane Compiler Would Optimize Atomics

www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/n4455.html

The paper’s claim:

False.

Compilers do optimize atomics, memory accesses around atomics, and utilize architecture-specific knowledge. This paper illustrates a few such optimizations, and discusses their implications.

Interestingly, none of the optimizations proposed in the paper actually work on GCC or Clang.

about-compilers,about-low-level,for-memequeue,is-blog,to-archive

The Magic Ring Buffer

fgiesen.wordpress.com/2012/07/21/the-magic-ring-buffer

A first (as far as I know) description of ringbuffer based on two mmaps. I hope to make a better one sometime, but for now this’ll the best explanation I have.

about-low-level,for-memequeue,is-blog,to-show

Implementing truly safe semaphores in rust

neosmart.net/blog/implementing-truly-safe-semaphores-in-rust
about-rust,is-blog,to-read

tips for systemd services management and hardening in NixOS

git.selfprivacy.org/alexoundos/articles/src/branch/master/systemd-hardening-in-NixOS/article.md

When it comes to security, we care about limiting access of each entity of a system to as few other entities as possible. Network input, executables and users must be able to reach only those resources, which are necessary to perform the defined server tasks. Principle of least priviledge.

Generally, it's better to implement as many layers of security as possible. Although, there is no way to make a server 100% bullet proof - it's a huge endless topic, this article covers some feasible essential systemd tunables that give us a layer of protection.

about-nix,is-blog,to-read

Laurence Tratt: Why Aren't Programming Language Specifications Comprehensive?

tratt.net/laurie/blog/2023/why_arent_programming_language_specifications_comprehensive.html
about-compilers,is-blog,to-read

Laurence Tratt: How Hard is it to Adapt a Memory Allocator to CHERI?

tratt.net/laurie/blog/2023/how_hard_is_it_to_adapt_a_memory_allocator_to_cheri.html
about-compilers,is-blog,to-read

Cranelift's Instruction Selector DSL, ISLE: Term-Rewriting Made Practical

cfallin.org/blog/2023/01/20/cranelift-isle
about-compilers,is-blog,to-read

A New Backend for Cranelift

cfallin.org/blog/2020/09/18/cranelift-isel-1
about-compilers,is-blog,to-read

Codebase as Database: Turning the IDE Inside Out with Datalog

petevilter.me/post/datalog-typechecking

Introspectable and extensible IDEs with logic programming

about-compilers,is-blog,is-interactive,to-read

A non-overlapping type level contains operation for heterogeneous lists

blog.weiznich.de/blog/eurorust-non-overlapping-contains-for-hlists

In this blog post we explore how to write a type level contains operation for HList inspired type lists without running into overlapping trait implementations

about-rust,is-blog,to-read

Pointers Are Complicated, or: What's in a Byte?

www.ralfj.de/blog/2018/07/24/pointers-and-bytes.html

Explanation of provenance, uninitialized memory and stuff like that. Useful as an entry point into realization that we don’t live in PDP-11 world anymore.

about-compilers,is-blog,to-show

Text Rendering Hates You

faultlore.com/blah/text-hates-you
about-text,is-blog,to-show

Breaking Our Latin-1 Assumptions

manishearth.github.io/blog/2017/01/15/breaking-our-latin-1-assumptions
about-text,is-blog,to-show

Let's Stop Ascribing Meaning to Code Points

manishearth.github.io/blog/2017/01/14/stop-ascribing-meaning-to-unicode-code-points
about-text,is-blog,to-show

It’s not wrong that "🤦🏼‍♂️".length == 7

hsivonen.fi/string-length
about-text,is-blog,to-show

Myths about /dev/urandom

www.2uo.de/myths-about-urandom

tl;dr: /dev/random is obsolete and /dev/urandom is strictly better except in early boot.

about-security,is-blog,to-show

Quantum computing for the very curious

quantum.country/qcvc

Presented in an experimental mnemonic medium that makes it almost effortless to remember what you read

is-blog,to-read

Index 1,600,000,000 Keys with Automata and Rust

blog.burntsushi.net/transducers

It turns out that finite state machines are useful for things other than expressing computation. Finite state machines can also be used to compactly represent ordered sets or maps of strings that can be searched very quickly.

about-rust,is-blog,to-read

What every programmer should know about memory

lwn.net/Articles/250967
about-low-level,is-blog,to-read

An Interactive Introduction to Fourier Transforms

www.jezzamon.com/fourier/index.html

Fourier transforms are a tool used in a whole bunch of different things. This is a explanation of what a Fourier transform does, and some different ways it can be useful.

about-math,is-blog,is-interactive

Color: From Hexcodes to Eyeballs

jamie-wong.com/post/color

If you're curious about rainbows, colorimetry, gamma encoding, and experiments run in the late 1920s, then this is the post for you!

is-blog,to-read

What I learned from making a DNS client in Rust

blog.adamchalmers.com/making-a-dns-client

A lot about sockets, syscalls and bits

about-networking,about-rust,is-blog,to-read

Introducing Riptide: WebKit’s Retreating Wavefront Concurrent Garbage Collector

webkit.org/blog/7122/introducing-riptide-webkits-retreating-wavefront-concurrent-garbage-collector

The new Riptide garbage collector in WebKit leads to a five-fold improvement in latency in the JetStream/splay-latency test.

about-compilers,is-blog,to-read

Oh-Auth - Abusing OAuth to take over millions of accounts

salt.security/blog/oh-auth-abusing-oauth-to-take-over-millions-of-accounts

It’s extremely important to make sure your OAuth implementation is secure. The fix is just one line of code away. We sincerely hope the information shared in our blog post series will help prevent major online breaches and help web service owners better protect their customers and users.

about-security,is-blog,to-read

Search-based compiler code generation

jamey.thesharps.us/2017/06/19/search-based-compiler-code-generation
about-compilers,is-blog,to-read

Introducing the B3 JIT Compiler

webkit.org/blog/5852/introducing-the-b3-jit-compiler

WebKit's FTL JIT now uses a new backend on OS X — the Bare Bones Backend, or B3 for short, replaces LLVM as the low-level optimizer.

about-compilers,is-blog,to-read

Introducing the WebKit FTL JIT

webkit.org/blog/3362/introducing-the-webkit-ftl-jit

Designed to bring aggressive C-like optimizations to the largest variety of JavaScript programs.

about-compilers,is-blog,to-read

A close encounter with false sharing

morestina.net/blog/1976/a-close-encounter-with-false-sharing

An example of false sharing in real-ish workload.

about-low-level,about-rust,for-job,is-blog,to-show

C++ exception — zero-cost exception handling

blog.the-pans.com/cpp-exception-1

Series of posts about how make C++ exceptions fast.

about-c++,is-blog,to-read

Building Segmented Logs in Rust: From Theory to Production!

arindas.github.io/blog/segmented-log-rust

Explore a Rust implementation of the persistence mechanism behind message-queues and write-ahead-logs in databases. Embark on a journey from the theoretical underpinnings to a production grade implementation of the segmented-log data structure.

about-database,about-rust,is-blog,to-read