High CPU usage and application is lagging

Viewed 35

I am trying to troubleshoot a issue in the customer site. This application mainly is fetching some data from the DB , and reading some registry settings.

But this exe is using almost 13% of CPU ( total 32GB RAM ) and causing the latency like it is taking almost ~3 mins to send the response { In other sites it completes within seconds with same amount of data in the DB , and CPU usage is very less } But this is happening in only one customer site , all the other sites which are having the same version is not having any issues .

I got the trace from process explorer looks like "mscorlib" is taking time while it is reading the registry.

AcLayers.DLL!NotifyShims+0x19fb
AcLayers.DLL!NotifyShims+0x22df
AcLayers.DLL!NotifyShims+0x12df7
AcLayers.DLL!NotifyShims+0xe92
[Native Frame: IL Method without Metadata]
[Managed to Unmanaged Transition]
C:\Windows\Microsoft.Net\assembly\GAC_64\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll!Microsoft.Win32.RegistryKey.OpenSubKey+0x8f
C:\Program Files\...\xxxxx.EXE!xx.modMLAcommon.GetRegistrySetting+0xf5
C:\Program Files\...\xxxxx.EXE!xxx.modMLAcommon.IsDiagnosticMode+0x47
C:\Program Files\...\xxxxx.EXE!xxx.ReplaceXMLtag+0x54c

What could cause the delay while reading the registry ? That too only in one site , because there are many other sites which has the same exe and still it is reading quickly.

My question might be bit vague , because all other possible things i tried and compared like the .NET version , windows pathes . And i also confirmed the this delay is not beacuse of no of records in DB , from the call stack it is pretty much clear that every time it is taking time while reading the registry.

Framework for EXE : .NET 4.7.1

Language : VB.NET

Class used for reading the registry : RegistryKey (Namespace Microsoft.Win32)

mscorlib dll version : 4.7.3946.0

0 Answers
Related