The recent chaos in financial markets yesterday threatened to blow apart a major international stock sale, which, if not deterred, could cost four U.S. underwriting firms hundreds of millions of dollars.

The British government had planned to sell its 31.5 percent stake in British Petroleum Co. for $12.1 billion beginning Friday. Yesterday, however, British Chancellor of the Exchequer Nigel Lawson -- under pressure from the underwriters of the deal -- said he would consider their request to terminate it.

If the deal goes forward, the underwriters and thousands of individual Britons who have committed to buy the stock at a price far higher than its current trading price would take a heavy hit. But the British government is under some pressure politically to go forward with the sale instead of bailing out the underwriters.

Key officials from the four U.S. firms who are underwriting the issue were in London yesterday, working through N.M. Rothschild, the merchant bank that is leading the underwriting, to halt the issue.

The American firms are Goldman Sachs, Shearson Lehman Bros., Salomon Brothers and Morgan Stanley, which between them have underwritten 505 million shares, for a total commitment of about $2.8 billion. The latter three investment banks have shared the issue roughly equally, with Goldman Sachs underwriting a larger number of shares. If the stock market does not recover by Friday, when the issue is scheduled to begin, the firms could face a book loss of $100 million or more each, according to an industry source.

The other firms deferred to Goldman Sachs for any comment on the BP issue, and Goldman Sachs said its policy is not to comment.

Meanwhile, other deals appeared to be moving forward undeterred and U.S. companies continued to announce plans to buy back their stocks, with International Business Machines Corp. saying it plans to purchase up to $1 billion worth of its stock.

Allegis Corp., the parent company of United Air Lines, announced it has agreed to sell its Westin Hotels subsidiary for $1.53 billion to the Robert M. Bass Group and Aoki Corp. of Japan. And CBS Inc. announced that it is continuing discussions with Sony Corp. of a possible sale of its records division for $2 billion.

The sale of the Westin Hotels by Allegis is part of a larger corporate restructuring, designed to focus the company on its airline business. Earlier this year Allegis announced the sale of its Hilton International Hotels chain and Hertz Corp. Analysts said yesterday that the price Allegis got for Westin was in the middle of precollapse estimates of what the hotel chain might bring. The buyers are an investment group based in Fort Worth and a Japanese firm that has invested in other U.S. real estate, including the Alqonquin Hotel in New York.

IBM said its board of directors voted to authorize the buyback of up to $1 billion worth of shares in blocks of at least 5,000. No time frame for the purchases was given.

Like hundreds of other companies that have announced stock buyback plans, IBM said it believes its shares are a good long-term investment.

The company said the move, in essence, extends buyback programs that began in 1986 and that are almost complete.

Even before the new buybacks begin, IBM will have spent about $2.5 billion and will have acquired about 19 million of its shares, or about 3 percent of the 604 million shares outstanding as of the end of July. Based on yesterday's closing price, $1 billion could add another 8.47 million shares to that number.

Other corporations announcing stock buyback plans yesterday included Warner-Lambert Co., J.C. Penney Co., Chesapeake Corp., Westvaco Corp., Cray Research Inc., Birmingham Steel Corp., Sierra Health Services Inc. and U.S. Shoe Corp. In addition, Fairchild Industries Inc. of Chantilly announced that its board has authorized the repurchase of as many as 3 million shares of its common stock.

Stock buybacks have proliferated since early last week in the face of sagging stock prices. In some cases, falling stock prices have made corporate managers fearful of potential takeover attempts, and have prompted them to buy back stock to protect against such attempts.

In other cases, when a company's stock is selling at below book value, buybacks become a way to improve book value -- net asset value divided by the number of shares outstanding -- and earnings per share. In addition buybacks provide a psychological boost for shareholders made nervous by the market, by demonstrating, as one analyst said, "that management stepped up to the plate to say that they think the stock is undervalued."

In London, the fate of the BP deal is expected to be announced by Thursday.

The two-thirds of BP stock that is privately owned has been trading at much lower levels than the price originally set for the offering of 330 pence or $5.45 a share. Yesterday BP closed at 259 pence a share, down 7. That means that small investors who have applied for BP shares and the underwriters, who will have to buy the stock if no other purchasers can be found, will end up with a lousy deal.

Last week the British government said it was determined to press ahead with the issue, despite the gap between the offering price and BP's trading price. But Monday afternoon, British investment banks underwriting the issue made a private appeal to Lawson, who heads the British Treasury, asking him to suspend the issue. Special correspondent Jeff Ferry in London contributed to this story.