Billionaire investor Warren Buffett's Berkshire Hathaway invests over $100 billion in individual stocks, and while Buffett's renowned for his patience, it appears he's pretty unhappy about the performance of IBM (IBM 1.05%) and General Electric (GE -2.11%). According to Berkshire Hathaway's quarterly 13-F report, Buffett spent last quarter reducing his ownership stake in Big Blue and unloading all of his shares in GE.

IBM's competition is stiff, and profit is struggling to grow

IBM may be a big-cap technology stalwart, but its attempts to transform itself by focusing on next-generation technology has been slow to overcome headwinds associated with declining demand for its legacy hardware products.

Warren Buffett speaks to someone in a crowd.

IMAGE SOURCE: MOTLEY FOOL.

The company announced disappointing first-quarter financials back in April, and in July, it didn't offer much more to cheer about when it released its second-quarter numbers. Sales slipped another 4.7% year over year, bringing the company's streak of quarterly annual revenue declines to 21. The company reported that earnings per share increased 1% year over year, but as fellow Fool Timothy Green points out, the increase disappears if you take away the benefit of a lower tax rate.

IBM's pinned its hopes on a return to growth on its strategic-imperatives businesses, a collection of services focusing on higher-growth opportunities like cloud computing. Revenue from these businesses has been a bright spot for the company in the past, but the pace of growth slowed in Q2 -- sparking worries that IBM may be struggling to compete against top players including Amazon.com's AWS, Microsoft, and Alphabet. IBM's strategic-imperatives sales have grown at a strong double-digit rate, but in Q2, performance was much more mixed, with cloud and mobile posting growth of 15% and 27%, respectively, and analytics and security growing by only 4% each, including currency impacts.

The quarterly results probably didn't inspire much confidence in Warren Buffett, who reported in his first-quarter SEC filings that he had already begun selling off some of his massive position in IBM. In the first quarter, he sold about 17 million shares, leaving him with 64.5 million shares remaining on March 31. In the second quarter, his selling continued, leaving him with about 54.1 million shares on June 30.

It's anyone's guess if Buffett's going to eliminate IBM shares from his portfolio altogether, but I wouldn't bet against it. It's hard to sell as much stock as Buffett owns in IBM without causing a big drop in share prices, so in instances like this, Buffett has taken a measured approach that includes selling shares over the span of a few quarters. One recent example of this was his decision to sell his Wal-Mart Stores, Inc. stock. It took him about one year to fully unwind that position.

General Electric: Too many challenges

After the financial crisis, General Electric took big steps to reduce its exposure to consumer finance and boost its exposure to energy. It's too early to say for sure if those were smart moves, but lately, the report card is mixed. With longtime CEO Jeffery Immelt exiting earlier this month, there appears to be too much uncertainty associated with owning GE stock for Warren Buffett to stick around.

GE Chart

GE data by YCharts.

Buffett gave GE an important vote of confidence during the financial crisis when he invested $3 billion in GE warrants in 2008 that he later converted into stock. However, he sold 10.6 million shares in Q2, which represented the last of his remaining investment in the industrial giant.

It's likely that the Oracle of Omaha made a nice pile of money on GE over the years because, while GE's stock has dipped lately, it gained about 40% during Buffett's investment period. Nevertheless, Buffett's decision to sell the rest of his GE shares indicates he'd rather own cash than continue owning GE. Frankly, it's hard to blame him given that GE's second-quarter sales fell 11.7% and its net earnings fell 57% year over year.

New CEO John Flannery, who took the helm in August, clearly has some work to do to get GE's ship back on course. Previously, Flannery was the top person at GE Healthcare, a bright spot in the company's performance over the past decade. Navigating what's become a very tough energy market will be among his biggest challenges. 

GE recently merged its energy business with Baker Hughes to form an energy service Goliath -- however, crude prices and natural gas prices have remained depressed and that's crimped demand and sent GE's oil and gas-related revenue 6% lower through the first six months of 2017 when compared to 2016. Profit in the oil and gas segment nosedived 52% in Q2 alone -- hardly encouraging news.

GE's transportation business, which includes its rail business, is also a trouble spot. Its sales fell 5% year over year in the first six months of 2017, and that drop caused an 18% decline in that segment's profit over the period. It probably shouldn't be ignored that Warren Buffett owns Burlington Northern, one of the country's biggest rail companies. From that perch, he probably has an interesting view of what locomotive demand looks like going forward. If his selling of GE is any indication, Flannery has an uphill climb ahead of him with this business.

Overall, General Electric's success is tightly tied to the global industrial economy, but since it's become less reliant on consumer spending, it may no longer jibe with Buffett's current thinking. After all, while he was cutting ties with GE last quarter, Buffett was investing hundreds of millions of dollars in Synchrony Financial (SYF 5.04%), which was formerly part of GE's consumer-lending business before being spun-off in 2014. Perhaps one investing takeaway from Buffett's sale of GE is that he has more confidence that American workers' wages will strengthen than he does that commodities and industrial-goods spending is heading higher.