[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [aspectj-users] Rebuild AspectJ project after eclipse restart
- From: Andy Clement <andrew.clement@xxxxxxxxx>
- Date: Sun, 10 Oct 2010 09:57:02 -0700
- Delivered-to: firstname.lastname@example.org
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=Iu8Xl8FG12igKy2eT4xa06pFXFm+9IQZ39o0H44UAu4=; b=nBgvF/tuf14UnO+fg8RPNcsxlo3Ao1b9RzKf8a9YVJM9N6pZzziBlu55urkHZ5XvyB HrPhDjbH5rH6ahdjbSYhHyufRy7koPn/gRVyFWnLhZlcD/yzDKFFE5VqN017ZE8UizO2 IpfpYu/qlxP7v8TOtuXWUJKMYlHhuugN/TsDg=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=nbKdmDsexScnFxkqc8IQnexz57yyg8xlZOYxvb/cU9NvzPaugUkzgpeVDleURZMO91 NfMZTRT9x1g+Fe/psTAeTW49qDo5t3jO68UUmSZ4QcJ8OCqu01vbfIf8pcbQdE8gPGO/ gXWKmoWQG653xzp/H8mhHismrEDcVhVBwfm84=
Yes, that is the trade-off with using these options, speed vs memory -
but I'm not sure I would have expected them to be quite so exaggerated
typeDemotion=true - means eagerly throw stuff away that we might or
might not need later. Without demotion you run with a large heap as
everything is kept around. With it turned on you are often throwing
things away you'll need again. It isn't a particular smart algorithm
right now though, I imagine we could apply some smarts to maybe keep
things around longer that seemed to be used frequently.
minimalModel=true - this is not a trade off at all. This will save
memory *but* pieces of the model are only discarded (to save memory)
if they are not affected by ITDs or advice. This means if you have
aspects that hit only a few files in a large project, you can save a
load of memory, but if you have something like a tracing aspect that
hits 99% of your files, it won't save much at all.
If you don't think all your files are being hit by advice/itds, I'd
recommend just using minimalModel=true, to see if it helps alleviate
the GC thrashing. Meanwhile it sounds like we should look at making
type demotion smarter so that it isn't such an extreme tradeoff. I
wonder what your build time would be without the heap thrashing,
whatever that number is, it ought to be achievable with an intelligent
type demotion algorithm.
On 10 October 2010 04:45, Gil Sagi <gilmod@xxxxxxxxx> wrote:
> Hey Andy,
> When I'm building the project without the heap optimization
> (-Xset:minimalModel=true,typeDemotion=true)the heap is reaching my max
> heapsetting (~1400) which causes the GC to run again and again which seems
> to affect the performance and the full build takes about 8 minutes.
> Now when I'm trying to build with the optimization it seems there is a big
> reduction in the heap usage but the build is very very slow and takes more
> than 1 hour (it didn't finish yet...).
> So actually I cannot use this optimization although the heap state is
> absolutely better.
> Do you have any idea?
> 2010/10/10 Andy Clement <andrew.clement@xxxxxxxxx>
>> One thing:
>> On 8 October 2010 09:32, Gil Sagi <gilmod@xxxxxxxxx> wrote:
>> > Currently the Eclipse downside is the memory consumption of the weaving
>> > process - it takes about 8 minutes and the heap is getting up to 1400MB
>> > so
>> > restart the Eclipse from time to time is a use-case we cannot ignore.
>> That is a long time for a full build... Is it by any chance due to
>> the heap getting relatively full and then GC thrashing going on? (so
>> not actually running out of memory, but running on the limit). If so
>> you could try those AJDT memory settings I mentioned in the 1.6.10
>> readme, they should reduce the heap usage (if you try them and they
>> don't, that is interesting feedback...) -
>> aspectj-users mailing list
> aspectj-users mailing list