go to www.geomview.org home page
 
Home

Overview
FAQ
Documentation

Download

Mailing List

Geomview For Windows?

Support
Users
Development

Bug Reporting
Contributing
Contact Us

Sponsors

 

Site Search

 

Advanced
Search

 
About the software@geom archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ REQ 5904]: Geomview and Linux



Dear Geomview Team:

Linux has changed the way it handels named pipes, and this affects geomview
when run with the Mp option. I think the file that needs changing is
$(GEOMROOT)/src/lib/oogl/refcomm/streampool.c, where O_RDONLY should be
changed to O_RDWR. I would have tried it myself, but the sources failed
to compile. Here is the relevant exerpt from the CHANGES files from the
Linux version 2.0 kernel directory.

>  Named pipes [...] 
>  =====================
>  
>     Linux's handling of named pipes changed (it now does it The Right Way
>  instead of the SunOS way ;-).  This broke some programs that depended
>  on the SunOS behavior, [...]
>
>     The new named pipe behavior also causes problems with [...].  If
>  you're running [...], it will just keep eating up CPU time
>  until you have no idle time free.  To fix this, [...] change the line
>  
>     CONFIG_OPENFIFO="O_RDONLY"
>  
>     to
>  
>     CONFIG_OPENFIFO="O_RDWR"
>  
>     A similar method (finding all named pipes opened read-only and
>  changing them to read-write) will fix any program that is broken
>  because of this change.

This "eating up CPU cycles" behavior is exactly what happens when I
run geomview with a named pipe under X. Interestingly enough, X also
consumes more and more CPU cycles. None of this happens before the
first set of data is written to the pipe. Deleting the pipe from
inside Geomview with the delete-object command doesn't help
either.

I don't know when this change happend in the Linux kernel history, but
on any case the new stable 2.0 series has this feature.  Here is a
little example:

$ geomview -Mp pipe &
$ top
  PID USER     PRI  NI SIZE  RES SHRD STAT %CPU %MEM  TIME COMMAND            
  234 mayer      6   0 4504 3120 1504 R    12.2 13.6  0:01 /usr/local/Geomview/
   78 root      13   0 5356 2308 1320 R     4.1 10.0  1:24 X :0
$ top
  234 mayer      1   0 4504 3124 1508 S     0.0 13.6  0:01 /usr/local/Geomview/
   78 root      13   0 5356 2308 1320 R     0.0 10.0  1:31 X :0   
$ cat OFF/sphere.off >pipe
$ top
  234 mayer     14   0 4920 3484 1552 R     4.4 15.2  0:02 /usr/local/Geomview/
   78 root      15   0 5356 2308 1320 R     3.7 10.0  1:32 X :0
$ top
  234 mayer     20   0 4920 3484 1552 R    63.0 15.2  0:08 /usr/local/Geomview/
   78 root       5   0 5356 2308 1320 S    34.6 10.0  1:35 X :0
$ top
  234 mayer     11   0 4920 3484 1552 R    65.4 15.2  0:15 /usr/local/Geomview/
   78 root       3   0 5356 2308 1320 S    32.6 10.0  1:39 X :0
$ top
  234 mayer     14   0 4920 3484 1552 R    63.0 15.2  0:21 /usr/local/Geomview/
   78 root      16   0 5356 2308 1320 R    35.2 10.0  1:42 X :0
$ top
  234 mayer     17   0 4920 3484 1552 R    69.7 15.2  0:28 /usr/local/Geomview/
   78 root       3   0 5356 2308 1320 S    28.2 10.0  1:45 X :0       
$ kill %1
$ top
   78 root      13   0 5156 2112 1120 R    24.2  9.2  2:00 X :0
$ top
   78 root      19   0 5156 2112 1120 R     1.1  9.2  2:00 X :0        

I am running Linux 2.0.3 on an AMD 486DX4-100 with 24 MB RAM, with XFree
3.1.2.

I suggest you make a version of Geomview available for the 2.0 series
of Linux. This either amounts to a complete new distribution, or to
just the modified executable gvx (half a megabyte if gzipped).

Yours sincerely,
Uwe F. Mayer <mayer at math.brown.edu>


 
Home | Overview | FAQ | Documentation | Support | Download | Mailing List
Windows? | Development | Bug Reporting | Contributing | Contact Us | Sponsors
 
site hosted by
SourceForge Logo