Most Americans support the new, controversial Arizona law that gives police there the power to check the residency status of suspected illegal immigrants. But most also still back a program giving those here illegally the right to earn legal documentation, according to a new Washington Post-ABC News poll.

In all, 58 percent of the 1,004 adults polled in early June supported the law, while 57 percent backed a “path to citizenship.”

Immigration has been rising in prominence as an issue and has the potential to roil party unity on both sides as Democrats and Republicans push for the upper hand in the midterm elections. Liberal Democrats are broadly against the Arizona law; moderate and conservative Democrats are more evenly split on the issue. Most staunch Republicans oppose a “path to citizenship,” while a majority of other Republicans favor such a plan. At the Texas Republican convention last week, the party splintered over the issue, with moderates proposing a legalization plan through military service; the party ultimately added an Arizona-like measure to its plank.

“I’m for it (the Arizona law) because it’s giving a sense of accountability and it’s making it easier to recognize who’s who,” said Terrance Hawkins, 36, a comedian from Oxon Hill, Md., and a Democrat. Illegal immigrants, he said in a follow-up interview, “just come and they stay, and they end up getting health care coverage.”

But Nancy Thomas, 58, a Democrat who is a bodywork therapist in Annapolis, Md., worried that the law could result in racial profiling. “It leans too much on somebody’s appearance, and it doesn’t really depend on an action somebody does,” she said.

A further challenge for Democrats is that public disapproval over how President Obama is dealing with immigration has edged higher, with 51 percent of all respondents — and 56 percent of political independents — giving him low ratings on the issue.

One unifying immigration concern is the widespread perception that the federal government is not doing enough to keep illegal immigrants from coming into the country. Overall, 75 percent of those polled fault border enforcement, and 83 percent support using National Guard troops to patrol the U.S.-Mexico line.

The poll results have a margin of error of plus or minus three percentage points.