Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!cs.utexas.edu!ut-emx!ccwf.cc.utexas.edu From: conan@ccwf.cc.utexas.edu (Robert Faulkner) Newsgroups: comp.sys.amiga.programmer Subject: Re: Instructions on 68000 Summary: Scc Instuction and its use !! Keywords: Scc 68000 Assembly Message-ID: <47118@ut-emx.uucp> Date: 12 Apr 91 21:43:49 GMT References: <4577@orbit.cts.com> Sender: news@ut-emx.uucp Reply-To: conan@ccwf.cc.utexas.edu (Robert Faulkner) Distribution: na Organization: University of Texas ccwf.cc.utexas.edu Lines: 51 In-reply-to: koleman@pnet51.orb.mn.org (Kurt "Koleman" Koller) Originator: conan@dopey.cc.utexas.edu >From: koleman@pnet51.orb.mn.org (Kurt "Koleman" Koller) >Ok, I was looking at some source in Assembly, and I saw some instructions that >I wasn't familiar with. My assembler (Macro 68) assembles them just fine, and >they ARE mentioned in the 68000 manual, but just MENTIONED. I have no idea >what they do. If anyone can help me, so be it. > > st (MemoryLocation) > sne d(n) > sf > sge >etc... > > These are not "documented" instructions. What do they do, and why would >someone use them other than to save cycles or 10? Are they also used on the >020 030 040 etc? These are Set According to Condition commands in the form Scc The specified condition code is Tested, if the condition is true, the byte specified by the effective address is set to TRUE, (all ones), otherwise that byte is set to False (all zeroes), "CC" may specify the following conditions CC Carry Clear LS Low or Same CS Carry Set LT Less Than EQ Equal MI Minus F False NE Not Equal GE Greater or Equal PI Plus GT Greater Than T True HI High VC Overflow Clear LE Less or Equal VS OverFlow Set This command is a good way to set a Boolean Flag byte in a return value for a function. As far as I know it is supported on all of the 680x0 processors. Feel free to e-mail me with any other questions. I got all of this information from the S68000 User's Guide, which only costs about $0.65 at our University Book Store. You can also call Signetics and they will send you one free, plus a bunch of other useful information on the 68000. The phone # is 408-739-7700, ask for publications department. Thanks, -- Robert Faulkner conan@ccwf.cc.utexas.edu /// Recursion: Thinking \\\/// University of Texas about \\// Amiga Computers Thinking