16k: core: Change default TARGET_MAX_PAGE_SIZE_SUPPORTED to 16384
Changing TARGET_MAX_PAGE_SIZE_SUPPORTED default from 65536 to 16384 as
this would reduce the ELF alignment for files and thereby also
decreasing the padding required. Although increased padding does not
result in increased disk space (due to holes), it increases file
metadata. Reducing ELF alignment also helps reduce page table memory as
it reduces number of memory pages utilized / virtual memory address
mappings.
Test: lunch <target> && get_build_var TARGET_MAX_PAGE_SIZE_SUPPORTED
Bug: 310232825
Change-Id: I7c6b1bb699fec8b8ecf49a0f06a79d89142e3a2b
diff --git a/core/config.mk b/core/config.mk
index d7516d3..c109b1c 100644
--- a/core/config.mk
+++ b/core/config.mk
@@ -413,7 +413,7 @@
# When VSR vendor API level >= 34, binary alignment will be 65536.
ifeq ($(call math_gt_or_eq,$(VSR_VENDOR_API_LEVEL),34),true)
ifeq ($(TARGET_ARCH),arm64)
- TARGET_MAX_PAGE_SIZE_SUPPORTED := 65536
+ TARGET_MAX_PAGE_SIZE_SUPPORTED := 16384
endif
endif
endif
@@ -432,8 +432,8 @@
ifdef PRODUCT_NO_BIONIC_PAGE_SIZE_MACRO
TARGET_NO_BIONIC_PAGE_SIZE_MACRO := $(PRODUCT_NO_BIONIC_PAGE_SIZE_MACRO)
ifeq ($(TARGET_NO_BIONIC_PAGE_SIZE_MACRO),true)
- ifneq ($(TARGET_MAX_PAGE_SIZE_SUPPORTED),65536)
- $(error TARGET_MAX_PAGE_SIZE_SUPPORTED has to be 65536 to support page size agnostic)
+ ifeq (,$(filter 16384 65536,$(TARGET_MAX_PAGE_SIZE_SUPPORTED)))
+ $(error TARGET_MAX_PAGE_SIZE_SUPPORTED has to be either 16384 or 65536 to support page size agnostic)
endif
endif
endif