Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

From the essay Programming Languages Explained by Paul Graham, published in Hackers & Painters:

The high-level language that you feed the compiler is also known as source code, and the machine language translation it generates is called object code.

From the Wikipedia article on object code:

Object code, or sometimes object module, is what a computer compiler produces.

From a definition of 'compiler':

Traditionally, the output of the compilation has been called object code or sometimes an object module. (Note that the term "object" here is not related to object-oriented programming.)

So what is the term object related to?

share|improve this question
Note that a compiler does not have to generate machine code. It is customary to have a lower abstraction level , otherwise it is normally called a translator. – user1249 May 18 '12 at 15:10
The first two people that had to communicate with each other about object code didn't know what to call it so they adopted a very generic term. – semaj May 18 '12 at 15:43
up vote 7 down vote accepted

Object code is sometimes also called target code, because it is the target result of the translation process performed by compilers. So "object code" is used as an opposite of "source code".

There are other strange names in the compiler world: for example, the segment of the file with the binary code of your program is often called "the text segment".

share|improve this answer

It is object as in "objective". Not object as a "thing".

Similar to dasblinkenlight's answer about being called "target code". It is the target or objective of the compiler.

share|improve this answer
Not sure I agree with that. – Loki Astari May 18 '12 at 17:39
Sounds about right to me. It's always been referred to in the context of the objective of the compiler. – Lord Tydus May 19 '12 at 0:41

Object code is produced when you compile a source code. This object code is not executable yet because it does not have required libraries to run. So you link multiple object codes and libraries and it becomes an executable.

In my understanding "object" relates to the "thing" you developed by writing that source code. It can be a module, class, function or anything.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.