home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #23 / NN_1992_23.iso / spool / gnu / gcc / help / 2312 < prev    next >
Encoding:
Internet Message Format  |  1992-10-12  |  1.1 KB

  1. Path: sparky!uunet!stanford.edu!ames!haven.umd.edu!darwin.sura.net!ukma!cs.widener.edu!iggy.GW.Vitalink.COM!pacbell.com!decwrl!ditka!starnet!motcsd!udc!qbarnes
  2. From: qbarnes@urbana.mcd.mot.com (Quentin Barnes)
  3. Newsgroups: gnu.gcc.help
  4. Subject: Force loading of register
  5. Message-ID: <1992Oct12.161458.3340@urbana.mcd.mot.com>
  6. Date: 12 Oct 92 16:14:58 GMT
  7. Sender: news@urbana.mcd.mot.com (News)
  8. Organization: Motorola Computer Group, Urbana Design Center
  9. Lines: 19
  10. Nntp-Posting-Host: neptune.urbana.mcd.mot.com
  11.  
  12. I would like to be able to force gcc to load a specific register
  13. for me.  I thought that the code to do this would be:
  14.  
  15.         register volatile unsigned long base asm("#r14");
  16.  
  17.         base = (unsigned long)0x1000000;
  18.  
  19. (This is for a Motorola m88k processor.  Change the asm("...") to
  20. a register appropriate for you system.)
  21.  
  22. gcc generates:
  23. volasm.c:nn: warning: volatile register variables don't work as you might wish
  24.  
  25. Why is this message displayed?  Am I "doing the right thing" just that
  26. gcc doesn't handle it yet?  Or is there another way to do what I want?
  27.  
  28. -- 
  29. Quentin Barnes
  30. qbarnes@urbana.mcd.mot.com | ..!uiucuxc!udc!qbarnes
  31.