A Not-Called Function Can Cause a 5X Slowdown
This bug is fixed in the latest insider builds at least.<p>Using the author&#x27;s own testing tool:<p>With the Spring 2018 release:<p><pre><code>    F:\tmp&gt;.\ProcessCreatetests.exe
    Main process pid is 46940.
    Testing with 1000 descendant processes.
    Process creation took 2.309 s (2.309 ms per process).
    Lock blocked for 0.003 s total, maximum was 0.000 s.
    Average block time was 0.000 s.

    Process termination starts now.
    Process destruction took 0.656 s (0.656 ms per process).
    Lock blocked for 0.001 s total, maximum was 0.000 s.
    Average block time was 0.000 s.

    Elapsed uptime is 7.08 days.
    Awake uptime is 7.08 days.

    F:\tmp&gt;.\ProcessCreatetests.exe -user32
    Main process pid is 44584.
    Testing with 1000 descendant processes with user32.dll loaded.
    Process creation took 2.624 s (2.624 ms per process).
    Lock blocked for 0.014 s total, maximum was 0.001 s.
    Average block time was 0.000 s.

    Process termination starts now.
    Process destruction took 1.617 s (1.617 ms per process).
    Lock blocked for 1.122 s total, maximum was 0.648 s.
    Average block time was 0.026 s.

    Elapsed uptime is 7.08 days.
    Awake uptime is 7.08 days.
</code></pre>
With an insider build:<p><pre><code>    C:\tmp&gt;.\ProcessCreatetests.exe
    Main process pid is 9928.
    Testing with 1000 descendant processes.
    Process creation took 2.440 s (2.440 ms per process).
    Lock blocked for 0.003 s total, maximum was 0.002 s.
    Average block time was 0.000 s.

    Process termination starts now.
    Process destruction took 1.306 s (1.306 ms per process).
    Lock blocked for 0.003 s total, maximum was 0.001 s.
    Average block time was 0.000 s.

    Elapsed uptime is 4.78 days.
    Awake uptime is 3.93 days.

    C:\tmp&gt;.\ProcessCreatetests.exe -user32
    Main process pid is 14144.
    Testing with 1000 descendant processes with user32.dll loaded.
    Process creation took 4.756 s (4.756 ms per process).
    Lock blocked for 0.022 s total, maximum was 0.004 s.
    Average block time was 0.000 s.

    Process termination starts now.
    Process destruction took 1.823 s (1.823 ms per process).
    Lock blocked for 0.003 s total, maximum was 0.001 s.
    Average block time was 0.000 s.

    Elapsed uptime is 4.78 days.
    Awake uptime is 3.93 days.

</code></pre>
There&#x27;s no longer a difference in lock blocked time whether or not you load user32 during process destruction. Nor does the very obvious mouse stuttering still happen.