Do not overwrite file if we cannot improve on the size

Discards the optimized version if it is not smaller than the original.