Hello John, Hmmm, in my experience the CPU load reported by the getrusage function under Linux is quite reliable.
I do not know how I could use the parallel port to show which thread is running in a multi-threaded program like Linrad. As I understand it, threads can be stopped at any point in case the scheduler thinks it has been running too long. Sending a message to the parallel port saying one particular thread is waiting on a semaphore will not show all the times when this particular thread is not running. There is another way however. I can set silly parameters in Linrad to provoke the CPU load to grow up to the point where screen and mouse become affected. Under Suse 9.1 this happens when the Linrad CPU meter shows 102% when I run Linrad-02.28 on the Pentium III. With exactly the same parameters, (2 RF channels, fft1 window power of sin=6, fft2 window power of sin=2, slowest possible fft routines and 2 x16 bits for audio output ) Linrad-02.21 runs happily at a CPU load of 50% and I setting maximum window parameters does not cause more than 60% CPU load with not even the slightest trace of any overload problem. There is a real problem here. I have no idea what it is but I have verified that it is present under good old Red Hat 9 which still has the old implementation of getrusage which reports CPU load individually for each thread:-) Under RH9 I do not see the problem with normal parameters as those ones Daniel sent, but when setting silly parameters I see near 100% load with 02.28 while 02.21 shows only about 50% load. I can see that the wideband dsp thread (fft1 + fft2) increases from 40% in 2.21 to 80% in 2.28. I do not know why this happens, but I can easily use the parallel port and an oscilloscope as you suggest to find out where this particular thread spends its time in case some simple writes to the screen will not show it. I am pretty sure I did something silly. Hopefully I can correct it without introducing new problems. 73 Leif > My experience with the OS telling me what the OS is doing is not good. > Of course there are 'reasons' for whatever OS behaviour! But generally OS > numbers about OS usage are in my experience, total garbage. > > I find it better to put a bit out to the parallel port and measure what > is going on with an o-scope. 1 = busy, in linrad, whatever; 0 = in OS > (whatever that means). There are many parallel port bits so they can allow > one to time various routines, etc. > > If you do do this experiment, be prepared for the REAL surprises!! > > Just my humble opinion !! > john > > > > On Sun, 8 Apr 2007, Leif Asbrink wrote: > > > Hello Daniel, > > > > Thanks for info:-) > > > > I am now able to reproduce similar results - but I > > have no idea at the moment what they mean. > > > > I am looking at CPU load with and without sound output. > > Under Suse 9.1 I observe the following: > > Linrad-02.21 Linrad-02.28 > > PIV 2.66 GHz, Sound ON 8.3% 7.8% > > PIV 2.66 GHz, Sound OFF 4.3% 3.9% > > PIII 800 MHz, Sound ON 24% 28% > > PIII 800 MHz, Sound OFF 15% 17% > > It is similar with svgalib, the X11 server is innocent ;-) > > > > > > I have tried Red Hat 9 (kernel 2.4.20) on the Pentium III > > and I find 20% with sound on and 12% with sound OFF. It > > does not matter whether I try 02-21 or 02-28. > > > > I will try some other Linux distributions on the > > PentiumIII to see if something interesting can be > > detected. > > > > > > 73 > > > > Leif / SM5BSZ > > > > > > ############################################################# > > This message is sent to you because you are subscribed to > > the mailing list <linrad@antennspecialisten.se>. > > To unsubscribe, E-mail to: <[EMAIL PROTECTED]> > > To switch to the DIGEST mode, E-mail to <[EMAIL PROTECTED]> > > To switch to the INDEX mode, E-mail to <[EMAIL PROTECTED]> > > Send administrative queries to <[EMAIL PROTECTED]> > > > > > ############################################################# > This message is sent to you because you are subscribed to > the mailing list <linrad@antennspecialisten.se>. > To unsubscribe, E-mail to: <[EMAIL PROTECTED]> > To switch to the DIGEST mode, E-mail to <[EMAIL PROTECTED]> > To switch to the INDEX mode, E-mail to <[EMAIL PROTECTED]> > Send administrative queries to <[EMAIL PROTECTED]> > ############################################################# This message is sent to you because you are subscribed to the mailing list <linrad@antennspecialisten.se>. To unsubscribe, E-mail to: <[EMAIL PROTECTED]> To switch to the DIGEST mode, E-mail to <[EMAIL PROTECTED]> To switch to the INDEX mode, E-mail to <[EMAIL PROTECTED]> Send administrative queries to <[EMAIL PROTECTED]>