Page MenuHomeFreeBSD

Allocate arm64 per-CPU data in the correct domain
ClosedPublic

Authored by andrew on Oct 6 2021, 3:54 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Dec 11, 6:39 AM
Unknown Object (File)
Fri, Dec 5, 2:43 AM
Unknown Object (File)
Sun, Nov 23, 9:24 AM
Unknown Object (File)
Fri, Nov 21, 6:53 AM
Unknown Object (File)
Mon, Nov 17, 5:31 PM
Unknown Object (File)
Sat, Nov 15, 8:56 PM
Unknown Object (File)
Fri, Nov 14, 11:49 PM
Unknown Object (File)
Fri, Nov 14, 2:53 AM
Subscribers

Details

Summary

To minimise NUMA traffic allocate the pcpu, dpcpu, and boot stacks in
the correct domain when possible.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 42001
Build 38889: arc lint + arc unit

Event Timeline

andrew requested review of this revision.Oct 6 2021, 3:54 PM
sys/arm64/arm64/machdep.c
109

Isn't this the same as cpuid_to_pcpu[] now? Do we need __pcpu[] at all?

sys/arm64/arm64/mp_machdep.c
509
643

I think this probably deserves an XXX comment.

sys/arm64/arm64/mp_machdep.c
518

FWIW, there is no benefit to allocating domain-local boot stacks, they are used only in the window after the AP starts and before it switches to a thread.

sys/arm64/arm64/mp_machdep.c
518

I mostly did it for consistency.

markj added inline comments.
sys/arm64/arm64/machdep.c
1363

We assume that .bss is allocated from the domain to which the BSP belongs. That's probably true in practice though, at least amd64 makes a similar assumption when it allocates the pcpu area in pmap_bootstrap().

This revision is now accepted and ready to land.Oct 7 2021, 4:02 PM