Re: SPARC code generation references

pardo@june.cs.washington.edu (David Keppel)
Tue, 28 May 91 17:12:59 GMT

          From comp.compilers

Related articles
SPARC code generation references ressler@cs.cornell.edu (1991-05-24)
Re: SPARC code generation references torek@elf.ee.lbl.gov (1991-05-26)
Re: SPARC code generation references preston@ariel.rice.edu (1991-05-28)
Re: SPARC code generation references pardo@june.cs.washington.edu (1991-05-28)
Re: SPARC code generation references array!colin (1991-05-27)
| List of all articles for this month |
Newsgroups: comp.compilers
From: pardo@june.cs.washington.edu (David Keppel)
Keywords: SPARC, optimize
Organization: Computer Science & Engineering, U. of Washington, Seattle
References: 91-05-100 91-05-101
Date: Tue, 28 May 91 17:12:59 GMT

torek@elf.ee.lbl.gov (Chris Torek) writes:
>[You can `leaf crush' on the SPARC as long as there are enough
> registers: non-parameter (sp/ret-pc) `o' registers and 7 `g'
> registers.]


Be careful with this. According to the SPARC ABI (Applications Binary
Interface) standard, an ABI conforming program does something like:


%g0 is always zero
%g1 is a caller-save `very temp'
%g2..%g4 are reserved for application code and may not
be modified by libraries
%g5..%g7 may be read but not written by an application
(e.g., the analog of %g2..%g4 for libraries)


Eek!


I don't sit on the committee. I think some of this is useful but as
much as they've done is too much, since it potentially leaves (so to
speak :-) only one `very temp'. As an aside, you can't manually
spill/restore reserved `g' registers because they might be needed by
an asynchronous signal. Ah, omniscience by committee is just as hard
as any other time :-)


;-D on ( An opinion a day... ) Pardo
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.