mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
When the differentiating a function containing loops, we allocate a linear map context object on the heap. This context object may store non-trivial objects, such as closures, that need to be released explicitly. Fix the autodiff linear map context allocation builtins to correctly release such objects and not just free the memory they occupy.
3.9 KiB
3.9 KiB