General Motors Corp. produced its last X car yesterday, ending with solemnity and controversy what began six years ago as one of the biggest car promotion programs in U.S. auto history.

The line was closed with the final assembly of a 1985-model, light-blue Buick Skylark at GM's Willow Run plant in Ypsilanti, Mich. Last rites were administered, in the presence of GM officials and reporters, at 5:35 p.m. EST.

In its relatively brief product life, the X body moved from Car of the Year in 1980 to Loser of the Year in 1985. It was a journey fueled by initial consumer infatuation that became a volatile mixture of disappointment and lawsuits.

The catalyst for the change was an allegedly faulty rear-brake system installed in the 1980-model X cars -- the first of the line that actually went into production in calendar year 1979.

There were complaints that the rear brakes locked during moderate-to-hard stops, causing loss of driver control. GM is in U.S. District Court here fighting those charges in a $4 million lawsuit brought against the auto maker by the federal government.

In a related case, GM is accused by the federal government of lying to cover up the alleged defects.

GM has produced 3.3 million X cars since January 1979. The auto maker has held fast to its claim that those cars are safe. But the controversy that washed over the 1980 models eroded X-car sales and hastened the demise of the vehicle family and its offspring -- even those later models whose braking and handling were substantially improved.

It wasn't supposed to happen that way.

At birth, the front-wheel-drive X cars were hailed by domestic auto critics as a four-part American response to the fuel-efficient Japanese cars then invading the U.S. auto market.

The Xs were the Chevrolet Citation, Oldsmobile Omega, Pontiac Phoenix and Buick Skylark. They came with either a 2.5-liter, inline, four-cylinder engine, or a speedier 2.8-liter V-6. The cars could seat five people or carry as much cargo as a small pickup truck.

Motor Trend Magazine gave the X bodies "Car of the Year" honors in 1980. But then, the complaints started.

Some X-car buyers began calling the National Highway Traffic Safety Administration with reports that their cars locked up in moderate-to-hard stops and spun out of control. There were reported injuries and deaths -- and publicity and congressional hearings and more publicity and, finally, on Aug. 3, 1983, a $4 million lawsuit filed against GM by the federal government.

GM says that the lawsuit "in and of itself had nothing to do" with the company's decision last year to start phasing out the Xs, although GM conceded that "misleading publicity" stemming from the government's charges "may have affected some purchase decisions."

Ward's Auto World, a major auto trade magazine published in Detroit, was less ambivalent in its assessment. The company gave the X car its 1985 "Loser of the Year" and "Wrath of Washington" awards, saying that the line was "bludgeoned by relentless publicity over allegedly unsafe brakes on earlier models."