Path: utzoo!attcan!uunet!lll-winken!ames!mailrus!cwjcc!gatech!rutgers!att!mtunb!jcm From: jcm@mtunb.ATT.COM (was-John McMillan) Newsgroups: comp.unix.wizards Subject: Re: sticky bit Summary: Sticky Data... Sigh, yes! Message-ID: <1362@mtunb.ATT.COM> Date: 10 Jan 89 22:34:17 GMT References: <18016@adm.BRL.MIL> <14750@cisunx.UUCP> <1359@mtunb.ATT.COM> <25591@wlbr.EATON.COM> Reply-To: jcm@mtunb.UUCP (was-John McMillan) Organization: AT&T ISL Middletown NJ USA Lines: 48 In article <25591@wlbr.EATON.COM> jm@wlbr.eaton.com (James Macropol) writes: ... >I once modified a V7 PDP-11 UNIX system to save a prototype of the data >out on the swap file, too. It took about twenty lines of changes in >text.c, text.h and exec.c (I think. My memory is getting hazy). > >Unlike the standard sticky texts, this DID help shared-text programs >that already had another incarnation running, because it DRASTICALLY cut >down on the number of reads necessary to initialize the data segment (to >one). On some large programs, it cut down program load time by almost >two seconds. Yup -- 'did it three years ago on the 3B1/7300 and it was a FLASH start-up... but o' that swap space! Fortunately, the faster and faster disks have made these tricks rather unnecessary when combined with Paging. PS: 1) I agree with much of what DLM said: the SB does introduce DIS-MOUNT anomalies. One strategy is to only Stick it to ROOTDEV programs. The gain it provides on paging systems can, indeed, be very small -- particularly, when the disk was well-ordered at the time the programs were loaded, when the disk-access rates are fast, when shared libraries are used, and particularly, I would presume, if sequentially allocated disk sectors were allocated to executable files -- a trick I've heard of, but never seen. However, on the 3B1/7300, even with its paging, the times are quite measurable, Dennis! 2) In article <314@twwells.uucp> Bill writes: ... >Depends on the system. Mine will move stuff out of swap if it's not >in use and the space is needed. Read the chmod(2) manual page to see >what yours does. Nice! How common is this? What is your system? Now I've got to scurry through SVR3.2 sources, I suppose ;-{ 'Don't recall the 3B1 being that considerate, however. >I just did my editor, compiler, make, and ls. All nice packages to be sure: But with shared libraries, LS is only 2 to 4 [4K] pages of TEXT. All EDITORS are great targets: you're poised over the keyboard and their TEXT runs towards 30 pages. Shells run 10 to 20 pages, so they're a WIN. Compiler & Make? Lucky you, getting to write software! %-} jc mcmillan -- att!mtunb!jcm -- juzz muttering for hizzelf