Fish tank with Puck the Fish Fish tank with Puck the Fish Water on the floor spelling Fish
 
Programming

Will it optimize?


23/7/10

See how well you know (or can anticipate) gcc’s optimizer. For each question, the left box contains some code, while the right box contains code that purports to do the same thing, but that illustrates a particular optimization. Will gcc apply that optimization?


Labor of Division (Episode 1)


15/2/10

1321528399 is an example of a “magic number:” a number that lets you substitute speedy multiplication for pokey division, as if by magic. In this post, I become a big fat spoilsport and ruin the trick for everyone.


cdecl


12/11/09

Quick, what is “char (*(*(* const x[3])())[5])(int)?”
If you immediately blurted out “x­is­an­array­of­three­const­pointers­to­functions­returning­pointers­to­arrays­of­five­pointers­to­functions­taking­int­returning­char“, and your last name doesn’t end with “itchie,” then chances are you used my new website:
www.cdecl.org
Yes, the venerable cdecl – the C gibberish to English translator – is now online. With AJAX! Every C declaration will be as an open book [...]


I Didn’t Order That, So Why Is It On My Bill, Episode 2


17/9/09

This is the second episode of I Didn’t Order That, So Why Is It On My Bill: C++ features you never use, but pay for anyways. See episode one here.
For those who like their punchlines first: std::string is designed to allow copy-on-write. But once operator[] is called, that string is ruined for COW [...]


I Didn’t Order That, So Why Is It On My Bill, Episode 1


22/6/09

C++ features you don’t use but produce a performance drag at runtime, episode 1: Inline Functions.


Barrier


17/2/07

What’s this multithreading thing everyone keeps talking about?


0xF4EE


24/11/06

Hex Fiend is open source.


The Treacherous Optimization


30/5/06

I imagine the author of grep, Ultimate Unix Geek, squinting at vi; the glow of a dozen xterms is the only light to fall on his ample frame covered by overalls, cheese doodles, and a tangle of beard. Discarded crushed Mountain Dew – no, no, Jolt – cans litter the floor. I look straight into the back of his head, covered by a snarl of greasy locks, and reply with a snarl of my own: You’re mine.


Nest


5/2/06

How do nested functions work, and why did Apple stop supporting them?


Array


23/12/05

Our arrays, aren’t.
There, that’s known as a teaser. You see it in television all the time. “Find out which common household plant devours pets at night…but first.” And then you have to sit through and watch the stuff about Brad and Angelina shacking up / Shaq driving his new Hummer / Hummer’s [...]


Float


26/9/05

Why now?
My friend over at SciFiHiFi suggests that Microsoft likes trees, but Apple likes hash tables. Well, I think that Microsoft prefers integer arithmetic, while Apple (or at least Cocoa) likes floating point. Here’s a bunch of examples I found:

Take color. Microsoft’s API (you know, THAT one) makes colors from integer components, [...]


objc_msgSend


1/8/05

Over an average of three runs, I benchmarked 25681135 messages a second. All right. Let’s see if we can do better!


Compiled Bitmaps


22/6/05

But how can you compile a bitmap? And is there any value remaining in this technique, or should it be left in the dustbin along side TSRs and DOSSHELL? Let’s find out!


Nil


29/5/05

What does sending a message to nil do in Objective-C? What value does it return? You probably know that if the method is declared to return an object, you get back nil, but what if the method is declared to return a char? An int? A long long? A float? A struct? And how does [...]


 
Mac OS X

Bridge


9/9/06

Mac OS 9 and NEXTSTEP were like two icy comets wandering aimlessly in space. Neither was really going anywhere in particular. And then, BANG! They collide, stick wetly together, spinning wildly! Thus was born Mac OS X – or so the legend goes.


Hex Fiend 1.1


24/8/06

Spiffy! Hex Fiend version 1.1 is ready. Hex Fiend is my fast and clever free hex editor for Mac OS X. New stuff:

Horizontal resizing
Custom fonts
Overwrite mode
Hidden files
Lots more goodies (see release notes)

Hex Fiend 1.1

May you find it useful!

Wake up.
Ssnsnrk.
Wake up, he’s gone.
Zzzz…wha? Oh, someone’s here. Allow me to spin up.
….….….….….….….….….….
If [...]


…and statistics


16/5/06

Here we go again


Hex Fiend


28/3/06

One of my side projects has born some fruit. Introducing Hex Fiend, a new hex editor for Mac OS X.


Mystery


3/6/05

I’m sure you’ve seen it too, ’cause it was on Slashdot and if you’re fishing here, you’re definitely an online junkie. I’m talking about that Anandtech article, of course. The one that tries to compare OS X to Linux and a PowerPC to an x86. Lemme see…this one. No more mysteries, [...]


 
Uncategorized

I’m Bringing Hexy Back


31/7/09

Hooray, it’s Hex Fiend 2, a nearly complete rewrite of Hex Fiend that incorporates even better techniques for working with big files. Hex Fiend is my fast and clever hex editor for Mac OS X.
Click On Me To Get Hex Fiend
This app is about exploring the implementation of standard desktop UI features in the [...]


Roundy


1/6/09

As any usability expert will tell you, the foundation of sound web page design is rounded corners. Their smooth curves lend an organic, almost sensual feel to a site, while pages without rounded corners are completely un-navigable morasses of right angles.


Buzz


25/4/07

Farewell, Buzz


Angband


13/4/07

So Angband iss back – so fissh, the fish, raw and wriggling, he hasst brought its back!


Logos


11/12/06

Hair care, or digital audio?


Spam


9/8/05

Well, they found me. I knew it was only a matter of time. It happens to every blog. Comment spam, and a lot of it. But nobody told me it would be like this! I got about 200 messages an hour. I mean, the attention is flattering, but still, [...]


Daybreak


25/5/05

I’m a developer on Apple’s AppKit team; I work to make Cocoa better. With a few exceptions, we are responsible for both AppKit and Foundation. This is my blog.
You can contact me at corydoras@ridiculousfish.com
Description forthcoming.