(Reuters) - HP Inc (HPQ.N), which houses the former Hewlett-Packard Co's legacy hardware business, reported a better-than-expected quarterly profit as aggressive cost cutting helped counter weak demand for personal computers and printers.
The company's shares reversed course to trade up more than 2 percent at $12.45 after the bell on Wednesday.
"I believe the general sentiment from HP Inc investors is that it could have been much worse given how poorly the PC market has been expected to be and the poor PC sales numbers put forth by peers," Bill Kreher, tech analyst at Edward Jones, said.
Total costs and expenses fell by 10.3 percent to $10.75 billion in the second quarter ended April 30, from a year earlier.
The company remains on track to cut costs by more than $1 billion in 2016, Chief Executive Dion Weisler said on a conference call.
HP Inc said in February it was accelerating its restructuring program and still expects about 3,000 people to exit by the end of the financial year 2016, instead of over three years, as announced initially in September.
Revenue in the personal systems business, the company's biggest, fell 9.9 percent in the second quarter, while revenue declined 15.8 percent in the printing division.
HP Inc forecast an adjusted profit of 37-40 cents per share for the third quarter, largely below the average analyst estimate of 40 cents.
The company lowered the top end of its 2016 adjusted profit forecast to $1.65 per share from $1.69, leaving the low end unchanged at $1.59.
HP's earnings from continuing operations fell to $660 million, or 38 cents per share, in the second quarter, from $733 million, or 40 cents per share, a year earlier.
The company's revenue fell about 11 percent to $11.59 billion.
Excluding items, the company earned 41 cents per share.
Analysts on average had expected earnings of 38 cents per share and revenue of $11.72 billion, according to Thomson Reuters I/B/E/S.
This is HP Inc's second quarterly results since Hewlett-Packard Co formally split in November.
The other company, Hewlett Packard Enterprise Co (HPE.N), announced on Tuesday that it would be spinning off and merging its struggling IT services business with Computer Sciences Corp (CSC.N).
(Reporting by Alan John Koshy in Bengaluru; Editing by Maju Samuel)