Very few $0 CEOs start at $0 Salary. Most start with a reasonable salary-bonus-equity combination. As the company grows to be more successful and the equity they own (or have future rights to via vesting) becomes more valuable they reach a point where more salary basically pointless (since salary above $1,000,000 is not tax deductible to a profitable company it ios also pointless to the company). In many cases any amount of salary at all is pointless due to the wealth of the individual.
Some of these CEOs at $0 salary have stock worth more than a Billion dollars. $1M in salary equals one-thousandth of their company provide wealth. Moving their salary to $0 is just a way to make that corporate thorn go away. Equity compensation keeps them aligned with shareholders and allows them to continue being rewarded for grwoth and success.
I should point out that some of the CEOs who do this make the effort for far more altruistic reasons, but most of the CEOs at a $0 salary have already crossed the salary-requirement threshold.
So, equity compensation for these CEOs is based on a combination of market data, internal worth and shareholder acceptability.