fix: sealing: Make lotus-worker report GPU usage to miner during ReplicaUpdate task (#10806)

* Make lotus-worker report GPU usage to miner during ReplicaUpdate task

* make gen

---------

Co-authored-by: Jacob Crowther <jcrowthe@users.noreply.github.com>
This commit is contained in:
Shrenuj Bansal 2023-05-03 12:28:03 -04:00 committed by GitHub
parent a3a429edad
commit 78800a4e77
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 65 additions and 58 deletions

Binary file not shown.

Binary file not shown.

View File

@ -5208,7 +5208,7 @@ Response:
"0": { "0": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -5217,7 +5217,7 @@ Response:
"1": { "1": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -5226,7 +5226,7 @@ Response:
"2": { "2": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -5235,25 +5235,25 @@ Response:
"3": { "3": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"4": { "4": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"5": { "5": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -5262,7 +5262,7 @@ Response:
"6": { "6": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -5271,7 +5271,7 @@ Response:
"7": { "7": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -5280,18 +5280,18 @@ Response:
"8": { "8": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"9": { "9": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
} }
@ -5300,7 +5300,7 @@ Response:
"0": { "0": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -5309,7 +5309,7 @@ Response:
"1": { "1": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -5318,7 +5318,7 @@ Response:
"2": { "2": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -5327,25 +5327,25 @@ Response:
"3": { "3": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"4": { "4": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"5": { "5": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -5354,7 +5354,7 @@ Response:
"6": { "6": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -5363,7 +5363,7 @@ Response:
"7": { "7": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -5372,18 +5372,18 @@ Response:
"8": { "8": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"9": { "9": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
} }

View File

@ -1135,7 +1135,7 @@ Response:
"0": { "0": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -1144,7 +1144,7 @@ Response:
"1": { "1": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -1153,7 +1153,7 @@ Response:
"2": { "2": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -1162,25 +1162,25 @@ Response:
"3": { "3": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"4": { "4": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"5": { "5": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -1189,7 +1189,7 @@ Response:
"6": { "6": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -1198,7 +1198,7 @@ Response:
"7": { "7": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -1207,18 +1207,18 @@ Response:
"8": { "8": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"9": { "9": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
} }
@ -1227,7 +1227,7 @@ Response:
"0": { "0": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -1236,7 +1236,7 @@ Response:
"1": { "1": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -1245,7 +1245,7 @@ Response:
"2": { "2": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -1254,25 +1254,25 @@ Response:
"3": { "3": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"4": { "4": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"5": { "5": {
"MinMemory": 2048, "MinMemory": 2048,
"MaxMemory": 2048, "MaxMemory": 2048,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 2048, "BaseMinMemory": 2048,
@ -1281,7 +1281,7 @@ Response:
"6": { "6": {
"MinMemory": 8388608, "MinMemory": 8388608,
"MaxMemory": 8388608, "MaxMemory": 8388608,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 8388608, "BaseMinMemory": 8388608,
@ -1290,7 +1290,7 @@ Response:
"7": { "7": {
"MinMemory": 1073741824, "MinMemory": 1073741824,
"MaxMemory": 1073741824, "MaxMemory": 1073741824,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 0,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
@ -1299,18 +1299,18 @@ Response:
"8": { "8": {
"MinMemory": 4294967296, "MinMemory": 4294967296,
"MaxMemory": 4294967296, "MaxMemory": 4294967296,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
}, },
"9": { "9": {
"MinMemory": 8589934592, "MinMemory": 8589934592,
"MaxMemory": 8589934592, "MaxMemory": 8589934592,
"GPUUtilization": 0, "GPUUtilization": 1,
"MaxParallelism": 1, "MaxParallelism": 1,
"MaxParallelismGPU": 0, "MaxParallelismGPU": 6,
"BaseMinMemory": 1073741824, "BaseMinMemory": 1073741824,
"MaxConcurrent": 0 "MaxConcurrent": 0
} }

View File

@ -342,7 +342,9 @@ var ResourceTable = map[sealtasks.TaskType]map[abi.RegisteredSealProof]Resources
MaxMemory: 8 << 30, MaxMemory: 8 << 30,
MinMemory: 8 << 30, MinMemory: 8 << 30,
MaxParallelism: 1, MaxParallelism: 1,
MaxParallelismGPU: 6,
GPUUtilization: 1.0,
BaseMinMemory: 1 << 30, BaseMinMemory: 1 << 30,
}, },
@ -350,7 +352,9 @@ var ResourceTable = map[sealtasks.TaskType]map[abi.RegisteredSealProof]Resources
MaxMemory: 4 << 30, MaxMemory: 4 << 30,
MinMemory: 4 << 30, MinMemory: 4 << 30,
MaxParallelism: 1, MaxParallelism: 1,
MaxParallelismGPU: 6,
GPUUtilization: 1.0,
BaseMinMemory: 1 << 30, BaseMinMemory: 1 << 30,
}, },
@ -359,6 +363,7 @@ var ResourceTable = map[sealtasks.TaskType]map[abi.RegisteredSealProof]Resources
MinMemory: 1 << 30, MinMemory: 1 << 30,
MaxParallelism: 1, MaxParallelism: 1,
GPUUtilization: 1.0,
BaseMinMemory: 1 << 30, BaseMinMemory: 1 << 30,
}, },
@ -367,6 +372,7 @@ var ResourceTable = map[sealtasks.TaskType]map[abi.RegisteredSealProof]Resources
MinMemory: 2 << 10, MinMemory: 2 << 10,
MaxParallelism: 1, MaxParallelism: 1,
GPUUtilization: 1.0,
BaseMinMemory: 2 << 10, BaseMinMemory: 2 << 10,
}, },
@ -375,6 +381,7 @@ var ResourceTable = map[sealtasks.TaskType]map[abi.RegisteredSealProof]Resources
MinMemory: 8 << 20, MinMemory: 8 << 20,
MaxParallelism: 1, MaxParallelism: 1,
GPUUtilization: 1.0,
BaseMinMemory: 8 << 20, BaseMinMemory: 8 << 20,
}, },