GlobalFoundries will build two chip plants in upstate New York backed by up to 21 billion dollars from Japan. The US and Japan will jointly own the sites, and the US government will take a 4 percent stake in the company.