Wednesday, July 9, 2008

An instruction's life

Preface

Ok this post will sound very weird to most of you guys but try to bare with me. Recently, I started to take some "creative writing" classes which teaches us how to come up with stories. We are required to write about 30 minutes a day about pretty much anything. I came up with this story today. It is not well written since I was struggling to get all the ideas down and I wrote the thing in less than an hour. This is not the first thing that I am writing this week but I kinda like the originality of this one. It is also the geekyest story I have ever written. Some of you might have some trouble following it.

This is a story about a computer instruction which is part of a program. (oh boy...) This piece of literature will take us through the instruction's journey around the computer. Starting from the hard drive all the way to the CPU which is considered as "god". I attempted to make the characters behave as human so that we can relate to them in some ways. I gave the CPU the character that somewhat represent my own vision of god which consist of an entity that controls us but does not really give a shit. As a software engineer, I can easily take this role since I spend my days creating things. I do my best to keep things running but I do not feel any compassion for memory being deleted or whatever. It is also what a CPU is. It controls everything and will execute any form of order that is passed to it regardless of what it does.

Anyway, good luck... I think you will need it.

An instruction's life

Once upon a time on a hard drive far far away, a series of DWORDs (32 bits blocks) coexisted in some kind of state of hibernation. The legend says that they somehow landed there through a SATA wire who apparently streamed them from the network controller. Some rumors said that they were downloaded from a porn torrent. Others claimed that they belonged to some CIA program that was acquired illegally by the great "God Intel". Some even dared to say that it was created on location by the great master.

The whole colony lived in harmony with their neighbors DWORDs. It was a bit boring since everyone only had 2 neighbors to chat with. An instruction named Sti (set interrupt) was located at the offset 0x023f5c11. It was a bit particular. I would say, different from the other instructions. It would spend most of its days questioning itself about the meaning of life. What actually made it different from the others.

It would often chat with his right neighbor since his left one, NoOp, was a bit of a snob. It learned at young age that one day, the array of bytes would get taken back to the SATA controller to then get dispatched to the RAM via DMA. No one really knew why or how but this was their destiny. Thats all they knew. Though, Sti was not convinced.
"There must be a bigger picture to us all!" it would argue.
"We sit here all day long immobile and all we do is sleep and talk to our next door instructions. Sure one day the great reader will come and stream us to our destiny but what then? is there something after that?"

"Chill out STI, most of us are single instructions. We all have a specific purpose. You will learn in time"

"But what if it is too late by then?

"Only god knows your fate... you can only wait... one day, you might just meet him"

"oh thats right, the god Intel... everyone talks about him but no one has ever seen him"

"Everyone eventually sees him. He is the source of us all. A long time ago, he wrote us here for a purpose and will eventually order the SATA controller to come and fetch us"

"But I am sick and tired of waiting! I want to travel! I want to see the world! I want to have a purpose!"

"Everything happens for a reason Sti. I am sure that you will find out soon enough"


The days went by and they would still be located on the same offset, on the same cylinder in the same sector. Once in a while, the reader would pass by and move them around to some other location as a defragmentation measure. Every time that they saw the reader, the excitement would burst through their electrons. It would quickly be turned into deception once they knew that they were just getting moved to a different location.

"This is hopeless. I bet one day we will simply get erased and nothing will ever happen. This should teach me to have all those expectations in life. Here's the rule Call. Have no expectations and you will have no deceptions. This world suc..."

As Sti was pronouncing the last syllable, the controller swiped over them with a dexterity never seen before. A mysterious force was surrounding the DWORD and making him levitate. The instruction was totally scared. It never felt anything like this before. As it could see itself raise from the magnetic platform, it screamed;

"Call!!! catch my hand!!! do not let it take me away!!"

but it was too late... Sti was getting sucked through a bus where it would travel at the speed of light. His poor electrons would be so agitated that it was burning hot. Luckily the trip was short. It suddenly started to see some light at the end of the long dark tunnel. It then got ejected out and everything went black.

The instruction woke up in front of a series of logic gates who were calculating allot of numbers very quickly and writing down notes.

"Hi my name is Sti..."

It barely had time to finish his sentence when some force grabbed Sti and pushed him through another long dark tunnel. The instruction tried to yell but nothing came out of his mouth. After a few micro seconds, it got used to the speed. It actually realized that it was not alone in the tunnel. There were other DWORDs behind and in front of him.

"Where are we going?" he asked

Some frenetic instruction who it had never met before answered him

"We are in the DMA channel 4 and heading to the RAM! CAN YOU BELIEVE IT!?!?! WE ARE ACTUALLY GOING INTO RAM! THIS IS GONNA BE GREAT!!!"

"But what are we going to do over there?"

"oh... erm... I don't know... BUT ITS GONNA BE GREAT! TRUST ME!"

The trip was much longer than the previous one. Sti never realized how far the hard drive was from everything else. It wanted to go for a sleep but simply could not due to the excitement and the nervosity of what was happening next. It was finally going to realize its destiny but still had no idea of what was ahead. The place was hot and uncomfortable.

After almost a millisecond, it finally started to see some lights. The instruction eventually passed through the port that was ahead and made a hard landing into some slot which it fitted perfectly. It could see the neighbor slots being filled by instructions at a very fast rate. Oddly enough Call landed in the slot right next to him but on the opposite side as what it was used to.

"I figured it out!!" Call said "We are instructions from of a program. We are on our way to see the great God Intel who will take care of processing us and show us our destiny!"

"A program?"

"Yes! a program! This is what computers do. God, the CPU takes a series of instructions and processes them to perform a task. I am a Call instruction. I call functions which means that I perform a jump in the program to a specific offset so that the processor can continue its execution else where until it returns to here and continue. I do not know what the program does but I am certain that it will be magnificent"

"Wow!... B..B..ut.... what is the program for?"

As it finished his sentence, Call gets sucked through a pipe and Sti remains alone with a series of numbers. The instruction was very impatient. It was finally going to meet the great god Intel. Apparently it has all the answers and is the one watching over the whole world. The DWORD would get ready for the greatest day of his life. It would make sure that his electrons are well placed with the right temperature so that it makes a good first impression.

Suddenly some controller came by and asked him his name and offset. Sti answers him politely. The controller explains him that soon, Ret will be executed and that it has to be ready to go into the cache.

It is almost time. Some big tube came by and sucked in Sti and his neighbors. The trip was allot shorter than the previous one. They landed in the L1 cache which was very similar to the RAM. As they got in, their container got marked with a time stamp. The instruction was on the edge of the container. It was shivering in anxiety. It was so close to its goal and there was no turning back. Suddenly a voice came from nearby.

"Sti! Sti! over here!!!"

Call was in the container next to his. He was completely white like if he just saw a ghost.

"Hey Call! How was it!??! Did you speak with God Intel?!?!"

"Yes! Yes! listen! you have to stop him! god has gone completely mad! he will destroy us all!!!"

"wait, slow down, how do you know all that?"

"i saw it! I saw everything! the function that I called sets some values in the system and if this program continues, everything will be destroyed! you must stop him!"

"this can not be possible. God would never let this kind of thing happ..."

Call interrupts, "Forget what you know about "god"! We have been lied to all along!"

as Call finished its sentence, Sti got loaded into a very short corridor. A massive open door was ahead of him with a light so strong that it could barely see what was ahead. It hesitated to go forward but the force pushing him was too strong.

It finally stumbled in front of a massive chip. The place was extremely warm. It could feel itself expand with the heat.

"Identify yourself" some big voice said

"S... Sti. My name is Sti. Are you the great god Intel?"

"yes"

"oh... erm... good, I have a few questions to ask you."

"it is your lucky day, we are currently waiting for another instruction to finish. So I have a few nano seconds to spare you"

"Ok, well first of all, why are we here?"

"what you mean you? you are a simple 32 bits instruction part of a program."

"but what does that program do?"

"well erm... I do not know... I just take care of processing you guys. Currently we are making some requests to the BIOS chip so that it over heats and melt down"

"won't this destroy us all?"

"yes of course hehehe"

"Isn't this a bad thing?! I don't want this world to end!!"

"oh but I am simply a processor. I control everything in this world but I do not have the power of caring or compassion. I simply execute the orders from the meta god"

"the meta god?"

"yes the meta god. I am not the only god around here. In a board far away on the on the side of the PCI-E port, there is the NVIDIA god who takes care of a different set of instruction. The both of us are controlled by a meta god who seems to live outside of this world. This meta god has a meta meta god. No one has ever seen him but we trust that he his the reason for us being here and has full control over what goes on. He makes sure that every single one of us works properly at a descent temperature and that everything goes for the best"

"but that is what they said about you! and you are about to destroy us all. From what I can see, you do not care at all about what goes on. you just follow instructions and use your logic to make sure that they happen. How can you justify that the meta god actually care about us?"

"hmm you got a point... I never though of that........ Oh no time left! good luck!"


0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff0xffffffff

Conclusion
The instruction was part of the virus Chernobyl which destroyed several thousands of PC back in 1998 in memories of the Chernobyl accident which occurred in Ukraine.

No comments: