Running the SAS· System Under 386 Multitasking Software Julie Maddox, SAS Institute Inc., Cary, NC

ABSTRACT The DESOview SETUP program lets you tell DESQview how you want your system CQrtfigured and how you would like the The ability to muttitask is fast becoming a necessity in the world DESOview system options set. The Performance Setup options of personal computers. The virtual mode of the 80386 mlcropro­ control the amount of processing time DESQv1ew allocates to the cessor has made multitasking viable. This paper discusses how foreground and background tasks. Since the task processing to run the SAS System for personal computers under OESOView time can be altered dynamically, it is probably best to accept 386. " Windowsf386, PC-MOS®1386, and VMf386~ DESQview's default values for these options.

Creating the DESQv!ew 386 Program Information File for the INTRODUCTION SAS System

The fntef0 80386 microprocessor has opened up a whole new For DESOview to run SAS software or any other program, you W()rtd of computing power for those of us who are always trying must relay some basic information, such as the amount of mem­ to do several tasks at one time. The 386 processor supports mul­ ory to allocate and where the system files are located. This infor­ tiple virtual machines that' can run applications in a multitasking mation is communicated via the DESOview program information environment as if each task is running on its own BOB6 machine. file (OVP). Some of the options defined in this file depend on what Although only one application has control of the central process­ type of jobs you plan on submitting during the SAS session, For ing unit (CPU) at any given instant, the multitasking software example, if you want to run SAS/GRAPH® software or if you plan passes control back and forth between the different tasks such to download a file using the micro-to-host, link. then you have to that they all appear to be executing simultaneously. change some of the DVP options.

Four of the most popular 386 multitasking environments include: The Change A Program menu is shown in Figure 1, with the typical OESQview 386 by Quarterdeck Office Systems, Microsoft Win­ options that should be set tor a base SAS session. The Memory dowsf386 by Microsoft Corporation, PC-MOS/386 by The Soft­ Size option specifies the minimum amount of memory the SAS ware Link, and VM/386 by Intelligent Graphics Corporation. System needs to come up in the interactive display manager DESOview 366 and Windowsl386 both allow you to display tasks mode. The Parameters field can be used to enter SAS configura­ in a windowed environmen~ while PC·MOS/386 and VM/386 will tion options, such as -EMS ALL, or to enter SAS program names display only one task on the screen at a time. All four of these you wish to run in batch mode. To help prevent lost clusters, dis-­ packages wiN allow applications to be executed in background able the Allow Close command. This way the SAS ses­ or in foreground. Thts paper discusses how to run the SAS\!) Sys­ sion must be terminated normally (thus SASUSER and SASWORK tem fQr personal computers in these four multitasking environ~ files are closed) before the window is closed. The DESQview 386 menis. program information file shown in Figure 1 is useful for running base SAS software, SAS/STAr." SASIFSP1' SAS/A~ and SAS/ETS® software. In order to run SAS/ASSIST"" software, you DESOVIEW 386 need to change tile Program Name field to either ASSIST.BAT or SASMOUSE.BAT depending on whether you want to use a DESOview 386 is a multitasking control program developed by mouse within SAS/ASSIST. Figure 2 displays the DVP file for Quarterdeck Office Systems. DESQview 386 consists of two sep-­ SAS/ASSIST running with a mouse, arate programs. OESOview Version 2,2 and the Quarterdeck Manager - 386'" Version 4.2., Together these Configuring DESQview 386 to Run SASIGRAPH, SAS/IML, programs take advantage of the powerful features of the 80386 SAS/OC, and SAS/OR Software microprocessor to provide a polished multitasking environment. System requirements for running the SAS. System under To run SAS/GRAPH software, several options in the program OESOview 386 include information file need to be modified, Figure 3 displays the .. B03S6-based IBM® compatible personal computer DESQview information file needed to run SAS/GRAPH software. SAS/GRAPH usually tries to display graphics using the entire • 4 MB of screen. Setting the Virtualize text/graphics option tells OESQview to force SAS/GRAPH output to stay within the window borders. • Mouse (optional) To maximize performance on a EGA display adapter, disable the Share EGA when foreground/zoomed option. Thus, when the .. PC DOS or MS·DOS® Version 2.0 or later. SAS/GRAPH window is zoomed and executing in the foreground. all other background EGA graphics programs are temporarily Configuring DESQview 386 to Run with the SAS System suspended. Note: SAS/IML~ SASIQCf and SASIOR® software also display graphiCS information and thus should be configured Quarterdeck's Expanded Memory Manager (QEMM-386) can as described above for SAS/GRAPH, transform all extended memory into expanded memory. To enable aEMM~386 add a DEVICE- statement to your Configuring DESQview 386 to Run the Micro-to~Host Unk CONFIG.SYS file. This Is normally done automatically for you dur­ ing the QEMM-386 installation process. In addition, if you plan To execute the SAS micrcrto-host link under DESQview. modifi~ to use a mouse with OESQviaw, you need to add a OEVICE= cations need to be made in the DVP file. Also a DOS batch file statement to load your mouse driver.

537 is used to invoke the communications program and the SAS Sys­ • IBM compatible personal computer with an 80386 tem. The DVP file for the micro-ta-host Imk is shown in FlQure processor or equipped with an Intel Inboard"" 386/AT 4. • 4 MB of Extended Memory The most critical setting in the DVP file for the micro-to-host link is disabling the Can be swapped out option. Communications pro­ • Microsoft Mouse (strongly recommended) grams must be managed at all times. Thus, they cannot be • PC DOS or MS-OOS Version 3.1 or later. swapped out of memory to disk. Otherwise data are lost, and the PC will probably lock up, requiring you to reboot the machine. Also, in order to run the micro-to-host link in the background, Configuring Windowsj386 to run the SAS System make sure that you do not have a mouse oonflgured to use the same port as the asynchronous communications line. Note that Windowsf386 allows each application to allocate up to 640k of a DOS batch file, such as the one shown below, is used to startup . In addition, each application can access the communications program and then to invoke the SAS Sys~ expanded memory. All memory on your PC should be configured tem. as extended memory and any EMS device drivers in your CONFIG.SYS file should be removed. U you plan to use a mouse CD \ll:t.1NK with Windows/386, you need to add a DEVICE - statement that TTY loads your mouse driver. 'AS

Finally. depending on the communication program being used, The WIN.JNI file contains settings for Windows/386 features. Sys­ you may need to increase the Memory Size option. tem settings such as c~or pr.eferences, mouse acceleration. and default fonts or printers can be changed using the Control Panel. The most notable windows configuration options are Multitasking and Performance Issues WINOOWM£MSIZ£ and £MMSIZE. The WlNDOWMEMSIZE tells Windows/386 the maximum amount of memory anyone applica:­ The SAS System for personal computers can be executed in tion can allocate. The EMMSIZE fixes the maximum amount of either foreground or background. In fact multiple SAS sessions extended memory that can be used as expanded memory at any can be run simultaneously. The only restriction is that each SAS one time. Set these two options as follows: session should have its own SASUSER and SASWORK subdirec­ tories. You can ensure this by invoking each SAS session from "'iw.:lrn_elll$i;$"'6~(j a different directory. or by inserting the ..sASUSER and emms.he= -sASWORK options in the Parameters field of the program infor­ mation fi1e. Also, you should not attempt to share SAS data sets Creating the Program Information File for the SAS System 'or catalogs. Unpredictable results, including data corruption. may occur. The program information file (Plf) contains information about how the SAS System wlll use system resources and memory. You As you start multitasking you will notlce a perfonnance degrada­ will probably want to have several different PIF files for running tion. DESQview atlows you to change the foreground task and the SAS System under different scenerios. For example, the PIF the system options dynamically. Ftgure 5 shows the performance fiie for running SAS/ASSIST software would be different from a options that can be modified in-stream. To increase the perfor­ SAS session executing the micro-ta-host link. mance of the foreground task. you should look at the Share CPU, Share EGA. and Allow swapping out options. If you disable 111. The Windows/aS6 Program Information Editor with the typical Share CPU option, then all other background tasks are sus~ settings necessary for a basic SAS session is shown in Figure ponded. Also, if you are working wi1l1 SAS/GRAPH software 6. The first four entries provide basic program information. The using an EGA adapter,. then you can tell DESQview whether to Program Parameters field can be used to enter SAS program allow background tasks to share the EGA device. Finally, dis­ names to run in batch mode, or to enter SAS configuration abllng, theAJlow swapping out option ensures that the current task options such as -EMS ALL. The KB Required entry lists the mini­ is always in memcuy and will not be swapped out to the hard disk. mum amount of memory needed to bring the SAS System up in fun~screen mode. The Usage Control options chosen will enable There are also several OESOView system options that can be the SAS System to run inside a window and in the background. dynamically modified to improve performance. You can control The Close Window on Exit option will close the application only the number of clock ticks to allocate for foreground and baek~ after your SAS session has been terminated normally by either ground tasks. If you u,ually perform lightforeground tasks (such a BYE or ENDSAS command. as ediflng your SAS programs) and heavy background process­ Ing (such as sorting a large SAS data set) 1I1en you win probably The program information file discussed above is useful tor run­ want to increase the time allocated to the background task. Also, ning b .... SAS software, SAS/STAT, SAS/GRAPH, SASIFSP, you can set a global system option that prevents any task from SAS/AF, SAS/IML, SAS/ETS, SAS/OO, and SAS/OC software. being swapped to the hard disk. Configuring Windowsf386 to Run SAS/ASSIST Software

MICROSOFT WINDOWS/386 SAS/ASSIST software can run under Windows/386 either with or without a mouse. If you plan to run SAS/ASSIST software with !3S6 (Version 2.1) is a multitasking control a mouse, then modify the program informatiOn lile as shown in program developed by Microsoft Corporation. Windows/38G Figure 7. When your application runs inside a window. takes advantage of the 80386 microprocessor to provide a com~ Windows/386 has complete control over the mouse, Setting the plate multitasking environment. Note that Windows/386 provides Usage Control option to Full Screen tells Windowsf386 to allow a user interface consistent with the OS/2- presentation manager. the application. SAS/ASSIS"f software, to use the mouse. Note, Windows/386 automatically provides expanded memory support, even though the Full Screen option is set, programs generated so no additional EMS software is required. System requirements by SAS/ASSIST can still execute in the background. In addition, for running the SAS System under Windows/386 include

538 the mouse driver for SAS/ASSIST software must be loaded Configuring PC-MOS/386 to Run the BAS System before invoking Windows/386, so your AUTOEXEC.BAT file should include statements similar to those shown be;ow: PC-MOS/386 is very similar to the DOS . Sys­ tem configuration options are entered in the CONFIG.SYS file, If d \SAB KENU SASHOUSE you plan on using EMS then you will need to add a OEV1CE= cd \1(183:86 statement in your CONFIG.SYS file that tells PC-MOS how much WINl86 extended memory is to be configured as expanded memory. set~ tin9 this option can be tricky. especially in determining the .buffer Because we are invoking the mouse driver in the address to be used for . Refer to the PC-MOS AUTOEXEC.BAT Iile, SAS/ASSIST software should be invoked documentation for details on how to configure your system. using ASSIST.BAT rather th.n SASMOUSE.BAT. If you wish to run SAS/ASSIST without a mouse, then you should disable the Running the SAS System under PC-MOS/386 Fuji Screen Usage Control option. .~ PC-MOS/386 starts only one session when the system is booted. Configuring Windows/386 to run with the Micro-to-Host Link The ADDTASK command tats you create new virtual machines to run additional tasks. One session is always operating in the fore­ To execute the micro~to~host link under Windows/386 you will ground and all other sessions are running in the background. need to create a DOS batch file to startup_the communications Since PC~MOS/386 does not support windowing, the foreground program and then invoke the SAS System. The program informa­ session occupies the entire screen. tion file for the- micro-to-host link Is shown in Figure 8. The DOS batch file, M2HLlNK.BAT. should be similar to the one shown Executing the SAS System under PC-MOS/3B6 is essentially the below; same as runnIng under OOS. PC-MOS does not require program

e(l \RLINX information files. To invoke the SAS System simply type SAS at tTy the MOS command prompt. With no additional commands, you $AS may execute any statements in base SAS, SAS/STAT, SAS/FSP, SAS/Af', and SAS/ETS software. In addition, you may need to alter the KB Required option to allow additional memory for your communications program. Also, in Running the Micro-to-Host -Link and SAS/ASSIST Software order to execute the micrQ-to-host link in the background, make with PC-MOS/3SS sure that your mouse does not share the same port as yoor asyn­

chronous communications line. In order to execute the micro-to-host link under PC~MOS/386, you need to issue aMOS USEIRQ command before running your Multitasking and Performance I$$ues communications program. The MOS USEEIRQ command lets you reserve control of the communications port for a task:. Once the Under Windowsj386, the SAS System can be executed in back­ port is reserved, you can startup your communications program ground or in foreground, In fact, you can have multiple SAS ses­ to set up the asynchronous connection. Note the micro-to-host sions running simultaneously. The only restriction is that each link can run either in foreground or baCkground under SAS session must have its own unique SASUSER and SASWORK PC-MOS/;l86. subdirectories. To accomplish this, change the Initial Directory option in the PIF file to start each SAS M$SiOn from a different If you plan on running SAS/ASSIST software with a mouse you directory. Also, note that you should not attempt to share SAS need to first reserve the mouse port. Once again, you should use data sets or catalogs. Unpredictable results, including file-corrup­ the MOS USElRQ command before invoking SASMOUSE.BAT. If tion. may occur. you do not want to use a mouse with SAS/ASSIST software, then invoke the ASSIST.BAT fUe at the MOS command prompt. As you start mWtitasking in Windows/3B6. you wUi notice a per­ fonnance degradation. The Control Menu allows you to dynami­ Running SAS/GRAPH, SAS/OR, SAS/QC, and SAS/IML cally change the tasking options from the Settings dialog box. The Software under PC-MOS/3SS Settings dialog box shown in Figure 9 allows you to set the fore­ ground task to run exclusively or conversely to temporarily sus­ In order to execute SAS/GRAPH software under PC-MOS/SS6, pend execution. This menu affows you to set and adjust the you need to make sure that the video mode for that session is priority of the tasks you currently have: executing. set correctly. By default, each session is brought up in eGA mode. ~f you have a different type of display adapter you should issue the MOS VMODE command to alter the video mode for that PC-MOS/386 session. Note that if you select EGA or VGA mode for a task, then when you switch out of that task all processing in that session The Software link's PC-MOS/386 Version 3.0 is a moduiar oper­ is temporarily suspended. Thus. EGA and VGA graphics will only ating system designed to provide multitasking and multI-user. display when that task is in the foreground. Since SASIOR, capability. PC-MOSf386 completely replaces the DOS operating SAS/QC, and SASllML software also display graphic informa­ system. PC·MOS provides a software driver that wilt convert tion. the video mode should be set as discussed above before extended memory into expanded memory. System requirements executing any of these products. for running the SAS system under PC-MOS/386 include • ISM Compatible Personal Computer using 80386 processor

• 4 MB of Extended Memory.

539 Multitasking and Performance Issues PC-MOS is a ,trademark of The Software Link.

PC-MOS/386 does not dynamiCally vSty the memory allocated to VM/386 is a trademark of Intelligent Graphics" Corporation. the different tasks. Once you have allocated memory to a ses­ sion. no other task can access that memory. You can change the Figure 1 DESQview 386 Program Information File for Base SAS amount of memory assignad to a task by using U1e MOS RESIZE Software command. In addition, PC~MOS/386 provkles several utility com~ mands that allow to change the priority and- amount of pro­ you ",. .,._ .. cessing time each task receives. By default. each task gets an equal share of CPU processing time. The MOSADM SLICE com­ X6=ry She {in 1<), 'ne mand lets you increase or decrease the number of clock ticks each task receives. PC-MOS/386 documentation suggests that a SLICE of four time ticks is a practical limit (PC-MOS User guide nirecwry., C:\SAS CIlapter 6, page 27), The MOSADM PRI command lets you control w...it"" toort di:r;«<:U)' to "ere...... _.: fill the priority assigned to each task. The task with the highest prior' D:l%plll1& IFa¢l1= in!~n .. tion".·._."! rill ity wiH always receive processing time as long_as it is needed. vinu"liz .. t~xt/'~r"-pltic,, {y.N,'T) ••••. , tYj \I""", ...... ,;0.1 p"'rt» !Y,II.1 ...} ...... ~ [Ill Then processing time is passed on to the lower priority tasks. Re4U'''''$ noppy

Under PC-MOS/386, the SAS System can be executad in fore­ Cball\le ,. 1'1:<>9"""" MV~"""" ept:i<>"" ground or in background. In fact multiple SAS sessions can be s:rst... KeliOory {in II)... Mild_.. "", prO Exp&!>ded MttDary Size (in K" S&S8lon must have its own unique SASUSER and SASWORK sub-­ directories. You can ensure this by starting each session from \iin Width., ao Startinq widtb.: nart:inq COl""", data sets or catalogs. Unpredictable results, lnctuding data cor­ ruption, may occur.

C1",* ¢l'l e"~t ('{,II,blank) ••••••• (V) U"..,. lts <>1m ""1"'"' ...... , tT] 1>11""" e10M IUI'>d<>I< "o~.. • (lI) Runs 1" blockgro>uM (Y,N,l>la"I<).. tV) Uses _th =processor •••.•••.•• , {l} JC"ybmord nflict {O-4}...... • TOI $l>a" .. <::fU ""en (o"'.... "'" ''''''pp"d <><>t {Y,M,bhnk)., [J ProteetiOl'! 1"".. 1 i\l~l),"."",.,.' [0] VMf386 is a multitasking control program developed by Intelligent Graphics Corporation. VMf386 divides your computer into multi­ ple virtual machines that operate independently. In fact, you can Figure 2 OESQview 386 Program Information File for reboot the foreground session wUhout affecting any other tasks SAS/ASSIST Software with a Mouse that are running in the background. Currently, the SAS System cannot execute under VMJ386 Version 1.20. However, the deve!-­ ~, ," ~ I opers at Intelligent Graphics are looking into correcting this prob­ SAS/MlS1ST ""tt""" .. .. itll ...,,"'" lem in a future release. Mmoory Siz.. (in 19' 330

SUMMARY Di".. ctory.: C'\ASSIS'l

WI:'j,t.. ", u~t .H ...... tly to" _"I)"" ...... ~ {If} Thera are two Cia_at wjnnets when it comes to multitasking With Displays 91:'aplti= information " p') V1rtualiu h:rt/9"'''-pt

Although the SAS System can run under PC-MOS/386, the inter- S)"I't.. ,. _ry lin H •• ,.·.·< 1ace is not user friendly and system configuration can be difficult. script: Imff.", Size.

Currently the SAS System will not executa: undBf VMJ386 Version Te"t P"qes, 1 Grapnic" Pil'JIIS' 1 Initid_, :m"""rupts, 01} t" f1'

1.20., Intelligent Graphics Corporation is looking into correcting IUmi"", po~itlQl\' Maxi...... H .. ight: 25 starting a"i9l>t., starti.,.. Row ••• , this probfem and perhaps the SAS System will execute under a _t...... tli.dtil.: IIQ lltartillq lIi

SAS. SASIAF, SAS/ETS. SAS/FSP, SAS/GRAPH, SAS/IML, C1""" on ~:ian):) •.•••• {lj u ...... It:o ....n ':01"""'.. . .. , (¥] All"" <::lose WinaclCII...or ...... {r] lCooyboaroJ c""tHct (0-4) ••••••••••• ,g) $""... t:1"U "h.. " t<;>!;'''''!'''''''',1. ._... (Y1 Sha'N 001. ..twn f="""r""nd/~"'''''''~d.' t1l1 SAS/ASSIST andSASISTAT are trademal1lanl<). [] Pr-ot.. ctiOil level {O~J!.. .: to] Inc., Cary, NC, USA.

IBM.is a registered trademark and OS/2 tS a trademark of Interna­ tional· Business Machines Corporation. lntel-is a registered trademark and Inboard is a trademark of Intel Corporation.

Microsoft and MS-OOS are registered trademarks of Microsoft Corporation.

DESQview and Quarterdeck Expanded MemOfY Manager- 386 are trademarks of Quarterdeck Office Systems.

540 Figure 3 OESQview 386 Program Information File for Figure 6 Winoows/386 Program Information File for Base SAS SAS/GRAPH SOftware SOftware

fU~

I«>y$ 10" D"~ 'M Open """''' $(; PrOllr,." lith.. te"". SIIS Sof"twu .. l't'&i1r~ •• ,.: !!'\SJIS\.SIIS. e« Proll""" P.ua_( .. rs:, \1 ! .. itH,l I);;",,<>"o")'t iC;"'\SU 11 ...... \1 R.. "uir.-- .. ts, 1C9 !!... quir .. d ~ 1C9 !1~"ind IE!]

Writes text "irectly to. s=-e-en..... {5] Usall" Contro15< o I'~U s ...... (1 tzl.!a<>k!lroutld llisp1ay" grapt,ie" inf".-tkon" .••• ,.: (TI EXcluU".. Vtrtl>rts {T,1I,1,2l.... . (Ii' ....O!lr .... !i>!>hi.,,,Il'tulti,,i.. '.n R"q\l11C6" n,,1iWl' j" 0""". '" tnt C'llrat>l>i<>" .... T ..!(" P,n,,.,. PI for _a~ <>t>tions Press <- when you are !lONE £1001 .. Win

Syn_~ry (in K) ••••••• , Maxi...... l'roqr.... Ke=ry Si~ .. (in X). $.(:rip" 1'I.ttt.. r $11.. , • ., ... , UNO M<\Xu.u.. SJqlaruleCj' ec.lu"",",

P ..tluoaloe •• , DrO!l~"" l.ltl~: Cl<>SseWi_.. """"",,,,,""",,, III) lruns 1" bAIoM {1r,lI,bUnltj, IY] Prtl>jra.. !ara,""f"~". lJ= ....t.h ooprl!s""r...... III Keyl><>ard conn!.et {l,}-~)...... (oJ Share CPU -.. !<>~q;r<>I1ntn lew>t ((>-1) {OJ &"",ry fI .. " .. ir...... ncs' 1C9 ft.qui ... d Press n Cor standaJ"U!,,,,n o E:!clusi"" Pf"ogr".. !";'C"h O ...... ~o<>t Orut * G.. "lIhi<>,. .... Hultl.l.l .. ron S<>r .. " .. !),cban".. OHene OS,u.. hi<>" .... r .. n Figure 4 DESQview 386 Program Information File for the Micro~ flo" .. l,Iin

."". ."", Figure 8 Windowsf386 Program infOfmation File for the Micro4o~ Host link """"<>'CY 512 .. (it>. K)t 110

P"ollr_ ~ .... , Optl""", Wd.~ text directly tc "cr.... "., ..... , {If) Ill''',,,,,,,, lil:l .. , Di"plays ..rapt>ics infor.at.ion..... iN) vi""","",H~ .. '"""'tj"1""P""c~ {.. ,Ii,"") ••••• , tYJ I'~o"r .... £ .... " ... ""' .. 5' Uses .... rial t>Ct"ts (I',U,1,2j •••••• , ••• • (1') R.. qui .... " noWY diskette. {Ii) Initial D"" .. .,tory. ~....,,,,y R .... llh_M~l 1C9 .!!;Mllir.,d @:ill 1C8 !! .. si""d rE!l Un" .. ControJ,t;1 0 FyJ.l Scr",,,, iZ:l.!!.acl<'l"oh h~t $"r .. "" £:O«;ha"ll" O«<>n. o GUl'hi<>".... re1<.t: script lI"ffe.r Sh" ••• " •• , lWO l'I~xi"'''1I Ex{>and

Text P"",,, .. , 1 Q:aphl.c" Page'" 1 Initial !!ode, , 00 to ff

Window _1£10~, Ka,,,bull lleiqht.: 25 Starting :1\0..... ; t\aX1JlUII W!dth.l Bli $~rti~q ~l"""" Figure 9 Windows/386 Settings Dialog Sox

Cl"",.. WI .,>d ..... : (lil lruns in b«ckg:r:ot&ction l .."d (O-J)...... (01 Pre"" <- wh .. n you are DONE E""c$U.... Figure 5 OESQview 386 Tune Performance Window t",sk""!01 Ih>ti.. "" o E.ar.. ,round I (luN.Dat ..... ) "'no ~rt:ont.ance _.!!.",,,,k9uund o E.l:clusiv.. 00"' <- This li'indOll

When in t'creground: Share CPU .•••••.• ['1 Share EGA .••••••. ['1 Run in background .. ['l Allow swapping out. [YJ System Foreground ticks, [ '1 eaekqroUtld ticks, [ 'J Allow swapping out; ['1

541