Thread overview
iOS natively supports thread-locals
Jun 19, 2016
Dan Olson
Jun 19, 2016
Joakim
Jun 19, 2016
Jacob Carlborg
Jun 20, 2016
Dan Olson
June 18, 2016
Good news!  I just did a simple LDC test of thread locals using vanilla LLVM 3.8.0 and Xcode 3.7.1.  Targeted both arm64 (iPhone 6) and armv7 (older iPad mini) running iOS 9.3.2.  This paves the way for ditching my modified LLVM.

Was there an Apple announcement about this?

I am not sure when this came about.  It snuck in sometime between Jan 2016 and the LLVM 3.8.0 release in early March.  I noticed when trying to cherry-pick my thread-local changes today into a 3.8.0 release and there was conflict.  Looking at the code, there it was, TLS support.

I think device needs to be running at least iOS 9.0 for armv7 and 8.0 for arm64.  Doesn't work yet in iOS Simulator for 32-bit though.
-- 
Dan
June 19, 2016
On Sunday, 19 June 2016 at 02:40:51 UTC, Dan Olson wrote:
> Good news!  I just did a simple LDC test of thread locals using vanilla LLVM 3.8.0 and Xcode 3.7.1.  Targeted both arm64 (iPhone 6) and armv7 (older iPad mini) running iOS 9.3.2.  This paves the way for ditching my modified LLVM.
>
> Was there an Apple announcement about this?
>
> I am not sure when this came about.  It snuck in sometime between Jan 2016 and the LLVM 3.8.0 release in early March.  I noticed when trying to cherry-pick my thread-local changes today into a 3.8.0 release and there was conflict.  Looking at the code, there it was, TLS support.
>
> I think device needs to be running at least iOS 9.0 for armv7 and 8.0 for arm64.  Doesn't work yet in iOS Simulator for 32-bit though.

Looks like this commit, ARM-only for now:

http://llvm.org/viewvc/llvm-project?view=revision&revision=257039
June 19, 2016
On 2016-06-19 04:40, Dan Olson wrote:
> Good news!  I just did a simple LDC test of thread locals using vanilla
> LLVM 3.8.0 and Xcode 3.7.1.  Targeted both arm64 (iPhone 6) and armv7
> (older iPad mini) running iOS 9.3.2.  This paves the way for ditching my
> modified LLVM.

Aha, interesting. Does the implementation look like the one for OS X or is completely different?

-- 
/Jacob Carlborg
June 20, 2016
Jacob Carlborg <doob@me.com> writes:

> On 2016-06-19 04:40, Dan Olson wrote:
>> Good news!  I just did a simple LDC test of thread locals using vanilla LLVM 3.8.0 and Xcode 3.7.1.  Targeted both arm64 (iPhone 6) and armv7 (older iPad mini) running iOS 9.3.2.  This paves the way for ditching my modified LLVM.
>
> Aha, interesting. Does the implementation look like the one for OS X or is completely different?

It looks the same as OS X.