this post was submitted on 01 Apr 2025
514 points (97.8% liked)

Technology

68495 readers
4000 users here now

This is a most excellent place for technology news and articles.


Our Rules


  1. Follow the lemmy.world rules.
  2. Only tech related news or articles.
  3. Be excellent to each other!
  4. Mod approved content bots can post up to 10 articles per day.
  5. Threads asking for personal tech support may be deleted.
  6. Politics threads may be removed.
  7. No memes allowed as posts, OK to post as comments.
  8. Only approved bots from the list below, this includes using AI responses and summaries. To ask if your bot can be added please contact a mod.
  9. Check for duplicates before posting, duplicates may be removed
  10. Accounts 7 days and younger will have their posts automatically removed.

Approved Bots


founded 2 years ago
MODERATORS
top 34 comments
sorted by: hot top controversial new old
[–] lud@lemm.ee 9 points 6 days ago (1 children)

What's the Weissman score?

[–] fatal_internal_error@lemmy.world 3 points 6 days ago (1 children)

So it’s gonna be a dick measuring contest?

[–] agelord@lemmy.world 1 points 6 days ago

I'll measure the most.

[–] L3s@lemmy.world 7 points 6 days ago (1 children)
[–] LemmySilverBot@lemmy.world 8 points 6 days ago

Thank you for voting. You can vote again in 24 hours. leaderboard

[–] NoSpotOfGround@lemmy.world 254 points 1 week ago* (last edited 1 week ago) (3 children)

The real meat of the story is in the referenced blog post: https://blog.codingconfessions.com/p/how-unix-spell-ran-in-64kb-ram

TL;DR

If you're short on time, here's the key engineering story:

  • McIlroy's first innovation was a clever linguistics-based stemming algorithm that reduced the dictionary to just 25,000 words while improving accuracy.

  • For fast lookups, he initially used a Bloom filter—perhaps one of its first production uses. Interestingly, Dennis Ritchie provided the implementation. They tuned it to have such a low false positive rate that they could skip actual dictionary lookups.

  • When the dictionary grew to 30,000 words, the Bloom filter approach became impractical, leading to innovative hash compression techniques.

  • They computed that 27-bit hash codes would keep collision probability acceptably low, but needed compression.

  • McIlroy's solution was to store differences between sorted hash codes, after discovering these differences followed a geometric distribution.

  • Using Golomb's code, a compression scheme designed for geometric distributions, he achieved 13.60 bits per word—remarkably close to the theoretical minimum of 13.57 bits.

  • Finally, he partitioned the compressed data to speed up lookups, trading a small memory increase (final size ~14 bits per word) for significantly faster performance.

[–] ch00f@lemmy.world 42 points 1 week ago (2 children)

For anyone struggling, lemmy web interface added the colon into the URL for the blog post link. Here's a clickable version without the colon:

https://blog.codingconfessions.com/p/how-unix-spell-ran-in-64kb-ram

[–] NoSpotOfGround@lemmy.world 1 points 1 week ago

Thanks, and sorry about that! I removed the colon from near my URL now, just in case.

[–] db2@lemmy.world 24 points 1 week ago
[–] potate@lemmy.ca 6 points 1 week ago

The blog post is an incredible read.

[–] ColeSloth@discuss.tchncs.de 101 points 1 week ago (6 children)

Old school coding and game programing was magic. The clever tricks that nes game programmers came up with to work around hardware limitations was phenomenal. It went way beyond the bushes and clouds in mario being the same thing but in a different color.

[–] sirboozebum@lemmy.world 7 points 6 days ago (1 children)

Restrictions and boundaries spur innovation.

[–] jdeath@lemm.ee 2 points 6 days ago

any constraints, really. pretty cool!

[–] Valmond@lemmy.world 4 points 6 days ago

The old scrollers in non-consoles (consoles had hardware scrollers) used funky tech too to reduce overdraw. Fun times.

[–] xavier666@lemm.ee 38 points 1 week ago (1 children)

I am still in awe of the fast inverse square root method used in QuakeIII. Good times.

[–] VindictiveJudge@lemmy.world 5 points 6 days ago

IIRC, someone got with the author of that bit of code to ask how they came up with it, but they had simply learned it from someone else. So they tracked them down and found that they had also learned it from someone else. They eventually landed on Greg Walsh as the original author, but for a bit the code had no known origin.

[–] General_Effort@lemmy.world 12 points 1 week ago* (last edited 1 week ago)

nes game programmers

Were these guys even Real Programmers?

Here's a great talk by a guy who worked on a 1982 game for the Atari 2600, a game console first released in 1977. It's a fascinating insight into the early evolution of computing. They didn't work around limitations. They used a machine to do whatever it could.

If anyone has ever wondered by what standard C is a high-level language, this is for you. Or if you want to know how we ever could have developed something to connect the abstract logic of some algorithm with some glowing pixels on a screen.

Pitfall Classic Postmortem With David Crane Panel at GDC 2011 (Atari 2600)

There's an ancient myth that a god created the first pair of tongs. Tongs need to be forged in a smithy. Obviously, you need tongs for that.

[–] REDACTED@infosec.pub 11 points 1 week ago (4 children)

Check out demoscene. The mind-blowing things they create with only with kilobytes..

[–] xavier666@lemm.ee 2 points 6 days ago

Thanks for this. Got a burst of nostalgia

[–] noxypaws@pawb.social 1 points 6 days ago

Here's one of my recent-ish faves on GB, music is so damn catchy

https://www.youtube.com/watch?v=GleZBHhOsmE

I had a zx81, 1k ram, still could play pong.

[–] ColeSloth@discuss.tchncs.de 3 points 1 week ago

Yeah. The average NES game was only 200kb.

[–] jasoman@lemmy.world 8 points 1 week ago (1 children)

In oblivion on Xbox they even reboot the console on a loading screen to clear up ram.

[–] Romkslrqusz@lemm.ee 12 points 1 week ago (1 children)
[–] jasoman@lemmy.world 1 points 6 days ago

Thank that is indeed correct.

[–] troyunrau@lemmy.ca 72 points 1 week ago (3 children)

Long article for one sentence of trivia and no info on the algo itself. The death of the internet is upon us.

[–] adespoton@lemmy.ca 48 points 1 week ago* (last edited 1 week ago) (1 children)

Doesn’t even name the algorithm, and somehow spells LZMA wrong, despite just having written it out longhand.

Well, it’s PC Gamer.

[edit] I still can’t figure out if they’re referencing LZW encoding… the L and Z being the same Lempel and Ziv from LZMA, but with Welch having a different solution for the rest of the algorithm due to size constraints.

[–] troyunrau@lemmy.ca 23 points 1 week ago

Probably mostly AI written.

[–] GrabtharsHammer@lemmy.world 20 points 1 week ago

I'd like to imagine they took the short trivia fact and applied the inverse of the compression algorithm to bloat it into something that satisfied the editor.

[–] rice@lemmy.org 7 points 1 week ago

The blog post it links to has all the info, but it is more of a series of changes to the dictionary instead of 1 set thing

[–] SirFasy@lemmy.world 11 points 1 week ago

If it aint broke, don't fix it.

[–] 0x0@programming.dev 1 points 1 week ago (1 children)

Only 1 GiB of RAM? Moooom!
Shut up Johnny, Voyager's still out there with way less.

[–] rmuk@feddit.uk 2 points 6 days ago

Yeah, but I've not got two hundred Firefox tabs open on Voyager.