Rep. Adam B. Schiff’s campaign strategy of spending millions to highlight Republican Senate candidate Steve Garvey’s conservative record appears to have paid off, making Garvey a strong favorite to emerge from Tuesday’s primary as Schiff’s general election opponent.

That’s the finding of the latest UC Berkeley Institute of Governmental Studies poll co-sponsored by The Times. The survey finds Schiff, the veteran Democratic congressman from Burbank, and Garvey, the former Dodgers star first baseman, in effect tied for the lead in the primary just days before the election.

Schiff’s strategy appears to be boxing out his chief rival, Rep. Katie Porter of Irvine, a fellow Democrat, who trails in third.

In the general election, Schiff would be an overwhelming favorite to beat Garvey in heavily Democratic California. The poll finds Schiff starting with a significant lead in a two-way matchup, 53% to 38%, with 9% undecided. By contrast, a general election between Schiff and Porter would start out tied, with 4 in 10 voters undecided, the poll found.

In the primary, Garvey is favored by 27% of likely voters, Schiff 25% and Porter 19%. Rep. Barbara Lee (D-Oakland) garners 8%, while 12% of likely voters pick a different candidate and 9% are undecided.

Political consultants following the returns of mailed ballots expect that Tuesday’s primary will be a low-turnout affair, with an electorate that is significantly older, whiter and more Republican than the state’s voter population as a whole.

“The composition of the turnout works to the advantage of Schiff and Garvey and to the detriment of Porter,” who is more popular with younger voters, said Mark DiCamillo, director of the Institute of Governmental Studies poll and a longtime California pollster.

A low turnout that is more conservative than the norm could also mean trouble for Proposition 1, Gov. Gavin Newsom’s latest effort to address homelessness and change the state’s 20-year-old Mental Health Services Act.

The ballot measure includes $6.4 billion in bonds to build facilities to provide 10,000 new treatment beds for people with severe mental illness.

Half of likely voters back the initiative, 34% oppose it and 16% remain undecided, according to the poll. Although that’s a significant lead, backers of ballot measures generally want to see support above 50% because undecided voters tend to vote no.

Several major Republican figures have endorsed the bond measure, but the poll shows a large majority of Republican voters oppose it, while Democrats support it.

“The dynamics of low-turnout California elections are pretty set in stone,” said political data expert Paul Mitchell.

“Those dynamics are old people over-perform, homeowners over-perform. Latinos under-perform and Republicans over-perform,” he said. That combination gives Garvey a significant boost at this stage of the election, he added.

Among the 20% of people who already had voted by the time the poll wrapped up Tuesday, Schiff led with 35%, with Garvey at 28%. Garvey does better with people who plan to vote on election day, while Schiff does better with people who plan to drop off their ballots before election day, the poll showed.

For much of last year, the Senate race was mostly defined by Lee, Porter and Schiff — a trio of Democrats with similar voting records — all looking for ways to stand out in a contest to succeed the late Sen. Dianne Feinstein.

Schiff led for much of last year with Porter nipping at his heels.

Both raised millions of dollars powered by their respective abilities to appeal to Democrats across the country.

Porter’s inquisitions of Wall Street executives during congressional hearings made her a favorite of liberal voters — particularly young ones — angry about inequality and corporate greed.

Schiff’s reputation as one of former President Trump’s leading opponents created a wellspring of loyalty among Democratic voters who were impressed by his work when he was chair of the House Intelligence Committee and a prominent impeachment manager.

Older voters also were drawn to Schiff, who garnered the endorsement of most the party’s established leadership, starting with former House Speaker Nancy Pelosi (D-San Francisco).

Those factors all had the makings for a generational clash among Democrats until Garvey joined the fray in October.

Garvey’s entry gave Schiff the opportunity to take advantage of the state’s top-two primary system, in which the two candidates who get the most votes in the primary advance to the general election, regardless of party.

Because Democrats outnumber Republicans by such a wide margin in California, a Democrat who ends up with a Republican opponent in a statewide general election starts out with a huge edge.

Schiff has spent upward of $25 million on television advertising, most of which has framed the contest as a two-candidate race between him and Garvey. An outside group of Schiff allies has spent roughly an additional $10 million on a similar effort.

Garvey’s campaign has spent just $1.4 million through mid-February.

Schiff’s ads, which make no mention of Porter, describe Garvey as “too conservative for California.” They appear to have had the intended effect of endearing Garvey, a first-time candidate, to Republicans who previously knew little about him other than his past as a baseball star. About two-thirds of likely Republican voters now support him, the poll found.

Porter has also been subjected to roughly $10 million in attack ads from an outside group funded by by Silicon Valley billionaires and cryptocurrency investors.

That appears to have hurt her standing among voters. In the current poll, 27% of likely voters had an unfavorable view of her — an 11-percentage-point jump from the last survey in early January. Her image remains favorable overall, however, with 45% of likely voters seeing her favorably, and 28% of likely voters having no opinion of her.

As Garvey, with Schiff’s help, consolidated the Republican vote, the congressman moved ahead among Democrats. The poll found him leading Porter among Democratic voters, 40% to 30%.

Garvey, Schiff and Porter are basically tied among No Party Preference voters.

Schiff has the edge in the state’s two largest population centers, Los Angeles County and the San Francisco Bay Area. In the Bay Area, he has the support of 28% of voters, with Porter in second at 24%. In Los Angeles County, his home turf, Schiff has 28%, with Garvey in second at 22%.

In the last Times poll in January, Porter led on her home turf, Orange County, by double digits. Now Garvey has leapfrogged her in the populous county, grabbing 34% support among likely voters. Porter has 30%.

Garvey also holds commanding leads in the Central Valley, Inland Empire and San Diego County.

As he has become better known, the shares of voters who see Garvey favorably and unfavorably have both risen. Currently, likely voters are closely split, with 36% having a favorable view and 37% an unfavorable one, while 27% had no opinion of him.

Nearly half, 47%, of likely voters had a favorable view of Schiff, while 37% had an unfavorable view and 16% no opinion.

Asked what issues were most important to their vote, 55% of likely voters said protecting abortion rights was very important and 51% said the same about being a strong opponent of Trump. Those two were the top motivators listed by Schiff and Porter supporters.

The next most important issue, listed as very important by 46% of likely voters, was support for tougher immigration laws. Among Garvey supporters, 94% said that was very important.

The starkest fault line is age, with Porter doing far better than her opponents with voters younger than 50. She leads both Schiff and Garvey with voters under age 40 by double-digit percentages. Schiff and Garvey are essentially tied with likely voters over age 65 (35% to 34%).

The Berkeley IGS poll was conducted online in English and Spanish on Feb. 22-27.

It surveyed 3,304 registered California voters who have already voted or are considered likely to participate in the Tuesday primary. Because the results were weighted to match census and voter registration benchmarks, estimates of the margin of error may be imprecise; however, the survey’s estimated margin of error for the likely voters is 2 percentage points in either direction.