Japan's Toshiba Corp reported a smaller-than-expected quarterly operating loss on Wednesday thanks to solid chip prices, and stuck to its forecast for a return to profit this year on cost cuts.

Toshiba, the world's No.2 maker of NAND-type flash memory chips, is hurrying to invest in new technologies to keep up with sector leader Samsung Electronics Co, whose chip operations returned to a profit on a nascent chip recovery.

Chronic losses on semiconductors prompted Toshiba, the owner of U.S. nuclear power firm Westinghouse, to raise $5 billion to shore up its finances and rein in chip output earlier this year, as it awaits nuclear power plant revenues.

Toshiba stuck to its 100 billion yen ($1.1 billion) operating profit forecast for the full year to next March as it cuts costs. That is far above the average forecast by 18 analysts polled by Thomson Reuters for a profit of 29.7 billion yen.

Toshiba said its operating loss totaled 37.6 billion yen in April-June, against a 22.9 billion yen loss a year earlier. It beat the consensus for a 52.6 billion yen loss forecast by 3 analysts.

It posted a net loss of 57.8 billion yen, against an 11.6 billion yen loss a year earlier on a 17 percent fall in sales.

Ahead of the results Toshiba shares rose 0.5 percent, against a 1.3 percent gain in Tokyo's electrical machinery subindex.

Its shares rose 38 percent in April-June as its $5 billion fund raising allayed fears about its finances, outpacing a 25 percent rise in the subindex.

($1=94.38 Yen)

(Reporting by Mayumi Negishi; Editing by Michael Watson)