Page MenuHomeFreeBSD

libc/aarch64: Add memset for a 64 byte dc zva
ClosedPublic

Authored by andrew on Jan 19 2026, 12:18 PM.
Tags
None
Referenced Files
F145635331: D54776.id170036.diff
Sun, Feb 22, 11:22 AM
F145635321: D54776.id170036.diff
Sun, Feb 22, 11:22 AM
Unknown Object (File)
Sun, Feb 22, 12:28 AM
Unknown Object (File)
Sat, Feb 21, 10:33 AM
Unknown Object (File)
Tue, Feb 17, 9:28 PM
Unknown Object (File)
Mon, Feb 16, 5:27 PM
Unknown Object (File)
Sun, Feb 8, 7:39 AM
Unknown Object (File)
Fri, Jan 30, 9:03 PM
Subscribers

Details

Summary

On arm64 we can use the "dc zva" instruction to zero memory. The CPU
tells software if the instruction is implemented, and if so the size
and alignment it will use.

When the size is 64-bytes the Arm Optimized Routines implementation of
memset can use dc zva to zero memory, and has a build flag to skip
checking.

Use this flag to build a version of memset that will be used when this
assumption is true.

Sponsored by: Arm Ltd

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable