cchang@acsu.buffalo.edu (Chengping Chang) (12/09/90)
I am programming in Xm under SCO UNIX in a 386 box with 16 Meg memory. After I run several large programs, I use up all the memory and system starts memory paging, which slows down system dramatically. I hope someone can shed some light on the following questions: 1) The size of motif programs seems abnormal huge: a compiled execute file as simple as "Hellow World" occupies almost 1 mega bytes. I do not know whether the problem is unique to SCO UNIX. Is there any way to reduce the size of the program? How it works at the other environments. 2) I have several huge programs each with hundreds of Widgets. Atter I load some of my programs, the numerous widgets created engulf all the system memory, and the system performance deteriorates. I have already tried to reuse, reconfigure the windows as much as possible, but I still have scores of windows and hundreds of Widgets. For performance sake, I create all the widgets at start up, leave them there, just change attributes, managed and unmanaged them according to user's response. Am I terribly wrong? Thanks in advances. Hweida Jian, 12/07/90
marbru@attc.UUCP (Martin Brunecky) (12/11/90)
In article <49973@eerie.acsu.Buffalo.EDU> cchang@acsu.buffalo.edu (Chengping Chang) writes: > > I am programming in Xm under SCO UNIX in a 386 box with 16 Meg memory. >After I run several large programs, I use up all the memory and system >starts memory paging, which slows down system dramatically. > >1) The size of motif programs seems abnormal huge: a compiled execute file > as simple as "Hellow World" occupies almost 1 mega bytes. I do not know > whether the problem is unique to SCO UNIX.... Not unique. Note that the way Motif is structured, even such a simple program as HelloWorld sucks in the entire toolkit. It is assumed that Motif will be a shared library, however, there are only few op. systems that can do that ... > >2) I have several huge programs each with hundreds of Widgets. > Atter I load some of my programs, the numerous widgets created engulf > all the system memory, and the system performance deteriorates. After Motif 1.0, OSF had *recognized* that there is a memory problem. So Motif 1.1 is better, and hopefully the next release will be even better and so ... Unfortunatelly, the way Motif classes are defined, they are huge and there is no way you can cut down on lets say PushButton (of courcse, you can use gadgets, but the client side instance isn't much smaller). So the only answer - except for creating/destroying objects on fly, which yealds abysmal performance as well - is: BUY MORE MEMORY ! For example, SPARCstation with 8MB is an underdog with ANY flavor of X, not only Motif. Add 4 more MB and the world suddenly looks much brighter. [Sometimes I suspect that Athena was not funded by DEC and IBM, but by the Japanese chipmakers -)] However, You'v got 16MB, which should be plenty ... It sounds like something somewhere is not doing garbage collection right. Especially if, as you say, it happens "after running several programs". That sounds like memory leak in the server.... With repeated runs of the *same* program, the server size should NOT be growing. If that's not the case, you'v got the case to go after SCO -). -- =*= Opinions presented here are solely of my own and not those of Auto-trol =*= Martin Brunecky {...}sunpeaks!auto-trol!marbru (303) 252-2499 (sometimes also: marbru@auto-trol.COM ) Auto-trol Technology Corp. 12500 North Washington St., Denver, CO 80241-2404