RE: GC options. Reply

2001-08-09 Thread Simon Marlow


> Hello!
> 
> On Tue, Aug 07, 2001 at 10:47:50AM +0100, Simon Marlow wrote:
> 
> >   - Compacting garbage collection is enabled when the residency
> > reaches a certain percentage of the maximum heap size (if there
> > is one).
> 
> Could there be the possibility to set an absolute amount of memory
> to start compacting, at least for the case of no maximum heap size?

Yes, there could be, but I don't want the GC tunables to get any more
complicated than they already are.  In this case you could just set the
maximum heap size to the size of your memory+swap and then set the
compaction threshold so that compaction would kick in at the desired
point.

Cheers,
Simon


___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: GC options. Reply

2001-08-08 Thread Hannah Schroeter

Hello!

On Tue, Aug 07, 2001 at 10:47:50AM +0100, Simon Marlow wrote:

>   - Compacting garbage collection is enabled when the residency
> reaches a certain percentage of the maximum heap size (if there
> is one).

Could there be the possibility to set an absolute amount of memory
to start compacting, at least for the case of no maximum heap size?

Kind regards,

Hannah.

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



RE: GC options. Reply

2001-08-07 Thread Simon Marlow


> "Simon Marlow" <[EMAIL PROTECTED]> writes:
> 
> > Ok, I've done the following:
> 
> >   - disabled the maximum heap
> 
> >   - RTS options are taken from the GHCRTS environment variable
> > in addition to the command line (the command line has 
> precedence).
> 
> (I haven't followed this debate closely, so I may be missing out on
> something, but:) 
> 
> Perhaps it could be possible to embed a default in
> the executable as well, through a command line option to the
> compiler/linker?   You know, for the occasional program that actually
> requires more heap than one is comfortable declaring in GHCRTS, but
> one is too lazy to write a shell wrapper for?

You can do this already, though not with a compiler option.  It would be
possible to do it with a compiler option, but it would be tricky to
implement - basically the compiler would have to generate a small C
file, compile it, and link it into the excecutable, and somehow avoid
conflicting with any other hooks that the programmer had already
defined.

So, I'm enclined not to do this on the grounds that the payoff to effort
ratio is small.  But, as usual, if there's strong demand then we'll
probably do it anyway.

Cheers,
Simon

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: GC options. Reply

2001-08-07 Thread Ketil Malde

"Simon Marlow" <[EMAIL PROTECTED]> writes:

> Ok, I've done the following:

>   - disabled the maximum heap

>   - RTS options are taken from the GHCRTS environment variable
> in addition to the command line (the command line has precedence).

(I haven't followed this debate closely, so I may be missing out on
something, but:) 

Perhaps it could be possible to embed a default in
the executable as well, through a command line option to the
compiler/linker?   You know, for the occasional program that actually
requires more heap than one is comfortable declaring in GHCRTS, but
one is too lazy to write a shell wrapper for?

-kzm
-- 
If I haven't seen further, it is by standing in the footprints of giants

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



RE: GC options. Reply

2001-08-07 Thread Simon Marlow


Ok, I've done the following:

  - disabled the maximum heap size by default.  It can still be
enabled with +RTS -M

  - RTS options are taken from the GHCRTS environment variable
in addition to the command line (the command line has precedence).

  - Compacting garbage collection is enabled when the residency
reaches a certain percentage of the maximum heap size (if there
is one).

Cheers,
Simon

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: GC options. Reply

2001-08-07 Thread John Meacham

I like the enviornment variable option, I would very much like to have
part of my log-in sequence parse the output of 'free' or some other real
memory reporting tool and set the limits as appropriate for the system I
happen to be on.
John

On Tue, Aug 07, 2001 at 08:54:25AM +0100, Marc van Dongen wrote:
> S.D.Mechveliani ([EMAIL PROTECTED]) wrote:
> 
> : > Issue 1: should the maximum heap size be unbounded by default?
> : > Currently the maximum heap size is bounded at 64M. 
> : > [..]
> : >   1. remove the default limit altogether
> : >   2. raise the default limit
> : >   3. no change
> : 
> : Put the default to  30M.
> 
> That seems to be on the low side.
> Obviously people's opinions will
> always differ.
> 
> Why not introduce environment
> variables to allow for people to
> set their own defauls settings?
> 
> Regards,
> 
> 
> Marc [still lurking] van Dongen
> -- 
>  Marc van Dongen, CS Dept | phone:  +353 21 4903578
> University College Cork, NUIC | Fax:+353 21 4903113
>   Western Road, Cork, Ireland | Email: [EMAIL PROTECTED]
> 
> ___
> Glasgow-haskell-users mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
> 

-- 
---
John Meacham - California Institute of Technology, Alum. - [EMAIL PROTECTED]
---

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



Re: GC options. Reply

2001-08-07 Thread Marc van Dongen

S.D.Mechveliani ([EMAIL PROTECTED]) wrote:

: > Issue 1: should the maximum heap size be unbounded by default?
: > Currently the maximum heap size is bounded at 64M. 
: > [..]
: > 1. remove the default limit altogether
: > 2. raise the default limit
: > 3. no change
: 
: Put the default to  30M.

That seems to be on the low side.
Obviously people's opinions will
always differ.

Why not introduce environment
variables to allow for people to
set their own defauls settings?

Regards,


Marc [still lurking] van Dongen
-- 
 Marc van Dongen, CS Dept | phone:  +353 21 4903578
University College Cork, NUIC | Fax:+353 21 4903113
  Western Road, Cork, Ireland | Email: [EMAIL PROTECTED]

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users



GC options. Reply

2001-08-07 Thread S.D.Mechveliani

Hello,

here are my votes on Simon Marlow's questions.


> Issue 1: should the maximum heap size be unbounded by default?
> Currently the maximum heap size is bounded at 64M. 
> [..]
>   1. remove the default limit altogether
>   2. raise the default limit
>   3. no change

Put the default to  30M.


> Issue 2: Should -M be renamed to -H, and -H renamed to something else?
> The argument for this change is that GHC's -M option is closer to the
> traditional meaning of -H.

Yes.

> Issue 3: (suggestion from Julian S.) Perhaps there should be two options
> to specify "optimise for memory use" or "optimise for performance",
> which have the effect of setting the defaults for various GC options to
> appropriate values. 
> [..]

All right. 
But let the meaning of  -O  remain as it was.

-
Serge Mechveliani
[EMAIL PROTECTED]

___
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users