diff options
| author | Richard Diamond <wichard@vitalitystudios.com> | 2015-08-05 22:10:57 +0000 |
|---|---|---|
| committer | Richard Diamond <wichard@vitalitystudios.com> | 2015-08-05 22:10:57 +0000 |
| commit | 559c1d72a94dcd7dba088438359422591aa3355b (patch) | |
| tree | bfe3f69fe6cc8654636f99258447ca558dccf77c /llvm/test | |
| parent | 36e7e52aa4f8d79c898d74f93711c4a0c78e253f (diff) | |
| download | bcm5719-llvm-559c1d72a94dcd7dba088438359422591aa3355b.tar.gz bcm5719-llvm-559c1d72a94dcd7dba088438359422591aa3355b.zip | |
Divide the primitive size in bits by eight so the initial load's alignment is in
bytes as expected. Tested with the included unit test.
llvm-svn: 244155
Diffstat (limited to 'llvm/test')
| -rw-r--r-- | llvm/test/Transforms/AtomicExpand/expand-atomic-rmw-initial-load.ll | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/llvm/test/Transforms/AtomicExpand/expand-atomic-rmw-initial-load.ll b/llvm/test/Transforms/AtomicExpand/expand-atomic-rmw-initial-load.ll new file mode 100644 index 00000000000..197250ef455 --- /dev/null +++ b/llvm/test/Transforms/AtomicExpand/expand-atomic-rmw-initial-load.ll @@ -0,0 +1,8 @@ +; RUN: opt -S %s -atomic-expand -mtriple=i686-linux-gnu | FileCheck %s + +define i8 @test_initial_load(i8* %ptr, i8 %value) { + %res = atomicrmw nand i8* %ptr, i8 %value seq_cst + ret i8 %res +} +; CHECK-LABEL: @test_initial_load +; CHECK-NEXT: %1 = load i8, i8* %ptr, align 1 |

