Which phase of the life cycle of a star is near its end?
Usually when it starts to swell up to a Red Giant or Red Supergiant its days are numbered (days in a metaphorical star sense!)
When stars get to the Red Giant or Red Supergiant stage it signals that most of its hydrogen fuel is becoming exhausted and it is starting to burn more helium. A Red Giant star can still last from anywhere to a few thousand to a billion years though.
Our own star, the sun will become a Red Giant in about 4 billion years. At that time if will engulf the planets Mercury, Venus and probably Earth. Mars and beyond might be ok. In fact in those dying years, Mars might become more habitable - if humans are still around!