ACM Home Page
Please provide us with feedback. Feedback
Register allocation by puzzle solving
Full text PdfPdf (1.68 MB)
Source
Conference on Programming Language Design and Implementation archive
Proceedings of the 2008 ACM SIGPLAN conference on Programming language design and implementation table of contents
Tucson, AZ, USA
SESSION: Session VIII table of contents
Pages 216-226  
Year of Publication: 2008
ISBN:978-1-59593-860-2
Also published in ...
Authors
Fernando Magno Quintão Pereira  University of California, Los Angeles, Los Angeles, CA, USA
Jens Palsberg  University of California, Los Angeles, Los Angeles, CA, USA
Sponsors
ACM: Association for Computing Machinery
SIGPLAN: ACM Special Interest Group on Programming Languages
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 15,   Downloads (12 Months): 248,   Citation Count: 0
Additional Information:

abstract   references   index terms   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/1375581.1375609
What is a DOI?

ABSTRACT

We show that register allocation can be viewed as solving a collection of puzzles. We model the register file as a puzzle board and the program variables as puzzle pieces; pre-coloring and register aliasing fit in naturally. For architectures such as PowerPC, x86, and StrongARM, we can solve the puzzles in polynomial time, and we have augmented the puzzle solver with a simple heuristic for spilling. For SPEC CPU2000, the compilation time of our implementation is as fast as that of the extended version of linear scan used by LLVM, which is the JIT compiler in the openGL stack of Mac OS 10.5. Our implementation produces x86 code that is of similar quality to the code produced by the slower, state-of-the-art iterated register coalescing of George and Appel with the extensions proposed by Smith, Ramsey, and Holloway in 2004.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
Scott Ananian. The static single information form. Master's thesis, MIT, September 1999.
2
 
3
L. Belady. A study of the replacement of algorithms of a virtual storage computer. IBM System Journal, 5:78--101, 1966.
 
4
5
 
6
Florent Bouchez. Allocation de registres et vidage en mémoire. Master's thesis, ENS Lyon, 2005.
 
7
Florent Bouchez, Alain Darte, Christophe Guillon, and Fabrice Rastello. Register allocation: What does the NP-completeness proof of chaitin et al. really prove? Or revisiting register allocation: Why and how. In LCPC, pages 283--298. Springer, 2006.
 
8
 
9
Philip Brisk, Foad Dabiri, Jamie Macbeth, and Majid Sarrafzadeh. Polynomial-time graph coloring register allocation. In IWLS, pages 447--454. 2005.
10
11
 
12
Gregory J. Chaitin, Mark A. Auslander, Ashok K. Chandra, John Cocke, Martin E. Hopkins, and Peter W. Markstein. Register allocation via coloring. Computer Languages, 6:47--57, 1981.
13
 
14
Alkis Evlogimenos. Improvements to linear scan register allocation. Technical report, University of Illinois, Urbana-Champaign, 2004.
 
15
 
16
Fanica Gavril. The intersection graphs of subtrees of a tree are exactly the chordal graphs. Journal of Combinatorial Theory, Series B, 16(1):47 -- 56, 1974.
17
 
18
Martin Charles Golumbic. Trivially perfect graphs. Discrete Mathematics, 24:105 -- 107, 1978.
 
19
Daniel Grund and Sebastian Hack. A fast cutting-plane algorithm for optimal coalescing. In CC, volume 4420, pages 111--115. Springer, 2007.
 
20
Sebastian Hack, Daniel Grund, and Gerhard Goos. Register allocation for programs in SSA-form. In CC, pages 247--262. Springer, 2006.
 
21
Lang Hames and Bernhard Scholz. Nearly optimal register allocation with PBQP. In JMLC, pages 346--361. Springer, 2006.
 
22
Corporate SPARC International Inc. The SPARC Architecture Manual, Version 8. Prentice Hall, 1st edition, 1992.
23
 
24
Richard M Karp. Reducibility among combinatorial problems. In Complexity of Computer Computations, pages 85--103. Plenum, 1972.
25
 
26
 
27
Jonathan K. Lee, Jens Palsberg, and Fernando M. Q. Pereira. Aliased register allocation for straight-line programs is NP-complete. In ICALP, pages 680--691. Springer, 2007.
 
28
 
29
 
30
Fernando Magno Quintao Pereira and Jens Palsberg. Register allocation via coloring of chordal graphs. In APLAS, pages 315--329. Springer, 2005.
 
31
Fernando Magno Quintao Pereira and Jens Palsberg. Register allocation after classic SSA elimination is NP-complete. In FOSSACS, pages 79--93. Springer, 2006.
 
32
Fernando Magno Quintao Pereira and Jens Palsberg. Register allocation by puzzle solving, 2008. http://compilers.cs.ucla.edu/ fernando/projects/puzzles/.
33
 
34
Vivek Sarkar and Rajkishore Barik. Extended linear scan: an alternate foundation for global register allocation. In CC, pages 141--155. Springer, 2007.
35
36
 
37
38
 
39
40
 
41

Collaborative Colleagues:
Fernando Magno Quintão Pereira: colleagues
Jens Palsberg: colleagues