230d2ae5e6
Before we've jitted the first bit of the TC, having so many threads leads to a pathological situation: we accept a bunch of requests (135) and have all of them running in the interpeter, starving the JIT thread that is trying to make them all go faster. (Perf record of a machine in this situation shows the vast majority of the time in dispatchImpl, SrcDB::find, and enterTC). This diff tries to solve this by limiting the number of threads to the number of cores for the first N requests.