home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.amiga.programmer
- Path: sparky!uunet!ukma!gatech!ncar!news.miami.edu!cybernet!pineal.math.fau.edu!spc
- From: spc@pineal.math.fau.edu (Sean 'Captain Napalm' Conner)
- Subject: Re: 680x0 register usage on Amiga?
- Message-ID: <1993Jan28.022243.28629@cybernet.cse.fau.edu>
- Sender: news@cybernet.cse.fau.edu
- Organization: Florida Atlantic University, but who cares?
- References: <1993Jan27.214002.23569@fcom.cc.utah.edu>
- Date: Thu, 28 Jan 1993 02:22:43 GMT
- Lines: 21
-
- In article <1993Jan27.214002.23569@fcom.cc.utah.edu> val@news.ccutah.edu (Val Kartchner) writes:
- >
- >I usually program the Amiga in C. When I want to get the maximum speed in
- >a core routine, I go to assembly language. However, I'm not sure which
- >CPU registers are allocated and which are free for me to use when programming.
- >Here is the list as I understand it:
- >
- You list is basically correct, only D0 is ALWAYS used as a return value
- (integer, pointer, float) (with the possible exception of a double, which
- may be returned in D0 and D1 (but check your compiler documentation)).
-
- Basically, A0,A1,D0, and D1 are scratch registers. Any value to be
- returned will come back in D0. All others sould be the same on exit as on
- entry.
-
- I know that all the libraries on the Amiga (except where noted) follow
- this convention.
-
- -spc (And you would think they would make it more visible than they do
- the RKM's 8-)
-
-