News for hackers. Stuff that matters.
Re:Defending GCC considered futile by zanny on Tuesday February 10, 2015 @09:59AM (#9027445)
So this was a discussion in /r/linux last week about LLVM and GCC et al, so I'm just reposting my statements on why a world where GCC is irrelevant is bad:

It takes little effort on Apples or Googles or Microsofts part to take advantage of an LLVM dominated world to close off their own changes to it and try to force developers to use their own proprietary LLVM distributions on their own operating systems. It stops every other company in the future from taking advantage of all the great LLVM tech to implement their own CPUs in terms of LLVM IR, so they never need to publish their ISA and they can lock down their platform with a blob LLVM of their own. The only thing stopping any of that from happening is GCC being a still competitive alternative.

If LLVM came to dominate the compiler scene to such a degree that GCC were irrelevant, it opens the flood gates to any major company forking LLVM into a proprietary paid for compiler that they require on their OS to profit from. It lets you do anything from what Apple is already doing with Swift, where you create a programming language with a proprietary compiler, or you could go from the other end and implement a proprietary translation unit so that you never need to publish your ISA (something Nvidia never does) but that allows all the LLVM compilers to target it.

Right now, nobody can close off their LLVM contributions because a hobbled and fractured LLVM ecosystem is one that cannot overcome GCC. In the same way Apple and Google had to cooperate on webkit until it was so dominate they were in a position to fork and do their own things with it once Gecko was rendered effectively irrelevant, but the difference is that webkit was LGPL and Clang is its own permissive license - they still cannot directly modify the free software parts without redistribution, so it is harder to make a proprietary webkit, but Apple surely has succeeded since they have their own proprietary patchset on top of trunk webkit nowadays.

Re:Defending GCC considered futile by maxlybbert on Tuesday February 10, 2015 @11:35AM (#9028188)
This is a common belief. It is, I believe, the reason Stallman wrote the GPL and the reason Torvalds continues to use the GPL 2.

But Eric Raymond convinced me that it's irrelevant ( http://esr.ibiblio.org/?p=928 ):

"If we live in 'Type A' a universe where closed source is more efficient, markets will eventually punish people who take closed source code open. Markets will correspondingly reward people who take open source closed. In this kind of universe, open source is doomed; the GPL will be subverted or routed around by efficiency-seeking investors as surely as water flows downhill.

"If we live in a 'Type B' universe where open source is more efficient, markets will eventually punish people who take open source code closed. Markets will correspondingly reward people who take closed source open. In such a universe closed source is its own punishment; open source will capture ever-larger swathes of industry as investors chase efficiency gains.

"In a Type A universe, reciprocal licensing is futile. In a Type B universe, reciprocal licensing is unnecessary. In neither universe can the GPL’s attempts to punish what we regard as misbehavior have more than short-term, temporary effects."

Re:Defending GCC considered futile by JoshTriplett on Tuesday February 10, 2015 @12:13PM (#9028434)
That assumes a company writing its own closed-source software is capable of keeping up with an entire community. If that were the case, we'd have had a proprietary version of the Linux kernel long ago, and it'd have completely replaced Linux in all the areas where Linux currently thrives.

Also, assuming the case that Open Source is more efficient, some of us don't want to wait around for inefficient closed-source-based companies to fold, because they can use the large savings they're sitting on to take a very long time thrashing around and doing damage before dying or adapting. If copyleft licenses can speed that process up, great.

Finally, there's a false dichotomy here: closed-source and open-source are not on a single scale of goodness measured by "efficiency", and the market does not perfectly adjust to maximize efficiency.

ESR's type-A and type-B universes both presuppose free markets and perfect market efficiency. There's a difference between wanting that and assuming that it's already the case.

Re:Defending GCC considered futile by maxlybbert on Tuesday February 10, 2015 @12:51PM (#9028673)
> That assumes a company writing its own closed-source software is capable of keeping up with an entire community. If that were the case, we'd have had a proprietary version of the Linux kernel long ago, and it'd have completely replaced Linux in all the areas where Linux currently thrives.

Uh, yes, that's one of the reasons the license itself doesn't make much of a difference. If you want to fork the Linux kernel and not give back -- and companies do that in our world -- you'll quickly learn that the license is the least of your problems with regard to staying up to date.

> Also, assuming the case that Open Source is more efficient, some of us don't want to wait around for inefficient closed-source-based companies to fold, because they can use the large savings they're sitting on to take a very long time thrashing around and doing damage before dying or adapting.

That's a valid point. Then again, reciprocal licenses are based on the assumption that, fundamentally, they'll get faster results with legal action (or threatened legal action) than the results you can expect from the the added costs of running a fork of an open source project. When your first cease and desist letter works, that's true. Then again, the IBM vs. SCO fiasco showed how long it can take to get vindication from the courts.

> ESR's type-A and type-B universes both presuppose free markets and perfect market efficiency. There's a difference between wanting that and assuming that it's already the case.

You don't have to have perfect market efficiency. Thinking about how things would work in a perfect world is often useful for understanding the imperfect world we actually do live in. The world we live in does involve a very impersonal market that will relentlessly tell you when you're in the wrong business, or trying to do something in a silly way. People have an ability to ignore the market's message, but it certainly exists.

Re:Defending GCC considered futile by Demiurge on Tuesday February 10, 2015 @12:09PM (#9028409)
What if we live in a universe that is of Type C, in which the market favors complicated combination of factors of which 'open source' is a very minor one, and market positioning with technical prowess of software is the major one, whereby software is opened or closed based on specific political circumstances, such that the timing and not the direction is important?
Re:Defending GCC considered futile by maxlybbert on Tuesday February 10, 2015 @12:45PM (#9028641)
I'm sure you're capable of doing that analysis yourself, but in my opinion, the GPL wouldn't provide any more benefits to a Type C universe than it provides in a Type A or Type B universe.
Re:Defending GCC considered futile by eli_gottlieb on Wednesday February 11, 2015 @05:59AM (#9032261)
Instead, we live in a Type C universe, where the Efficient Market Hypothesis is untrue and real people regularly behave more in accordance with personal beliefs and ideologies than in accordance with the imperative to increase wealth by all means possible.
Re:Defending GCC considered futile by maxlybbert on Thursday February 12, 2015 @01:04AM (#9037650)
Although he didn't say so, Raymond's thought analysis is based on the development of software in a commercial or professional setting. The decision of whether to release personal projects as open source is a different discussion altogether.
Re:Defending GCC considered futile by maxlybbert on Thursday February 12, 2015 @12:45PM (#9040077)
Oops: "thought experiment" or "analysis" not a silly mash of the two.
Re:Defending GCC considered futile by zanny on Tuesday February 10, 2015 @01:36PM (#9028967)
I disagree with both premises, because software is not a free market. It exists in the framing context of IP and copyright, unnatural societal constructs with varying reasons for existing. But they do exist.

It is not a universal truth whether or not proprietary or free software makes sense. In a world without copyright, the mechanisms of software profiteering and the utility of open or closed source radically change, since anything and everything is effectively permissively licensed.

On one side, it would take the profit motive out of proprietary software. Without copyright you can not prosecute users who redistribute your binaries, and thus it is "hard" to get people to buy them from you. I would not say impossible because I would not fathom considering all the possibilities in such a foreign context. But in the general case, without copyright, it becomes impossible to profiteer off false scarcity of information in the form of copies of software.

I say that because its important to contextualize why people strive to close off and lock down their software by depriving users of software freedoms - because copyright control, control of distribution, and the right to a monopoly over the idea means profit. If you take that away suddenly there is little incentive not to develop the software you want communally with others who want the same software, because your options are either do all the work yourself closed and have everyone else use it anyway, or open it up and have others contribute and lessen your burden. The mechanism though does not change - if you are distributing your software, which is the only way the GPL even takes effect to compel source release, in a copyright free world it makes more sense to at least release the source as an act of security. Because you cannot even sell visibility - ie, if someone wants to derive from you, you cannot extort them to see the source because if you do take money from them to see it once, you cannot legally compel them not to then release it once you have willfully given them a copy.

In that political paradigm - not a universe, not a fundamental rule of reality - software freedom just makes sense almost all the time. And the edge cases where it does not are much easier to overcome, because today free software is an uphill battle against corporate interests who use their power over software to extort their users of revenue to then fund the enhancement of their product. It is why photoshop and office are so hard to contend with, because they get so much money by using this framework of information monopolies to entrench themselves perpetually.

There are a lot of ways to frame a society that could in theory bias it towards free or proprietary software. which is in part why I don't always agree with RMS - I love the GPL and what it means in our political environment today, but I also claim it is a highly flawed economic model due to the existence of state sponsored IP in the first place. But there are many other ways to do things, and in any of those permutations free software may or may not be economically optimal, and that means it is absolutely simplifying things to claim "universes where free software make sense" exist. That is literally not seeing outside the box at all.

Re:Defending GCC considered futile by maxlybbert on Tuesday February 10, 2015 @10:45PM (#9031466)
I'll concede that a universe could exist where software isn't covered by copyright or any similar law. I don't see how the GPL would be any more useful in that universe than in the two that Raymond considered.
Re:Defending GCC considered futile by josephg on Tuesday February 10, 2015 @10:27AM (#9027647)
I'm always confused by this stance. It presupposes that big companies like Apple and Google will at some point become bad actors in the opensource world. (They both contribute huge amounts of code). Even Microsoft is starting to open up their codebase with the release of huge parts of the .NET ecosystem.

Frankly, I want the big boys on my side when it comes to opensource code. I want them to use the code I write. Usually I indirectly benefit from them using my code anyway, and they benefit, and everyone's happy. This is true even if they decide to make proprietary changes which don't get pushed upstream. I gain influence in my community and lucrative job offers. I get invited to talk at tech conferences, and my projects (present and future) attract more attention. I honestly don't see the downside here.

Apple might have a change of leadership and decide to swim against the current and make LLVM proprietary, but if that happens can't we just fork it? As far as I can see, MariaDB is doing just fine. And until that happens (which will probably be never), we can get some huge compiler ecosystem improvements on Apple's dime. All opensource.

Am I missing something, or is this fear of corporations totally unjustified?

Re:Defending GCC considered futile by vetinari on Tuesday February 10, 2015 @10:41AM (#9027758)
That pressupossition is not that unrealistic.

For example, see shader compilers for GPUs. How many open shader compilers do you see around? Is there any motivation to open them?

On the other side, during the 90's, we have seen many vendors come with new CPU ISAs, extensions of existing ISAs, new SOCs, etc. Many of them didn't have resources or will to write a new C compiler, so they wanted to use someting existing. They were willing to write new GCC backend - and GCC license basically forced them to be open. After this, there was no point in keeping ISA specification secret.

LLVM/clang does not have this effect. It pretty much rewards for being closed. So today, we have shitty (especially on ARM-SoCs) shader compilers for secret ISAs, and you aren't going to see their sources anytime soon.

Re:Defending GCC considered futile by j_s on Tuesday February 10, 2015 @11:04AM (#9027985)
I am not very familiar with the world of shader compilers, but it seems like you have provided the most concrete example I've heard yet of how GCC benefited in the long term in a way that LLVM/clang didn't.

I would love to hear from anyone with more expertise in this realm who might be able to dispute this claim in any way... otherwise this seems to be a smoking gun in GCC's favor!

Re:Defending GCC considered futile by pgeorgi on Tuesday February 10, 2015 @12:18PM (#9028474)
There are some llvm based shader compilers out there. Some even open (AMD), some not (Nvidia).

The situation with architectures in 90s sounds about right: Those that were kept closed (and where a gcc backend was thus no option for the vendor - mostly embedded stuff) have to this day shitty compilers with unpredictable optimizers.

Re:Defending GCC considered futile by GalacticDomin8r on Tuesday February 10, 2015 @12:22PM (#9028500)
I'm not sure about the exact conclusion you seem to draw but it seems to be something like "GPL projects tend to have better outcomes than non-GPL". The whole point of the thread doesn't support that conclusion coming directly from the GCC brain trust. It's only natural that niche GCC users are going to hang around the longest.

I'd also like to note LLVM/clang didn't gain large non-apple marketshare until GCC adopted GPLv3 which has more to with it's stagnation than anything IMO. v2 is palatable to many business needs, v3 is not.

Re:Defending GCC considered futile by j_s on Tuesday February 10, 2015 @04:11PM (#9029924)
Mostly I was looking for a specific/practical current example where using LLVM allowed a company to release something closed-source, where they would have been forced to open it if they used GCC.

The rubber apparently meets the road with the NVidia shader compiler.

Re:Defending GCC considered futile by eropple on Tuesday February 10, 2015 @02:47PM (#9029412)
> LLVM/clang does not have this effect. It pretty much rewards for being closed.

Only if you can convince people to use your architecture. The tools being closed is a minus in that, and must be taken into account with a lot of other stuff. A closed dev environment may well drown a brand-new ecosystem that you're trying to bootstrap.

Sony recently contributed back a ton of LLVM and clang stuff from their PS4 project, by the way. Why would they do that if keeping it closed was so rewarding?

Re:Defending GCC considered futile by Joky on Tuesday February 10, 2015 @12:36PM (#9028588)
Imagination just released their IR. LLVM has a backend for AMD GPUs. It's moving, slowly but it's moving...
Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @10:42AM (#9027759)
Microsoft is opening their codebase because they've been crushed by the enormous efforts of open source. This concession was hard won over the course of decades.

Apple and Google do not contribute code freely, nor do they contribute a significant amount of their code. The contributions are limited to areas in which an advantage exists. One only has to look at the machinations present in other development platforms to realize the threat. Consider what's happened with Java in recent years. Or look to Swift. Or to the entire Microsoft ecosystem which was built in part on a foundation of open source. BSD licensed code permeates the Windows environment; to ask "what's the concern" belies a rather stunning ignorance of Microsoft's behavior over the three prior decades.

Re:Defending GCC considered futile by hga on Tuesday February 10, 2015 @10:47AM (#9027809)
"because they've been crushed by the enormous efforts of open source"

As opposed to their own ineptitude (e.g. Vista and Windows 8) or the changing of the guard from original founders?

I'm certain open source played a role, but I suspect a secondary one. Heck, if post XP Windows didn't suck so much, I and my parents (who nowadays run what I build them) would be using it instead of Linux for our desktops.

Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @11:04AM (#9027982)
Vista and Windows 8 aren't the problem. Lack of presence on servers and mobile devices is the problem -- those are the two key spaces where OSS platforms have won out.

Linux is still not a significant player on desktops. Microsoft is still completely dominating that space.

Re:Defending GCC considered futile by zanny on Tuesday February 10, 2015 @01:42PM (#9029006)
Nobody in a ten mile radius of me gives a crap about what is running on servers or phones. Most of them do not recognize an Android smartphone as a legitimate computer. They do not know what a CPU is, they do not know what a hard drive is, and they think their monitor on the desk is the computer and the tower in the closet is the "CPU".

Windows has the mindshare of the masses. When many upper-middle class white Americans want to write a document, they can only fathom word. When they want to do a spreadsheet, they can only fathom Excel. When they want to draw, they can only fathom Photoshop.

It isn't about options or features or anything, I'm talking about the super majority of people who cannot any longer comprehend the existence of anything but what they know - where being presented with Linux destroys their world view. They talk about OSX like its an easy bake oven rather than another computer, or as if its another desktop UI for Windows that also runs Office.

Which is why Microsofts open source efforts are pretty much all on the developer end. They know their userbase is completely ignorant to everything just the way they intended, and it would take years of retraining to push the public conscience away from the mindset that Microsoft Windows is the personal computer, and everything else is some gadget.

Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @03:05PM (#9029533)
Microsoft's board cares, which is why there was a change in leadership. That's the subject hga raised and is what my reply is in reference to.
Re:Defending GCC considered futile by hga on Tuesday February 10, 2015 @11:12AM (#9028040)
Mobile devices I firmly ascribe to ineptitude, and can supply some 2nd and 3rd hand details I've read about.

Servers are more complicated. In the mid-90s Windows NT started dropping in quality, and the much older decision to have mandatory file locking resulted in situations where creating a server with a major MS server application could require ~ 20 reboots. And many more bug and security fixes require reboots than they do on UNIX(TM) based/inspired platforms.

Then one could argue ineptitude in marketing when Microsoft didn't cut deals that could have made their software competitive for mass installations. I really wonder about that, because so many of these need source, but it's "a path not traveled", except internally with Azure.

Re:Defending GCC considered futile by DannyBee on Tuesday February 10, 2015 @11:14AM (#9028046)
"Apple and Google do not contribute code freely, nor do they contribute a significant amount of their code. The contributions are limited to areas in which an advantage exists."

This is simply false, actually. But of course, you have no evidence of this, only rhetoric, while i actually see literally every code contribution google makes.

Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @12:19PM (#9028484)
By all means contradict me. Do they open source more than 25% of their code written?

More than 10%?

More than 1%?

Re:Defending GCC considered futile by Anderkent on Tuesday February 10, 2015 @12:36PM (#9028587)
That's not what you claimed. You claimed they do not contribute code freely; they certainly do. It might not be a very significant percentage if their code written, but it's a fact that they contribute code to open source projects, and they do not charge for it.
Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @01:00PM (#9028723)
I see the misunderstanding. When I say "contribute code freely" I mean "without restriction."

You are certainly aware that the vast majority of code is under strict restrictions and will be leveraged for competitive/controlling purposes rather than being shared. Employees wishing to freely contribute code in these domains will have their requests denied.

We've both been employed by large SV companies; we both know how this works. The majority of software will be used in an attempt to control the market.

Re:Defending GCC considered futile by DannyBee on Tuesday February 10, 2015 @03:40PM (#9029753)
"You are certainly aware that the vast majority of code is under strict restrictions and will be leveraged for competitive/controlling purposes rather than being shared. Employees wishing to freely contribute code in these domains will have their requests denied. "

?????? None of this is true. I mean, literally none of this. I don't even know where to begin.

Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @04:11PM (#9029922)
This isn't a complicated statement. Why are you struggling with it?

Google does not open source the VAST majority of their code -- it remains tightly restricted. Surely agree this is an accurate statement?

Re:Defending GCC considered futile by DannyBee on Wednesday February 11, 2015 @01:24PM (#9034515)
Because it's an incredibly vague statement that is open to many interpretations?

As written, actually, i don't agree with it.

Google has open sourced > 100 million lines of source code, depending on how you count.

I can't tell you what percent this is, but it is quite significant

It is the vast majority of a number of products, and not the vast majority of a number of other products.

In fact, for some subsidiaries, all of the code is open source. For some, it isn't.

So your statement depends on a lot - who are you counting, what is "their code" (Code we've written, code we've modified, or code we use), etc

If you make a detailed enough statement, i'd probably agree. But as written, there are plenty of cases where google open sources the vast majority of it's code.

Re:Defending GCC considered futile by throwaway90999 on Wednesday February 11, 2015 @11:57PM (#9037468)
If you insist on continuing to be disingenuous we can simply end the conversation.
Re:Defending GCC considered futile by twic on Tuesday February 10, 2015 @04:01PM (#9029864)
> Consider what's happened with Java in recent years.

What has happened with Java in recent years?

One thing i can think of is that the 'official' Sun/Oracle JDK has gone from being closed source, to having a second-class GPL'd derivative, to being built on a GPL'd core. The amount of proprietary closed-source code has gone from 4% to 1% to nothing that doesn't have a free replacement today.

Re:Defending GCC considered futile by throwaway90999 on Tuesday February 10, 2015 @04:09PM (#9029916)
> What has happened with Java in recent years?

Your feigned ignorance is disingenuous. An enormous legal battle over the platform took place within the past decade.

We are very lucky that the outcome was favorable and that the platform has been able to continue to improve.

Re:Defending GCC considered futile by fungos on Tuesday February 10, 2015 @12:54PM (#9028688)
Narrow and egocentric view of the situation. This is not about developer (your) freedom (to use, to change, to gain over) but is about user freedom. Do a little research about RMS's history and what he defends instead of just reading some (context) limited mailing postings to have your conclusions.
Re:Defending GCC considered futile by davidw on Tuesday February 10, 2015 @10:37AM (#9027725)
> Am I missing something, or is this fear of corporations totally unjustified?

Sun Microsystems basically grabbed BSD development by hiring up a lot of good people and running with it. It took a while for the various free BSD's to come into their own.

Basically, with "bsd licensed" software, if a big company hired up all the developers, they could take it proprietary and out-compete fork efforts.

I don't think it happens often, but it's not impossible, either.

Re:Defending GCC considered futile by hga on Tuesday February 10, 2015 @10:43AM (#9027773)
Really???

The AT&T lawsuit and the end of DARPA BSD funding and that research group at UCB didn't have a lot to do with that? That was several years after Sun got in bed with AT&T and announced that BSD based SunOS was doomed.

I don't know, but I wonder.

Re:Defending GCC considered futile by davidw on Tuesday February 10, 2015 @10:49AM (#9027827)
There are lots of factors, and you can't exactly rerun the experiment a number of times, tweaking all of them.

There's also the fact that the internet was far less available in that day and age, making it more difficult to get good people involved.

I don't think it's a big risk, but like I said, I don't think it's impossible either.

Re:Defending GCC considered futile by dragonwriter on Tuesday February 10, 2015 @10:59AM (#9027935)
> Basically, with "bsd licensed" software, if a big company hired up all the developers, they could take it proprietary and out-compete fork efforts.

Well, look, sure, if you hire all the developers that are working on something and understand it, you can probably out-compete other implementations even if all you have the old developers do on your proprietary project is write up specs from which a different set of developers build a legally non-derivative interoperable implementation.

That may be a risk with permissively-licensed Free software, but its also a risk with copyleft Free software and proprietary software.

Re:Defending GCC considered futile by davidw on Tuesday February 10, 2015 @11:05AM (#9027990)
My experience is that specs - even will written ones - are far enough from working, tested code that it's going to be significantly easier to take the BSD project proprietary than to build a competitor to a GPL licensed one from scratch. Also, to be attractive to the 'core group', I think working on new stuff is more interesting.
Re:Defending GCC considered futile by CamperBob2 on Tuesday February 10, 2015 @01:25PM (#9028882)
I'm always confused by this stance. It presupposes that big companies like Apple and Google will at some point become bad actors in the opensource world

To resolve your confusion in this area, perhaps you should consult an Oracle.

Re:Defending GCC considered futile by riffraff on Tuesday February 10, 2015 @02:23PM (#9029286)
aren't we in that world already? I.e. the swift compiler uses llvm but is not open source, the obj-c compiler used gcc and it was.
Re:Defending GCC considered futile by marcosdumay on Tuesday February 10, 2015 @10:47AM (#9027804)
I understand this position, and yes, it looks like the natural outcome in a simple game-like modeling.

Yet, PostgreSQL survives, and is doing well. Ditto for Apache. That is enough evidence that there's something wrong with the usual modeling... Ok, maybe not enough evidence for you to feel secure on the viability of big non copyleft licensed software, but you should at least take it into account.

Re:Defending GCC considered futile by pjmlp on Tuesday February 10, 2015 @10:12AM (#9027534)
Well, you just have to look at Swift or some GPGPU drivers using LLVM.
Re:Defending GCC considered futile by davidw on Tuesday February 10, 2015 @10:19AM (#9027592)
Probably the best way to avoid this is to make sure all the eggs (developers) never end up in any one basket. Apple is a big risk there.
Re:Defending GCC considered futile by gcp on Tuesday February 10, 2015 @10:06AM (#9027493)
One of the big advantages of LLVM's license in this regard is that, unlike GCC, you don't risk leaking patents either even if you did open source it. Or did they fix that now?
Re:Defending GCC considered futile by DannyBee on Tuesday February 10, 2015 @11:14AM (#9028062)
LLVM's developer policy has required free patent grants for many years, and a number of companies have done so.

(a different number simply don't patent stuff they contribute to LLVM)