Skip to content

Commit 6d19e5c

Browse files
committed
Revert "raise class region size to 32GB for arm64 Android"
This reverts commit b5dd9d1.
1 parent 749640c commit 6d19e5c

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

Android.bp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ common_cflags = [
2626
"-DREGION_QUARANTINE_QUEUE_LENGTH=1024",
2727
"-DREGION_QUARANTINE_SKIP_THRESHOLD=33554432", // 32MiB
2828
"-DFREE_SLABS_QUARANTINE_RANDOM_LENGTH=32",
29-
"-DCONFIG_CLASS_REGION_SIZE=34359738368", // 32GiB
3029
"-DN_ARENA=1",
3130
"-DCONFIG_STATS=true",
3231
"-DCONFIG_SELF_INIT=false",
@@ -36,6 +35,14 @@ cc_defaults {
3635
name: "hardened_malloc_defaults",
3736
defaults: ["linux_bionic_supported"],
3837
cflags: common_cflags,
38+
arch: {
39+
arm64: {
40+
cflags: ["-DCONFIG_CLASS_REGION_SIZE=2147483648"] // 2GiB
41+
},
42+
x86_64: {
43+
cflags: ["-DCONFIG_CLASS_REGION_SIZE=34359738368"] // 32GiB
44+
},
45+
},
3946
conlyflags: ["-std=c17", "-Wmissing-prototypes"],
4047
stl: "none",
4148
}

0 commit comments

Comments
 (0)