StoreRules

Rules · Support 16 KB page sizes · Optimize custom memory allocators

Summary of recommendations

In plain words

If your app, engine or library uses a custom memory allocator, follow these recommendations for 16 KB page size devices; apps using the standard Android allocator (scudo) can skip them.

  • Purge thresholds: scale release thresholds dynamically using sysconf(_SC_PAGESIZE) to prevent release logic from permanently deadlocking.
  • Allocation order: allocate from the densest (almost full) page or slab first, reducing RSS by packing active objects together.
  • Span sizing: align size classes to 16 KB multiples and avoid oversized slabs to eliminate tail-page fragmentation and reduce slack.
  • Buffer caches: call madvise(MADV_DONTNEED) immediately when caching large buffers, avoiding idle RAM bloat while keeping fast virtual reuse.
  • Swap/ZRAM: zero out memory on free() instead of on allocation to improve ZRAM compression ratios.

Summary written by StoreRules and checked against the official text.

From the official text

| Area | Recommendation | Expected impact | | --- | --- | --- | | Purge thresholds | Scale release thresholds dynamically using sysconf(SCPAGESIZE). | Prevents release logic from permanently deadlocking. | | Allocation order | Allocate from the densest (almost full) page or slab first. | Reduces resident memory (RSS) …

Read the full official text ↗ Open in the StoreRules library Ask whether your app complies

Change history

No substantive change since StoreRules began tracking it.

First seen: 2026-10-16

Developers' cases about this clause

No cases yet.

Share your case