Several hours of attempted negotiations failed and police using non-lethal force were unable to quell the riot, Fasci said. So authorities decided to use lethal force to protect the lives of the guards and the prisoners.

Authorities could see through video monitors that at least one prisoner had already been killed and guards had been taken hostage, Fasci said. The guards were being held and beaten on the roof.

"If they had not taken these decisions right now we would be talking about many more dead," Fasci said.

The trouble started Monday night when one of the half-dozen gangs that are normally kept apart inside the prison protested. The protest died down, but early Tuesday morning fighting broke out and a prisoner was killed and his body burned, Fasci said.

When police first went in trying to take control they were met by about 150 prisoners who attacked them with metal tools and rubble from work that was being carried out inside the prison.

No guards were killed in the violence, but a police officer was gravely wounded with a punctured lung.

It is 4,000 inmates against 300 guards, Fasci said, adding the facility was not designed for that many prisoners or prisoners of the risk level it holds.

"It's very difficult to keep them in order," he said.

He said autopsies would be required to determine how many were killed by other inmates and how many by authorities. At least two appeared to have died from bullet wounds.

In March, four inmates in the same prison died after they took control of a prison pharmacy and apparently overdosed.

In another prison in Nuevo Leon, 49 prisoners died when two factions of the Zetas cartel clashed in February 2016.