|
Isaac Leonard
@
is8ac
@is8ac@mastodon.social
|
|
Rust user, ML dev
|
|
|
207
Tweets
|
166
Following
|
11
Followers
|
| Tweets |
| Isaac Leonard retweeted | ||
|
David Chapman
@Meaningness
|
Jan 9 |
|
.@slatestarcodex is an extraordinary, massive, persistent force of nature, like Jupiter’s Great Red Spot or something.
Read his decade in review and be gobsmacked: slatestarcodex.com/2020/01/08/wha…
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
In conclusion: Current software has increased binary size and memory usage in exchange for security and performance and developer convenience.
(Even taking all this into account, it is still inexcusably large, broken and insecure.)
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
To take the example of the Gboard apk:
Compressed, the APK is 61 MB.
Inside it, the big things are:
28M: libintegrated_shared_object.so which appears to handle speech recognition.
48M: res/* which contains lots of *.xml files which are actually binary. Dictionaries perhaps?
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Build times:
Modern compilers do more work.
Some people do care about build times.
Go and Swift build fast.
Rust release builds relatively slowly, but `cargo check` is fast. They care about build times: perf.rust-lang.org blog.mozilla.org/nnethercote/20…
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
This introduces overhead and increase latency. Latency cannot be masked by better hardware because CPU speeds are not increasing very much any more.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Qubes OS is an extreme case. But to a lesser extent, all modern operating systems compartmentalize their userspace software, requiring it to live in its own well protected sandbox and communicate through tightly defined channels.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
This is nice for security, (because kernel devs have so far failed at building a mainstream kernel which can safely execute malicious userspace software), but introduces significant overhead.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Modularly:
Qubes OS qubes-os.org is 4.5 GB and takes quite huge amounts of RAM. Why does it need to be so large? Because it runs each group of applications in its own VM with it's own kernel and root FS.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
ChromeOS is an example of what Linux can be if you do not need to maintain compatibility with other software and hardware.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Backwards compatibility:
Linux is big because it maintains compatibility with a older APIs. I assume Windows is similar. Redox OS redox-os.org is 49 MB for a full GUIed OS with a few basic applications. It does not support existing software however.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
[2]: Rust provides automatic memory management without a GC by means of a barrow checker. New Rust devs spend the first few weeks fighting the barrow checker, and often just copy memory to avoid it (which increases memory usage again). Swift uses reference counting.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Until recently[2], the primary way to achieve automatic memory management was garbage collection. This introduces CPU and memory overhead.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Memory usage:
If a programmer manages memory manually, they will introduce memory corruption bugs, some of which be security vulnerabilities.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Swift chose to have fast compile times and small binaries, at the expense of performance. Rust chose to have good performance but larger binaries [1] and slow compile times. gankra.github.io/blah/swift-abi/
[1]: Where large binaries means many 100s of KBs.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
If you aggressively inline your functions, you can optimize better, but then the binary will be larger.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Binary size:
There are trade offs between (performance and portability) and binary size. If you dynamically link your libraries, the binary will smaller, but if the DLLs are not present, it will break.
|
||
|
|
||
|
Isaac Leonard
@is8ac
|
Jan 8 |
|
Some thoughts:
(The following should not be taken as an apology for the current state of software development.)
|
||
|
|
||
| Isaac Leonard retweeted | ||
|
𝔊𝔴𝔢𝔯𝔫
@gwern
|
Jan 2 |
|
I had, but my next thought was "I don't understand why Shane Legg, who seems like a pretty smart guy, is so ludicrously optimistic that connectionism is going to suddenly start working when it never has before, and worth quitting a good academic career for."
Not my best call.
|
||
|
|
||
| Isaac Leonard retweeted | ||
|
Sarah Constantin
@s_r_constantin
|
Dec 31 |
|
“It would imply that there are language-like behaviors out there in logical space which aren’t language and which are nonetheless so much like it, non-trivially, beautifully, spine-chillingly like it.”
|
||
|
|
||
| Isaac Leonard retweeted | ||
|
Yascha Mounk
@Yascha_Mounk
|
Dec 21 |
|
My deep respect to @dwallacewells for reporting this news.
May all journalists writing about climate change follow his lead: The facts are bad enough to justify urgent action on climate change. Attempts to scare people into action by going beyond the science will only backfire.
|
||
|
|
||