The incentives for market-based research aren't wrong, but they do have a limit. Investors aren't going to spend ten billion dollars on research to find a cure they expect to make only one billion dollars profit from. They aren't running charities. Many other people are running charities, of course, especially for cancers. If you want to help fund them you can. Many people do. The govt also funds a ton of research.
As for the motivation to not pursue a profitable cure because you'd rather make more money from treatments, this isn't really the options you get to choose from. The real game they play is to choose either to find and sell the cure if one exists, or to sit back and watch the just-as-smart competition find and sell that cure instead of them. Their profitable treatment loses out either way.
Cancer affects many many people who are healthy otherwise and would have had many more productive years. It isn't just a disease of old age. Especially breast cancer. Either way, elderly folks are the most prolific voters, so there's the incentive situation for the govt.