Why might the housing part of the US GDP basket 40% of the basket, but only 17% of China's?
The “shopping baskets” of items should be representative of consumer spending patterns. The general principle is to apply a fixed set of weights to price changes for each of the items such that their influence on the overall index reflects their importance in the typical household budget.
In 2015, housing on average accounted for about 22 percent of consumption expenditure in China, and it represented about 33 percent of household expenditure in the U.S. in 2016 (same percentage in 2018 according to the US Bureau of Labor Statistics). These consumption patterns may explain the difference between the 40% in the U.S. and the 17% in China.