aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/atomic_ut.cpp
diff options
context:
space:
mode:
authorsievlev <sievlev@yandex-team.ru>2022-02-10 16:51:45 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:51:45 +0300
commit3288844da9a26e598b08a1f4c2362603bcf1f506 (patch)
treeab7fbbf3253d4c0e2793218f09378908beb025fb /util/system/atomic_ut.cpp
parentc38d513b2c4ace7c22019ef4cc24003204b77391 (diff)
downloadydb-3288844da9a26e598b08a1f4c2362603bcf1f506.tar.gz
Restoring authorship annotation for <sievlev@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'util/system/atomic_ut.cpp')
-rw-r--r--util/system/atomic_ut.cpp48
1 files changed, 24 insertions, 24 deletions
diff --git a/util/system/atomic_ut.cpp b/util/system/atomic_ut.cpp
index 3bf68177d9..07211ffba7 100644
--- a/util/system/atomic_ut.cpp
+++ b/util/system/atomic_ut.cpp
@@ -18,9 +18,9 @@ class TAtomicTest
UNIT_TEST(TestAtomicSub)
UNIT_TEST(TestAtomicGetAndSub)
UNIT_TEST(TestAtomicSwap)
- UNIT_TEST(TestAtomicOr)
- UNIT_TEST(TestAtomicAnd)
- UNIT_TEST(TestAtomicXor)
+ UNIT_TEST(TestAtomicOr)
+ UNIT_TEST(TestAtomicAnd)
+ UNIT_TEST(TestAtomicXor)
UNIT_TEST(TestCAS)
UNIT_TEST(TestGetAndCAS)
UNIT_TEST(TestLockUnlock)
@@ -152,27 +152,27 @@ private:
UNIT_ASSERT_VALUES_EQUAL(v, Max<intptr_t>());
}
- inline void TestAtomicOr() {
- TAtomic v = 0xf0;
-
- UNIT_ASSERT_VALUES_EQUAL(AtomicOr(v, 0x0f), 0xff);
- UNIT_ASSERT_VALUES_EQUAL(v, 0xff);
- }
-
- inline void TestAtomicAnd() {
- TAtomic v = 0xff;
-
- UNIT_ASSERT_VALUES_EQUAL(AtomicAnd(v, 0xf0), 0xf0);
- UNIT_ASSERT_VALUES_EQUAL(v, 0xf0);
- }
-
- inline void TestAtomicXor() {
- TAtomic v = 0x00;
-
- UNIT_ASSERT_VALUES_EQUAL(AtomicXor(v, 0xff), 0xff);
- UNIT_ASSERT_VALUES_EQUAL(AtomicXor(v, 0xff), 0x00);
- }
-
+ inline void TestAtomicOr() {
+ TAtomic v = 0xf0;
+
+ UNIT_ASSERT_VALUES_EQUAL(AtomicOr(v, 0x0f), 0xff);
+ UNIT_ASSERT_VALUES_EQUAL(v, 0xff);
+ }
+
+ inline void TestAtomicAnd() {
+ TAtomic v = 0xff;
+
+ UNIT_ASSERT_VALUES_EQUAL(AtomicAnd(v, 0xf0), 0xf0);
+ UNIT_ASSERT_VALUES_EQUAL(v, 0xf0);
+ }
+
+ inline void TestAtomicXor() {
+ TAtomic v = 0x00;
+
+ UNIT_ASSERT_VALUES_EQUAL(AtomicXor(v, 0xff), 0xff);
+ UNIT_ASSERT_VALUES_EQUAL(AtomicXor(v, 0xff), 0x00);
+ }
+
inline void TestAtomicPtr() {
int* p;
AtomicSet(p, nullptr);