Bug in clang thread_local initialization Bug in clang thread_local initialization multithreading multithreading

Bug in clang thread_local initialization


When you find that a compiler causes runtime behavior which you are relatively certain is incorrect; and another popular compiler does not cause that same behavior - that is sufficient, IMHO, in order to file a bug against said compiler.

As @SamVarshavchik suggestions, you:

  1. Visit LLVM's bug tracker
  2. Create an account if you don't have one
  3. Look for duplicates (e.g. using the term "thread-local")
  4. If you don't find one - you file a bug

I've done just that, so now we have bug 42111.

At worst - it'll be marked as a dupe.

edit: It was not a dupe, and has just now (June 5th 2019) been fixed.