Skip to content
  • jfb's avatar
    C++11 atomics · a8427ea8
    jfb authored
    Use only the 'portable' atomics when possible [*], which use C++11 atomics. After this patch, individual uses of atomicops.h, for all platforms, should be migrated on by one to explicitly use std::atomic. This will require adapting code which has different assumptions (not all the memory accesses are the same, std::atomics does have signed and unsigned integer both without UB, volatile atomic should be used with shared memory, etc).
    
      [*] Portable atomics aren't used on Windows and OSX for now: some implicit inclusions of windows.h need to be fixed when moving to <atomic> (it was included through "atomicops.h"); some compatibility issues need to be fixed on OSX (see compat.h).
    
    R= thakis@chromium.org
    BUG= 559247
    TEST= git cl try
    
    Review URL: https://codereview.chromium.org/1466833002
    
    Cr-Commit-Position: refs/heads/master@{#363758}
    a8427ea8