Quick test with the 50/1.8 STM and 5D2. Actual focus distance not measured; only cross-checked values from ML with those from EXIF.
Focus dist Focus dist Focus dist Aperture
Disp by ML Lower EXIF Upper EXIF
34cm 0.34m 0.34m f/1.8
37cm 0.34m 0.37m f/1.8
41cm 0.37m 0.41m f/1.8
47cm 0.41m 0.47m f/1.8
53cm 0.47m 0.53m f/1.8
62cm 0.53m 0.62m f/1.8
73cm 0.62m 0.73m f/1.8
87cm 0.73m 0.87m f/1.8
1.10m 0.87m 1.1m f/1.8
1.41m 1.1m 1.41m f/1.8
1.99m 1.41m 1.99m f/1.8
3.50m 1.99m 3.5m f/1.8
8.61m 3.5m 8.61m f/1.8
inf 81.91m inf f/1.8
inf 81.91m inf f/22
8.61m 3.5m 8.61m f/22
3.50m 1.99m 3.5m f/22
1.99m 1.41m 1.99m f/22
1.41m 1.1m 1.41m f/22
1.10m 0.87m 1.1m f/22
87cm 0.73m 0.87m f/22
73cm 0.62m 0.73m f/22
62cm 0.53m 0.62m f/22
53cm 0.47m 0.53m f/22
47cm 0.41m 0.47m f/22
41cm 0.37m 0.41m f/22
37cm 0.34m 0.37m f/22
34cm 0.34m 0.34m f/22
Remarks:
- the focus distance encoder has a small number of unique positions
- there's no hysteresis (same values when turning the focus ring back and forth)
- aperture does not affect the results (so, "Lower" and "Upper" have nothing to do with DOF near/far)
- the value displayed by ML always matches the "Upper" distance reported in EXIF
- there is another "Lower" distance, currently ignored by ML
- unique values of "Lower" are mostly the same as for "Upper", with one exception on my lens (81.91m vs infinity)
- "Lower" and "Upper" in EXIF must be the ends of an interval where the actual focus distance is believed to be (by Canon firmware)
- since ML only displays the right end of the interval, it overestimates the EXIF value
- the mean value of the two distances might be a better estimation
- the geometric mean might be even better (rationale somewhere in
this topic; I can make some plots if needed).
Delay: outside LiveView, ML refreshes the lens parameters once per second (by polling the MPU). By default, Canon firmware does not refresh this information unless you take a picture. So, if you print the focus distance from ML (e.g. from a Lua script) before taking a picture, without waiting for a refresh, you may get old (incorrect) values.
TLDR - yes, the focus distance reported by ML could be a bit better.
The difference you are seeing might be simply from the encoder resolution.