Plots.jl + GR backend: time to plot on windows always 2.3 seconds

Hello everyone,

Not sure if this is normal or not, but when I type in the repl the following:

julia> @time using Plots; @time display(plot(rand(10)))
  3.859720 seconds (8.52 M allocations: 590.593 MiB, 7.35% gc time, 12.19% compilation time)
  7.764304 seconds (17.92 M allocations: 957.783 MiB, 2.12% gc time, 68.93% compilation time)
julia> @time display(plot(rand(10)))
  2.337953 seconds (140.36 k allocations: 2.781 MiB)

Between the first and second time I invoke the plot() function, I close the window with the figure.
As you can see from the timing, after closing the window and invoking again plot
I always get a time to plot of approximately 2.3 seconds.

I’m on windows 10. This behaviour occurs on julia1.6.3 and julia1.7 and GR backend.
For the PyPlot and Plotly backends there is no issue.

I’v never seen this behaviour on my ubuntu machine.

Thanks,
Olivier

Not sure what is considered “normal”, but I see roughly the same timing - if I don’t close the QtTerm window then timing is 0.01s, while with closing in between calls it’s ~2.3s so this seems to be the overhead of opening the new window?

Ok, interesting.
Good to know I’m not the only only one.

Bumping this.
Anyone else has experienced this?
Is there a solution?

thanks again