[all-commits] [llvm/llvm-project] 5a1525: [scudo][standalone] Precommit pages

ChiaHungDuan via All-commits all-commits at lists.llvm.org
Tue Dec 20 09:40:50 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 5a1525c57635f3633e069c23f20ca12fe92ecced
      https://github.com/llvm/llvm-project/commit/5a1525c57635f3633e069c23f20ca12fe92ecced
  Author: Yaneury Fermin <yaneury at google.com>
  Date:   2022-12-20 (Tue, 20 Dec 2022)

  Changed paths:
    M compiler-rt/lib/scudo/standalone/common.h
    M compiler-rt/lib/scudo/standalone/fuchsia.cpp
    M compiler-rt/lib/scudo/standalone/release.h

  Log Message:
  -----------
  [scudo][standalone] Precommit pages

On Fuchsia, this CL changes garbage collection
to precommit all pages if the |Buffer| doesn't
fit into the static buffer size.

A test program (scudotest) was used that deliberately
grows a size class high water mark to the point where
the pre-allocated static buffer is no longer used for
garbage collection.

Traces showed that precommiting the Vmar removes ~30 page faults
and ~.22ms of wall time.*

Before: https://ui.perfetto.dev/#!/?s=7da19fc3f59448eef51fd6fd03283bb87b702cf1a565bcbe6c9c28371671
After: https://ui.perfetto.dev/#!/?s=97707cd99b2c9efd1e6569b2deb97e3d16f8be532c59a0cc12463c37fbb1d8

*: Use the added `zx_vmar_op_range` as a reference point to observe
the differences.

For more context, see https://fxbug.dev/115594.

Reviewed By: Chia-hungDuan

Differential Revision: https://reviews.llvm.org/D140320




More information about the All-commits mailing list