The Sahwa fighters returned fire, wounding the attacker, who then blew himself up as they gathered around him, killing three and wounding six others, police officials said.
The Sahwa militia took up arms against al-Qaeda in late 2006 with US backing.
Its fighters, recruited from among tribesmen and former anti-government fighters, are credited with turning the tide in the war against al-Qaeda in Iraq.
'More dead than wounded'
Control of the Sahwa passed to Iraq in October 2008, and their wages - said to have been cut from $300 under US leadership to $100 monthly - have been paid, often late, by the Shia-led government.
The attack in Baghdad took place as Sahwa fighters gathered outside a military base to collect their pay.
"There were more than 150 people sitting on the ground when the explosion
took place. I ran, thinking that I was a dead man," Uday Khamis, 24, who was sitting outside the Mahmoudiyah hospital where many of the wounded were taken, said.
His left hand was bandaged and his clothes were stained with blood.
"There were more dead than wounded," he said.
It was unclear how many of the dead were members of the militia, Iraqi troops or civilian accountants handing out money.
Sunni fighters targeted
A military official at the base said the explosion was the work of one suicide bomber wearing an explosives vest.
"The suicide bomber blew himself up in the biggest group of Sahwa members. We generally let them enter the base in groups of 10 for them to get their salaries," the AFP news agency quoted a military official, who wished to remain anonymous, as saying.
In the past six months many Sahwa fighters and members of their families have been killed in revenge attacks.
"They have been often targeted in recent months for their role in combating al-Qaeda and other Sunni fighters," Al Jazeera's Rawya Rageh, reporting from Baghdad, said.
The attacks have not been claimed yet, but "all fingers are going to be pointed at al-Qaeda in Iraq at this point," Rageh said.
Four months after an inconclusive parliamentary election in March, Iraq has yet to form a new government as politicians bicker over who will lead it.
Analysts say the political vacuum is fuelling instability and various armed groups are exploiting it to their advantage.