Book Excerpt: Write Great Code—Think Low Level, Write High Level

o matter how well you write and understand high-level programming languages, your applications can probably benefit if you’re willing to dig down into the lower-level code that makes the computer work. And for most developers, that means learning assembly language and understanding compilers.

In Write Great Code, Volume 2: Thinking Low-Level, Writing High-Level (No Starch Press, March 2006), author Randall Hyde speaks to a new generation of programmers who haven’t been taught assembly language, and many of whom haven’t been trained in a computer science curriculum. This book, the second installment in the popular Write Great Code series, explains how compilers work to translate high-level language statements and data structures into machine code. Armed with this understanding, programmers will be able to choose a proper mix of high-level language statements to produce more efficient software?all without having to give up the productivity and portability benefits of a high-level language.

The two chapters excerpted here should not only serve as a good introduction to the advantages of knowing lower-level programming, but also give you a good feel for the comprehensive coverage and the target audience level of this book.

Chapter 3, 80×86 Assembly for the High-level Language (HLL) Programmer, walks you through the 80×86 architecture, provides a basic overview of 80×86 assembly language, the addressing modes for this chip family, and then describes the various syntax forms used in common assemblers such as HLA, MASM/TASM, and Gas.

Chapter 8, Variables in a High-level Language, covers the low-level implementation of variables used in high-level languages, including the runtime memory organization, attributes that differentiate variables from other objects, the difference between static, automatic, and dynamic variables, and how machine instructions encode the address of a variable.

Reproduced from Write Great Code, Volume 2: Thinking Low-Level, Writing High-Level by permission of No Starch Press. ISBN 1593270658, copyright 2006. All rights reserved.

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

The Latest

microsoft careers

Top Careers at Microsoft

Microsoft has gained its position as one of the top companies in the world, and Microsoft careers are flourishing. This multinational company is efficiently developing popular software and computers with other consumer electronics. It is a dream come true for so many people to acquire a high paid, high-prestige job

your company's audio

4 Areas of Your Company Where Your Audio Really Matters

Your company probably relies on audio more than you realize. Whether you’re creating a spoken text message to a colleague or giving a speech, you want your audio to shine. Otherwise, you could cause avoidable friction points and potentially hurt your brand reputation. For example, let’s say you create a

chrome os developer mode

How to Turn on Chrome OS Developer Mode

Google’s Chrome OS is a popular operating system that is widely used on Chromebooks and other devices. While it is designed to be simple and user-friendly, there are times when users may want to access additional features and functionality. One way to do this is by turning on Chrome OS