Skip to content
Prev 9222 / 10988 Next

[Rcpp-devel] Overriding 'ARMA_64BIT_WORD 1' in RcppArmadillo

Hey!

Since it seems to be the case that we don't know much about what happens,
I'm making an experiment which consists on an R package to stress
RcppArmadillo here: https://github.com/gvegayon/arma64bit. Following Dirk's
advice, I've included the #define ARMA_64BIT_WORD before #include
<RcppArmadillo.h> (as seen here
https://github.com/gvegayon/arma64bit/blob/c10b5d4a80b93088da730e45ee8c583feeff2ab6/src/misc.cpp#L2-L3)
and included CXX_STD = CXX11 in Makevars. After compiling the package and
asking for a matrix of size 1e5 x 1e5 I get an error, here (so it doesn't
seem to be working):
error: SpMat::init(): requested size is too large
Error: SpMat::init(): requested size is too large

My guess is that #define ARMA_32BIT_WORD is overriding #define
ARMA_64BIT_WORD. I'm an R user that jumped to Rcpp a while ago so I still
don't fully understand how things work under the hood with R + Rcpp. Any
clues?

Best,

sessionInfo()

R version 3.2.5 (2016-04-14)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.4 LTS

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
LC_TIME=en_US.UTF-8
 [4] LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8
 LC_MESSAGES=en_US.UTF-8
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C

[10] LC_TELEPHONE=C             LC_MEASUREMENT=en_US.UTF-8
LC_IDENTIFICATION=C

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

other attached packages:
[1] arma64bit_0.1.0.9000 Matrix_1.2-5

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.4     lattice_0.20-33 digest_0.6.9    withr_1.0.1
grid_3.2.5
 [6] covr_2.0.1      git2r_0.14.0    magrittr_1.5    lazyeval_0.1.10
rstudioapi_0.5
[11] whisker_0.3-2   rex_1.1.1       rmarkdown_0.9.5 devtools_1.11.1
tools_3.2.5
[16] yaml_2.1.13     htmltools_0.3.5 memoise_1.0.0

George G. Vega Yon
+1 (626) 381 8171
http://www.its.caltech.edu/~gvegayon/
On Thu, Mar 31, 2016 at 12:37 PM, Dirk Eddelbuettel <edd at debian.org> wrote:

            
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20160428/8543a09b/attachment.html>