macOS performance

Hi,
I’m not sure that this topic was never discussed earlier, but I found only similar ones and they are kind of outdated.

I have some noticeable difference in performance when running Github Actions on Ubuntu vs macOS, and the latter takes way more time than the former one.
The question: if the observable behavior is known and expected one? Any advice you can give me to make it better?

I don’t think that there is something on our side, since we run on matrix.os, and there are no problems with Ubuntu. Everything is the same - same tests, same compiler and etc.
For example, building ocaml compiler takes around 4 minutes on Ubuntu and 11 minutes on macOS.
The tests themselves have even a bigger difference: 17 minutes on Ubuntu and 1 h 15 minutes on macOS.

I can provide a link, just for example:

Thanks!

@gitoleg,

The GitHub-hosted Linux and and Windows runners are hosted on Standard_DS2_v2 virtual machines in Microsoft Azure, and GitHub uses MacStadium to host the macOS runners. More details, see “Cloud hosts for GitHub-hosted runners”.

The Microsoft Azure and MacStadium are two different platforms, and it is inevitable that there are some differences of performance between them.

Not sure why the macOS runners are slower so much.
I have created an issue ticket (actions/virtual-environments#1336) to help you report this question.
You can follow this issue ticket and add your comments in it.