We present a study of nuclear shape coexistence in the region of neutron-deficient lead isotopes. The midshell gold isotopes 180,185,188,190Au (Z=79), the two long-lived nuclear states in 197At (Z=85), and the neutron-rich nuclide 219At were produced by the ISOLDE facility at CERN and their masses were determined with the high-precision Penning-trap mass spectrometer ISOLTRAP. The studied gold isotopes address the trend of binding energies in a region of the nuclear chart where the nuclear charge radii show pronounced discontinuities. Significant deviations from the atomic-mass evaluation were found for 188,190Au. The new trend of two-neutron separation energies is smoother, although it does reveal the onset of deformation. The origin of this effect is interpreted in connection to the odd-even staggering of binding energies, as well as theoretically by Hartree-Fock-Bogoliubov calculations including quasiparticle blocking. The role of blocking for reproducing the large odd-even staggering of charge radii in the mercury isotopic chain is illustrated