misc.h: 清理多余代码
This commit is contained in:
parent
fea8b8af4e
commit
c921bafbf6
22
src/misc.h
22
src/misc.h
|
@ -141,26 +141,4 @@ namespace WinProcGroup
|
|||
void bindThisThread(size_t idx);
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
using TimePoint = std::chrono::milliseconds::rep; // A value in milliseconds
|
||||
|
||||
static_assert(sizeof(TimePoint) == sizeof(int64_t), "TimePoint should be 64 bits");
|
||||
|
||||
inline uint64_t rand64()
|
||||
{
|
||||
return static_cast<uint64_t>(rand()) ^
|
||||
(static_cast<uint64_t>(rand()) << 15) ^
|
||||
(static_cast<uint64_t>(rand()) << 30) ^
|
||||
(static_cast<uint64_t>(rand()) << 45) ^
|
||||
(static_cast<uint64_t>(rand()) << 60);
|
||||
}
|
||||
|
||||
inline uint64_t rand56()
|
||||
{
|
||||
return rand64() << 8;
|
||||
}
|
||||
|
||||
void start_logger(const std::string &fname);
|
||||
|
||||
#endif // #ifndef MISC_H_INCLUDED
|
Loading…
Reference in New Issue