ffi.from_buffer causing performance problems with TLS/HTTP and PyPy3.7 7.34
We are still digging into our performance issues with the move to PyPy3.7.
Our service makes frequent HTTP calls over a persistent TLS connection.
When we run vmprof on the service against PyPy2.7-7.3.4 we see less than 1% of the time is spent reading the status from the HTTP response. On PyPy3.7-7.3.4, the exact same code spends over 15% of the total runtime doing the same thing. CPython3.6 does not show this issue.
I have tried walking the library code, but I don't see any smoking guns.
I have attached vmprof runs, in case that helps. Both runs had similar load and were sampled for several minutes after letting the jit warm up.
Compare the time spent in "_read_status" for pypy2 and pypy3.
As noted in a comment below, I determined that most of cpu time of the
read_status is spent in