Home Page -------------------
[Home Page] - [Reviews Main]
-------------------

Book Review
Zen and the Art of Code Optimisation by Michael Abrash
ISBN: 1 883577 03 9       Publisher: Coriolis Group       Pages: 450pp&disk       Price: $39-95
Categories:   internals and hardware     assembler    
Reviewed by Chris Hills in C Vu 9-5 (Jul 1997)
Another reviewer passed this book to me because it had 'too much assembler'. It is not for the faint hearted. It is for those who need (not just think they would like) more speed. The title of the book is a hint 'Zen of...'. One has to have the correct frame of mind for this book. One also needs knowledge of the hardware, assembler and algorithms, as there is no attempt to teach basics. In fact it is assumed that one has a reasonably good understanding of assembler to start with. Much of the book comes from the author's column 'Pushing the Envelope' in PC Techniques . The author's passion appears to be speed over all other criteria.

The whole Intel PC range from 8088 to the Pentium is covered. Also the Pentium's V-pipe. If you need to ask what a V-Pipe is then this book is probably not for you. The text works its way through the processors, looking at the known 'cycle eating' areas and suggesting ways to deal with them. The book is full of tips and examples like 'If any byte register is loaded and then 2 cycles later any register is used to point to memory, 1 cycle is lost. So for example...'. It is up to you to work out how and when to use these snippets in your own work.

Speed increases are given in cycles and also using a supplied precision timer. It is a library for linking into one's own code. This is an actuate timer with a range of up to 54 milliseconds that can be used to measure performance improvements. 54 ms may not sound long but it highlights the tone of this book, it looks very closely at small parts of code to save cycles. Also included on the disc are several versions of the game of life to illustrate various points.

I think experienced assembly programmers may take to this book. The average C coder will not because, as the book shows, to make real speed increases one has to drop into correctly optimised, hand-crafted, assembler. There is not enough C++ in it to interest the C++ community. I found the book interesting to read but I did not take to it despite enjoying assembly programming and as the previous reviewer did not get on with it either I do not think it is a book I would recommend.


Other Authors with the same surname

Abrash
Zen of Graphics Programming (2ed) by Michael Abrash  (Reviewed Mar 1997)
Zen of Graphics Programming by Michael Abrash [Highly Recommended]  (Reviewed Sep 1995)


Last Update - 13 May 2001.

To link to this review, please use the URL: http://www.accu.org/bookreviews/public/reviews/z/z001445.htm

Copyright © The Association of C & C++ Users 1998-2000. All rights reserved.

Mirrored from http://www.accu.org/