Advanced Micro Devices Inc. followed Nvidia Corp.’s lead on Wednesday, putting a dollar value on the amount of inventory it plans to write down related to new export restrictions on chips to China.