If they can slow down the growing of office space without slowing down hiring, that's a win.
Yes, they are locked in to some leases and have bought some buildings. But at any one time, some leases will run out, and some buildings will be transacted.
If the mass of employess is 30% less productive from home, it is way more expensive than the buildings.
You'll have people who are more productive working from home and some of them will even do more work for the company [as opposed to quietly working half as many hours while getting just as much done]. You'll have others who are less productive. Some of them will also work more hours to make up for at least some of their lost productivity.
Given that companies are now open to it, I think we can infer that WFH productivity is no lower than 80-90% of WFO productivity, averaged across the workforce. Whether WFH = 90%, 100% or 110% WFO productivity, I couldn't guess.
It must be something like 50 or 60% of productivity, and at 70% of the speed.
They are locked into leases and/or have purchased the buildings outright. So the cost is sunk. This is why google is upset and will take salary away from remote workers.