RPC Binder: avoid spinnning for partial chunked read
(issues spotted by fmayle@) I avoided calling poll on sockets, in order to try to avoid wasting a syscall in some cases. However, when we simulated a partial read (to avoid the kernel problems) and there was a partial read of that as well, it caused CPU spinning. Just poll every time. It works, and since there's no busy looping, it's actually much better. We're also planning on switching the default chunk size to be larger, so we'd never hit the 2 syscall case normally anymore. There is also a log added if a busy spin can happen again so it's more visible and this logic is quite complicated. Bug: 416772676 Test: binderRpcTest Flag: EXEMPT bugfix Change-Id: Ia2e6c70a5ec9efd762f7eefa9b8cc30479f395a3
Loading
Please register or sign in to comment