Open zxldev opened 9 months ago
The choice between the two depends on whether you need the additional info that the v2 struct provides. Note that running GetLibrary().Lookup("nvmlDeviceGetMemoryInfo_v2")
should do what you wanted.
Note that because the function signatures are not equivalent, we cannot alias GetMemoryInfo
to the different versions based on availability.
When get memory information, how can I determine whether to use GetMemoryInfo_v2 or GetMemoryInfo?
Can the lib.Lookup() method be made public? This way, I can use lib.Lookup("nvmlDeviceGetMemoryInfo_v2") to check if v2 is supported.
or, mark it in Init method as public var,