提交 033523ea 编写于 作者: L liaogang

update

上级 ea916c84
......@@ -23,7 +23,7 @@ limitations under the License. */
#include <gtest/gtest.h>
#include <unordered_map>
inline bool is_aligned(void const *p, const size_t n) {
inline bool is_aligned(void const *p) {
return 0 == (reinterpret_cast<uintptr_t>(p) & 0x3);
}
......@@ -68,7 +68,7 @@ TEST(BuddyAllocator, CPUMultAlloc) {
}
for (auto p : ps) {
EXPECT_EQ(is_aligned(p.first, 32), true);
EXPECT_EQ(is_aligned(p.first), true);
paddle::memory::Free(cpu, p.first);
// Buddy Allocator doesn't manage too large memory chunk
......@@ -123,7 +123,7 @@ TEST(BuddyAllocator, GPUMultAlloc) {
}
for (auto p : ps) {
EXPECT_EQ(is_aligned(p.first, 32), true);
EXPECT_EQ(is_aligned(p.first), true);
paddle::memory::Free(gpu, p.first);
// Buddy Allocator doesn't manage too large memory chunk
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册