Updated from 12:42 p.m. with analyst comments.

Shares of IBM Corp. (IBM) dipped lower by 1.1% to $147.19 on Wednesday afternoon after Warren Buffett's Berkshire Hathaway Inc. (BRK.B)  slashed his stake in the legacy tech giant. 

According to regulatory filings posted late Tuesday, the legendary investor reduced his stake by nearly a third in the fiscal third quarter to about 37 million shares worth $5.37 billion, down from 54.1 million shares worth $8.32 billion. 

A very rough estimate based on quarterly position statements show that Berkshire has realized a loss of about $540 million on its IBM investment in 2017, after finally breaking even on it earlier in the year. 

As of the latest filings, Berkshire has fallen to being the fourth-largest shareholder in IBM, with a 3.9% stake; at one point, it was the largest one.  

CFRA Research analyst David Holt said Berkshire's move could put IBM's stock under pressure in the near term, but that it shouldn't overshadow some of the wider improvements being made at the company. 

"We do not think this negates the fundamental stabilization of key segments that have been a drag in the past at IBM," said Holt, who has a Buy rating on IBM shares. "Coupled with nascent success scaling cloud, we think this helps power solid trends in Strategic Imperatives and lends incremental margin lift." 

"In our view, material signs of recovery at IBM still look to be in play," Holt added. 

Buffett surprised Wall Street when he first invested in IBM six years ago. The 87-year-old Oracle of Omaha had famously resisted investing in tech stocks, saying he didn't understand how many of them make money. Recently, Buffett has admitted they he may have made a mistake by not buying shares of Amazon.com Inc. (AMZN) and Alphabet Inc. (GOOGL) .

After examining IBM's business model, Buffett decided to invest in 2011, saying Big Blue seemed to have a clear vision of where it would be headed next. 

"They have laid out a road map and I should have paid more attention to it five years ago," Buffett said in 2011. "...They've done an incredible job." 

Exactly, Watson.
Exactly, Watson.

At the time, IBM was in the midst of navigating a major shift to new markets like supercomputers, software and analytics from old areas like computer hardware. The once-struggling tech company seemed to be on a path to success. 

That turnaround hasn't panned out as well as Buffett had hoped. Earlier this year, Buffett began cutting back on his stake in IBM, selling off almost a third of his 81 million shares in the first two quarters of 2017. Explaining his decision for the portfolio move, Buffett said IBM has hit some roadblocks, as competitors continue to stunt some of the growth projections laid out by the company when he first started buying shares. 

"I don't value IBM the same way that I did six years ago when I started buying...I've revalued it somewhat downward," Buffett told CNBC in May. "...IBM is a big strong company but they've got big strong competitors too." 

Buffett has continued to wind down his holdings in IBM in the past several months. In August, Buffett reduced his stake to 54 million shares worth $8.3 billion from 64.5 million shares worth $11.2 billion. 

IBM, meanwhile, has had a rough year. The tech firm is the third-worst performer in the Dow Jones Industrial Average, having fallen over 7% this year. General Electric (GE) holds the No. 1 spot with a one-year decline of 40.4%, followed by Merck (MRK) , which has slid more than 14% since this time last year.

Elsewhere, Berkshire increased its position in Apple Inc. (AAPL) by 3.9 million shares during the third quarter, bringing its stake to roughly 134 million. The firm also upped its stake in Monsanto (MON) and Bank of America (BAC) .

Apple, GE and Alphabet are holdings in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio. Want to be alerted before Cramer buys or sells AAPL, GE or GOOGL? Learn more now.

More of What's Trending on TheStreet:

More from Stocks

Here Is How Mastercard Is Betting That Global Trade Will Increase

Here Is How Mastercard Is Betting That Global Trade Will Increase

Tesla, Disney, Marvel and Denmark's Danske Bank - 5 Things You Must Know

Tesla, Disney, Marvel and Denmark's Danske Bank - 5 Things You Must Know

Here's One Reason Why the Markets Have Become Resilient to Trade Worries

Here's One Reason Why the Markets Have Become Resilient to Trade Worries

3 Reasons Apple or Alphabet Should Consider Buying Tesla

3 Reasons Apple or Alphabet Should Consider Buying Tesla

FedEx Tanks After It Fails to Deliver on Earnings

FedEx Tanks After It Fails to Deliver on Earnings