BAGHDAD (AP) — Sunni lawmakers pulled out of talks on forming a new Iraqi government after militants attacked a Sunni mosque in a volatile province outside Baghdad during Friday prayers, killing at least 64 people.

It was not immediately clear if the attack was carried out by Shiite militiamen or the Islamic State extremist group, which has been advancing into the ethnically and communally mixed Diyala province and has been known to kill fellow Sunni Muslims who refuse to submit to its leadership.

But Sunni lawmakers pointed to powerful Shiite militias, and two major parliamentary blocs pulled out of talks on forming a new Cabinet, setting up a major challenge for prime minister-designate Haider al-Abadi, a Shiite who is struggling to form an inclusive government that can confront the militants.

The blocs affiliated with Parliament Speaker Salim al-Jabouri and Deputy Prime Minister Saleh Al-Mutlak demanded that outgoing Prime Minister Nouri al-Maliki and the main Shiite parliamentary bloc hand over the perpetrators within 48 hours and compensate the families of victims "if they want the political process and the new government to see the light of day."