(Reuters) - Intel Corp INTC.O Chief Executive Brian Krzanich resigned on Thursday after an investigation found he had a consensual relationship with an employee in breach of company policy.

The head of the largest U.S. chipmaker is the latest in a line of men in business and politics to lose their jobs or resign over relationships viewed as inappropriate, a phenomenon highlighted by the #MeToo social media movement.

Krzanich led Intel as rival chipmakers ate away at its dominance in the technology over several decades and he also presided over a series of high-level executive departures.

The change in leadership comes as Intel expands beyond personal computers and servers into areas such as artificial intelligence and self-driving cars, where smaller competitors including Nvidia Corp NVDA.O are strong. Qualcomm Inc QCOM.O leads in the mobile chip market.

The board named Chief Financial Officer Robert Swan as interim CEO and said it has begun a search for a permanent CEO, including internal and external candidates.

“An ongoing investigation by internal and external counsel has confirmed a violation of Intel’s non-fraternization policy, which applies to all managers,” Intel said in a statement, declining to give any further information about the probe. Its shares fell 2.4 percent.

The company’s board was informed a week ago that Krzanich had a mutual relationship with an employee in his chain of command in the past, according to a source familiar with the matter who asked not to be named. The relationship began before Krzanich became CEO in 2013 and ended several years ago, the person said.

‘BK’ OUT

Krzanich, who did not have an employment contract, is entitled to a $38 million “walk-away” payment in the event of a voluntary termination, according to Intel’s regulatory filings.

Of that, $31 million is in the form of accelerated stock awards and $4.1 million in the form of deferred compensation, based on Intel’s share price on Dec. 29.

An Intel spokesman declined to say whether the walk-away payment applied to Krzanich’s resignation, but said the investigation into Krzanich’s conduct continued and that the board reserved the right to take further action.

FILE PHOTO - Brian Krzanich, Intel CEO, holds up Intel's newest drone, the Shooting Star Mini as he speaks at the Intel Keynote address at CES in Las Vegas, Nevada, U.S. January 8, 2018. REUTERS/Rick Wilking

Corporations are under increasing pressure to “walk the walk” on executive behavior with the rise of the #MeToo movement, said Ivan Feinseth, chief investment officer at Tigress Financial Partners.

In the last few months Martin Sorrell, founder of advertising giant WPP Plc WPP.L, and casino mogul Steve Wynn of Wynn Resorts Ltd WYNN.O resigned after accusations of impropriety. Wynn has denied the accusations and Sorrell has denied any wrongdoing.

Krzanich, 58, an engineer and Intel veteran known at the company as “BK,” was appointed CEO in May 2013. Intel shares more than doubled during his tenure as the company expanded into new markets.

He was recently credited with containing the fallout from the discovery of security flaws in the company’s chips that could allow hackers to steal data from computers, although his sale of much of his Intel stock before the flaws were disclosed to investors attracted some criticism.

TIME FOR AN OUTSIDER?

His temporary replacement, Robert Swan, has been Intel's CFO since October 2016 and previously spent nine years as CFO of eBay Inc EBAY.O. Given his short tenure and lack of experience in manufacturing, he is not likely to be named permanent CEO, Cowen analyst Matthew Ramsay said.

While Intel dominates in processors for servers and data centers, global competitors are catching up with its manufacturing technology, said Bernstein analyst Stacy Rasgon.

“BK will go down in history as the CEO that let Intel’s process leadership advantage slip away,” he said, adding that a change at the top could bring in fresh ideas.

Kevin Cassidy, an analyst at Stifel, said that Intel would take the change in stride.

“Although we respect Krzanich’s efforts in redirecting Intel’s strategy from a computer-centric to a data-centric company, we view Intel as a process-driven company with a deep bench of CEO candidates that can continue to drive the corporate strategy,” he said.

In its 50-year history, Intel has never appointed a permanent CEO who did not come up through the company’s ranks.

But those ranks are thinner than they used to be, with prominent Intel executives such as former CFO and manufacturing chief Stacy Smith, former president Renee James, ex-architecture chief Dadi Perlmutter and Dianne Bryant, who headed the data center group, leaving in recent years.

Instead, Krzanich’s replacement could end up being one of the outsiders he brought into the company’s executive ranks, a sort of “insider outsider” such as Murthy Renduchintala, Intel’s chief engineering officer who joined Intel in 2015 after helping lead Qualcomm’s chip business.

“They’ve got some very good people they’ve brought in,” said Dan Hutcheson, CEO of VLSI Research Inc, who “know the company, know the new direction. It’s not a turnaround story.”

UBS analyst Tim Arcuri wrote to clients that “the door is open to hire from the outside.”

Intel on Thursday raised its second-quarter revenue and profit forecast, saying it expects quarterly revenue of about $16.9 billion and adjusted profit of about 99 cents per share, up from a previous forecast of $16.3 billion in revenue and adjusted earnings per share of 85 cents.

Analysts on average were expecting revenue of $16.29 billion and adjusted profit of 85 cents per share.

“There are no new payments as part of his departure,” a source familiar with the company told Reuters.