High CPU usage when scrolling

Hi!

It seems to me that RStudio 1.2.1335 for MacOS uses too much CPU for simple GUI interactions that should not be that demanding, e.g. scrolling. When scrolling through my RScript, the RStudio process often uses 60% of CPU and the QtWebEngineProcess 100%. I noticed because fans often started spinning audibly when I was scrolling through scripts. I tried forcing the OpenGL option in the settings, as well as unchecking the Use GPU blacklist and driver workarounds options. I did not notice much difference. Using the default Textmate theme. It happens even with empty global environment and no packages loaded, and with relatively short scripts (less than 100 rows).
My config:
MacBook Pro (Retina, 13-inch, Mid 2014)
2,6 GHz Intel Core i5
8 GB 1600 MHz DDR3
Intel Iris 1536 MB
MacOS 10.14.5

1 Like

Can you also try the preview release and see if things are improved there?

Unfortunately, there doesn't seem to be much difference.

I'm noticing this issue also. I just upgraded to the newest RStudio (1.2.1335). When I open RStudio the rsession CPU usage goes right away to nearly 99% without doing anything. Then I try to load a package (in this case dplyr) and I get the error in the image below that keeps repeating and repeating and will not stop. I need to force quit. During this time QtWebEngineProcess get to greater than 100% of CPU, two rsessions are open each with 99% CPU.

When I quit RStudio one rsession seems to stay open using 99% cpu.

Oddly, this seems to be related to R markdown (?). If I load dplyr in the console no problem. If I open a new R markdown and keep the default R markdown code and then try to run a single line of the R markdown this issue comes up right away BUT if I knit this works fine.

Seems to be something to do, for me, with trying to run a single line of code from an R markdown document.

I'm using a MacBook Pro with Mojave, R 3.6

Tentatively, I'm not seeing this issue with the preview version (1.2.1541)!

I just tried the new preview version (1.2.1541) as well, and I'm still seeing the high CPU usage (QtWebEngine and RStudio processes) when scrolling through an RScript. Maybe yours is an unrelated issue?

I guess so, sorry to hear it. For me it seemed to be strongly related to R markdown. A colleagues suggested that because the error message for me (above) was printing out so many times, and quickly, that this was why the CPU was going crazy (?).

Sorry if this was already mentioned, but did you try forcing software rendering as opposed to using OpenGL? Just in case that makes a difference on your machine.

I tried it just now. I didn't notice any significant decrease in the CPU usage in either of those processes. Tried it in both the preview and the stable (1.2.1335) versions.

Dang. I don't have any other good ideas. Would you mind filing this as a bug report at https://github.com/rstudio/rstudio/issues, so we don't lose track of this?

Done:

1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.