Roughly speaking, the price per share of a company is a reflection of the expectations of the market about the future cash flows a company generates.
The market is simply telling us that it expects Tesla to generate more cash flow (very different than accounting profit) than of GM.
If you believe otherwise you see something the market doesn't and therefore can profit handsomely
EDIT: wording