Re: [Rd] mem.limits deprecated

From: Martin Morgan <mtmorgan_at_fhcrc.org>
Date: Mon, 06 Feb 2012 13:57:42 -0800

On 02/06/2012 12:45 PM, Jeroen Ooms wrote:
> After upgrading my servers to 2.14, log files were filled warnings
> that 'mem.limits' has been deprecated and to use gc instead. After
> reading the NEWS for R 2.14.0 and PR#14795 I learned that it is
> actually deprecated without replacement.
>
> Hereby I just want to voice that this function was actually in use by
> at least several users. Among other things, it is a useful to limit
> per-session memory on a shared resource. I am not sure what the
> assumption that 'these limits are nowadays almost never used' was
> based on, but I would disagree.

These were also sometimes useful in our own use case, where setting --min-n/vsize can speed start-up of scripts loading complicated packages (e.g., Matrix or Bioconductor IRanges) that trigger dozens of garbage collections before arriving at the > prompt, or needing to input large data up-front; as a contrived example (70 garbage collections under default values):

mtmorgan_at_linux-ibmc:~> time ~/bin/R-2-13-branch/bin/R --slave --vanilla -e "library(IRanges)"

real    0m2.306s
user    0m2.270s
sys     0m0.028s

mtmorgan_at_linux-ibmc:~> time ~/bin/R-2-13-branch/bin/R --min-nsize=2200000 --slave --vanilla -e "library(IRanges)"

real    0m1.931s
user    0m1.854s
sys     0m0.069s

mtmorgan_at_linux-ibmc:~> ~/bin/R-2-13-branch/bin/R --version R version 2.13.1 Patched (2011-09-04 r56932) Copyright (C) 2011 The R Foundation for Statistical Computing ISBN 3-900051-07-0
Platform: x86_64-unknown-linux-gnu (64-bit)

These were particularly useful in starting up nodes in an (Rmpi) cluster, and perhaps more generally suggest that, for some use cases, the default memory allocations could be revised (they have not for a long time, from current R-devel):

  29749     ripley #define Min_Nsize 220000
  29749     ripley #define Min_Vsize (1*Mega)

Martin

> Obviously this is message is late, the decision has been made and we
> were not paying attention when we should have. However if there is
> possibly anything that can be done to rescue some of this
> functionality that would be greatly appreciated. E.g. by keeping some
> of the support in the memory allocator and moving the R code into a
> package or so.
>
> Thank you
>
> ______________________________________________
> R-devel_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

-- 
Computational Biology
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109

Location: M1-B861
Telephone: 206 667-2793

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Received on Mon 06 Feb 2012 - 22:06:00 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 07 Feb 2012 - 18:30:14 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive