The real problem is just that patents are way too long for software. Long patents make sense for things in a slow changing industry. If it takes 10 years in pharma for research and another 5 years to pass trials, then 20 years of protection seems reasonable to recoup the investment. But for software, I'd argue that most patents are granted on things that are pretty obvious, and in many cases, I'd suspect probably writing up the patent takes longer than actually coming up with the idea and implementation. Certainly, if an engineer is churning out multiple patents a year, then I don't think it's likely that they have enough value to society to warrant issuing a patent for.
Let's not even forget the original motivation for patents, which was to increase knowledge sharing so that companies didn't keep their technology secret, and conferring an advantage on companies who chose to share their methods for others to copy and build upon. That's clearly a totally different outcome to when patent trolls are suing people for accidentally infringing a patent they didn't even know existed.