[Rcpp-devel] Question on performance

Jordi Molins jordi.molins.coronado at gmail.com
Sat Sep 22 09:02:38 CEST 2018


Hello, I am new in this distribution list. I am using Rcpp for my project,
and I enjoy the Rcpp implementation quite a lot.

I have read the paper
https://www.sas.upenn.edu/~jesusfv/Update_March_23_2018.pdf and I see the
performance of Rcpp is about 4x times slower than C++ proper code, or 3x
times slower than Numba/Cython Python code.

Do you think that these figures are realistic? Of course, performance
calculations are always dependent on many factors (very often, not
explicit). But I am surprised that Rcpp is that slow in comparison to C++
code. I do not understand that Rcpp may be so slow, unless there are many
calls back and forth between Rcpp and R. The same for compiled Python code
vis a vis Rcpp.

Or maybe I am wrong?

Jordi Molins i Coronado
+34 69 38 000 59
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20180922/e8d88849/attachment.html>


More information about the Rcpp-devel mailing list