Immigration isn't the problem. Op has Global Entry which mostly works well at SFO.
The problem is checked bags. Waiting to claim and recheck bags considerably cuts down the odds of making the connection. It's a short walk between terminals--though TSA pre is a crapshoot.