Op wo, 19-04-2006 te 14:31 -0400, schreef Youness Alaoui:
> On Wed, 19 Apr 2006 13:05:22 -0400, Karel Demeyer <[EMAIL PROTECTED]>
> wrote:
>
> > Op wo, 19-04-2006 te 12:35 -0400, schreef Youness Alaoui:
> >> the efforts are worth it I'm sure, and they are very well apreciated!!!
> >> I
> >> noticed some memleaks too (we have so many omg!) :
> >> open amsn, do a "llength [image names]" it should return 100s.. then
> >> connect, it becomes 200.. open a chat window, it becomes 245, close a
> >> chat
> >> window, it goes down to 235 (while it should be 200 not 235), open
> >> again,
> >> goes up to 245, close, goes down to 235.. open a chatwindow with someone
> >> else, goes up to 247, close it, goes down to 237...
> >> I noticed my amsn took a lot of memory and I had I think around 900
> >> images
> >> opened... closed all I could (user_pic, smallpic, etc... all user
> >> images),
> >> and it went down to 600.. which is still a lot..
> >
> > I really think this is fixed in the long run. We just use a lot of
> > images. Therz are some things that could be made better still .. which
> > By heart: we have per standard smiley trigger a copy of the smiley ->
> > should be saved by name or by only one trigger
> > We really use a lot pictures:
> > the scrollbar base pixmaps
> > per scrollbar widget some pixmaps (all the protocol windows, the main
> > window, every chatwindow)
> > a combobox picture
> > per smiley trigger a picture (could be enhanced)
> > per custom smiley a picture
> > dps
> > smaller version of dps for notificatio
> > tiny dp if dp_on_cl
> > the "mainbar"
> > trayicon pixmaps
> > So, I really worked on this to give 'm all a comprehensive name (check
> > my latest commits) so we can keep track of 'm very easily so we don't
> > duplicate etc. There's no substancial leak here imo.
> >
>
> yes, we do use a lot, but we use more than what we should.. I mean amsn
> just connected and it uses 100 images?? I don't see any image apart from
> the banner in the bottom and the 'choose language' image...
> and when we create a chatwindow, it create 40 images, when we destroy a
> chatwindow it destroys 10 images, while it should have destroyed 40...
> yes, we do use a lot of images, but we use them without any need for
> them!!!
I'm gonna read the rest of the mail later as I have to go now .. but to
reply on this, use:
foreach i [lsort [image names]] { puts $i}
to get a nice listing of all images and tell me which one is not in use.
I don't think we should delete dp's all time as we don't use 'm all time
and recreate 'm every time again .. though you could think of this as
only about 3 dps at once are in use.
But would it be good to have this disk-activity all the time ?
> >
> >> also, check for :
> >> info commands ::http::*
> >> there are a lot of http tokens that are never closed.. you can do this :
> >> set memleak 0; foreach tok [info command ::http::*] { catch { incr
> >> memleak
> >> [string length [array get $tok]] } }; puts $memleak
> >> it should give you how much space "as a string of characters.." (doesn't
> >> count internal representation of array and of unicoded string (2 bytes a
> >> char))) is used by those tokens... that are never [http::cleanup $tok]..
> >> after opening amsn, I think I had 100Kb used by that already...
> >
> >
> > Well; the leak I found in the balloon code and the webcam code is also
> > about arrays that are always growing and growing. So that was the next
> > thing I was looking into. I only looked for "global" arrays though
> > (those who come up in "info globals.
> > I don't have this problem with the ::http:: stuff right now. Is it
> > because I don't log in over http ? should I webcam first ? (as I found
> > some ::http:: references in msncam.tcl)
> >
>
> no, I'm loggin in with direct connect, the https are vars not commands, so
> it's info vars.. sorry about that.. and we have them probably because of
> autoupdater or the http for ssl auth or.. I don't know! anyways, it's used
> there!
>
> > Maybe I should do some:
> > foreach namespace in namespaces { namesapce eval $namespace {[info
> > commands]}
> >
> > and then check those outputs for arrays with [array exists ..] to know
> > of more arrays ?
>
> arrays appear in [info vars]..
>
> >
> > I guess we don't have any "strings or lists we keep appending stuff on",
> > right ?
> >
>
> we have plugins log, protocl/status log, but they have a limit.. they
> should probably be set to a veeeery small limit on a production release,
> and the status window should be disabeld for security reasons.. no ?
> anyways, I don't know apart from the objects for webcam/FT..
>
> >
> > Karel
> >
> >> KKRT
> >>
> >>
> >> On Wed, 19 Apr 2006 10:52:00 -0400, Karel Demeyer <[EMAIL PROTECTED]>
> >> wrote:
> >>
> >> > Hi,
> >> >
> >> > I found 2 small memleaks in webcam.tcl but as I don't know anything
> >> > about this code apart from the gui, I'd like someone other to fix it.
> >> > The first is about entries in the array 'objects' that are never
> >> unset.
> >> > Every webcam session adds info to this array which I guess could be
> >> > unset after the session or whenever it's appropriate.
> >> > The second is about the images it creates. I made it create tmpX
> >> images
> >> > as I've done in other places throughout our codebase. Every webcam
> >> > session seems to add an image that isn't destroyed. This should be
> >> > destroyed too.
> >> >
> >> > I hope all these efforts would be worth it and we'll have a less
> >> leaking
> >> > aMSN for the next release maybe ? :)
> >> >
> >> > Karel.
> >> >
> >> >
> >> >
> >> >
> >> > -------------------------------------------------------
> >> > Using Tomcat but need to do more? Need to support web services,
> >> security?
> >> > Get stuff done quickly with pre-integrated technology to make your job
> >> > easier
> >> > Download IBM WebSphere Application Server v.1.0.1 based on Apache
> >> > Geronimo
> >> >
> >> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> >> > _______________________________________________
> >> > Amsn-devel mailing list
> >> > [email protected]
> >> > https://lists.sourceforge.net/lists/listinfo/amsn-devel
> >>
> >>
> >>
> >
> >
> >
> > -------------------------------------------------------
> > Using Tomcat but need to do more? Need to support web services, security?
> > Get stuff done quickly with pre-integrated technology to make your job
> > easier
> > Download IBM WebSphere Application Server v.1.0.1 based on Apache
> > Geronimo
> > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> > _______________________________________________
> > Amsn-devel mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/amsn-devel
>
>
>
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Amsn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amsn-devel