IME (I worked there for a long time, but no longer), individual (and small groups of) engineers with a passion for OSS drive publishing/sharing.
Execs with the interests you outline approve/agree to the sharing.
The motivations are not monolithic, and a corporation is not a person, it's a group of people.
Could you elaborate on why they care? Do they have some kind of competitive advantage when it comes to Protobuf?
With things like protobuf/grcp it's a bit harder, but if they define the standard for data exchange between machines they can eventually - use it as apart of their search indexer - incorporate external services into their products while keeping their standard architecture - integrate acquired software into their stack (you hope being acquired by google? Prepare ;) ) - it reduces risk of alternative approaches from becoming defaults, which could harm Google's integration wishes - if job candidates are used to protobuf there is one thing less to reach a new hire
This certainly isn't a conclusive list, and I can't judge relevance of each for their decision, but those things certainly impact the decision aside from "we think it's cool"
Summer of Code is a huge project they finance, seems altruistic but is a recruiting&marketing tool.
Publishing libraries like protobuf and abseil serves to drive standards in directions they like.
Chrome/Chromium drives the open web, ensures their say on standards and gives the ability to set them.
Android/AOSP brings leadership in mobile devices to them. Again driving standards to their needs and preventing Apple from making the mobile world a google-free walked garden.
SDKs for their services - obvious.
And to be clear, that is by no means bad. And that potential abuse of their position has to be controlled (i.e. when setting web standards to their likings) is mostly independent from their software being open or not.