Commit 16d148e
committed
feat(quinn-udp): add runtime probe for Apple fast datapath APIs
Add a fork-based runtime probe to safely detect availability of private
Apple `sendmsg_x`/`recvmsg_x` APIs before using them. These APIs may
crash on unsupported OS versions, so the probe tests them in a child
process and falls back to standard `sendmsg`/`recvmsg` if unavailable.
Key changes:
- Add `probe` module that forks a child to test API availability
- Cache probe result in `OnceLock` for process lifetime
- Split fast path (`send_via_sendmsg_x`/`recv_via_recvmsg_x`) from
slow path (`send_single`/`recv_single`) for runtime dispatch
- Add `prepare_msg_x`/`prepare_recv_x` for `msghdr_x` preparation1 parent e51c2d6 commit 16d148e
1 file changed
+387
-86
lines changed
0 commit comments