summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/builtins/arm/sync-ops.h
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2014-05-12 15:23:37 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2014-05-12 15:23:37 +0000
commit310874ae3c699a513876e1e250cef2ea4beb170d (patch)
tree311c490a6d8d5636e185e127c73d629f5d4d140c /compiler-rt/lib/builtins/arm/sync-ops.h
parent3f7878ac5f4ed6ff69269199358181017671ba90 (diff)
downloadbcm5719-llvm-310874ae3c699a513876e1e250cef2ea4beb170d.tar.gz
bcm5719-llvm-310874ae3c699a513876e1e250cef2ea4beb170d.zip
[CompilerRT] use .p2align, .balign instead of .align
The .align statements in ARM assembly routines is actually meant to be a power of 2 alignment (e.g. .align 2 == 4 byte alignment, not 2). Switch to using .p2align. .p2align is guaranteed to be a power-of-two alignment always and much more explicit. The .align in the case of x86_64 is byte alignment, use .balign instead of .align. llvm-svn: 208578
Diffstat (limited to 'compiler-rt/lib/builtins/arm/sync-ops.h')
-rw-r--r--compiler-rt/lib/builtins/arm/sync-ops.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler-rt/lib/builtins/arm/sync-ops.h b/compiler-rt/lib/builtins/arm/sync-ops.h
index 777b121d3bc..87cc3c27c17 100644
--- a/compiler-rt/lib/builtins/arm/sync-ops.h
+++ b/compiler-rt/lib/builtins/arm/sync-ops.h
@@ -16,7 +16,7 @@
#include "../assembly.h"
#define SYNC_OP_4(op) \
- .align 2 ; \
+ .p2align 2 ; \
.thumb ; \
DEFINE_COMPILERRT_FUNCTION(__sync_fetch_and_ ## op) \
dmb ; \
@@ -30,7 +30,7 @@
bx lr
#define SYNC_OP_8(op) \
- .align 2 ; \
+ .p2align 2 ; \
.thumb ; \
DEFINE_COMPILERRT_FUNCTION(__sync_fetch_and_ ## op) \
push {r4, r5, r6, lr} ; \
OpenPOWER on IntegriCloud