JIT: How much of a performance gain, automatic(?), and is it safe everywhere?
It's been on my to-do list to consider adding just-in-time compilation of future expression, particularly for future_lapply() (and also to doFuture). Since R is about to gain automatic JIT compilation, I've held back on this to see where we end up.
Today I've noticed the following in SVN commit to R-base on 2017-03-14:
Disable JIT in R processes created in mclapply and friends (performance optimization, prevents repeated compilation of the same code). https://github.com/wch/r-source/commit/62b3dd0d962da83700cfab4a8b65ced76a9e65c0
Are the cases where we need to do similar protection? I don't think so, and all system-wide tests indicate it's not needed, but I'm adding this issue here as a reminder to myself.
I made the fail-safe codes in the for loop to do that. Try the parallel work in the for looping; it fails, rechecks server status retries them. After that, if I could get the result, I save the RDS file in the local.
Codes: https://github.com/seonghobae/kaefa/blob/master/R/kaefa.R#L453 and https://github.com/seonghobae/kaefa/blob/master/R/kaefa.R#L499