Click here to Skip to main content
Click here to Skip to main content

Why Learn Assembly Language?

, 29 Jun 2010 CPOL
Rate this:
Please Sign up or sign in to vote.
An article explaining the benefits of learning assembly language



"Assembly language? Isn't that the hard to read instructions on how to assemble your brand new computer desk?"...


What is Assembly Language?

x86 Assembly is a programming language for the x86 class of processors (specifically the 32bit x86 processors IA-32 - The instruction set defined by the IA-32 architecture is targeted towards the family of microprocessors installed in the vast majority of personal computers on the planet. Assembly language is machine specific and considered a "low level" language. This means that the code and syntax is much closer to the computer's processor, memory, and I/O system. A high level language is designed with keywords, libraries, and a syntax that introduces a high level of abstraction between the language and the hardware.


I thought assembly was a dead language, why waste the time?

Though it's true, you probably won't find yourself writing your next customer's app in assembly, there is still much to gain from learning assembly. Today, assembly language is used primarily for direct hardware manipulation, access to specialized processor instructions, or to address critical performance issues. Typical uses are device drivers, low-level embedded systems, and real-time systems (EDIT:Thanks Trollslayer). The fact of the matter is, the more complex high level languages become, and the more ADT (abstract data types) that are written, the more overhead is incurred to support these options. In the instances of .NET, perhaps bloated MSIL. Imagine if you knew MSIL. This is where assembly language shines. (EDIT)Assembly language is as close to the processor as you can get as a programmer so a well designed algorithm is blazing -- assembly is great for speed optimization. It's all about performance and efficiency. Assembly language gives you complete control over the system's resources. Much like an assembly line, you write code to push single values into registers, deal with memory addresses directly to retrieve values or pointers. To write in assembly is to understand exactly how the processor and memory work together to "make things happen". Be warned, assembly language is cryptic, and the applications source code size is much much larger than that of a high-level language. But make no mistake about it, if you are willing to put in the time and the effort to master assembly, you will get better, and you will become a stand out in the field.

So why should you care?

Points of Interest

Wirth's Law

I remember dialling into a BBS on my 486 with my brand new 2400bps modem. Fast-forward 14 years and now we are only limited by our imagination. With all of these amazing technological breakthroughs, there is a glaring anomaly; a paradox. This is referred to as Wirth's law. Wirth's law states that software is getting slower more rapidly than hardware becomes faster. There's no one reason why this is the case, but I'd like to think that the further we as developers drift away from the lower level details of software development, we write less than stellar (inefficient code). Hold the phone! I'm not calling anyone stupid. It's just that these new languages and supercharged processors have abstracted us so far from the machine, that we no longer have to be concerned with things like garbage collection, variable initialization, memory address pointers, etc. All of these features and more are now standard in today's languages/runtimes/IDEs. The result is a new breed of developers that rely on superior hardware power for performance rather than striving to write concise, cohesive, efficient code.

My Eyes are Open!

I realize now that learning assembly language will teach me about the inner workings of the computer. I'll learn how the CPU/CPU registers work with memory addresses to achieve the end result one instruction at a time. This doesn't mean that I'm going to begin coding everything in assembly, however, I will learn which data types to use and when. I'll learn how to write smaller, faster, more efficient routines. I will understand software development at a level that most of my peers don't. I'm even opening up to the possibility of looking into writing my own compiler.

So if you are serious about getting a leg up on the competition in your field, I'd recommend trying to learn assembly language.

Resources on Learning Assembly

Introduction to x86 Assembly Language


I plan to update this blog with links to tutorials/articles/books/sample source code.

Well, as always,
Thanks for reading.
Buddy B.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Software Developer
United States United States
I'm a 28 year old software engineer from Tennessee. I've been programming since I was 13 years old. I'm fortunate enough to be able to do what I love for a living.
VB.NET, ASP.NET, C#, assembly, HTML, JavaScript, AJAX
I'm MCP, MCAD, MCSD.NET certified.
follow me on twitter

Comments and Discussions

QuestionSecurity Reasons PinmemberLee Wang Hao1-Nov-14 4:56 
SuggestionOnline video course for x86 assembly PinmemberMember 111387798-Oct-14 8:24 
QuestionMy vote of 5 PinmemberJosef Manurung30-Dec-11 7:00 
QuestionAssembly language. Pinmembernigel wright3-Oct-11 12:10 
GeneralFew Queries Pinmemberpopchecker13-Sep-10 16:48 
GeneralRe: Few Queries Pinmemberbuddy.james23-Sep-10 22:20 
GeneralFor a different take on the pros & cons of asm over other languages. PinmemberDigital Thunder7-Jul-10 10:24 
GeneralRe: For a different take on the pros & cons of asm over other languages. Pinmemberbjames027-Jul-10 19:25 
GeneralMy vote of 3 PinmemberBit_Flipper1-Jul-10 19:05 
GeneralPE File Format Pinmembermnjrupp29-Jun-10 5:50 
GeneralOveral cost Pinmemberdanielj29-Jun-10 4:58 
GeneralRe: Overal cost Pinmemberbjames0229-Jun-10 5:43 
Thanks for the response.
I never said that assembly language was cost effective. I simply stated that we can benifit from learning a language that close to the machine.
GeneralRe: Overal cost Pinmembersupercat929-Jun-10 6:17 
GeneralRe: Overal cost Pinmemberdanielj29-Jun-10 23:02 
GeneralRe: Overal cost Pinmemberbjames0230-Jun-10 6:32 
GeneralRe: Overal cost Pinmembersupercat930-Jun-10 6:36 
GeneralRe: Overal cost Pinmemberke4vtw20-Jul-10 6:00 
Generalassambly PinmemberAdrabi Abderrahim25-Jun-10 16:28 
GeneralRe: assambly Pinmemberbjames0225-Jun-10 19:08 
GeneralTrue worth of knowleged gained from learning Pinmemberw3bdev25-Jun-10 6:48 
GeneralWaiting for examples and tutorials PinmvpJose Menendez Póo25-Jun-10 6:39 
GeneralRe: Waiting for examples and tutorials Pinmemberbjames0225-Jun-10 6:43 
GeneralRe: Waiting for examples and tutorials PinmembervizEQ28-Jun-10 15:09 
GeneralRe: Waiting for examples and tutorials Pinmemberbjames0228-Jun-10 23:39 
GeneralRe: Waiting for examples and tutorials PinmemberRugbyLeague29-Jun-10 1:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.150327.1 | Last Updated 29 Jun 2010
Article Copyright 2010 by bjames02
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid