March 18, 2003
The Sniper's Tale

The Guardian has an extensive series of excerpts from Marine Lance Corporal Anthony Swofford's book Jarhead, detailing his expereinces as a sniper during the last Gulf War. Swofford came from a military family. He was a US marine to the bone. But when he was sent to fight in the 1991 Gulf war and saw the devastation he was part of, doubts and despair set in. What were they fighting for? He tells how it felt to be a soldier on the ground, under fire from the enemy, and, worse, from his own side. Sobering stuff.

Then we send a few guys downtown to rent all of the war movies they can get their hands on. For three days we sit in our rec room and drink beer and watch all of those damned movies [...]

There is talk that many Vietnam films are anti-war, that the message is war is inhumane and look what happens when you train young American men to fight and kill. But, actually, Vietnam war films are all pro-war, no matter what Kubrick or Coppola or Stone intended. Mr and Mrs Johnson in Omaha or San Francisco will watch the films and weep and decide war is inhumane and terrible, but Corporal Johnson at Camp Pendleton and Sergeant Johnson at Travis Air Force Base and Lance Corporal Swofford at Twentynine Palms Marine Corps Base watch the same films and are excited by them, because they celebrate the terrible and despicable beauty of their fighting skills.

Posted by Darren Wershler-Henry at March 18, 2003 10:55 AM
Comments

We can see an example of this in our code we've written so far. In each function's block, we declare variables that hold our data. When each function ends, the variables within are disposed of, and the space they were using is given back to the computer to use. The variables live in the blocks of conditionals and loops we write, but they don't cascade into functions we call, because those aren't sub-blocks, but different sections of code entirely. Every variable we've written has a well-defined lifetime of one function.

Posted by: Etheldreda on January 18, 2004 10:46 PM

Each Stack Frame represents a function. The bottom frame is always the main function, and the frames above it are the other functions that main calls. At any given time, the stack can show you the path your code has taken to get to where it is. The top frame represents the function the code is currently executing, and the frame below it is the function that called the current function, and the frame below that represents the function that called the function that called the current function, and so on all the way down to main, which is the starting point of any C program.

Posted by: Zachary on January 18, 2004 10:47 PM

When the machine compiles your code, however, it does a little bit of translation. At run time, the computer sees nothing but 1s and 0s, which is all the computer ever sees: a continuous string of binary numbers that it can interpret in various ways.

Posted by: Dionise on January 18, 2004 10:47 PM

When the machine compiles your code, however, it does a little bit of translation. At run time, the computer sees nothing but 1s and 0s, which is all the computer ever sees: a continuous string of binary numbers that it can interpret in various ways.

Posted by: Martin on January 18, 2004 10:48 PM

This is another function provided for dealing with the heap. After you've created some space in the Heap, it's yours until you let go of it. When your program is done using it, you have to explicitly tell the computer that you don't need it anymore or the computer will save it for your future use (or until your program quits, when it knows you won't be needing the memory anymore). The call to simply tells the computer that you had this space, but you're done and the memory can be freed for use by something else later on.

Posted by: Jenkin on January 18, 2004 10:48 PM
-->