Millions go to the polls amid threats of militant attacks and after the collapse of peace talks.