Such heaps of money could only be meaningfully invested in case of a large technological breakthrough that would enable the emergence of entirely new industries, skill-sets and supporting businesses. Think of the internal-combustion engine, electricity, and (we are already exhausting the potential of this one) the Internet.
Otherwise, the mere existence of that money (even if it never gets spent) serves no other purpose than to reinforce the status-quo.
Problem is that effectively if you spend that money you wind up devaluing any capital you already have invested in. So, why risk the devaluation? If I were Apple or Microsoft I would just quietly hum to myself and pretend it didn't exist. Or that I'm saving it for occasional dividend payouts. But beyond that, I'd stay as far away from active investment as possible.
In many ways this is akin to a mathematical singularity where all economic models break down. Can't tax it out of the economy or deficit spend it, both will cause misallocations from the speculative markets as they'll assume the dead money has worth which incentivizes them to spend it which again devalues existing capital invested which causes the markets to collapse. So, what to do? I assume at this point we're heading into a situation that's similar to a post-scarcity economy, so it's inevitable that prices will have to collapse whether we want them to or not. And that means certain norms such as property rights go away (along with the State institutions that prop it up). We'll get a Star Trek future, but only after the Mad Max nightmare between now and then is my guess (purely speculative and not of substance imo).
Otherwise, the mere existence of that money (even if it never gets spent) serves no other purpose than to reinforce the status-quo.