Skip to content

GpaGetDataTypeAsStr

Copyright (c) 2018-2024 Advanced Micro Devices, Inc. All rights reserved.

Syntax

GpaStatus GpaGetDataTypeAsStr(
GpaDataType counter_data_type,
const char** type_str);

Description

Gets a string representation of the specified counter data type. This could be used to display counter types along with their name or value. For example the kGpaDataTypeUint64 counter_data_type would return gpa_uint64.

Parameters

NameDescription
counter_data_typeThe data type whose string representation is needed.
type_strThe address which will hold the string representation upon successful execution.

Return value

Return valueDescription
kGpaStatusOkThe string representation was successfully retrieved.
kGpaStatusErrorGpaNotInitializedGPA was not initialized. Call GpaInitialize before all other entrypoints.
kGpaStatusErrorNullPointerThe supplied type_str parameter is NULL.
kGpaStatusErrorInvalidParameterThe counter_data_type parameter has an invalid value.
kGpaStatusErrorExceptionException occurred.