On Tue, May 12, 2020, 10:55 AM Mark Fletcher <mark2...@gmail.com> wrote:
> On Tue, May 12, 2020 at 08:16:52AM -0600, D. R. Evans wrote: > > Mark Fletcher wrote on 5/12/20 7:34 AM: > > > Hello > > > > > > > I have noticed that recent versions of R supplied by debian are using > all the > > available cores instead of just one. I don't know whether that's a debian > > change or an R change, but it certainly makes things much faster (one of > my > > major complaints about R was that it seemed to be single threaded, so > I'm very > > glad that, for whatever reason, that's no longer the case). > > > Thanks, but definitely not the case here. When running on my own > machine, top shows the process at 100% CPU, the load on the machine > heading for 1.0, and the Gnome system monitor shows one CPU vCore > (hyperthread, whatever) at 100% and the other 7 idle. > > R is certainly _capable_ of using more of the CPU than that, but you > have to load libraries eg snow and use their function calls to do it -- in > short, like in many languages, you have to code for parallelism. I tried > to keep parallelism out of this experiment on both machines being > compared. > You don't mention which distro you are running on the EC2 instance, nor whether R or the C libraries differ in release levels. Moreover, that EC2 instance type is AMD-based not Intel. So if not an apples-to-oranges comparison, it might be fujis-to-mcintoshs. Long ago I built R from source a couple times a year. It has an unfathomable number of libraries and switches, any one of them could have a decisive effect on performamce. Two different builds could be quite different in behavior. Mark > >