O'Reilly logo

Modern Compiler Implementation in Java, Second Edition by Jens Palsberg, Andrew W. Appel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

11Register Allocation

reg-is-ter: a device for storing small amounts of data al-lo-cate: to apportion for a specific purpose

Webster′s Dictionary

The Translate, Canon, and Codegen phases of the compiler assume that there are an infinite number of registers to hold temporary values and that MOVE insructions cost nothing. The job of the register allocator is to assign the many tempora ies to a small number of machine registers, and, where possible, to assign the source and destination of a MOVE to the same register so that the MOVE can be deleted.

From an examination of the control and dataflow graph, we derive an interference graph. Each node in the interference graph represents a temporary value; each edge (t1, t2) indicates a pair of temporaries ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required