mirror of
https://github.com/apple/swift-nio
synced 2026-11-25 04:47:49 +00:00
Motivation: Unfortunately, closure composition is really expensive: closures that capture closures always heap allocate. To make ELF.Isolated perform well, then, we need to inline the method bodies directly. Modifications: - Add some isolated functions into ELF for enqueueing callbacks. - Inline the implementation of the ELF methods into the isolated view. Result: Allocation counts match between isolated/nonisolated.