At least 33 inmates have been killed in an uprising at the largest prison in the northernmost state of Brazil, according to news reports citing local officials. The violence, which occurred overnight in Roraima state, comes just five days after Brazil's deadliest prison massacre in nearly 25 years.

That violence last weekend left at least 56 prisoners dead in a penitentiary in Manaus, just south of Roraima in the massive state of Amazonas.

Brazilian paper O Estado de Sao Paulo reports that most of the victims of Friday's violence were decapitated, dismembered or had their hearts torn out. The attackers had broken locks and invaded an area where low-risk prisoners were kept, the news service says.

The riot at Roraima's Monte Cristo penitentiary was eventually put down by elite police forces. Police officials say there were no escapes.

The killings at both prisons appear to be the work of members of Brazil's drug gangs. Members of the First Capital Command, or PCC — Brazil's most powerful gang — were among the dozens killed days ago at the Anisio Jobim Penitentiary in Manaus.

The North Family faction, a rival of the PCC, is believed to have led that massacre. "The Family is allied with the Rio de Janeiro-based Red Command drug gang, Brazil's second most powerful faction after the PCC," Reuters reports. Red Command and the Sao Paolo-based PCC are said to be fighting over smuggling routes in the Amazon.

The news service has more on the feud between Brazil's two major gangs:

"For more than two decades, PCC and Red Command maintained an uneasy alliance, ensuring that a steady flow of drugs and guns flowed across Brazil's long jungle border."But about six months ago PCC and Red Command split, as PCC moved to take control of lucrative drug routes across the border with Paraguay and become Brazil's dominant gang."Experts say PCC also has been moving to infiltrate areas in Red Command's home base of Rio de Janeiro, further stoking a turf war that threatens to spill onto the streets of Brazil's biggest cities."

NPR's Philip Reeves says investigators are now trying to determine whether the massacre in Roraima is an act of retribution, which many feared following the killings of PCC members earlier in the week.

Brazilian Justice Minister Alexandre Moraes resisted initial reports that called it just that. He says the uprising was the result of an internal dispute within the PCC.

As Philip reported Thursday from the city of Manaus, Brazilian officials are now facing questions about how prison violence has been allowed to happen on this scale.

Copyright 2017 NPR. To see more, visit http://www.npr.org/.