Utilizing AMD GPUs with radeontop (with examples)

Utilizing AMD GPUs with radeontop (with examples)

Radeontop is a command-line tool that allows users to monitor and display the utilization of AMD GPUs. With its ability to provide real-time information about GPU usage, radeontop is a valuable tool for optimizing performance and troubleshooting issues related to AMD graphics cards. In this article, we will explore different use cases of the radeontop command, along with their respective code examples, motivations, explanations, and example outputs.

1: Show the utilization of the default AMD GPU

radeontop

Motivation:

By default, radeontop provides information on the default AMD GPU in the system. This can be useful for a quick overview of the GPU’s utilization, such as GPU core and memory usage, shader core activity, and GPU temperature.

Explanation:

The radeontop command without any arguments will display the utilization of the default AMD GPU in the system. It requires no additional parameters and can be executed directly in the command line.

Example Output:

RadeonTop 1.3.1 - 2018-07-08, Git revision 5235203 (clean)

GPU: 0
Frequencies:
	Core:		300MHz
	Memory:		150MHz
	Bus:		100MHz
	PCIe:		5000MT/s

Usage:
	Shader:		34.83%
	ROP:		39.34%
	SH:		45.53%
	SE:		37.32%

Temperature:		71C

2: Enable colored output

radeontop --color

Motivation:

Enabling colored output enhances the readability and visual appeal of the radeontop command’s display. It enables the utilization information to be presented with colors, making it easier to distinguish different components of the GPU utilization.

Explanation:

The --color option can be added to the radeontop command to enable colored output. Once enabled, various colors will be used to represent different GPU utilization metrics, such as shader, ROP, shader engine, and SE utilization.

Example Output:

Example Output for Enable colored output

3: Select a specific GPU

radeontop --bus bus_number

Motivation:

Sometimes, there might be multiple AMD GPUs installed in a system. In such cases, it is beneficial to have the flexibility to choose and monitor a specific GPU’s utilization. The ability to select a specific GPU allows for individual monitoring and troubleshooting of each GPU.

Explanation:

To select a specific GPU, the --bus option should be used with the bus_number argument. The bus_number corresponds to the bus number of the desired GPU as obtained from the output of the lspci command.

Example Output:

RadeonTop 1.3.1 - 2018-07-08, Git revision 5235203 (clean)

GPU: 1
Frequencies:
	Core:		300MHz
	Memory:		150MHz
	Bus:		100MHz
	PCIe:		5000MT/s

Usage:
	Shader:		64.21%
	ROP:		23.45%
	SH:		47.89%
	SE:		42.11%

Temperature:		67C

4: Specify the display refresh rate

radeontop --ticks samples_per_second

Motivation:

Adjusting the display refresh rate is important when monitoring GPU utilization in real-time. A higher refresh rate might provide more accurate and fine-grained information, but it also comes with additional GPU overhead. Balancing the refresh rate based on monitoring requirements ensures optimal performance and efficiency.

Explanation:

The --ticks option followed by the samples_per_second argument allows the user to specify the display refresh rate. The samples_per_second value determines how many times per second radeontop will update the utilization information.

Example Output:

RadeonTop 1.3.1 - 2018-07-08, Git revision 5235203 (clean)

GPU: 0
Frequencies:
	Core:		300MHz
	Memory:		150MHz
	Bus:		100MHz
	PCIe:		5000MT/s

Usage:
	Shader:		38.11%
	ROP:		21.79%
	SH:		46.67%
	SE:		36.88%

Temperature:		68C

By utilizing the various options and arguments provided by the radeontop command, users can gain valuable insights into the utilization of their AMD GPUs. Whether it’s monitoring the default GPU or selecting a specific device, enabling colored output, or adjusting the refresh rate, radeontop proves to be a versatile tool for optimizing and troubleshooting AMD graphics cards.

Related Posts

Manage Virtual Machines in Azure (with examples)

Manage Virtual Machines in Azure (with examples)

In this article, we will explore different use cases of the az vm command, which is part of the Azure Command-Line Interface (CLI).

Read More
How to use the command 'retroarch' (with examples)

How to use the command 'retroarch' (with examples)

RetroArch is a versatile frontend that allows users to run emulators, game engines, and media players.

Read More
How to use the command 'az apim' (with examples)

How to use the command 'az apim' (with examples)

This article provides examples on how to use the az apim command, which is used to manage Azure API Management services.

Read More