[Tcl Java] Re: possible memory.

2000-10-27 Thread Mo DeJong
On Thu, 26 Oct 2000, Daniel Wickstrom wrote: "Mo" == Mo DeJong [EMAIL PROTECTED] writes: Mo Are you up to it? I am going to be working on this object ref Mo queue thing for some time, so if you could take a whack at the Mo Notifier it would really help. There is not going to

[Tcl Java] Re: possible memory.

2000-10-27 Thread Daniel Wickstrom
"Mo" == Mo DeJong [EMAIL PROTECTED] writes: Mo I ran the tests again, and it looks like everything is working Mo just great. I can also run some multi-threaded tests that did Mo not work in the past. Mo Are there any remaining issues we need to look at before Mo merging

[Tcl Java] Re: possible memory.

2000-10-26 Thread Daniel Wickstrom
"Mo" == Mo DeJong [EMAIL PROTECTED] writes: Mo Are you up to it? I am going to be working on this object ref Mo queue thing for some time, so if you could take a whack at the Mo Notifier it would really help. There is not going to be much Mo overlap in these changes, so they

[Tcl Java] Re: possible memory.

2000-10-24 Thread Jiang Wu
] -Original Message- From: Dan Wickstrom [mailto:[EMAIL PROTECTED]] Sent: Sunday, October 22, 2000 11:53 AM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: [Tcl Java] Re: possible memory. Jiang Wu wrote: Let's not forget there is a problem with the putting object on a queue

[Tcl Java] Re: possible memory.

2000-10-24 Thread Mo DeJong
On Tue, 24 Oct 2000, Jiang Wu wrote: That may be true for your specific case. Though, it is not true in general. One could also potentially delete the interpreter without removing the thread. For example, one may be using a pool of Java threads to do some work. One thread is retrieved,

[Tcl Java] Re: possible memory.

2000-10-22 Thread Dan Wickstrom
Mo DeJong wrote: On Sat, 21 Oct 2000, Dan Wickstrom wrote: What does your src/tclblend/tcl/lang/CObject.java finalize() method look like? I thought the last round of patches left that ptr dangling on purpose. I have not has time to Yes the finalize method just calls the super

[Tcl Java] Re: possible memory.

2000-10-22 Thread Jiang Wu
Let's not forget there is a problem with the putting object on a queue for deletion by the interpreter. As the GC may run at a random time, it is possible when a Cobject is being finalized, the associated interpreter is already deleted. 1. Create a thread, 2. Add a Tcl interpreter 3. Do some

[Tcl Java] Re: possible memory.

2000-10-22 Thread Dan Wickstrom
Jiang Wu wrote: Let's not forget there is a problem with the putting object on a queue for deletion by the interpreter. As the GC may run at a random time, it is possible when a Cobject is being finalized, the associated interpreter is already deleted. 1. Create a thread, 2. Add a Tcl

[Tcl Java] Re: possible memory.

2000-10-22 Thread Mo DeJong
Boy, I must have been on crack yesterday. The patch I posted that used a global table to keep a legal ref to a cleanup object was way way too complex. After rereading section 12.6.1 of the JLS, I realized the error of my ways.

[Tcl Java] Re: possible memory.

2000-10-22 Thread Mo DeJong
On Sun, 22 Oct 2000, Jiang Wu wrote: Let's not forget there is a problem with the putting object on a queue for deletion by the interpreter. As the GC may run at a random time, it is possible when a Cobject is being finalized, the associated interpreter is already deleted. 1. Create a

[Tcl Java] Re: possible memory.

2000-10-21 Thread Mo DeJong
On Sat, 21 Oct 2000, Dan Wickstrom wrote: What does your src/tclblend/tcl/lang/CObject.java finalize() method look like? I thought the last round of patches left that ptr dangling on purpose. I have not has time to Yes the finalize method just calls the super class finalize method.

[Tcl Java] Re: possible memory.

2000-10-21 Thread Mo DeJong
On Sat, 21 Oct 2000, Dan Wickstrom wrote: What does your src/tclblend/tcl/lang/CObject.java finalize() method look like? I thought the last round of patches left that ptr dangling on purpose. I have not has time to Yes the finalize method just calls the super class finalize

[Tcl Java] Re: possible memory.

2000-10-20 Thread Jiang Wu
You made a good catch here. Here is what I think is happening. This is a problem only when a pure Java TclObject is converted into a native C Tcl_Obj. Suppose we create a TclObject on a simple Java string "a b c" (TclString). (In your email, the TclObject is an ArrayObject, which is also a

[Tcl Java] Re: possible memory.

2000-10-20 Thread Mo DeJong
On Fri, 20 Oct 2000, Daniel Wickstrom wrote: The TclList.getLength method converts indexListObj to a TclList object which uses an underlying Tcl_Obj to hold the internal rep. At the end of this case statement, it returns leaving indexListObj with no references. The jvm garbage collects

[Tcl Java] Re: possible memory.

2000-10-19 Thread Dan Wickstrom
The last posting got mangled a little, so I'm attaching the trace file. It's probably a lot clearer than looking at my last posting. -Dan 0 ckalloc 8c5d99024./../generic/tclLiteral.c 261 1 ckalloc 8c5d9d817./../generic/tclLiteral.c 267