International Business Machines Corp. on Friday reported its first-ever quarterly loss, a $1.73 billion deficit caused in part by the recession and by a new method of accounting for retiree benefits.

Sales of IBM computer hardware fell more than 17 percent in the quarter, far below analysts' expectations.IBM said the loss translated to $3.03 a share, compared with a profit of $1.04 billion, or $1.81 a share, in the year-ago quarter.

The world's largest computer firm recorded a $2.26 billion charge during the quarter, or $3.96 a share, to cover costs associated with adoption of a new accounting rule on post-retirement health benefits. All U.S. companies eventually must make the accounting change.