Skip to content

test(heapStats-mimalloc): read VM tags from the kernel instead of vmmap labels - #40044

Merged
dylan-conway merged 2 commits into
mainfrom
farm/f9e78114/heapstats-vmtag-mach-vm-region
Aug 23, 2026
Merged

dylan-conway merged 2 commits into
mainfrom
farm/f9e78114/heapstats-vmtag-mach-vm-region

test(heapStats-mimalloc): read VM tags from the kernel instead of vmm…

a0fceef
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Aug 22, 2026 in 13m 11s

Code review found 1 potential issue

Found 1 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 1
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit test/js/bun/jsc/heapStats-mimalloc.test.ts:87 VM_REGION_EXTENDED_INFO_COUNT should be 9, not 10

Annotations

Check warning on line 87 in test/js/bun/jsc/heapStats-mimalloc.test.ts

See this annotation in the file changed.

@claude claude / Claude Code Review

VM_REGION_EXTENDED_INFO_COUNT should be 9, not 10

`VM_REGION_EXTENDED_INFO_COUNT` is 9 in xnu's `<mach/vm_region.h>` (`sizeof(vm_region_extended_info_data_t)/sizeof(natural_t)` = 36/4), not 10. Functionally harmless — the kernel only rejects `*count < 9` and the `info` buffer is 16 u32s — but a constant named exactly after the header macro that carries a different value will make the next reader wonder if there's a newer struct revision. Suggest `9`, or pass `info.length` to make the over-provisioning explicit rather than looking like a tra