How to remove GPU Process in Chrome

Updated post here: https://codeyarns.github.io/tech/2015-09-21-how-to-remove-gpu-process-in-chrome.html

How to monitor GPU

20150629_gpu_monitor

Monitoring the GPU and GPU memory (VRAM) utilization on Windows is easy. There are many general tools, including specific tools supplied by your GPU vendor (like MSI’s Afterburner or EVGA’s Precision). Sadly, there is not a single tool on Linux that can monitor your GPU and show as many stats in a convenient GUI.

The best solution I have found is to open NVIDIA X Server Settings. In the section about your GPU, you can monitor these values:

  • GPU utilization
  • Memory utilization
  • Temperature

Sadly, there is no graphing tools to view these values over time.

Tried with: NVIDIA driver 346.46 and Ubuntu 14.04

How to get GPU information

To get information about your NVIDIA GPU at the shell, try:

$ nvidia-smi

+------------------------------------------------------+                       
| NVIDIA-SMI 331.38     Driver Version: 331.38         |                       
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce 9600 GT     Off  | 0000:03:00.0     N/A |                  N/A |
|  0%   58C  N/A     N/A /  N/A |    386MiB /   511MiB |     N/A      Default |
+-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+
| Compute processes:                                               GPU Memory |
|  GPU       PID  Process name                                     Usage      |
|=============================================================================|
|    0            Not Supported                                               |
+-----------------------------------------------------------------------------+

This requires that you have the NVIDIA driver package installed.

If you do not have the driver installed, you can try:

$ lspci | grep VGA

03:00.0 VGA compatible controller: NVIDIA Corporation G94 [GeForce 9600 GT] (rev a1)

This lists the actual GPU being used in the graphics card. For example, G94 in the above graphics card.

To get detailed information about the card, use the domain ID number shown at the beginning of the line. For example:

$ lspci -v -s 03:00.0

03:00.0 VGA compatible controller: NVIDIA Corporation G94 [GeForce 9600 GT] (rev a1) (prog-if 00 [VGA controller])
    Subsystem: ASUSTeK Computer Inc. Device 827c
    Flags: bus master, fast devsel, latency 0, IRQ 63
    Memory at f6000000 (32-bit, non-prefetchable) [size=16M]
    Memory at d0000000 (64-bit, prefetchable) [size=256M]
    Memory at f4000000 (64-bit, non-prefetchable) [size=32M]
    I/O ports at cf00 [size=128]
    [virtual] Expansion ROM at f7000000 [disabled] [size=512K]
    Capabilities: <access denied>
    Kernel driver in use: nvidia

Notice that the GPU capabilities section is not displayed since that requires superuser privileges. To view the GPU capabilities:

$ sudo lspci -v -s 03:00.0

03:00.0 VGA compatible controller: NVIDIA Corporation G94 [GeForce 9600 GT] (rev a1) (prog-if 00 [VGA controller])
    Subsystem: ASUSTeK Computer Inc. Device 827c
    Flags: bus master, fast devsel, latency 0, IRQ 63
    Memory at f6000000 (32-bit, non-prefetchable) [size=16M]
    Memory at d0000000 (64-bit, prefetchable) [size=256M]
    Memory at f4000000 (64-bit, non-prefetchable) [size=32M]
    I/O ports at cf00 [size=128]
    [virtual] Expansion ROM at f7000000 [disabled] [size=512K]
    Capabilities: [60] Power Management version 3
    Capabilities: [68] MSI: Enable+ Count=1/1 Maskable- 64bit+
    Capabilities: [78] Express Endpoint, MSI 00
    Capabilities: [b4] Vendor Specific Information: Len=14 <?>
    Capabilities: [100] Virtual Channel
    Capabilities: [128] Power Budgeting <?>
    Capabilities: [600] Vendor Specific Information: ID=0001 Rev=1 Len=024 <?>
    Kernel driver in use: nvidia

Tried with: Ubuntu 14.04

How to enable full speed FP64 in NVIDIA GPU

In many recent NVIDIA GPUs shipping in graphics cards, the FP64 cores are executed at reduced speed. For example, the GTX Titan is capable of achieving a double performance that is 1/3 of float performance. However, by default the card does FP64 at a reduced speed of 1/24 of FP32. This is done because the primary audience of these consumer cards are gamers. And games use mostly FP32 computations. Enabling full speed FP64 reduces the FP32 performance by a bit since the maximum clock speed needs to be reduced and also increases power consumption since all the power hungry FP64 cores are running.

To enable full speed FP64 on Linux, make sure you have the latest NVIDIA drivers installed. Open the NVIDIA X Server Settings application. Go to the section with the name of your graphics card > PowerMizer and enable the CUDA - Double precision option. That is it, your CUDA application should now run with full speed FP64 on the GPU.

Tried with: NVIDIA GTX Titan, NVIDIA driver 319.37, CUDA 5.5 and Ubuntu 12.04 LTS

How to compare two CPUs or GPUs

There are now websites which offer performance comparison between any two CPUs or GPUs. The one I like is CPUBoss for CPU comparison and GPUBoss for GPU comparison. In either site, you can also find out information about an individual CPU or GPU by searching for its name in the top search box. You can also sort all the CPUs or GPUs by their performance or other metrics by using the Sort option at the top.

Where to find list of CUDA GPUs and compute capability

It used to be cumbersome to look for the NVIDIA GPUs which supported CUDA and to figure out which compute capability version they supported. You had to check one of the appendices of the CUDA Programming Guide.

NVIDIA has now put all that information online here: https://developer.nvidia.com/cuda-gpus

MSI Afterburner

 

One of the coolest things about using a graphics card from MSI is their MSI Afterburner application. It is primarily meant for overclocking, but I think its monitor GUI is the best out there for GPUs. The user can pick the data he wants to be monitored (temperature, clock, memory usage and many more). These are displayed in real-time much like a heart-rate monitor. The values on the right show the current value, while hovering the mouse over any part of the graph shows the value at that time. The polling period can be adjusted and this application supports the smallest polling periods I have seen.

Tried with: MSI Afterburner 2.1.0 on a NVIDIA GTX 580