The purpose of the diode is to limit the charging voltage of the backup power supply when Vcc is greater than the max charging voltage of of the backup supply.