[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: KConfig memory usage / .kderc
From:       Andreas Pour <pour () mieterra ! com>
Date:       1999-05-15 21:49:35
[Download RAW message or body]

pbrown@redhat.com wrote:

[ ... ]

> In worse news, I now realize that we are wasting between 30 and 50k of
> memory each time we create a new KConfig object.  This is because of all
> the key,value pairs that are contained in ~/.kderc.  It has ballooned up
> quite a bit recently, too.  Each time a KConfig is created these global
> entries are included in addition to any config-file specific entries.  It
> is data so it is not shared.  Thus if you have 10 KDE programs running on
> your system (and we usually have at least that many) you are wasting at
> least 300-500k.  That's pretty senseless.
>
> Any ideas about how to get these values into some sort of shared memory
> area?

How about a binary file with locking?  Would be useful to have a locking
library in kde anyway, seeing as a lot of libraries could use this feature to
avoid data duplication.

The trick is getting the locking to work across all supported systems and
NFS.  Once that is done, the first program to start gets the lock, parses the
config file, creates the binary version, releases the lock.  Everyone else
can just read the binary file quickly (since they use the same library, they
have the same data structures :-)  ).

Regards,

Andreas Pour

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic