Gross domestic product expanded at a more modest pace in the second quarter, while persistent inflation metrics continue to unsettle financial markets.