A useful post by Peter Kellner at YouGov:

In all polls these days, the raw data must be handled with care. It’s normal for the sample to contain too many people in some groups, and too few in others. So all reputable pollsters adjust their raw data to remove these errors. It is standard practice to ensure that the published figures, after correcting these errors, contain the right number of people by age, gender, region and either social class (Britain) or highest educational qualification (US).  Most US polls also weight by race.

Beyond that, there are two schools of thought. Should polls correct ONLY for these demographic factors, or should they also seek to ensure that their published figures are politically balanced? In Britain these days, most companies employ political weighting. YouGov anchors its polls in what our panel members told us at the last general election; other companies ask people in each poll how they voted in 2010, and use this information to adjust their raw data. Ipsos-MORI are unusual in NOT applying any political weighting.

Pew and ABC/Washington Post polls on the other hand does not control for party ID. Comparing election outcomes state by state on Nov 6 with election forecasts ay allow us to discriminate among these various philosophies.