The movie is ambiguous. When I chronicled Marla's death in my novel To Reign in Hell,
I put it about four years after the destruction of the planet's ecosystem.
This was done entirely for dramatic purposes. Marla's death was a big deal; I didn't want to throw it away in the first few chapters of the book. Plus, if Marla was going to be the great love of Khan's life, whose death caused him to be consumed by vengeance, I wanted to spend a good chunk of the book on their romance, which needed time to grow and deepen . . . .
So, yeah, in my version, Marla survived on the planet for at least four years before her fatal encounter with that Ceti eel.
Not sure how they handled it in the comic-book version . . . . .