Google Solves One Of Chrome's Biggest Issues Using Windows 10's 'TerminateProcess'

Windows 10 Task Manager, Google Chrome

For many reasons, Google Chrome is the most popular web browser in the world. But despite that, it has numerous issues.

And one of the most prominent, is RAM use and instability. For almost all of its life, Chrome has been plagued with excessive memory hunger, and tends to gobble up every bit of available memory.

This is especially true when there are many tabs open at once.

Without enough memory and prolonged usage of Chrome with too many tabs open on Windows operating system on PCs, the web browser will soon become unresponsive and can eventually crash. Or worse, it can even render the who PC unresponsive as it hangs the whole computer system.

If the Windows managed to free up some memory, Chrome will quickly consume it again. And if users managed to close the many open tabs, Chrome can still leave some residual threaded processes that will still consume resources.

This could be really troublesome, especially when users are doing online tasks on one of the tabs.

Google has been working with Microsoft to seek ways for eliminating this particular issue, and it found that utilizing Windows 10's TerminateProcess feature could help.

In a Chromium post, Google said that it has been using TerminateProcess to help the browser exit processes cleanly, and with that, it "will avoid some utility-process crashes on Windows," and that "TerminateProcess has helped a lot in many process types already."

According to Microsoft on its documentation page, TerminateProcess is a function used to "unconditionally cause a process to exit."

By utilizing this function, Chrome should be able to quickly free up memory when tabs aren't anymore in use, making the browser to run more efficiently on Windows 10.

Google in using TerminateProcess in Chrome is certainly a welcome move.

Windows TerminateProcess.
Windows' TerminateProcess diagram.

The TerminateProcess function is often used in Windows to unconditionally terminate a specified process and all of its threads. The function will then notify each dynamic link libraries (DLLs) that the process is terminating.

Windows use this function mostly in extreme circumstances, simply because the function removed all objects that is currently handled by the app.

What this means, TerminateProcess forces Windows to start from plain zero if users want to start the app again.

Another way of saying it, the function allows Windows to close an app completely after users closed it, and preventing the app from running anything again in the background following the closure.

By doing this, Windows can quickly free up any system resources that an app has been gobbling up.

So making use of TerminateProcess, Google should make Chrome capable of closing a selection of tabs, or indeed the whole browser, and immediately get back the resources it was using.

As of the announcement, the use of the TerminateProcess function in Chrome is still being tested by Google.

Along with several other fixes, Chrome should turn from a resource hog into a leaner, more reliable browser.

Published: 
24/12/2020