You're incorrect, Square has non-SF offices, too. I think @nrp has put it well in his comment https://news.ycombinator.com/item?id=21342101. Square is categorized differently than Salesforce by SF tax law and pays a different proportion of taxes than Salesforce.
EDIT: corrected username