ceph/cmake/modules
Ulrich Weigand c58fc258a2 cmake: Improve test for 16-byte atomic support on IBM Z
Commit d1b9d14324 added a check for
16-byte atomics without library support on IBM Z.  Unfortunately
it turns out this test only works correctly when the test case
is built without optimization.  (This is normally true, but it
may not be the case when passing explicit CXXFLAGS to cmake.)

The underlying reason is that GCC may choose to use either an
inline implementation of the 16-byte atomics or library calls,
depending on whether or not it is able to prove the atomic
variable is properly aligned.  At -O0 it is never able to prove
that, but at higher optimization levels it depends on the complexity
of the expression (in particular, whether GCC can track down the
definition of the underlying object).

As the test case uses a very simple expression, it may happen that
this test can be built without requiring library support, but some
of the "real" uses of atomics in Ceph code cannot.   This defeats
the whole purpose of the test at configure time.

Fixed by making the access pattern in the test more complex, so
that the test fails even at high optimization levels.

Fixes: https://tracker.ceph.com/issues/43747

Signed-off-by: Ulrich Weigand <ulrich.weigand@de.ibm.com>
2020-01-23 13:13:58 +01:00
..
FindPython cmake: CMAKE_ROLE defaults to "PROJECT" 2019-12-19 10:58:58 +08:00
AddCephTest.cmake cmake: drop Find{Python,Python2}.cmake 2019-12-19 11:52:56 +08:00
BuildBoost.cmake CMake - Workaround set Boost_component_FOUND 2020-01-08 11:31:04 -05:00
Buildc-ares.cmake
BuildDPDK.cmake Merge pull request #31841 from rosinL/wip-support-dpdk-numa 2019-12-02 16:45:11 +08:00
BuildFIO.cmake test/fio: bump to fio 3.15 2019-11-12 02:24:45 +03:00
Buildpmem.cmake cmake: move pmdk build script to Buildpmem.cmake 2019-07-10 11:43:27 -04:00
BuildQatDrv.cmake
BuildRocksDB.cmake cmake: support parallel build for rocksdb 2019-11-25 13:14:22 +05:30
BuildSPDK.cmake cmake/modules: look for GNU make first instead of BSD make 2019-11-25 13:16:04 +05:30
CephCheck_link.c cmake: detect linker support 2019-10-08 21:53:03 +08:00
CephCheck_link.map cmake: detect linker support 2019-10-08 21:53:03 +08:00
CephChecks.cmake cmake: detect librt for POSIX time functions 2019-11-14 21:26:57 +08:00
CheckCxxAtomic.cmake cmake: Improve test for 16-byte atomic support on IBM Z 2020-01-23 13:13:58 +01:00
CheckYasm.cmake
CTags.cmake
Distutils.cmake src,qa: install python bindings into lib/cython_modules/lib.3 2019-12-19 11:52:54 +08:00
Findaio.cmake
Findbabeltrace.cmake
FindBacktrace.cmake
Findblkid.cmake
FindBoost.cmake cmake: update FindBoost.cmake for 1.72 2019-12-22 23:56:52 +08:00
Findc-ares.cmake
FindCppCheck.cmake cmake: silence messages when cppcheck/IWYU is not found 2019-12-10 11:08:02 +08:00
FindCUnit.cmake
FindCython.cmake cmake: drop WITH_PYTHON2 option 2019-12-19 10:58:58 +08:00
Finddpdk.cmake crimson: link required dpdk components for seastar 2019-11-13 15:53:31 +08:00
Findfcgi.cmake
Findfio.cmake
Findfmt.cmake
Findfuse.cmake
FindGMock.cmake
Findgperftools.cmake
FindGSSApi.cmake
FindIWYU.cmake cmake: silence messages when cppcheck/IWYU is not found 2019-12-10 11:08:02 +08:00
FindJeMalloc.cmake
Findkeyutils.cmake
Findleveldb.cmake
FindLTTngUST.cmake
FindLZ4.cmake
Findnl.cmake cmake: rewrite Findgenl to support components argument 2019-06-19 21:21:00 +08:00
FindNUMA.cmake cmake: Add dpdk numa support 2019-11-28 20:15:39 +08:00
FindOATH.cmake
FindOpenLdap.cmake
Findpmem.cmake cmake: Add the support to use system PMDK library 2019-07-10 11:43:27 -04:00
FindPython3.cmake cmake: update FindPython* modules 2019-07-20 22:35:07 +08:00
Findqatzip.cmake
FindRabbitMQ.cmake
FindRDKafka.cmake cmake: check version of librdkafka 2019-12-15 22:16:08 +08:00
Findrdmacm.cmake
FindRocksDB.cmake
FindSanitizers.cmake cmake: fix libtsan detection 2019-09-30 14:49:12 -04:00
Findsnappy.cmake
FindStdFilesystem_test.cc
FindStdFilesystem.cmake cmake: require CMake v3.10.2 2019-08-02 22:09:12 +08:00
Findudev.cmake
Finduuid.cmake
Findverbs.cmake
Findxfs.cmake
Findzfs.cmake
GetGitRevisionDescription.cmake cmake/modules/GetGitRevisionDescription: update to work with git-worktree 2019-10-07 14:26:07 -05:00
GetGitRevisionDescription.cmake.in cmake/modules/GetGitRevisionDescription: update to work with git-worktree 2019-10-07 14:26:07 -05:00
patch-dpdk-conf.sh cmake: Add dpdk numa support 2019-11-28 20:15:39 +08:00
SIMDExt.cmake