calulating size on preflight