Most patients die within 5 years and spend two-thirds of remaining life as an inpatient, UCSF report finds.