[SROA] Don't de-atomic volatile loads and stores
authorDavid Majnemer <david.majnemer@gmail.com>
Tue, 14 Jul 2015 06:19:58 +0000 (06:19 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Tue, 14 Jul 2015 06:19:58 +0000 (06:19 +0000)
commit2a27389edc504ba4f933b8042d8cc5b0cca53248
treea69fa1dc890f1ace6690505da7ccb10dbfccea63
parent6f1e023b46a9989440e377d8a33a74e8e16c3eca
[SROA] Don't de-atomic volatile loads and stores

Volatile loads and stores are made visible in global state regardless of
what memory is involved.  It is not correct to disregard the ordering
and synchronization scope because it is possible to synchronize with
memory operations performed by hardware.

This partially addresses PR23737.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@242126 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/SROA.cpp
test/Transforms/SROA/basictest.ll