In "Flawed Justice: Accountability for ISIS Crimes in Iraq", HRW said Baghdad and the Kurdish authorities in the north were holding "thousands of trials of Islamic State suspects without a strategy to prioritise the worst abuses under Iraqi and international law".
"The broad prosecution under terrorism law of all those affiliated with ISIS (IS) in any way, no matter how minimal, could impede future community reconciliation and reintegration, and clog up Iraqi courts and prisons for decades," the New York-based group said.
The group said the authorities "appear to be prosecuting all ISIS suspects in their custody under counterterrorism laws, primarily for ISIS membership, and not focusing on specific actions or crimes that may have been committed".
HRW identified 7,374 cases of suspects charged under this law since 2014, of whom 92 have been executed.
More From This Section
Its researchers estimate the total number of people imprisoned for suspected IS membership at 20,000.
HRW said it was easier to charge a suspect under anti- terrorism laws than with a specific offence under the penal code as all the authorities had to do was to prove IS membership.
It said counterterrorism laws carry harsh sentences, including life in prison or the death penalty, even for belonging to the jihadist group.
"But that makes it more difficult to prioritise and punish the most serious crimes," it said.
It said the report was based on information gathered in Arbil and Baghdad between November 2016 and July 2017.
HRW also said it regretted that a 2016 Iraqi law granting amnesty to suspects who can show they joined IS or any extremist group against their will and have not committed a crime was not being consistently applied.
"Execution of fighters who surrender or are hors de combat is a war crime," HRW added.
IS swept across a third of Iraq in 2014 and seized several cities including Mosul, before starting to be driven out in mid-2017.