mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: Fixes https://github.com/facebook/react-native/issues/27327 , we need to create autorelease pool for each run loop in secondary thread, otherwise application may have memory issues. More details can refer to [CreatingThreads](https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/Multithreading/CreatingThreads/CreatingThreads.html)  ## Changelog [iOS] [Fixed] - Add autorelease pool for each run loop for JS Thread Pull Request resolved: https://github.com/facebook/react-native/pull/27395 Test Plan: Example can be found in https://github.com/facebook/react-native/issues/27327. No memory spikes any more. Reviewed By: PeteTheHeat Differential Revision: D19132504 Pulled By: fkgozali fbshipit-source-id: d1747f27d36e9a7934966b34aa46d344e06193b3