10 December 2013

BCPL pointers were not zero indexed because of compile time issues.

Re: Citation Needed - blarg?

Mike has done a bit of research, but not enough. Reading and understanding the BCPL manual (let alone having any experience with '60s and '70s compiler technology) would have made this jump from Martin Richard's comment (which says nothing about the cost of optimizing the code) to "in that context none of the offset-calculations we’re supposedly economizing are calculated at execution time" obviously wrong.

First, the yacht thing is a complete red herring. You always had to limit your job run times because computers were just plain unreliable. They could easily go down several times a day, forcing the restart of a job. Higher priority jobs could always show up and bump you, and getting bumped was not all that big a deal... you'd just get run again once it was done, if by chance you happened to be late in the queue you'd run a day or so later at the most... and that could happen anyway if jobs before you ran into problems or there was too much maintenance downtime. A handicapping run a few times a year? that's nothing.

Second, you could have expressions on both sides of the dyadic "!" operator. "V!I" was exactly the same as "I!V" ... Richards spells that out explicitly in the text Mike quoted! There's no reason to treat it as a compile-time-only issue.

Third, of course BCPL had pointers. It was completely typeless, an address was just a number. When you wrote


You create both a pointer variable "V" and allocated a 5 element array to it. Yes, it really allocated a total of six cells. As far as I recall, "V" could be reassigned to point to another vector, or incremented within itself.

Fourth, local variables were dynamically created on the stack. So a local


could be at any address in the stack, depending on the call history.

Fifth, and backing up my recollection in the third point, the BCPL manual has an example of pointers being initialized on page 27:


Sixth, he's applying 21st century reasoning about compilers to the '60s. When you wrote:


it's virtually certain that the compiler would actually generate the code to fetch "V" and add one to it. I would be staggered to learn that the compiler optimized away this extra indirection, ever, because that would have required tracking the state of every variable used as an lvalue to know when that optimization was safe.

Finally, seventh, and most critically, using 1 index on the dyadic "!" operator would have caused extra complexity for *programmers*, because suddenly "!(V+I)" would mean something different from "V!I", and having "!(V+I)" mean "the memory at V + I + 1" would be just nutty.

BCPL arrays, like C arrays, were zero-origin because it fell naturally out of the unification of pointers and other values in a low level language.

13 August 2013

Hipster NSA

Hipster NSA was into data before they got big.
Hipster NSA only taps underground cables.
Hipster NSA says you don’t really collect data until you listen to it.
Hipster NSA stopped 50 terrorist attacks. You’ve probably never heard of them.
Hipster NSA stalked you before you were cool.

28 June 2013

Onward Sauron’s Soldiers

Just leaving this here...

Onward Sauron’s Soldiers

Words by Richard Tatge, Al Kuhfeld and Ken Fletcher. Sung to the tune of 'Onward Christian Soldiers'

Onward Sauron’s soldiers,
Marching as to war,
With the eye of Sauron
Going on before
Darkness like a banner
shadows all the foe.
Forward into battle see the Nazgul go.

Onward Sauron’s soldiers,
Matching as to war,
With the eye of Sauron
Going on before.

Trolls and Balrogs mangle
Dragons burn and bite!
With us you must tangle
Or run and scream in fright.
Evil is our watchword,
Pain is our delight;
Middle-Earth must crumble,
Under Mordor's might.


From the dread dark tower.
To the black Khazad-dum.
We’ll send elves and hobbits
Shrieking to their tomb.
Men and dwarves together
Go down in defeat.
In the hunger after the battle.
They’ll be nice to eat.


Conquer every village!
Yell out the battle cry!
Murder, rape and pillage,
Then spit in their eye!
See the craven victims
Quivering with fear:
We’ll be leaving Mordor
Sometime late next year.

17 June 2013

Teal Deer has a new buddy! PW;DR

Via @Skud RT @NeuroPolarbear Proposed new internet slang: BPW;DR. Means, "behind paywall, didn't read".

I'm just going to use "pw;dr".

The Teal Deer has a new buddy. What do we call this one? Power Deer?

05 June 2013

Oh dear where can the matter be...

Just leaving this here for reference...

Oh dear, where can the matter be?
When it's converted to energy,
There is a slight loss of parity.
Johnny's so long at the fair.

He promised to buy me a second-hand Morris,
A matched set of H-Bombs that go off in chorus,
A musically-talented agile slow loris,
And other delights that are rare.

Oh dear, where can the matter be?
When it's converted to energy,
There is a slight loss of parity.
Johnny's so long at the fair.

He promised to buy me a used weeping willow,
A pair of chrome booties for my armadillo,
A hand-tatted, plaid, pterodactyl-down pillow,
And other delights that are rare.

He promised to buy me a magical locket,
A miniature couerl to keep in my pocket,
A duocorn stallion, a Saturn-V rocket,
And other delights that are rare.

He promised to buy me a positron beauty,
A lit'rally minded transistorized cutie,
A chrome-plated robot that does double-duty,
And other delights that are rare.

He promised to buy me an incomplete wizard,
A red-headed genie, a hexapod gizzard,
A house-broken dragon, a musical blizzard,
And other delights that are rare.

He promised to buy me a microwave oven,
Some witches from Karres arrayed in a coven,
Some teflon extrusions to further our lovin',
And other delights that are rare.

11 May 2013

Keeping Presidents in the Nuclear Dark (from wayback machine)

CDI.ORG is now owned by a domain squatter, so I'm just going to leave this article in its entirety here:

Taken from here.

Keeping Presidents in the Nuclear Dark
(Episode #1: The Case of the Missing “Permissive Action Links”)
Bruce G. Blair, Ph.D, CDI President, bblair@cdi.org
Feb. 11, 2004
Last month I asked Robert McNamara, the secretary of defense during the Kennedy and Johnson administrations, what he believed back in the 1960s was the status of technical locks on the Minuteman intercontinental missiles. These long-range nuclear-tipped missiles first came on line during the Cuban missile crisis and grew to a force of 1,000 during the McNamara years — the backbone of the U.S. strategic deterrent through the late 1960s. McNamara replied, in his trade-mark, assertively confident manner that he personally saw to it that these special locks (known to wonks as “Permissive Action Links”) were installed on the Minuteman force, and that he regarded them as essential to strict central control and preventing unauthorized launch.

When the history of the nuclear cold war is finally comprehensively written, this McNamara vignette will be one of a long litany of items pointing to the ignorance of presidents and defense secretaries and other nuclear security officials about the true state of nuclear affairs during their time in the saddle. What I then told McNamara about his vitally important locks elicited this response: “I am shocked, absolutely shocked and outraged. Who the hell authorized that?” What he had just learned from me was that the locks had been installed, but everyone knew the combination.

The Strategic Air Command (SAC) in Omaha quietly decided to set the “locks” to all zeros in order to circumvent this safeguard. During the early to mid-1970s, during my stint as a Minuteman launch officer, they still had not been changed. Our launch checklist in fact instructed us, the firing crew, to double-check the locking panel in our underground launch bunker to ensure that no digits other than zero had been inadvertently dialed into the panel. SAC remained far less concerned about unauthorized launches than about the potential of these safeguards to interfere with the implementation of wartime launch orders. And so the “secret unlock code” during the height of the nuclear crises of the Cold War remained constant at OOOOOOOO.

After leaving the Air Force in 1974, I pressed the service, initially by letters addressed to it and then through congressional intermediaries, to consider a range of terrorist scenarios in which these locks could serve as crucial barriers against the unauthorized seizure of launch control over Minuteman missiles. In 1977, I co-authored (with Garry Brewer) an article (click here to view) entitled “The Terrorist Threat to World Nuclear Programs” in which I laid out the case for taking this threat more seriously and suggesting remedial measures including, first and foremost, activating those McNamara locks that apparently he and presidents presumed had already been activated.

The locks were activated in 1977.

It is hard to know where to begin, and end, in recounting stories like this one that reveal how misinformed, misled, and misguided on critical nuclear matters our top leaders have been throughout the nuclear age. A multitude of such examples can, and will, be described in forthcoming columns.

08 May 2013

Dear Twitter...

Dear Twitter: if you're going to continue to be jerks about letting people write new twitter clients, please can I have an official twitter client for the Mac that:

1. Puts the latest tweet at the bottom of the page, not at the top.
2. Puts the box to enter a new tweet at the bottom of the page, below the most recent tweet, not in its own window.
3. Keeps track of last tweet read, oldest tweet not seen, and so on, and lets me jump easily and reliably to each of these points.
4. When I uncheck "When new tweets arrive, scroll to top", then when new tweets arrive, don't scroll to the top. (in fact it'd be nice to have a visible toggle (like a pushpin) that controlled scrolling, because that's something I like to tweak on and off, but just having that work would be a start)
5. When I click on a link, just send it to my browser, don't go "hey, that's a picture, let me open it in my crippled picture viewer that doesn't let you copy images, image locations, or see commentary".

Yes, I know this is a long list. It's also incomplete. These are just the most annoying things, the ones that make me go "I can't DEAL with this before I've had my coffee".

There's more. Lots more. Like, how about showing me the display name of a poster inline instead of their cute little picture, and displaying retweets as "@friend: RT @gonzo: blag blah blah" instead of "@gonzo: Blah blah blah" with "retweeted by @friend" in little grey letters underneath.

The bottom line: you really don't do a good enough job of writing client software to call software that does a much better job of interacting with your service "redundant". Get over it. You should be paying these people a bonus, not cutting them off.

[Next week: Linden Lab's passive-aggressive relationship with alternate viewers. or not.]