I have an 32" Acer ET322QK 4k FreeSync monitor that I use to play MAME games with CRT shaders applied. Most games play very smoothly thanks to FreeSync, but I noticed that some games (such as Rally-X) still had some stuttering. I then discovered that these games all have refresh rates of 60.6Hz, and MAME's own FPS metric showed a steady 99% of target - just short.
This is not a MAME or a FreeSync limitation; DisplayPort 1.2 itself has a limit of 60Hz at 4k. However, I found a solution for Windows:
- Install Custom Resolution Utility (CRU) (https://www.monitortests.com/forum/Thread-Custom-Resolution-Utility-CRU).
- In CRU, click "Edit..." to the right of the monitor name at the top, then change the maximum "V rate" value from 60 to 61.
- In CRU, under "Detailed resolutions", choose the 3840x2160 resolution, click Edit, and change the refresh rate near the bottom to 61Hz.
- Run the restart64 utility provided with CRU to restart your Windows graphics system.
- In the Windows display control panel, change the refresh rate to 61Hz. (In Windows 10, I did this at System > Display > Display adapter properties > Monitor tab > Screen refresh rate drop-down.)
- In your mame.ini file, set waitvsync to 1.