Path: utzoo!attcan!uunet!lll-winken!ncis.llnl.gov!helios.ee.lbl.gov!pasteur!ucbvax!bloom-beacon!apple!lsr From: lsr@Apple.COM (Larry Rosenstein) Newsgroups: comp.sys.mac.programmer Subject: Re: Help With VBL Tasks Message-ID: <463@internal.Apple.COM> Date: 23 Jan 89 18:11:22 GMT References: <8343@orstcs.CS.ORST.EDU> <27628@ucbvax.BERKELEY.EDU> <451@internal.Apple.COM> <6347@hoptoad.uucp> Organization: Advanced Technology Group, Apple Computer Lines: 30 In article <6347@hoptoad.uucp> tim@hoptoad.UUCP (Tim Maroney) writes: > >However, this doesn't address the fact that you may need a different A5 >from the one in CurrentA5, which was David's point. This may happen in Definitely true. In fact, I wouldn't recommend using CurrentA5 any more. The times when you need to setup A5 are in interrupt routines, and generally, you can't count on CurrentA5 under MultiFinder. (Although I think there are some cases where it is OK to use CurrentA5, it is best not to take chances.) >like socket listeners or custom interrupt handlers. I still don't know >any way around this except for stashing a copy of your A5 in >code-relative space, which is explicitly forbidden (with good reason) >by Tech Note #2. I'm not even sure that Apple acknowledges that this >is a problem This is clearly acknowledged in Tech Note 180. Some routines that run at interrupt level are given pointers to parameter blocks, etc. where the desired A5 could be stashed. (VBL tasks are one of these.) Some routines don't have any place to store A5, so the Tech Note recommends storing the desired A5 into your code area. This applies to Time Manager tasks and interrupt service routines. -- Larry Rosenstein, Object Specialist Apple Computer, Inc. 20525 Mariani Ave, MS 46-B Cupertino, CA 95014 AppleLink:Rosenstein1 domain:lsr@Apple.COM UUCP:{sun,voder,nsc,decwrl}!apple!lsr