Reconstruction of sub-femtosecond longitudinal bunch profile measurement data