President Donald Trump denounced automaker General Motors this week after the company announced plans to cut 14,000 jobs in the United States and Canada, and to cancel some of its popular car models, including the plug-in hybrid Chevrolet Volt. He also threatened to cut the company's subsidies, specifically a tax credit the car-maker is already likely to lose.

Shares fell 3 percent in response.

All the same, an investment in GM in 2012 — two years after the company officially came out of bankruptcy and began recovering from the major financial crisis that hit the auto industry — would have made you a profit. A $1,000 investment then would be worth more than $2,200 as of Nov. 30, according to CNBC calculations, including price appreciation and dividend gains reinvested.

While the company's stock has trended slightly upward over the years, and has generally been doing better than it was six years ago, any individual stock can over- or under-perform and past returns do not predict future results.

CNBC: General Motors stock as of Nov. 30, 2018

On Tuesday, when Trump tweeted that he was "very disappointed" with the company's decision to idle U.S. plants in Ohio, Michigan and Maryland and threatened to cut the company's federal subsidies, GM shares were on track for their worst day in a month.

It was not immediately clear how much subsidies do, in fact, help GM's business. Currently, buyers of electric vehicles qualify for a tax credit of up to $7,500, which is designed to encourage eco-friendly car sales. But that credit starts to phase out when a manufacturer sells 200,000 electric vehicles in the United States, and GM expects to hit that cap by the end of the year.

The company has also started to move away from at least one of its electric vehicle models, the hybrid Chevrolet Volt.

GM warned this summer that the Trump administration's trade war could force job cuts. The company also said in a statement that it remains "committed to maintaining a strong manufacturing presence in the U.S." and that "many of the U.S. workers impacted by [plant closures] will have the opportunity to shift to other GM plants."

After the 2008 financial crisis, GM was among three major automakers, including Chrysler and Ford, to be bailed out by the U.S. government. Trump alluded to that in his tweet: "The U.S. saved General Motors, and this is the THANKS we get!"

If you're looking to invest in GM, or in the stock market in general, experienced investors like Warren Buffett, Mark Cuban and Tony Robbins suggest you start with index funds, which hold every stock in an index, offer low turnover rates, attendant fees and tax bills. They also fluctuate with the market to eliminate the risk of picking individual stocks.

Like this story? Subscribe to CNBC Make It on YouTube!

Don't miss: If you invested $1,000 in Facebook at its IPO, here's how much you'd have now