Andrey Semashev
ca151bedb4
Fixed warnings about left-shifting negative signed integers.
2017-05-22 15:21:22 +03:00
Andrey Semashev
11c785768c
Updated to reflect changes from P0558R1 accepted into C++17.
...
1. Expose value_type and difference_type (where present) to user's code.
2. Prohibit arithmetic operations on pointers to non-object types. In
particular, arithmetic operations such as fetch_add/fetch_sub will no longer
compile for pointers to cv void, pointers to functions and pointers to
non-static class members.
Also, use C++11 <type_traits> when possible instead of Boost.TypeTraits to
reduce dependencies. Cleaned up value_arg_type internal type usage for more
efficient argument passing.
2017-04-01 18:29:26 +03:00
Andrey Semashev
2b6ef06b57
Added preliminary support for MSVC for ARM64 target.
2017-01-07 21:27:09 +03:00
Andrey Semashev
5b30e196a6
Added is_always_lock_free static constant from C++17.
2016-10-13 15:59:22 +03:00
Andrey Semashev
9be3389f06
Updated test to refrect improved support for Oracle Studio and SPARC.
2016-09-17 13:30:26 +03:00
Andrey Semashev
6bb5b17108
Silenced MSVC warnings about 'this' being used in the constructor initialization list.
2015-08-22 20:47:56 +03:00
Andrey Semashev
ff91811c1a
Fixes #10994 . Fixed compilation with gcc 4.4 when cmpxchg16b is used.
2015-08-17 23:27:37 +03:00
Andrey Semashev
b1bb36c5b3
Only use intptr_t when available. Only test integer overflows/underflows for unsigned integers (the behavior is undefined for signed ints anyway). This should silence compiler warnings as well.
2015-08-17 22:25:19 +03:00
Andrey Semashev
4162cb109f
Corrected memory ordering of loads. Relaxed loads do not synchronize-with seq_cst stores, which allowed the test to fail. Also removed unnecessary loads that did not contribute to the test robustness and could have reduced it by issuing extra memory fences.
2015-08-14 15:03:35 +03:00
Andrey Semashev
7b1d722d94
Ported tests to core/lightweight_test.hpp.
...
Boost.Test was dropped due to instability and long-standing differences between develop and master branches. We don't use most of its features anyway.
2015-01-25 18:50:58 +03:00
Jürgen Hunold
30f72c8d25
Add explicit dependency on Boost.Test
2015-01-14 16:13:41 +01:00
Andrey Semashev
4dee330229
Added support for types with non-trivial default constructors.
2014-07-07 22:40:41 +04:00
Andrey Semashev
313497c6ae
Added Windows version specification to fix compilation with MSVC. The code targets for Windows 2000.
2014-06-09 01:18:38 +04:00
Andrey Semashev
0c9b1b3806
Reworked platform selection, fixed Windows backend.
...
Platform selection now works in two stages. First compiler is tested for
the supported configuration. If that fails, OS is tested. Lastly, if
nothing succeeded, emulation backend is selected.
2014-06-09 01:07:26 +04:00
Andrey Semashev
97ae84a474
Adjusted the workaround for ldrexd/strexd instruction problem with register pairs allocation. The problem only affects ARMv6k in Thumb mode, so enable these instructions for ARM mode. Also don't base the decision on the compiler version, it is probably not relevant. Updated lockfree test to reflect the recent changes related to ARM backends.
2014-05-23 21:02:07 +04:00
Andrey Semashev
76b78f2491
#9985 . Added ebx saves and restores in asm blocks to avoid frame pointer clobbering, when frame pointer omission is disabled.
2014-05-17 21:58:59 +04:00
Andrey Semashev
17cf91d8c9
Working on the library rewrite. Implemented gcc-x86 and gcc-sync
...
backends.
2014-05-04 00:14:24 +04:00
Andrey Semashev
625c3c3a2e
Compilation fixes. Added public headers for atomic_flag and atomic.
2014-04-20 17:26:42 +04:00
Andrey Semashev
20747acd08
Corrected includes.
2014-01-27 11:30:04 +04:00
Andrey Semashev
1bda03c997
Attempt to fix tests on MSVC
...
[SVN r85574]
2013-09-05 17:01:50 +00:00
Andrey Semashev
3869ce33cf
Added tests for int128 atomicity.
...
[SVN r84804]
2013-06-16 14:01:04 +00:00
Andrey Semashev
55e8b16a12
Fixed compilation with gcc 4.4. Optimized code for gcc older than 4.7 and also added support for 128-bit atomic ops. Completed transition to defaulted and deleted functions.
...
[SVN r84801]
2013-06-16 13:40:11 +00:00
Andrey Semashev
9cab8a9ebf
Added a generic atomic<> implementation based on the new __atomic intrinsics available in gcc 4.7 and clang 3.2. The new implementation adds support for 128-bit atomic. Other implementations updated to employ new macros in Boost.Config for defaulted and deleted functions (this is not complete yet). Fixed padding for the lock pool. Initializing constructor for atomic<> made explicit to avoid ambiguities of different overloads of operator=.
...
[SVN r84800]
2013-06-15 20:43:48 +00:00
Andrey Semashev
179e72cfd1
Code cleanup.
...
[SVN r84700]
2013-06-08 18:22:36 +00:00
Andrey Semashev
5b0186dc7d
Added implementation of 64-bit atomic operations on 32-bit Windows. Pointer specializations of 64-bit CAS-based atomic implementation extracted to a separate header, since these specializations are not needed on 32-bit platforms.
...
[SVN r84695]
2013-06-08 17:36:38 +00:00
Tim Blechmann
18b97cbe7a
atomic: Optimization for 64 bit loads and stores for 32 bit x86 on gcc
...
fixes #8574
[SVN r84288]
2013-05-15 06:12:46 +00:00
Tim Blechmann
96b44933f0
atomic: provide additive functionality for atomic<void*>
...
fixes #8501
[SVN r84190]
2013-05-08 04:45:38 +00:00
Tim Blechmann
764db51b6d
atomic: adapt for constexpr and noexcept
...
Signed-off-by: Tim Blechmann <tim@klingt.org >
[SVN r82870]
2013-02-14 12:32:41 +00:00
Tim Blechmann
982dc948e3
atomic: fix typos
...
fixes #7804
[SVN r82072]
2012-12-18 09:43:23 +00:00
Andrey Semashev
7dabb82d2b
Added threading=multi requirement to fix linking with pthread.
...
[SVN r81833]
2012-12-10 19:43:51 +00:00
Tim Blechmann
eea655ca35
atomic: fix testsuite compilation with -Werror=unused-but-set-variable
...
[SVN r81756]
2012-12-07 13:35:25 +00:00
Tim Blechmann
0b153e9f03
atomic: fix linking of testsuite
...
[SVN r81738]
2012-12-06 12:35:53 +00:00
Helge Bahmann
00a7156487
atomic: remove remaining C99 ints
...
Remove remaining references to (u)intX_t, use the boost::(u)intX_t ones
instead. Fixes remaining unit test failures on Windows.
[SVN r79670]
2012-07-22 13:05:39 +00:00
Helge Bahmann
a7b62d7f46
atomic: fix lockfree expectation on win64
...
Expect atomic<long long> to be lockfree on win64 since it it using cmpxchg64
now.
[SVN r79667]
2012-07-22 13:02:43 +00:00
Helge Bahmann
4e45b3a94c
atomic: use static linkage for unit tests
...
Use static linkage for unit tests
[SVN r79645]
2012-07-21 19:11:07 +00:00
Helge Bahmann
e2966c0f1b
atomic: fix atomicity unit test
...
Make expectation for BOOST_ATOMIC_*_LOCK_FREE macros match actual platform
support.
[SVN r79644]
2012-07-21 19:00:40 +00:00
Helge Bahmann
8b95b4018a
Prefer boost::cstdint to stdint
...
Fixes compilation errors on a number of platforms.
[SVN r79643]
2012-07-21 18:50:11 +00:00
Helge Bahmann
131b70c1fa
atomic: initial import
...
[SVN r79348]
2012-07-08 11:21:45 +00:00