Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
dcdb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
7
Issues
7
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
dcdb
dcdb
Commits
1e026fa8
Commit
1e026fa8
authored
Feb 21, 2020
by
Weronika
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
adding the PCIE troughput sensor to the nvml plugin
parent
22f19301
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
6 deletions
+19
-6
dcdbpusher/sensors/nvml/nvml.conf
dcdbpusher/sensors/nvml/nvml.conf
+5
-0
dcdbpusher/sensors/nvml/nvmlConfigurator.cpp
dcdbpusher/sensors/nvml/nvmlConfigurator.cpp
+1
-0
dcdbpusher/sensors/nvml/nvmlSensorBase.h
dcdbpusher/sensors/nvml/nvmlSensorBase.h
+8
-3
dcdbpusher/sensors/nvml/nvmlSensorGroup.cpp
dcdbpusher/sensors/nvml/nvmlSensorGroup.cpp
+5
-3
No files found.
dcdbpusher/sensors/nvml/nvml.conf
View file @
1e026fa8
...
...
@@ -101,6 +101,11 @@ group nvml_g2 {
feature
GPU_ECC_ERR
}
sensor
gpu_pcie_thru
{
mqttsuffix
/
pcie_thru
feature
GPU_PCIE_THRU
}
}
...
...
dcdbpusher/sensors/nvml/nvmlConfigurator.cpp
View file @
1e026fa8
...
...
@@ -46,6 +46,7 @@ nvmlConfigurator::nvmlConfigurator() {
_gpuFeatureMAP
[
"GPU_UTL_MEM"
]
=
GPU_UTL_MEM
;
_gpuFeatureMAP
[
"GPU_UTL_GPU"
]
=
GPU_UTL_GPU
;
_gpuFeatureMAP
[
"GPU_ECC_ERR"
]
=
GPU_ECC_ERR
;
_gpuFeatureMAP
[
"GPU_PCIE_THRU"
]
=
GPU_PCIE_THRU
;
_groupName
=
"group"
;
_baseName
=
"sensor"
;
...
...
dcdbpusher/sensors/nvml/nvmlSensorBase.h
View file @
1e026fa8
...
...
@@ -51,6 +51,8 @@ enum GPU_FEATURE {
GPU_UTL_MEM
=
10
,
GPU_UTL_GPU
=
11
,
GPU_ECC_ERR
=
13
,
GPU_PCIE_THRU
=
14
,
};
/**
...
...
@@ -142,9 +144,12 @@ class nvmlSensorBase : public SensorBase {
case
GPU_UTL_GPU
:
feature
=
"GPU_UTL_GPU"
;
break
;
case
GPU_ECC_ERR
:
feature
=
"GPU_ECC_ERR"
;
break
;
case
GPU_ECC_ERR
:
feature
=
"GPU_ECC_ERR"
;
break
;
case
GPU_PCIE_THRU
:
feature
=
"GPU_PCIE_THRU"
;
break
;
}
LOG_VAR
(
ll
)
<<
leading
<<
" Feature type: "
<<
feature
;
}
...
...
dcdbpusher/sensors/nvml/nvmlSensorGroup.cpp
View file @
1e026fa8
...
...
@@ -41,9 +41,6 @@ struct counters_t {
unsigned
long
long
energy_initial
;
unsigned
long
long
energy_current
;
unsigned
long
long
energy_previous
;
// unsigned int freq1;
// unsigned int freq2;
// unsigned int freq3;
unsigned
int
temperature
;
unsigned
int
fanspeed
;
unsigned
int
clockspeed_graphics
;
...
...
@@ -53,6 +50,7 @@ struct counters_t {
unsigned
int
power
;
unsigned
long
long
ecc_counts
;
nvmlUtilization_t
utilization
;
unsigned
int
pcie_throughput
;
}
counters
;
nvmlSensorGroup
::
nvmlSensorGroup
(
const
std
::
string
&
name
)
:
...
...
@@ -190,6 +188,10 @@ void nvmlSensorGroup::read() {
err
=
nvmlDeviceGetTotalEccErrors
(
env
.
device
,
NVML_MEMORY_ERROR_TYPE_CORRECTED
,
NVML_VOLATILE_ECC
,
&
(
counters
.
ecc_counts
));
reading
.
value
=
counters
.
ecc_counts
;
break
;
case
(
GPU_PCIE_THRU
):
err
=
nvmlDeviceGetPcieThroughput
(
env
.
device
,
NVML_PCIE_UTIL_COUNT
,
&
(
counters
.
pcie_throughput
));
reading
.
value
=
counters
.
pcie_throughput
;
break
;
}
s
->
storeReading
(
reading
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment