mjtsai + catfish_man   545

Twitter
iOS didn’t exist yet, but on the Mac side NSUndoManager confused me so badly I decided to write my own.

Each design problem I solved brought mine closer to being NSUndoManager again, so I finally deleted it and used Cocoa’s with more understanding.https://t.co/95duoFcULJ

— David Smith (@Catfish_Man) February 15, 2020
FavoriteTweet  Catfish_Man 
yesterday by mjtsai
Twitter
not really, no. If you reserveCapacity() the actual amount you need, then you will always get the appropriate small or large representation.

If your contents don’t fit in small, you don’t want small.

— David Smith (@Catfish_Man) February 10, 2020
FavoriteTweet  Catfish_Man 
6 days ago by mjtsai
Twitter
str.reserveCapacity(<=15) will do it

— David Smith (@Catfish_Man) February 10, 2020
FavoriteTweet  Catfish_Man 
6 days ago by mjtsai
Twitter
Subtle Swift 5.2 change: -mutableCopy on bridged Swift Arrays will now do copy on write and produce a Swift NSMutableArray subclass, rather than eagerly copying to an ObjC NSMutableArray.

(At least I’m pretty sure I got that change into 5.2)

— David Smith (@Catfish_Man) February 5, 2020
FavoriteTweet  Catfish_Man 
11 days ago by mjtsai
Twitter
That said, I believe I can probably generate a longer list of hard to answer questions in Swift using *only* the behavior of the “as?” operator, so I’m not sure I agree with your premise.

— David Smith (@Catfish_Man) February 5, 2020
FavoriteTweet  Catfish_Man 
11 days ago by mjtsai
Twitter
Honestly this is a huge problem with the current model of software production. Any structural quality improvements you make will be used to shorten schedules by reducing bug fixing time instead.https://t.co/RtT3Bfb0CF

— David Smith (@Catfish_Man) February 1, 2020
FavoriteTweet  Catfish_Man 
15 days ago by mjtsai
Twitter
In my experience it’s almost impossible to talk about the company as a whole, and these things are at the team/group/department level.

Swift stdlib is quite pleasant currently.

— David Smith (@Catfish_Man) January 30, 2020
FavoriteTweet  Catfish_Man 
18 days ago by mjtsai
Twitter
Finally got my “make Swift allocations that have no ObjC weak references or associated objects deallocate much faster” change landed. It was like 95% working last spring, but I was stumped by one remaining failure.

Let’s see if it sticks 😅https://t.co/IsHpd0nJ7H

— David Smith (@Catfish_Man) January 24, 2020
FavoriteTweet  Catfish_Man 
23 days ago by mjtsai
Twitter
This is an incredibly valuable programming skill that I’ve never really figured out how to train: the ability to look at a thing, zoom out to an abstract level, and then zoom back in to a different-looking concrete case you’ve already solved.https://t.co/MrzRyMdKPw

— David Smith (@Catfish_Man) January 24, 2020
FavoriteTweet  Catfish_Man 
23 days ago by mjtsai
Twitter
I still really like the description of Swift’s memory model (I believe I’m paraphrasing @jckarter here) as being exactly like Rust, except all lifetimes are implicit and whenever it would emit a compile error it emits a copy or retain instead.

— David Smith (@Catfish_Man) December 24, 2019
FavoriteTweet  Catfish_Man 
7 weeks ago by mjtsai
Twitter
Reminder that if you want to handle priority inversions properly there’s no way (at least on iOS/Mac and in userspace, elsewhere is outside my expertise) to do one-writer-or-arbitrarily-many-readers mutual exclusion. Neither concurrent dispatch queues nor pthread rwlocks do it.

— David Smith (@Catfish_Man) December 17, 2019
FavoriteTweet  Catfish_Man 
8 weeks ago by mjtsai
Twitter
There was a… rather long period where any time NSUserDefaults wrote a file out it would immediately read it back in and verify it, just to make sure that any possible heap corruption didn’t get persisted to disk. Even your computer doesn’t trust computers https://t.co/wjehswVpN5

— David Smith (@Catfish_Man) December 16, 2019
FavoriteTweet  Catfish_Man 
9 weeks ago by mjtsai
Twitter
([extremely objective-c voice] we can resolve this dilemma by not supporting inlining within a module either!)

— David Smith (@Catfish_Man) December 4, 2019
FavoriteTweet  Catfish_Man 
10 weeks ago by mjtsai
Twitter
Terrible idea: supporting inlining across module boundaries (it leads to accidentally calcifying incorrect or suboptimal implementations)

Terrible idea: not supporting inlining across module boundaries (it leads to library abstractions always being second class to DIY ones)

— David Smith (@Catfish_Man) December 4, 2019
FavoriteTweet  Catfish_Man 
10 weeks ago by mjtsai
Twitter
Interestingly, libdispatch and libxpc do the same trick via a different mechanism. They have their native vtable-style dispatch structure, and a fake ObjC class, and use a linker order file to make sure they get laid out next to each other in memory. Wacky stuff.

— David Smith (@Catfish_Man) December 1, 2019
FavoriteTweet  Catfish_Man 
11 weeks ago by mjtsai
Twitter
(It’s also vaguely unclear to me why anyone thinks this is a gotcha. ObjC is written in C++ and assembly too. Swift objects are allocated via C’s runtime. It’s all built on each other, always has been.

But if you must gotcha, at least learn about the more interesting reality 😊)

— David Smith (@Catfish_Man) December 1, 2019
FavoriteTweet  Catfish_Man 
11 weeks ago by mjtsai
Twitter
re: “every Swift class is an ObjC class” going around, it’s more complicated than that.

Swift classes contain an ObjC class attached at the front for interop purposes. The ObjC runtime also grew the ability to ask Swift’s runtime about the parts it doesn’t understand.

— David Smith (@Catfish_Man) December 1, 2019
FavoriteTweet  Catfish_Man 
11 weeks ago by mjtsai
Twitter
One of the problems with corporate secrecy is it leads people to assume that every tidbit of information is part of some grand overarching plan, when a lot of times it’s just “no, someone got around to implementing that optimization”.https://t.co/jCSbpVG4Nq

— David Smith (@Catfish_Man) November 20, 2019
FavoriteTweet  Catfish_Man 
12 weeks ago by mjtsai
Twitter
(The specific issue is that String *really* wants to have valid contents, and NSString is pretty chill and will let you delete chunks of things and try to muddle along. When bridging we have to mimic NSString for compatibility.)

— David Smith (@Catfish_Man) November 15, 2019
FavoriteTweet  Catfish_Man 
november 2019 by mjtsai
Twitter
Karoy’s proposals are always delightfully thoughtful and well explained. This is well worth taking the time to read even though most Swift programmers likely won’t end up *directly* using it: https://t.co/9axnm7irFz

— David Smith (@Catfish_Man) November 8, 2019
FavoriteTweet  Catfish_Man 
november 2019 by mjtsai
Twitter
Check out, build, and install Foundation + CoreFoundation: one command per step, only one of them at all complicated

Just check out something from GitHub into GCR: ?!?????? https://t.co/RWuzTZj5V7

— David Smith (@Catfish_Man) November 4, 2019
FavoriteTweet  Catfish_Man 
november 2019 by mjtsai
Twitter
Worth it pic.twitter.com/8moj48l4DY

— David Smith (@Catfish_Man) October 15, 2019
FavoriteTweet  Catfish_Man 
october 2019 by mjtsai
Twitter
My first prototype was an alternative to NSFileHandle of all things, but some friends on another team were like “you know if you replace all those NSData*s with ids it looks a surprising amount like something we were prototyping, let’s join forces”.

— David Smith (@Catfish_Man) October 11, 2019
FavoriteTweet  Catfish_Man 
october 2019 by mjtsai
Twitter
Well, the final version that actually shipped isn’t my work, but the original concept is simple enough: make KVO composable, then strip it down to just the most core concept (data streaming) by replacing all the options and parameters with composition.

— David Smith (@Catfish_Man) October 11, 2019
FavoriteTweet  Catfish_Man 
october 2019 by mjtsai
Twitter
After a lot of fiddly work, the Swift runtime and standard library no longer depend on Foundation! (they’ll still use it for bridging if it’s present)https://t.co/OSpic0rVIQ

Next up: finding out where the last thing linking CoreFoundation is hiding and decoupling from that too

— David Smith (@Catfish_Man) August 23, 2019
FavoriteTweet  Catfish_Man 
august 2019 by mjtsai
Twitter
This article comparing two ADHD meds is fascinating for a number of reasons, but the one that particularly stuck out to me is the way time release pills actually work. I assumed it was based on the rate at which they dissolve, but it’s *mechanical*!https://t.co/HpBMcunO0U

— David Smith (@Catfish_Man) August 22, 2019
FavoriteTweet  Catfish_Man 
august 2019 by mjtsai
Twitter
One of the awkward things about how decoupled Apple’s betas are from when improvements get submitted is sometimes I’ll see something going around twitter, know about a relevant change, and have no idea if that change is in the build they’re talking about.

— David Smith (@Catfish_Man) August 6, 2019
FavoriteTweet  Catfish_Man 
august 2019 by mjtsai
Twitter
SE-0263, my proposal for allowing faster creation of Strings in certain cases, is up for review now: https://t.co/l449UIYYUn

Comments and suggestions gratefully accepted :)

— David Smith (@Catfish_Man) July 30, 2019
FavoriteTweet  Catfish_Man 
july 2019 by mjtsai
Twitter
Today in “speedups that really shouldn’t work this well”, ~10% or so win for Encoder just by avoiding “as! NSCopying”https://t.co/BwH2XMjDsU

— David Smith (@Catfish_Man) July 17, 2019
FavoriteTweet  Catfish_Man 
july 2019 by mjtsai
Twitter
LRT: Back when I maintained the Cocoa formatters, NSRelativeDateTimeFormatter was the most commonly requested missing feature by a large margin. It handles things like “yesterday” and “in 2 weeks”. Tina (I don’t think she’s on twitter?) did a fantastic job with it! #wwdc

— David Smith (@Catfish_Man) June 6, 2019
FavoriteTweet  Catfish_Man 
june 2019 by mjtsai
Twitter
Let's see, names this project has had…

Pipelines
Dataflows
KVO2
PubSub
Combine

am I forgetting any? 😂

— David Smith (@Catfish_Man) June 3, 2019
FavoriteTweet  Catfish_Man 
june 2019 by mjtsai
Twitter
A long LONG time ago (…2012), @cbarrett, @andy_matuschak, and I were working on a thing.

It’s come a long way since then, and ultimately the final big push was after I left the team.https://t.co/XxZjKEjruM

— David Smith (@Catfish_Man) June 3, 2019
FavoriteTweet  Catfish_Man 
june 2019 by mjtsai
Twitter
Cheesegrater 2.0 has rounded handles, which tbh is the main thing that needed to be fixed #wwdc

— David Smith (@Catfish_Man) June 3, 2019
FavoriteTweet  Catfish_Man 
june 2019 by mjtsai
Twitter
INCREDIBLY stoked about app launch time speedups in iOS 13. Huge props to the folks who followed up on my temporary team’s work last year and took it way further than we could have <3 #wwdc

— David Smith (@Catfish_Man) June 3, 2019
FavoriteTweet  Catfish_Man 
june 2019 by mjtsai
Twitter
Looks like someone has made an implementation of the beautiful Hash Array Mapped Trie data structure for Swift: https://t.co/9PDRCpsSS0

Interesting to see the tradeoffs illustrated so starkly: 10x slower vs Dictionary for access, but so much faster to copy that it broke the test

— David Smith (@Catfish_Man) May 24, 2019
FavoriteTweet  Catfish_Man 
may 2019 by mjtsai
Twitter
Oh nice.

Yeah this is definitely something we could do better in Foundation. We also should just have a version of CFStringGetCStringPtr that takes both an encoding and a requires termination flag. Currently we have one or the other but not both for some reason.

— David Smith (@Catfish_Man) April 27, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
I’ve updated my “NSUserDefaults in Practice” guide for iOS 12/macOS Mojave. This will likely be the last update to it, since I no longer work on NSUserDefaults.

Most of the update was just labeling pitfalls as pre-iOS-12-only 🎉https://t.co/Vza3HN9yGu

— David Smith (@Catfish_Man) April 14, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
NSUserDefaults always writes to Any, but will preferentially read from Current if it’s present.

— David Smith (@Catfish_Man) April 14, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
Oh, I can tell you what’s going on there: that’s { kCFPreferencesCurrentUser, kCFPreferencesAnyHost } vs { kCFPreferencesCurrentUser, kCFPreferencesCurrentHost }

Usually you want the former, as you’re seeing.

— David Smith (@Catfish_Man) April 14, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
sudo log config --subsystem=com. apple. {defaults, cfprefsd} --reset

to turn it back off.

— David Smith (@Catfish_Man) April 14, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
Interesting. Try turning on debug logging:

sudo log config --subsystem=com. apple .{defaults, cfprefsd} --mode "level:debug, persist:debug"

(minus the spaces in the com bit, had to avoid twitter auto linking)

cfprefsd + your app will log a lot of detail about prefs operations

— David Smith (@Catfish_Man) April 14, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
…and yes Swift technically can do it all as an expression like the shell script does :P

The zip-like bit I have here is so gross lol pic.twitter.com/hylFhZ1863

— David Smith (@Catfish_Man) April 6, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
I can’t figure out if I’m proud or horrified of this bit of shell nonsense I came up with to compare two files of Swift benchmark results:

paste -d , oldoutput.txt output.txt | awk -F "," '{printf "%s %s %s %f\n", $2, $8, $16, $8 / $16}' | sort -k4 | egrep -v "(1\.0|0\.9[1-9])"

— David Smith (@Catfish_Man) April 6, 2019
FavoriteTweet  Catfish_Man 
april 2019 by mjtsai
Twitter
My favorite thing about this “FB deleted all of Zuck’s old posts” debacle is that the *positive spin narrative* is “our backups don’t work and we have random customer data loss”. Imagine wanting your customers to believe *that*, but they assume worse of you.

— David Smith (@Catfish_Man) March 30, 2019
FavoriteTweet  Catfish_Man 
march 2019 by mjtsai
Twitter
The cool thing about cache awareness is that it’s fractal. It turns out that jumping over the cold path of swift_retain instead of jumping to it burns enough icache to slow down a bunch of -Onone benchmarks as much as 20%, much to my surprise!

— David Smith (@Catfish_Man) March 17, 2019
FavoriteTweet  Catfish_Man 
march 2019 by mjtsai
Twitter
LRT: often under-leveling doesn’t even look like not valuing accomplishments; it can look like not assigning high visibility/prestige (often high risk) projects to someone because they’re “too important for keeping the day to day stuff working”

— David Smith (@Catfish_Man) March 5, 2019
FavoriteTweet  Catfish_Man 
march 2019 by mjtsai
Twitter
Fun fact: using CFDateFormatter on dates in the year 12000 can produce incorrect results in some cases. Can you see what’s going on here?https://t.co/ZM2aYAUgbuhttps://t.co/2xnYnyrjFp

— David Smith (@Catfish_Man) March 5, 2019
FavoriteTweet  Catfish_Man 
march 2019 by mjtsai
Twitter
I did the inverse of this. People kept messing up the copy of Escape Velocity on the school computer, so I renamed and re-iconed ResEdit to look like a data file, and put a little program that asked for a password then said “wrong password” in its place.https://t.co/Szbzf3r3D9

— David Smith (@Catfish_Man) February 23, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
In particular:
• A second reference count for unowned references is kept
• The object’s deinit runs when all strong references are gone, but it isn’t actually freed until unowned ones are too!

(Yes, unowned references still pay for atomic math; unowned(unsafe) avoids that)

— David Smith (@Catfish_Man) February 22, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
I’ve seen some confusion about this recently, so figure it’s worth discussing: ‘unowned’ in Swift is *not* like __unsafe_unretained in ObjC, and actually is pretty odd.

The difference is just that unowned deterministically guarantees a crash if misused, but that requires a lot:

— David Smith (@Catfish_Man) February 22, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
“Happy code paths are all alike; every error path is unhappy in its own way.” - Tolstoy on Swift error handling

— David Smith (@Catfish_Man) February 21, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
My favorite variation on this thread is when the shadow-IT is because the project was considered too secret to tell IT about, so the people working on it set up their own parallel version of everything on some random machine in a corner https://t.co/rvjDnKxfJz

— David Smith (@Catfish_Man) February 12, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
(+alloc/+allocWithZone: on the other hand can be short circuited, so the full transformation from [[…alloc] init] to objc_alloc_init(…) is both a time and space win)

— David Smith (@Catfish_Man) February 8, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
This is such an interesting compiler optimization. *Unlike* retain and release, -init isn’t short-circuitable, but turning [objc_alloc(…) init] into a function that does exactly that is still worth it just to save the code size for the method call.https://t.co/83bFDre9C7

— David Smith (@Catfish_Man) February 8, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
A persistent problem with trying to mitigate computer related risk is that effect size and mistake size are barely (if at all) correlated.

Automated checkers (types, fuzzers, sanitizers, static analysis, etc…) are interesting partly *because* they’re not focused on big mistakes

— David Smith (@Catfish_Man) February 5, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
I feel like there should be an addendum to that: “most code contains no such loops”

— David Smith (@Catfish_Man) February 5, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
Anyone have recommendations for *quiet* USB-C external hard drives? Ideally inexpensive. Speed/capacity not essential, it’s a backup drive for not-data-heavy people.

— David Smith (@Catfish_Man) February 5, 2019
FavoriteTweet  Catfish_Man 
february 2019 by mjtsai
Twitter
What I’m getting at is that we’ve been discovering that the inherent costs of multithreading are a lot higher than they look in microbenchmarks (because microbenches hide cache effects and keep thread pools hot). A lot of iOS 12 perf wins were from daemons going single-threaded.

— David Smith (@Catfish_Man) January 5, 2019
FavoriteTweet  Catfish_Man 
january 2019 by mjtsai
Twitter
Yeah, this made me nervous with the now-defunct attempt to make cfprefsd use one workloop for all requests too. "Does a case exist where one request will be abnormally slow in a way that's harmless to other clients?" is a hard question to answer sometimes.

— David Smith (@Catfish_Man) January 5, 2019
FavoriteTweet  Catfish_Man 
january 2019 by mjtsai
Twitter
btw on the subject of “should I use NSOperationQueue or libdispatch”, since it came up, my concrete recommendation is: you should really strongly consider not writing async/concurrent code.

I know this sounds weird in 2018, but the cost in complexity *and* performance is high.

— David Smith (@Catfish_Man) January 5, 2019
FavoriteTweet  Catfish_Man 
january 2019 by mjtsai
Twitter
One of the things that makes NSOperationQueue vs dispatch tricky is lack of historical context in most documentation. There’s a tendency to assume “NSOQ must provide a lot of value, or why would it exist?” that doesn’t take into account that it predates libdispatch.

— David Smith (@Catfish_Man) January 5, 2019
FavoriteTweet  Catfish_Man 
january 2019 by mjtsai
Twitter
Something I wish got more weight in design discussions (say, of programming languages) is the tendency for unintended consequences.

“Make this empirically revealed user scenario wonderful” is great, but what was the impact on everything else? Special cases hide surprises.

— David Smith (@Catfish_Man) December 27, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
A remarkable number of things I’ve learned in my years here boil down to “I emailed Greg with a ‘clever’ idea and he patiently explained why it wasn’t as simple as I thought”.https://t.co/S17XFx3WGa

— David Smith (@Catfish_Man) December 22, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
I was using ptr.pointee = bridged, which carefully tried to destroy the “current” value at that location first. Switching to ptr.initialize(from:) got me the “no just retain the new value and splat over what’s there, it’s fine” that I wanted.

— David Smith (@Catfish_Man) December 13, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
Got a nice perf win for NSDictionary -> Swift.Dictionary bridging (and as a result, Codable decoding) via a new Dictionary initializer from @lorentey and some ARC help from @gottesmang :Dhttps://t.co/vsJeWrz5dl pic.twitter.com/OEHytdwWUD

— David Smith (@Catfish_Man) December 13, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
This is pretty much why we’re un-inlining as much stuff in the Swift stdlib as possible. Every implementation detail that’s not ABI visible is a detail that gets to *stay* an implementation detail rather than being de-facto API.

— David Smith (@Catfish_Man) December 12, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
Right, similar to C++ template instantation. Swift’s decision to provide non-erased generics across module boundaries without mandatory inlining is *really cool* but also it’s pretty clear why most languages don’t do that.

— David Smith (@Catfish_Man) December 8, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
Allocation 2%
Copying 5%
Refcounting 8%
Generic Metadata Lookup 3600%
Miscellaneous 1.5%

someone who is good at the programming please help me fix this. my bridging code is dying

— David Smith (@Catfish_Man) December 8, 2018
FavoriteTweet  Catfish_Man 
december 2018 by mjtsai
Twitter
This String.utf16 speedup from @Ilseman is excellent :Dhttps://t.co/UbeWUyt9y7

— David Smith (@Catfish_Man) November 29, 2018
FavoriteTweet  Catfish_Man 
november 2018 by mjtsai
Twitter
Oh and this isn’t particularly unique to software, it applies to basically every task. Find anything worth doing and you can sink decades into learning how to do it better.

— David Smith (@Catfish_Man) November 20, 2018
FavoriteTweet  Catfish_Man 
november 2018 by mjtsai
Twitter
I see today we have discourse about which kinds of software are hard to build.

All of it.

If you disagree, I invite you to pick an area and be the first person in history to get it right.

Decontextualized solutions with no real world requirements are easy, sure. But who cares?

— David Smith (@Catfish_Man) November 20, 2018
FavoriteTweet  Catfish_Man 
november 2018 by mjtsai
Twitter
Not sure if anyone is able to process tech stuff right now, but here’s the results of my initial String bridging perf workhttps://t.co/DxGGTfPbR6 pic.twitter.com/giMkkbe749

— David Smith (@Catfish_Man) November 7, 2018
FavoriteTweet  Catfish_Man 
november 2018 by mjtsai
Twitter
Security fixes in 10.14.1: https://t.co/OOUxmaN93v

I count 22 “memory corruption” and 3 “overflow”. Memory safe languages can’t become widespread fast enough.

— David Smith (@Catfish_Man) October 30, 2018
FavoriteTweet  Catfish_Man 
october 2018 by mjtsai
Twitter
Yup. The limited form of it in use now explicitly budgets write cycles.

— David Smith (@Catfish_Man) October 19, 2018
FavoriteTweet  Catfish_Man 
october 2018 by mjtsai
Twitter
Idle reminder that NSDictionary/NSMutableDictionary are quite a bit faster and more memory efficient than their CF counterparts, *even when accessed via the CF API*

— David Smith (@Catfish_Man) October 16, 2018
FavoriteTweet  Catfish_Man 
october 2018 by mjtsai
Twitter
https://t.co/PHnUqeJUxK

A parable of sorts: NSBundle used to be clever and slip its refcount in among some flags to save memory. Sadly, the bitshift to get to it was off, so -release multiplied its refcount by 2.

Were the apps that broke when I fixed it the buggy ones?

— David Smith (@Catfish_Man) October 12, 2018
FavoriteTweet  Catfish_Man 
october 2018 by mjtsai
Twitter
I feel like they're underselling the 30% faster app launch thing. That's not (generally) something you can throw a dedicated accelerator at. You just have to go faster.

— David Smith (@Catfish_Man) September 12, 2018
FavoriteTweet  Catfish_Man 
september 2018 by mjtsai
Twitter
You can tell someone’s been hanging around compiler people too much when they say “uninhabited bit patterns” instead of “invalid values”

— David Smith (@Catfish_Man) August 17, 2018
FavoriteTweet  Catfish_Man 
august 2018 by mjtsai
Twitter
Lock ordering bugs are maybe the most fairytale bullshit bugs I see on a regular basis.

“ok there’s two locked doors”
“right”
“everyone must open the left one first, then the right one”
“what happens if someone does right then left?”
“you are both imprisoned forever”
“the fuck?”

— David Smith (@Catfish_Man) July 24, 2018
FavoriteTweet  Catfish_Man 
july 2018 by mjtsai
Twitter
The token-based one is even faster apparently

— David Smith (@Catfish_Man) July 19, 2018
FavoriteTweet  Catfish_Man 
july 2018 by mjtsai
« earlier      
per page:    204080120160

Copy this bookmark:



description:


tags: