As he emerges from a sometimes- bitter primary campaign, presumptive Republican presidential nominee John McCain poses a stiff challenge to either of his potential Democratic opponents in the general election, a new Los Angeles Times/Bloomberg poll has found.

The findings underscore the difficulties ahead for Democrats as they hope to retake the White House during a time of war, with voters giving McCain far higher marks when it comes to experience, fighting terrorism and dealing with the situation in Iraq.

Both Barack Obama and Hillary Rodham Clinton have made ending America’s involvement in the war a centerpiece of their campaigns. And even though a clear majority of those polled said the war was not worth waging, about half of registered voters said McCain -- a Vietnam vet who has supported the Bush administration’s military strategy -- was better able to deal with Iraq.

In head-to-head contests, the poll found, McCain leads Clinton by 6 percentage points (46% to 40%) and Obama by 2 points (44% to 42%). Neither lead is commanding given that the survey, conducted Feb. 21-25, has a margin of error of plus or minus 3 percentage points.

The Arizona senator is viewed favorably by 61% of all registered voters, including a plurality of Democrats.

The survey showed that McCain’s potential advantages extend even to domestic issues, where he is considered to be most vulnerable. Even though McCain has joked about his lack of expertise on economic issues, voters picked him over Obama, 42% to 34%, as being best able to handle the economy. However, Clinton led McCain on that issue, 43% to 34%.

“I just think he’s older, he’s more experienced, and he’s got the betterment of the country in mind,” said Robert Fear, 79, a registered Democrat from Newton, Ill., who said he planned to support McCain in November.

In the Democratic race, the survey showed, Obama’s support has increased across all of the party’s key constituencies.

The Illinois senator now leads Clinton, 48% to 42%, among Democratic primary voters nationally -- a far cry from his double-digit deficits throughout 2007 and the first weeks of 2008.

The poll, which surveyed 1,246 registered voters, was conducted under the direction of Times Polling Director Susan Pinkus.

Obama’s lead over Clinton in the Times/Bloomberg poll comes in the wake of his 11 consecutive primary and caucus victories. He is ahead in the closely contested race for delegates to the party’s national nominating convention and in recent days has made gains in the key states of Ohio and Texas, which hold primaries Tuesday.

At least two other national surveys released this week have shown Obama taking the lead among Democratic voters -- a development that puts further pressure on Clinton to win the upcoming primaries or face calls from some party leaders to drop out.

One hopeful sign for the New York senator: Of Democratic voters whose home states have yet to hold primaries or caucuses, the former first lady maintains a 13-point edge over Obama.

But the findings also showed that Obama has successfully broadened his coalition, which once was limited primarily to wealthier and better-educated Democrats.

While Clinton’s support has remained steady at 42% since the last Times/Bloomberg survey, in January, Obama’s has surged 15 points. That may be due to backing from voters who had supported John Edwards -- who dropped out of the race Jan. 30 -- as well as many previously undecided voters.

Obama now splits the vote with Clinton among Democratic primary voters without college degrees and among working women, two areas in which Clinton had been strong.

But the findings showed that whoever wins the nomination could face challenges in unifying the party. Older white women remain fiercely loyal to Clinton, while the contest has revealed a sharp race gap -- with blacks overwhelmingly supporting the man who could become the country’s first African American president.

The poll suggests that the once-muscular grip on the Democratic base held by Clinton and her husband, the former president, has loosened quickly as they have intensified their attacks on Obama and tried to paint him as ill-prepared for the presidency.

One of the most striking findings is that when Democratic voters are asked whom they support now, regardless of whom they voted for in an earlier primary or caucus, Obama leads by nearly 20 points, 55% to 37%.

“I liked Bill [Clinton], and I liked the combo of both of them,” said Monica Butler, 48, an executive assistant who lives in Orlando, Fla. “But then Bill just started running off his mouth again, and then you really think about things, and you think, ‘Oh, my God, are we going backward again? We need to go forward.’ ”

As for the New York senator, Butler added: “I just don’t relate to her anymore. She came out with good intentions, but I think she was more true to herself in the beginning than she is now.”

Poll respondent Valerie Grivas, a 49-year-old graphic artist in San Antonio, said she decided in the last few days that she would vote in the Texas primary for Obama, even though she has been excited about the prospect of electing the first female president.

She said she “couldn’t bear to watch” as Clinton attacked Obama during their debate in Austin last week. Playing off Obama’s campaign slogan of “Change you can believe in,” Clinton called his recent repetition of language spoken in 2006 by Massachusetts Gov. Deval Patrick, an Obama friend and supporter, “change you can Xerox.”

“I can’t stand to hear her try to shame him or insult him,” Grivas said. “It makes her look petty and small, and I don’t want them to attack each other. I want them to be on the same team.”

Democratic voters are divided over what should happen if neither Clinton nor Obama attains the 2,025 delegates needed to secure the nomination by the time the national convention begins Aug. 25 in Denver.

The survey’s participants are evenly split over whether the 796 superdelegates should vote for the candidate they personally support or for the one who won their state. But a majority (52%) thinks the party should allow delegates from Florida and Michigan to participate, agreeing with the position taken by the Clinton campaign. The national party stripped those two states of voting delegations for setting their primary dates ahead of the party’s election schedule.

But whether Clinton or Obama emerges with the nomination, McCain will be a force to reckon with.

When compared to either Democrat, McCain is rated as the “strongest leader.” He easily outpaces both when voters are asked who has the “right experience to be president,” beating Obama by 31 points and Clinton by 12.

But the survey did expose some weaknesses for McCain.

Nearly one in four Republican primary voters said they were “unhappy” that he would win the GOP nomination. And of those voters, about half said they would either vote for another candidate in November or stay home, an ominous sign for Republicans at a time when Democrats are expected to be highly motivated.

Both Clinton and Obama beat McCain when voters are asked who would best handle healthcare and “substantially change the way things are done in Washington.”

And on an issue dear to core conservative voters -- battling illegal immigration -- Clinton scored slightly better than McCain, a result of the Republican’s past support for creating a path to citizenship for those here illegally. Against Obama, McCain scored better on that issue.

peter.wallsten@latimes.com

Times Deputy Polling Director Jill Darling contributed to this report.