[comp.sys.mac.programmer] Low-memory Globals under Multifinder

jonp@motbos.UUCP (Jon Parmet) (10/21/88)

Could someone (maybe at Apple?) provide some insight on accessing low-memory
globals from 'C'. 

I'm particulary interested in the behavior of CurDirStore and SfSaveDisk. Under
multifinder, I bring up two applications ( only 1 meg :-( ), invoke standard 
file in each and attach to two different directories in each. When I switch 
back and forth, I am in the directory I was when I suspended it, as expected. 

Are separate copies of CurDirStore and SfSaveDisk maintained by the system for
each appl. and swapped in accordingly? If my program is running in the
background and I write to either/both of these (neither tech note 47 nor 80
mention the implications of writing to these under multifinder), will I cause
a foreground appl. to use those settings the next time it calls SF? I have no
problem saving/restoring the settings if I'm running in the foreground,
although it doesn't appear that I need to in the foreground. I don't
necessarily intend to write to them from a background application, but I am
interested in what behavior is to be expected in all cases and if I should
expect thses things to change when apple does the major rewrite of the OS.


Any tips would greatly be appreciated.


Regards,


-- 
Jon Parmet @ Blackhole Technology, Inc., Winchester, MA, 1-800-621-0039
UUCP: {hplabs!motsj1, decwrl!decvax, gatech!mcdchg, apollo,
      arla!oakhill, apps!oakhill, mnetor}....!motbos!jonp

alexis@ccnysci.UUCP (Alexis Rosen) (10/23/88)

I believe that low-memory globals are swapped out for both major and
minor context switches.

----
Alexis Rosen                       alexis@dasys1.UUCP  or  alexis@ccnysci.UUCP
Writing from                       {allegra,philabs,cmcl2}!phri\
The Big Electric Cat                                       uunet!dasys1!alexis
Public UNIX                           {portal,well,sun}!hoptoad/