Dear R-help list members,

I am hoping to get you help in reproducing a problem I am having That is
only reproducible on a large-memory machine. Whenever I run the following
lines, get a segfault listed below:

 *** caught segfault ***
address 0x7f092cc46e40, cause 'invalid permissions'

Traceback:
 1: La.svd(x, nu, nv)
 2: svd(X)
 3: ginv(bigmatrix)


Here is the code that I run:

require(MASS)
l=30000
w=30000
x=rpois(l*w,0.00126)
bigmatrix=matrix(x,nrow=l,ncol=w)
inverted=ginv(bigmatrix)

I have tried this both with OMP_NUM_THREADS=1 and greater than 1, and the
resulting is always a segfault. The max memory used in around 40G. I am
running this on a machine with 128Gb of RAM. I have also done tests with
15,000x15,000 matrices, and they do not cause any segfaults, so I think the
problem is related to the size of the input to the La.svd function. I have
also tried this with a less sparse matrix, but again, no change in the
outcome.

I have submitted the bug report to the R bugzilla site (
https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15163), but I wanted
to see if anyone on the r-help list has hit this problem before, or can
reproduce it, and if there is a solution out there. My web searches have
turned up nothing. It appears that R uses a modified version of LAPACK 3.1,
and the latest version of LAPACK is 3.4.2. Is that important?

Thanks so much for your help,

Cyrus

PS: Here is my SessionInfo: (I am using ubuntu).

R version 2.15.2 (2012-10-26)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
 [7] LC_PAPER=C                 LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] MASS_7.3-22     Matrix_1.0-10   lattice_0.20-10 Rcpp_0.10.2
[5] devtools_0.8

loaded via a namespace (and not attached):
 [1] compiler_2.15.2 digest_0.6.0    evaluate_0.4.3  grid_2.15.2
 [5] httr_0.2        memoise_0.1     parallel_2.15.2 RCurl_1.95-3
 [9] stringr_0.6.2   tools_2.15.2    whisker_0.1

	[[alternative HTML version deleted]]

