From harmony-dev-return-17522-apmail-incubator-harmony-dev-archive=incubator.apache.org@incubator.apache.org Mon Oct 30 03:21:54 2006 Return-Path: Delivered-To: apmail-incubator-harmony-dev-archive@www.apache.org Received: (qmail 22156 invoked from network); 30 Oct 2006 03:21:52 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 Oct 2006 03:21:52 -0000 Received: (qmail 99548 invoked by uid 500); 30 Oct 2006 03:22:00 -0000 Delivered-To: apmail-incubator-harmony-dev-archive@incubator.apache.org Received: (qmail 99516 invoked by uid 500); 30 Oct 2006 03:22:00 -0000 Mailing-List: contact harmony-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: harmony-dev@incubator.apache.org Delivered-To: mailing list harmony-dev@incubator.apache.org Received: (qmail 99507 invoked by uid 99); 30 Oct 2006 03:22:00 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 29 Oct 2006 19:22:00 -0800 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=RCVD_IN_BL_SPAMCOP_NET,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of gcjhd-harmony-dev@m.gmane.org designates 80.91.229.2 as permitted sender) Received: from [80.91.229.2] (HELO ciao.gmane.org) (80.91.229.2) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 29 Oct 2006 19:21:46 -0800 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1GeNiG-0007uZ-HN for harmony-dev@incubator.apache.org; Mon, 30 Oct 2006 04:21:24 +0100 Received: from gw.nsib.ru ([217.117.80.2]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Oct 2006 04:21:24 +0100 Received: from alex.astapchuk by gw.nsib.ru with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 30 Oct 2006 04:21:24 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: harmony-dev@incubator.apache.org From: Alex Astapchuk Subject: Re: [drlvm] Class unloading support Date: Mon, 30 Oct 2006 09:21:14 +0600 Lines: 50 Message-ID: References: <5836de490610240251p120dfa56x736fbb5eb1898aca@mail.gmail.com> <12385bbd0610290613j143aa91co2b02e5d486a14211@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: gw.nsib.ru User-Agent: Thunderbird 1.5.0.7 (Windows/20060909) In-Reply-To: <12385bbd0610290613j143aa91co2b02e5d486a14211@mail.gmail.com> Sender: news X-Virus-Checked: Checked by ClamAV on apache.org Ivan, Ivan Volosyuk: > On 10/29/06, Alex Astapchuk wrote: >> Mikhail Fursov: >> > On 10/28/06, Alex Astapchuk wrote: >> >> >> >> Aleksey, >> >> >> >> > 1. Mark and scan based approach. >> >> > 2. Automatic class unloading approach. >> >> >> >> In the #2, is there any chance for other components to be notified >> about >> >> unloaded classes? >> >> >> > >> > Alex, >> > I asked Aleksey about the same feature some time ago. I was >> interested if >> > it's possible to deallocate profiler's data in EM for unloaded >> methods. The >> > answer was: OK you will get a callback from VM. So, this feature is >> in the >> > design. Let's wait Aleksey to give us more details about it. >> >> Hmmm... Yes, some more details would be nice. >> If I get it right, in case of automagic unloading, GC does all the job >> without a knowledge whether it collects a class, a classloader or >> whatever else. >> Perhaps I'm missing something, but to provide a callback on class >> unloading, the GC must know the semantic of the object being collected. > > The callback will be called by class unloading implementation (for > #1). It will definetly know everything about classloader being Sure, I see no problem with #1. But I'm really curious how the callback can be implemented in the *second* approach - with automatic class unloading. -- Thanks, Alex > deallocated. EM just needs to make relation between its data > structures with corresponding classloader and free them by request. >