Archive for 'random'

Uh-oh, this can’t be good

Can this lead to anything good when I’m starting to write lines like this myself?

my $filter = join ‘ and ‘, map { “agr.$_ = $temp.$_” } split(/, /, $fields);

I know, it’s not that scary, and does not involve even a single regexp, but still…

It must be a bug in OS/compiler/…

Ever looked at the code which is absolutely correct, yet runs incorrectly? Sometimes it looks like a genuine compiler bug. “I swear, mister! The compiler corrupts my code!”

Look again. And again. Eventually you’ll find where your code is broken.

(Of course, in some cases quite often the compiler is broken… GLSL, anyone?)

Pimp my code, part 15: The Greatest Bug of All says the above in a much nicer way:

Maybe the problem was there was some huge bug in Apple’s Mach, where if you open too many files in a short period of time, the filesystem tried to, like, cache the results, and the cache blew up, and as a result the filesystem incorrectly just would fail to open any more files, instead of flushing the cache.

I’ve also been around long enough to know that whenever I know the operating system must be bugged, since my code is correct, I should take a damn close look at my code. The old adage (not mine) is that 99% of the time operating system bugs are actually bugs in your program, and the other 1% of the time they are still bugs in your program, so look harder, dammit.

A post well worth reading… about the process of investigating tricky bugs. And sincere as well. It’s so good that I’ll just quote it again:

It’s a bug we should have caught. We should have spent the time to get the images in the 10,000 item file. I messed up.

Software is written by humans. Humans get tired. Humans become discouraged. They aren’t perfect beings. As developers, we want to pretend this isn’t so, that our software springs from our head whole and immaculate like the goddess Athena. Customers don’t want to hear us admit that we fail.

The measure of a man cannot be whether he ever makes mistakes, because he will make mistakes. It’s what he does in response to his mistakes. The same is true of companies.

We have to apologize, we have to fix the problem, and we have to learn from our mistakes.

So very true.

Pixar’s Brad Bird on Innovation

Here: Pixar’s Brad Bird on Fostering Innovation. Pretty good.

Invincible shutdown buttons!

I booted into Vista yesterday to test something. It offered a bunch of updates to install. After they were installed, I got this:

Invincible buttons

I am not sure what shutdown buttons do when they look like this. I guess they are invincible, or something. Ha, I’m your log off button! You can’t kill me!

Yes, one of the updates installed was the ATI driver update, so I guess there’s some glitch somewhere in the driver update that makes some buttons be displayed like this… But hey, this is not some random driver that I found on the net, it’s the one that is officially suggested by Vista’s update!

I can has vertex?

I can has vertex data?You know something became a cultural phenomenon when hardware review sites start putting up images like this…

From AnandTech’s Radeon HD 4850 & 4870 review: I can has vertex data?

Edit: gee, nowadays the reviews have funny performance measures. Like, FPS per square centimeter (of GPU die size)! It does actually make (some) sense, but it’s still funny. Frames per second per square centimeter… mmm… delicious.

Lolshadows strike again

Continuing the old theme

CAN I HAS MOIRE SHADOWS

CAN I HAS MOIRE SHADOWS?

One-liners: biawesome filtering

Said by Jonathan Czeck of Graveck:

What kind of filtering does Resize() function use? Nearest-neighbor, bilinear, bicubic, biawesome?

Since then “biawesome” became a local meme at work. Biawesome is awesome on steroids.

New random blog

As if the world was not a bad enough place – I put up a new blog about Random Stuff. It’s in Lithuanian and is mostly about that “life” stuff; no triangles there.

Here it is: aras-p.info/blogas

My experience with Crysis so far

So I decided to check out Crysis myself. A demo for a non-gamer like me would be perfect, I thought.

It’s probably three frames per second. In the menu!

I did not see the game itself yet, got bored while waiting for the after-menu-but-before-game intro movie to end (it’s not skippable, and it also ran at about three FPS). This is after watching half a dozen obligatory before-menu intro movies at 3 FPS with stuttering sound (“nvidia,vidia,vidia,vidia… the way it’s meant,meant,meant,meant…” – TWIMTBP).

All of this on a half-decent PC, I think – Intel Core 2 Quad, 4GB RAM, Radeon 3850, Windows XP, latest drivers, none of extra stuff running; the PC is able to run other 3D stuff just fine. I’m sure the developers and EA’s testing labs have tested everything extensively, but sometimes something completely random apparently can make things be oh so slow. Oh well. Get back to work.

What if eyes were orthographic?

Yesterday at work we had some small discussion, involving something about projecting things behind the near plane onto the near plane (don’t remember what exactly). It went onto “now that you look at something, you see this, and this is because the eyes are perspective, not orthographic, and …”. And then it struck us:

What if the eyes were orthographic?

Think about it…. that would be totally weird!