Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Add question

You must login to ask question.

Login

Register Now

APPSeCONNECT community provides a new way for integration super heros connect the external world. Join hands together to build a community of people to help each other, solve problems or share knowledge.

Relationship of Graphics Card with Agent

Relationship of Graphics Card with Agent

Recently, we have seen an issue where an user is facing high CPU usage when our APPSeCONNECT agent is opened. We have investigated further and found the CPU utilization increases when a complex page of the agent is opened. Such a case is purely an issue with Graphics driver in the environment. In this article, we will see what are the processes which can help in reducing or removing this kind of issues on your system.

Symptoms

You are getting high CPU usage whenever you open the agent tool. If you open your task manager, you see the CPU utilization of “InSync.appseconnect.AppStarter.exe” is constantly at a CPU percentage higher than 20%.  Remember, the article will help you only if the CPU utilization is constantly at a higher rate rather than sudden spikes.

Cause

There could be a number of reasons for this to happen.

  1. Graphics driver is not updated, and certain security patch installed in the server from Windows require you to upgrade your graphics driver.
  2. You are using hardware acceleration, but your graphics card is not perfectly offloading the user interface rendering to GPU and it uses CPU completely.

Why this happens?

In order to obtain GPU-accelerated rendering, our Agent renders and presents graphics through the DirectX pipeline. The GPU, or Graphics Processing Unit, is the chip that powers your video card. Essentially, hardware acceleration offloads the work of rendering graphics in the application from your computer’s main processor (CPU) to the video card’s processor (GPU). By using hardware on your video card that is specifically designed for rendering graphics instead of software functions run by the CPU, the performance of your application’s graphics and user interface is increased, or accelerated. The ultimate goal is that complex graphics routines become render-bound (that is, limited by the capabilities of the GPU), rather than processor-bound (that is, limited by the capabilities and speed of your computer’s CPU). This frees up the CPU to do other work, makes the best use of your video card’s unique graphics capabilities, and speeds up the performance of your app each time the user upgrades to a newer, faster, and more advanced video card (as they become available).

This, of course, assumes that your video card supports hardware acceleration. In fact, not all of them do, and the application accommodates this with a three-tiered approach:

  1. If your video card does not provide any level of hardware acceleration, such as if you’re running a version of DirectX less than 7.0, the application falls back to Tier 0 rendering mode, or software acceleration.
  2. If your video card supports partial hardware acceleration, such as if you’re running a version of DirectX between 7.0 and 9.0, then the application uses Tier 1 rendering mode.
  3. If your video card supports full hardware acceleration for all graphics output, corresponding to a version of DirectX equal or greater than 9.0, then the application uses Tier 2 rendering mode.

The application is intelligent enough to fall back to different tiers depending on either DirectX version or graphics card drivers. But sometimes the process does not work perfectly, which causes the system to fail the offloading work from GPU to CPU and then it processes in CPU entirely.

What are the Solutions?

There are a number of solutions to the problem, and I am trying to get into the scenarios one by one.

Update / Reinstall Graphics Drivers

Graphics drivers are one of the primary reason of such an issue. If you see when you open complex user interface the CPU utilization increases, that means clearly the graphics driver is not working well. To update the graphics driver, ask your system admin to see what graphics card installed in the system and upgrade. If your system admin tells you that there is no GPU installed, it would be nice to disable Hardware acceleration, such that the rendering engine does not go to the fallback mechanism and does everything in CPU at the first place. In such scenarios, there will be a rise in CPU usage when you keep Agent open.

Identify whether drivers are updated

  • Navigate to Start > Control Panel.
  • Click Device Manager.
  • Find the Display Adapter section and expand.
  • Right-click Intel® Display Adapter and select Properties.
  • Go to the Driver tab and you should see your driver version.

If you see the driver versions correctly, that means the driver is installed.

Identify whether DirectX is having issues

  • Start > Run (or Windows+ R)
  • Type DxDiag in the Run Window.
  • Press Enter.
  • Navigate to the tab listed as Display 1.
  • The driver version is listed under the Driver section as Version.

If driver version is listed, then the DirectX is working correctly.

Disable Hardware acceleration and check if issue persists

Sometimes these offloading of CPU to GPU fails because of graphics driver is not responding at certain point of time in such cases, we recommend to disable hardware  acceleration such that entire thing works in software rendering.

To disable graphics hardware acceleration:

  • Choose Start > Control Panel.
  • Double-click Display.
  • Click the Settings tab.
  • Click Advanced.
  • Click the Troubleshoot tab.
  • Move the Hardware Acceleration slider to None.
  • Click Apply and then click OK to accept the new setting and close the dialog box
  • Click OK to close the Display Properties dialog box.
  • Restart Windows.

You can also choose the registry to do the same thing.

  • Press the Windows Logo key + R to open a Run dialog.
  • Type regedit into the Run dialog and press Enter to open the Registry Editor.
  • In the left pane of the Registry Editor, navigate to the following directory:

HKEY_CURRENT_USER > Software > Microsoft

  • In the right pane of the Registry Editor, click on the Graphic sub-key under the Microsoft key to having its contents displayed in the right pane.
  • In the right pane of the Registry Editor, check to see if a DWORD value titled DisableHWAcceleration exists. If the DWORD value exists, it will probably have a value of 0. Simply double-click on it to modify it, replace whatever is in its Value data: field with 1, and click on OK.
    If the DisableHWAcceleration value does not exist, right-click on an empty space in the right pane of the Registry Editor, hover over New and click on DWORD (32-bit) value, name the new DWORD value DisableHWAcceleration, double-click on the newly created value to modify it, replace whatever is in its Value data: field with 1 and click on OK.
  • Close the Registry Editor.
  • Restart your computer to have the changes you made take effect.

 

If you see any discrepancies or you see the problem is fixed after disabling hardware acceleration, you should be certain that the issue happened only because of graphics card issue.

 

Conclusion

Thus to encounter such problems, first you need investigation, then you can be certain what was causing the issue. Do let us know your issues in comments such that we can discover more use cases of high CPU usages.

Hope this helps.

About Abhishek SurVerifiedBeginner

VP, Products at InSync Abhishek Sur has been a Microsoft MVP since 2011. He is currently working as a Product Head with Insync Tech-Fin Solutions Pvt Ltd. He has profound theoretical insight and years of hands-on experience in different .NET products and languages. Over the years, he has helped developers throughout the world with his experience and knowledge. He owns a Microsoft User Group in Kolkata named Kolkata Geeks and regularly organizes events and seminars in various places to spread .NET awareness. A renowned public speaker, voracious reader, and technology buff, Abhishek's main interest lies in exploring the new realms of .NET technology and coming up with priceless write-ups on the unexplored domains of .NET. He is associated with Microsoft's Insider list on WPF and C# and stays in touch with Product Group teams. He holds a Master's degree in Computer Application along with various other certificates to his credit. Abhishek is a freelance content producer, developer, and site administrator. His website www.abhisheksur.com guides both budding and experienced developers in understanding the details of languages and latest technologies. He has a huge fan following on social networks. You can reach him at books@abhisheksur.com, get online updates from his Facebook account, or follow him on Twitter @abhi2434.

Follow Me

Leave a reply

Share via
Copy link
Powered by Social Snap