未验证 提交 d9f5d1eb 编写于 作者: Z Zeng Jinle 提交者: GitHub

ag allocator by default, test=develop (#21837)

上级 e519a1fc
......@@ -27,7 +27,7 @@ DEFINE_bool(free_idle_chunk, false,
"allocation request. If true, no allocation would be cached. This "
"flag only works when FLAGS_allocator_strategy=auto_growth.");
DEFINE_bool(free_when_no_cache_hit, true,
DEFINE_bool(free_when_no_cache_hit, false,
"Whether to free idle chunks when no cache hit. If true, idle "
"chunk would be freed when no cache hit; if false, idle "
"chunk would be freed when out of memory occurs. This flag "
......
......@@ -307,7 +307,12 @@ DEFINE_double(memory_fraction_of_eager_deletion, 1.0,
* Example:
* Note: For selecting allocator policy of PaddlePaddle.
*/
DEFINE_string(allocator_strategy, "naive_best_fit",
#ifdef PADDLE_ON_INFERENCE
static constexpr char kDefaultAllocatorStrategy[] = "naive_best_fit";
#else
static constexpr char kDefaultAllocatorStrategy[] = "auto_growth";
#endif
DEFINE_string(allocator_strategy, kDefaultAllocatorStrategy,
"The allocation strategy. naive_best_fit means the original best "
"fit allocator of Fluid. "
"auto_growth means the experimental auto-growth allocator. "
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册