[Rcpp-devel] RInside and multi-threading

Darren Cook darren at dcook.org
Sun Feb 12 10:13:00 CET 2012


> | I found [2], suggesting that this is okay for RServe. Implying it would
> | be okay for RInside too?
> 
> At present, Rserve is set up to fork (on OS X and Linux)...

I took it to mean it forks per connection. The quote below is talking
about threads in a client application sharing a connection to an Rserve
server. Assuming I didn't misunderstood that much, it implies R can
handle non-eval commands in parallel, (which in turn would imply that
RInside would also be okay).
(That may not be the case if Rserve is serializing the incoming requests
on each connection... but in that case there would be no need for them
to have written the "don't eval in parallel" warning.)

A chain of assumptions... it be nice if someone had actually tried it.
(If no one else has, then I will get to it; eventually.)

Darren

> | [2]: http://www.rosuda.org/Rserve/
> | "Rserve is thread safe across connections, but eval methods are not
> | thread safe within one connection. This means that multiple threads
> | should not use the same connection unless they guarantee that no eval
> | calls are run in parallel."



-- 
Darren Cook, Software Researcher/Developer

http://dcook.org/work/ (About me and my work)
http://dcook.org/blogs.html (My blogs and articles)


More information about the Rcpp-devel mailing list