mirror of https://github.com/ARMmbed/mbed-os.git
63 lines
2.0 KiB
Plaintext
63 lines
2.0 KiB
Plaintext
/* mbed Microcontroller Library
|
|
* Copyright (c) 2019 ARM Limited
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
* you may not use this file except in compliance with the License.
|
|
* You may obtain a copy of the License at
|
|
*
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
* See the License for the specific language governing permissions and
|
|
* limitations under the License.
|
|
*/
|
|
#ifndef __atomic
|
|
#define __atomic
|
|
|
|
// Just go straight to the main file
|
|
#include <mstd_atomic>
|
|
|
|
#define ATOMIC_VAR_INIT(x) { x }
|
|
#define ATOMIC_FLAG_INIT MSTD_ATOMIC_FLAG_INIT
|
|
|
|
// And then pull it all into our std
|
|
namespace std {
|
|
using mstd::atomic;
|
|
using mstd::atomic_is_lock_free;
|
|
using mstd::atomic_store;
|
|
using mstd::atomic_store_explicit;
|
|
using mstd::atomic_load;
|
|
using mstd::atomic_load_explicit;
|
|
using mstd::atomic_exchange;
|
|
using mstd::atomic_exchange_explicit;
|
|
using mstd::atomic_compare_exchange_weak;
|
|
using mstd::atomic_compare_exchange_weak_explicit;
|
|
using mstd::atomic_compare_exchange_strong;
|
|
using mstd::atomic_compare_exchange_strong_explicit;
|
|
using mstd::atomic_fetch_add;
|
|
using mstd::atomic_fetch_add_explicit;
|
|
using mstd::atomic_fetch_sub;
|
|
using mstd::atomic_fetch_sub_explicit;
|
|
using mstd::atomic_fetch_and;
|
|
using mstd::atomic_fetch_and_explicit;
|
|
using mstd::atomic_fetch_or;
|
|
using mstd::atomic_fetch_or_explicit;
|
|
using mstd::atomic_fetch_xor;
|
|
using mstd::atomic_fetch_xor_explicit;
|
|
using mstd::atomic_flag;
|
|
using mstd::atomic_flag_test_and_set;
|
|
using mstd::atomic_flag_test_and_set_explicit;
|
|
using mstd::atomic_flag_clear;
|
|
using mstd::atomic_flag_clear_explicit;
|
|
using mstd::atomic_init;
|
|
using mstd::memory_order;
|
|
using mstd::kill_dependency;
|
|
using mstd::atomic_thread_fence;
|
|
using mstd::atomic_signal_fence;
|
|
}
|
|
|
|
#endif /* __atomic */
|