Subject: re: "detected global register use not covered by .register pseudo-op"
To: der Mouse <mouse@Rodents.Montreal.QC.CA>
From: matthew green <mrg@eterna.com.au>
List: port-sparc64
Date: 09/24/2007 16:00:30
   I'm trying to build some code on 3.1 sparc64, and I'm getting assembler
   errors saying "detected global register use not covered by .register
   pseudo-op".
   
   Now, the code does include some assaembly.  I'm prepared to hack on it.
   But I can't usefully do this until I know what the complaint is
   complaining about.  I tried google, but it just showed me a bunch of
   people describing getting the same complaint out of sparc64 for various
   OSes and pieces of software, with no explanations of what it meant or
   how to deal with it.  "man as" was even less help; it doesn't mention
   the .register pseudo-op at all.  I infer that one has to use .register
   in some way to "cover" uses of global registers, but that's not much
   help - it's not even clear what "global registers" means (%g0-%g7?
   registers not saved by functions? something else?).
   
   Any pointers or other hints?


i don't remember exactly what it is about but newer code
tends to have this in it:

       .register       %g2,#scratch
       .register       %g3,#scratch

i had to fix netbsd src for newer gcc at some point in the
last few years.


.mrg.