Older blog entries for pphaneuf (starting at number 234)

News from the evil empire

Team at Microsoft switches from Visual Source (Un)Safe to Subversion. That must be a relief!

Polling is evil

Yeah, nothing new under the sun, but more whining about the evil of polling from Jeff Darcy. I'm fighting polling issues in our code, so maybe that post just touched a sensitive thing for me, but still, people, be careful when you design your protocols!

The joy of being dumb

From a blog I started reading not very long ago, called Creating Passionate Users, a post on how being clueless can sometimes be an asset. While I think that might be a bit of an exageration sometimes, I do feel that my greatest strength as a software designer isn't so much large amounts of creative genius, but rather an ability to approach problems from different angles.

Sometimes, I find an angle where everything makes more sense and is much simpler to explain.

I often say that the reason I'm such a genius at finding simple, general solutions is because I'm not smart enough to understand the complex, non-general solutions. I have to make things fit into my brain, so I work hard on make them smaller, until they do fit.

More Tim Bray on PHP

I made mention of Tim Bray and PHP. He's talking about PHP some more.

I'm still on the side of being completely appalled at PHP. Quoting of script parameters and spotty support for placeholders in SQL (maybe tied to MySQL's shoddiness, in this case), poking out like sore thumbs. The changing of language semantics between minor versions, and sometimes even with a single binary by playing with the interpreter's configuration file (a lot of scripts written for Perl 4 still work fine, and Perl 6 is being designed to continue support for existing scripts). The shoddy interpreter which doesn't cache the compiled scripts (this used to be provided by a proprietary package sold by Zend). Ridiculously silly "exception" handling (fixed now, although I wouldn't bet on the backward compatibility). The apparently endless stream of security advisories. And numerous other fun things...

I think the big break of PHP was in having an Apache module, and thus avoiding fork-and-exec costs. On older machines, this was a killer. That's it. You'd use PHP, and you could make things 10 times faster than using CGI scripts in any other language. The database integration? Let me laugh, even the much-used MySQL support is a joke compared to the ease of use of Perl's DBI.

Murder is in the air

Oracle buys both Innobase and Sleepycat. For all intends and purposes, there are two non-crap backends for MySQL, InnoDB and BDB. The former is made by Innobase, and the latter uses Sleepycat's Berkeley DB at its core. MySQL has been getting to be a pain in Oracle's butt in the last few years.

Hmm, what's that smell?

11 Feb 2006 (updated 11 Feb 2006 at 11:36 UTC) »
Interface oriented programming

My evil twin, pvanhoof, makes some noise about "interface oriented programming" which I can agree with. Regarding implementations, it makes it easier to create proxies which can do all sorts of things (including provide compatibility with a new but API-incompatible version of the API) and do more than one implementation of an API. It also gives unit tests something to bite against, making it easy to provide fake versions to test users of an API, as well, as providing a clear contract to test implementations of the API against.

But I still think he's evil. How could I not be the good twin?

SuSE uses APT

Yep, SuSE now uses APT too.

Some cool tools

Check out this demo of Shark. Quite pretty. But am I nuts or I'm still missing a straightforward strace-type tool? It's no so much for performance as for debugging...

Pain threshold

It's interesting to note how, in order to be a good person to clean up code, you need both a low pain threshold and go into the most awful code.

Maybe cleanups would be better done by a serie of incrementally more sensitive developers.

When am I?!?

From RFC 3339:

All times expressed have a stated relationship (offset) to Coordinated Universal Time (UTC). (This is distinct from some usage in scheduling applications where a local time and location may be known, but the actual relationship to UTC may be dependent on the unknown or unknowable actions of politicians or administrators. The UTC time corresponding to 17:00 on 23rd March 2005 in New York may depend on administrative decisions about daylight savings time. This specification steers well clear of such considerations.)

And steer clear you should. Fucking daylight savings.

16 Jan 2006 (updated 16 Jan 2006 at 22:21 UTC) »
Better late than never

I just discovered del.icio.us recently, and I must admit it's pretty awesome.

I don't really have huge piles of bookmarks, but something I do really often is email myself a pile of links to check out later. Then, I more or less delete stuff and lose track of it, because I feel there's just too much. When I need it again, I rely on my well-known perfect memory (NOT!) to Google it again, with rather variable results.

Now, this thing is great, for a few reasons. First, I can just never delete links, using searching and tags to find the stuff I need. Also, there is a collaborative aspect to it, when other people have bookmarked the same page, you can see what tags they used, you can see what other people have under these tags and find related resources.

They also have RSS versions of most of the pages you can look at (look at the bottom for the RSS icon), so if you're interested in someone's "bookmark stream", you can hook it up to your RSS reader. If that's too general, you can use an RSS feed for one person's tag in particular (say, my programming tag), or to the most popular links with a certain tag.

I thought that bookmarking things on their system instead of on my local browser would be more painful, but they provide a bookmarklet to make this super-easy. You can also export back to your browser.

A quick rant

Could someone tell what kind of retard thought it is ever a good idea for links clicked in other applications to replace one of your tabs/windows content?

I'm in another window, doing something unrelated. What right does it have to go and scribble over a random web page. For the ultimate insult, this is usually the latest one, so it's the one most likely to be of interest to you! Gah!

You're only allowed to trample "yourself". That is, a web browser window, when you click on a link, has perfect right to load that link replacing what you are currently viewing. Some random application shouldn't be allowed to just barf over my browser.

More details about my Ogg Vorbis/MP3 angst

In my previous entry, I mentioned that I did not envision Ogg Vorbis displacing MP3 any time soon. I should expand on that a bit.

The three reasons I like Ogg Vorbis are as follow:

  • They have higher quality for the same size, quite possibly the best music codec around with the latest improvements.
  • It is free from patent entanglement, allowing developers just like myself to develop Ogg Vorbis applications without having to deal with icky things like getting sued.
  • It does not have any DRM-related annoyances. I can listen to my Ogg Vorbis files whenever I want, on whatever device I want (as long as the device supports it, argh!).

I already mentioned the first one in my previous post. The advantage of Ogg Vorbis is too minimal for the average MP3 user to notice or care. This makes for very little pressure on the part of users. There is no clamour for higher quality audio format (as demonstrated by the fact that most people seem to put up with MP3s that are so low in quality that I would personally prefer listening to a local FM station with a strong signal), apart from a few audiophiles.

In view of this, I often try to mention you can also get smaller files with equivalent quality (so instead of an horrid 3 megs MP3, you can have an equally horrid Ogg Vorbis for only a bit over 2 megs!). But as time goes on, things like broadband and BitTorrent are making that kind of difference irrelevant to users.

Oppose this to the PNG crowd, who could immediately show web sites looking incredibly better, therefore gaining a huge amount of traction with web designers, who then pressured the browser developers. Things like the nice drop shadows in Google Local are based on PNGs.

For the second point, let's just say that there are people making money and would like to keep it that way. And since they are making money, they have some to spare to go and hand around to people, make their patented technologies standard, and so on. Picture a world where MPEG4 would use Vorbis as it's General Audio codec. But no, that's not happening, it's a patent-covered AAC instead.

These two, in themselves, is definitely making this a up-hill battle, but the last point is no less of a hurdle. In fact, it might be the worst thing.

Just about everyone related to moving music files around (legally, anyway) wants DRM. They hate MP3 for not having DRM, and would not support it if they could afford to. In this situation, MP3 is the "open" choice!

It could go either way. If music buyers would get a bit more pissed about DRM, and would start rebelling against it, one could point to Ogg Vorbis as a DRM-free high quality format (people put up with a lot when the music is free, but if they pay for it, I'd venture that they're rather have it in the best possible quality).

But let's say that I'm not holding my breath.

5 Jan 2006 (updated 5 Jan 2006 at 10:40 UTC) »
Oh, cool! But... no!

It seems that Fluendo just posted some job openings in France! But damn, it's in Lyon, not Toulouse!

Ogg Vorbis/MP3 angst

I'm having music codec angst. I'm a supporter of Ogg Vorbis, having all my music ripped in that format, buying and recommending hardware that supports it, but I'm growing tired. I just don't see it displacing MP3, not in a long time. I was going at this a bit like the old PNG/GIF war, but PNG had definite tangible advantages for web designers (the killer one, alpha channel, allowing proper shadows and antialiasing). Other than the moral rightness, Ogg Vorbis is, well, only very slightly better, and then, only if you listen super-carefully (I can tell the difference, but most people can't be bothered) or is slightly smaller (this is getting irrelevant,as I'm seeing people rip their stuff to FLAC nowadays, and bandwidth is plentiful).

I think I'm still sticking to Ogg Vorbis for now, but I am growing tired and weaker in my resolve.

Optimization and ease of use

I tried some optimizations to XPLC, but I seem to have failed. The code is bigger and the memory usage is bigger. It's possibly very slightly slower too, but it's doubtful. There is some non-trivial improvement in ease of use close at hand, though, so I'll keep this around to play with some more. It's a tough call, though...

225 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!