MADRID — Spaniards voted Sunday in local elections forecast to inflict a crushing defeat on the ruling Socialists as anger over mass unemployment boiled over into popular protests.

Protesters, who blame politicians for bleak economic prospects and a jobless rate of more than 21 percent, remained camped in central Madrid's Puerta del Sol square on election day.

The electoral impact of the swelling protests, which have brought tens of thousands into the streets since last weekend, was unknown.

More than 34 million people are eligible to vote Sunday, choosing 8,116 mayors, 68,400 town councillors and 824 members of regional parliaments for 13 of the country's 17 semi-autonomous regions.

Surveys forecast devastating losses for the Socialists as voters vent their anger over the loss of millions of jobs and painful spending cuts, including to state salaries.

Polls opened at 9:00 am (0700 GMT) and were to close at 8:00 pm (1800 GMT), with first results expected two or three hours later.