Galactus Dormammu. Eternity is stronger than Galactus so Dormammu wins or tie with Galactus. Dormammu sees Galactus as his lackey.
I guess Dormammu could put Galactus in a pocket dimension but i doubt Galactus would not start Depending on the time both Dormammu and Galactus go without energy, Thanos has a significant.
Though I ravage worlds to live, I bear no malice toward any living thing.
Strange I spent a lot of time on comping up with ideas for Dormammu. During the Infinity Wars series, there were spinoffs called "Infinity Warps," in which characters like Captain. But who is more powerful of the two?