Replace malloc_not_svelte with malloc_low_memory.
The malloc_not_svelte variable name is confusing and makes the low memory config the default. Change this so that the default is the regular allocator, and that Malloc_low_memory is used to enable the low memory allocator. Update blueprint rules so that scudo is the default action. Test: Verified scudo config is used by default. Test: Verfified Android GO config uses the jemalloc low memory config. Change-Id: Ie7b4b005a6377e2a031bbae979d66b50c8b3bcdb
This commit is contained in:
parent
6f7fb5a0b5
commit
1c46a00865
3 changed files with 18 additions and 5 deletions
|
@ -240,11 +240,16 @@ cc_library_static {
|
|||
"libdebuggerd/backtrace.cpp",
|
||||
"libdebuggerd/gwp_asan.cpp",
|
||||
"libdebuggerd/open_files_list.cpp",
|
||||
"libdebuggerd/scudo.cpp",
|
||||
"libdebuggerd/tombstone.cpp",
|
||||
"libdebuggerd/tombstone_proto.cpp",
|
||||
"libdebuggerd/utility.cpp",
|
||||
],
|
||||
|
||||
cflags: [
|
||||
"-DUSE_SCUDO",
|
||||
],
|
||||
|
||||
local_include_dirs: ["libdebuggerd/include"],
|
||||
export_include_dirs: ["libdebuggerd/include"],
|
||||
|
||||
|
@ -256,6 +261,7 @@ cc_library_static {
|
|||
"bionic_libc_platform_headers",
|
||||
"gwp_asan_headers",
|
||||
"liblog_headers",
|
||||
"scudo_headers",
|
||||
],
|
||||
|
||||
static_libs: [
|
||||
|
@ -273,6 +279,7 @@ cc_library_static {
|
|||
"libtombstone_proto",
|
||||
"libprocinfo",
|
||||
"libprotobuf-cpp-lite",
|
||||
"libscudo",
|
||||
],
|
||||
|
||||
target: {
|
||||
|
@ -312,11 +319,9 @@ cc_library_static {
|
|||
cflags: ["-DROOT_POSSIBLE"],
|
||||
},
|
||||
|
||||
malloc_not_svelte: {
|
||||
cflags: ["-DUSE_SCUDO"],
|
||||
whole_static_libs: ["libscudo"],
|
||||
srcs: ["libdebuggerd/scudo.cpp"],
|
||||
header_libs: ["scudo_headers"],
|
||||
malloc_low_memory: {
|
||||
cflags: ["-UUSE_SCUDO"],
|
||||
exclude_static_libs: ["libscudo"],
|
||||
},
|
||||
},
|
||||
apex_available: [
|
||||
|
|
|
@ -16,6 +16,8 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#if defined(USE_SCUDO)
|
||||
|
||||
#include "types.h"
|
||||
#include "utility.h"
|
||||
|
||||
|
@ -49,3 +51,5 @@ class ScudoCrashData {
|
|||
void FillInCause(Cause* cause, const scudo_error_report* report,
|
||||
unwindstack::AndroidUnwinder* unwinder) const;
|
||||
};
|
||||
|
||||
#endif // USE_SCUDO
|
||||
|
|
|
@ -14,6 +14,8 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#if defined(USE_SCUDO)
|
||||
|
||||
#include "libdebuggerd/scudo.h"
|
||||
#include "libdebuggerd/tombstone.h"
|
||||
|
||||
|
@ -141,3 +143,5 @@ void ScudoCrashData::AddCauseProtos(Tombstone* tombstone,
|
|||
FillInCause(tombstone->add_causes(), &error_info_.reports[report_num++], unwinder);
|
||||
}
|
||||
}
|
||||
|
||||
#endif // USE_SCUDO
|
||||
|
|
Loading…
Reference in a new issue