Skip to content

Commit

Permalink
add warning when set memory limits valide is pre-volta arch
Browse files Browse the repository at this point in the history
Signed-off-by: rongfu.leng <rongfu.leng@daocloud.io>
  • Loading branch information
lengrongfu committed Oct 2, 2024
1 parent 37d2609 commit 5978161
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/mps-control-daemon/mps/daemon.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,10 @@ func (m *Daemon) perDevicePinnedDeviceMemoryLimits() map[string]string {
totalMemoryInBytesPerDevice := make(map[string]uint64)
replicasPerDevice := make(map[string]uint64)
for _, device := range m.Devices() {
if isVoltaDevice := (*mpsDevice)(device).isAtLeastVolta(); !isVoltaDevice {
klog.Warningf("Skipping memory limits for pre-volta device %s", device.ID)
continue
}
index := device.Index
totalMemoryInBytesPerDevice[index] = device.TotalMemory
replicasPerDevice[index] += 1
Expand Down

0 comments on commit 5978161

Please sign in to comment.