Lenovo Group Ltd. posted a surprise quarterly loss on rising operating expenses and a $400 million charge due to US tax reforms.

The world’s second-largest PC maker reported a $288.8 million net loss in the three months ended December. That compares with the projection of a $124.5 million profit, according to the average of analysts’ estimates compiled by Bloomberg. Revenue increased 6% to $12.94 billion, compared with the $12.5 billion projected.

Worldwide PC shipments rose during the December quarter for the first time in six years — albeit less than 1%. But HP Inc. widened its lead over its closest rival, according to research outfit IDC. Lenovo still hasn’t come up with an answer for a smartphone business built on the acquisition of Motorola Mobility from Google four years ago for $2.9 billion. And its data centre business remains undercut by domestic rivals.

Rising memory chip costs will weigh on profitability at Lenovo’s PC cash cow, according to Anand Srinivasan and Wei Mok, analysts with Bloomberg Intelligence. “Its phone business remains weak, with a low share and losses that may widen, even with unit and sales gains," they wrote ahead of the earnings.

The miss came as Lenovo swallowed a one-time charge of roughly $400 million as a result of the Trump administration’s tax overhaul, though it said the reforms may result in a lower tax rate for its US operations in the longer term.

Lenovo’s shares fell 1.3% on Wednesday, paring this year’s gains to 2.3%. The stock has fallen in each of the past three years. Bloomberg