Bug 63548 - Juk sucks insane amounts of memory
Summary: Juk sucks insane amounts of memory
Status: RESOLVED WORKSFORME
Alias: None
Product: juk
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Scott Wheeler
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-01 02:15 UTC by Iván Sánchez Ortega
Modified: 2003-11-09 22:26 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Iván Sánchez Ortega 2003-09-01 02:15:56 UTC
Version:            (using KDE 3.1.9)
Compiler:          gcc version 3.3.2 20030812 (Debian prerelease)
OS:          Linux (i686) release 2.4.21-1-k7-smp

Hello there...

This holidays i've been playing with Juk for some time..... making it load a several *thousand* songs.
The result is that my computer gets out of memory (causing crashes to Juk, and even Kicker sometimes due to lack of free memory)
It seems to me that Juk sucks about 100KB (!!) per song loaded. That means 1000 songs = roughly 100MB of mem. Anyone having a big collection and a computer with not too much memory will have his/her system unresponsive and crashing. (anyone said Juk on radio stations?)
By the way, the crash shows when loading an entire directory full of thousands of songs. This means that it doesn't matter if Juk optimizes memory usage *after* having loaded the songs into the collection playlist, memory usage must be optimized *during* loading.

I've tested this bug with one of the lastest CVS snapshots of Juk - and the memory usage is still that bad.

Question: 
Comment 1 Scott Wheeler 2003-09-01 02:23:57 UTC
You most likely have something wrong with your system elsewhere -- I'm not sure 
exactly what. 
 
JuK uses about 28 MB of memory here for my 2500 items.  I recently did a lot of 
profiling with about 12,500 items and the memory there was always between 50-60 
MB. 
 
Many JuK users are using JuK for collections of 1000 - 20000 items and this is the 
first report of excessive memory usage that I've gotten. 
Comment 2 Iván Sánchez Ortega 2003-09-01 02:30:23 UTC
Subject: Re:  Juk sucks insane amounts of memory

> You most likely have something wrong with your system elsewhere -- I'm not
> sure exactly what.

Perhaps some problems with libraries - I'm using libid3-3.8.3 and an old 
libqt3c102-mt 3.1.1+randr-4. If you like, i can make up a list with the 
versions of all things that Juk depend onto, if that would help.

Comment 3 Scott Wheeler 2003-10-25 15:58:34 UTC
Are you still experiencing this?
Comment 4 Iván Sánchez Ortega 2003-10-25 18:56:25 UTC
Subject: Re:  Juk sucks insane amounts of memory

A fecha S
Comment 5 Iván Sánchez Ortega 2003-10-31 16:39:44 UTC
I managed to install a somewhat recent CVS snapshot of KDE - 20031020 to be precise. And I'm sorry to say that Juk still sucks lots of memory (2500 songs in main list ~= roughly 200MB of memory)

I don't know if 20031020 includes the changes to improve memory usage. Please let me know. I don't know what is causing the extra memory usage :-(
Comment 6 Scott Wheeler 2003-10-31 16:50:32 UTC
Well, the first round of optimizations were made on that day so I doubt they made it in there.  Several more came on the October 27th and the next couple of days after that.

Of course it should be noted that even in the worst case that we were profiling we were looking at about 80 MB of memory for about 15000 items.  With my collection now in the 3200 range it's about 20 MB of non-shared memory at the moment.

Are you sure that you're checked for *non* shared memory?  i.e. if you have Qt and KDE, id3lib, etc compiled with full debugging symbols the amount of shared memory being used would be especially high...

Also, are you checking just after an import or on an instance where the items were restored from the cache?  I noticed (and fixed) an issue recently where imported items (i.e. the first time that they're read) were taking significantly more memory than restored items.
Comment 7 Iván Sánchez Ortega 2003-10-31 17:10:43 UTC
Subject: Re:  Juk sucks insane amounts of memory

A fecha Friday 31 October 2003 16:50, Scott Wheeler escribi
Comment 8 Scott Wheeler 2003-10-31 19:07:05 UTC
Can you try this:

Start JuK and scan a relatively small directory; keep adding files while it's still under a reasonable size of memory consumption.

Exit JuK and restart and then note the memory consumption after the restart?
Comment 9 Scott Wheeler 2003-11-09 06:15:59 UTC
Closing this one for now since I and those that I've worked with on the memory optimizations with JuK can't reproduce this.

I'm still not sure exactly what's going on, but nobody has been able to reproduce this which leads me to the assumption that it must be something specific to your set up.

I wish that I was able to give a better answer, but from the information that's come up so far I just don't have any idea why things are behaving this way on your system.
Comment 10 Iván Sánchez Ortega 2003-11-09 22:16:21 UTC
Subject: Re:  Juk sucks insane amounts of memory

A fecha Domingo, 09 de Noviembre de 2003 06:16, Scott Wheeler escribi
Comment 11 Scott Wheeler 2003-11-09 22:26:24 UTC
Ah, great.  That makes me feel better about things.  :-)