title: .Net 4 constantly wasting one CPU core on StrongNameSignatureVerification
body: <p>We have a mixed mode assembly application (MFC+WinForms) running on .Net 4, Windows 2008 R2 that constantly uses 100% cpu on one thread.   </p>
  
  <p>Using ProcessExplorer we see the following stack on the busy thread.  We can also see another 10 threads using just 0.01% CPU that are running clr.dll!StrongNameSignatureVerification.  </p>
  
  <p>The spinning thread doesn't prevent the rest of the application from running but wastes CPU time.</p>
  
  <p>The stack trace of the busy thread is as follows:</p>
  
  <pre><code>ntoskrnl.exe!IoAcquireRemoveLockEx+0xe7
  ntoskrnl.exe!memset+0x22a
  ntoskrnl.exe!KeWaitForSingleObject+0x2cb
  ntoskrnl.exe!KeDetachProcess+0x120d
  ntoskrnl.exe!PsReturnProcessNonPagedPoolQuota+0x3a3
  ntoskrnl.exe!CcSetDirtyPinnedData+0x433
  mscorlib.ni.dll+0x2b066a
  mscorlib.ni.dll+0x2317ac
  mscorlib.ni.dll+0x2b066a
  mscorlib.ni.dll+0x2317ac
  mscorlib.ni.dll+0x26ccf7
  mscorlib.ni.dll+0x237fc4
  mscorlib.ni.dll+0x26cc3c
  clr.dll+0x21bb
  clr.dll!CoUninitializeEE+0xee9b
  clr.dll!CoUninitializeEE+0x11463
  clr.dll!CoUninitializeEE+0x114dc
  clr.dll!CoUninitializeEE+0x1154b
  clr.dll!StrongNameErrorInfo+0xa638
  clr.dll!StrongNameSignatureVerification+0x144fb
  clr.dll!StrongNameSignatureVerification+0x1457d
  clr.dll!StrongNameSignatureVerification+0x14638
  clr.dll!StrongNameSignatureVerification+0x146d2
  clr.dll!StrongNameErrorInfo+0x9977
  clr.dll!StrongNameErrorInfo+0xa5bc
  clr.dll!StrongNameErrorInfo+0xa553
  clr.dll!StrongNameErrorInfo+0xa517
  clr.dll!StrongNameErrorInfo+0xa151
  clr.dll!StrongNameErrorInfo+0x9501
  clr.dll!StrongNameErrorInfo+0xad67
  clr.dll!StrongNameSignatureVerification+0x164d9
  ntdll.dll!RtlCreateUserProcess+0x8c
  ntdll.dll!RtlCreateProcessParameters+0x4e
  </code></pre>
  
  <p>The only similar account I've been able to find is in this question: <a href="https://stackoverflow.com/questions/7303315/clr-sllstrongnamesignatureverification-cpu-consumption">clr.sll!StrongNameSignatureVerification CPU consumption</a> though the thread seems to have gone cold.</p>
  
  <p>We don't sign our assemblies and are willing to trust them, is there a way to completely disable the strong name verification?</p>