hi everyone,
I just added additional instructions in the README file of mcx for setting up mcx/mcxcl/mmc (or any CUDA program) on a modern hybrid GPU laptops. if you happen to use a hybrid GPU laptop, check it out
my last two laptops I used for developing mcx are both hybrid graphics - that means it has a discrete NVIDIA GPU (2060 and 4070, respectively), and an integrated GPU (iGPU) - one laptop has an AMD Ryzen CPU with Renoir AMD iGPU, another with an Intel CPU+iGPU.
I have dual boot on both laptops - for Windows, as long as you
applied the TdrDelay
registry fix, mcx/mcxcl/mmc should be able to run - but it
won't work if you don't change the registry.
for Linux - I had Ubuntu 22.04, I noticed that the AMD
iGPU+NVIDIA GPU had no trouble running mcx on the NVIDIA card -
nothing need to be changed. However, when I switched to the Intel
iGPU+NVIDIA GPU, in the default setting (nvidia-prime is set in
the hybrid mode), mcx/mcxcl/mmc can only run for a few seconds and
the screen is frozen.
the fix to this is to make nvidia to be the primary GPU in NVIDIA X settings, or run
sudo prime-select nvidia
Even running in the performance mode, nvidia driver seems to have
a known bug when using the newer 6.x linux kernels - that mcx may
give you an error after the machine wakeup from sleep. I found
many similar reports of this issue on nvidia's forums, including
mine
so far, nvidia hasn't fixed this bug yet, a workaround is to run (close matlab if it is on)
sudo rmmod /dev/nvidia-uvm
sudo modprobe nvidia-uvm
if no error, this should make the nvidia card visible again.
anyhow, I just want to share this. On my other work desktops
running either standalone or hybrid mode on older Linux (ubuntu
18.04, 20.04), they have zero issue.
Qianqian