Programming Leftovers
-
The Rust Programming Language Blog: Generic associated types to be stable in Rust 1.65
As of Rust 1.65, which is set to release on November 3rd, generic associated types (GATs) will be stable — over six and a half years after the original RFC was opened. This is truly a monumental achievement; however, as with a few of the other monumental features of Rust, like async or const generics, there are limitations in the initial stabilization that we plan to remove in the future.
The goal of this post is not to teach about GATs, but rather to briefly introduce them to any readers that might not know what they are and to enumerate a few of the limitations in initial stabilization that users are most likely to run into. More detailed information can be found in the RFC, in the GATs initiative repository, in the previous blog post during the start of the stabilization push, in the associated items section in the nightly reference, or in the open issues on Github for GATs
-
Generic associated types in Rust 1.65 [LWN.net]
The Rust Types Team announces that the long-awaited generic associated types feature will be stable in Rust 1.65.
-
Scripts and programs should skip having extensions like '.sh' and '.bash'
I have the opposite view. Unless you have a strong reason, you should avoid putting an extension like .sh, .bash, or .pl on your scripts and programs. The reason to avoid it is a variant of not making product names visible in messages. Some day you may want to change that shell script into a Perl script, or a Ruby script, or a compiled program (perhaps you get an urge to use Rust). At that point, either you have to find every use of the script elsewhere in your system and change them all, or you have a '.sh' program that's actually written in Perl.
-
Paper review: Concurrency Control Performance Modeling
Another week, another paper! This week for our Red Book reading group, I read "Concurrency Control Performance Modeling" by Rakesh Agrawal, Michael J. Carey, and Miron Livny. It was 46 pages, and I had a little trouble finding the whole paper—many of the Google Scholar links had missing pages in the middle, which was confusing the first time I encountered a weird gap.
-
Early speed optimizations aren’t premature
The problem with this saying is that many people wrongly interpret it as “early optimization is the root of all evil.” In fact, writing fast software from the start can be hugely beneficial.
In order to reduce the scope a bit, I’m going to focus on one particular problem domain: data processing pipelines or batch jobs. This is the kind of software you often write when doing data science, or scientific computing: you load in some data, process them, spit out a result.
-
RIP: Kathleen Booth, the inventor of assembly language • The Register
Professor Kathleen Booth, one of the last of the early British computing pioneers, has died. She was 100.
Kathleen Hylda Valerie Britten was born in Worcestershire, England, on July 9, 1922. During the Second World War, she studied at Royal Holloway, University of London, where she got a BSc in mathematics in 1944. After graduating, she became a junior scientific officer at the Royal Aircraft Establishment, a research organization in Farnborough. Two years later she moved to Birkbeck College, first as a research assistant, and later a lecturer and then research fellow.
She also worked at the British Rubber Producers' Research Association (BRPRA), where she met and worked with mathematician and physicist Andrew Donald Booth, who later became her husband. After studying with X-ray crystallographer Professor J D Bernal – inventor of the Bernal Sphere – A D Booth was working out crystal structures using X-ray diffraction data, and finding the manual calculations very tedious; he built an analog computer to automate part of this.
-
One-Time Programs
One of the things I like to do on this blog is write about new research that has a practical angle. Most of the time (I swear) this involves writing about other folks’ research: it’s not that often that I write about work that comes out of my own lab. Today I’m going make an exception to talk about a new paper that will be appearing at TCC ’22. This is joint work with my colleagues Abhishek Jain and Aarushi Goel along with our students Harry Eldridge and Max Zinkus.
This paper is fun for three reasons: (1) it addresses a cool problem, (2) writing about it gives me a chance to cover a bunch of useful, general background that fits the scope of this blog [indeed, our actual research won’t show up until late in the post!], and most critically (3) I want people to figure out how to do it better, since I think it would be neat to make these ideas work more practical. (Note, if you will, that TCC stands for Theory of Cryptography conference, which is kind of a weird fit.)
-
I ❤️ Scala's Community
The official community channels are very civilized, friendly, and welcoming. There, you can easily find very knowledgeable engineers and scientists, willing to help, without having to feel shame for the questions you ask.
-
Immutable Collections should be Your Default
Mutable collection types should only be used strategically, with purpose, otherwise for correctness/safety purposes, the default should be immutable collection types, aka persistent data structures.
-
Dependencies
Here is two straight up facts:
a. There are dependencies that are gratuitous and unnecessary.
b. There are dependencies that make your code significantly more readable and comfy.
-
Louis-Philippe Véronneau - Extruded Schiit Stack
The original Schiit Stack — being 2 devices high — was pretty manageable as-is. With my current 4-high stack though, things became unstable and I had to resort to finding a way to bolt them together.
[...]
After looking at local options, I then decided to use 15mm x 15mm rails from Misumi. I went with this option since the rails are still small enough not to be an eyesore, but also because this system uses M3 screws, which the Schiit mini series also uses, making assembly much easier.
I choose to make the assembled stack quite a bit taller than the previous one made with 3D printed plastic, as I found the headphone amp got pretty hot during the summer and I wanted to provide better airflow.