none
RStudio Crashes for setMKLthreads(1) RRS feed

  • Question

  • Updated to Open R 3.5.3 and now RStudio crashes with fatal error when attempting to set the number of threads in calling setMKLthreads(). 
    Tuesday, November 5, 2019 8:26 PM

All replies

  • I can't duplicate the problem using RStudio 1.1.463 and Microsoft R Open 3.5.3 on my Windows machine..

    What machine are you using(Linux or Windows)?  How much memory and processors does it have?

    What is the fatal error you get from Rstudio?

    Wednesday, November 6, 2019 6:57 PM
  • it just says fatal error occurred and must restart. Rstudio 1.2.5019.  Everything worked with Open R 3.5.1.
    Thursday, November 7, 2019 6:58 PM
  • I was just able to duplicate the problem in the new version of Rstudio. It doesn't happen in the version of RGui that comes with Microsoft R Open, so this is a problem that only manifests itself in Rstudio.


    Friday, November 8, 2019 5:59 PM
  • We are investigating the issue to see where the problem is and will keep you updated.
    Friday, November 8, 2019 6:25 PM
  • The following code in my R package still crashes Rstudio with Microsoft R Open 3.5.3:

    if ("RevoUtilsMath" %in% rownames(installed.packages())) {
        RevoUtilsMath::setMKLthreads(1)
    }

    Is there any news regarding this issue?

    Wednesday, April 8, 2020 7:27 PM
  • Robin - if you try the same in Rgui or Rterm ( setMKLthreads / getMKLthreads ) - then everything works correctly, therefore this problem is probably related more to RStudio way of handling R core commands, and possibly not much to ROpen or RClient, although it is part of RevoUtilsMath package (developer "Revolution Analytics" is subsidiary of/owned by MS) and MKL libraries are coming from Intel (but still are processor-neutral, more relying on CPU instructions/architecture).

    In my experience on Windows (latest version of 10 Pro x64 - 1909) system even setting environment variable MKL_CBWR (=AUTO or AVX2{in my case} depending on instruction set support by CPU) doesn't fix problem with RStudio session crash either (and session/console tab isn't really related to terminal tab for this context, so setting it there won't affect session).

    You can try to ask the same question on RStudio support forum (or may be forum related to this specific class of packages .. and yes - these still are by MS)..
    Monday, April 13, 2020 3:21 PM