Home
last modified time | relevance | path

Searched refs:IsPowerOfTwo (Results 1 – 6 of 6) sorted by relevance

/arkcompiler/runtime_core/libpandabase/tests/
Dmath_helpers_test.cpp40 HWTEST(MathHelpers, IsPowerOfTwo, testing::ext::TestSize.Level0)
42 EXPECT_TRUE(IsPowerOfTwo(1));
43 EXPECT_TRUE(IsPowerOfTwo(2));
44 EXPECT_TRUE(IsPowerOfTwo(4));
45 EXPECT_TRUE(IsPowerOfTwo(64));
46 EXPECT_TRUE(IsPowerOfTwo(1024));
47 EXPECT_TRUE(IsPowerOfTwo(2048));
48 EXPECT_FALSE(IsPowerOfTwo(3));
49 EXPECT_FALSE(IsPowerOfTwo(63));
50 EXPECT_FALSE(IsPowerOfTwo(65));
[all …]
/arkcompiler/runtime_core/libpandabase/utils/
Dmath_helpers.h55 constexpr bool IsPowerOfTwo(T value) in IsPowerOfTwo() function
149 ASSERT(IsPowerOfTwo(table_size));
/arkcompiler/runtime_core/libpandafile/
Dpanda_cache.h194 static_assert(panda::helpers::math::IsPowerOfTwo(DEFAULT_FIELD_CACHE_SIZE));
195 static_assert(panda::helpers::math::IsPowerOfTwo(DEFAULT_METHOD_CACHE_SIZE));
196 static_assert(panda::helpers::math::IsPowerOfTwo(DEFAULT_CLASS_CACHE_SIZE));
/arkcompiler/runtime_core/libpandabase/mem/ringbuf/
Dlock_free_ring_buffer.h32 static_assert(panda::helpers::math::IsPowerOfTwo(RING_BUFFER_SIZE));
/arkcompiler/ets_runtime/ecmascript/
Dlinked_hash_table.cpp28 ASSERT_PRINT(helpers::math::IsPowerOfTwo(capacity), "capacity must be pow of '2'"); in Create()
Dtagged_hash_table.h91 …ASSERT_PRINT(helpers::math::IsPowerOfTwo(static_cast<uint32_t>(entriesCount)), "the size must be p… in Create()