* commit 'd520c95e457fb81522491b7e50dc736e81e9bbd1': ARM: Change dmb domain for bionic_atomic_barrier()
This commit is contained in:
commit
b0ad47e20d
@ -17,7 +17,7 @@
|
|||||||
#define BIONIC_ATOMIC_AARCH64_H
|
#define BIONIC_ATOMIC_AARCH64_H
|
||||||
|
|
||||||
/* For ARMv8, we can use the 'dmb' instruction directly */
|
/* For ARMv8, we can use the 'dmb' instruction directly */
|
||||||
__ATOMIC_INLINE__ void __bionic_memory_barrier(void) {
|
__ATOMIC_INLINE__ void __bionic_memory_barrier() {
|
||||||
__asm__ __volatile__ ( "dmb ish" : : : "memory" );
|
__asm__ __volatile__ ( "dmb ish" : : : "memory" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -16,9 +16,9 @@
|
|||||||
#ifndef BIONIC_ATOMIC_ARM_H
|
#ifndef BIONIC_ATOMIC_ARM_H
|
||||||
#define BIONIC_ATOMIC_ARM_H
|
#define BIONIC_ATOMIC_ARM_H
|
||||||
|
|
||||||
__ATOMIC_INLINE__ void __bionic_memory_barrier(void) {
|
__ATOMIC_INLINE__ void __bionic_memory_barrier() {
|
||||||
#if defined(ANDROID_SMP) && ANDROID_SMP == 1
|
#if defined(ANDROID_SMP) && ANDROID_SMP == 1
|
||||||
__asm__ __volatile__ ( "dmb" : : : "memory" );
|
__asm__ __volatile__ ( "dmb ish" : : : "memory" );
|
||||||
#else
|
#else
|
||||||
/* A simple compiler barrier. */
|
/* A simple compiler barrier. */
|
||||||
__asm__ __volatile__ ( "" : : : "memory" );
|
__asm__ __volatile__ ( "" : : : "memory" );
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
* the architecture-specific assembler versions.
|
* the architecture-specific assembler versions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
__ATOMIC_INLINE__ void __bionic_memory_barrier(void) {
|
__ATOMIC_INLINE__ void __bionic_memory_barrier() {
|
||||||
__sync_synchronize();
|
__sync_synchronize();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
*
|
*
|
||||||
* Macros defined in this header:
|
* Macros defined in this header:
|
||||||
*
|
*
|
||||||
* void ANDROID_MEMBAR_FULL(void)
|
* void ANDROID_MEMBAR_FULL()
|
||||||
* Full memory barrier. Provides a compiler reordering barrier, and
|
* Full memory barrier. Provides a compiler reordering barrier, and
|
||||||
* on SMP systems emits an appropriate instruction.
|
* on SMP systems emits an appropriate instruction.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user