Quantifying the role of bars in the build-up of central mass concentrations in disc galaxies