Skip to content
Prev 8123 / 10988 Next

[Rcpp-devel] RcppEigen: Windows binary from CRAN crashes R, but not when installing from source.

I think John's advice is spot on here. The issue is only seen when
`NDEBUG` is not defined.

I can reproduce the crash (assertion failure) by ensuring I have

    CXXFLAGS=-UNDEBUG

in my ~/.R/Makevars. Note that:

1. An assertion failure from Eigen implies you are doing something
that you should not be doing, and
2. R by default sets -DNDEBUG whenever compiling by default, so I am
surprised that you are not seeing it (does your package have a custom
Makefile / Makevars or something to that effect? Or do you have your
own custom Makevars somewhere?)

Anyway, let's assume Eigen is right -- this means you're multiplying
two non-conforming matrices, and hence your matrix product is
undefined. Which makes sense, since you're now trying to multiply two
non-conforming matrices. And if you want a scalar * matrix
multiplication then you need to be using a different function.

Note that this is exactly what Eigen's assertion was telling you here!


On Thu, Oct 16, 2014 at 8:58 AM, John Buonagurio
<jbuonagurio at exponent.com> wrote: