Terrax probably wins this
Terrax is too fast for Galvatron. I think that Galvatron is a lot stronger and if he is able to get a shot off he would win.
However, if Unicron really needs the planet he would probably grant Galvatron more abilities should as speed and if this is the case Galvatron would win.
Now that I think about it Galvatron wins this. Terrax's engery blast is not going to do much damage on Galvatron. Galvatron gets shot by engery blast, laser blast and whatever the autobots unleashes on him and he survives. Plus Galvatron could also tap into a blackhole to gain more power if he needs.