When I use "Auto image size" → "Fit image to window" on a non-retina display, the result is correct:

However, when I move the window to a retina display, the image is resized incorrectly. Here's an example for a 150% retina factor:

Apparently, some part of XnViewMP is accounting for the retina factor in its calculation while another part doesn't.