similar to: R garbage collection

Displaying 20 results from an estimated 6000 matches similar to: "R garbage collection"

2011 Aug 04
1
slightly speeding up readChar()
Hi, I was trying to have R read files faster with readChar(). That was before I noticed that readChar() is not that bad! In any case, below I suggest a few simple changes that will make readChar slightly faster. I followed readChar(useBytes=T), and tried to identify all O(N) operations, where N is the size of the file. The assumption is that for LARGE files we want to avoid any O(N) operations,
2010 Apr 19
1
transient memory allocation and external pointers
Hello, The Writing R extensions manual section 6.1.1 describes the transient memory allocation function R_alloc, and states that memory allocated by R_alloc is automatically freed after the .C or .Call function is completed. However, based on my understanding of R's memory handling, as well as some test functions I have written, I suspect that this is not quite accurate. If the .Call
2004 Jun 02
1
data filtering
I would like to know if there is a way to do the following command in one step, primarily for speed on large data (5 million elements), and secondarily for readablity. mean(delta[(intersect(which(x[['class']]==0),which(delta<1)))]) Do I really have to rely on an intersect operator? Isn't that O(nlg(n))? Can't I just filter in one step? As an R newbie, I would have guessed
2004 Jul 02
1
reading large data
Hello, I have trouble using read.table for flat files of larger than about 300MB on windows 2000. Any ideas of how to file a bug report? Is it a known issue? I have three cuts of data, a 1%, 10% and 100% sample in flat text files. The 100% sample is about 350MB. When I read the 1% and 10% files, besides being slow, everything works. RAM footprint appears to increase approximately 2x of text
2007 Oct 24
1
setuid question
I've got a problem I hope someone can help with. We have a directory on a redhat box where we want anyone who creates a file (usually done with samba access) to have that file be created as if by a special "user" and group.. Now in the smb.privateshares config file we specify force user and force group.. However when we create a file in this directory it shows it being owned by the
2011 Oct 05
1
Moderating consequences of garbage collection when in C
Allocating many small objects triggers numerous garbage collections as R grows its memory, seriously degrading performance. The specific use case is in creating a STRSXP of several 1,000,000's of elements of 60-100 characters each; a simplified illustration understating the effects (because there is initially little to garbage collect, in contrast to an R session with several packages
1999 Apr 22
1
mvfft (PR#176)
This message is in MIME format --_=XFMail.1.3.p0.Linux:990422185944:4782=_ Content-Type: text/plain; charset=us-ascii R-0.64.0 on RedHat Linux 5.1 Some problems with multivariate fast fourier transform. I have attached the dump of a 30 x 3 matrix that seems to reliably reproduce these problems 1) mvfft doesn't like vectors. It complains about not having enough memory: R>
2007 Oct 11
1
problem installing MCMCpack
I'm completely new to R and am trying to install an add-on package for one of our faculty members. I've had no problems with most of them, but am completely stuck trying to figure out why MCMCpack won't install.. any help is VERY much appreciated!!! here's what I get when I try to install the package: * Installing *source* package 'MCMCpack' ... checking for C++ compiler
2004 Aug 16
1
turning off automatic coersion from list to matrix
Hello, I am having trouble understanding how R is coercing between matrices and lists in the following example. I have an aggregate behavior I like: aggregate(a[,"num"],by=list(product=a[,"product"],region=a[,"region"]), sum) Now in reality I have more columns than just product and region, and need to pick different combinations. So I want to abstract this into a
2000 Feb 08
1
problem with va_list type (alpha) (PR#421)
Full_Name: Albrecht Gebhardt Version: 0.99.0 OS: alpha, osf4.0 Submission from: (NULL) (143.205.180.40) Both DEC cc and gcc complain (osf4.0, alpha) about applying an unary operator (!) to a non scalar type (va_list arg) in printutils.c I'm not sure if I understood what was intended by "!arg" (see below), but with this patch I at least was able to compile. (and R runs now, but I
2008 Oct 03
1
Memory crash
Hello, I get a segfault when running glmmboot in my own package glmmML. Has happened many time before, but this time I get no hint of where in my C functions the error might be. I give the output below. Can this be an R bug? I suspect it has to do with repeated calls to 'vmmin' like this: for (...){ vmax = vmaxget(); vmmin(*p, b, &Fmin, bfun,
2001 Feb 20
2
segfault
I've managed to trap the following segfault with xxgdb and gctorture() set. The segfault seems to move around if gctorture() is not set, but has now occurred twice in the same spot with it set. xxgdb gives the message Program received signal SIGSEGV, Segmentation fault. 0x71244 in RunGenCollect (size_needed=2) at memory.c:1027 and the source listing points to FORWARD_CHILDREN(s); in the
2001 Oct 05
1
modifying matrix allocation functions for use with R
Dear R people, I'm using compiled C code as a shared library as a backend to C code, using the .C interface. I need to do some matrix manipulation in the C code. I decided to use the new GSL (Gnu Scientific Library) currently (0.9.3) in beta status. This has appropriate matrix structures defined, and quite a comprehensive collection of matrix routines. However, there is a problem with the
2005 Nov 27
1
segfault on write.dcf with gzfile connection
I'm seeing a segfault on x86_64 Linux with the following code: desc = read.dcf("BAD") con = gzfile("test.gz", "wt") write.dcf(desc, file=con) close(con) where BAD has a long field (see below for example). The crash happens inside dummy_vfprintf. I think the issue is that the va_list ap is modified by the first vsnprintf call
2012 Jul 10
6
getting rid of old spam from +spam Maildir ?
I'm trying to setup per user '+spam' delivery from amavis tags, so that each user gets any mails tagged as spam to 'spam' Maildir via +spam Dovecot lmtp delivery. after say 7 days I want to delete all spams older than 7 days, if I simply delete mail files from the file system, is that a 'bad thing' ? what is a proper way to do that, and scripts ? for
2001 Nov 15
3
pdf() behavior (PR#1174)
--0__=88256B050063F04C8f9e8a93df938690918c88256B050063F04C Content-type: text/plain; charset=us-ascii The attached script produces "Error in plot.xy ... negative length vectors are not allowed" when using pdf() but not when using postscript (). platform sparc-sun-solaris2.8 arch sparc os solaris2.8 system sparc, solaris2.8 status major 1 minor 3.1 year 2001 month
2009 Mar 01
0
[LLVMdev] Why LLVM should NOT have garbage collection intrinsics
On 2009-03-01, at 05:41, Mark Shannon wrote: > Gordon Henriksen wrote: > >>> The semantics of llvm.gcroot are vague: "At compile-time, the code >>> generator generates information to allow the runtime to find the >>> pointer at GC safe points." >>> >>> Vague, ill-specified interfaces are worse than none. >> >>
2009 Mar 01
2
[LLVMdev] Why LLVM should NOT have garbage collection intrinsics
Gordon Henriksen wrote: > > The "runtime interface" is a historical artifact. LLVM does not impose > a runtime library on its users. I wouldn't have a problem deleting all > mention of it, since LLVM does not impose a contract on the runtime. > Excellent, I found it somewhat unhelpful! >> The semantics of llvm.gcroot are vague: >> "At
2008 Jan 19
1
R_alloc segfaults
I want to write a little stand-alone C program that calls R_alloc, but I get a segmentation fault: int main(int argc, char** argv){ double* d = (double *)R_alloc(2, sizeof(double)); // <- segmentation fault! return 0; } gdb reveals that sizeof(double) evaluated to 0: > R_alloc (nelem=2, eltsize=0) at memory.c:1649 so it results in the segfault later. This is how I compile my
2008 Mar 05
1
R_alloc with structures with "flexible array members"
Dear All, In a package, I want to use some C code where I am using a structure (as the basic element of a linked list) with flexible array members. Basically, this is a structure where the last component is an incomplete array type (e.g., Harbison & Steel, "C, a reference manual, 5th ed.", p. 159) such as: struct Sequence { struct Sequence *next; int len; unsigned int