Balance is the law of nature. When one element becomes too strong, it throws the entire ecosystem out of wack. As the number of people who have a stake in the community diminishes, and the number of people who actively resent it grows, you risk social explosion. The good times need to be good for everyone. You can't have tech millionaires living in splendid isolation while you make working people with decent jobs, as homeless as a runaway crack fiend on Sunset Strip.
Companies can at least help build housing for their workers.
Because the issue isn't money, but homes. And all the money in the world does not give you a place to sleep if there are none to be had. And if all you have is a normal salary, you aren't even in the running. Giving to homeless shelters is not enough. Preventing your company from pushing up housing prices might do a lot more to prevent homelessness and limit traffic congestion.