[llvm] r264335 - Add <atomic> to ThreadPool.h, since std::atomic is used

Chris Lattner via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 1 13:27:08 PDT 2016


Seems fine to me,

-Chris

> On Apr 1, 2016, at 12:15 PM, Tom Stellard <tom at stellard.net> wrote:
> 
> Hi Chris,
> 
> Is this OK to merge into the 3.8 branch?
> 
> -Tom
> 
> On Thu, Mar 24, 2016 at 08:39:17PM -0000, Dimitry Andric via llvm-commits wrote:
>> Author: dim
>> Date: Thu Mar 24 15:39:17 2016
>> New Revision: 264335
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=264335&view=rev
>> Log:
>> Add <atomic> to ThreadPool.h, since std::atomic is used
>> 
>> Summary:
>> Apparently, when compiling with gcc 5.3.2 for powerpc64, the order of
>> headers is such that it gets an error about std::atomic<> use in
>> ThreadPool.h, since this header is not included explicitly.  See also:
>> 
>> https://llvm.org/bugs/show_bug.cgi?id=27058
>> 
>> Fix this by including <atomic>.  Patch by Bryan Drewery.
>> 
>> Reviewers: chandlerc, joker.eph
>> 
>> Subscribers: bdrewery, llvm-commits
>> 
>> Differential Revision: http://reviews.llvm.org/D18460
>> 
>> Modified:
>>    llvm/trunk/include/llvm/Support/ThreadPool.h
>> 
>> Modified: llvm/trunk/include/llvm/Support/ThreadPool.h
>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/ThreadPool.h?rev=264335&r1=264334&r2=264335&view=diff
>> ==============================================================================
>> --- llvm/trunk/include/llvm/Support/ThreadPool.h (original)
>> +++ llvm/trunk/include/llvm/Support/ThreadPool.h Thu Mar 24 15:39:17 2016
>> @@ -33,6 +33,7 @@
>> #pragma warning(pop)
>> #endif
>> 
>> +#include <atomic>
>> #include <condition_variable>
>> #include <functional>
>> #include <memory>
>> 
>> 
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits



More information about the llvm-commits mailing list