BankAmerica Corp. yesterday reported a $337 million loss for 1985, as it continued to struggle with a massive portfolio of problem loans.

BankAmerica, which is the nation's second-biggest bank company, last year added $2.18 billion to its reserves for bad loans and wrote off $1.6 billion in loans as uncollectible. The addition to loan loss reserves is subtracted directly from profits.

BankAmerica's loss for the year would have been greater except that it earned $490 million before taxes by selling its headquarters building in San Francisco and its consumer finance subsidiary.

Donald K. Crowley, senior vice president of the securities firm of Keefe, Bruyette & Woods, said the BankAmerica peformance was worse than anticipated. He said that the key question is whether BankAmerica has its problem loans under control. "We're looking for them to report operating profits in 1986, but we can't have a lot of conviction about it," Crowley said.

Bank of America, the flagship subsidiary of BankAmerica, is plagued by loans to the Third World, commercial real estate, agriculture and shipping. Crowley noted that the agriculture and commercial real estate industries on the West Coast still are deteriorating.

For the final three months of last year, BankAmerica reported a loss of $178 million, even after a $180 million pretax gain on the sale of the consumer finance company.

BankAmerica announced that it would suspend payment of the 20-cent-a-share dividend scheduled for common stockholders next month.

Besides the problem loans, BankAmerica also had a $10 million loss on its travelers check operations in the Far East and had to pay a $4.75 million fine to the Treasury Department for failing to report thousands of cash transactions in excess of $10,000.

BankAmerica's results were in contrast to profitable performances announced yesterday by Citicorp, the country's biggest bank company, and a number of other major banking companies.

The fourth-quarter loss was another setback for BankAmerica, which a few years ago was the biggest and one of the most profitable bank companies in the country.

BankAmerica shocked the financial community last summer when it reported a $338 million loss for its second quarter -- mainly because of unexpectedly high loan losses and problem loans. The troubles were uncovered during an examination of Bank of America by officials from the Office of the Comptroller of the Currency.

As a result of the comptroller's examination, the bank company added $909 million to its reserves for loan losses in the second quarter of last year -- to cover $382 million of loans that were written off as uncollectible and to provide a cushion for other loans that were shaky but had not yet gone bad.

Analysts had hoped that BankAmerica, by making the big addition to the loan loss reserves last summer, would put its problems behind it. But the company had to add $488 million to loss reserves in the third quarter, and was able to report a tiny $65 million profit only because of a $310 million gain on the sale of its headquarters.

In the last three months of the year, the company added another $591 million to loss reserves and had to charge off $527 million in loan losses.

Samuel H. Armacost, president and chief executive officer of BankAmercia, called 1985 a "wrenching year" for the company.

BankAmerica reported that its problem loans declined by about $350 million in the final three months of the year -- to about $3.42 billion from $3.79 billion at the end of the third quarter. Most of the decline reflected the return of $212 million in Argentine loans to performing status.

BankAmerica Corp. had assets of $118.5 billion at the end of December, compared with $117.7 billion at the end of 1984.