Hello, and welcome to the list! First, thanks for helping and doing all that. I can point you to some stuff that might help you. 1 - look at debug.tcl, it has some usefull profiling and memory stuff 2 - the code you shown below is useless because the way animated images are handled is completely different. Each anigif has a CxImage associated with it which itself contains multiple CxImage objects representing each of the frames of the anigif. With your code below, you'll only get the image data stored inside of Tk's Image structure, not the memory used by CxImage in the background. 3 - Most of the plugins will not affect the memory at all, apart from chameleon plugin, that's because it uses an extension that adds a whole themeing engine, so it's normal, and yes, chameleon uses a HUGE amount of memory, all other plugins use none... 4 - what you found about the anigif taking 8MB is interesting.. I'd like to see mor eprofilign done on this.. 5 - look at the 'prof' package for tcl, it's a useful profiler, it could help you.
Thx for all! KaKaRoTo On Thu, Sep 27, 2007 at 02:30:03PM -0300, Ivan Hernandez wrote: > Hello! > > I have never developed with tcl/tk, but have been using amsn and making > customizations to the code because it's simply the only serious choice > for using msn on linux. The problem i'm looking is that the memory > footprint tends to be too big. it sometimes come near to 120mb of ram. > it's a lot, and i'm not talking about virtual memory. 120mb allocated... > on the physical ram. > > So i have started to plug off plugins, and so, and looking where does it > consumes so much memory. > > Finally i have found a way to keep it less than 40mb, but it means > saying goodbye to almost every plugin i use, and mutilating the theme. > > Some things really waste memry. For example, animated gif's. Replacing > the loganim.gif that comes with the new theme for the login with a > simple animated gif with 4kb saves almos 8mb of ram. > > That means, that there should be a lot of little things to improve. Amsn > needs a tool to see how much memory each loaded image wastes, and the > same for plugin, so one can realize what is happening. > > How could that be done on tcl? i have tried some code on the skin.tcl like: > > set imagen [image create photo ${naming}_${pixmap_name} > -file [::skin::GetSkinFile ${location} [set > ${location}_names($pixmap_name)] \ > "" [set > ${location}_fblocation($pixmap_name)]] -format cximage] > set imagen_string [$imagen data -format cximage] > puts "Pixmap size $res = [string length $imagen_string] " > > But was not much useful. I think that developers would find a way to do > this much more easy. > > Well... that's all. > Thanks for the time and i will try to be more helpful than simpy saying > "amsn is getting fat" ! > > Ivan > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2005. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Amsn-devel mailing list > Amsn-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/amsn-devel ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Amsn-devel mailing list Amsn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/amsn-devel