Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
Scientific programming and computer architecture
Viswanath D., The MIT Press, Cambridge, MA, 2017. 624 pp. Type: Book (978-0-262036-29-0)
Date Reviewed: Feb 14 2018

You can find books that teach you how to write efficient code in a specific language. The efficiency here comes from using good algorithms and making the best use of the language capability. You can also find books that discuss computer architecture and what happens under the hood when programs are being executed. This book combines both: how to write efficient programs that make the best use of the underlying hardware.

You will learn how the hardware and software interact. Some questions tackled by this book: What makes computer programs fast or slow? How do programming constructs map to different parts of the computer’s architecture? To answer these questions, and many more, you need to be a bit closer to the machine and not shielded from what is happening under the hood. Therefore, this book opts for C/C++ under Linux on x86 processors. Sorry, Java (or Python or Scala) folks! The book discusses the entities between the programmer and the architecture. It digs into linkers, compilers, operating systems, and computer architecture.

Even though the book assumes a working knowledge (at the undergraduate level) of C/C++, the first two chapters give a quick overview of the language and some of the useful tools like makefiles and important libraries.

Chapter 3 explains the architecture of the processor (that is, microarchitecture) and shows how to optimize code for pipelining. The following chapter discusses the memory hierarchy and shows how to optimize memory access in a program. Dealing with memory is not easy because there is a whole hierarchy involved: from several levels of cache to the main memory (DRAM), then to the disk. Optimizing code for memory access involves dealing with many entities of different characteristics. Chapter 4 gives examples of matrix transpose and matrix multiplication and how to optimize them.

Because we are in the era of parallelism, chapters 5 and 6 tackle the topics of threads in shared memory and message passing in distributed memory.

The last two chapters of the book show readers how to deal with different architectures than the traditional processor. Chapter 7 discusses the Intel Xeon Phi coprocessor and chapter 8 discusses graphics processing units.

Overall, I like this book and its idea. The code used is available online, at github, so readers can try it for themselves.

Productivity programmers (that is, those who want to use easy languages like Java, Python, and so on, and care more about productivity than performance) are shielded from what happens under the hood. But performance programmers (those brave people who use C/C++, CUDA, OpenCL, OpenMP, and so on) are the target audience of this book. If you want to know how the different pieces of a computer system interact and how to make the best use of that to write efficient programs, are willing to dig into serious lower-than-usual-level programming, and have a working knowledge of C/C++, then this book is for you.

More reviews about this item: Amazon

Reviewer:  Mohamed Zahran Review #: CR145853 (1804-0158)
Bookmark and Share
  Reviewer Selected
Featured Reviewer
 
 
General (C.1.0 )
 
 
Performance of Systems (C.4 )
 
 
Physical Sciences And Engineering (J.2 )
 
Would you recommend this review?
yes
no
Other reviews under "General": Date
Computer architecture
Baer J. Computer 17(10): 77-87, 1984. Type: Article
May 1 1985
Computer organization
Andrews M., Computer Science Press, Inc., New York, NY, 1987. Type: Book (9789780881751147)
Dec 1 1987
Computer organization: hardware/software (2nd ed.)
Gorsline G., Prentice-Hall, Inc., Upper Saddle River, NJ, 1986. Type: Book (9789780131653252)
Nov 1 1986
more...

E-Mail This Printer-Friendly
Send Your Comments
Contact Us
Reproduction in whole or in part without permission is prohibited.   Copyright 1999-2024 ThinkLoud®
Terms of Use
| Privacy Policy