What happened

Shares of Advanced Micro Devices (NASDAQ:AMD) have climbed more than 31% so far in 2017, according to data provided by S&P Global Market Intelligence, after the company reported strong fourth-quarter 2016 and full-year 2016 earnings, as well as an earnings beat in the second quarter of 2017.

So what

AMD's stock jumped 20% in February after the company reported a 15% year-over-year revenue increase in the fourth quarter, to $1.11 billion. Non-GAAP earnings per share came in at negative $0.01, which matched analysts' consensus estimates.

Man in background pointing at bar chart.

Image source: Getty Images.

The company also posted solid gains for the full year, with revenue climbing 7% year over year from 2015 and net losses slowing to $117 million, down from $419 million the previous year. 

Nearly all of those gains were lost in May, though, after AMD reported its first-quarter 2017 results. Revenue was up 18% year over year and the company had a net loss of $0.04 per share. But investors were disappointed with the company's Q2 guidance of 12% year-over-year revenue growth. They may have been expecting higher growth after a slew of new AMD products had recently hit the market.

But that didn't stop the company's share price from bouncing back in July -- and jumping more than 20% -- leading up to the company's second-quarter results on July 25. Revenue was up 19% year over year to $1.22 billion and non-GAAP EPS hit $0.02. Both of those results were higher than analysts' consensus estimates of $1.16 billion in revenue and breakeven for earnings.

Now what

Investors are likely to be pleased with AMD in the short term, as third-quarter revenue is expected to increase 15% year over year, at the midpoint. The company also increased its annual revenue expectations to growth by mid to high teens percentage, up from its previous expectations of low double-digit growth. That helped fuel investor optimism toward the end of this month and will likely keep it going in the coming months.