Live data from Hacker News

LLVM 6.0.0 Release

lists.llvm.org

21–30 of 33 posts

Re: LLVM 6.0.0 Release

#21
post #12
post #3

Earlier quoted context omitted.

I can't remember, has Apple bothered enabling thread-local storage in its clang distribution yet?

Apple's clang supports thread_local as of XCode 8: https://stackoverflow.com/questions/28094794/why-does-apple-...

Better late than never, I suppose. The answer indicates it might be ABI incompatible with upstream clang though? I'm sure that can cause a lot of fun...

Re: LLVM 6.0.0 Release

#22
post #15

Earlier quoted context omitted.

Can’t you just install a more up to date compiler with brew? I don’t know if signing binaries works though.

Brew's approach to compilers adds tremendous friction. Brew doesn't download a binary, it builds the compilers (both gcc and clang) and installs them but doesn't make bin/ links. It's because of this that our build process (I'm not OP BTW) builds with all of brew gcc, brew clang and xcode (thank goodness for xcodebuild at least, so I can do this all from a Makefile). CMake is really helpful here.

Homebrew has bottles so you don't have to do compilation on your machine–you just download a precompiled version.

Re: LLVM 6.0.0 Release

#23
post #10

Earlier quoted context omitted.

Apple's LLVM and Clang from Xcode 9 are based on version 4.0 of the main LLVM/Clang. You'll need at least LLVM/Clang 5.0 for more C++17 compatibility. To be fair, modern C++ support is not a priority for Apple, their efforts are more toward Swift.

It's fine if it's not a priority, but why ship a crippled compiler when they could ship the upstream compiler? ABI issues maybe? (I've heard from OS X users that XCode updates have broken the string ABI multiple times anyway...). I don't really care too much since I'm not an OS X user, but some people insist on trying to compile/run some of the software I work on on OS X...

"crippled" is rather hyperbolic. Older, less feature rich, but not crippled.

Re: LLVM 6.0.0 Release

#24
post #15

Earlier quoted context omitted.

Brew's approach to compilers adds tremendous friction. Brew doesn't download a binary, it builds the compilers (both gcc and clang) and installs them but doesn't make bin/ links. It's because of this that our build process (I'm not OP BTW) builds with all of brew gcc, brew clang and xcode (thank goodness for xcodebuild at least, so I can do this all from a Makefile). CMake is really helpful here.

Homebrew has bottles so you don't have to do compilation on your machine–you just download a precompiled version.

Yes, but GCC and clang are not provided that way, and, as I mentioned, not linked into /usr/local/bin. I understand why they don't do the latter (it could confuse the unsuspecting user) but it does add friction.

Re: LLVM 6.0.0 Release

#25
post #17
post #10

Earlier quoted context omitted.

It's fine if it's not a priority, but why ship a crippled compiler when they could ship the upstream compiler? ABI issues maybe? (I've heard from OS X users that XCode updates have broken the string ABI multiple times anyway...). I don't really care too much since I'm not an OS X user, but some people insist on trying to compile/run some of the software I work on on OS X...

Talking of Apple Clang as a crippled compiler comes across as very uneducated opinion to me. It goes through an extensive validation / stabilization for many months before being released. So yes it adds some delay in getting new shiny features, but calling it "crippled" seems like a very much uneducated opinion here. You can have an idea about the integration exactly what version from upstream Apple is integrating by…

Thank you for the info/insight.

I assumed that the specified language features, especially ones also depending on core libraries like libc++, would most likely be released as part of the next major OS update (since these are very essential for the complete system and need to be tested along side it as one whole).

I didn't check the macOS 10.13.4 beta, but I'm assuming that the features I mentioned are coming as part of macOS 10.14 and Xcode 10.

Re: LLVM 6.0.0 Release

#26
post #19
post #17

Earlier quoted context omitted.

Talking of Apple Clang as a crippled compiler comes across as very uneducated opinion to me. It goes through an extensive validation / stabilization for many months before being released. So yes it adds some delay in getting new shiny features, but calling it "crippled" seems like a very much uneducated opinion here. You can have an idea about the integration exactly what version from upstream Apple is integrating by…

I'm sure a lot of work goes into it, but often features that are present in upstream clang seem to be removed or heavily delayed. Fom the perspective of a Linux "developer" whose software (C++ scientific tools) sometimes gets compiled with the Xcode clang++, I've seen (i.e. been told of by Apple users) all sorts of problems that don't happen with upstream clang or modern gcc. The fact that the versioning isn't cohere…

What features?

Re: LLVM 6.0.0 Release

#27
post #24

Earlier quoted context omitted.

Homebrew has bottles so you don't have to do compilation on your machine–you just download a precompiled version.

Yes, but GCC and clang are not provided that way, and, as I mentioned, not linked into /usr/local/bin. I understand why they don't do the latter (it could confuse the unsuspecting user) but it does add friction.

> but GCC and clang are not provided that way

What? On my machine both are available as bottles:

    $ brew info gcc | head -n 1
    gcc: stable 7.3.0 (bottled), HEAD
    $ brew info llvm | head -n 1
    llvm: stable 5.0.1 (bottled), HEAD [keg-only]

Re: LLVM 6.0.0 Release

#28
post #19

Earlier quoted context omitted.

I'm sure a lot of work goes into it, but often features that are present in upstream clang seem to be removed or heavily delayed. Fom the perspective of a Linux "developer" whose software (C++ scientific tools) sometimes gets compiled with the Xcode clang++, I've seen (i.e. been told of by Apple users) all sorts of problems that don't happen with upstream clang or modern gcc. The fact that the versioning isn't cohere…

What features?

Well the one I'm familiar with is Apple's explicit disabling of thread-local storage for a long time. See e.g. https://stackoverflow.com/a/23850891, which thankfully has been fixed since then (but it took something like 2 years).

Re: LLVM 6.0.0 Release

#29
post #24

Earlier quoted context omitted.

Yes, but GCC and clang are not provided that way, and, as I mentioned, not linked into /usr/local/bin. I understand why they don't do the latter (it could confuse the unsuspecting user) but it does add friction.

> but GCC and clang are not provided that way What? On my machine both are available as bottles: $ brew info gcc | head -n 1 gcc: stable 7.3.0 (bottled), HEAD $ brew info llvm | head -n 1 llvm: stable 5.0.1 (bottled), HEAD [keg-only]

Huh, interesting; our site config seems to require building so I had assumed that was the case!

Re: LLVM 6.0.0 Release

#30
post #29

Earlier quoted context omitted.

> but GCC and clang are not provided that way What? On my machine both are available as bottles: $ brew info gcc | head -n 1 gcc: stable 7.3.0 (bottled), HEAD $ brew info llvm | head -n 1 llvm: stable 5.0.1 (bottled), HEAD [keg-only]

Huh, interesting; our site config seems to require building so I had assumed that was the case!

Make sure that you install (or reinstall after a big macOS upgrade) the XCode command line tools. If they are not present, homebrew falls back to compiling GCC from source.
Post reply on HN