The Organization of African Unity summit ended today on a sour note, following one of the most argumentative conferences in its history, reflecting the tensions created by Morocco's war against Western Sahara guerrillas.

The Western Sahara debate, characterized by OAU Chairman Siaka Stevens as "heated and acrimonious," overshadowed the summit's effort to concentrate on a coordinated program to bring down the racially discriminatory government of South Africa and South African-ruled Namibia (also known as Southwest Africa).

The delegates called for the total withdrawal of Western investment in South Africa, scoring such lesser measures as the proposal in the U.S. Congress that American firms operating in that country be required to adopt nondiscriminatory employment codes.

Outside of unanimity on southern African issues, interviews and speeches during the summit indicated that the organization is at a crossroads after 17 years and mixed results in its efforts of to resolve Africa's growing list of domestic and cross-border conflicts.

Since its founding in Addis Ababa, Ethiopia, in 1963, the OAU has operated as a loose group of African heads of state, with widely divergent political views, tenuously held together by hard-won compromises.

The Western Sahara flare-up, delegates here said, came closest to splitting the organization when 12 states implicitly declared that they would support Morocco and leave the OAU rather than accept the anti-Moroccan guerrillas as members at the level of an "independent state."

Western Saharan guerrillas, called Polisario, have been battling. Moroccan troops for four years over the latter's annexation of the former Spanish colony of Western Sahara on the Atlantic coast of northwest Africa. The former colony was ceded to Morocco and Mauritania in 1976 by Spain.

The Polisario guerrillas, with the support of 26 of the OAU's 50 member states, applied for admission to the organization as the Democratic Saharaoui Arab Republic.

The issue of admission split the summit along ideological lines. Most of the African states in favor, such as Mozambique and Zimbabwe, are left wing or themselves achieved independence after guerrilla wars.

But older, conservative states, such as Senegal, Cameroon, the Ivory Coast and Egypt, balked at the precedent of allowing a guerrilla group to achieve full membership. The states that fought the move were also influenced by heavy Moroccan lobbying before and during the summit.

The front-line states, so-called because they border on South Africa and Namibia, led the lobbying effort on behalf of the Polisario, according to a Liberian delegate.

The question of admission has "been put into abeyance," according to OAU spokesman Peter Onu, until a committee meets with all parties in the dispute later this year. Last year, the OAU, which has been involved in mediation efforts for the past three years, called for a U.N.-supervised referendum in the war-torn territory, but Morocco has refused to cooperate.

"The Organization of African Unity is not equipped to handle crises," said Sierra Leonean Foreign Minister Abdulai Conteh in an interview. "The question is," Conteh added, how do we stablize Africa?"

Conteh and other delegates support the idea of creating a 15-member OAU security council that would deal with crises on an ad hoc basis.

Secretary General Edem Kodjo touched on the same theme in his remarks opening the summit.

"The persistence of the crises, their increasing complexity," Kodjo told the 1,000 delegates, "exacerbated egoism here and intransigence there, point to a future of doubt for all Africans.

Other issues raised at the summit included the 15-year civil war in Chad, heightened tension between Libya and Tunisia, continued conflict between Ethiopia and Somalia and black Africa's fears of South African efforts to destabilize the independent states of southern Africa.

In other matters at the summit:

The delegates unanimously adopted a resolution condemning Israel for continuing to allow new settlements on the West Bank and incorporating Jerusalem as an integral part of the country.

Secretary General Kodjo announced that the organization is $11 millions in arrears and that member states only paid 50 percent of their annual assessments last year. The arrears are the equivalent of one year's budget.