Older blog entries for ncm (starting at number 101)

28 Mar 2004 (updated 28 Mar 2004 at 23:43 UTC) »

I was at the office with a colleague who has used Java in earnest on contract projects, when we saw the announcement that IBM had Freed their Jikes RVM. I started poking around to find out what it was, and when we finally uncovered the secret, we both laughed and laughed. You have to thankful for anything that yields such harmless mirth.

Lots of people code in Java, and probably lots more in Visual Basic. One can't sneer at the one without sneering at the other; they do get work done that they might otherwise bother me to do, so I have to be thankful for that, too. Hence, it does matter how easy it is to code for GNOME in languages like them. Mulling that over, I realized that the most effective way to make it easy to use GNOME in Java programs would be to change the Makefiles for core GNOME so that they are all compiled with G++. Then, just make sure all the callback sites (and sites those are called from, on up the line) are exception-safe.

After that, it only takes trivial (maybe automatically-generated) stub libraries to make the GNOME libraries safely callable from Java programs built with Gcj; the callbacks can throw exceptions right through GNOME back to the main program. Hack up a (minor) variation on Gcj to make it compile C# instead, and then C# integrates trivially, too, and offers an easy out once MS starts swinging the patent hammer. (Maybe Gcvb would follow, may-God-have-mercy.) My feeling, though, is that this all makes way too much sense ever to be embraced by the people who actually like those languages. Meanwhile, I suspect too many of the GNOME core people are too superstitious ever to use G++, for any reason.

Despite tromey's misgivings about Gcj-3.4, I think G++-3.4 will be the best release yet, and its iostreams will be faster than Glibc's stdio. (Thank Paolo Carlini, Petur Runolfsson, and Jerry Quinn for the latter.)

Tom, by the way, appears to be among those who wildly overestimate the value of the Java-1.5 "generics" feature. It's more akin to Ada's than to C++'s, which means that it adds only checking, but not expressive power.

In recent weeks I've been getting almost 1000 viruses a day in my e-mail, with improbably many of the forged "From:" addresses matching Gcc mailing list members. I'm beginning to suspect it's a deliberate DDOS attack. (Spam is nowhere near so heavy, for me, and although the viruses are easily filtered out, the bounce messages are less so.) Has there been any discussion of this elsewhere?

Linux-2.4.6, gnome-panel, Galeon, and Evolution are still working fine for me, mostly, except for the persnickety ALSA sound system. Orkut "I hate Java" membership is at 394, vs. "Lisp" at 389. "Lisp" will catch up, I'm confident. I should have kept a daily graph.

21 Mar 2004 (updated 21 Mar 2004 at 19:12 UTC) »

Who would have thought there was something new to say about discrete finite automata? Evidently until now only Boris Alexeev (scroll down just a bit).

Anybody can write a Scheme interpreter in Scheme, but that's no great trick: I can turn my car into a car without even a wrench. If you want to impress me, write a Haskell compiler, as a set of ".h" files, that runs in any C++ compiler's template evaluator, and toss in the entire Haskell standard library, and make it practical to use for writing real, almost pretty, programs. (Too late, it's done.) I am obliged to mslicker for drawing my attention to a wholly remarkable paper: Syntax Sugar for FC++: lambda, infix, monads, and more. Of course the library it describes is available under a liberal license.

Membership in Orkut "I hate Java" first caught up with "Lisp" at 284. Now they're both at 365, and still tracking. Amazing. Then again, there's Limecat, who is manifestly displeased, so who knows anything?.

Thank you and congratulations, bagder, on your 79th cURL release. Your work matters.

Everything is still working -- Galeon, Evolution, gnome-panel, linux-2.6. After I suspended my laptop to disk, though, and turned it back on, I had to reset the ALSA/ES1978 driver. Tsk.

17 Mar 2004 (updated 18 Mar 2004 at 03:54 UTC) »
Seagulls circling in a blizzard is not something I ever expected to see out my office window.

Wonderful news... It looks as if the Gcc project plans to commit, finally, to a compiler-and-library C++ ABI, coincident with the release of gcc-3.4 this month. That means code built with any g++-3.4.x (or 3.5.x, hopefully) compiler, and linked against the corresponding libstdc++.so, will be upward link-compatible, just as code linked against any Glibc-2.x can dynamic-link to any later Glibc. If it's not obvious to you why this is big news, think how much trouble it is to get a whole bunch of different libraries built with the same compiler dot-release as the program you hope to run that depends on them.

This ABI eliminates the biggest single impediment to a lively bazaar in C++ libraries. Writing powerful libraries is what C++ is really all about; the STL was just a first step. Now the trick will be to get all the GNU/Linux distributions to ship libraries built with that version, so that C++ binaries might be compatible across distros without needing to be static-linked. (Debian will need pushing, particularly.) Meanwhile, our own murrayc's GNOME C++ bindings are now mature enough to make C++ GNOME programs as compile-time-safe, and convenient, as with any native C++ GUI toolkit.

Bad news... First Miguel, then ESR, and now Havoc. Sigh. What is it about marketing scams promoting proprietary software deployment vehicles that they so easily take in Free Software spokesmen? Free Software has achieved all it has, exceeding by far every conventional expectation, without such dubious help. Suddenly, running on a slow, memory-hungry, buggy, untuneable "platform" capable of supporting only crabbed imitations of native languages is the modern, high-level way to do software development. C++ has somehow become indistinguishable from C, and incapable of high-level-itiveness, whatever they imagine that to be. Weird. At least Havoc isn't on his knees begging favors from Scott McNealy.

Good news... I upgraded my gnome-panel and metacity packages, and now the panel auto-hides correctly, again. Yay somebody! Linux-2.6.4 is still working fine. Evolution started crashing, but stopped when I upgraded to a binary built against the new GNOME libraries that came in with the panel upgrade. Galeon still isn't leaking zombie threads, despite my wife's assiduous eBayage. Another milestone: I have finally deleted all my old Netscape 4 binaries.

This is the funniest thing I've seen since Why's (Poignant) Guide to Ruby: Understanding Object Oriented Programming. This one's not intentionally funny, though, which makes it even more so. (Note: that the examples are Java is surely only incidental.)

Finally upgraded to linux-2.6.4, from 2.4.21-pre5-ac3. I think this was the longest I have ever used one kernel, eleven months. It all went surprisingly smoothly: the only hiccup was when the hotplug daemon startup script hung during boot (in the pci hotplug section -- nil, since I have a laptop) until I hit ctrl-C, and then startup resumed. Everything seems to work, and it swaps a lot less. I plugged in a USB mouse, to see what would happen, and it Just Worked.

lindsey and cactus: What C# calls "properties" are what most people call hints of bad design; that is, if you have enough of them in your code to benefit from automation, you probably have way too many. That said, I'm saving off cactus's example. (About Shakespeare: I would leave out the <speaker> element entirely, and just add an "id" attribute to the <speech> element instead. No point in repeating the speakers' written names throughout the document.)

Am I corrupted yet? I have used Gaim as an IRC client to talk with graydon and others about Monotone implementation details.

Membership in my "I hate Java" community on Orkut has tracked the "Lisp" community's, almost exactly, ever since it first caught up. Probably every member of each ought to be a member of the other too. It's a shame that the similar experiment here didn't, ultimately, work out -- Advogato article threads are too susceptible to trolling -- although it did evoke a few memorable lines.

Listening to Supersuckers, "Must've Been High" (I used to think I hated country music; so did they, I think) and Satan's Pilgrims.

Before I rebooted into 2.6.4, I upgraded to the latest mozilla library dpkgs, which made galeon and firefox not leak zombie children any more. Happy day! Nothing I run crashes or leaks too badly any more.

29 Feb 2004 (updated 3 Mar 2004 at 03:51 UTC) »
Monotone

In the coming Source Code Control wars, with Subversion and Arch squaring off, the dark horse (if I may mix metaphors) looks to be Monotone, by our own graydon. Such beautiful code, such spare design. Why not pitch in and help by giving it a "blame" command, or perhaps a web view? Just to touch such code will exalt you.

A Proud Moment

As of this moment, the Orkut group "I hate Java" has 284 members, identically with the "Lisp" group. In other words, right now, and maybe never again, precisely as many people hate Java as like Lisp. Who knows what the future holds? Will the next year bring more Java haters or Lisp likers? Will Orkut survive that long? Will Java?

People posting are finally beginning to catch on to what these "I hate ..." groups are for, and it's starting to get fun. (What could be more dreary than somebody hyping their own favorite language?) It took longer than I expected, and for a while I thought the experiment had failed entirely. Score one for humanity.

Zombie Leaks

Debian unstable finally got Mozilla Firefox, so I installed it to see if it will spawn zombie processes like a parthenogenic rabbit (and like Galeon 1.3.1{1,2,3}, lately) when used to look at eBay.com. The answer is yes, which narrows the problem considerably: the fault is all Mozilla. Meanwhile, Evolution 1.4.5 (even with Bonoboized Vim as its editor!) hasn't crashed in many weeks.

18 Feb 2004 (updated 8 May 2006 at 19:55 UTC) »
whytheluckystiff's Ruby book (really, a long article) made me laugh more than anything I've seen in a long time. Chunky bacon!

The Open Source world (or, anyway, the Open Source Initiative, or maybe just ESR) is in pretty sad shape when it finds itself pleading with some rapacious corporation to free a stupidly-designed language created, in the first place, just to attack some other even-more rapacious corporation. Sun is free, and welcome, to make itself irrelevant to Free Software, and the world at large. It would already be forgotten if not for its multi-billion dollar bank account, which (incidentally) feeds OpenOffice and SCO alike. Java itself is already irrelevant to Free Software: Java needs Free Software, but Free Software doesn't need Java. As Sun fades from our minds, so will Java, and good riddance.

It makes me feel better to think that Free Software is not in similarly sad shape. Then I look at the Mono and dotGNU projects. They're not begging anybody, exactly. One might say, rather, that they're asking for it. I'm not sure which is worse. I guess this is what the mainstream is like: fools make themselves irrelevant, the rest of us (or "them", maybe) go about our business, and it all comes out OK, because we're not in the middle of an apocalyptic struggle any more.

Speaking of worse, I just finished the worst book I have read in years -- "Chindi" by Jack McDevitt. It's awful from the very first line: "The Benjamin ... was at the extreme limit of its survey territory". Each chapter is worse than the last, each deft touch reveals it as the more tawdry. Chapters start with quotes from great but dull works of the 23rd century. The ship captain is gorgeous but unfulfilled. Every character is bored with his or her life and life's work. Reading it was like watching a train wreck. Recommended, sort of.

Orkut has got quite boring. The only thing I'm watching for now is when the membership count of the "I hate Java" community passes that of the "[I like] Lisp" community. "I hate Perl" had been tracking "I hate Java" just twelve members behind, but has lately almost stagnated. Of course nobody hates Python, and probably won't until 3.0, when all the "list comprehensions" and Lispy doodads make Python programs incomprehensible. (Meanwhile, membership in "M-x viper-mode" and "I resent Lisp" creep obscurely upward. Ha ha, they have no idea what lies in store!)

Galeon 1.3.12 on my home machine is still leaking zombie processes like a parthogenetic rabbit. I have to shut it down daily when it hits the 206 mark and freezes. Oddly, that doesn't happen at the office, where I never look at eBay; evidently my wife's eBay usage triggers something nasty. Otherwise it's a great browser.

The real fun in Orkut.com is not in pestering people to be your friends. It's in creating what they call "Communities". Some seem to exist only as badges, so the icon shows up on peoples' summary page and helps to define what they're about. Others are a place to meet; e.g. there's one for my home town. I created the "I hate Java" and "I hate Perl" communities, which are both growing with gratifying rapidity, and the "M-x viper-mode" community, which remains (equally gratifyingly) obscure. (These in addition to Ogg and Advogato mentioned earlier.) It was fun constructing the icons. I couldn't see how to draw a diagonal straight line, in Gimp, so I selected and filled a horizontal rectangle and then rotated the whole thing.

Finally read Steve Martin's "Shopgirl". A real pleasure. Re-read Tom Robbins's "Half-Asleep in Frog Pajamas". (I had read it before, I think, but could hardly recall any of it. That and "Skinny Legs and All" are his best work.) Read Terry Pratchett's new "Monstrous Regiment"; not as good as "Wee Free Men", but astonishingly good nonetheless.

I'm seeing geese flying past the window, now, heading east... East?

The latest version of Galeon is out, 1.3.12. I have high, high hopes. It finally has the feature I had most wanted, Emacs edit key bindings: no more wiping out my whole Advogato diary entry with a careless ^W or ^A. With its independence from libbonobo, maybe it will not leak memory or child processes like 1.3.11a did. Evolution 1.4.5 hasn't crashed on me in a long time, gvim running under libbonobo notwithstanding.

I'll congratulate chalst again, because I doubt he was surfing Advogato the first time.

Got invited onto orkut.com, and created Ogg and Advogato interest groups before they shut down. I'm not sure what that sort of site is for, but anyway discovered that Marc Merlin works at Google. Now I know at least two people there. Coincidentally got invited onto linkedin.com, that looks almost the same in some ways, but is full of CEOs and consultants. Weird.

About layered UIs... every program of any complexity has a layered UI, regardless of its designer's intent. The subset of features that are immediately comprehensible to newbies is one. For experts, the top level UI is always hacking, whether via scripting, registry entries, or recompiling the damn program. Talk about layers is really just about adding more of them.

murrayc (and everybody else coding C++): When you mention an inherited member in a template function body, you have no choice but to prefix it with "this->", or the compiler might just go find some other object of the same name. The natural coding-style implication of this fact is that all uses of members should be prefixed with "this->". Besides making the code easier to follow, it makes for better error messages, and better error-checking. As a nice side effect, it makes it entirely unnecessary to put dumb prefixes on private member names. (Yes, it effectively adds six characters to each member name, which you might think would be a problem, but in practice it just doesn't cause any trouble.) C++98 really is a different language from pre-standard C++, and it calls for different coding practices.

22 Jan 2004 (updated 30 Jan 2004 at 02:58 UTC) »

Let me be the first to congratulate chalst on his new offspring.

slamb: Apologies for not replying sooner, about cancellation and C++. All the cancellation points defined by POSIX are C calls, which are normally declared "throw()". Built with any existing compiler (except DEC's) and C library, they unwind the stack ignoring catch blocks, thus corrupting the process state. Given a jimmied C library that turns them into exceptions, they throw past code that (either in the runtime or, if the runtime is also jimmied, in the user code) wasn't expecting any exceptions, and so probably corrupt the process state. As ought to be needless to say, a corrupt process state makes a poor execution environment for other threads. A useful response would be just to return -1 and set errno each time a cancellation point is called after cancellation, but POSIX people start shrieking ZERO UPTAKE when you mention it. They see no problem with breaking every existing thread-safe C++ library (which they assert are ALREADY BROKEN), but worry about a few vendors taking them seriously if they countenance a C++ binding that preserves existing libraries by being a little different from the C binding. Of course C++ components (e.g. filebuf) could throw, and finding errno == ETHREADCANCELLED or something ought to be cause to throw something, so cancellations should turn into exceptions pretty easily.

According to a status box posted by flphoto when it saves a rotated version of a JPEG image, it is saving losslessly. It's easy to imagine how it could do this, by rewriting headers and then rotating and transposing individual 8x8-pixel cells. This is an improvement, because I had been using Gimp, before, and it certainly does not load and save losslessly.

freetype: Have you read any Terry Pratchett? He continues to astonish with each new volume. Let me recommend the new Wee Free Men. Ach, Crivens! I wish I'd grown up with his books instead of (e.g.) Heinlein's & Tolkien's.

mallum: I have never yet encountered a dog (never mind a pug!) with palette problems. Painting, as an activity, seems better suited to cats. I can certainly imagine pugs with palate problems, though. IMHO the tendency should be culled from the breed via the time-honored method.

Is there something peculiar to participation on the GStreamer project that leads to not answering e-mail? Probably it's good, if it means they're writing code instead. E-mail is a time sink.

My birthday present (appropriately, I suppose, given Gollum's obsession) was enough hours free to see the third installment of the Jackson Lord of the Rings. (Most of what I recall from the books comes via the Harvard Lampoon parody, "Bored of the Rings", with its wee protagonists Moxie, Pepsi, Frito, and Spam.) Among the moments where suspension of disbelief failed were Merry (or Pippin?) and Gandalf bouncing instantly back and forth between the lower battlements and the palace on the hill -- with Gandalf abandoning his post just to save the regent's son, whose only evident value was as a future husband to Eowyn; the horses wading into a sea of pikemen without all being skewered in time for lunch; and Eowyn slicing through three feet of dragon neck (bone and all) with one sword stroke. Did anybody else notice that the Rohanners' only actual contribution, ultimately (besides Eowyn's solo, itself unnecessary), was to provide the new (and now redundant) regent a bride, and a job? The ghosts would have mopped the field with or without the cavalry's arrival. (This last reminds me of David Brin's critiques of Star Wars -- the Jedis never really accomplish anything, although they get all the screen time.)

I'm running Evolution with GVim as the message editor now -- A big thank you to Jason Hildebrand, jdhildeb. No crashes lately, but Evo 1.4.5 still seems to leak zombie processes. (That might be GtkHTML or something.)

Galeon 1.3.11a has the disadvantage, vs. certain earlier versions, of leaking both memory and zombie subprocesses. I am back to killing and restarting it every few days to keep my system from thrashing.

Happy Birthday to me. Turning 42 in 2004 feels oddly rectilinear and cartesian.

I finally found a program, flphoto, that does most of what I need for my collection of thousands of digital photos of my kids. (Surprisingly, it's not among the over 13000 packages in the Debian unstable archive, yet.) I needed a program to present thumbnails of a directory of images, and let me point to some of them and have it rotate them 90 degrees and write them out that way. I had thought that gphotocoll might do it, and installed PostgreSQL because it needed that, but it lacks (so far) any kind of touchup feature, although it seems pretty cool for what it does do. (Hint for those new to PostgreSQL: until you fool with permissions and config files, connect to the database with an empty hostname, not "localhost".) If I could point at an eye and click "no red here", there would be nothing left to wish for.

slamb: It's funny to read about you working on thread-cancellation-safety and C++. POSIX thread cancellation is incompatible with C++, and will be for quite some time. Based on the attitudes of the people who get to decide -- non-C++ coders all -- that may mean "forever". (It happened to Ada.) Actually, it's probably more correct to say that thread cancellation is incompatible with C, as well, because it demands coding discipline that C doesn't really support, and that has never been observed outside the Space Shuttle's autopilot. It could be compatible with C++, more or less, and with non-imperative languages (which doesn't include Lisp, but maybe with Lisp anyhow), but POSIX people seem implacably hostile to the variant semantics needed for workable non-C language bindings.

It surprises me to see people ooh-ing and aah-ing, here, over subpixel rendering. Gnome has done that for a long time (and maybe KDE too). I've had subpixel rendering on my laptop ever since I installed and configured libxft, at least in Gnome-y programs (i.e. almost everything but xterm).

All-encompassing thank-yous to murrayc, DV, Bram, bagder, redi, lerdsuwa, and joey, among others.

Galeon 1.3.11a has one new annoyance over 1.3.10: it puts new blank tabs way out at the end of the list, instead of next to the current tab.

92 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!