EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Does Microchip play fast and loose with the GPL?

Started by Eric March 18, 2008
I've been looking at the PIC24 and PIC32 compilers from Microchip
lately. These are based on the gnu toolchain.

Their PIC24 compiler works for a month in a full-featured manner, and
after that it goes down to a "student edition" that has most
optimizations disabled. Once you pay megabucks you get them back. I
initially thought this wasn't a violation because I assumed they wrote
their own closed source optimizer. However, this appears not to be the
case, and the source code they released for their C30 compiler doesn't
have any reference to any kind of limitiations. So the executable they
released was clearly not built from the source code they released.

Even worse, their PIC32 compiler, called C32, has a 64K code
limitation unless you pay megabucks and that limitation also doesn't
appear in the source that they released.

Am I looking at this wrong? I thought the GPL says that you have to
release all of the source code you used to build your shipping
compiler? Can someone enlighten me?

Eric
On 18 Mrz., 16:03, Eric <englere_...@yahoo.com> wrote:
> I've been looking at the PIC24 and PIC32 compilers from Microchip > lately. These are based on the gnu toolchain. > > Their PIC24 compiler works for a month in a full-featured manner, and > after that it goes down to a "student edition" that has most > optimizations disabled. Once you pay megabucks you get them back. I > initially thought this wasn't a violation because I assumed they wrote > their own closed source optimizer. However, this appears not to be the > case, and the source code they released for their C30 compiler doesn't > have any reference to any kind of limitiations. So the executable they > released was clearly not built from the source code they released. > > Even worse, their PIC32 compiler, called C32, has a 64K code > limitation unless you pay megabucks and that limitation also doesn't > appear in the source that they released. > > Am I looking at this wrong? I thought the GPL says that you have to > release all of the source code you used to build your shipping > compiler? Can someone enlighten me? > > Eric
well, deriving code from GPL GCC (MIPS compiler?) renaming mips-gcc to pic32-gcc and selling for 1200$ sounds like Microchip lawers either HAVE not done their homework, or that they have dont it extremly well. So or so, its really shame, that Microchip tries to sell MIPS GCC for 1200 usd well, there NO PIC32 silicon yet available, only starterkits. Antti
Antti <Antti.Lukats@googlemail.com> writes:

> On 18 Mrz., 16:03, Eric <englere_...@yahoo.com> wrote: >> I've been looking at the PIC24 and PIC32 compilers from Microchip >> lately. These are based on the gnu toolchain. >> >> Their PIC24 compiler works for a month in a full-featured manner, and >> after that it goes down to a "student edition" that has most >> optimizations disabled. Once you pay megabucks you get them back. I >> initially thought this wasn't a violation because I assumed they wrote >> their own closed source optimizer. However, this appears not to be the >> case, and the source code they released for their C30 compiler doesn't >> have any reference to any kind of limitiations. So the executable they >> released was clearly not built from the source code they released. >> >> Even worse, their PIC32 compiler, called C32, has a 64K code >> limitation unless you pay megabucks and that limitation also doesn't >> appear in the source that they released. >> >> Am I looking at this wrong? I thought the GPL says that you have to >> release all of the source code you used to build your shipping >> compiler? Can someone enlighten me? >> >> Eric > > well, deriving code from GPL GCC (MIPS compiler?) renaming mips-gcc to > pic32-gcc and selling for 1200$ sounds like Microchip lawers either > HAVE not done their homework, or that they have dont it extremly well. > > So or so, its really shame, that Microchip tries to sell MIPS GCC for > 1200 usd > > well, there NO PIC32 silicon yet available, only starterkits.
Why would a *device manufacturer* do this anyway? Idiots. -- John Devereux
Eric wrote:
> I've been looking at the PIC24 and PIC32 compilers from Microchip > lately. These are based on the gnu toolchain. > > Their PIC24 compiler works for a month in a full-featured manner, and > after that it goes down to a "student edition" that has most > optimizations disabled. Once you pay megabucks you get them back. I > initially thought this wasn't a violation because I assumed they wrote > their own closed source optimizer. However, this appears not to be the > case, and the source code they released for their C30 compiler doesn't > have any reference to any kind of limitiations. So the executable they > released was clearly not built from the source code they released. > > Even worse, their PIC32 compiler, called C32, has a 64K code > limitation unless you pay megabucks and that limitation also doesn't > appear in the source that they released. > > Am I looking at this wrong? I thought the GPL says that you have to > release all of the source code you used to build your shipping > compiler? Can someone enlighten me? >
Yes, the GPL requires them to release the source code for the binaries they ship - but only to those to whom they have given the binaries, and then only if they ask for them. So they are (AFAIK - IANAL) allowed to offer for downloaded a crippled binary version, and an uncrippled source version which does not match the binary version. But if you download the crippled binary, you can ask them for the crippled sources (and they must inform you of that right, and make it clear that the versions are different). If the uncrippled sources are easily available, then it's quite likely no one has bothered asking specifically for the crippled sources. If, on the other hand, the downloadable sources are not full-featured (for example, they are missing the optimisations), then Microchip are on shaky ground. Anyone may buy the full version, insist on getting the source, and then publicly release the source - any attempt to restrict that would be a violation of the GPL. It is close to impossible to integrate closed-source optimisers with gcc - the gcc architecture is specifically monolithic to avoid it. There have, I believe, been regular suggestions from gcc developers wanting to make the compiler more modular (such as actively separating the front and back end binaries) and to support plugins (it would make testing much easier). These ideas have been rejected because the FSF wants to make it hard (technically and legally) to mix closed-source code within the gcc compiler. So any optimisers that Microchip have written for their ports of gcc will also be under the GPL. Wherever they stand with regard to the letter of the law on the GPL, these time- and space-limited binaries are certainly not within the spirit of the GPL. It's okay to add non-GPL'ed tools along with the GPL'ed tools (such as simulators, IDEs, hardware debugger interfaces, etc.), of course.
On Mar 18, 11:45=A0am, John Devereux <jdREM...@THISdevereux.me.uk>
wrote:

> Why would a *device manufacturer* do this anyway? Idiots.
Hmmm. $1200 or market share. $1200 or market share. Which to choose?!
On Mar 18, 9:01 am, Mike Silva <snarflem...@yahoo.com> wrote:
> On Mar 18, 11:45 am, John Devereux <jdREM...@THISdevereux.me.uk> > wrote: > > > Why would a *device manufacturer* do this anyway? Idiots. > > Hmmm. $1200 or market share. $1200 or market share. Which to > choose?!
Which is yet another one of the reasons that I use AVR's instead. G.
On Mar 18, 12:26 pm, David Brown <da...@westcontrol.removethisbit.com>
wrote:

> Yes, the GPL requires them to release the source code for the binaries > they ship - but only to those to whom they have given the binaries, and > then only if they ask for them.
Not exactly. Choice (a) is ship the source with the binaries, effectively to customers only. If that is not taken, choice (b) requires offering it to any third party at copying cost. Choice (c) inheritance is not available for commercial distribution, but choice (b) probably includes third parties in order to support inheritance for choice (c) non-commercial redistribution.
On Mar 18, 12:18=A0pm, ghel...@lycos.com wrote:
> On Mar 18, 9:01 am, Mike Silva <snarflem...@yahoo.com> wrote: > > > On Mar 18, 11:45 am, John Devereux <jdREM...@THISdevereux.me.uk> > > wrote: > > > > Why would a *device manufacturer* do this anyway? Idiots. > > > Hmmm. =A0$1200 or market share. =A0$1200 or market share. =A0Which to > > choose?! > > Which is yet another one of the reasons that I use AVR's instead.
I would think MIPS would be rather annoyed about this, assuming they make money on devices sold, not compilers sold.
Eric <englere_geo@yahoo.com> writes:
> However, this appears not to be the case, and the source code they > released for their C30 compiler doesn't have any reference to any > kind of limitiations. So the executable they released was clearly > not built from the source code they released.
Having looked at their PIC24 gcc source code, the key is that they call out to a license manager executable which determines the license. If the LM says so, the code in gcc simply shuts off various -O and -f options. Rebuilding with that code disabled (the sources disable it by default, but it's just a -D to turn it on) gives you a fully functional compiler. This is fine with the GPL. Since the compilers are distributed over the web, and the sources are also, the GPL is satisfied via clause 3a. The LM bits and the license key are not covered by the GPL, so they need not worry about how they ship those to customers. As for charging a fee, the GPL ALLOWS this. The GNU philosophy encourages you to charge what the market will bear, providing you offer sources with whatever binaries you distribute. Microchip's license for their runtime explicitly precludes non-microchip compilers, but I can't say if rebuilding their compiler from their sources results in a not-their-compiler, from a legal point of view. I think this is something that GPL3 addresses, in that the user must be able to rebuild and *use* the binary, not just be able to rebuild it.
cs_posting@hotmail.com wrote:
> On Mar 18, 12:26 pm, David Brown <da...@westcontrol.removethisbit.com> > wrote: > >> Yes, the GPL requires them to release the source code for the binaries >> they ship - but only to those to whom they have given the binaries, and >> then only if they ask for them. > > Not exactly. Choice (a) is ship the source with the binaries, > effectively to customers only. If that is not taken, choice (b) > requires offering it to any third party at copying cost. Choice (c) > inheritance is not available for commercial distribution, but choice > (b) probably includes third parties in order to support inheritance > for choice (c) non-commercial redistribution.
I'm not sure I follow what you wrote - there are no requirements involving third parties. The GPL (in this case) only affects Microchip, and anyone to whom Microchip distributes the software. As you say, Microchip must either give them the source with the binaries, or a written offer of availability of the source for no more than a reasonable handling fee. But third parties have no writes to the code - I cannot insist that Microchip gives me source for their compiler, unless they have sold it to me, or let me download it.

The 2024 Embedded Online Conference