Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: da8482b85ac12c72d6c7c08d8c7e791db6d8642e
      
https://github.com/WebKit/WebKit/commit/da8482b85ac12c72d6c7c08d8c7e791db6d8642e
  Author: Dan Hecht <[email protected]>
  Date:   2026-07-17 (Fri, 17 Jul 2026)

  Changed paths:
    M Source/bmalloc/libpas/src/test/AllocationZeroingTests.cpp

  Log Message:
  -----------
  [libpas] Verify large zeroed allocations under out-of-order page faults
https://bugs.webkit.org/show_bug.cgi?id=319621
rdar://182446375

Reviewed by Keith Miller.

The >= 1 MB zeroed path leaves pages zero-fill-on-demand (madvise(MADV_ZERO)
or the mmap fallback), so a page is only observed zero when first faulted.
The other tests read and write ascending, so they only ever fault pages in
ascending order -- but a hashtable, the workload where this matters, reads
its buckets in hash order, i.e. effectively at random.

Add a test that puts dirty data under a large region (allocate, dirty,
free), reallocates the same size so the zeroed path runs over that dirty
backing, then verifies the buffer reads zero while first-faulting its pages
in ascending, descending, and deterministically shuffled orders, under both
immediate free-list reuse and forced decommit/recommit, across the
threshold and a multi-megabyte size. The reused-buffer check and the shared
reuse case gain an optional FaultOrder parameter; the generic runs keep the
default ascending scan.

* Source/bmalloc/libpas/src/test/AllocationZeroingTests.cpp:
(addAllocationZeroingTests):

Canonical link: https://commits.webkit.org/317390@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to