2017-04-12 75 views

回答

1

日誌消息似乎來自

libmalloc-53.1.1 /src/malloc.c

作爲源代碼是可用here 在行#567 - 或文本至少搜索「記錄的malloc(但不是V M」。

malloc_printf(ASL_LEVEL_INFO, "recording malloc (but not VM allocation) stacks to disk using standard recorder\n"); 

關於記錄環境中,應該對Apple documentation看看。

如果你擔心日誌消息,我指的是行內註釋源:

// Set up stack logging as early as possible to catch all ensuing VM allocations, 
// including those from _malloc_printf and malloc zone setup. Make sure to set 
// __syscall_logger after this, because prepare_to_log_stacks() itself makes VM 
// allocations that we aren't prepared to log yet. 

所以我想你應該忽略它,除非你想調試內存分配。

爲了設置/取消malloc的調試環境,從項目工具欄中選擇編輯計劃...並進入診斷面板。

XCode Scheme Panel

+0

我還沒有啓用任何環境變量。如何禁用此日誌? – iSwift

+0

在您的XCode項目工具欄中,從下拉菜單中輸入* Edit Scheme ... *,選擇* Diagnostics *面板並檢查內存管理選項。 – lookaji

相關問題