mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-27 18:12:02 +00:00
Merge pull request #292 from proller/tcmalloc
Dont use tcmalloc TCMALLOC_AGGRESSIVE_DECOMMIT patch
This commit is contained in:
commit
00176b9c5e
@ -99,7 +99,7 @@ void Static::InitStaticVars() {
|
||||
|
||||
bool aggressive_decommit =
|
||||
tcmalloc::commandlineflags::StringToBool(
|
||||
TCMallocGetenvSafe("TCMALLOC_AGGRESSIVE_DECOMMIT"), false);
|
||||
TCMallocGetenvSafe("TCMALLOC_AGGRESSIVE_DECOMMIT"), true);
|
||||
|
||||
pageheap_->SetAggressiveDecommit(aggressive_decommit);
|
||||
|
||||
|
@ -1,3 +1,6 @@
|
||||
#ifndef NO_TCMALLOC
|
||||
#include <gperftools/malloc_extension.h>
|
||||
#endif
|
||||
#include "Server.h"
|
||||
#include "LocalServer.h"
|
||||
#include <DB/Common/StringUtils.h>
|
||||
@ -33,6 +36,10 @@ static bool isClickhouseApp(const std::string & app_suffix, std::vector<char *>
|
||||
|
||||
int main(int argc_, char ** argv_)
|
||||
{
|
||||
#ifndef NO_TCMALLOC
|
||||
MallocExtension::instance()->SetNumericProperty("tcmalloc.aggressive_memory_decommit", false);
|
||||
#endif
|
||||
|
||||
std::vector<char *> argv(argv_, argv_ + argc_);
|
||||
|
||||
auto main_func = mainEntryClickHouseServer;
|
||||
|
Loading…
Reference in New Issue
Block a user