Software patents have little to do with "protecting an invention", but they are a powerful tool of oppression. (The oppressed party being μISV's and the ones doing the oppressing are the guys with the patents, think Microsoft, Adobe, Unisys, IBM and other large multinational corporations.)
Software patents are an impediment to innovation and therefore detrimental to software consumers.
Contrary to popular belief, a patent sought on an algorithm, method or GUI-aspect is usually not sought because the particular method is so ingenious that it is only natural to protect the awesome intellectual investment - on the contrary: Software patents are almost by definition applied for exclusively to monopolize the obvious.
Software patents are a legal way to convert money into monopoly. If you really have invented something cool, of course you won't apply for a patent, because then your competitors will be able to get a detailed description at no cost.
Another patent myth is that a patent somehow protects against copying. Not at all. Copyright Law, as laid out in the Berne Convention, does that already. In countries that are a signatory to it.
How Patent Law applies internationally is partly defined in the Agreement on Trade-Related Aspects of Intellectual Property Rights (TRIPS), and signatory nations abide at least in part by the rules the US has stipulated.
It is almost trivial to be granted a patent on virtually anything, partly because the US government makes hundreds of millions of USD on issuing them. It is much harder to actually enforce a patent.
Like junk bonds, patents are avidly traded. Small companies, established with the sole purpose of filing for patents, employ dozens of freelance scientists from low-wage countries to apply for as many "obvious" software patents as possible. When hundreds of patents have been filed on pathetically simple things, the venture capitalists sell their company to a larger company, and that company subsequently sues, or threatens to sue a large software company like Microsoft. Microsoft then either settles the case (they paid one hundred million USD to Borland in a (partial) patent infringement case) or acquires the company. Software patents are big business.
Innovation is stifled by software patents. It is much easier for a large software company to make competition impossible by dozens of patents that should never have been granted in the first place, and ensure enforcement by an army of attorneys, than continuing to stay ahead of their competition by steadily improving their products.
Small independent software vendors do not have the thousands of USD/year it takes to apply for and maintain a patent, let alone access to the legal apparatus required to successfully defend their patent in court against the likes of Adobe and Microsoft. This means that software patents, in practice, are nothing but a vulgar tool for the larger software companies to bully the smaller ones, regardless of the merit of the patent - and at the cost of innovation.
This translates to sub-optimal software at inflated prices, and even worse, a slowing down of innovation in countries where they take IP seriously. The whole concept of "Intellectual Property" is ethically and logically questionable. Because when two people get the same idea at the same time, why would the one with the cash be allowed the sole benefits of that idea? Because he paid for it to the US government?
The US government has monopolized the implementation of ideas in the software world, and is making a lot of money out of it. It threatens developing countries like India with trade sanctions when they don't enforce US law in their own countries. Software patents are a prime example of "money making more money", they have spiraled out of control at the sole benefit of Corporate America.
Really innovative ideas in software are rarely patented. They are kept as trade secrets. Taking Go as an example, with a single exception (David Fotland), guys selling their Go programs don't explain the details. Fotland has a well-paying day time job however, and the others live of their software.
Does it go too far to call this the "patent mafia"? Not at all. Software patents are relatively benign compared to pharmaceutical patents that amount to "bio-piracy". Companies rip off indigenous knowledge on medicinal plants, patent the active ingredient and monopolize the production of that substance worldwide for decades. The tribe can be lucky when enough of the medicinal plants remain, as extracting sufficient of the active compound to do first tests (before an efficient synthesis methods is developed) can decimate a population. Contrary to popular belief, nature-based medicines do not require hundreds of millions of USD in R&D (and over half of all medicines are discovered in nature first, like artemisinin and oseltamivir), and patenting them and selling them with 99% profit is downright criminal from an ethical standpoint.
The "inventions" that pertain to most software patents carry no R&D price tag. It can be argued that it is unfair that algorithms can be patented. Like the absurdity of patenting the Law of Gravity, patenting things that occur naturally in nature is highly questionable, however hard it was to discover them. An algorithm is, at best, the "best solution of achieving a goal". Many algorithms are therefore not inventions, but common-sense inspired discoveries of "natural solutions", and like the Law of Gravity, those belong to us all.