25 newsletters today.
Abandoned Futures
2026-07-23
In September 1969, Sikorsky Aircraft made a decision almost unheard of in the defense industry: they would build a high-speed attack helicopter entirely with company funds, no Army contract, no government money. The prototype flew nine months later. It was called the S-67 Blackhawk (unrelated to the later UH-60), and it embarrassed almost everything else in the sky.
The specs were absurd for 1970. On December 14, 1970, test pilots Kurt Cannon and Byron Graham pushed the S-67 to 216.84 knots (249.5 mph) over a 3-kilometer course — a world helicopter speed record. Nine days later they set the 15-25 km record at 220.9 mph. The aircraft used a five-bladed articulated rotor, retractable landing gear, small stub wings that offloaded the rotor at high speed (adding lift and mounting hardpoints), and speedbrakes on the wing trailing edges that let it decelerate hard enough to perform loops and rolls — a helicopter doing aerobatics at the Farnborough Air Show in 1971.
It also carried a serious weapons load: a chin turret with a 30mm cannon or 7.62mm minigun, plus up to 16 TOW missiles or 2.75-inch rocket pods on the stub wings. The cockpit was tandem, armored, and had a low-profile silhouette from the front. Sikorsky pitched it as the answer to the Lockheed AH-56 Cheyenne, which was already hemorrhaging money and years behind schedule.
The Army evaluated the S-67 in 1972 against the Bell 309 KingCobra. Neither won. The Army had already decided to start the Advanced Attack Helicopter (AAH) program from scratch — which eventually produced the AH-64 Apache in 1975. Sikorsky's completed, flying, world-record aircraft was rejected in favor of a paper competition that would take five more years.
Sikorsky kept flying it as a demonstrator. On September 1, 1974, at the Farnborough Air Show, chief test pilot Kurt Cannon attempted a low-altitude loop, misjudged the recovery, and crashed. Both pilots were killed. The only prototype was destroyed. Sikorsky, having spent roughly $10 million of its own money with nothing to show, shelved the entire program.
Why it matters in 2026: The S-67's core insight — that a helicopter with retractable gear, offloading wings, and speedbrakes could push past 220 mph without needing exotic rotor systems — is exactly the design philosophy Sikorsky returned to 40 years later with the X2 and S-97 Raider (coaxial + pusher prop). But the S-67 achieved comparable speeds with conventional single-rotor technology. Modern composite blade materials, fly-by-wire control (which the S-67 lacked and desperately needed for its aerobatic envelope), and active vibration suppression would eliminate the exact failure modes that killed Cannon. The FARA (Future Attack Reconnaissance Aircraft) competition just got cancelled in February 2024, leaving the Army once again without a replacement for the OH-58 Kiowa it retired a decade ago. A modernized S-67 airframe — retractable gear, stub wings, speedbrakes, five-bladed rotor, all now understood problems — would cost a fraction of a coaxial pusher and hit the same speed envelope.
Sikorsky had the answer in a hangar in Stratford, Connecticut, in 1972. The Army wanted a different answer, then cancelled that too.
Daily Automotive Engines
2026-07-23
Every piston ring seals the combustion chamber by pressing outward against the cylinder wall. That outward force per unit of contact area is called radial wall pressure (RWP), and it's the single spec that determines whether your rings seal, drag, or scuff. Most enthusiasts assume "more pressure = better seal." That's backwards. Modern engines make more power with less ring tension than a 1970s small-block, and understanding why explains a decade of ring technology.
RWP comes from two sources: the ring's own spring tension (its free gap wants to expand outward) and combustion gas pressure getting behind the ring and pushing it out — the gas-assist effect. On the compression stroke and power stroke, cylinder pressure sneaks behind the top ring through the piston's ring groove clearance and multiplies the sealing force. A top ring at 150 psi combustion pressure sees roughly 150 psi times the ring's back area pushing it against the wall, which dwarfs its 15-20 psi of static spring tension.
Why thin rings win:
Rule of thumb: Top ring static tension typically runs 10-25 lbs of tangential force (measured with the ring compressed to bore diameter). A 1970s ring might be 25-30 lbs; a modern LS or Coyote top ring is 12-16 lbs. Convert to RWP roughly as: RWP (psi) ≈ 2 × tangential tension (lbs) ÷ (bore diameter × ring axial thickness in inches). A 4.00" bore with a 1.5mm (0.059") ring at 15 lbs tangential = ~127 psi static RWP — trivial compared to 800+ psi peak combustion pressure doing the real sealing.
Real-world example: GM's LS7 (7.0L) uses a 1.5mm top ring with ~14 lbs tension. The same displacement in a 1970 LS7 454 used 5/64" (2.0mm) rings at 28+ lbs. The modern engine seals better, makes more specific output, and loses less power to ring drag — all because engineers learned to let combustion pressure do the sealing work instead of relying on brute spring force.
Daily Debugging Puzzle
map Iteration Order Trap: The HMAC That Signs Differently Every Restart2026-07-23
You're building a webhook signer. Each outbound request is HMAC-signed over its parameters, and the receiver verifies with the shared secret. Locally, tests pass. In staging, tests pass. In prod, roughly half of retried requests fail signature verification — but only after a pod restart. Same params, same secret, different signature.
func SignRequest(params map[string]string, secret []byte) string {
h := hmac.New(sha256.New, secret)
for k, v := range params {
h.Write([]byte(k))
h.Write([]byte("="))
h.Write([]byte(v))
h.Write([]byte("&"))
}
return hex.EncodeToString(h.Sum(nil))
}
func main() {
secret := []byte("s3cr3t")
params := map[string]string{
"amount": "100",
"currency": "USD",
"user_id": "42",
}
fmt.Println(SignRequest(params, secret))
fmt.Println(SignRequest(params, secret))
// Often the same within one run — always different across runs.
}
Go deliberately randomizes map iteration order. Since Go 1.0 the spec has said the order is unspecified, and since 1.3 the runtime actively perturbs it — a seed derived from a per-map hash randomizer is mixed in at map creation so that iteration order varies from run to run (and sometimes within a run after growth).
That means h.Write gets fed amount=100¤cy=USD&user_id=42& on one invocation and user_id=42&amount=100¤cy=USD& on the next. HMAC is order-sensitive: different byte sequences produce different digests. Your signature depends on the runtime's random seed.
Why does it seem to "work" in tests? Small maps (≤ 8 entries, one bucket) often iterate in insertion order for the duration of a single process — the randomization mostly kicks in across processes or after the map grows past one bucket. So a test suite that creates a fresh map inside each test can hash consistently for hours, then a pod restart re-seeds the runtime and every signature changes.
This class of bug hides in anything that turns a map into an ordered byte stream: HMAC signing, canonical JSON, cache keys built from concatenated pairs, log-line fingerprints for dedup, or an idempotency key hashed from a request body.
Never iterate a map when the output order matters. Extract keys, sort them, then iterate in a defined order:
func SignRequest(params map[string]string, secret []byte) string {
keys := make([]string, 0, len(params))
for k := range params {
keys = append(keys, k)
}
sort.Strings(keys)
h := hmac.New(sha256.New, secret)
for _, k := range keys {
h.Write([]byte(k))
h.Write([]byte("="))
h.Write([]byte(params[k]))
h.Write([]byte("&"))
}
return hex.EncodeToString(h.Sum(nil))
}
A few adjacent traps worth naming:
encoding/json sorts map keys when marshaling map[string]T — so json.Marshal(params) is deterministic. But json.Marshal on a struct preserves field order, and swapping between the two representations silently changes the signed bytes.key=value& concatenation, {"a":"b&c","d":"e"} and {"a":"b","c":"d","e":""} produce colliding inputs. Length-prefix each field, or sign a canonical JSON encoding.sync.Map.Range is also unspecified, and range over a channel is FIFO only for a single producer.If you want a lint that catches this class of bug, go vet won't — but a review rule of "no range over a map inside a hash, hmac, Marshal, or io.Writer pipeline without a preceding sort" catches it every time.
Daily Digital Circuits
2026-07-23
A convolutional encoder is a shift register that XORs its taps to produce two output bits for every input bit — cheap to build, but it spreads each bit's influence across many outputs. To decode it, you can't just look at one received bit; you have to find the most likely input sequence that could have produced the noisy bits you observed. That's what a Viterbi decoder does, and it does it in silicon at hundreds of megabits per second.
The trick is the trellis: a graph where each node is an encoder state at a given time step. For a rate-1/2, constraint-length K=7 encoder (the NASA standard, also used in 802.11a/g), there are 2^(K-1) = 64 states. Each state has exactly two incoming edges (from the two possible previous input bits) and two outgoing edges. The decoder's job is to find the single path through the trellis with the smallest accumulated error.
The workhorse block is the ACS unit — Add, Compare, Select. For each state at time t:
For 64 states, you need 64 ACS units running in parallel every cycle. This is the critical path — path metrics feed back on themselves, so you can't just pipeline your way out. Modern designs use modulo arithmetic on the metrics to prevent overflow without periodic renormalization stalls.
After ACS, you need to trace back through the survivor memory to recover the actual decoded bits. Rule of thumb: traceback depth ≈ 5×K gives you within 0.1 dB of infinite-depth performance. So K=7 needs about 35 stages of survivor history. Two common architectures: register-exchange (fast but power-hungry — shift the entire survivor path every cycle) and traceback RAM (slower but denser — write survivors to memory, then walk backward on demand).
Real-world example: An 802.11a receiver at 54 Mbps needs to decode 27 Msymbols/sec of coded bits. At 64 states with two ACS ops per state per symbol, that's 3.5 billion ACS operations per second — trivially met by a 200 MHz clock with parallel ACS units, but a nightmare to code in software.
Once you go past K=9, the state count explodes (256+) and Viterbi becomes uneconomical — that's where LDPC and turbo codes took over for modern 4G/5G.
Daily Electrical Circuits
2026-07-23
Peter Baxandall's 1952 tone control is still the go-to circuit in guitar amps, mixing consoles, and hi-fi preamps. Unlike a passive James/RC tone stack that only attenuates, the Baxandall network wraps around an op-amp so you get true boost and cut around a center flat position — typically ±15 dB at 100 Hz and 10 kHz — with low output impedance and no insertion loss at the flat setting.
How it works. The circuit is a shunt-feedback inverting amplifier where the input and feedback impedances are frequency-dependent. Bass and treble each get their own pot:
Design rule of thumb. Pick the bass corner around 100–300 Hz and treble corner around 3–10 kHz. For a resistor R around the pot, choose:
Example: R = 100 kΩ pot, f_bass = 160 Hz → Cb = 10 nF. f_treble = 3.2 kHz with 10R = 1 MΩ → Ct = 50 pF (round to 47 pF). Use 1% film caps if you care about channel matching in stereo.
Real-world example. The Fender Blackface preamp, JBL/UREI mixing consoles, and countless Behringer-era mixers all use variants of this network. In a Marshall JCM800 modification, swapping the passive tone stack for a Baxandall around a TL072 gives you clean ±12 dB shelving without loading down the preceding gain stage — useful when you want tone shaping after the distortion instead of before.
Watch out for: log-taper pots ruin the symmetry (use linear); large bass caps with electrolytic construction inject distortion (use film); and the op-amp needs bandwidth of at least 1 MHz for clean treble response.
Daily Engineering Lesson
2026-07-23
A face gear is a disc with teeth cut on its flat face (not its cylindrical edge) that meshes with a standard spur or helical pinion whose axis is perpendicular to the disc. Visually, it looks like a crown of teeth pointing along the shaft axis. Functionally, it does what a bevel gear does — transmit power between shafts at 90° — but with one critical manufacturing advantage: the mating pinion is a plain cylindrical gear that can be cut on ordinary hobbing equipment. Only the face gear itself requires specialized tooling.
Why they exist: Bevel gears (especially spiral bevel and hypoid) require expensive dedicated machines — Gleason or Klingelnberg cutters — and their pinions are conical and difficult to inspect. Face gear sets let you replace the bevel pinion with a cheap, off-the-shelf spur pinion. This matters enormously when you need many pinions and few face gears, or when the pinion must be replaceable in service.
Key geometric properties:
Real-world example: The Sikorsky/Boeing RAH-66 Comanche and later Boeing AH-64 Apache upgrade programs evaluated face gear main rotor drives specifically because a helicopter transmission carries torque through many parallel pinion paths into one central gear. Replacing spiral bevel pinions with spur pinions removed the most expensive gears from the maintenance chain and allowed torque-splitting geometries that spiral bevels can't achieve.
Rule of thumb — face width: keep the active face width b under about 0.3× the mean pitch diameter of the face gear. Beyond that, the inner-radius teeth undercut and the outer-radius teeth become pointed. So for a 200 mm face gear, target a face width no greater than ~60 mm. If you need more load capacity, increase the diameter — don't widen the face.
Where you'll see them: helicopter main rotor gearboxes, aerospace accessory drives, some high-end printing press drives, and specialty robotic joints where a replaceable spur pinion drives a large, precisely-mounted face gear.
Forgotten Books
2026-07-23
Book: The horseman's guide & farrier : a new and improved system of handling and educating the horse : together with diseases and their treatment by York & Williams (1866)
Read it: Internet Archive
Tucked into the front matter of an obscure Vermont horse-training manual from 1866 is one of the earliest examples of what we would now recognize as a restrictive end-user license agreement — the kind of legal fine print we now associate with software rather than farriery.
Directly above the copyright notice, York & Williams printed this warning:
TO PURCHASERS. Persons buying this work have every right of using, but no right of teaching, or transferring to others, the book or its contents. By so doing they will lay themselves liable to prosecution.
Read that again. The authors are claiming that when you buy their book, you receive only the right to use the knowledge inside — not to teach it, and not even to hand the physical book to someone else. This is essentially a proto-EULA, printed almost a century before software makers began attaching similar terms to shrink-wrapped floppy disks.
The book itself was a horse-handling manual by two itinerant trainers who traveled the United States and Canada demonstrating their system for gentling "wild and vicious horses." Their livelihood depended on paid demonstrations — so their business model was threatened by the very act of publishing. If a farmer read the book and then taught his neighbors, York & Williams lost customers. Their solution was to invent, on their own authority, a private restriction that copyright law did not actually grant them.
Was it enforceable? Almost certainly not, even in 1866. Copyright has always protected the specific expression of ideas, never the ideas themselves. You cannot copyright a horse-taming technique any more than you can copyright a recipe or a mathematical proof. And the notion that a buyer cannot resell or give away a book they legally purchased was formally demolished by the U.S. Supreme Court in 1908 in Bobbs-Merrill Co. v. Straus, which established the first-sale doctrine. But in 1866 — before that ruling — an ambitious warning printed in bold type might have been enough to deter most readers.
The modern echo. Anyone who has clicked "I Agree" without reading has encountered the intellectual descendant of this 1866 warning: the claim that your purchase grants a limited license rather than ownership, that you may use but not share, that violation invites "prosecution." When John Deere argues you don't really own the tractor you paid for, or when a textbook publisher forbids you from reselling your used copy, they are making the same argument York & Williams made about horse-taming secrets — just with better lawyers.
What's remarkable is not the greed but the earliness. A century and a half before software licensing, two Vermont horse trainers had already intuited the entire logic of the modern IP restriction: sell the artifact, retain control of the knowledge.
Forgotten Darkroom
2026-07-23
Book: DTIC AD0014092: Continuous-Tone Electrostatic Electro-Photography by Defense Technical Information Center (1952)
Read it: Internet Archive
Most people know Xerox as the office-machine company whose name became a verb. Almost nobody knows that in 1952, the underlying technology was classified as restricted military information, developed under an Army Signal Corps contract, and stamped with an espionage warning.
RESTRICTED SECURITY INFORMATION (Subcontract Under Signal Corps... Contract No. DA 36-039 sc-123)... Tenth and Final Progress Report (January 1, 1952, through December 31, 1952) to THE HALOID COMPANY on CONTINUOUS-TONE ELECTROSTATIC ELECTROPHOTOGRAPHY... OBJECTIVE OF RESEARCH: To evolve an electrostatic electrophotographic process capable of producing continuous-tone photographs of high quality. This document contains information affecting the national defense of the United States within the meaning of the Espionage Act...
This is the Tenth and Final Progress Report from Battelle Memorial Institute researchers (Bixby, Andrus, Ullrich, Walkup, Schaffert, Reid) to The Haloid Company — the small Rochester photographic-paper firm that, six years later in 1958, would rename itself Haloid Xerox, and in 1961, simply Xerox.
Two things modern readers rarely realize:
The team never fully cracked continuous-tone xerography for photographs. Instead, Haloid pivoted to what worked: the Xerox 914 office copier shipped in 1959, reproducing documents in high-contrast black and white. Photo-quality continuous tone in dry electrostatic printing wouldn't really arrive until laser printers with sophisticated halftone screening in the 1980s, and true continuous-tone electrophotography only became routine with modern digital presses like the Indigo and iGen in the 2000s.
So this classified 1952 report is a snapshot of engineers chasing a goal that would take fifty years to fully solve — and, in the meantime, accidentally inventing the office as we know it.
Every laser printer in every office today is a direct descendant of this restricted Signal Corps subcontract. The charged photoconductor drum, the toner particles attracted to a latent electrostatic image, the fused output — all of it traces back to research that once carried an Espionage Act warning on its cover page. The next time you press "Print," you're using declassified 1950s military reconnaissance technology.
Forgotten Patent
2026-07-23
On May 12, 1908, the U.S. Patent Office issued patent US 887,357 to a self-taught farmer from Murray, Kentucky named Nathan B. Stubblefield. The title read simply: "Wireless Telephone." The drawings showed something no one in the growing radio community was building — a system that transmitted human voice through the air without Hertzian waves at all.
Stubblefield's device used two large, coaxial coils of wire. A speaker's voice modulated current in the transmitting coil; a receiving coil, tuned nearby, picked up the changing magnetic field and reproduced the voice in an earpiece. His earlier experiments (from at least 1892) also used ground conduction — driving current through the earth between buried metal rods. Marconi's world was chasing radiation; Stubblefield was quietly exploiting near-field magnetic coupling.
He wasn't a crank. On January 1, 1902, he demonstrated the system publicly on the Potomac in Washington, D.C., transmitting voice and music from a boat to receivers on shore. The St. Louis Post-Dispatch called it "wireless telephony." Scientific American covered him. And crucially, his 1908 patent describes something eerily modern: a cellular arrangement of overhead coil "cells" so that a moving vehicle carrying a receiver coil could pick up voice as it passed beneath each one. The patent literally illustrates handoff between fixed transmitters and a mobile subscriber.
Stubblefield died alone and starving in a shack in 1928, convinced (probably rightly) that he had been swindled out of his invention. Radio, meanwhile, went the other direction — Marconi's radiated electromagnetic waves became the standard, and near-field induction was dismissed as a limited-range curiosity.
Except the "curiosity" never went away. It became infrastructure:
Stubblefield picked the "wrong" physics for 1908. Radiation won the century because it traveled miles, not yards. But once we started putting computers in pockets, wearing sensors on wrists, and embedding electronics in bodies, we needed the other half of Maxwell's equations back — short range, low power, no antenna, no line-of-sight required. The Kentucky farmer had the right idea a century too early. The market for it just hadn't been invented yet.
Daily GitHub Zero Stars
2026-07-23
Language: Swift
UsageBar is a minimal macOS menu bar app written in Swift that tracks your usage of two of the most popular AI coding assistants on the market right now: Codex and Claude Code. Instead of digging into billing dashboards or terminal logs to figure out how much of your quota you've burned through, you get a small, glanceable indicator that lives quietly at the top of your screen.
Why is this interesting? A few reasons:
Who benefits? Any Mac-based developer who leans heavily on Codex or Claude Code — especially freelancers and consultants watching costs, or engineers on plans with hard weekly quotas who want a passive early-warning signal before they're locked out. It's also a nice starting point for anyone learning SwiftUI/AppKit menu bar development, since the scope is tightly bounded.
Daily Hardware Architecture
2026-07-23
When you write to memory, the store lands in the cache — not DRAM, not persistent memory, not the NIC's coherent buffer. If you need that write to actually escape the cache hierarchy, you need a flush. x86 gives you three instructions, and they are wildly different in cost and semantics.
CLFLUSH (1998, SSE2): The original. Evicts the target cache line from every level of the hierarchy on every core. It's strongly ordered — CLFLUSH serializes with all loads and stores to any address. In practice this behaves almost like an implicit fence: your out-of-order engine drains, then the flush proceeds. Cost: roughly 100-500 cycles per line, plus the pipeline stall.
CLFLUSHOPT (2016, Skylake): Same eviction behavior, but weakly ordered. CLFLUSHOPTs to different cache lines can pipeline. You still need an SFENCE at the end to guarantee ordering with subsequent stores, but flushing 64 lines no longer means 64 sequential 300-cycle stalls. Throughput improvement of 5-10x when flushing ranges.
CLWB (2016, Skylake-SP): Cache Line Write Back. Writes the dirty line to memory but keeps it in cache in the Exclusive state. This is the killer feature for persistent memory (Optane) and any workload that flushes-then-re-reads. Also weakly ordered, also needs SFENCE.
Concrete example — persistent memory log append:
Rule of thumb: Never write a CLFLUSH loop in new code. If you don't need the line again, use CLFLUSHOPT + SFENCE. If you might, use CLWB + SFENCE. The SFENCE is what makes the flush observable to subsequent stores — the flush instruction alone only guarantees the writeback started, not that it's globally visible.
The gotcha: CLWB on pre-Ice Lake parts was implemented as CLFLUSHOPT internally — the line got evicted anyway. Only from Ice Lake (2019) onward does CLWB actually preserve the cache state. Check CPUID before assuming you're getting the fast path.
Hacker News Deep Cuts
2026-07-23
Link: https://gregwolanski.com/files/
HN Discussion: 2 points, 0 comments
There's a quiet crisis happening in how we store our digital lives, and almost nobody is talking about it. An entire generation is growing up without a mental model of what a file is. They have Google Docs, Notion pages, Instagram posts, iCloud photo streams, and Spotify playlists — but ask them where any of it actually lives, and the question doesn't parse. This post, judging by title and author, is a manifesto for the humble file: a discrete, portable, named thing that you own.
Why does this matter to a technical audience? Because we're the last people who still remember. We know that a file is a self-contained artifact you can copy to a USB stick, email to yourself, back up to three different places, and open in fifteen years with software that hasn't been invented yet. A Notion page cannot do any of these things. A Google Doc is a lease, not a possession. When the service dies — and services always die — the "content" evaporates.
The technical implications are worth dwelling on:
What makes this post interesting isn't nostalgia — it's a design argument. The file abstraction is one of computing's genuine successes: a universal, tool-agnostic unit of persistence. We are actively regressing away from it, and most people don't notice because the alternatives feel more convenient in the moment. The convenience has a bill that comes due later, usually when a company pivots or shuts down and your work is suddenly held hostage inside a proprietary format nobody else can read.
Worth reading if you've ever felt uneasy watching a family member's "photos" live entirely inside an app they don't understand and can't export.
HN Jobs Teardown
2026-07-23
Source: HN Who is Hiring
Posted by: strateos
Strateos (YC W15) is hiring five roles simultaneously — Backend, Full-Stack, Frontend, Principal Architect, and SRE — all ONSITE in Menlo Park. This isn't a sprinkle-hire; this is a company scaling an entire engineering organization at once, and the role composition tells us exactly where they are.
The stack decoded: Linux, Scala, RabbitMQ, Rails, Typescript, React, Ansible, Postgres. This is a fascinatingly bimodal choice. Rails + React + Postgres is the classic YC "ship product fast" trio — clearly the customer-facing experiment definition and scheduling UI. But Scala + RabbitMQ is the tell: they're running a distributed message-passing system, almost certainly the orchestration layer that coordinates physical lab robots executing experiments. Scala is a deliberate choice here — you pick it when you need JVM performance, strong typing for correctness (you really don't want a race condition telling a robot to pipette the wrong reagent), and Akka-style actor models for hardware coordination.
What the roles reveal:
Trends highlighted: The "cloud lab" / lab-as-a-service space (competing with Emerald Cloud Lab, Transcriptic's own history) is heating up post-COVID as biotech and pharma seek to de-risk wet-lab investment. The onsite-only requirement in 2026 is striking — most companies went hybrid. It suggests the software is tightly coupled to physical hardware access; engineers likely need to walk to the robots.
Green flags: Mature stack (nothing trendy-for-trendy's-sake), clear mission, YC pedigree with 10+ years of runway proving the model works, explicit benefits mentioned (medical/dental/vision). Hiring a Principal Architect signals they've earned the right to think long-term.
Red flags: Onsite-only in a post-remote world narrows the talent pool dramatically and hints at cultural inflexibility. Five simultaneous senior hires in Menlo Park also implies a fresh funding round with aggressive burn — pressure to deliver will be intense. No salary bands disclosed.
Daily Low-Level Programming
2026-07-23
When you write() to a file, the kernel doesn't touch the disk. It copies your bytes into the page cache, marks those pages dirty, and returns. The actual I/O happens later, driven by a background flusher thread (kworker/flush) and gated by four sysctl knobs that most engineers never touch — until latency mysteries appear.
The knobs live in /proc/sys/vm/:
write() call is blocked and made to do the writeback itself. This is the "cliff."The disaster scenario. Server with 128 GB RAM, default settings. A batch job dirties memory at 2 GB/s. Background threshold is 12.8 GB — hit in 6 seconds, flusher wakes up. But the disk sustains only 500 MB/s. Dirty pages keep growing. At 25.6 GB (20%), every subsequent write() blocks, throttled to disk speed. Meanwhile, an unrelated process calls fsync() on a 4 KB config file — and waits for the entire 25 GB of dirty pages belonging to other files to flush, because fsync() flushes the whole inode's dirty range and competes for the same congested block queue. Your "quick config update" takes 30+ seconds.
The rule of thumb. Set dirty_bytes (the absolute-value version of the ratio) to roughly 1–2 seconds of your disk's write bandwidth. For a 500 MB/s SSD: vm.dirty_bytes = 500000000, vm.dirty_background_bytes = 100000000. This caps worst-case latency at ~1 second instead of "however long it takes to flush 20% of RAM."
Real-world example. PostgreSQL and Redis both document this. PostgreSQL's checkpoint-tuning guide explicitly recommends lowering dirty_background_bytes because default settings let dirty pages accumulate until a checkpoint's fsync storm stalls all queries. Facebook's engineering blog documented multi-second p99 spikes traced entirely to the 20% cliff on machines with hundreds of GB of RAM.
Check yours right now: grep -E 'Dirty|Writeback' /proc/meminfo. If Dirty is in the gigabytes, your next fsync() is going to hurt.
fsync() into a multi-second stall.
RFC Deep Dive
2026-07-23
If you have ever run an IPsec VPN from a coffee shop, a hotel, or basically anywhere behind a home router, you owe your working tunnel to RFC 3947. It solves one of the most philosophically awkward collisions in the history of the internet: IPsec was designed to protect the integrity of IP headers, and NAT exists specifically to rewrite them.
The core problem. IPsec's Authentication Header (AH) computes an integrity check over the IP source and destination addresses. NAT changes those addresses. Result: every packet is discarded as tampered. ESP without AH survives header rewrites, but ESP has no port numbers. A NAT box tracking outbound flows uses the 5-tuple to demux return traffic — with ESP, all it sees is protocol number 50 and two IP addresses. Two clients behind the same NAT establishing ESP tunnels to the same responder are indistinguishable on the return path. IKE itself runs over UDP/500, and many early NATs rewrote the source port, breaking the cookie exchange that assumes port 500 on both sides.
The detection trick. RFC 3947 adds two new IKE payloads exchanged in Phase 1: NAT-D (NAT-Discovery) payloads containing HASH(CKY-I | CKY-R | IP | Port). Each peer computes the hash of what it thinks its own IP and port are, and what it thinks the peer's IP and port are, then sends both. The receiver recomputes locally. If the hash of the received "your IP" matches what the receiver actually sees, there is no NAT in front of the sender. If it doesn't match, a NAT was between them. This elegantly distinguishes "NAT in front of me" from "NAT in front of the peer," which matters for keepalive scheduling.
The vendor-ID dance. Because RFC 3947 was the successor to years of vendor-specific NAT-T drafts (each with its own incompatible IKE vendor ID hash), a compliant implementation typically sends multiple vendor ID payloads — the RFC 3947 hash 4a131c81070358455c5728f20e95452f plus draft-02, draft-03, and Microsoft variants — and picks the highest common denominator. Wireshark captures of any IKE exchange still show this fossil record.
The float to 4500. Once NAT is detected, both peers switch subsequent IKE traffic (and all ESP traffic) to UDP port 4500. This is the "IKE port floating" that RFC 3948 defines. ESP packets get a four-byte UDP header prepended, giving NAT the port numbers it needs to demux flows. A four-byte "non-ESP marker" of all zeros distinguishes IKE messages from ESP-in-UDP on the same 4500 socket — since a real ESP SPI is never zero, the demultiplexer can tell them apart.
Why it still matters. Every strongSwan, Libreswan, Windows built-in VPN, iOS/macOS IKEv2 client, and enterprise firewall implements this. IKEv2 (RFC 7296) folded NAT-T into the base spec, but the mechanism is identical — hash-based detection, port float to 4500, ESP-in-UDP encapsulation. Modern WireGuard sidesteps the whole mess by being UDP-native from day one, which is arguably a delayed acknowledgment that RFC 3947 was papering over a design mismatch that shouldn't have existed. But until WireGuard is universal, 4500/udp remains one of the most important port numbers most engineers have never had to think about.
Historical footnote. The RFC was published January 2005, but drafts circulated from 2001. Cisco, Microsoft, and SafeNet all shipped incompatible pre-standard versions, which is why the vendor-ID negotiation is so byzantine — the RFC had to codify backward compatibility with its own prehistory.
Stack Overflow Unanswered
2026-07-23
Stack Overflow: View Question
Tags: c, gcc, multiprocessing, operating-system, locking
Score: 2 | Views: 112
The asker is working through MIT 6.828/6.S081 and hit the classic "lab locks" exercise: implement a reader-writer spinlock where many readers can share the lock, but a writer needs exclusive access. Conceptually simple, but easy to botch in ways that only show up at high concurrency.
Why this is hard. A textbook RW-lock has three subtleties that beginners rarely appreciate until they hit a race:
__sync_fetch_and_add without proper acquire/release fences will let the CPU reorder loads from the protected region before the lock acquisition. GCC's newer __atomic_* builtins with explicit memory_order are what you actually want.Sketch of a direction. The cleanest spinlock RW-lock uses a single int:
#define WRITER_BIT 0x80000000
// low 31 bits = reader count, top bit = writer held
void racquire(rwlock *l) {
while (1) {
int v = __atomic_load_n(&l->s, __ATOMIC_RELAXED);
if (v & WRITER_BIT) continue; // writer present, spin
if (__atomic_compare_exchange_n(&l->s, &v, v+1,
0, __ATOMIC_ACQUIRE, __ATOMIC_RELAXED))
return;
}
}
void wacquire(rwlock *l) {
int zero = 0;
while (!__atomic_compare_exchange_n(&l->s, &zero, WRITER_BIT,
0, __ATOMIC_ACQUIRE, __ATOMIC_RELAXED)) {
zero = 0; // reset expected
}
}
Release for readers is __atomic_fetch_sub(&l->s, 1, __ATOMIC_RELEASE); for writers, __atomic_store_n(&l->s, 0, __ATOMIC_RELEASE).
Gotchas. First, disable interrupts around acquire in kernel context — xv6's push_off()/pop_off() — otherwise a timer interrupt can preempt a lock holder and deadlock the same CPU. Second, don't use __sync builtins (deprecated, full-barrier only); use __atomic with explicit orderings so the lab's benchmark actually shows reader parallelism. Third, the lab's grading test spins many readers to prove they can hold concurrently — if your reader path takes an exclusive cache line every time (e.g. one giant global counter), throughput collapses due to cache-line bouncing even though correctness is fine. A per-CPU reader counter with a shared writer flag scales far better if the lab pushes on that.
Daily Software Engineering
2026-07-23
You've already got SLRU with ghost entries. You've added frequency-weighted promotion. Now here's the failure mode nobody warns you about: a key gets hammered for ten seconds during a batch job, accumulates a huge frequency count, and then sits in your protected segment for hours doing nothing useful. Frequency without a time window is just lifetime popularity, and lifetime popularity is a terrible predictor of future access.
Promotion windowing fixes this by only counting accesses that happened inside a sliding time window (say, the last 5 minutes) when deciding whether a probationary key deserves promotion to the protected segment. Old hits decay out; recent bursts count. The key still lives in the cache — you're only changing the promotion decision, not eviction.
How it works:
Real-world example: A news site's article cache. When a story trends, it gets 50,000 hits in an hour and its lifetime frequency shoots up. Without windowing, that article sits in the protected segment for the next 48 hours while newer stories fight for probationary slots. With a 30-minute promotion window, once the trend dies, the article stops getting promoted on subsequent accesses and naturally drifts out — freeing protected space for the next trending story.
Rule of thumb: Set the window to roughly 2–3× your typical hot-key lifespan. For CDN edge caches serving trending content, 15–30 minutes works well. For database buffer pools where working sets shift by workload phase, match the window to your phase duration (often 5–15 minutes). Too short and you thrash — legitimately hot keys keep failing promotion. Too long and you're back to lifetime frequency.
Implementation cost: A 4-slot timestamp ring per key adds ~32 bytes. On a 10M-entry cache, that's 320MB — non-trivial. Cheaper alternative: an exponentially-decayed counter (8 bytes) with decay applied lazily on access. You lose precision but keep the "recent bursts matter more" property.
When to skip it: If your access patterns are stationary (same keys hot for weeks), windowing adds cost without benefit. It shines when workloads have temporal locality of popularity — trending content, time-of-day patterns, campaign-driven traffic.
Tool Nobody Knows
2026-07-23
You know the drill. A service running as www-data can't open /srv/apps/tenant-42/uploads/inbox/foo.pdf. You start ls-ing each directory: ls -ld /srv, ls -ld /srv/apps, ls -ld /srv/apps/tenant-42... six commands later you spot a stray drwx------ in the middle. Or you don't, because there's a symlink pointing to a bind mount that lives on an NFS export with squashed UIDs, and now you're chasing your tail.
namei is the util-linux tool built for exactly this. One command, one column-per-hop breakdown, symlinks and mountpoints expanded inline. Been shipping in every distro since the '90s.
$ namei -lx /srv/apps/tenant-42/uploads/inbox/foo.pdf
f: /srv/apps/tenant-42/uploads/inbox/foo.pdf
Dr-xr-xr-x root root /
drwxr-xr-x root root srv
drwxr-xr-x root root apps
drwx------ deployer deployer tenant-42 <-- gotcha
drwxr-xr-x deployer www-data uploads
drwxrwx--- deployer www-data inbox
-rw-r----- deployer www-data foo.pdf
tenant-42 is mode 700 owned by deployer, so www-data can't traverse into it — the leaf's permissions are irrelevant. The chase is over in one screen.
The flags that matter:
-l — long listing with mode/owner/group per component. This is the flag you always want; it's basically -m -o -v bundled.-x — mark mountpoints with a capital D instead of lowercase d. Priceless when the "missing" permission is actually a container bind mount over a hardened directory, and you'd otherwise never notice the layer change.-n — don't follow symlinks. Useful when the symlink target itself is the thing you're investigating.The symlink case, where namei earns its keep:
$ namei -l /var/www/html/uploads/report.csv
f: /var/www/html/uploads/report.csv
dr-xr-xr-x root root /
drwxr-xr-x root root var
drwxr-xr-x root root www
drwxr-xr-x root root html
lrwxrwxrwx root root uploads -> /mnt/data/uploads
dr-xr-xr-x root root /
drwxr-xr-x root root mnt
drwx------ root root data <-- symlink target dies here
drwxrwxr-x root www uploads
-rw-rw-r-- root www report.csv
Each symlink gets its own indented subwalk. Try producing that with ls and readlink in a loop and see how long it takes you — and how many corner cases (loops, relative link targets, mid-path links) you'd have to handle.
Why not just stat or ls -ld in a loop? You can, and you probably have. But you have to spell out every component, remember to chase the symlink targets manually, and mentally align seven different outputs. namei tokenizes the path itself, walks each component with lstat(2), and hands you one aligned table. It's the diff between "I'll figure this out" and "here's your bug."
The killer combo: sudo -u www-data namei -lx /srv/apps/tenant-42/uploads/inbox/foo.pdf. Now lstat happens as the actual failing user, and any traversal denials surface right where they'd fail at runtime. If your daemon runs as UID 33 and hits an NFS mount that squashes it to nobody, you'll see the exact hop where the perms lie — without having to su into a service account or spelunk through logs.
namei -lx collapses "who denied me at what layer?" from a six-command scavenger hunt into a one-command truth table.
What If Engineering
2026-07-23
A rotovator is a tether spinning end-over-end in orbit, its tip dipping into the upper atmosphere like a rotating pinwheel. Time the rotation right and the tip momentarily stands still relative to a mountaintop, grabs a payload, and flings it upward as the wheel keeps turning. No rocket needed for the ride up — just a hook and impeccable timing.
Let's build one that snatches cargo from the summit of Chimborazo (6,263 m, and conveniently the point on Earth's surface farthest from the planet's center).
Circular orbital velocity at 200 km altitude is about 7,780 m/s. The mountaintop moves eastward at ~465 m/s (equatorial rotation). For the tip to be stationary relative to the peak at grab-time, the tether must spin so its tip velocity equals the orbital velocity of its center of mass, minus 465 m/s, in the opposite direction of orbital motion.
Pick a center-of-mass altitude of 500 km (orbital velocity ~7,613 m/s). The tip needs to be moving backward at 7,613 − 465 = 7,148 m/s at the moment of contact. That means tether length ≈ 500 km − 6.3 km ≈ 494 km, and rotation rate ω = v/r = 7,148 / 494,000 ≈ 0.0145 rad/s — one full rotation every 7.2 minutes.
Tip centripetal acceleration: ω²r = (0.0145)² × 494,000 ≈ 104 m/s². That's 10.6 g on the cargo. Freight only — no passengers unless you enjoy hemorrhaging.
The tether must support its own weight under that centripetal load. Characteristic velocity V_c = √(σ/ρ) sets the limit — the tip can safely spin at roughly V_c.
Real CNT yarns today hit maybe 4 GPa in bulk — a factor-of-15 gap. A conservative Zylon rotovator could still work if we accept a lower tip speed: build a shorter, slower wheel that meets an aircraft flying at Mach 12 instead of a stationary peak. This is exactly the "hypersonic skyhook" architecture NASA studied in the 2000s.
Release the cargo half a rotation later, at apogee. Payload velocity = orbital velocity + tip velocity = 7,613 + 7,148 ≈ 14,760 m/s — well above solar escape (16.6 km/s from LEO requires a bit more, but you're on a hyperbolic trajectory heading somewhere interesting). Every grab-and-throw drains the rotovator's orbital energy, so you need to rebalance — either by catching descending cargo (elegant) or with an ion thruster (boring but reliable). An asymmetric flow of 1 ton up per week needs about 10 MW of electric propulsion to hold station.
At 7,148 m/s tip speed, "stationary relative to peak" lasts a few milliseconds across a capture zone maybe 10 meters wide. Miss by 3 ms and the hook arrives 20 meters off. This is the actual killer — not materials, not gravity, but timing a moving grapple to millisecond precision from 500 km away, twice a day, forever.
Wikipedia Rabbit Hole
2026-07-23
Wikipedia: Read the full article
In 1940, as German bombers droned over British cities during the Blitz, a young researcher named Robert W. Sutton was tinkering with a peculiar vacuum tube at the Signal School group at Bristol University. His device would become known as the Sutton tube — the world's first reflex klystron — and it would quietly become one of the most important gadgets of the Second World War. Without it, radar as we know it might have arrived years later.
To understand why the Sutton tube mattered, you need to know what a klystron does. A conventional klystron uses an electron beam that passes through two separate resonant cavities: one that "bunches" the electrons and another that extracts amplified microwave energy. It's elegant, but bulky. Sutton's insight was radical: use just one cavity. The electron beam passes through, hits a repeller electrode with a negative voltage, and bounces back through the same cavity — hence "reflex." The returning bunched electrons dump their energy into the cavity on the way back, producing microwave oscillations.
Why did this matter? Because reflex klystrons were tunable low-power oscillators — perfect as the "local oscillator" in superheterodyne radar receivers. If you've heard of the cavity magnetron (the celebrated British invention that gave Allied radar its punch), the reflex klystron was its unsung sibling. The magnetron blasted out the transmitted pulse; the reflex klystron sat in the receiver, generating the reference frequency that let the radar detect faint echoes. You could tune it just by adjusting a voltage — no mechanical adjustments, no delay. Every centimetric radar set needed one.
The connections here run deep:
What's striking about the Sutton tube is how it embodied a whole philosophy of wartime engineering: take an existing complex device, find the elegant simplification, and get it into production yesterday. Sutton didn't invent the klystron — he found the version that could be manufactured by the thousands and fit inside an aircraft. The single-cavity design meant fewer parts, easier tuning, and lower voltage requirements.
The device's descendants are still around. Modern particle accelerators use gigantic klystrons to accelerate beams. Satellite ground stations use them for uplinks. And every time you've watched a scene in an old war film with a technician tweaking a dial on a radar receiver, they were almost certainly adjusting the repeller voltage on something derived from Sutton's 1940 breakthrough.
Daily YT Documentary
2026-07-23
Channel: Magnetic Space (2590 subscribers)
This video tackles one of the most poetic truths in modern astrophysics: the atoms that make up your body — the calcium in your bones, the iron in your blood, the oxygen in every breath — were forged in the cores of stars that lived and died long before our solar system existed. It's the concept Carl Sagan famously distilled into "we are made of star stuff," but explored with the depth that concept deserves.
Expect a walk through stellar nucleosynthesis: how the Big Bang produced only hydrogen, helium, and traces of lithium, and how everything heavier had to be cooked up inside stars through fusion. Lighter elements form quietly over a star's main-sequence life, while heavier elements like gold, uranium, and much of the iron on Earth were forged in the violent deaths of massive stars — supernovae and neutron star collisions — that scattered enriched material across the galaxy.
The channel is small (under 3k subscribers) but the topic is a genuinely rewarding one: it connects cosmology, nuclear physics, and biology in a way that reframes how you see the physical world around you. The other candidate — a clickbaity "secret Apollo experiments" video about growing food on the Moon — reads like low-effort AI narration from a channel that solicits paid promotions in its description.
Daily YT Electronics
2026-07-23
Channel: TechPenguin (1670 subscribers)
Ground loops are one of those insidious problems that plague audio engineers, instrumentation designers, and anyone building precision analog circuits. They manifest as mysterious 50/60 Hz hum, unexplained DC offsets, or intermittent noise that vanishes when you touch the chassis — and they're notoriously hard to diagnose without the right approach.
This TechPenguin video tackles the problem head-on with an oscilloscope-driven methodology. Rather than just describing ground loops in the abstract, the video walks through what a ground loop actually looks like on a scope trace: the characteristic mains-frequency ripple, the differential voltage measurable between two supposedly "grounded" points, and how the amplitude scales with loop area.
The practical value here is the diagnostic workflow. You'll learn how to use the scope in differential mode (or with careful single-ended probing) to measure the voltage between chassis ground points, identify which piece of equipment is injecting current into the loop, and verify that mitigations — star grounding, isolation transformers, ground-lift adapters, or optical isolators — actually work rather than just seeming to.
For a small channel, TechPenguin punches above its weight on fundamentals that bench technicians and hobbyists genuinely need. Ground loop debugging is a rite of passage for anyone doing sensitive measurements, and having a systematic scope-based approach beats the usual "wiggle cables until it stops" method.
Daily YT Engineering
2026-07-23
Channel: Metals Beyond Matter (154 subscribers)
Solidification is one of those topics that sits quietly at the foundation of nearly every metal object around you — from the engine block in your car to the turbine blades in a jet engine — yet it's rarely explained well outside a university metallurgy course. This video tackles the specific question of why pure metals and alloys behave so differently as they transition from liquid to solid, which is where a huge amount of a metal's final properties get locked in.
Pure metals solidify at a single sharp temperature, while alloys solidify across a range, producing a "mushy zone" where liquid and solid coexist. That distinction drives everything from casting defects (segregation, porosity, hot tearing) to the grain structures that determine strength and ductility. Understanding cooling curves, nucleation, and dendritic growth is essential for anyone doing casting, welding, additive manufacturing, or failure analysis.
Why this one over the alternatives: Most of the other candidates are surface-level "why is X material like this" explainers or hashtag-heavy shorts. The stainless-steel and titanium videos cover ground already saturated on YouTube. This one addresses a mechanism — phase transformation kinetics — that actually rewards the viewer with a mental model they can reuse across many materials problems.
Daily YT Maker
2026-07-23
Channel: Real Roofing (338 subscribers)
Most roofing contractors sub out their sheet metal work to a fab shop across town, mark it up, and hope the panels show up on time. Real Roofing brings the whole process in-house, and this video walks through what that actually looks like on a real residential job — a backyard gazebo in Peoria, Arizona.
The interesting content here is the roll-forming step. Roll formers take a coil of flat sheet steel and progressively bend it through a series of paired rollers until it takes on the finished profile — standing seam, corrugated, ribbed panel, whatever the job calls for. Doing it on-site (or in a dedicated shop truck) means panels can be produced to exact length with no transverse seams, which is a real weatherproofing win on longer runs.
For a small channel from a working contractor, this is the kind of content that's genuinely useful: you get to see the shop layout, the roll-former in operation, and how custom flashing and trim get cut and bent to match a non-standard structure like a gazebo (which has more corners and transitions per square foot than most houses). If you're planning a metal roof project or just curious about how the panels above your head actually get made, it's a solid look behind the curtain.
Note: The other candidates were mostly Shorts, hashtag spam, or a very brief water-reclamation clip — this was the clearest choice.
Daily YT Welding
2026-07-23
Channel: Micro Motors ASMR (17 subscribers)
Custom motorcycle subframe work is a genuinely useful fabrication topic because it combines tube bending, mitered joints, and structural welding on a part that has to survive road vibration and rider weight. A café racer seat frame (sometimes called a subframe loop) typically involves bending small-diameter round tube into a matched pair of rails, notching the ends to fit the existing frame's main tubes, and tying them together with cross braces.
What makes this build worth watching is the scope: it's a complete, at-home project rather than a factory montage. Expect to see how the builder establishes the seat pan geometry, jigs the tubes so both sides mirror each other, and copes the tube ends to sit flush against a round host tube — the fishmouth cut is one of the most useful skills in motorcycle and bicycle fabrication.
The ASMR framing means minimal narration, so treat it as a visual reference: watch the sequence of operations, the fixturing choices, and the tack-then-fully-weld discipline that keeps a thin-wall tube frame from warping. It's also a rare look at a channel with only 17 subscribers actually attempting a real-world modification project instead of shorts spam.
The other candidates today were mostly shorts, hashtag-heavy clips, or vague factory footage — this one stands out as an actual sustained build.
