mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-02 12:32:04 +00:00
4db8d09de9
* Make libunwind optional. Allow use custom libcctz * fix * Fix * fix * Update BaseDaemon.cpp * Update CMakeLists.txt * Reorganize includes. part 1 * Update dbms_include.cmake * Reorganize includes. part 2 * Reorganize includes. part 3 * dbms/src/Common/ThreadPool -> libs/libcommon * Reorganize includes. part 4 * Fix print_include_directories * Update thread_creation_latency.cpp * Update StringRef.h
19 lines
302 B
C++
19 lines
302 B
C++
#pragma once
|
|
|
|
#include <string.h>
|
|
|
|
|
|
template <typename T>
|
|
inline T unalignedLoad(const void * address)
|
|
{
|
|
T res {};
|
|
memcpy(&res, address, sizeof(res));
|
|
return res;
|
|
}
|
|
|
|
template <typename T>
|
|
inline void unalignedStore(void * address, const T & src)
|
|
{
|
|
memcpy(address, &src, sizeof(src));
|
|
}
|