Back on Titan, Thanos told his people "you need to kill half the population to save our civilization from disaster." The people of Titan dismissed Thanos as insane. Thanos, being actually insane, decided he was going to prove he was right by going around massacring halves of populations.
In other words, he's not doing this to actually help anyone, he's doing it just to prove he was right. Solving the universe's problems by other means wouldn't do that so that's not an acceptable outcome for him.
In 2026. That's decades away.
The US could announce withdrawal at any time with six months' notice, sure, but that has not happened yet.