The galaxy was nearly annihilated before and when the Necrons woke up the Chaos Gods were still here. They are immortal and eternal in the truest sense of those words. They exist beyond the bounds of time itself, they have always existed and always will, regardless of what the material realm is doing.
"Look into my eyes, and see your death."
"Let them hate, so long as they fear."