Infineon has agreed to buy Cypress Semiconductors in a deal that values the U.S. maker of microchips used in cars and electronic devices at 9 billion euros ($10.1 billion) including debt, sending shares in the German company lower on concerns over the cost.