Wednesday was not a good day for President Donald Trump. It wasn't half-bad for markets.

Stocks ended the day marginally higher on Wednesday as the CEOs of some of the biggest publicly-traded companies in the United States exited a pair of presidential advisory councils aimed at the economy and manufacturing. The president may have a penchant for bragging about the stock market, but it has become increasingly apparent that the stock market doesn't care much about him.

The Dow Jones Industrial Average, S&P 500 and Nasdaq all ended the day with modest gains. Shares of Merck (MRK) , whose CEO Ken Frazier was the first executive to exit Trump's manufacturing council, climbed 0.32% to $62.70. Campbell Soup (CPB) stock gained 0.48% to $53.99 and 3M (MMM) stock rallied 0.36% to $207.02; the CEOs of both firms quit the manufacturing council Wednesday before it was disbanded.

While corporate executives worked to gain Trump's favor early in his administration in hopes of business-friendly policies, it appears many have moved on, either by choice or by force. A number of executives, including JPMorgan Chase's (JPM) Jamie Dimon, General Electric's (GE)  Jeffrey Immelt and Johnson & Johnson's (JNJ) Alex Gorsky, criticized the president directly in their statements on racist violence in Charlottesville, Virginia, over the weekend and Trump's equivocal reaction.

"The President's statements yesterday were deeply troubling," Immelt said.

"The President's most recent statements equating those who are motivated by race-based hate and those who stand up against hatred is unacceptable," Gorsky said.

CEOs seem to be doing just fine without Trump's help. Earnings are up, stocks are on the rise, deal-making is robust and stock buybacks are continuing. And while the president has a clear penchant for bragging about the stock market, most Wall Street analysts agree it's not about him.

And it's not just investors who are turning a blind eye to Trump -- economy-focused players in Washington, D.C., are tuning out the noise on him as well.

House Ways & Means Committee Chairman Kevin Brady (R-TX) in an interview Wednesday with CNBC said he remains focused on tax reform, even as the sky was falling in Trumpworld.

"I think there's room for all of America to work with this White House and Congress to do this because, while there are divisions in the country, this is about delivering tax relief to all Americans," he said. Apparently, tax cuts are color-blind.

National Economic Council Director Gary Cohn, who was reportedly "disgusted" and "upset" by Trump's Charlottesville comments, is forging ahead of tax reform as well. He told reporters after Trump's baffling Trump Tower press conference on Tuesday that he hopes tax legislation can get done before Thanksgiving.

Wednesday marked what is arguably one of Trump's worst days as president. It turns out Wall Street doesn't much care anymore.