No prior knowledge of assembly language required!
In the beginning, most software was written in assembly, the CPU’s low-level language, in order to achieve acceptable performance on relatively slow hardware. Early programmers were sparing in their use of high-level language code, knowing that a high-level language compiler would generate crummy, low-level machine code for their software. Today, however, many programmers write in high-level languages like C, C++, Pascal, Java, or BASIC. The result is often sloppy, inefficient code. You don’t need to give up the productivity and portability of high-level languages in order to produce more efficient software.
In this second volume of the Write Great Code series, you’ll learn:
• How to analyze the output of a compiler to verify that your code does, indeed, generate good machine code
• The types of machine code statements that compilers typically generate for common control structures, so you can choose the best statements when writing HLL code
• Just enough 80x86 and PowerPC assembly language to read compiler output
• How compilers convert various constant and variable objects into machine data, and how to use these objects to write faster and shorter programs
With an understanding of how compilers work, you’ll be able to write source code that they can translate into elegant machine code. That understanding starts right here, with Write Great Code, Volume 2: Thinking Low-Level, Writing High-Level.
About the Author
Randall Hyde is the author of The Art of Assembly Language, one of the most highly recommended resources on assembly, and Write Great Code, Volume 1. He is also the co-author of The Waite Group's MASM 6.0 Bible. He has written for Dr. Dobb's Journal and Byte, as well as professional journals.