*BSD News Article 37751


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!msuinfo!uwm.edu!news.alpha.net!news.mathworks.com!udel!gatech!usenet.ins.cwru.edu!cleveland.Freenet.Edu!bx970
From: bx970@cleveland.Freenet.Edu (Donna A. Lilly)
Newsgroups: comp.unix.bsd
Subject: bsd process sticks in 'D' state
Date: 11 Nov 1994 07:11:59 GMT
Organization: Case Western Reserve University, Cleveland, OH (USA)
Lines: 37
Message-ID: <39v5fv$47e@usenet.INS.CWRU.Edu>
Reply-To: bx970@po.cwru.edu (Donna Lilly)
NNTP-Posting-Host: kanga.ins.cwru.edu

Hi!

I have a unix process that runs on a Sun 4/30 with 54 Mb of swap space (virtual memory) and 16 Mb real memory as shown below:

  slx1:/var/adm grep swap mess*
  messages:Nov  7 19:58:27 slx2 vmunix: swap on sd0b fstype spec size 54000K
  
  slx1:/var/adm grep mem mess*
  messages:Nov  7 19:58:27 slx2 vmunix: mem = 16028K (0xfa7000)
  messages:Nov  7 19:58:27 slx2 vmunix: avail mem = 13131776
  
The problem is the machine does not appear to be executing my program
efficiently.  The symptom is the process state is almost always 'D'
rather than 'R' or 'S' like it is on my other programs that I believe
are executing much more efficiently: 

  slx2:~ rsh slx1 'ps -aux '
  stty: TCGETS: Operation not supported on socket
  Where are you?
  USER       PID %CPU %MEM   SZ  RSS TT STAT START  TIME COMMAND
  bx970      9575 16.8 59.449088 7620 p0 D    Nov  33395:00 cdmbv
  bx970     11783 11.8  3.6  240  464 ?  R    00:36   0:00 ps -aux
  bx970     11780  8.5  4.5  116  580 ?  S    00:36   0:00 tcsh -c ps -aux
  
If anyone has any suggestions as to how to get this program running
faster I'd certainly be grateful!

P.S.  The program is a learning algorithm on a large text corpus and it
does need 49Mb of space to represent the data.  I decided to read in all
my data on startup since unix allows a process to consume essentially
all the virtual memory that's available when it starts up, and the use
of virtual memory in unix seems to generally be quite efficient
(e.g. loading a large array - like 49 Mb - with a binary disk file of
data).
-- 
        Donna Lilly
        Cleveland, OH