FreeBSD Throws the Clang/LLVM Switch: Future Releases Use LLVM 360
An anonymous reader writes "Brooks Davis has announced that the FreeBSD Project has now officially switched to Clang/LLVM as C/C++ compiler. This follows several years of preparation, feeding back improvements to the Clang and LLVM source code bases, and nightly builds of FreeBSD using LLVM over two years. Future snapshots and all major FreeBSD releases will ship compiled with LLVM by default!"
Grin (Score:3, Funny)
I'm just so HAPPY!
Re: (Score:2)
For us non-BSD muggles, please explain why.
Re:Grin (Score:5, Informative)
This explains it well: http://unix.stackexchange.com/a/49970/7345
Re:Grin (Score:4, Informative)
Here are some very interesting, compelling reasons to switch to Clang:
http://channel9.msdn.com/Events/GoingNative/GoingNative-2012/Clang-Defending-C-from-Murphy-s-Million-Monkeys [msdn.com]
Re:Grin (Score:5, Informative)
Generally a lot of BSD users don't like the GPL, and getting rid of a GPLed compiler makes them quite happy.
Also, although I've heard a lot about the inner workings of GCC being rather intertwined and convoluted, whereas LLVM is simpler to work with and modify (not sure how true this is).
Re:Grin (Score:5, Interesting)
It isn't necessarily an issue with the GPL (aside from 3 being invasive, which I personally have an issue with and so do the lawyers I work with) - I have a problem with Stallman's (aka RMS) model, which says charge for hardware and give the software with source away for free.
I worked for a CAD software company (we were bought by a huge multinational conglomerate, so I technically still work for them, but I moved around and rarely touch CAD these days). In our former incarnation, we sold exactly no hardware and were bundled with exactly zero hardware, but ran on pretty much every platform imaginable (9 at one point, but much fewer now, since our customers are mostly moving to Linux or Windows). Giving away our software (not to mention the source code) would be a really bad business model, but to appease those in RMS's dream world, we'd need to find hardware partners and give it away for free with the hardware and be paid by the hardware vendor - but since we have to give away source, we'd more than likely use an in-house developed proprietary language to make porting as difficult as possible. This, in fact, is a BAD and not very open business model - if we'd been bought by our current owner, we'd almost certainly be proprietary software for their hardware and not run on platforms like Linux or even Windows. This happens in the console world all the time - when Microsoft bought Bungie, they basically shafted what Bungie was known for - mac games (and took a year to release Halo on Windows/Mac to keep it XBox exclusive as long as possible to the ire of Steve Jobs - later releases became XBox exclusive). If you think that is a good thing, great for you - I don't. Incidentally, the part of the company I work for has an open data model as well - that makes it easy for customers to switch, but we are doing our jobs well because few actually do.
I've been at odds with RMS over this for years...
Re:Grin (Score:4, Insightful)
With BSD software, not only are you giving away the source code, but you are giving it away with even fewer restrictions than with GPL.
What's that you say? You want to take the software that other people have released and use it in your closed source product? Well then of course you like BSD software better. But you can obviously see why many people who write the open software prefer a GPL style.
Re: (Score:3, Insightful)
But you're not forced to give all of it away, as you effectively are with the GPL.
If you've created something that you'd like to give back to the community, you can. -And it's very often in your own best interests to do so. If however, you've created something that, at least for now, you'd prefer not to give away, well you're free to do that instead.
The BSD model has proven
Re: (Score:3)
I think a lot of people miss the point. The copyright owner chooses the license. If you don't like the license, don't use it (as FreeBSD did).
Whether you are forced to share or not should be one of thing things the project/company should decide on early. If it's not important, then it doesn't matter. If it *is* important, then select the appropriate license.
It is not like you can pay Microsoft for a windows license, and then violate their license (remember hacking windows NT workstation to run IIS serve
Your anti-GPL FUD is inaccurate and unconvincing. (Score:3, Insightful)
It seems to me that the ability to "lock up" formerly free software has enabled the worst actors in the global market for computer software to accumulate wealth and power which they have then used to distort the market to the detriment of free software authors. The GPL is a response to this perception.
And frankly, while I support your freedom to release your code under any license you wish (a freedom many BSD people don't seem to like) I find these "GPL tekks away mah freederms" sound bites laughable. You
Re:Your anti-GPL FUD is inaccurate and unconvincin (Score:5, Insightful)
It seems to me that the ability to "lock up" formerly free software has enabled the worst actors in the global market for computer software to accumulate wealth and power which they have then used to distort the market to the detriment of free software authors. The GPL is a response to this perception.
The software is always free. What they do is not make their changes free, but the original is still free as ever.
An idea cannot be "stolen" or "taken away". The original will always remain.
Personally, I think most people's ability to think breaks down once "infinite" is involved. I have no qualms with GPL, but your argument is full of holes. You are as bad as the RIAA claiming others steal their work and every stolen copy is a lost sale. Please revise your argument, it makes the GPL look like a bunch of zealots use it.
Success of open source depends on... (Score:3)
Re:Grin (Score:4, Insightful)
Dummies.
Re:Grin (Score:4, Insightful)
But you're not forced to give all of it away, as you effectively are with the GPL.
Utterly false.
You can license just part of your own code as GPL and release as much or as little as you want.
You even still retain complete control of your code that you have previously released as GPL, so you can then take it and change it or use it in your closed software, or license it out for a price to someone, or release it as BSD.
Yeah, but this right is denied downstream, ironically under the very copyleft clauses that claim to preserve the 'software freedom'.
The BSD model has proven that you don't need to twist peoples arms
GPL is not twisting anybody's arm. I challenge you to find a single example of a GPL project which has engaged in predatory patent trolling, deliberate compatibility breakage to harm competition, or format or protocol obfuscation to lock in customers. Things which some closed software companies engage in regularly is completely against the nature of open source development, but also open source makes it pretty hard for any of those techniques to be effective.
Not saying it would never happen, but there is nothing about the GPL license that twists anybody's arm.
Oh, you meant "you twisted my arm" as-in, "I want to use your code that you own the rights to, but under the terms I set. Waaahhh.". In that case, fuck you, that's copyright infringement and have fun destroying people's livelihood, hypocrite.
It's not an issue of mere taking the code and changing the terms - let's say I took something that the GP had written and modified it, and then distribute the modified version, that's where the differences start. With GPL, I'm forced to release the source code of my modifications. With BSD, I don't have to - only the original BSD source code has to be given, but I still have the option of keeping the source code of my modifications to myself, even while distributing.
GPL... Among many freedoms it takes away
Stopped reading there. You're either a massive troll or a clueless friggin nincompoop.
Read the 4 freedoms on the home page of the FSF. GPL violates every one of them.
Re: (Score:3)
If I take BSD licensed code and incorporate it into my commercial product, and don't release the source, it is NOT stealing. It is totally within the requirements of the license. The BSD folk want (and this is what the GPL peeps DON'T get) ANY project to have a library of well tested, standards compliant code available for use as the project author sees fit. We DON'T want to force people to reinvent the wheel to circumvent licensing restrictions if they decide they want to build a closed source project
Re: (Score:2)
The GPL doesn't force you to give the software away. You can sell it. Indeed, RMS himself used to **sell** tapes of GPL software to fund the FSF. RedHat make *billions* on per-seat licensing of GPL software. Nor does GPL software force you, as an author, to GPL all the software. As the author you are completely free to draw the line as you wish between which bits of your software are GPL and which proprietary. You just grant yourself an exception.
What the GPL *does* do, which a BSD licence does not, is prot
Re:Grin (Score:4, Insightful)
Hu? Let say you release a part of your software under GPL and "draw a line" for the rest, I'm entitled to ask you to release the whole thing under GPL, unless you're able to prove that the part you put on the other side of the line is not a derivative work of GPL'd part.
Only if you wrote part of it. If I write a program and release half of it under the GPL, the only person who can sue me over it is me.
The GPL is only an issue if you want to steal other people's code. It doesn't force you to do anything with code you write, unless you mix it with code you didn't write and don't have a license to use (other than the GPL).
Re: (Score:3)
Hu? Let say you release a part of your software under GPL and "draw a line" for the rest, I'm entitled to ask you to release the whole thing under GPL, unless you're able to prove that the part you put on the other side of the line is not a derivative work of GPL'd part.
Only if you wrote part of it. If I write a program and release half of it under the GPL, the only person who can sue me over it is me.
The GPL is only an issue if you want to steal other people's code. It doesn't force you to do anything with code you write, unless you mix it with code you didn't write and don't have a license to use (other than the GPL).
That's a non-sequitur to what the parent had written. What he is pointing out is that if you had written a GPLed program, and he added his own part but did not want to release the source code to his modifications - under GPL, which the combined license would have to be under, he couldn't. That's not a problem in BSDL - there, since it is not a CopyLeft license, he could take that software, add his modifications and sell only the binaries. Or, if he wis
Re: (Score:3)
Yes, correct, it prevents the distribution of. Private modifications are fine either way.
Re: (Score:2)
I have a problem with Stallman's (aka RMS) model, which says charge for hardware and give the software with source away for free.
Richard Stallman's model says such thing. It says "if you want to save costs by using this source code then you must make your changes available to whoever uses it."
Re: (Score:3)
Thanks for sharing that. Perhaps it rankles that RMS has earned himself a place in the history books as a great benefactor of society, while your snarky Slashdot posts have accomplished no such thing?
Re: (Score:2)
It has little to do with "liking" or "disliking" the GPL. It has more to do with the GPL being incompatible with BSD's own license (and just about any other license). It's true there is a compile firewall with gcc, but it is still a less than ideal situation. BSD is also going to bring out a GPL-free C++11 stack.
Re:Grin (Score:5, Informative)
is there a reason for not making the front ends dynamic libraries which could be linked by any program that wants to parse source code?
Quoth the Stallman himself:
One of our main goals for GCC is to prevent any parts of it from being used together with non-free software. Thus, we have deliberately avoided many things that might possibly have the effect of facilitating such usage, even if that consequence wasn't a certainty. We're looking for new methods now to try to prevent this, and the outcome of this search would be very important in our decision of what to do.
Not only is the poor design true, it was very intentional. This is why we need the LLVM project. KDevelop and such shouldn't have to write their own compiler front ends to get feature parity with Visual Studio; but right now they do.
Re: (Score:2)
Re: (Score:3)
...prevent any parts of it from being used together with non-free software
Sounds similar to arguments against a stable driver interface for the Linux kernel.
Re: (Score:2)
Re:Grin (Score:4, Interesting)
unlike GCC, Clang/LLVM was designed to ensure the optimizations are the same each and every build. This means you can compile from source and check the md5 sum of your binary against the master md5 and know if the source has been modified before compilation. Critical for signed binaries.
Another benefit is the support for older hardware that's been dropped by the GCC team along with ease of debugging. I've had compiler optimizations introduce unexpected bugs/failure mode in the Linux kernel itself that disappeared when the No Optimization flag was set. Simply put, if the kernel isn't stable, I don't give a damn how stable the rest of your system is, it's not stable because you can't trust the kernel and that's why Clang/LLVM is all about.
Having a strong competitor to GCC (Score:5, Insightful)
will drive GCC to a far greater degree than without a competitor. This is good for all involved.
Re: (Score:2)
Re: (Score:2)
No its just good for your agenda, although the heavy involvement of Apple without the support of a tit-for-tat license is going to major offputting for many developers. The irony of FreeBSD switching to Clang/LLVM is not lost on me. Personally the thought of a two-level development of a browser quite disturbing.
The reality is GCC still moves forward, and Clang/LLVM has a long way to catch up, perhaps if develops stopped developing Clang/LLVM for that everyone would again getter a btter browser, and everyone would be on an equal playing field. ;)
but like I say I prefer a world where some do not get a better browser than others :(
Re: (Score:2)
Re: (Score:2)
How have they gotten this far? It's not like GCC is struggling to keep pace in development.
Why would a GCC developer move to LLVM? Do you believe that all of the developers on the project are so opportunistic that they would simply jump to a different compiler? I suspect
Re:Having a strong competitor to GCC (Score:5, Insightful)
Well, better for some people. I suspect that the first fallout of any industry shift to LLVM will be that the public compiler will be significantly lacking in optimizations while the expensive, proprietary versions will have all the good optimizations.
Not just that.
I remember the bad old days where every venduh and his dog had their own "extra proprietary super awseome dongle controlled extra awesome super cool" compiler.
Vendors of hardware *LOVE* proprietary compilers. And by love, I mean love to break in mysterious and subtle ways.
Once gcc took off in the embedded world, life got a lot better since many of the cheaper vendors would just use as close to stock gcc as possible (though usually with a little bit of extra internal compiler errors added), rather than some extra super proprietary extra messed up version.
This isn't a business issue. There is no sane business case for taking a commercial compiler front end and a commercial compiler back end, filling it with extra bugs and shipping it. But hardware vendors love to believe that they have an awesome proprietary advantage in software for some reason. Even though they sell hardware. They don't, of course. I'd just say "whatever" except that turns rapidly into invective if one is forced to use their "tools".
Once GCC came along, they believed that they no longer had such an advantage (presumably) so they stopped introducing their extra proprietary bugs into compilers, and limited themselves to a few extra miscellaneous bugs. But it was still mostly gcc and still mostly worked.
If LLVM comes to dominate, the hardware vendors will jump right back on that attitude and make the life of the humble developer hell again.
This isn't a religious, or philosophical issue. It's a "hardware vendors are mental" issue.
Re: (Score:3)
Re: (Score:2)
Re:Having a strong competitor to GCC (Score:4, Insightful)
That's hardly an industry shift and you know it.
So we're going to ignore all of the proprietary, seat-licensed compilers out there?
Quick! Into the name-calling and ad-hominem!
Do they? Unless you're on their compiler team you can't possibly know this.
I believe the phrase "you mad" applies very, very well to your spittle-flecked rant here.
Re: (Score:3)
Re: (Score:3)
or GCC will simply grab the better code and GPL it leaving it with another lesser competator
Re: (Score:3)
True, except the GPL claims to be even "freer" than free by the advocates who love to point how closed-source projects "steal" BSD source. The irony is that the GPL is doing the exact same thing which is legal, except the GPL forces are claiming it's superior and freer.
So you have one opensource li
LLVM stands for.... (Score:3)
Low Level Virtual Machine. However, has little to do with what it is now: http://en.wikipedia.org/wiki/LLVM [wikipedia.org]
Rename needed, certainly, it is.
Carry on.
Good job, guys! (Score:3)
I have been happily using clang++ at work for a while now and am thankful for the efforts in creating a real world-class open-source compiler suite! Glad to see FreeBSD become ever-freer!
KDE (Score:3)
Re: (Score:3)
Not GPL, and suitable for JIT (Score:5, Informative)
Re: (Score:3)
So, written a bit more flexibly, and licensed a bit more flexibly :)
Nothing wrong with having a "competitor" (it isn't, but anyway you get what I am saying) from either perspective. Gives both a reason to strive to improve.
Re: (Score:2)
Could you elaborate on the "economic reasons" certain categories cannot be released as free software?
Also, LLVM isn't actually designed for JIT: some people have managed to make it work, but not without problems. GCC isn't designed for JIT either, of course; it's outside the problem space of both.
Re: (Score:2)
At least for me "lli" works much more reliably than "lli -force-interpreter" (that disables the JIT).
Genres of non-free software (Score:3)
Could you elaborate on the "economic reasons" certain categories cannot be released as free software?
Certainly. I've started on this essay [pineight.com].
Re: (Score:2)
None of these, games, DRM crippled video players, tax software need to be proprietary. You even mention why: what would these software packages be without their WAD files, tax definition files and encryption keys.
Free software could leak cleartext or keys (Score:4, Insightful)
You even mention why: what would these software packages be without their WAD files, tax definition files and encryption keys.
A video game licensed as free software could be modified to leak the decrypted WAD files. Furthermore, console makers forbid use of a copylefted engine [slashdot.org]. This means a copylefted game can't run on consoles, which means it can't use the large monitor and multiple gamepads that the player already owns for the console but wouldn't consider buying for a PC. (There are some major genres of video games that for economic reasons cannot be released as PC exclusives; I can explain in more detail if you wish.)
A DRM crippled video player licensed as free software could be modified to leak the decryption keys, something that Disney, Fox, Paramount, Sony, Universal, and Warner Bros. forbid.
A tax program licensed as free software could be modified to leak the decrypted tax definition files.
Re: (Score:2)
Ah, but we should also point out that closed software on open hardware does little to achieve the above restrictions or protection of data. As long as the user has access to the underlaying machine they can still access the raw form of the program and the data. It's harder than having clear-text source code and unobfuscated data, sure, but it's doable.
The only environment in which closed-source code works is putting it on locked-down hardware, a "black box" of sorts with no external clue as to what's going
Re: (Score:3)
Think of it another way: If it's feasible to make money on a video game with a free engine and proprietary data, then why aren't there more popular video games built on engines that have been free from day one?
Not sure what you're asking, the first part of this question is completely disconnected from the second.
Then let me rephrase the question using grammatical parallelism [wikipedia.org] to reconnect the first part to the second: If it's feasible to derive a source of revenue from releasing a video game with a free engine and proprietary data, then why haven't companies taken advantage of this feasibility and released popular video games with a free engine and proprietary data?
And they both completely disregard what I've said above.
Which is why I introduced that question with "Think of it another way". I was trying to establish the criterion of whether or not a particular business m
"economic reasons" (Score:5, Interesting)
A lot of graphics software infringes on existing patents, but that isn't a reason you can state without risking treble damages in a lawsuit, so most of the graphics driver writers tend to just look the other way and hum as they dance past that particular graveyard. Practically, it's impossible to write genuinely competitive graphics code without infringing some East Texas idiot's patent.
There are also cases where code has specific strategic value to a company, and they want to amortize the cost of development over some period of time before they let their competitors use the code. For example, the Soft Updates code that Kirk McKusick, Julian Elisher, and I worked on for FreeBSD was licensed under a free-for-non-commercial-use license for a period of two years before we opened it up for general use. This was to allow us to recoup the investment on developing the code by allowing us to run our hardware without a UPS, while everyone else in the market had to have a UPS to deal with power failure and recovery. If you don't have it, you have to treat a power failure as a kernel panic and do a full fsck in order to return your disk to a known good state, since you can't otherwise guarantee that it wasn't a crash followed by a triple fault, which might have written bad data to some portion of the disk. So all the competing border router/SOHO server devices had to have batteries, which increased their cost relative to our product. It's one of the reasons IBM bought our company.
Yeah, it'd be great if some idiot were to spend 10 years of their free time neglecting their families so that all this stuff could be free, but no one really wants to be that idiot: people work on free software for love, and they work on the hard problems and productization in exchange for money, since no one is going to do scut work for free unless they're a masochist (if you happen to know one, though, I have a project or two they could tackle if they really wanted to suffer).
Millenium asked for economic reasons; I gave some (Score:3)
There are also economic reasons that Android replicates a lot of internal Linux APIs in order to get out from under the EXPORT_SYMBOL_GPL() so it can have faster/closed source graphics drivers.
Look, I most recently worked for Google on the ARM ChromeBook that Samsung recently announced. In the process, I did bring-up on the cellular modem and the camera, fixed the PMIC code, and did other things that ended up in the Linux Samsung 5250 board support, as well as rewrote the i8042 keyboard driver in u-boot in
Re: (Score:2)
Also, LLVM isn't actually designed for JIT: some people have managed to make it work, but not without problems. GCC isn't designed for JIT either, of course; it's outside the problem space of both.
WTF? Apple's first use of LLVM was as a JIT for OpenGL. When compiling OpenGL to code for various graphics cards became a maintenance nightmare, they used LLVM: OpenGL compiles to the internal representation of LLVM, same code for all graphics cards, and LLVM compiles to code for the graphics card, all at runtime.
Re: (Score:2)
Apple actually had to stretch some definitions on that project. The actual technique they used is more akin to what the original JVMs did: ahead-of-time compilation that happens to be just before the code is run, but ahead-of-time nonetheless. JIT implies something different, and it's not really in LLVM's problem space.
Re: (Score:2)
> There are some major categories of software that for economic reasons cannot be released as free software
Yet despite of this the world has survived for a rather long time using a Copyleft compiler without the heads of any Robber Barons exploding.
It's kind of on par with GNU finally using it's own kernel after 20 or so years instead of using the Linux kernel. It's interesting but far less significant than some might want to assert. We managed to get along quite well without it.
Re: (Score:2)
Who would put a compiler as part of their software (either FOSS or otherwise)? Unless, of course, your software is another compiler...
Five different virtual machines (Score:3)
Who would put a compiler as part of their software (either FOSS or otherwise)?
Implementations of the Java virtual machine, the Common Language Runtime (.NET virtual machine), the ActionScript engine in an SWF player, the JavaScript engine in a web browser, or a shader engine in an OpenGL implementation need to compile platform-independent bytecode into platform-specific native code.
Re:Not GPL, and suitable for JIT (Score:4, Insightful)
These are not exactly the terms of GPL and BSD but:
GPL is for people and companies that think "I wrote this software [together with X, Y and Z] and if somebody else makes it better they must share it with all the world, as I did."
BSD is for people and companies that think "I wrote this software [together with X, Y and Z] and I accept the loss that somebody else makes it better and keep it for themselves because I want to have the option of getting somebody's else software, make it better and keep it for me without sharing it back."
I think we can argue forever on the ethic merits of the two approaches (I feel in the GPL camp). Anyway both GPL and BSD make economic sense and we won't be talking about them if they didn't, one or both would be dead long time ago. If a company wants to include some big secret in its code, it must go BSD and occasionally regrets it can't use some GPL code and rant about it. Sometimes the GPL people rant about not being able to include BSD code in their projects.
Re:Not GPL, and suitable for JIT (Score:4, Insightful)
Actually it is much simpler than that;
GPL is designed to protect users' interests
BSD is designed to protect developers' interests
Re: (Score:2)
- With BSD, a good networking stack made it into (earlier versions of) Windows thereby helping user choice.
- With GPL, services companies are the norm which encourage convoluted software that's hard on users.
Re: (Score:3)
GPL -> User has access to source code so (in theory) has less risk of vendor lock-in. BSD -> Developers can create lockin
Well, it depends. Here on my FreeBSD system I have the source code to the entire operating system under /usr/src, it is included with the installer and can be installed during installation. Companies like Apple can use it to improve their products, and sometimes they contribute back even if all their products aren't open. However that doesn't make /usr/src go away.
Re: (Score:3)
While a developer can be a user, not all users are developers. Availability of the code means squat to someone who does not know how to write code.
That's ridiculous. If you have the code, you can *hire* someone to fix the thing, ten years after the original supplier went bankrupt or whatever.
I need the plans for my house, even if I'm not licensed to fix the bathroom -- I need them in case I hire someone to do improvements here.
Most every place I've been paid to work with software, the ones with budgetary responsibility have *not* been able to code themselves out of a wet paper bag. They've been readily able to get something fixed, if the source is available -- if needed by hiring someone to do it.
No, what you suggest is ridiculous. If the software is "free" to begin with, why would I want to spend a lot of money to hire something that nobody is going to bother to maintain? That would be throwing good money after bad. You are better off looking for an alternative and choosing a product in the first place that has adequate export facilities for your data should you decide to migrate to another system later.
You appear to be ignorant of how much software development costs to suggest that someone "hire
Re: (Score:2)
GPL is designed to protect users' interests
Exactly! (Freedom to tinker)
BSD is designed to protect developers' interests
This really depends on developer's interest. When releasing the software, developer has way more freedom to choose the software licence, then the user, who buys the software. Therefore, I'd argue that user's freedoms are in more need of a protection.
Re: (Score:3)
If not for the developers, what is the point of open source?
If not for the users, what is the point of software? If you insist on treating users as if they were developers then you will quickly lose them and destroy the relevance of your software. Software without users is nothing.
Can modify GPL'd code, make money and *not* share (Score:5, Insightful)
GPL is for people and companies that think "I wrote this software [together with X, Y and Z] and if somebody else makes it better they must share it with all the world, as I did."
That is quite misinformed. Organizations can modify and use GPL'd code internally, make a lot of money off of it, and not share with anyone. I believe Google does so.
BSD is for people and companies that think "I wrote this software [together with X, Y and Z] and I accept the loss that somebody else makes it better and keep it for themselves because I want to have the option of getting somebody's else software, make it better and keep it for me without sharing it back."
Beyond misinformed, merely a spouting of FSF spin.
In truth the BSD folks want the widest possible distribution of their software because they believe that will ultimately provide the computing world the greatest benefit. BSD Unix arguably did provide quite a benefit to both hobbyists and corporations.
Perhaps more importantly is that BSD Unix was a product of the University of California, a taxpayer funded entity, and they felt that all taxpayers should have equal access to their work. That the politics of picking good users and bad, approved uses of the software and unapproved, etc was wrong.
Re: (Score:3)
Darwin can be left open because there is so much closed source stuff atop it before one can use darwin to make a competitor to OSX.
That seems to be a strawman. The stuff on top of Darwin is neither BSD nor GPL, its not relevant. The fact remains that modified BSD code used by Apple is given back. Other corporations do so as well.
I still think that those selling services based on improved OSS are not following the spirit of the earlier GPL, so again not a good point.
The spirit of BSD is also to give back and share, and various corporations do follow this spirit without any arm twisting.
Re: (Score:3)
Actually I think you can't have both kinds of freedom at the same time: the freedom to do whatever you want with the code (and its license) allows you to limit the freedom of your users to do the same. This can be considered a minor problem (as BSD does) or a major one (as GPL does).
Re:Not GPL, and suitable for JIT (Score:5, Informative)
For example, we wouldn't have an Objective C compiler if NeXT hadn't been forced to release it in order to comply with the GPL.
Speaking as the person who wrote and maintains the GNUstep libobjc and the clang support for it: Bullshit. The GPL forced NeXT to open source half of the implementation (the compiler support, not the runtime), and their implementation was such a pile of crap that it set back GCC's support for a long time. Open source support for Objective-C in clang is so much better than in GCC that it's not even worth comparing the two.
Re:What's the clear advantage of LLVM? (Score:5, Informative)
The reason FreeBSD switches to clang/LLVM is the license: BSD instead of GPLv3.
You should give clang a try. The LLVM has a much cleaner api then gcc and the error message's are also more readeable. In terms of speed, the difference is shrinking with each release.
Re: (Score:3, Informative)
Clang is in the order of 10 times faster than GCC (compilation speed) and the generated binary is 1% faster than GCC (so essentially the same but saves hours of compile-time per day on 50MB+ C-files).
Bullshit. It's compilation is at most 1/3 faster, and on most cases I checked, the result executes between 5-25% slower. The former seems to be pretty constant everywhere, the latter strongly depends on the code base in question, with huge outliers both ways.
Re: (Score:3)
on most cases I checked, the result [with Clang] executes between 5-25% slower.
I recompiled a large audio processing code base in Clang and the result was about a 2-3% speedup, with no problems. I immediately switched to using Clang for all release builds. (I still use GCC for debug builds.)
Re: (Score:3)
Another option is to switch from hard drives to SSDs since that handles the bottleneck at its source: time spent seeking to a track.
This guy clearly has no idea what he is talking about.
Re:What's the clear advantage of LLVM? (Score:5, Informative)
I know of LLVM, but haven't used it, and it really seems like very few hardcore Linux/OSS devs have a clue about it. Is there really a clear advantage, or is it just an excuse to write a new compiler to solve a problem that doesn't exist?
The actual reason, from what I remember, is licensing. They want to build a fully BSD-licensed OS from the ground up, with zero dependence on GPL-licensed stuff.
Re: (Score:3)
Not really true. Everyone was pretty comfortable living along-side GPLv2-licensed software for many, many years. But NOT the new GPLv3. Organizations all over the place are running away, screaming, from anything using that extra-restrictive and incompatible license. The FSF, developing the GPLv3 license, has done more to promote BSD/MITX licensed software than anyone else could have ever hoped to.
Som
Re:What's the clear advantage of LLVM? (Score:5, Interesting)
I know of LLVM, but haven't used it, and it really seems like very few hardcore Linux/OSS devs have a clue about it. Is there really a clear advantage, or is it just an excuse to write a new compiler to solve a problem that doesn't exist?
Much better modularization, so that the tokenizer used by the compiler is easily available to other tools, so that your editor does not have to (try to) re-implement all the intricacies of C++ syntax, so that parse tree & symbolic info is available to your IDE, so that it does not have to try to re-implement parsing of all the intricacies of C++ templates & namespaces in order to give you cross-referencing or even re-factoring functions (not to mention support for a debugger that can actually figure out types in a complex inheritance hierarchy).
Re: (Score:2)
But the tokenizer and parser for an IDE have to work incrementally (parsing as you type), making them wholly different beasts.
Re: (Score:2)
I don't believe that you can make a claim like that if you do not have experience in the incremental parser code of an IDE.
Re: (Score:2)
But the tokenizer and parser for an IDE have to work incrementally (parsing as you type), making them wholly different beasts.
No need to work incrementally, as long as you just work _fast_. That's what you have fast processors for, to recompile after every keystroke.
Re: (Score:3)
Incremental parsing means that you don't re-lex/re-parse the entire text stream from the beginning every time a character or two get inserted because of user typing something. Which means that you have to have a lexerthat's smart enough to correct just the few affected tokens, and then a parser that looks at those changed tokens and updates only the affected part of the AST. Which, generally speaking, is not at all a trivial thing, especially for a language as complicated as C++ (where a single token change
Re: (Score:3)
It has a pretty good static analyzer.
Re: (Score:2)
Re:What's the clear advantage of LLVM? (Score:5, Informative)
I don't see anybody addressing this question adequately. Here goes for a start.
1) g++ has simply awful error messages for template code. clang++ has MUCH more helpful error messages. Of not quite so much importance, all clang/clang++ error messages are significantly better than those of gcc/g++. Looks like clang++ has spurred g++ to improve error messages in 4.8 though. They NEEDED to be improved.
2) clang++ 3.1 has significantly better C++11 support than g++ 4.7:
Rvalue refs for *this
Alignment support
Strong compare-exchange
Bidirectional fences
Atomics in signal handlers
Also borrows from C99 one very significant enhancement: C99 designated initializers
References:
clang: Expressive Diagnostics [llvm.org]
C++0x/C++11 Support in GCC [gnu.org]
C++98 and C++11 Support in Clang [llvm.org]
Re: (Score:3)
The main advantage of LLVM is that it will provide much needed competition for GCC which for the last decade has only had VCC to spur it on. Note that LLVM code can be freely transplanted into GCC while the reverse is not allowed, probably enough in itself to ensure GCC's continued preeminence even with Apple's fat checkbook backing LLVM.
Re: (Score:2)
and the FreeBSD users, we bring it to a bit larger number than that. Probably still only 10s of thousands...
Re:WOW (Score:4, Informative)
Most likely the BSD maintainers and developers out there.... bout thats less then 0.00001% of 7+billion people. I'm going to guess anywhere between 1-1000 =)
Now add in all the Mac and iOS developers and the number increases just slightly. MacOS X 10.8 is completely built using Clang + LLVM. OpenGL uses LLVM. OpenCL uses LLVM.
Don't knock it until you've tried it (Score:4, Interesting)
FreeBSD might not be anywhere near as popular as linux but its a damn good system, and whats more there arn't endless ever-so-slightly incompatable distributions of it. Ok, its never going to threaten Linux but its good to have a proper alternative free Unix system available that is actually interested in its end users and isn't just a pet project of the devs (unlike certain other BSDs I could mention).
Re: (Score:2)
Actually, 9 of them did. One of them had to be the designated driver. He had a car, you know.
Re: (Score:2)
Thanks for the clarification.
For a moment there I thought the AC was counting in binary
Re:Why switch at all? (Score:5, Informative)
Could check this article: http://clang.llvm.org/comparison.html [llvm.org]
Apple made the switch a while back in Xcode. The end result was much better debugging and refactoring capabilities.
Re: (Score:3)
Sure.
1) Clang(++) produces better error messages. This is a mere nicity when dealing with C code, but it's an absolute requirement when dealing with template based C++.
2) Clang has a much more comprehensive set of warnings that get into static analysis of your code than gcc.
3) Clang is modular, and can be used to develop other tools using the same parser/type checker/...
3.1) Because of this, it's been used to develop a static analyser that can be seperately invoked (because it runs substantially slower tha
Re: (Score:2)
Nothing has stunted the computer/software industries more than the introduction of the 8086 and the GPL.
Having lived with the the safe Duopoly of Microsoft/Apple [Years of IE6 was only part of the problem] dominate everything absolutely for so long. Other than providing a viable competitor, where commercial companies have failed to compete, and are swallowed up by these larger companies as the bundle all the profitable software I fail to see their relevance. The only effective competitor seems to have been GPL for obvious reason [its almost immune...although buying off key people and handing out free hardware
Re: (Score:2)
Odd how the most used *nix is GPLed -Linux
odd how veteran companies from the unix war (oracle, ibm, hp,) are pushing the use of LInux and other GPLed software.
maybe they figured out that sharing is best but if that were it they could have simply shared and setteled on a BSD. Or they realize that working where there competitor can't simply fork and close at will is best for everyone involved thus settling on a GPL licensed stack
Re: (Score:2)
Odd how the most used *nix is GPLed -Linux
You'd need a reference for that. I would submit that BSD code is more prevalent than GPL in actual use by an order of magnitude or better.
Every copy of windows has BSD code in it (No, not the tcp/ip stack). But libraries to do things like zipping files, displaying GIFs, etc etc. Mac OS and iOS is based on BSD as well. Even linux has BSD code in it. So does the PS3, Xbox 360, and FreeNAS.
Re: (Score:2)
Re: (Score:2)
The FSF has always granted an exception for compiling non-GPL3 software, but they don't like it. Others (like me) have feared they may pull such licensing sometime in the future, so having an alternative is a good thing - we shouldn't put too much power in the control of one relatively radical group.
Re: (Score:3)
Re: (Score:3)
Apple for example is using lots of FreeBSD in their operating system, and they contribute back.
Careful, pointing out that Apple contributes back to FOSS will get you lynched on /.
Pointing out that Apple releases their OS kernel under an open license, as well as pays to develop CUPS, WebKit, and LLVM/Clang, will result in them pissing on your grave.
There really are far too many GPL extremists whom condemn any software that doesn't fit into the GPL orthodoxy, even if they use alternate free software licenses.
Re: (Score:3)
Yup. In many ways, FreeBSD probably has more desktop users than Linux does; it's just that FreeBSD is renamed "OS X", and has a bunch of additional software dropped in. In many ways, OS X is FreeBSD with a set of additional proprietary userspace interface and API's dropped in.
And yet, in spite of OS X being a 'closed fork', Apple still voluntarily contributes a substantial amount of code back to FreeBSD. To me, it's proof that the BSD license works well, and that compulsory contribution isn't the only way t