Wednesday, November 24, 2010

symbolic links on Windows

Windows "shortcuts" are not the same thing as Unix symbolic links. In fact, Windows (at least, pre-Vista Windows) doesn't have symbolic links. Bummer.

BUT - it turns out that Windows 2000 and later do have a feature called junction points.These can be used to produce the moral equivalent of a symbolic link for directories only, not individual files. Since I mostly use directory symlinks anyway, this is useful for me. Thank you, Mike Nordell, for your little makelink command line tool!

Monday, November 22, 2010

Hey - it worked!

Nearly 16 years ago, I got call more-or-less out of the blue from a fellow named Rob Utzschneider, who wanted to interview me for a parallel processing start-up named Applied Parallel Technologies. Rob and his co-founder, Ed Zyszkowski, had just received funding under the Advanced Technology Program, a program run by NIST, an agency of the U.S. Commerce Department. The intent of ATP was, " spur the development of path-breaking new technologies by providing cost-shared funding for potentially valuable but high-risk R&D projects." Over a two year period, ATP put about $1.1million into Applied Parallel Technologies (APT - confusingly similar to ATP...), which paid our salaries, bought us workstations, gave us an Internet connection and who knows what else.

Over time, APT morphed into Torrent Systems, acquired VC funding, and was eventually acquired by Ascential Software and, ultimately, IBM. The system we developed - Orchestrate - is still at the heart of IBM's Information Server software. Given its continued survival, we must have done something right.

Evidently NIST thought so, too. I just stumbled over an ATP report describing the performance of the first 50 completed ATP projects. Our work earned 4 stars - the highest possible rating - and was among the 8 top-ranked projects. The project summary brought back a lot of memories.

So - I guess that, at least in our case, a government program actually did just what it was supposed to do. The ATP grant got Torrent off the ground, and we were successful enough that venture capital followed. We built a working system that helped bring parallel processing into the mainstream. The MapReduce software used by Google is a variation on the flow-based, data parallel concepts embodied in Orchestrate.


Saturday, November 20, 2010

Doesn't anyone care?

This morning I was out in the lawn raking leaves at about 10:30 when I spotted delivery truck preparing to turn the wrong way up our one-way street (from Miller to Orchard). I yelled to him that it was a one way street, but he kept coming - and in the process tore down the phone lines that cross the street at that corner. He stopped the truck, and I yelled to him that he had taken down wires, but he ignored me, backed his truck down Orchard, paused, and then turned down Blake and left.

I went inside, discovered that among the lines he took out were our phone lines, and called the Cambridge police to report the incident. The Cambridge Fire Department promptly sent a truck out to inspect the downed lines and get them off the street.

I then called Verizon to report the downed lines, a real exercise in frustration. They force you to listen to ads for FIOS before giving you a chance to enter any options, and you're then forced through a voice response system that never offers you a chance to talk to a human. I tried contacting them on the web; that was just as fruitless. I wonder if Verizon has any clue how infuriating their customer support is.

Finally, I called back the Cambridge police department to see if they wanted any of the information I had, so they could follow up with the driver and/or trucking company. There was no interest at all.

SO - since it seems there will be no official action, I can at least publish what I have. First, the raw information:

  • License plate: MA 248 0924
  • DOT 949278
  • MC 640842
  • The truck was labeled DB Schenker and QTX, Salem, NH, and was a white box truck.
The U.S. Department of Transportation provides a lookup page for DOT/MC numbers, which provided these details on the trucking company:

Physical and
Mailing Address
SALEM, NH 03079
Phone(617) 201-0897
USDOT Number949278
MC NumberMC-640842

I got a good look at the driver, since he got out of the truck before driving off and asked me, "Is there a problem here?" in a threatening tone. He's a bit shorter than me (maybe 5'6"), mid 20's to mid 30's, black mustache, a little heavy. This was one time I regret not having a cell phone camera.

I'm still trying to figure out who, if anyone, I can report this incident to. It doesn't seem right that a guy can deliberately turn the wrong way on a one-way street, tear down phone lines, and just drive off.

Update: I filed a complaint (ID 100045255) with the Federal Motor Carrier Safety Admnistration.

Update, early January 2011: I got a response from the DOT, stating that they have opened an investigation.

Update, March 2011: I got another letter from the DOT; they are preparing an "enforcement action." Who knows what that means, but it should at least get the attention of the trucking company. Sometimes the system does work!

Thursday, November 11, 2010

C++ exceptions and dynamic loading

[Note: non-geeks can click away right now...]

I just spent a chunk of my afternoon trying to figure out why my C++ exception handlers were not being invoked on Linux, using g++. I could see the exception being thrown in the debugger, but the catch block that caught the exception was the "catch(...)" block, rather than my type-specific block.

It looks like it's a problem with the g++ exception mechanism. What appears to be happening is that the selection of the catch block uses the addresses of type_info blocks, rather than string comparisons on the exception names (which, I've been led to believe, is what Visual Studio C++ does - where my code works fine). If you are using a dynamically loaded module, and there are multiple copies of the RTTI information (easy to do if you are statically linking some libraries, which I am...), and you throw across the loaded module boundary, SPLAT!

This mailing list thread helped me figure this out. I learned a few other useful factoids in the process:

  • gdb's catch command makes it easy to break on exceptions being thrown and caught:
    • catch throw
    • catch catch
  • It's possible to dig around in the g++ runtime system within the body of a catch(...) block and get to the type_info for the exception, which will give you a (platform-dependent) type name - handy for a debug message.
Thank you, web denizens...

Tuesday, November 9, 2010

Algorithm 199

I'm blogging this just so I don't lose this useful reference to CACM Algorithm 199, a magic set of routines for converting between Gregorian (calendar) and Julian dates. Someday I'd love to read the original article and find out where all the magic numbers come from.