Qualcomm (QCOM - Get Report)  topped earnings expectations after the market close on Wednesday, but the bigger news was that the chipmaker said it will walk away from its purchase of NXI Semiconductors  (NXPI - Get Report) .

CEO Steven Mollenkopf said the company will also buy back $30 billion in shares, sending shares up nearly 6% to $62.96 in after-hours trading on Wednesday. 

"The rationale for the NXP acquisition was to accelerate our strategy of growing into adjacent opportunities where mobile compute was becoming ubiquitous," Mollenkopf. "This strategy remains unchanged." The Qualcomm CEO cited progress in autos, industrial Internet of things applications and in the development of 5g devices. 

Qualcomm earned $1.01 per share in the fiscal third-quarter, while sales grew 4% from the prior year to $5.6 billion. Wall Street expected the company to earn 71 cents per share on a non-Gaap basis, excluding stock option expensing, according to FactSet.

The San Diego company's $45 billion purchase of NXP had been in doubt. The merger parties needed approval from China's Ministry of Commerce, as traded disputes flared between Washington and Beijing.

Meanwhile, Qualcomm's royalties litigation with Apple Inc. (AAPL - Get Report)  continues. The company tallied up $140 million in litigation expenses in the third quarter, and expects a similar legal bill in the fourth quarter as patent cases proceed in the U.S., China and Germany.

While Qualcomm said it is making progress in court, the new iPhones will likely reflect the strained relations between the companies. "We believe Apple intends to solely use our competitors' modems rather than our modems in its next iPhone release," CFO George Davis said. "We will continue to provide modems for Apple legacy devices."

In another IP dispute, Qualcomm collected $500 million from an unnamed licensee. Qualcomm expects payments of $100 million in each of the next two quarters, in what Davis called a "good faith payment" while negotiations continue.

Qualcomm expects fiscal fourth-quarter revenues of $5.1 billion to $5.9 billion, compared to $4.9 billion in the fourth fiscal quarter last year. The company forecasts 75 cents to 85 cents in earnings per share, a drop from 92 cents per share in last year's fourth quarter. 

Apple is a holding in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio. Want to be alerted before Cramer buys or sells AAPL? Learn more now.