Lippard.Multics 1986-10-13 16:29:06 mst Mon Subject: Automatic Rebinding Date: Wednesday, 8 October 1986 12:52 mst From: Barry Margolin To: {mbx >udd>m>jjl>misc>misc} or: But I never learned to bind a manual... Stephen Robbins Dear Mom, It's hard being a dynamic linker. People want me to do so much work for them. And then they get upset when I follow their instructions to the letter. Sigh. So to "solve" my having done something RIGHT, they complicate my job AGAIN. I wish I had taken your advice and become an airline reservation system. The job started out great. When someone wanted to call procedure "B", they'd call it first with a dummy address. I'd notice, of course, and load in the REAL routine "B." Then I'd replace the dummy pointer with the B's real entry point. After that, things'd run fine. Since I'd keep the real pointer in my reference name table, I could look up "B" real fast the next time. I was consistent, too. "But what about recompiling?" they started to protest, "If B's address changes, things will stop working!" Hell, I get things right the FIRST time. If I didn't I wouldn't keep my job long. But if THEY don't I'm expected to cover for them It burns me up! I had to solve THEIR problem. Along with the routine entry point in my reference name table, I started keeping a pointer to a block of memory. In that block of memory I'd put the address of every reference to "B" I had resolved. Then on demand, I could update all the references. Did they appreciate that? No. "Too much wasted space!" they cried. Or sometimes, "There's not enough room to record all my references to B!" Sheesh. So I tried something else. I got together with the compiler and had her generate all indirect calls. Instead of resolving "B" to point to the routine itself, I had it point through an indirect entry in my reference name table (where the pointer to that block of memory used to go, in fact). So when they recompiled "B," I'd just change that entry. Voila! All their calls went to the new "B." Were they satisfied? Of course not. After that, all I hear is, "Procedure calls have slowed down!" Don't they understand time-space tradeoffs? Mother, there's just no pleasing some people. I've been thinking about it carefully, and I'm coming home. Please fix up my old address space; it'll be great to see you again! MULTICS [sic] just isn't the place for me. Love, Your son, D. Linker.