poll more efficiently in Subprocess::waitTimeout
Summary: Unconditionally sleeping for 100ms in the wait polling loop has high average latency. If a process exits just after the initial wait() call, it's better to poll again sooner. Start with a 2ms sleep and double it every sleep, capping out at 100ms. Reviewed By: yfeldblum, mzhaom Differential Revision: D17769851 fbshipit-source-id: efec8fdb8c2199b8db29b46b8c43fdaac56f69a8
Showing
Please register or sign in to comment