/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Licensees holding valid Qt Enterprise licenses may use this file in
** accordance with the Qt Enterprise License Agreement provided with the 
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Digia.  
**
** If you have questions regarding the use of this file, please use
** contact form at http://qt.digia.com
** $QT_END_LICENSE$
**
****************************************************************************/

#ifndef QATOMIC_ARMV7_H
#define QATOMIC_ARMV7_H

QT_BEGIN_HEADER

// use the DMB instruction when compiling for ARMv7, ...
#ifndef Q_CC_RCVT
# define Q_DATA_MEMORY_BARRIER asm volatile("dmb\n":::"memory")
#else
# define Q_DATA_MEMORY_BARRIER do{__asm { dmb } __schedule_barrier();}while(0)
#endif

// ... but the implementation is otherwise identical to that for ARMv6
QT_BEGIN_INCLUDE_HEADER
#include "QtCore/qatomic_armv6.h"
QT_END_INCLUDE_HEADER

QT_END_HEADER

#endif // QATOMIC_ARMV7_H
