OSDN Git Service

Merge "Revert "Revert "Remove GCC atomic workarounds."""
authorDan Albert <danalbert@google.com>
Tue, 12 Aug 2014 21:42:23 +0000 (21:42 +0000)
committerGerrit Code Review <noreply-gerritcodereview@google.com>
Tue, 12 Aug 2014 19:27:26 +0000 (19:27 +0000)
1  2 
runtime/atomic.h

@@@ -252,11 -184,10 +184,10 @@@ class QuasiAtomic 
    DISALLOW_COPY_AND_ASSIGN(QuasiAtomic);
  };
  
- #if ART_HAVE_STDATOMIC
  template<typename T>
- class Atomic : public std::atomic<T> {
+ class PACKED(sizeof(T)) Atomic : public std::atomic<T> {
   public:
 -  Atomic<T>() : std::atomic<T>() { }
 +  Atomic<T>() : std::atomic<T>(0) { }
  
    explicit Atomic<T>(T value) : std::atomic<T>(value) { }