No doubt He betrayed his brother for personal gain. What did Fredo think was going to happen?

How about the fact that he gave information to the Family's adversaries, opened the drapes to Michael and Kay's bedrooom, who used it to attempt the hit?

Then when Michael survived the Tahoe shooting, he deliberately and deceitfully concealed the Senate hearing and cunningly withheld the information he knew, for Michael to commit perjury because he can only get the Donship if he was dead or sent to prison

Let’s be honest Michael initially did give him a pass “I know he's scared -- tell him everything's all right. Tell him I know Roth misled him -- and he didn't know they were planing to kill me.”

Fredo's outburst in the boathouse revealed
1. the depth of his resentment toward his brother.
2. his jealousy, simmering anger at being stepped over
3. the extent of his deeper involvement with Roth against his brother

We had debated before Fredo could have been spared but Turnbull puts up an excellent case for it's justification

Originally Posted by Turnbull

Michael's ordering of Fredo's murder was a horrific act. Michael was a reprehensibllle man, heading a reprehensible criminal empire. But, from his viewpoint, Fredo had to die. Fredo's outburst in the boathouse revealed the depth of his resentment toward his brother. Sooner or later, someone elserwould approach Fredo with yet anpther death-dealing offer. And, as Don, Michael had to prove to enemies and even friends that no one--not even his brother--gets a pass from Michael Corleone, no one finds a c***k l in his armor. As Hyman Roth said, "This is the business we've chosen."

Michael being tormented by Fredo's murder in spite of his treachery, shows he has a heart