BELFAST, Northern Ireland (AP) _ Four suspected IRA guerrillas were shot and killed by British soldiers after they attacked a police station, authorities said today.

Two other gunmen and a soldier were wounded in the gun battle late Sunday at Coalisland, 30 miles west of Belfast, a police spokesman said. All three were under police guard in a hospital.

A stray bullet struck a fuel tank, touching off a fire that gutted a nearby Roman Catholic church.

No one was injured at the police post, the spokesman said.

Thirty-one people have been killed this year in one of the worst eruptions of sectarian and political violence in Northern Ireland in a decade. The Irish Republican Army, which is fighting to end British rule in the province, has slain 10 people and has lost five men in clashes with security forces.

Sinn Fein, the legal political arm of the IRA, identified one of those killed overnight as Kevin Barry O'Donnell, 21, who was cleared of gunrunning charges by a London jury in March.

O'Donnell's cousin Seamus O'Donnell also was among the dead, Sinn Fein said. The other dead men were not immediately identified.

During his trial in London, Kevin O'Donnell denied he was involved with the IRA, saying he came from a devout Roman Catholic family opposed to the taking of life. After he was convicted of two minor firearms charges, he was deported from England to Northern Ireland.

The police spokesman, speaking on condition of anonymity, said a heavy machine gun, which had been mounted on a stolen truck, was recovered along with several AK-47 rifles.

The spokesman said that a short time after the police station was attacked ''soldiers in uniform encountered a number of vehicles and armed men outside the town at Dernagh Crossroads at a car park at St. Patrick's Roman Catholic Church.''

People living near the scene of the shootout, which happened just after 11 p.m., said the gunmen were ambushed by the Special Air Service, a highly trained British army unit.

Witnesses told of flares lighting the night sky and said the soldiers were dressed in black.

''As soon as the shooting started we ducked to the floor. The shooting went on and on and on,'' an unidentified woman told British Broadcasting Corp. radio. ''It lasted roughly about 10 minutes all together.''

Francis Malloy, a local councilor for Sinn Fein, said: ''Maximum force was used when these men could have been arrested. This looks like another case of shoot to kill.''

Last week, 600 more soldiers were brought into Northern Ireland and additional covert operations were put in place in response to the upsurge in violence.