1
2
3
4 package stats
5
6 import (
7 fmt "fmt"
8 _ "github.com/gogo/protobuf/gogoproto"
9 proto "github.com/gogo/protobuf/proto"
10 io "io"
11 math "math"
12 math_bits "math/bits"
13 reflect "reflect"
14 strings "strings"
15 )
16
17
18 var _ = proto.Marshal
19 var _ = fmt.Errorf
20 var _ = math.Inf
21
22
23
24
25
26 const _ = proto.GoGoProtoPackageIsVersion3
27
28 type Metrics struct {
29 Pids *PidsStat `protobuf:"bytes,1,opt,name=pids,proto3" json:"pids,omitempty"`
30 CPU *CPUStat `protobuf:"bytes,2,opt,name=cpu,proto3" json:"cpu,omitempty"`
31 Memory *MemoryStat `protobuf:"bytes,4,opt,name=memory,proto3" json:"memory,omitempty"`
32 Rdma *RdmaStat `protobuf:"bytes,5,opt,name=rdma,proto3" json:"rdma,omitempty"`
33 Io *IOStat `protobuf:"bytes,6,opt,name=io,proto3" json:"io,omitempty"`
34 Hugetlb []*HugeTlbStat `protobuf:"bytes,7,rep,name=hugetlb,proto3" json:"hugetlb,omitempty"`
35 MemoryEvents *MemoryEvents `protobuf:"bytes,8,opt,name=memory_events,json=memoryEvents,proto3" json:"memory_events,omitempty"`
36 XXX_NoUnkeyedLiteral struct{} `json:"-"`
37 XXX_unrecognized []byte `json:"-"`
38 XXX_sizecache int32 `json:"-"`
39 }
40
41 func (m *Metrics) Reset() { *m = Metrics{} }
42 func (*Metrics) ProtoMessage() {}
43 func (*Metrics) Descriptor() ([]byte, []int) {
44 return fileDescriptor_2fc6005842049e6b, []int{0}
45 }
46 func (m *Metrics) XXX_Unmarshal(b []byte) error {
47 return m.Unmarshal(b)
48 }
49 func (m *Metrics) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
50 if deterministic {
51 return xxx_messageInfo_Metrics.Marshal(b, m, deterministic)
52 } else {
53 b = b[:cap(b)]
54 n, err := m.MarshalToSizedBuffer(b)
55 if err != nil {
56 return nil, err
57 }
58 return b[:n], nil
59 }
60 }
61 func (m *Metrics) XXX_Merge(src proto.Message) {
62 xxx_messageInfo_Metrics.Merge(m, src)
63 }
64 func (m *Metrics) XXX_Size() int {
65 return m.Size()
66 }
67 func (m *Metrics) XXX_DiscardUnknown() {
68 xxx_messageInfo_Metrics.DiscardUnknown(m)
69 }
70
71 var xxx_messageInfo_Metrics proto.InternalMessageInfo
72
73 type PidsStat struct {
74 Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
75 Limit uint64 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"`
76 XXX_NoUnkeyedLiteral struct{} `json:"-"`
77 XXX_unrecognized []byte `json:"-"`
78 XXX_sizecache int32 `json:"-"`
79 }
80
81 func (m *PidsStat) Reset() { *m = PidsStat{} }
82 func (*PidsStat) ProtoMessage() {}
83 func (*PidsStat) Descriptor() ([]byte, []int) {
84 return fileDescriptor_2fc6005842049e6b, []int{1}
85 }
86 func (m *PidsStat) XXX_Unmarshal(b []byte) error {
87 return m.Unmarshal(b)
88 }
89 func (m *PidsStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
90 if deterministic {
91 return xxx_messageInfo_PidsStat.Marshal(b, m, deterministic)
92 } else {
93 b = b[:cap(b)]
94 n, err := m.MarshalToSizedBuffer(b)
95 if err != nil {
96 return nil, err
97 }
98 return b[:n], nil
99 }
100 }
101 func (m *PidsStat) XXX_Merge(src proto.Message) {
102 xxx_messageInfo_PidsStat.Merge(m, src)
103 }
104 func (m *PidsStat) XXX_Size() int {
105 return m.Size()
106 }
107 func (m *PidsStat) XXX_DiscardUnknown() {
108 xxx_messageInfo_PidsStat.DiscardUnknown(m)
109 }
110
111 var xxx_messageInfo_PidsStat proto.InternalMessageInfo
112
113 type CPUStat struct {
114 UsageUsec uint64 `protobuf:"varint,1,opt,name=usage_usec,json=usageUsec,proto3" json:"usage_usec,omitempty"`
115 UserUsec uint64 `protobuf:"varint,2,opt,name=user_usec,json=userUsec,proto3" json:"user_usec,omitempty"`
116 SystemUsec uint64 `protobuf:"varint,3,opt,name=system_usec,json=systemUsec,proto3" json:"system_usec,omitempty"`
117 NrPeriods uint64 `protobuf:"varint,4,opt,name=nr_periods,json=nrPeriods,proto3" json:"nr_periods,omitempty"`
118 NrThrottled uint64 `protobuf:"varint,5,opt,name=nr_throttled,json=nrThrottled,proto3" json:"nr_throttled,omitempty"`
119 ThrottledUsec uint64 `protobuf:"varint,6,opt,name=throttled_usec,json=throttledUsec,proto3" json:"throttled_usec,omitempty"`
120 XXX_NoUnkeyedLiteral struct{} `json:"-"`
121 XXX_unrecognized []byte `json:"-"`
122 XXX_sizecache int32 `json:"-"`
123 }
124
125 func (m *CPUStat) Reset() { *m = CPUStat{} }
126 func (*CPUStat) ProtoMessage() {}
127 func (*CPUStat) Descriptor() ([]byte, []int) {
128 return fileDescriptor_2fc6005842049e6b, []int{2}
129 }
130 func (m *CPUStat) XXX_Unmarshal(b []byte) error {
131 return m.Unmarshal(b)
132 }
133 func (m *CPUStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
134 if deterministic {
135 return xxx_messageInfo_CPUStat.Marshal(b, m, deterministic)
136 } else {
137 b = b[:cap(b)]
138 n, err := m.MarshalToSizedBuffer(b)
139 if err != nil {
140 return nil, err
141 }
142 return b[:n], nil
143 }
144 }
145 func (m *CPUStat) XXX_Merge(src proto.Message) {
146 xxx_messageInfo_CPUStat.Merge(m, src)
147 }
148 func (m *CPUStat) XXX_Size() int {
149 return m.Size()
150 }
151 func (m *CPUStat) XXX_DiscardUnknown() {
152 xxx_messageInfo_CPUStat.DiscardUnknown(m)
153 }
154
155 var xxx_messageInfo_CPUStat proto.InternalMessageInfo
156
157 type MemoryStat struct {
158 Anon uint64 `protobuf:"varint,1,opt,name=anon,proto3" json:"anon,omitempty"`
159 File uint64 `protobuf:"varint,2,opt,name=file,proto3" json:"file,omitempty"`
160 KernelStack uint64 `protobuf:"varint,3,opt,name=kernel_stack,json=kernelStack,proto3" json:"kernel_stack,omitempty"`
161 Slab uint64 `protobuf:"varint,4,opt,name=slab,proto3" json:"slab,omitempty"`
162 Sock uint64 `protobuf:"varint,5,opt,name=sock,proto3" json:"sock,omitempty"`
163 Shmem uint64 `protobuf:"varint,6,opt,name=shmem,proto3" json:"shmem,omitempty"`
164 FileMapped uint64 `protobuf:"varint,7,opt,name=file_mapped,json=fileMapped,proto3" json:"file_mapped,omitempty"`
165 FileDirty uint64 `protobuf:"varint,8,opt,name=file_dirty,json=fileDirty,proto3" json:"file_dirty,omitempty"`
166 FileWriteback uint64 `protobuf:"varint,9,opt,name=file_writeback,json=fileWriteback,proto3" json:"file_writeback,omitempty"`
167 AnonThp uint64 `protobuf:"varint,10,opt,name=anon_thp,json=anonThp,proto3" json:"anon_thp,omitempty"`
168 InactiveAnon uint64 `protobuf:"varint,11,opt,name=inactive_anon,json=inactiveAnon,proto3" json:"inactive_anon,omitempty"`
169 ActiveAnon uint64 `protobuf:"varint,12,opt,name=active_anon,json=activeAnon,proto3" json:"active_anon,omitempty"`
170 InactiveFile uint64 `protobuf:"varint,13,opt,name=inactive_file,json=inactiveFile,proto3" json:"inactive_file,omitempty"`
171 ActiveFile uint64 `protobuf:"varint,14,opt,name=active_file,json=activeFile,proto3" json:"active_file,omitempty"`
172 Unevictable uint64 `protobuf:"varint,15,opt,name=unevictable,proto3" json:"unevictable,omitempty"`
173 SlabReclaimable uint64 `protobuf:"varint,16,opt,name=slab_reclaimable,json=slabReclaimable,proto3" json:"slab_reclaimable,omitempty"`
174 SlabUnreclaimable uint64 `protobuf:"varint,17,opt,name=slab_unreclaimable,json=slabUnreclaimable,proto3" json:"slab_unreclaimable,omitempty"`
175 Pgfault uint64 `protobuf:"varint,18,opt,name=pgfault,proto3" json:"pgfault,omitempty"`
176 Pgmajfault uint64 `protobuf:"varint,19,opt,name=pgmajfault,proto3" json:"pgmajfault,omitempty"`
177 WorkingsetRefault uint64 `protobuf:"varint,20,opt,name=workingset_refault,json=workingsetRefault,proto3" json:"workingset_refault,omitempty"`
178 WorkingsetActivate uint64 `protobuf:"varint,21,opt,name=workingset_activate,json=workingsetActivate,proto3" json:"workingset_activate,omitempty"`
179 WorkingsetNodereclaim uint64 `protobuf:"varint,22,opt,name=workingset_nodereclaim,json=workingsetNodereclaim,proto3" json:"workingset_nodereclaim,omitempty"`
180 Pgrefill uint64 `protobuf:"varint,23,opt,name=pgrefill,proto3" json:"pgrefill,omitempty"`
181 Pgscan uint64 `protobuf:"varint,24,opt,name=pgscan,proto3" json:"pgscan,omitempty"`
182 Pgsteal uint64 `protobuf:"varint,25,opt,name=pgsteal,proto3" json:"pgsteal,omitempty"`
183 Pgactivate uint64 `protobuf:"varint,26,opt,name=pgactivate,proto3" json:"pgactivate,omitempty"`
184 Pgdeactivate uint64 `protobuf:"varint,27,opt,name=pgdeactivate,proto3" json:"pgdeactivate,omitempty"`
185 Pglazyfree uint64 `protobuf:"varint,28,opt,name=pglazyfree,proto3" json:"pglazyfree,omitempty"`
186 Pglazyfreed uint64 `protobuf:"varint,29,opt,name=pglazyfreed,proto3" json:"pglazyfreed,omitempty"`
187 ThpFaultAlloc uint64 `protobuf:"varint,30,opt,name=thp_fault_alloc,json=thpFaultAlloc,proto3" json:"thp_fault_alloc,omitempty"`
188 ThpCollapseAlloc uint64 `protobuf:"varint,31,opt,name=thp_collapse_alloc,json=thpCollapseAlloc,proto3" json:"thp_collapse_alloc,omitempty"`
189 Usage uint64 `protobuf:"varint,32,opt,name=usage,proto3" json:"usage,omitempty"`
190 UsageLimit uint64 `protobuf:"varint,33,opt,name=usage_limit,json=usageLimit,proto3" json:"usage_limit,omitempty"`
191 SwapUsage uint64 `protobuf:"varint,34,opt,name=swap_usage,json=swapUsage,proto3" json:"swap_usage,omitempty"`
192 SwapLimit uint64 `protobuf:"varint,35,opt,name=swap_limit,json=swapLimit,proto3" json:"swap_limit,omitempty"`
193 XXX_NoUnkeyedLiteral struct{} `json:"-"`
194 XXX_unrecognized []byte `json:"-"`
195 XXX_sizecache int32 `json:"-"`
196 }
197
198 func (m *MemoryStat) Reset() { *m = MemoryStat{} }
199 func (*MemoryStat) ProtoMessage() {}
200 func (*MemoryStat) Descriptor() ([]byte, []int) {
201 return fileDescriptor_2fc6005842049e6b, []int{3}
202 }
203 func (m *MemoryStat) XXX_Unmarshal(b []byte) error {
204 return m.Unmarshal(b)
205 }
206 func (m *MemoryStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
207 if deterministic {
208 return xxx_messageInfo_MemoryStat.Marshal(b, m, deterministic)
209 } else {
210 b = b[:cap(b)]
211 n, err := m.MarshalToSizedBuffer(b)
212 if err != nil {
213 return nil, err
214 }
215 return b[:n], nil
216 }
217 }
218 func (m *MemoryStat) XXX_Merge(src proto.Message) {
219 xxx_messageInfo_MemoryStat.Merge(m, src)
220 }
221 func (m *MemoryStat) XXX_Size() int {
222 return m.Size()
223 }
224 func (m *MemoryStat) XXX_DiscardUnknown() {
225 xxx_messageInfo_MemoryStat.DiscardUnknown(m)
226 }
227
228 var xxx_messageInfo_MemoryStat proto.InternalMessageInfo
229
230 type MemoryEvents struct {
231 Low uint64 `protobuf:"varint,1,opt,name=low,proto3" json:"low,omitempty"`
232 High uint64 `protobuf:"varint,2,opt,name=high,proto3" json:"high,omitempty"`
233 Max uint64 `protobuf:"varint,3,opt,name=max,proto3" json:"max,omitempty"`
234 Oom uint64 `protobuf:"varint,4,opt,name=oom,proto3" json:"oom,omitempty"`
235 OomKill uint64 `protobuf:"varint,5,opt,name=oom_kill,json=oomKill,proto3" json:"oom_kill,omitempty"`
236 XXX_NoUnkeyedLiteral struct{} `json:"-"`
237 XXX_unrecognized []byte `json:"-"`
238 XXX_sizecache int32 `json:"-"`
239 }
240
241 func (m *MemoryEvents) Reset() { *m = MemoryEvents{} }
242 func (*MemoryEvents) ProtoMessage() {}
243 func (*MemoryEvents) Descriptor() ([]byte, []int) {
244 return fileDescriptor_2fc6005842049e6b, []int{4}
245 }
246 func (m *MemoryEvents) XXX_Unmarshal(b []byte) error {
247 return m.Unmarshal(b)
248 }
249 func (m *MemoryEvents) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
250 if deterministic {
251 return xxx_messageInfo_MemoryEvents.Marshal(b, m, deterministic)
252 } else {
253 b = b[:cap(b)]
254 n, err := m.MarshalToSizedBuffer(b)
255 if err != nil {
256 return nil, err
257 }
258 return b[:n], nil
259 }
260 }
261 func (m *MemoryEvents) XXX_Merge(src proto.Message) {
262 xxx_messageInfo_MemoryEvents.Merge(m, src)
263 }
264 func (m *MemoryEvents) XXX_Size() int {
265 return m.Size()
266 }
267 func (m *MemoryEvents) XXX_DiscardUnknown() {
268 xxx_messageInfo_MemoryEvents.DiscardUnknown(m)
269 }
270
271 var xxx_messageInfo_MemoryEvents proto.InternalMessageInfo
272
273 type RdmaStat struct {
274 Current []*RdmaEntry `protobuf:"bytes,1,rep,name=current,proto3" json:"current,omitempty"`
275 Limit []*RdmaEntry `protobuf:"bytes,2,rep,name=limit,proto3" json:"limit,omitempty"`
276 XXX_NoUnkeyedLiteral struct{} `json:"-"`
277 XXX_unrecognized []byte `json:"-"`
278 XXX_sizecache int32 `json:"-"`
279 }
280
281 func (m *RdmaStat) Reset() { *m = RdmaStat{} }
282 func (*RdmaStat) ProtoMessage() {}
283 func (*RdmaStat) Descriptor() ([]byte, []int) {
284 return fileDescriptor_2fc6005842049e6b, []int{5}
285 }
286 func (m *RdmaStat) XXX_Unmarshal(b []byte) error {
287 return m.Unmarshal(b)
288 }
289 func (m *RdmaStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
290 if deterministic {
291 return xxx_messageInfo_RdmaStat.Marshal(b, m, deterministic)
292 } else {
293 b = b[:cap(b)]
294 n, err := m.MarshalToSizedBuffer(b)
295 if err != nil {
296 return nil, err
297 }
298 return b[:n], nil
299 }
300 }
301 func (m *RdmaStat) XXX_Merge(src proto.Message) {
302 xxx_messageInfo_RdmaStat.Merge(m, src)
303 }
304 func (m *RdmaStat) XXX_Size() int {
305 return m.Size()
306 }
307 func (m *RdmaStat) XXX_DiscardUnknown() {
308 xxx_messageInfo_RdmaStat.DiscardUnknown(m)
309 }
310
311 var xxx_messageInfo_RdmaStat proto.InternalMessageInfo
312
313 type RdmaEntry struct {
314 Device string `protobuf:"bytes,1,opt,name=device,proto3" json:"device,omitempty"`
315 HcaHandles uint32 `protobuf:"varint,2,opt,name=hca_handles,json=hcaHandles,proto3" json:"hca_handles,omitempty"`
316 HcaObjects uint32 `protobuf:"varint,3,opt,name=hca_objects,json=hcaObjects,proto3" json:"hca_objects,omitempty"`
317 XXX_NoUnkeyedLiteral struct{} `json:"-"`
318 XXX_unrecognized []byte `json:"-"`
319 XXX_sizecache int32 `json:"-"`
320 }
321
322 func (m *RdmaEntry) Reset() { *m = RdmaEntry{} }
323 func (*RdmaEntry) ProtoMessage() {}
324 func (*RdmaEntry) Descriptor() ([]byte, []int) {
325 return fileDescriptor_2fc6005842049e6b, []int{6}
326 }
327 func (m *RdmaEntry) XXX_Unmarshal(b []byte) error {
328 return m.Unmarshal(b)
329 }
330 func (m *RdmaEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
331 if deterministic {
332 return xxx_messageInfo_RdmaEntry.Marshal(b, m, deterministic)
333 } else {
334 b = b[:cap(b)]
335 n, err := m.MarshalToSizedBuffer(b)
336 if err != nil {
337 return nil, err
338 }
339 return b[:n], nil
340 }
341 }
342 func (m *RdmaEntry) XXX_Merge(src proto.Message) {
343 xxx_messageInfo_RdmaEntry.Merge(m, src)
344 }
345 func (m *RdmaEntry) XXX_Size() int {
346 return m.Size()
347 }
348 func (m *RdmaEntry) XXX_DiscardUnknown() {
349 xxx_messageInfo_RdmaEntry.DiscardUnknown(m)
350 }
351
352 var xxx_messageInfo_RdmaEntry proto.InternalMessageInfo
353
354 type IOStat struct {
355 Usage []*IOEntry `protobuf:"bytes,1,rep,name=usage,proto3" json:"usage,omitempty"`
356 XXX_NoUnkeyedLiteral struct{} `json:"-"`
357 XXX_unrecognized []byte `json:"-"`
358 XXX_sizecache int32 `json:"-"`
359 }
360
361 func (m *IOStat) Reset() { *m = IOStat{} }
362 func (*IOStat) ProtoMessage() {}
363 func (*IOStat) Descriptor() ([]byte, []int) {
364 return fileDescriptor_2fc6005842049e6b, []int{7}
365 }
366 func (m *IOStat) XXX_Unmarshal(b []byte) error {
367 return m.Unmarshal(b)
368 }
369 func (m *IOStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
370 if deterministic {
371 return xxx_messageInfo_IOStat.Marshal(b, m, deterministic)
372 } else {
373 b = b[:cap(b)]
374 n, err := m.MarshalToSizedBuffer(b)
375 if err != nil {
376 return nil, err
377 }
378 return b[:n], nil
379 }
380 }
381 func (m *IOStat) XXX_Merge(src proto.Message) {
382 xxx_messageInfo_IOStat.Merge(m, src)
383 }
384 func (m *IOStat) XXX_Size() int {
385 return m.Size()
386 }
387 func (m *IOStat) XXX_DiscardUnknown() {
388 xxx_messageInfo_IOStat.DiscardUnknown(m)
389 }
390
391 var xxx_messageInfo_IOStat proto.InternalMessageInfo
392
393 type IOEntry struct {
394 Major uint64 `protobuf:"varint,1,opt,name=major,proto3" json:"major,omitempty"`
395 Minor uint64 `protobuf:"varint,2,opt,name=minor,proto3" json:"minor,omitempty"`
396 Rbytes uint64 `protobuf:"varint,3,opt,name=rbytes,proto3" json:"rbytes,omitempty"`
397 Wbytes uint64 `protobuf:"varint,4,opt,name=wbytes,proto3" json:"wbytes,omitempty"`
398 Rios uint64 `protobuf:"varint,5,opt,name=rios,proto3" json:"rios,omitempty"`
399 Wios uint64 `protobuf:"varint,6,opt,name=wios,proto3" json:"wios,omitempty"`
400 XXX_NoUnkeyedLiteral struct{} `json:"-"`
401 XXX_unrecognized []byte `json:"-"`
402 XXX_sizecache int32 `json:"-"`
403 }
404
405 func (m *IOEntry) Reset() { *m = IOEntry{} }
406 func (*IOEntry) ProtoMessage() {}
407 func (*IOEntry) Descriptor() ([]byte, []int) {
408 return fileDescriptor_2fc6005842049e6b, []int{8}
409 }
410 func (m *IOEntry) XXX_Unmarshal(b []byte) error {
411 return m.Unmarshal(b)
412 }
413 func (m *IOEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
414 if deterministic {
415 return xxx_messageInfo_IOEntry.Marshal(b, m, deterministic)
416 } else {
417 b = b[:cap(b)]
418 n, err := m.MarshalToSizedBuffer(b)
419 if err != nil {
420 return nil, err
421 }
422 return b[:n], nil
423 }
424 }
425 func (m *IOEntry) XXX_Merge(src proto.Message) {
426 xxx_messageInfo_IOEntry.Merge(m, src)
427 }
428 func (m *IOEntry) XXX_Size() int {
429 return m.Size()
430 }
431 func (m *IOEntry) XXX_DiscardUnknown() {
432 xxx_messageInfo_IOEntry.DiscardUnknown(m)
433 }
434
435 var xxx_messageInfo_IOEntry proto.InternalMessageInfo
436
437 type HugeTlbStat struct {
438 Current uint64 `protobuf:"varint,1,opt,name=current,proto3" json:"current,omitempty"`
439 Max uint64 `protobuf:"varint,2,opt,name=max,proto3" json:"max,omitempty"`
440 Pagesize string `protobuf:"bytes,3,opt,name=pagesize,proto3" json:"pagesize,omitempty"`
441 XXX_NoUnkeyedLiteral struct{} `json:"-"`
442 XXX_unrecognized []byte `json:"-"`
443 XXX_sizecache int32 `json:"-"`
444 }
445
446 func (m *HugeTlbStat) Reset() { *m = HugeTlbStat{} }
447 func (*HugeTlbStat) ProtoMessage() {}
448 func (*HugeTlbStat) Descriptor() ([]byte, []int) {
449 return fileDescriptor_2fc6005842049e6b, []int{9}
450 }
451 func (m *HugeTlbStat) XXX_Unmarshal(b []byte) error {
452 return m.Unmarshal(b)
453 }
454 func (m *HugeTlbStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
455 if deterministic {
456 return xxx_messageInfo_HugeTlbStat.Marshal(b, m, deterministic)
457 } else {
458 b = b[:cap(b)]
459 n, err := m.MarshalToSizedBuffer(b)
460 if err != nil {
461 return nil, err
462 }
463 return b[:n], nil
464 }
465 }
466 func (m *HugeTlbStat) XXX_Merge(src proto.Message) {
467 xxx_messageInfo_HugeTlbStat.Merge(m, src)
468 }
469 func (m *HugeTlbStat) XXX_Size() int {
470 return m.Size()
471 }
472 func (m *HugeTlbStat) XXX_DiscardUnknown() {
473 xxx_messageInfo_HugeTlbStat.DiscardUnknown(m)
474 }
475
476 var xxx_messageInfo_HugeTlbStat proto.InternalMessageInfo
477
478 func init() {
479 proto.RegisterType((*Metrics)(nil), "io.containerd.cgroups.v2.Metrics")
480 proto.RegisterType((*PidsStat)(nil), "io.containerd.cgroups.v2.PidsStat")
481 proto.RegisterType((*CPUStat)(nil), "io.containerd.cgroups.v2.CPUStat")
482 proto.RegisterType((*MemoryStat)(nil), "io.containerd.cgroups.v2.MemoryStat")
483 proto.RegisterType((*MemoryEvents)(nil), "io.containerd.cgroups.v2.MemoryEvents")
484 proto.RegisterType((*RdmaStat)(nil), "io.containerd.cgroups.v2.RdmaStat")
485 proto.RegisterType((*RdmaEntry)(nil), "io.containerd.cgroups.v2.RdmaEntry")
486 proto.RegisterType((*IOStat)(nil), "io.containerd.cgroups.v2.IOStat")
487 proto.RegisterType((*IOEntry)(nil), "io.containerd.cgroups.v2.IOEntry")
488 proto.RegisterType((*HugeTlbStat)(nil), "io.containerd.cgroups.v2.HugeTlbStat")
489 }
490
491 func init() {
492 proto.RegisterFile("github.com/containerd/cgroups/v2/stats/metrics.proto", fileDescriptor_2fc6005842049e6b)
493 }
494
495 var fileDescriptor_2fc6005842049e6b = []byte{
496
497 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x4d, 0x73, 0xd4, 0x46,
498 0x13, 0x66, 0xed, 0xc5, 0xeb, 0xed, 0xb5, 0xc1, 0x0c, 0x86, 0x57, 0xc0, 0xcb, 0xda, 0x5e, 0x02,
499 0x45, 0xaa, 0x92, 0xdd, 0x94, 0xf3, 0x55, 0x49, 0x91, 0x4a, 0x19, 0x02, 0x45, 0x8a, 0x10, 0x5c,
500 0x02, 0x57, 0x8e, 0xaa, 0x59, 0x69, 0x2c, 0x0d, 0x96, 0x34, 0xaa, 0x99, 0x91, 0x1d, 0x73, 0xca,
501 0x21, 0xd7, 0x54, 0x7e, 0x4d, 0xfe, 0x03, 0xb7, 0xe4, 0x98, 0x53, 0x2a, 0xf8, 0x97, 0xa4, 0xba,
502 0x67, 0x64, 0x29, 0x07, 0x43, 0x6e, 0xd3, 0x4f, 0x3f, 0xdd, 0xea, 0x8f, 0x99, 0x6e, 0xc1, 0x27,
503 0xa9, 0xb4, 0x59, 0x3d, 0x9f, 0xc6, 0xaa, 0x98, 0xc5, 0xaa, 0xb4, 0x5c, 0x96, 0x42, 0x27, 0xb3,
504 0x38, 0xd5, 0xaa, 0xae, 0xcc, 0xec, 0x70, 0x7b, 0x66, 0x2c, 0xb7, 0x66, 0x56, 0x08, 0xab, 0x65,
505 0x6c, 0xa6, 0x95, 0x56, 0x56, 0xb1, 0x40, 0xaa, 0x69, 0xcb, 0x9e, 0x7a, 0xf6, 0xf4, 0x70, 0xfb,
506 0xfa, 0x7a, 0xaa, 0x52, 0x45, 0xa4, 0x19, 0x9e, 0x1c, 0x7f, 0xf2, 0xdb, 0x22, 0x0c, 0x9e, 0x3a,
507 0x0f, 0xec, 0x33, 0xe8, 0x57, 0x32, 0x31, 0x41, 0x6f, 0xb3, 0x77, 0x77, 0xb4, 0x3d, 0x99, 0x9e,
508 0xe5, 0x6a, 0xba, 0x2b, 0x13, 0xf3, 0xdc, 0x72, 0x1b, 0x12, 0x9f, 0xdd, 0x83, 0xc5, 0xb8, 0xaa,
509 0x83, 0x05, 0x32, 0xdb, 0x3a, 0xdb, 0xec, 0xc1, 0xee, 0x1e, 0x5a, 0xdd, 0x1f, 0x9c, 0xfc, 0xb5,
510 0xb1, 0xf8, 0x60, 0x77, 0x2f, 0x44, 0x33, 0x76, 0x0f, 0x96, 0x0a, 0x51, 0x28, 0x7d, 0x1c, 0xf4,
511 0xc9, 0xc1, 0x7b, 0x67, 0x3b, 0x78, 0x4a, 0x3c, 0xfa, 0xb2, 0xb7, 0xc1, 0x98, 0x75, 0x52, 0xf0,
512 0xe0, 0xfc, 0xbb, 0x62, 0x0e, 0x93, 0x82, 0xbb, 0x98, 0x91, 0xcf, 0x3e, 0x82, 0x05, 0xa9, 0x82,
513 0x25, 0xb2, 0xda, 0x3c, 0xdb, 0xea, 0xdb, 0x67, 0x64, 0xb3, 0x20, 0x15, 0xfb, 0x1a, 0x06, 0x59,
514 0x9d, 0x0a, 0x9b, 0xcf, 0x83, 0xc1, 0xe6, 0xe2, 0xdd, 0xd1, 0xf6, 0xed, 0xb3, 0xcd, 0x1e, 0xd7,
515 0xa9, 0x78, 0x91, 0xcf, 0xc9, 0xb6, 0xb1, 0x62, 0x4f, 0x60, 0xd5, 0x05, 0x1d, 0x89, 0x43, 0x51,
516 0x5a, 0x13, 0x2c, 0xd3, 0xd7, 0xef, 0xbc, 0x2b, 0xdf, 0x87, 0xc4, 0x0e, 0x57, 0x8a, 0x8e, 0x34,
517 0xf9, 0x12, 0x96, 0x9b, 0x2e, 0xb0, 0x00, 0x06, 0x71, 0xad, 0xb5, 0x28, 0x2d, 0xb5, 0xae, 0x1f,
518 0x36, 0x22, 0x5b, 0x87, 0xf3, 0xb9, 0x2c, 0xa4, 0xa5, 0xde, 0xf4, 0x43, 0x27, 0x4c, 0x7e, 0xef,
519 0xc1, 0xc0, 0xf7, 0x82, 0xdd, 0x04, 0xa8, 0x0d, 0x4f, 0x45, 0x54, 0x1b, 0x11, 0x7b, 0xf3, 0x21,
520 0x21, 0x7b, 0x46, 0xc4, 0xec, 0x06, 0x0c, 0x6b, 0x23, 0xb4, 0xd3, 0x3a, 0x27, 0xcb, 0x08, 0x90,
521 0x72, 0x03, 0x46, 0xe6, 0xd8, 0x58, 0x51, 0x38, 0xf5, 0x22, 0xa9, 0xc1, 0x41, 0x44, 0xb8, 0x09,
522 0x50, 0xea, 0xa8, 0x12, 0x5a, 0xaa, 0xc4, 0x50, 0x7b, 0xfb, 0xe1, 0xb0, 0xd4, 0xbb, 0x0e, 0x60,
523 0x5b, 0xb0, 0x52, 0xea, 0xc8, 0x66, 0x5a, 0x59, 0x9b, 0x8b, 0x84, 0x7a, 0xd8, 0x0f, 0x47, 0xa5,
524 0x7e, 0xd1, 0x40, 0xec, 0x36, 0x5c, 0x38, 0xd5, 0xbb, 0xaf, 0x2c, 0x11, 0x69, 0xf5, 0x14, 0xc5,
525 0x0f, 0x4d, 0x7e, 0x1d, 0x02, 0xb4, 0x97, 0x83, 0x31, 0xe8, 0xf3, 0x52, 0x95, 0x3e, 0x1d, 0x3a,
526 0x23, 0xb6, 0x2f, 0x73, 0xe1, 0x93, 0xa0, 0x33, 0x06, 0x70, 0x20, 0x74, 0x29, 0xf2, 0xc8, 0x58,
527 0x1e, 0x1f, 0xf8, 0x0c, 0x46, 0x0e, 0x7b, 0x8e, 0x10, 0x9a, 0x99, 0x9c, 0xcf, 0x7d, 0xf0, 0x74,
528 0x26, 0x4c, 0xc5, 0x07, 0x3e, 0x5e, 0x3a, 0x63, 0xa5, 0x4d, 0x56, 0x88, 0xc2, 0xc7, 0xe7, 0x04,
529 0xac, 0x10, 0x7e, 0x28, 0x2a, 0x78, 0x55, 0x89, 0x24, 0x18, 0xb8, 0x0a, 0x21, 0xf4, 0x94, 0x10,
530 0xac, 0x10, 0x11, 0x12, 0xa9, 0xed, 0x31, 0x5d, 0x88, 0x7e, 0x38, 0x44, 0xe4, 0x1b, 0x04, 0x30,
531 0x7d, 0x52, 0x1f, 0x69, 0x69, 0xc5, 0x1c, 0x43, 0x1c, 0xba, 0xf4, 0x11, 0xfd, 0xa1, 0x01, 0xd9,
532 0x35, 0x58, 0xc6, 0x1c, 0x23, 0x9b, 0x55, 0x01, 0xb8, 0x1b, 0x80, 0xf2, 0x8b, 0xac, 0x62, 0xb7,
533 0x60, 0x55, 0x96, 0x3c, 0xb6, 0xf2, 0x50, 0x44, 0x54, 0x93, 0x11, 0xe9, 0x57, 0x1a, 0x70, 0x07,
534 0x6b, 0xb3, 0x01, 0xa3, 0x2e, 0x65, 0xc5, 0x85, 0xd9, 0x21, 0x74, 0xbd, 0x50, 0x15, 0x57, 0xff,
535 0xed, 0xe5, 0x11, 0x56, 0xb3, 0xf5, 0x42, 0x94, 0x0b, 0x5d, 0x2f, 0x44, 0xd8, 0x84, 0x51, 0x5d,
536 0x8a, 0x43, 0x19, 0x5b, 0x3e, 0xcf, 0x45, 0x70, 0xd1, 0x55, 0xbb, 0x03, 0xb1, 0xf7, 0x61, 0x0d,
537 0x2b, 0x1c, 0x69, 0x11, 0xe7, 0x5c, 0x16, 0x44, 0x5b, 0x23, 0xda, 0x45, 0xc4, 0xc3, 0x16, 0x66,
538 0x1f, 0x02, 0x23, 0x6a, 0x5d, 0x76, 0xc9, 0x97, 0x88, 0x7c, 0x09, 0x35, 0x7b, 0x5d, 0x05, 0xbe,
539 0x91, 0x2a, 0xdd, 0xe7, 0x75, 0x6e, 0x03, 0xe6, 0x2a, 0xe4, 0x45, 0x36, 0x06, 0xa8, 0xd2, 0x82,
540 0xbf, 0x74, 0xca, 0xcb, 0x2e, 0xea, 0x16, 0xc1, 0x0f, 0x1d, 0x29, 0x7d, 0x20, 0xcb, 0xd4, 0x08,
541 0x1b, 0x69, 0xe1, 0x78, 0xeb, 0xee, 0x43, 0xad, 0x26, 0x74, 0x0a, 0x36, 0x83, 0xcb, 0x1d, 0x3a,
542 0x65, 0xcf, 0xad, 0x08, 0xae, 0x10, 0xbf, 0xe3, 0x69, 0xc7, 0x6b, 0xd8, 0xa7, 0x70, 0xb5, 0x63,
543 0x50, 0xaa, 0x44, 0xf8, 0xb8, 0x83, 0xab, 0x64, 0x73, 0xa5, 0xd5, 0x7e, 0xdf, 0x2a, 0xd9, 0x75,
544 0x58, 0xae, 0x52, 0x2d, 0xf6, 0x65, 0x9e, 0x07, 0xff, 0x73, 0x0f, 0xb3, 0x91, 0xd9, 0x55, 0x58,
545 0xaa, 0x52, 0x13, 0xf3, 0x32, 0x08, 0x48, 0xe3, 0x25, 0x57, 0x04, 0x63, 0x05, 0xcf, 0x83, 0x6b,
546 0x4d, 0x11, 0x48, 0x74, 0x45, 0x38, 0x0d, 0xf6, 0x7a, 0x53, 0x84, 0x06, 0x61, 0x13, 0x58, 0xa9,
547 0xd2, 0x44, 0x9c, 0x32, 0x6e, 0xb8, 0xfe, 0x77, 0x31, 0xe7, 0x23, 0xe7, 0xaf, 0x8e, 0xf7, 0xb5,
548 0x10, 0xc1, 0xff, 0x1b, 0x1f, 0x0d, 0x82, 0xed, 0x6f, 0xa5, 0x24, 0xb8, 0xe9, 0xda, 0xdf, 0x81,
549 0xd8, 0x1d, 0xb8, 0x68, 0xb3, 0x2a, 0xa2, 0x42, 0x46, 0x3c, 0xcf, 0x55, 0x1c, 0x8c, 0x9b, 0xe7,
550 0x5e, 0x3d, 0x42, 0x74, 0x07, 0x41, 0xf6, 0x01, 0x30, 0xe4, 0xc5, 0x2a, 0xcf, 0x79, 0x65, 0x84,
551 0xa7, 0x6e, 0x10, 0x75, 0xcd, 0x66, 0xd5, 0x03, 0xaf, 0x70, 0xec, 0x75, 0x38, 0x4f, 0x03, 0x2d,
552 0xd8, 0x74, 0x4f, 0x93, 0x04, 0xbc, 0xad, 0x6e, 0xf0, 0xb9, 0x01, 0xb9, 0xe5, 0xc2, 0x25, 0xe8,
553 0x3b, 0x44, 0xf0, 0x69, 0x9a, 0x23, 0x5e, 0x45, 0xce, 0x76, 0xe2, 0x9e, 0x26, 0x22, 0x7b, 0x64,
554 0xdf, 0xa8, 0x9d, 0xf9, 0xad, 0x56, 0x4d, 0xd6, 0x13, 0x03, 0x2b, 0xdd, 0xe9, 0xcd, 0xd6, 0x60,
555 0x31, 0x57, 0x47, 0x7e, 0x22, 0xe1, 0x11, 0xa7, 0x48, 0x26, 0xd3, 0xac, 0x19, 0x48, 0x78, 0x46,
556 0x56, 0xc1, 0x7f, 0xf4, 0x73, 0x08, 0x8f, 0x88, 0x28, 0x55, 0xf8, 0xf1, 0x83, 0x47, 0x7c, 0xec,
557 0x4a, 0x15, 0xd1, 0x01, 0x36, 0xde, 0x4d, 0xa0, 0x81, 0x52, 0xc5, 0x13, 0x99, 0xe7, 0x93, 0x9f,
558 0x7b, 0xb0, 0xdc, 0xec, 0x39, 0xf6, 0x55, 0x77, 0x2b, 0xe0, 0xbe, 0xba, 0xf5, 0xf6, 0xe5, 0xf8,
559 0xb0, 0xb4, 0xfa, 0xb8, 0x5d, 0x1d, 0x5f, 0xb4, 0xab, 0xe3, 0x3f, 0x1b, 0xfb, 0xfd, 0x22, 0x60,
560 0x78, 0x8a, 0xe1, 0x5d, 0x4c, 0xf0, 0x81, 0x0b, 0xca, 0x7d, 0x18, 0x7a, 0x09, 0xeb, 0x9f, 0xc5,
561 0x3c, 0xca, 0x78, 0x99, 0xe4, 0xc2, 0x50, 0x15, 0x56, 0x43, 0xc8, 0x62, 0xfe, 0xd8, 0x21, 0x0d,
562 0x41, 0xcd, 0x5f, 0x8a, 0xd8, 0x1a, 0xaa, 0x89, 0x23, 0x3c, 0x73, 0xc8, 0x64, 0x07, 0x96, 0xdc,
563 0x7a, 0x66, 0x9f, 0x37, 0x1d, 0x76, 0x89, 0x6e, 0xbd, 0x6d, 0x9f, 0xfb, 0x48, 0x89, 0x3f, 0xf9,
564 0xa5, 0x07, 0x03, 0x0f, 0xe1, 0x35, 0x29, 0xf8, 0x4b, 0xa5, 0x7d, 0x8f, 0x9c, 0x40, 0xa8, 0x2c,
565 0x95, 0x6e, 0x36, 0x28, 0x09, 0x98, 0x94, 0x9e, 0x1f, 0x5b, 0x61, 0x7c, 0xab, 0xbc, 0x84, 0xf8,
566 0x91, 0xc3, 0x5d, 0xc3, 0xbc, 0x84, 0xbd, 0xd6, 0x52, 0x99, 0x66, 0x63, 0xe0, 0x19, 0xb1, 0x23,
567 0xc4, 0xdc, 0xc2, 0xa0, 0xf3, 0x64, 0x0f, 0x46, 0x9d, 0x5f, 0x87, 0xb7, 0x2c, 0x76, 0x7f, 0x51,
568 0x16, 0xda, 0x8b, 0x82, 0xf3, 0x80, 0xa7, 0xc2, 0xc8, 0x57, 0x82, 0x82, 0x1a, 0x86, 0xa7, 0xf2,
569 0xfd, 0xe0, 0xf5, 0x9b, 0xf1, 0xb9, 0x3f, 0xdf, 0x8c, 0xcf, 0xfd, 0x74, 0x32, 0xee, 0xbd, 0x3e,
570 0x19, 0xf7, 0xfe, 0x38, 0x19, 0xf7, 0xfe, 0x3e, 0x19, 0xf7, 0xe6, 0x4b, 0xf4, 0x17, 0xf8, 0xf1,
571 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x4f, 0x2b, 0x30, 0xd6, 0x6d, 0x0a, 0x00, 0x00,
572 }
573
574 func (m *Metrics) Marshal() (dAtA []byte, err error) {
575 size := m.Size()
576 dAtA = make([]byte, size)
577 n, err := m.MarshalToSizedBuffer(dAtA[:size])
578 if err != nil {
579 return nil, err
580 }
581 return dAtA[:n], nil
582 }
583
584 func (m *Metrics) MarshalTo(dAtA []byte) (int, error) {
585 size := m.Size()
586 return m.MarshalToSizedBuffer(dAtA[:size])
587 }
588
589 func (m *Metrics) MarshalToSizedBuffer(dAtA []byte) (int, error) {
590 i := len(dAtA)
591 _ = i
592 var l int
593 _ = l
594 if m.XXX_unrecognized != nil {
595 i -= len(m.XXX_unrecognized)
596 copy(dAtA[i:], m.XXX_unrecognized)
597 }
598 if m.MemoryEvents != nil {
599 {
600 size, err := m.MemoryEvents.MarshalToSizedBuffer(dAtA[:i])
601 if err != nil {
602 return 0, err
603 }
604 i -= size
605 i = encodeVarintMetrics(dAtA, i, uint64(size))
606 }
607 i--
608 dAtA[i] = 0x42
609 }
610 if len(m.Hugetlb) > 0 {
611 for iNdEx := len(m.Hugetlb) - 1; iNdEx >= 0; iNdEx-- {
612 {
613 size, err := m.Hugetlb[iNdEx].MarshalToSizedBuffer(dAtA[:i])
614 if err != nil {
615 return 0, err
616 }
617 i -= size
618 i = encodeVarintMetrics(dAtA, i, uint64(size))
619 }
620 i--
621 dAtA[i] = 0x3a
622 }
623 }
624 if m.Io != nil {
625 {
626 size, err := m.Io.MarshalToSizedBuffer(dAtA[:i])
627 if err != nil {
628 return 0, err
629 }
630 i -= size
631 i = encodeVarintMetrics(dAtA, i, uint64(size))
632 }
633 i--
634 dAtA[i] = 0x32
635 }
636 if m.Rdma != nil {
637 {
638 size, err := m.Rdma.MarshalToSizedBuffer(dAtA[:i])
639 if err != nil {
640 return 0, err
641 }
642 i -= size
643 i = encodeVarintMetrics(dAtA, i, uint64(size))
644 }
645 i--
646 dAtA[i] = 0x2a
647 }
648 if m.Memory != nil {
649 {
650 size, err := m.Memory.MarshalToSizedBuffer(dAtA[:i])
651 if err != nil {
652 return 0, err
653 }
654 i -= size
655 i = encodeVarintMetrics(dAtA, i, uint64(size))
656 }
657 i--
658 dAtA[i] = 0x22
659 }
660 if m.CPU != nil {
661 {
662 size, err := m.CPU.MarshalToSizedBuffer(dAtA[:i])
663 if err != nil {
664 return 0, err
665 }
666 i -= size
667 i = encodeVarintMetrics(dAtA, i, uint64(size))
668 }
669 i--
670 dAtA[i] = 0x12
671 }
672 if m.Pids != nil {
673 {
674 size, err := m.Pids.MarshalToSizedBuffer(dAtA[:i])
675 if err != nil {
676 return 0, err
677 }
678 i -= size
679 i = encodeVarintMetrics(dAtA, i, uint64(size))
680 }
681 i--
682 dAtA[i] = 0xa
683 }
684 return len(dAtA) - i, nil
685 }
686
687 func (m *PidsStat) Marshal() (dAtA []byte, err error) {
688 size := m.Size()
689 dAtA = make([]byte, size)
690 n, err := m.MarshalToSizedBuffer(dAtA[:size])
691 if err != nil {
692 return nil, err
693 }
694 return dAtA[:n], nil
695 }
696
697 func (m *PidsStat) MarshalTo(dAtA []byte) (int, error) {
698 size := m.Size()
699 return m.MarshalToSizedBuffer(dAtA[:size])
700 }
701
702 func (m *PidsStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
703 i := len(dAtA)
704 _ = i
705 var l int
706 _ = l
707 if m.XXX_unrecognized != nil {
708 i -= len(m.XXX_unrecognized)
709 copy(dAtA[i:], m.XXX_unrecognized)
710 }
711 if m.Limit != 0 {
712 i = encodeVarintMetrics(dAtA, i, uint64(m.Limit))
713 i--
714 dAtA[i] = 0x10
715 }
716 if m.Current != 0 {
717 i = encodeVarintMetrics(dAtA, i, uint64(m.Current))
718 i--
719 dAtA[i] = 0x8
720 }
721 return len(dAtA) - i, nil
722 }
723
724 func (m *CPUStat) Marshal() (dAtA []byte, err error) {
725 size := m.Size()
726 dAtA = make([]byte, size)
727 n, err := m.MarshalToSizedBuffer(dAtA[:size])
728 if err != nil {
729 return nil, err
730 }
731 return dAtA[:n], nil
732 }
733
734 func (m *CPUStat) MarshalTo(dAtA []byte) (int, error) {
735 size := m.Size()
736 return m.MarshalToSizedBuffer(dAtA[:size])
737 }
738
739 func (m *CPUStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
740 i := len(dAtA)
741 _ = i
742 var l int
743 _ = l
744 if m.XXX_unrecognized != nil {
745 i -= len(m.XXX_unrecognized)
746 copy(dAtA[i:], m.XXX_unrecognized)
747 }
748 if m.ThrottledUsec != 0 {
749 i = encodeVarintMetrics(dAtA, i, uint64(m.ThrottledUsec))
750 i--
751 dAtA[i] = 0x30
752 }
753 if m.NrThrottled != 0 {
754 i = encodeVarintMetrics(dAtA, i, uint64(m.NrThrottled))
755 i--
756 dAtA[i] = 0x28
757 }
758 if m.NrPeriods != 0 {
759 i = encodeVarintMetrics(dAtA, i, uint64(m.NrPeriods))
760 i--
761 dAtA[i] = 0x20
762 }
763 if m.SystemUsec != 0 {
764 i = encodeVarintMetrics(dAtA, i, uint64(m.SystemUsec))
765 i--
766 dAtA[i] = 0x18
767 }
768 if m.UserUsec != 0 {
769 i = encodeVarintMetrics(dAtA, i, uint64(m.UserUsec))
770 i--
771 dAtA[i] = 0x10
772 }
773 if m.UsageUsec != 0 {
774 i = encodeVarintMetrics(dAtA, i, uint64(m.UsageUsec))
775 i--
776 dAtA[i] = 0x8
777 }
778 return len(dAtA) - i, nil
779 }
780
781 func (m *MemoryStat) Marshal() (dAtA []byte, err error) {
782 size := m.Size()
783 dAtA = make([]byte, size)
784 n, err := m.MarshalToSizedBuffer(dAtA[:size])
785 if err != nil {
786 return nil, err
787 }
788 return dAtA[:n], nil
789 }
790
791 func (m *MemoryStat) MarshalTo(dAtA []byte) (int, error) {
792 size := m.Size()
793 return m.MarshalToSizedBuffer(dAtA[:size])
794 }
795
796 func (m *MemoryStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
797 i := len(dAtA)
798 _ = i
799 var l int
800 _ = l
801 if m.XXX_unrecognized != nil {
802 i -= len(m.XXX_unrecognized)
803 copy(dAtA[i:], m.XXX_unrecognized)
804 }
805 if m.SwapLimit != 0 {
806 i = encodeVarintMetrics(dAtA, i, uint64(m.SwapLimit))
807 i--
808 dAtA[i] = 0x2
809 i--
810 dAtA[i] = 0x98
811 }
812 if m.SwapUsage != 0 {
813 i = encodeVarintMetrics(dAtA, i, uint64(m.SwapUsage))
814 i--
815 dAtA[i] = 0x2
816 i--
817 dAtA[i] = 0x90
818 }
819 if m.UsageLimit != 0 {
820 i = encodeVarintMetrics(dAtA, i, uint64(m.UsageLimit))
821 i--
822 dAtA[i] = 0x2
823 i--
824 dAtA[i] = 0x88
825 }
826 if m.Usage != 0 {
827 i = encodeVarintMetrics(dAtA, i, uint64(m.Usage))
828 i--
829 dAtA[i] = 0x2
830 i--
831 dAtA[i] = 0x80
832 }
833 if m.ThpCollapseAlloc != 0 {
834 i = encodeVarintMetrics(dAtA, i, uint64(m.ThpCollapseAlloc))
835 i--
836 dAtA[i] = 0x1
837 i--
838 dAtA[i] = 0xf8
839 }
840 if m.ThpFaultAlloc != 0 {
841 i = encodeVarintMetrics(dAtA, i, uint64(m.ThpFaultAlloc))
842 i--
843 dAtA[i] = 0x1
844 i--
845 dAtA[i] = 0xf0
846 }
847 if m.Pglazyfreed != 0 {
848 i = encodeVarintMetrics(dAtA, i, uint64(m.Pglazyfreed))
849 i--
850 dAtA[i] = 0x1
851 i--
852 dAtA[i] = 0xe8
853 }
854 if m.Pglazyfree != 0 {
855 i = encodeVarintMetrics(dAtA, i, uint64(m.Pglazyfree))
856 i--
857 dAtA[i] = 0x1
858 i--
859 dAtA[i] = 0xe0
860 }
861 if m.Pgdeactivate != 0 {
862 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgdeactivate))
863 i--
864 dAtA[i] = 0x1
865 i--
866 dAtA[i] = 0xd8
867 }
868 if m.Pgactivate != 0 {
869 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgactivate))
870 i--
871 dAtA[i] = 0x1
872 i--
873 dAtA[i] = 0xd0
874 }
875 if m.Pgsteal != 0 {
876 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgsteal))
877 i--
878 dAtA[i] = 0x1
879 i--
880 dAtA[i] = 0xc8
881 }
882 if m.Pgscan != 0 {
883 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgscan))
884 i--
885 dAtA[i] = 0x1
886 i--
887 dAtA[i] = 0xc0
888 }
889 if m.Pgrefill != 0 {
890 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgrefill))
891 i--
892 dAtA[i] = 0x1
893 i--
894 dAtA[i] = 0xb8
895 }
896 if m.WorkingsetNodereclaim != 0 {
897 i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetNodereclaim))
898 i--
899 dAtA[i] = 0x1
900 i--
901 dAtA[i] = 0xb0
902 }
903 if m.WorkingsetActivate != 0 {
904 i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetActivate))
905 i--
906 dAtA[i] = 0x1
907 i--
908 dAtA[i] = 0xa8
909 }
910 if m.WorkingsetRefault != 0 {
911 i = encodeVarintMetrics(dAtA, i, uint64(m.WorkingsetRefault))
912 i--
913 dAtA[i] = 0x1
914 i--
915 dAtA[i] = 0xa0
916 }
917 if m.Pgmajfault != 0 {
918 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgmajfault))
919 i--
920 dAtA[i] = 0x1
921 i--
922 dAtA[i] = 0x98
923 }
924 if m.Pgfault != 0 {
925 i = encodeVarintMetrics(dAtA, i, uint64(m.Pgfault))
926 i--
927 dAtA[i] = 0x1
928 i--
929 dAtA[i] = 0x90
930 }
931 if m.SlabUnreclaimable != 0 {
932 i = encodeVarintMetrics(dAtA, i, uint64(m.SlabUnreclaimable))
933 i--
934 dAtA[i] = 0x1
935 i--
936 dAtA[i] = 0x88
937 }
938 if m.SlabReclaimable != 0 {
939 i = encodeVarintMetrics(dAtA, i, uint64(m.SlabReclaimable))
940 i--
941 dAtA[i] = 0x1
942 i--
943 dAtA[i] = 0x80
944 }
945 if m.Unevictable != 0 {
946 i = encodeVarintMetrics(dAtA, i, uint64(m.Unevictable))
947 i--
948 dAtA[i] = 0x78
949 }
950 if m.ActiveFile != 0 {
951 i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveFile))
952 i--
953 dAtA[i] = 0x70
954 }
955 if m.InactiveFile != 0 {
956 i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveFile))
957 i--
958 dAtA[i] = 0x68
959 }
960 if m.ActiveAnon != 0 {
961 i = encodeVarintMetrics(dAtA, i, uint64(m.ActiveAnon))
962 i--
963 dAtA[i] = 0x60
964 }
965 if m.InactiveAnon != 0 {
966 i = encodeVarintMetrics(dAtA, i, uint64(m.InactiveAnon))
967 i--
968 dAtA[i] = 0x58
969 }
970 if m.AnonThp != 0 {
971 i = encodeVarintMetrics(dAtA, i, uint64(m.AnonThp))
972 i--
973 dAtA[i] = 0x50
974 }
975 if m.FileWriteback != 0 {
976 i = encodeVarintMetrics(dAtA, i, uint64(m.FileWriteback))
977 i--
978 dAtA[i] = 0x48
979 }
980 if m.FileDirty != 0 {
981 i = encodeVarintMetrics(dAtA, i, uint64(m.FileDirty))
982 i--
983 dAtA[i] = 0x40
984 }
985 if m.FileMapped != 0 {
986 i = encodeVarintMetrics(dAtA, i, uint64(m.FileMapped))
987 i--
988 dAtA[i] = 0x38
989 }
990 if m.Shmem != 0 {
991 i = encodeVarintMetrics(dAtA, i, uint64(m.Shmem))
992 i--
993 dAtA[i] = 0x30
994 }
995 if m.Sock != 0 {
996 i = encodeVarintMetrics(dAtA, i, uint64(m.Sock))
997 i--
998 dAtA[i] = 0x28
999 }
1000 if m.Slab != 0 {
1001 i = encodeVarintMetrics(dAtA, i, uint64(m.Slab))
1002 i--
1003 dAtA[i] = 0x20
1004 }
1005 if m.KernelStack != 0 {
1006 i = encodeVarintMetrics(dAtA, i, uint64(m.KernelStack))
1007 i--
1008 dAtA[i] = 0x18
1009 }
1010 if m.File != 0 {
1011 i = encodeVarintMetrics(dAtA, i, uint64(m.File))
1012 i--
1013 dAtA[i] = 0x10
1014 }
1015 if m.Anon != 0 {
1016 i = encodeVarintMetrics(dAtA, i, uint64(m.Anon))
1017 i--
1018 dAtA[i] = 0x8
1019 }
1020 return len(dAtA) - i, nil
1021 }
1022
1023 func (m *MemoryEvents) Marshal() (dAtA []byte, err error) {
1024 size := m.Size()
1025 dAtA = make([]byte, size)
1026 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1027 if err != nil {
1028 return nil, err
1029 }
1030 return dAtA[:n], nil
1031 }
1032
1033 func (m *MemoryEvents) MarshalTo(dAtA []byte) (int, error) {
1034 size := m.Size()
1035 return m.MarshalToSizedBuffer(dAtA[:size])
1036 }
1037
1038 func (m *MemoryEvents) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1039 i := len(dAtA)
1040 _ = i
1041 var l int
1042 _ = l
1043 if m.XXX_unrecognized != nil {
1044 i -= len(m.XXX_unrecognized)
1045 copy(dAtA[i:], m.XXX_unrecognized)
1046 }
1047 if m.OomKill != 0 {
1048 i = encodeVarintMetrics(dAtA, i, uint64(m.OomKill))
1049 i--
1050 dAtA[i] = 0x28
1051 }
1052 if m.Oom != 0 {
1053 i = encodeVarintMetrics(dAtA, i, uint64(m.Oom))
1054 i--
1055 dAtA[i] = 0x20
1056 }
1057 if m.Max != 0 {
1058 i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
1059 i--
1060 dAtA[i] = 0x18
1061 }
1062 if m.High != 0 {
1063 i = encodeVarintMetrics(dAtA, i, uint64(m.High))
1064 i--
1065 dAtA[i] = 0x10
1066 }
1067 if m.Low != 0 {
1068 i = encodeVarintMetrics(dAtA, i, uint64(m.Low))
1069 i--
1070 dAtA[i] = 0x8
1071 }
1072 return len(dAtA) - i, nil
1073 }
1074
1075 func (m *RdmaStat) Marshal() (dAtA []byte, err error) {
1076 size := m.Size()
1077 dAtA = make([]byte, size)
1078 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1079 if err != nil {
1080 return nil, err
1081 }
1082 return dAtA[:n], nil
1083 }
1084
1085 func (m *RdmaStat) MarshalTo(dAtA []byte) (int, error) {
1086 size := m.Size()
1087 return m.MarshalToSizedBuffer(dAtA[:size])
1088 }
1089
1090 func (m *RdmaStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1091 i := len(dAtA)
1092 _ = i
1093 var l int
1094 _ = l
1095 if m.XXX_unrecognized != nil {
1096 i -= len(m.XXX_unrecognized)
1097 copy(dAtA[i:], m.XXX_unrecognized)
1098 }
1099 if len(m.Limit) > 0 {
1100 for iNdEx := len(m.Limit) - 1; iNdEx >= 0; iNdEx-- {
1101 {
1102 size, err := m.Limit[iNdEx].MarshalToSizedBuffer(dAtA[:i])
1103 if err != nil {
1104 return 0, err
1105 }
1106 i -= size
1107 i = encodeVarintMetrics(dAtA, i, uint64(size))
1108 }
1109 i--
1110 dAtA[i] = 0x12
1111 }
1112 }
1113 if len(m.Current) > 0 {
1114 for iNdEx := len(m.Current) - 1; iNdEx >= 0; iNdEx-- {
1115 {
1116 size, err := m.Current[iNdEx].MarshalToSizedBuffer(dAtA[:i])
1117 if err != nil {
1118 return 0, err
1119 }
1120 i -= size
1121 i = encodeVarintMetrics(dAtA, i, uint64(size))
1122 }
1123 i--
1124 dAtA[i] = 0xa
1125 }
1126 }
1127 return len(dAtA) - i, nil
1128 }
1129
1130 func (m *RdmaEntry) Marshal() (dAtA []byte, err error) {
1131 size := m.Size()
1132 dAtA = make([]byte, size)
1133 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1134 if err != nil {
1135 return nil, err
1136 }
1137 return dAtA[:n], nil
1138 }
1139
1140 func (m *RdmaEntry) MarshalTo(dAtA []byte) (int, error) {
1141 size := m.Size()
1142 return m.MarshalToSizedBuffer(dAtA[:size])
1143 }
1144
1145 func (m *RdmaEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1146 i := len(dAtA)
1147 _ = i
1148 var l int
1149 _ = l
1150 if m.XXX_unrecognized != nil {
1151 i -= len(m.XXX_unrecognized)
1152 copy(dAtA[i:], m.XXX_unrecognized)
1153 }
1154 if m.HcaObjects != 0 {
1155 i = encodeVarintMetrics(dAtA, i, uint64(m.HcaObjects))
1156 i--
1157 dAtA[i] = 0x18
1158 }
1159 if m.HcaHandles != 0 {
1160 i = encodeVarintMetrics(dAtA, i, uint64(m.HcaHandles))
1161 i--
1162 dAtA[i] = 0x10
1163 }
1164 if len(m.Device) > 0 {
1165 i -= len(m.Device)
1166 copy(dAtA[i:], m.Device)
1167 i = encodeVarintMetrics(dAtA, i, uint64(len(m.Device)))
1168 i--
1169 dAtA[i] = 0xa
1170 }
1171 return len(dAtA) - i, nil
1172 }
1173
1174 func (m *IOStat) Marshal() (dAtA []byte, err error) {
1175 size := m.Size()
1176 dAtA = make([]byte, size)
1177 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1178 if err != nil {
1179 return nil, err
1180 }
1181 return dAtA[:n], nil
1182 }
1183
1184 func (m *IOStat) MarshalTo(dAtA []byte) (int, error) {
1185 size := m.Size()
1186 return m.MarshalToSizedBuffer(dAtA[:size])
1187 }
1188
1189 func (m *IOStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1190 i := len(dAtA)
1191 _ = i
1192 var l int
1193 _ = l
1194 if m.XXX_unrecognized != nil {
1195 i -= len(m.XXX_unrecognized)
1196 copy(dAtA[i:], m.XXX_unrecognized)
1197 }
1198 if len(m.Usage) > 0 {
1199 for iNdEx := len(m.Usage) - 1; iNdEx >= 0; iNdEx-- {
1200 {
1201 size, err := m.Usage[iNdEx].MarshalToSizedBuffer(dAtA[:i])
1202 if err != nil {
1203 return 0, err
1204 }
1205 i -= size
1206 i = encodeVarintMetrics(dAtA, i, uint64(size))
1207 }
1208 i--
1209 dAtA[i] = 0xa
1210 }
1211 }
1212 return len(dAtA) - i, nil
1213 }
1214
1215 func (m *IOEntry) Marshal() (dAtA []byte, err error) {
1216 size := m.Size()
1217 dAtA = make([]byte, size)
1218 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1219 if err != nil {
1220 return nil, err
1221 }
1222 return dAtA[:n], nil
1223 }
1224
1225 func (m *IOEntry) MarshalTo(dAtA []byte) (int, error) {
1226 size := m.Size()
1227 return m.MarshalToSizedBuffer(dAtA[:size])
1228 }
1229
1230 func (m *IOEntry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1231 i := len(dAtA)
1232 _ = i
1233 var l int
1234 _ = l
1235 if m.XXX_unrecognized != nil {
1236 i -= len(m.XXX_unrecognized)
1237 copy(dAtA[i:], m.XXX_unrecognized)
1238 }
1239 if m.Wios != 0 {
1240 i = encodeVarintMetrics(dAtA, i, uint64(m.Wios))
1241 i--
1242 dAtA[i] = 0x30
1243 }
1244 if m.Rios != 0 {
1245 i = encodeVarintMetrics(dAtA, i, uint64(m.Rios))
1246 i--
1247 dAtA[i] = 0x28
1248 }
1249 if m.Wbytes != 0 {
1250 i = encodeVarintMetrics(dAtA, i, uint64(m.Wbytes))
1251 i--
1252 dAtA[i] = 0x20
1253 }
1254 if m.Rbytes != 0 {
1255 i = encodeVarintMetrics(dAtA, i, uint64(m.Rbytes))
1256 i--
1257 dAtA[i] = 0x18
1258 }
1259 if m.Minor != 0 {
1260 i = encodeVarintMetrics(dAtA, i, uint64(m.Minor))
1261 i--
1262 dAtA[i] = 0x10
1263 }
1264 if m.Major != 0 {
1265 i = encodeVarintMetrics(dAtA, i, uint64(m.Major))
1266 i--
1267 dAtA[i] = 0x8
1268 }
1269 return len(dAtA) - i, nil
1270 }
1271
1272 func (m *HugeTlbStat) Marshal() (dAtA []byte, err error) {
1273 size := m.Size()
1274 dAtA = make([]byte, size)
1275 n, err := m.MarshalToSizedBuffer(dAtA[:size])
1276 if err != nil {
1277 return nil, err
1278 }
1279 return dAtA[:n], nil
1280 }
1281
1282 func (m *HugeTlbStat) MarshalTo(dAtA []byte) (int, error) {
1283 size := m.Size()
1284 return m.MarshalToSizedBuffer(dAtA[:size])
1285 }
1286
1287 func (m *HugeTlbStat) MarshalToSizedBuffer(dAtA []byte) (int, error) {
1288 i := len(dAtA)
1289 _ = i
1290 var l int
1291 _ = l
1292 if m.XXX_unrecognized != nil {
1293 i -= len(m.XXX_unrecognized)
1294 copy(dAtA[i:], m.XXX_unrecognized)
1295 }
1296 if len(m.Pagesize) > 0 {
1297 i -= len(m.Pagesize)
1298 copy(dAtA[i:], m.Pagesize)
1299 i = encodeVarintMetrics(dAtA, i, uint64(len(m.Pagesize)))
1300 i--
1301 dAtA[i] = 0x1a
1302 }
1303 if m.Max != 0 {
1304 i = encodeVarintMetrics(dAtA, i, uint64(m.Max))
1305 i--
1306 dAtA[i] = 0x10
1307 }
1308 if m.Current != 0 {
1309 i = encodeVarintMetrics(dAtA, i, uint64(m.Current))
1310 i--
1311 dAtA[i] = 0x8
1312 }
1313 return len(dAtA) - i, nil
1314 }
1315
1316 func encodeVarintMetrics(dAtA []byte, offset int, v uint64) int {
1317 offset -= sovMetrics(v)
1318 base := offset
1319 for v >= 1<<7 {
1320 dAtA[offset] = uint8(v&0x7f | 0x80)
1321 v >>= 7
1322 offset++
1323 }
1324 dAtA[offset] = uint8(v)
1325 return base
1326 }
1327 func (m *Metrics) Size() (n int) {
1328 if m == nil {
1329 return 0
1330 }
1331 var l int
1332 _ = l
1333 if m.Pids != nil {
1334 l = m.Pids.Size()
1335 n += 1 + l + sovMetrics(uint64(l))
1336 }
1337 if m.CPU != nil {
1338 l = m.CPU.Size()
1339 n += 1 + l + sovMetrics(uint64(l))
1340 }
1341 if m.Memory != nil {
1342 l = m.Memory.Size()
1343 n += 1 + l + sovMetrics(uint64(l))
1344 }
1345 if m.Rdma != nil {
1346 l = m.Rdma.Size()
1347 n += 1 + l + sovMetrics(uint64(l))
1348 }
1349 if m.Io != nil {
1350 l = m.Io.Size()
1351 n += 1 + l + sovMetrics(uint64(l))
1352 }
1353 if len(m.Hugetlb) > 0 {
1354 for _, e := range m.Hugetlb {
1355 l = e.Size()
1356 n += 1 + l + sovMetrics(uint64(l))
1357 }
1358 }
1359 if m.MemoryEvents != nil {
1360 l = m.MemoryEvents.Size()
1361 n += 1 + l + sovMetrics(uint64(l))
1362 }
1363 if m.XXX_unrecognized != nil {
1364 n += len(m.XXX_unrecognized)
1365 }
1366 return n
1367 }
1368
1369 func (m *PidsStat) Size() (n int) {
1370 if m == nil {
1371 return 0
1372 }
1373 var l int
1374 _ = l
1375 if m.Current != 0 {
1376 n += 1 + sovMetrics(uint64(m.Current))
1377 }
1378 if m.Limit != 0 {
1379 n += 1 + sovMetrics(uint64(m.Limit))
1380 }
1381 if m.XXX_unrecognized != nil {
1382 n += len(m.XXX_unrecognized)
1383 }
1384 return n
1385 }
1386
1387 func (m *CPUStat) Size() (n int) {
1388 if m == nil {
1389 return 0
1390 }
1391 var l int
1392 _ = l
1393 if m.UsageUsec != 0 {
1394 n += 1 + sovMetrics(uint64(m.UsageUsec))
1395 }
1396 if m.UserUsec != 0 {
1397 n += 1 + sovMetrics(uint64(m.UserUsec))
1398 }
1399 if m.SystemUsec != 0 {
1400 n += 1 + sovMetrics(uint64(m.SystemUsec))
1401 }
1402 if m.NrPeriods != 0 {
1403 n += 1 + sovMetrics(uint64(m.NrPeriods))
1404 }
1405 if m.NrThrottled != 0 {
1406 n += 1 + sovMetrics(uint64(m.NrThrottled))
1407 }
1408 if m.ThrottledUsec != 0 {
1409 n += 1 + sovMetrics(uint64(m.ThrottledUsec))
1410 }
1411 if m.XXX_unrecognized != nil {
1412 n += len(m.XXX_unrecognized)
1413 }
1414 return n
1415 }
1416
1417 func (m *MemoryStat) Size() (n int) {
1418 if m == nil {
1419 return 0
1420 }
1421 var l int
1422 _ = l
1423 if m.Anon != 0 {
1424 n += 1 + sovMetrics(uint64(m.Anon))
1425 }
1426 if m.File != 0 {
1427 n += 1 + sovMetrics(uint64(m.File))
1428 }
1429 if m.KernelStack != 0 {
1430 n += 1 + sovMetrics(uint64(m.KernelStack))
1431 }
1432 if m.Slab != 0 {
1433 n += 1 + sovMetrics(uint64(m.Slab))
1434 }
1435 if m.Sock != 0 {
1436 n += 1 + sovMetrics(uint64(m.Sock))
1437 }
1438 if m.Shmem != 0 {
1439 n += 1 + sovMetrics(uint64(m.Shmem))
1440 }
1441 if m.FileMapped != 0 {
1442 n += 1 + sovMetrics(uint64(m.FileMapped))
1443 }
1444 if m.FileDirty != 0 {
1445 n += 1 + sovMetrics(uint64(m.FileDirty))
1446 }
1447 if m.FileWriteback != 0 {
1448 n += 1 + sovMetrics(uint64(m.FileWriteback))
1449 }
1450 if m.AnonThp != 0 {
1451 n += 1 + sovMetrics(uint64(m.AnonThp))
1452 }
1453 if m.InactiveAnon != 0 {
1454 n += 1 + sovMetrics(uint64(m.InactiveAnon))
1455 }
1456 if m.ActiveAnon != 0 {
1457 n += 1 + sovMetrics(uint64(m.ActiveAnon))
1458 }
1459 if m.InactiveFile != 0 {
1460 n += 1 + sovMetrics(uint64(m.InactiveFile))
1461 }
1462 if m.ActiveFile != 0 {
1463 n += 1 + sovMetrics(uint64(m.ActiveFile))
1464 }
1465 if m.Unevictable != 0 {
1466 n += 1 + sovMetrics(uint64(m.Unevictable))
1467 }
1468 if m.SlabReclaimable != 0 {
1469 n += 2 + sovMetrics(uint64(m.SlabReclaimable))
1470 }
1471 if m.SlabUnreclaimable != 0 {
1472 n += 2 + sovMetrics(uint64(m.SlabUnreclaimable))
1473 }
1474 if m.Pgfault != 0 {
1475 n += 2 + sovMetrics(uint64(m.Pgfault))
1476 }
1477 if m.Pgmajfault != 0 {
1478 n += 2 + sovMetrics(uint64(m.Pgmajfault))
1479 }
1480 if m.WorkingsetRefault != 0 {
1481 n += 2 + sovMetrics(uint64(m.WorkingsetRefault))
1482 }
1483 if m.WorkingsetActivate != 0 {
1484 n += 2 + sovMetrics(uint64(m.WorkingsetActivate))
1485 }
1486 if m.WorkingsetNodereclaim != 0 {
1487 n += 2 + sovMetrics(uint64(m.WorkingsetNodereclaim))
1488 }
1489 if m.Pgrefill != 0 {
1490 n += 2 + sovMetrics(uint64(m.Pgrefill))
1491 }
1492 if m.Pgscan != 0 {
1493 n += 2 + sovMetrics(uint64(m.Pgscan))
1494 }
1495 if m.Pgsteal != 0 {
1496 n += 2 + sovMetrics(uint64(m.Pgsteal))
1497 }
1498 if m.Pgactivate != 0 {
1499 n += 2 + sovMetrics(uint64(m.Pgactivate))
1500 }
1501 if m.Pgdeactivate != 0 {
1502 n += 2 + sovMetrics(uint64(m.Pgdeactivate))
1503 }
1504 if m.Pglazyfree != 0 {
1505 n += 2 + sovMetrics(uint64(m.Pglazyfree))
1506 }
1507 if m.Pglazyfreed != 0 {
1508 n += 2 + sovMetrics(uint64(m.Pglazyfreed))
1509 }
1510 if m.ThpFaultAlloc != 0 {
1511 n += 2 + sovMetrics(uint64(m.ThpFaultAlloc))
1512 }
1513 if m.ThpCollapseAlloc != 0 {
1514 n += 2 + sovMetrics(uint64(m.ThpCollapseAlloc))
1515 }
1516 if m.Usage != 0 {
1517 n += 2 + sovMetrics(uint64(m.Usage))
1518 }
1519 if m.UsageLimit != 0 {
1520 n += 2 + sovMetrics(uint64(m.UsageLimit))
1521 }
1522 if m.SwapUsage != 0 {
1523 n += 2 + sovMetrics(uint64(m.SwapUsage))
1524 }
1525 if m.SwapLimit != 0 {
1526 n += 2 + sovMetrics(uint64(m.SwapLimit))
1527 }
1528 if m.XXX_unrecognized != nil {
1529 n += len(m.XXX_unrecognized)
1530 }
1531 return n
1532 }
1533
1534 func (m *MemoryEvents) Size() (n int) {
1535 if m == nil {
1536 return 0
1537 }
1538 var l int
1539 _ = l
1540 if m.Low != 0 {
1541 n += 1 + sovMetrics(uint64(m.Low))
1542 }
1543 if m.High != 0 {
1544 n += 1 + sovMetrics(uint64(m.High))
1545 }
1546 if m.Max != 0 {
1547 n += 1 + sovMetrics(uint64(m.Max))
1548 }
1549 if m.Oom != 0 {
1550 n += 1 + sovMetrics(uint64(m.Oom))
1551 }
1552 if m.OomKill != 0 {
1553 n += 1 + sovMetrics(uint64(m.OomKill))
1554 }
1555 if m.XXX_unrecognized != nil {
1556 n += len(m.XXX_unrecognized)
1557 }
1558 return n
1559 }
1560
1561 func (m *RdmaStat) Size() (n int) {
1562 if m == nil {
1563 return 0
1564 }
1565 var l int
1566 _ = l
1567 if len(m.Current) > 0 {
1568 for _, e := range m.Current {
1569 l = e.Size()
1570 n += 1 + l + sovMetrics(uint64(l))
1571 }
1572 }
1573 if len(m.Limit) > 0 {
1574 for _, e := range m.Limit {
1575 l = e.Size()
1576 n += 1 + l + sovMetrics(uint64(l))
1577 }
1578 }
1579 if m.XXX_unrecognized != nil {
1580 n += len(m.XXX_unrecognized)
1581 }
1582 return n
1583 }
1584
1585 func (m *RdmaEntry) Size() (n int) {
1586 if m == nil {
1587 return 0
1588 }
1589 var l int
1590 _ = l
1591 l = len(m.Device)
1592 if l > 0 {
1593 n += 1 + l + sovMetrics(uint64(l))
1594 }
1595 if m.HcaHandles != 0 {
1596 n += 1 + sovMetrics(uint64(m.HcaHandles))
1597 }
1598 if m.HcaObjects != 0 {
1599 n += 1 + sovMetrics(uint64(m.HcaObjects))
1600 }
1601 if m.XXX_unrecognized != nil {
1602 n += len(m.XXX_unrecognized)
1603 }
1604 return n
1605 }
1606
1607 func (m *IOStat) Size() (n int) {
1608 if m == nil {
1609 return 0
1610 }
1611 var l int
1612 _ = l
1613 if len(m.Usage) > 0 {
1614 for _, e := range m.Usage {
1615 l = e.Size()
1616 n += 1 + l + sovMetrics(uint64(l))
1617 }
1618 }
1619 if m.XXX_unrecognized != nil {
1620 n += len(m.XXX_unrecognized)
1621 }
1622 return n
1623 }
1624
1625 func (m *IOEntry) Size() (n int) {
1626 if m == nil {
1627 return 0
1628 }
1629 var l int
1630 _ = l
1631 if m.Major != 0 {
1632 n += 1 + sovMetrics(uint64(m.Major))
1633 }
1634 if m.Minor != 0 {
1635 n += 1 + sovMetrics(uint64(m.Minor))
1636 }
1637 if m.Rbytes != 0 {
1638 n += 1 + sovMetrics(uint64(m.Rbytes))
1639 }
1640 if m.Wbytes != 0 {
1641 n += 1 + sovMetrics(uint64(m.Wbytes))
1642 }
1643 if m.Rios != 0 {
1644 n += 1 + sovMetrics(uint64(m.Rios))
1645 }
1646 if m.Wios != 0 {
1647 n += 1 + sovMetrics(uint64(m.Wios))
1648 }
1649 if m.XXX_unrecognized != nil {
1650 n += len(m.XXX_unrecognized)
1651 }
1652 return n
1653 }
1654
1655 func (m *HugeTlbStat) Size() (n int) {
1656 if m == nil {
1657 return 0
1658 }
1659 var l int
1660 _ = l
1661 if m.Current != 0 {
1662 n += 1 + sovMetrics(uint64(m.Current))
1663 }
1664 if m.Max != 0 {
1665 n += 1 + sovMetrics(uint64(m.Max))
1666 }
1667 l = len(m.Pagesize)
1668 if l > 0 {
1669 n += 1 + l + sovMetrics(uint64(l))
1670 }
1671 if m.XXX_unrecognized != nil {
1672 n += len(m.XXX_unrecognized)
1673 }
1674 return n
1675 }
1676
1677 func sovMetrics(x uint64) (n int) {
1678 return (math_bits.Len64(x|1) + 6) / 7
1679 }
1680 func sozMetrics(x uint64) (n int) {
1681 return sovMetrics(uint64((x << 1) ^ uint64((int64(x) >> 63))))
1682 }
1683 func (this *Metrics) String() string {
1684 if this == nil {
1685 return "nil"
1686 }
1687 repeatedStringForHugetlb := "[]*HugeTlbStat{"
1688 for _, f := range this.Hugetlb {
1689 repeatedStringForHugetlb += strings.Replace(f.String(), "HugeTlbStat", "HugeTlbStat", 1) + ","
1690 }
1691 repeatedStringForHugetlb += "}"
1692 s := strings.Join([]string{`&Metrics{`,
1693 `Pids:` + strings.Replace(this.Pids.String(), "PidsStat", "PidsStat", 1) + `,`,
1694 `CPU:` + strings.Replace(this.CPU.String(), "CPUStat", "CPUStat", 1) + `,`,
1695 `Memory:` + strings.Replace(this.Memory.String(), "MemoryStat", "MemoryStat", 1) + `,`,
1696 `Rdma:` + strings.Replace(this.Rdma.String(), "RdmaStat", "RdmaStat", 1) + `,`,
1697 `Io:` + strings.Replace(this.Io.String(), "IOStat", "IOStat", 1) + `,`,
1698 `Hugetlb:` + repeatedStringForHugetlb + `,`,
1699 `MemoryEvents:` + strings.Replace(this.MemoryEvents.String(), "MemoryEvents", "MemoryEvents", 1) + `,`,
1700 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1701 `}`,
1702 }, "")
1703 return s
1704 }
1705 func (this *PidsStat) String() string {
1706 if this == nil {
1707 return "nil"
1708 }
1709 s := strings.Join([]string{`&PidsStat{`,
1710 `Current:` + fmt.Sprintf("%v", this.Current) + `,`,
1711 `Limit:` + fmt.Sprintf("%v", this.Limit) + `,`,
1712 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1713 `}`,
1714 }, "")
1715 return s
1716 }
1717 func (this *CPUStat) String() string {
1718 if this == nil {
1719 return "nil"
1720 }
1721 s := strings.Join([]string{`&CPUStat{`,
1722 `UsageUsec:` + fmt.Sprintf("%v", this.UsageUsec) + `,`,
1723 `UserUsec:` + fmt.Sprintf("%v", this.UserUsec) + `,`,
1724 `SystemUsec:` + fmt.Sprintf("%v", this.SystemUsec) + `,`,
1725 `NrPeriods:` + fmt.Sprintf("%v", this.NrPeriods) + `,`,
1726 `NrThrottled:` + fmt.Sprintf("%v", this.NrThrottled) + `,`,
1727 `ThrottledUsec:` + fmt.Sprintf("%v", this.ThrottledUsec) + `,`,
1728 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1729 `}`,
1730 }, "")
1731 return s
1732 }
1733 func (this *MemoryStat) String() string {
1734 if this == nil {
1735 return "nil"
1736 }
1737 s := strings.Join([]string{`&MemoryStat{`,
1738 `Anon:` + fmt.Sprintf("%v", this.Anon) + `,`,
1739 `File:` + fmt.Sprintf("%v", this.File) + `,`,
1740 `KernelStack:` + fmt.Sprintf("%v", this.KernelStack) + `,`,
1741 `Slab:` + fmt.Sprintf("%v", this.Slab) + `,`,
1742 `Sock:` + fmt.Sprintf("%v", this.Sock) + `,`,
1743 `Shmem:` + fmt.Sprintf("%v", this.Shmem) + `,`,
1744 `FileMapped:` + fmt.Sprintf("%v", this.FileMapped) + `,`,
1745 `FileDirty:` + fmt.Sprintf("%v", this.FileDirty) + `,`,
1746 `FileWriteback:` + fmt.Sprintf("%v", this.FileWriteback) + `,`,
1747 `AnonThp:` + fmt.Sprintf("%v", this.AnonThp) + `,`,
1748 `InactiveAnon:` + fmt.Sprintf("%v", this.InactiveAnon) + `,`,
1749 `ActiveAnon:` + fmt.Sprintf("%v", this.ActiveAnon) + `,`,
1750 `InactiveFile:` + fmt.Sprintf("%v", this.InactiveFile) + `,`,
1751 `ActiveFile:` + fmt.Sprintf("%v", this.ActiveFile) + `,`,
1752 `Unevictable:` + fmt.Sprintf("%v", this.Unevictable) + `,`,
1753 `SlabReclaimable:` + fmt.Sprintf("%v", this.SlabReclaimable) + `,`,
1754 `SlabUnreclaimable:` + fmt.Sprintf("%v", this.SlabUnreclaimable) + `,`,
1755 `Pgfault:` + fmt.Sprintf("%v", this.Pgfault) + `,`,
1756 `Pgmajfault:` + fmt.Sprintf("%v", this.Pgmajfault) + `,`,
1757 `WorkingsetRefault:` + fmt.Sprintf("%v", this.WorkingsetRefault) + `,`,
1758 `WorkingsetActivate:` + fmt.Sprintf("%v", this.WorkingsetActivate) + `,`,
1759 `WorkingsetNodereclaim:` + fmt.Sprintf("%v", this.WorkingsetNodereclaim) + `,`,
1760 `Pgrefill:` + fmt.Sprintf("%v", this.Pgrefill) + `,`,
1761 `Pgscan:` + fmt.Sprintf("%v", this.Pgscan) + `,`,
1762 `Pgsteal:` + fmt.Sprintf("%v", this.Pgsteal) + `,`,
1763 `Pgactivate:` + fmt.Sprintf("%v", this.Pgactivate) + `,`,
1764 `Pgdeactivate:` + fmt.Sprintf("%v", this.Pgdeactivate) + `,`,
1765 `Pglazyfree:` + fmt.Sprintf("%v", this.Pglazyfree) + `,`,
1766 `Pglazyfreed:` + fmt.Sprintf("%v", this.Pglazyfreed) + `,`,
1767 `ThpFaultAlloc:` + fmt.Sprintf("%v", this.ThpFaultAlloc) + `,`,
1768 `ThpCollapseAlloc:` + fmt.Sprintf("%v", this.ThpCollapseAlloc) + `,`,
1769 `Usage:` + fmt.Sprintf("%v", this.Usage) + `,`,
1770 `UsageLimit:` + fmt.Sprintf("%v", this.UsageLimit) + `,`,
1771 `SwapUsage:` + fmt.Sprintf("%v", this.SwapUsage) + `,`,
1772 `SwapLimit:` + fmt.Sprintf("%v", this.SwapLimit) + `,`,
1773 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1774 `}`,
1775 }, "")
1776 return s
1777 }
1778 func (this *MemoryEvents) String() string {
1779 if this == nil {
1780 return "nil"
1781 }
1782 s := strings.Join([]string{`&MemoryEvents{`,
1783 `Low:` + fmt.Sprintf("%v", this.Low) + `,`,
1784 `High:` + fmt.Sprintf("%v", this.High) + `,`,
1785 `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
1786 `Oom:` + fmt.Sprintf("%v", this.Oom) + `,`,
1787 `OomKill:` + fmt.Sprintf("%v", this.OomKill) + `,`,
1788 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1789 `}`,
1790 }, "")
1791 return s
1792 }
1793 func (this *RdmaStat) String() string {
1794 if this == nil {
1795 return "nil"
1796 }
1797 repeatedStringForCurrent := "[]*RdmaEntry{"
1798 for _, f := range this.Current {
1799 repeatedStringForCurrent += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
1800 }
1801 repeatedStringForCurrent += "}"
1802 repeatedStringForLimit := "[]*RdmaEntry{"
1803 for _, f := range this.Limit {
1804 repeatedStringForLimit += strings.Replace(f.String(), "RdmaEntry", "RdmaEntry", 1) + ","
1805 }
1806 repeatedStringForLimit += "}"
1807 s := strings.Join([]string{`&RdmaStat{`,
1808 `Current:` + repeatedStringForCurrent + `,`,
1809 `Limit:` + repeatedStringForLimit + `,`,
1810 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1811 `}`,
1812 }, "")
1813 return s
1814 }
1815 func (this *RdmaEntry) String() string {
1816 if this == nil {
1817 return "nil"
1818 }
1819 s := strings.Join([]string{`&RdmaEntry{`,
1820 `Device:` + fmt.Sprintf("%v", this.Device) + `,`,
1821 `HcaHandles:` + fmt.Sprintf("%v", this.HcaHandles) + `,`,
1822 `HcaObjects:` + fmt.Sprintf("%v", this.HcaObjects) + `,`,
1823 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1824 `}`,
1825 }, "")
1826 return s
1827 }
1828 func (this *IOStat) String() string {
1829 if this == nil {
1830 return "nil"
1831 }
1832 repeatedStringForUsage := "[]*IOEntry{"
1833 for _, f := range this.Usage {
1834 repeatedStringForUsage += strings.Replace(f.String(), "IOEntry", "IOEntry", 1) + ","
1835 }
1836 repeatedStringForUsage += "}"
1837 s := strings.Join([]string{`&IOStat{`,
1838 `Usage:` + repeatedStringForUsage + `,`,
1839 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1840 `}`,
1841 }, "")
1842 return s
1843 }
1844 func (this *IOEntry) String() string {
1845 if this == nil {
1846 return "nil"
1847 }
1848 s := strings.Join([]string{`&IOEntry{`,
1849 `Major:` + fmt.Sprintf("%v", this.Major) + `,`,
1850 `Minor:` + fmt.Sprintf("%v", this.Minor) + `,`,
1851 `Rbytes:` + fmt.Sprintf("%v", this.Rbytes) + `,`,
1852 `Wbytes:` + fmt.Sprintf("%v", this.Wbytes) + `,`,
1853 `Rios:` + fmt.Sprintf("%v", this.Rios) + `,`,
1854 `Wios:` + fmt.Sprintf("%v", this.Wios) + `,`,
1855 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1856 `}`,
1857 }, "")
1858 return s
1859 }
1860 func (this *HugeTlbStat) String() string {
1861 if this == nil {
1862 return "nil"
1863 }
1864 s := strings.Join([]string{`&HugeTlbStat{`,
1865 `Current:` + fmt.Sprintf("%v", this.Current) + `,`,
1866 `Max:` + fmt.Sprintf("%v", this.Max) + `,`,
1867 `Pagesize:` + fmt.Sprintf("%v", this.Pagesize) + `,`,
1868 `XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
1869 `}`,
1870 }, "")
1871 return s
1872 }
1873 func valueToStringMetrics(v interface{}) string {
1874 rv := reflect.ValueOf(v)
1875 if rv.IsNil() {
1876 return "nil"
1877 }
1878 pv := reflect.Indirect(rv).Interface()
1879 return fmt.Sprintf("*%v", pv)
1880 }
1881 func (m *Metrics) Unmarshal(dAtA []byte) error {
1882 l := len(dAtA)
1883 iNdEx := 0
1884 for iNdEx < l {
1885 preIndex := iNdEx
1886 var wire uint64
1887 for shift := uint(0); ; shift += 7 {
1888 if shift >= 64 {
1889 return ErrIntOverflowMetrics
1890 }
1891 if iNdEx >= l {
1892 return io.ErrUnexpectedEOF
1893 }
1894 b := dAtA[iNdEx]
1895 iNdEx++
1896 wire |= uint64(b&0x7F) << shift
1897 if b < 0x80 {
1898 break
1899 }
1900 }
1901 fieldNum := int32(wire >> 3)
1902 wireType := int(wire & 0x7)
1903 if wireType == 4 {
1904 return fmt.Errorf("proto: Metrics: wiretype end group for non-group")
1905 }
1906 if fieldNum <= 0 {
1907 return fmt.Errorf("proto: Metrics: illegal tag %d (wire type %d)", fieldNum, wire)
1908 }
1909 switch fieldNum {
1910 case 1:
1911 if wireType != 2 {
1912 return fmt.Errorf("proto: wrong wireType = %d for field Pids", wireType)
1913 }
1914 var msglen int
1915 for shift := uint(0); ; shift += 7 {
1916 if shift >= 64 {
1917 return ErrIntOverflowMetrics
1918 }
1919 if iNdEx >= l {
1920 return io.ErrUnexpectedEOF
1921 }
1922 b := dAtA[iNdEx]
1923 iNdEx++
1924 msglen |= int(b&0x7F) << shift
1925 if b < 0x80 {
1926 break
1927 }
1928 }
1929 if msglen < 0 {
1930 return ErrInvalidLengthMetrics
1931 }
1932 postIndex := iNdEx + msglen
1933 if postIndex < 0 {
1934 return ErrInvalidLengthMetrics
1935 }
1936 if postIndex > l {
1937 return io.ErrUnexpectedEOF
1938 }
1939 if m.Pids == nil {
1940 m.Pids = &PidsStat{}
1941 }
1942 if err := m.Pids.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
1943 return err
1944 }
1945 iNdEx = postIndex
1946 case 2:
1947 if wireType != 2 {
1948 return fmt.Errorf("proto: wrong wireType = %d for field CPU", wireType)
1949 }
1950 var msglen int
1951 for shift := uint(0); ; shift += 7 {
1952 if shift >= 64 {
1953 return ErrIntOverflowMetrics
1954 }
1955 if iNdEx >= l {
1956 return io.ErrUnexpectedEOF
1957 }
1958 b := dAtA[iNdEx]
1959 iNdEx++
1960 msglen |= int(b&0x7F) << shift
1961 if b < 0x80 {
1962 break
1963 }
1964 }
1965 if msglen < 0 {
1966 return ErrInvalidLengthMetrics
1967 }
1968 postIndex := iNdEx + msglen
1969 if postIndex < 0 {
1970 return ErrInvalidLengthMetrics
1971 }
1972 if postIndex > l {
1973 return io.ErrUnexpectedEOF
1974 }
1975 if m.CPU == nil {
1976 m.CPU = &CPUStat{}
1977 }
1978 if err := m.CPU.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
1979 return err
1980 }
1981 iNdEx = postIndex
1982 case 4:
1983 if wireType != 2 {
1984 return fmt.Errorf("proto: wrong wireType = %d for field Memory", wireType)
1985 }
1986 var msglen int
1987 for shift := uint(0); ; shift += 7 {
1988 if shift >= 64 {
1989 return ErrIntOverflowMetrics
1990 }
1991 if iNdEx >= l {
1992 return io.ErrUnexpectedEOF
1993 }
1994 b := dAtA[iNdEx]
1995 iNdEx++
1996 msglen |= int(b&0x7F) << shift
1997 if b < 0x80 {
1998 break
1999 }
2000 }
2001 if msglen < 0 {
2002 return ErrInvalidLengthMetrics
2003 }
2004 postIndex := iNdEx + msglen
2005 if postIndex < 0 {
2006 return ErrInvalidLengthMetrics
2007 }
2008 if postIndex > l {
2009 return io.ErrUnexpectedEOF
2010 }
2011 if m.Memory == nil {
2012 m.Memory = &MemoryStat{}
2013 }
2014 if err := m.Memory.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
2015 return err
2016 }
2017 iNdEx = postIndex
2018 case 5:
2019 if wireType != 2 {
2020 return fmt.Errorf("proto: wrong wireType = %d for field Rdma", wireType)
2021 }
2022 var msglen int
2023 for shift := uint(0); ; shift += 7 {
2024 if shift >= 64 {
2025 return ErrIntOverflowMetrics
2026 }
2027 if iNdEx >= l {
2028 return io.ErrUnexpectedEOF
2029 }
2030 b := dAtA[iNdEx]
2031 iNdEx++
2032 msglen |= int(b&0x7F) << shift
2033 if b < 0x80 {
2034 break
2035 }
2036 }
2037 if msglen < 0 {
2038 return ErrInvalidLengthMetrics
2039 }
2040 postIndex := iNdEx + msglen
2041 if postIndex < 0 {
2042 return ErrInvalidLengthMetrics
2043 }
2044 if postIndex > l {
2045 return io.ErrUnexpectedEOF
2046 }
2047 if m.Rdma == nil {
2048 m.Rdma = &RdmaStat{}
2049 }
2050 if err := m.Rdma.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
2051 return err
2052 }
2053 iNdEx = postIndex
2054 case 6:
2055 if wireType != 2 {
2056 return fmt.Errorf("proto: wrong wireType = %d for field Io", wireType)
2057 }
2058 var msglen int
2059 for shift := uint(0); ; shift += 7 {
2060 if shift >= 64 {
2061 return ErrIntOverflowMetrics
2062 }
2063 if iNdEx >= l {
2064 return io.ErrUnexpectedEOF
2065 }
2066 b := dAtA[iNdEx]
2067 iNdEx++
2068 msglen |= int(b&0x7F) << shift
2069 if b < 0x80 {
2070 break
2071 }
2072 }
2073 if msglen < 0 {
2074 return ErrInvalidLengthMetrics
2075 }
2076 postIndex := iNdEx + msglen
2077 if postIndex < 0 {
2078 return ErrInvalidLengthMetrics
2079 }
2080 if postIndex > l {
2081 return io.ErrUnexpectedEOF
2082 }
2083 if m.Io == nil {
2084 m.Io = &IOStat{}
2085 }
2086 if err := m.Io.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
2087 return err
2088 }
2089 iNdEx = postIndex
2090 case 7:
2091 if wireType != 2 {
2092 return fmt.Errorf("proto: wrong wireType = %d for field Hugetlb", wireType)
2093 }
2094 var msglen int
2095 for shift := uint(0); ; shift += 7 {
2096 if shift >= 64 {
2097 return ErrIntOverflowMetrics
2098 }
2099 if iNdEx >= l {
2100 return io.ErrUnexpectedEOF
2101 }
2102 b := dAtA[iNdEx]
2103 iNdEx++
2104 msglen |= int(b&0x7F) << shift
2105 if b < 0x80 {
2106 break
2107 }
2108 }
2109 if msglen < 0 {
2110 return ErrInvalidLengthMetrics
2111 }
2112 postIndex := iNdEx + msglen
2113 if postIndex < 0 {
2114 return ErrInvalidLengthMetrics
2115 }
2116 if postIndex > l {
2117 return io.ErrUnexpectedEOF
2118 }
2119 m.Hugetlb = append(m.Hugetlb, &HugeTlbStat{})
2120 if err := m.Hugetlb[len(m.Hugetlb)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
2121 return err
2122 }
2123 iNdEx = postIndex
2124 case 8:
2125 if wireType != 2 {
2126 return fmt.Errorf("proto: wrong wireType = %d for field MemoryEvents", wireType)
2127 }
2128 var msglen int
2129 for shift := uint(0); ; shift += 7 {
2130 if shift >= 64 {
2131 return ErrIntOverflowMetrics
2132 }
2133 if iNdEx >= l {
2134 return io.ErrUnexpectedEOF
2135 }
2136 b := dAtA[iNdEx]
2137 iNdEx++
2138 msglen |= int(b&0x7F) << shift
2139 if b < 0x80 {
2140 break
2141 }
2142 }
2143 if msglen < 0 {
2144 return ErrInvalidLengthMetrics
2145 }
2146 postIndex := iNdEx + msglen
2147 if postIndex < 0 {
2148 return ErrInvalidLengthMetrics
2149 }
2150 if postIndex > l {
2151 return io.ErrUnexpectedEOF
2152 }
2153 if m.MemoryEvents == nil {
2154 m.MemoryEvents = &MemoryEvents{}
2155 }
2156 if err := m.MemoryEvents.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
2157 return err
2158 }
2159 iNdEx = postIndex
2160 default:
2161 iNdEx = preIndex
2162 skippy, err := skipMetrics(dAtA[iNdEx:])
2163 if err != nil {
2164 return err
2165 }
2166 if (skippy < 0) || (iNdEx+skippy) < 0 {
2167 return ErrInvalidLengthMetrics
2168 }
2169 if (iNdEx + skippy) > l {
2170 return io.ErrUnexpectedEOF
2171 }
2172 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
2173 iNdEx += skippy
2174 }
2175 }
2176
2177 if iNdEx > l {
2178 return io.ErrUnexpectedEOF
2179 }
2180 return nil
2181 }
2182 func (m *PidsStat) Unmarshal(dAtA []byte) error {
2183 l := len(dAtA)
2184 iNdEx := 0
2185 for iNdEx < l {
2186 preIndex := iNdEx
2187 var wire uint64
2188 for shift := uint(0); ; shift += 7 {
2189 if shift >= 64 {
2190 return ErrIntOverflowMetrics
2191 }
2192 if iNdEx >= l {
2193 return io.ErrUnexpectedEOF
2194 }
2195 b := dAtA[iNdEx]
2196 iNdEx++
2197 wire |= uint64(b&0x7F) << shift
2198 if b < 0x80 {
2199 break
2200 }
2201 }
2202 fieldNum := int32(wire >> 3)
2203 wireType := int(wire & 0x7)
2204 if wireType == 4 {
2205 return fmt.Errorf("proto: PidsStat: wiretype end group for non-group")
2206 }
2207 if fieldNum <= 0 {
2208 return fmt.Errorf("proto: PidsStat: illegal tag %d (wire type %d)", fieldNum, wire)
2209 }
2210 switch fieldNum {
2211 case 1:
2212 if wireType != 0 {
2213 return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
2214 }
2215 m.Current = 0
2216 for shift := uint(0); ; shift += 7 {
2217 if shift >= 64 {
2218 return ErrIntOverflowMetrics
2219 }
2220 if iNdEx >= l {
2221 return io.ErrUnexpectedEOF
2222 }
2223 b := dAtA[iNdEx]
2224 iNdEx++
2225 m.Current |= uint64(b&0x7F) << shift
2226 if b < 0x80 {
2227 break
2228 }
2229 }
2230 case 2:
2231 if wireType != 0 {
2232 return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
2233 }
2234 m.Limit = 0
2235 for shift := uint(0); ; shift += 7 {
2236 if shift >= 64 {
2237 return ErrIntOverflowMetrics
2238 }
2239 if iNdEx >= l {
2240 return io.ErrUnexpectedEOF
2241 }
2242 b := dAtA[iNdEx]
2243 iNdEx++
2244 m.Limit |= uint64(b&0x7F) << shift
2245 if b < 0x80 {
2246 break
2247 }
2248 }
2249 default:
2250 iNdEx = preIndex
2251 skippy, err := skipMetrics(dAtA[iNdEx:])
2252 if err != nil {
2253 return err
2254 }
2255 if (skippy < 0) || (iNdEx+skippy) < 0 {
2256 return ErrInvalidLengthMetrics
2257 }
2258 if (iNdEx + skippy) > l {
2259 return io.ErrUnexpectedEOF
2260 }
2261 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
2262 iNdEx += skippy
2263 }
2264 }
2265
2266 if iNdEx > l {
2267 return io.ErrUnexpectedEOF
2268 }
2269 return nil
2270 }
2271 func (m *CPUStat) Unmarshal(dAtA []byte) error {
2272 l := len(dAtA)
2273 iNdEx := 0
2274 for iNdEx < l {
2275 preIndex := iNdEx
2276 var wire uint64
2277 for shift := uint(0); ; shift += 7 {
2278 if shift >= 64 {
2279 return ErrIntOverflowMetrics
2280 }
2281 if iNdEx >= l {
2282 return io.ErrUnexpectedEOF
2283 }
2284 b := dAtA[iNdEx]
2285 iNdEx++
2286 wire |= uint64(b&0x7F) << shift
2287 if b < 0x80 {
2288 break
2289 }
2290 }
2291 fieldNum := int32(wire >> 3)
2292 wireType := int(wire & 0x7)
2293 if wireType == 4 {
2294 return fmt.Errorf("proto: CPUStat: wiretype end group for non-group")
2295 }
2296 if fieldNum <= 0 {
2297 return fmt.Errorf("proto: CPUStat: illegal tag %d (wire type %d)", fieldNum, wire)
2298 }
2299 switch fieldNum {
2300 case 1:
2301 if wireType != 0 {
2302 return fmt.Errorf("proto: wrong wireType = %d for field UsageUsec", wireType)
2303 }
2304 m.UsageUsec = 0
2305 for shift := uint(0); ; shift += 7 {
2306 if shift >= 64 {
2307 return ErrIntOverflowMetrics
2308 }
2309 if iNdEx >= l {
2310 return io.ErrUnexpectedEOF
2311 }
2312 b := dAtA[iNdEx]
2313 iNdEx++
2314 m.UsageUsec |= uint64(b&0x7F) << shift
2315 if b < 0x80 {
2316 break
2317 }
2318 }
2319 case 2:
2320 if wireType != 0 {
2321 return fmt.Errorf("proto: wrong wireType = %d for field UserUsec", wireType)
2322 }
2323 m.UserUsec = 0
2324 for shift := uint(0); ; shift += 7 {
2325 if shift >= 64 {
2326 return ErrIntOverflowMetrics
2327 }
2328 if iNdEx >= l {
2329 return io.ErrUnexpectedEOF
2330 }
2331 b := dAtA[iNdEx]
2332 iNdEx++
2333 m.UserUsec |= uint64(b&0x7F) << shift
2334 if b < 0x80 {
2335 break
2336 }
2337 }
2338 case 3:
2339 if wireType != 0 {
2340 return fmt.Errorf("proto: wrong wireType = %d for field SystemUsec", wireType)
2341 }
2342 m.SystemUsec = 0
2343 for shift := uint(0); ; shift += 7 {
2344 if shift >= 64 {
2345 return ErrIntOverflowMetrics
2346 }
2347 if iNdEx >= l {
2348 return io.ErrUnexpectedEOF
2349 }
2350 b := dAtA[iNdEx]
2351 iNdEx++
2352 m.SystemUsec |= uint64(b&0x7F) << shift
2353 if b < 0x80 {
2354 break
2355 }
2356 }
2357 case 4:
2358 if wireType != 0 {
2359 return fmt.Errorf("proto: wrong wireType = %d for field NrPeriods", wireType)
2360 }
2361 m.NrPeriods = 0
2362 for shift := uint(0); ; shift += 7 {
2363 if shift >= 64 {
2364 return ErrIntOverflowMetrics
2365 }
2366 if iNdEx >= l {
2367 return io.ErrUnexpectedEOF
2368 }
2369 b := dAtA[iNdEx]
2370 iNdEx++
2371 m.NrPeriods |= uint64(b&0x7F) << shift
2372 if b < 0x80 {
2373 break
2374 }
2375 }
2376 case 5:
2377 if wireType != 0 {
2378 return fmt.Errorf("proto: wrong wireType = %d for field NrThrottled", wireType)
2379 }
2380 m.NrThrottled = 0
2381 for shift := uint(0); ; shift += 7 {
2382 if shift >= 64 {
2383 return ErrIntOverflowMetrics
2384 }
2385 if iNdEx >= l {
2386 return io.ErrUnexpectedEOF
2387 }
2388 b := dAtA[iNdEx]
2389 iNdEx++
2390 m.NrThrottled |= uint64(b&0x7F) << shift
2391 if b < 0x80 {
2392 break
2393 }
2394 }
2395 case 6:
2396 if wireType != 0 {
2397 return fmt.Errorf("proto: wrong wireType = %d for field ThrottledUsec", wireType)
2398 }
2399 m.ThrottledUsec = 0
2400 for shift := uint(0); ; shift += 7 {
2401 if shift >= 64 {
2402 return ErrIntOverflowMetrics
2403 }
2404 if iNdEx >= l {
2405 return io.ErrUnexpectedEOF
2406 }
2407 b := dAtA[iNdEx]
2408 iNdEx++
2409 m.ThrottledUsec |= uint64(b&0x7F) << shift
2410 if b < 0x80 {
2411 break
2412 }
2413 }
2414 default:
2415 iNdEx = preIndex
2416 skippy, err := skipMetrics(dAtA[iNdEx:])
2417 if err != nil {
2418 return err
2419 }
2420 if (skippy < 0) || (iNdEx+skippy) < 0 {
2421 return ErrInvalidLengthMetrics
2422 }
2423 if (iNdEx + skippy) > l {
2424 return io.ErrUnexpectedEOF
2425 }
2426 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
2427 iNdEx += skippy
2428 }
2429 }
2430
2431 if iNdEx > l {
2432 return io.ErrUnexpectedEOF
2433 }
2434 return nil
2435 }
2436 func (m *MemoryStat) Unmarshal(dAtA []byte) error {
2437 l := len(dAtA)
2438 iNdEx := 0
2439 for iNdEx < l {
2440 preIndex := iNdEx
2441 var wire uint64
2442 for shift := uint(0); ; shift += 7 {
2443 if shift >= 64 {
2444 return ErrIntOverflowMetrics
2445 }
2446 if iNdEx >= l {
2447 return io.ErrUnexpectedEOF
2448 }
2449 b := dAtA[iNdEx]
2450 iNdEx++
2451 wire |= uint64(b&0x7F) << shift
2452 if b < 0x80 {
2453 break
2454 }
2455 }
2456 fieldNum := int32(wire >> 3)
2457 wireType := int(wire & 0x7)
2458 if wireType == 4 {
2459 return fmt.Errorf("proto: MemoryStat: wiretype end group for non-group")
2460 }
2461 if fieldNum <= 0 {
2462 return fmt.Errorf("proto: MemoryStat: illegal tag %d (wire type %d)", fieldNum, wire)
2463 }
2464 switch fieldNum {
2465 case 1:
2466 if wireType != 0 {
2467 return fmt.Errorf("proto: wrong wireType = %d for field Anon", wireType)
2468 }
2469 m.Anon = 0
2470 for shift := uint(0); ; shift += 7 {
2471 if shift >= 64 {
2472 return ErrIntOverflowMetrics
2473 }
2474 if iNdEx >= l {
2475 return io.ErrUnexpectedEOF
2476 }
2477 b := dAtA[iNdEx]
2478 iNdEx++
2479 m.Anon |= uint64(b&0x7F) << shift
2480 if b < 0x80 {
2481 break
2482 }
2483 }
2484 case 2:
2485 if wireType != 0 {
2486 return fmt.Errorf("proto: wrong wireType = %d for field File", wireType)
2487 }
2488 m.File = 0
2489 for shift := uint(0); ; shift += 7 {
2490 if shift >= 64 {
2491 return ErrIntOverflowMetrics
2492 }
2493 if iNdEx >= l {
2494 return io.ErrUnexpectedEOF
2495 }
2496 b := dAtA[iNdEx]
2497 iNdEx++
2498 m.File |= uint64(b&0x7F) << shift
2499 if b < 0x80 {
2500 break
2501 }
2502 }
2503 case 3:
2504 if wireType != 0 {
2505 return fmt.Errorf("proto: wrong wireType = %d for field KernelStack", wireType)
2506 }
2507 m.KernelStack = 0
2508 for shift := uint(0); ; shift += 7 {
2509 if shift >= 64 {
2510 return ErrIntOverflowMetrics
2511 }
2512 if iNdEx >= l {
2513 return io.ErrUnexpectedEOF
2514 }
2515 b := dAtA[iNdEx]
2516 iNdEx++
2517 m.KernelStack |= uint64(b&0x7F) << shift
2518 if b < 0x80 {
2519 break
2520 }
2521 }
2522 case 4:
2523 if wireType != 0 {
2524 return fmt.Errorf("proto: wrong wireType = %d for field Slab", wireType)
2525 }
2526 m.Slab = 0
2527 for shift := uint(0); ; shift += 7 {
2528 if shift >= 64 {
2529 return ErrIntOverflowMetrics
2530 }
2531 if iNdEx >= l {
2532 return io.ErrUnexpectedEOF
2533 }
2534 b := dAtA[iNdEx]
2535 iNdEx++
2536 m.Slab |= uint64(b&0x7F) << shift
2537 if b < 0x80 {
2538 break
2539 }
2540 }
2541 case 5:
2542 if wireType != 0 {
2543 return fmt.Errorf("proto: wrong wireType = %d for field Sock", wireType)
2544 }
2545 m.Sock = 0
2546 for shift := uint(0); ; shift += 7 {
2547 if shift >= 64 {
2548 return ErrIntOverflowMetrics
2549 }
2550 if iNdEx >= l {
2551 return io.ErrUnexpectedEOF
2552 }
2553 b := dAtA[iNdEx]
2554 iNdEx++
2555 m.Sock |= uint64(b&0x7F) << shift
2556 if b < 0x80 {
2557 break
2558 }
2559 }
2560 case 6:
2561 if wireType != 0 {
2562 return fmt.Errorf("proto: wrong wireType = %d for field Shmem", wireType)
2563 }
2564 m.Shmem = 0
2565 for shift := uint(0); ; shift += 7 {
2566 if shift >= 64 {
2567 return ErrIntOverflowMetrics
2568 }
2569 if iNdEx >= l {
2570 return io.ErrUnexpectedEOF
2571 }
2572 b := dAtA[iNdEx]
2573 iNdEx++
2574 m.Shmem |= uint64(b&0x7F) << shift
2575 if b < 0x80 {
2576 break
2577 }
2578 }
2579 case 7:
2580 if wireType != 0 {
2581 return fmt.Errorf("proto: wrong wireType = %d for field FileMapped", wireType)
2582 }
2583 m.FileMapped = 0
2584 for shift := uint(0); ; shift += 7 {
2585 if shift >= 64 {
2586 return ErrIntOverflowMetrics
2587 }
2588 if iNdEx >= l {
2589 return io.ErrUnexpectedEOF
2590 }
2591 b := dAtA[iNdEx]
2592 iNdEx++
2593 m.FileMapped |= uint64(b&0x7F) << shift
2594 if b < 0x80 {
2595 break
2596 }
2597 }
2598 case 8:
2599 if wireType != 0 {
2600 return fmt.Errorf("proto: wrong wireType = %d for field FileDirty", wireType)
2601 }
2602 m.FileDirty = 0
2603 for shift := uint(0); ; shift += 7 {
2604 if shift >= 64 {
2605 return ErrIntOverflowMetrics
2606 }
2607 if iNdEx >= l {
2608 return io.ErrUnexpectedEOF
2609 }
2610 b := dAtA[iNdEx]
2611 iNdEx++
2612 m.FileDirty |= uint64(b&0x7F) << shift
2613 if b < 0x80 {
2614 break
2615 }
2616 }
2617 case 9:
2618 if wireType != 0 {
2619 return fmt.Errorf("proto: wrong wireType = %d for field FileWriteback", wireType)
2620 }
2621 m.FileWriteback = 0
2622 for shift := uint(0); ; shift += 7 {
2623 if shift >= 64 {
2624 return ErrIntOverflowMetrics
2625 }
2626 if iNdEx >= l {
2627 return io.ErrUnexpectedEOF
2628 }
2629 b := dAtA[iNdEx]
2630 iNdEx++
2631 m.FileWriteback |= uint64(b&0x7F) << shift
2632 if b < 0x80 {
2633 break
2634 }
2635 }
2636 case 10:
2637 if wireType != 0 {
2638 return fmt.Errorf("proto: wrong wireType = %d for field AnonThp", wireType)
2639 }
2640 m.AnonThp = 0
2641 for shift := uint(0); ; shift += 7 {
2642 if shift >= 64 {
2643 return ErrIntOverflowMetrics
2644 }
2645 if iNdEx >= l {
2646 return io.ErrUnexpectedEOF
2647 }
2648 b := dAtA[iNdEx]
2649 iNdEx++
2650 m.AnonThp |= uint64(b&0x7F) << shift
2651 if b < 0x80 {
2652 break
2653 }
2654 }
2655 case 11:
2656 if wireType != 0 {
2657 return fmt.Errorf("proto: wrong wireType = %d for field InactiveAnon", wireType)
2658 }
2659 m.InactiveAnon = 0
2660 for shift := uint(0); ; shift += 7 {
2661 if shift >= 64 {
2662 return ErrIntOverflowMetrics
2663 }
2664 if iNdEx >= l {
2665 return io.ErrUnexpectedEOF
2666 }
2667 b := dAtA[iNdEx]
2668 iNdEx++
2669 m.InactiveAnon |= uint64(b&0x7F) << shift
2670 if b < 0x80 {
2671 break
2672 }
2673 }
2674 case 12:
2675 if wireType != 0 {
2676 return fmt.Errorf("proto: wrong wireType = %d for field ActiveAnon", wireType)
2677 }
2678 m.ActiveAnon = 0
2679 for shift := uint(0); ; shift += 7 {
2680 if shift >= 64 {
2681 return ErrIntOverflowMetrics
2682 }
2683 if iNdEx >= l {
2684 return io.ErrUnexpectedEOF
2685 }
2686 b := dAtA[iNdEx]
2687 iNdEx++
2688 m.ActiveAnon |= uint64(b&0x7F) << shift
2689 if b < 0x80 {
2690 break
2691 }
2692 }
2693 case 13:
2694 if wireType != 0 {
2695 return fmt.Errorf("proto: wrong wireType = %d for field InactiveFile", wireType)
2696 }
2697 m.InactiveFile = 0
2698 for shift := uint(0); ; shift += 7 {
2699 if shift >= 64 {
2700 return ErrIntOverflowMetrics
2701 }
2702 if iNdEx >= l {
2703 return io.ErrUnexpectedEOF
2704 }
2705 b := dAtA[iNdEx]
2706 iNdEx++
2707 m.InactiveFile |= uint64(b&0x7F) << shift
2708 if b < 0x80 {
2709 break
2710 }
2711 }
2712 case 14:
2713 if wireType != 0 {
2714 return fmt.Errorf("proto: wrong wireType = %d for field ActiveFile", wireType)
2715 }
2716 m.ActiveFile = 0
2717 for shift := uint(0); ; shift += 7 {
2718 if shift >= 64 {
2719 return ErrIntOverflowMetrics
2720 }
2721 if iNdEx >= l {
2722 return io.ErrUnexpectedEOF
2723 }
2724 b := dAtA[iNdEx]
2725 iNdEx++
2726 m.ActiveFile |= uint64(b&0x7F) << shift
2727 if b < 0x80 {
2728 break
2729 }
2730 }
2731 case 15:
2732 if wireType != 0 {
2733 return fmt.Errorf("proto: wrong wireType = %d for field Unevictable", wireType)
2734 }
2735 m.Unevictable = 0
2736 for shift := uint(0); ; shift += 7 {
2737 if shift >= 64 {
2738 return ErrIntOverflowMetrics
2739 }
2740 if iNdEx >= l {
2741 return io.ErrUnexpectedEOF
2742 }
2743 b := dAtA[iNdEx]
2744 iNdEx++
2745 m.Unevictable |= uint64(b&0x7F) << shift
2746 if b < 0x80 {
2747 break
2748 }
2749 }
2750 case 16:
2751 if wireType != 0 {
2752 return fmt.Errorf("proto: wrong wireType = %d for field SlabReclaimable", wireType)
2753 }
2754 m.SlabReclaimable = 0
2755 for shift := uint(0); ; shift += 7 {
2756 if shift >= 64 {
2757 return ErrIntOverflowMetrics
2758 }
2759 if iNdEx >= l {
2760 return io.ErrUnexpectedEOF
2761 }
2762 b := dAtA[iNdEx]
2763 iNdEx++
2764 m.SlabReclaimable |= uint64(b&0x7F) << shift
2765 if b < 0x80 {
2766 break
2767 }
2768 }
2769 case 17:
2770 if wireType != 0 {
2771 return fmt.Errorf("proto: wrong wireType = %d for field SlabUnreclaimable", wireType)
2772 }
2773 m.SlabUnreclaimable = 0
2774 for shift := uint(0); ; shift += 7 {
2775 if shift >= 64 {
2776 return ErrIntOverflowMetrics
2777 }
2778 if iNdEx >= l {
2779 return io.ErrUnexpectedEOF
2780 }
2781 b := dAtA[iNdEx]
2782 iNdEx++
2783 m.SlabUnreclaimable |= uint64(b&0x7F) << shift
2784 if b < 0x80 {
2785 break
2786 }
2787 }
2788 case 18:
2789 if wireType != 0 {
2790 return fmt.Errorf("proto: wrong wireType = %d for field Pgfault", wireType)
2791 }
2792 m.Pgfault = 0
2793 for shift := uint(0); ; shift += 7 {
2794 if shift >= 64 {
2795 return ErrIntOverflowMetrics
2796 }
2797 if iNdEx >= l {
2798 return io.ErrUnexpectedEOF
2799 }
2800 b := dAtA[iNdEx]
2801 iNdEx++
2802 m.Pgfault |= uint64(b&0x7F) << shift
2803 if b < 0x80 {
2804 break
2805 }
2806 }
2807 case 19:
2808 if wireType != 0 {
2809 return fmt.Errorf("proto: wrong wireType = %d for field Pgmajfault", wireType)
2810 }
2811 m.Pgmajfault = 0
2812 for shift := uint(0); ; shift += 7 {
2813 if shift >= 64 {
2814 return ErrIntOverflowMetrics
2815 }
2816 if iNdEx >= l {
2817 return io.ErrUnexpectedEOF
2818 }
2819 b := dAtA[iNdEx]
2820 iNdEx++
2821 m.Pgmajfault |= uint64(b&0x7F) << shift
2822 if b < 0x80 {
2823 break
2824 }
2825 }
2826 case 20:
2827 if wireType != 0 {
2828 return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetRefault", wireType)
2829 }
2830 m.WorkingsetRefault = 0
2831 for shift := uint(0); ; shift += 7 {
2832 if shift >= 64 {
2833 return ErrIntOverflowMetrics
2834 }
2835 if iNdEx >= l {
2836 return io.ErrUnexpectedEOF
2837 }
2838 b := dAtA[iNdEx]
2839 iNdEx++
2840 m.WorkingsetRefault |= uint64(b&0x7F) << shift
2841 if b < 0x80 {
2842 break
2843 }
2844 }
2845 case 21:
2846 if wireType != 0 {
2847 return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetActivate", wireType)
2848 }
2849 m.WorkingsetActivate = 0
2850 for shift := uint(0); ; shift += 7 {
2851 if shift >= 64 {
2852 return ErrIntOverflowMetrics
2853 }
2854 if iNdEx >= l {
2855 return io.ErrUnexpectedEOF
2856 }
2857 b := dAtA[iNdEx]
2858 iNdEx++
2859 m.WorkingsetActivate |= uint64(b&0x7F) << shift
2860 if b < 0x80 {
2861 break
2862 }
2863 }
2864 case 22:
2865 if wireType != 0 {
2866 return fmt.Errorf("proto: wrong wireType = %d for field WorkingsetNodereclaim", wireType)
2867 }
2868 m.WorkingsetNodereclaim = 0
2869 for shift := uint(0); ; shift += 7 {
2870 if shift >= 64 {
2871 return ErrIntOverflowMetrics
2872 }
2873 if iNdEx >= l {
2874 return io.ErrUnexpectedEOF
2875 }
2876 b := dAtA[iNdEx]
2877 iNdEx++
2878 m.WorkingsetNodereclaim |= uint64(b&0x7F) << shift
2879 if b < 0x80 {
2880 break
2881 }
2882 }
2883 case 23:
2884 if wireType != 0 {
2885 return fmt.Errorf("proto: wrong wireType = %d for field Pgrefill", wireType)
2886 }
2887 m.Pgrefill = 0
2888 for shift := uint(0); ; shift += 7 {
2889 if shift >= 64 {
2890 return ErrIntOverflowMetrics
2891 }
2892 if iNdEx >= l {
2893 return io.ErrUnexpectedEOF
2894 }
2895 b := dAtA[iNdEx]
2896 iNdEx++
2897 m.Pgrefill |= uint64(b&0x7F) << shift
2898 if b < 0x80 {
2899 break
2900 }
2901 }
2902 case 24:
2903 if wireType != 0 {
2904 return fmt.Errorf("proto: wrong wireType = %d for field Pgscan", wireType)
2905 }
2906 m.Pgscan = 0
2907 for shift := uint(0); ; shift += 7 {
2908 if shift >= 64 {
2909 return ErrIntOverflowMetrics
2910 }
2911 if iNdEx >= l {
2912 return io.ErrUnexpectedEOF
2913 }
2914 b := dAtA[iNdEx]
2915 iNdEx++
2916 m.Pgscan |= uint64(b&0x7F) << shift
2917 if b < 0x80 {
2918 break
2919 }
2920 }
2921 case 25:
2922 if wireType != 0 {
2923 return fmt.Errorf("proto: wrong wireType = %d for field Pgsteal", wireType)
2924 }
2925 m.Pgsteal = 0
2926 for shift := uint(0); ; shift += 7 {
2927 if shift >= 64 {
2928 return ErrIntOverflowMetrics
2929 }
2930 if iNdEx >= l {
2931 return io.ErrUnexpectedEOF
2932 }
2933 b := dAtA[iNdEx]
2934 iNdEx++
2935 m.Pgsteal |= uint64(b&0x7F) << shift
2936 if b < 0x80 {
2937 break
2938 }
2939 }
2940 case 26:
2941 if wireType != 0 {
2942 return fmt.Errorf("proto: wrong wireType = %d for field Pgactivate", wireType)
2943 }
2944 m.Pgactivate = 0
2945 for shift := uint(0); ; shift += 7 {
2946 if shift >= 64 {
2947 return ErrIntOverflowMetrics
2948 }
2949 if iNdEx >= l {
2950 return io.ErrUnexpectedEOF
2951 }
2952 b := dAtA[iNdEx]
2953 iNdEx++
2954 m.Pgactivate |= uint64(b&0x7F) << shift
2955 if b < 0x80 {
2956 break
2957 }
2958 }
2959 case 27:
2960 if wireType != 0 {
2961 return fmt.Errorf("proto: wrong wireType = %d for field Pgdeactivate", wireType)
2962 }
2963 m.Pgdeactivate = 0
2964 for shift := uint(0); ; shift += 7 {
2965 if shift >= 64 {
2966 return ErrIntOverflowMetrics
2967 }
2968 if iNdEx >= l {
2969 return io.ErrUnexpectedEOF
2970 }
2971 b := dAtA[iNdEx]
2972 iNdEx++
2973 m.Pgdeactivate |= uint64(b&0x7F) << shift
2974 if b < 0x80 {
2975 break
2976 }
2977 }
2978 case 28:
2979 if wireType != 0 {
2980 return fmt.Errorf("proto: wrong wireType = %d for field Pglazyfree", wireType)
2981 }
2982 m.Pglazyfree = 0
2983 for shift := uint(0); ; shift += 7 {
2984 if shift >= 64 {
2985 return ErrIntOverflowMetrics
2986 }
2987 if iNdEx >= l {
2988 return io.ErrUnexpectedEOF
2989 }
2990 b := dAtA[iNdEx]
2991 iNdEx++
2992 m.Pglazyfree |= uint64(b&0x7F) << shift
2993 if b < 0x80 {
2994 break
2995 }
2996 }
2997 case 29:
2998 if wireType != 0 {
2999 return fmt.Errorf("proto: wrong wireType = %d for field Pglazyfreed", wireType)
3000 }
3001 m.Pglazyfreed = 0
3002 for shift := uint(0); ; shift += 7 {
3003 if shift >= 64 {
3004 return ErrIntOverflowMetrics
3005 }
3006 if iNdEx >= l {
3007 return io.ErrUnexpectedEOF
3008 }
3009 b := dAtA[iNdEx]
3010 iNdEx++
3011 m.Pglazyfreed |= uint64(b&0x7F) << shift
3012 if b < 0x80 {
3013 break
3014 }
3015 }
3016 case 30:
3017 if wireType != 0 {
3018 return fmt.Errorf("proto: wrong wireType = %d for field ThpFaultAlloc", wireType)
3019 }
3020 m.ThpFaultAlloc = 0
3021 for shift := uint(0); ; shift += 7 {
3022 if shift >= 64 {
3023 return ErrIntOverflowMetrics
3024 }
3025 if iNdEx >= l {
3026 return io.ErrUnexpectedEOF
3027 }
3028 b := dAtA[iNdEx]
3029 iNdEx++
3030 m.ThpFaultAlloc |= uint64(b&0x7F) << shift
3031 if b < 0x80 {
3032 break
3033 }
3034 }
3035 case 31:
3036 if wireType != 0 {
3037 return fmt.Errorf("proto: wrong wireType = %d for field ThpCollapseAlloc", wireType)
3038 }
3039 m.ThpCollapseAlloc = 0
3040 for shift := uint(0); ; shift += 7 {
3041 if shift >= 64 {
3042 return ErrIntOverflowMetrics
3043 }
3044 if iNdEx >= l {
3045 return io.ErrUnexpectedEOF
3046 }
3047 b := dAtA[iNdEx]
3048 iNdEx++
3049 m.ThpCollapseAlloc |= uint64(b&0x7F) << shift
3050 if b < 0x80 {
3051 break
3052 }
3053 }
3054 case 32:
3055 if wireType != 0 {
3056 return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
3057 }
3058 m.Usage = 0
3059 for shift := uint(0); ; shift += 7 {
3060 if shift >= 64 {
3061 return ErrIntOverflowMetrics
3062 }
3063 if iNdEx >= l {
3064 return io.ErrUnexpectedEOF
3065 }
3066 b := dAtA[iNdEx]
3067 iNdEx++
3068 m.Usage |= uint64(b&0x7F) << shift
3069 if b < 0x80 {
3070 break
3071 }
3072 }
3073 case 33:
3074 if wireType != 0 {
3075 return fmt.Errorf("proto: wrong wireType = %d for field UsageLimit", wireType)
3076 }
3077 m.UsageLimit = 0
3078 for shift := uint(0); ; shift += 7 {
3079 if shift >= 64 {
3080 return ErrIntOverflowMetrics
3081 }
3082 if iNdEx >= l {
3083 return io.ErrUnexpectedEOF
3084 }
3085 b := dAtA[iNdEx]
3086 iNdEx++
3087 m.UsageLimit |= uint64(b&0x7F) << shift
3088 if b < 0x80 {
3089 break
3090 }
3091 }
3092 case 34:
3093 if wireType != 0 {
3094 return fmt.Errorf("proto: wrong wireType = %d for field SwapUsage", wireType)
3095 }
3096 m.SwapUsage = 0
3097 for shift := uint(0); ; shift += 7 {
3098 if shift >= 64 {
3099 return ErrIntOverflowMetrics
3100 }
3101 if iNdEx >= l {
3102 return io.ErrUnexpectedEOF
3103 }
3104 b := dAtA[iNdEx]
3105 iNdEx++
3106 m.SwapUsage |= uint64(b&0x7F) << shift
3107 if b < 0x80 {
3108 break
3109 }
3110 }
3111 case 35:
3112 if wireType != 0 {
3113 return fmt.Errorf("proto: wrong wireType = %d for field SwapLimit", wireType)
3114 }
3115 m.SwapLimit = 0
3116 for shift := uint(0); ; shift += 7 {
3117 if shift >= 64 {
3118 return ErrIntOverflowMetrics
3119 }
3120 if iNdEx >= l {
3121 return io.ErrUnexpectedEOF
3122 }
3123 b := dAtA[iNdEx]
3124 iNdEx++
3125 m.SwapLimit |= uint64(b&0x7F) << shift
3126 if b < 0x80 {
3127 break
3128 }
3129 }
3130 default:
3131 iNdEx = preIndex
3132 skippy, err := skipMetrics(dAtA[iNdEx:])
3133 if err != nil {
3134 return err
3135 }
3136 if (skippy < 0) || (iNdEx+skippy) < 0 {
3137 return ErrInvalidLengthMetrics
3138 }
3139 if (iNdEx + skippy) > l {
3140 return io.ErrUnexpectedEOF
3141 }
3142 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3143 iNdEx += skippy
3144 }
3145 }
3146
3147 if iNdEx > l {
3148 return io.ErrUnexpectedEOF
3149 }
3150 return nil
3151 }
3152 func (m *MemoryEvents) Unmarshal(dAtA []byte) error {
3153 l := len(dAtA)
3154 iNdEx := 0
3155 for iNdEx < l {
3156 preIndex := iNdEx
3157 var wire uint64
3158 for shift := uint(0); ; shift += 7 {
3159 if shift >= 64 {
3160 return ErrIntOverflowMetrics
3161 }
3162 if iNdEx >= l {
3163 return io.ErrUnexpectedEOF
3164 }
3165 b := dAtA[iNdEx]
3166 iNdEx++
3167 wire |= uint64(b&0x7F) << shift
3168 if b < 0x80 {
3169 break
3170 }
3171 }
3172 fieldNum := int32(wire >> 3)
3173 wireType := int(wire & 0x7)
3174 if wireType == 4 {
3175 return fmt.Errorf("proto: MemoryEvents: wiretype end group for non-group")
3176 }
3177 if fieldNum <= 0 {
3178 return fmt.Errorf("proto: MemoryEvents: illegal tag %d (wire type %d)", fieldNum, wire)
3179 }
3180 switch fieldNum {
3181 case 1:
3182 if wireType != 0 {
3183 return fmt.Errorf("proto: wrong wireType = %d for field Low", wireType)
3184 }
3185 m.Low = 0
3186 for shift := uint(0); ; shift += 7 {
3187 if shift >= 64 {
3188 return ErrIntOverflowMetrics
3189 }
3190 if iNdEx >= l {
3191 return io.ErrUnexpectedEOF
3192 }
3193 b := dAtA[iNdEx]
3194 iNdEx++
3195 m.Low |= uint64(b&0x7F) << shift
3196 if b < 0x80 {
3197 break
3198 }
3199 }
3200 case 2:
3201 if wireType != 0 {
3202 return fmt.Errorf("proto: wrong wireType = %d for field High", wireType)
3203 }
3204 m.High = 0
3205 for shift := uint(0); ; shift += 7 {
3206 if shift >= 64 {
3207 return ErrIntOverflowMetrics
3208 }
3209 if iNdEx >= l {
3210 return io.ErrUnexpectedEOF
3211 }
3212 b := dAtA[iNdEx]
3213 iNdEx++
3214 m.High |= uint64(b&0x7F) << shift
3215 if b < 0x80 {
3216 break
3217 }
3218 }
3219 case 3:
3220 if wireType != 0 {
3221 return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
3222 }
3223 m.Max = 0
3224 for shift := uint(0); ; shift += 7 {
3225 if shift >= 64 {
3226 return ErrIntOverflowMetrics
3227 }
3228 if iNdEx >= l {
3229 return io.ErrUnexpectedEOF
3230 }
3231 b := dAtA[iNdEx]
3232 iNdEx++
3233 m.Max |= uint64(b&0x7F) << shift
3234 if b < 0x80 {
3235 break
3236 }
3237 }
3238 case 4:
3239 if wireType != 0 {
3240 return fmt.Errorf("proto: wrong wireType = %d for field Oom", wireType)
3241 }
3242 m.Oom = 0
3243 for shift := uint(0); ; shift += 7 {
3244 if shift >= 64 {
3245 return ErrIntOverflowMetrics
3246 }
3247 if iNdEx >= l {
3248 return io.ErrUnexpectedEOF
3249 }
3250 b := dAtA[iNdEx]
3251 iNdEx++
3252 m.Oom |= uint64(b&0x7F) << shift
3253 if b < 0x80 {
3254 break
3255 }
3256 }
3257 case 5:
3258 if wireType != 0 {
3259 return fmt.Errorf("proto: wrong wireType = %d for field OomKill", wireType)
3260 }
3261 m.OomKill = 0
3262 for shift := uint(0); ; shift += 7 {
3263 if shift >= 64 {
3264 return ErrIntOverflowMetrics
3265 }
3266 if iNdEx >= l {
3267 return io.ErrUnexpectedEOF
3268 }
3269 b := dAtA[iNdEx]
3270 iNdEx++
3271 m.OomKill |= uint64(b&0x7F) << shift
3272 if b < 0x80 {
3273 break
3274 }
3275 }
3276 default:
3277 iNdEx = preIndex
3278 skippy, err := skipMetrics(dAtA[iNdEx:])
3279 if err != nil {
3280 return err
3281 }
3282 if (skippy < 0) || (iNdEx+skippy) < 0 {
3283 return ErrInvalidLengthMetrics
3284 }
3285 if (iNdEx + skippy) > l {
3286 return io.ErrUnexpectedEOF
3287 }
3288 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3289 iNdEx += skippy
3290 }
3291 }
3292
3293 if iNdEx > l {
3294 return io.ErrUnexpectedEOF
3295 }
3296 return nil
3297 }
3298 func (m *RdmaStat) Unmarshal(dAtA []byte) error {
3299 l := len(dAtA)
3300 iNdEx := 0
3301 for iNdEx < l {
3302 preIndex := iNdEx
3303 var wire uint64
3304 for shift := uint(0); ; shift += 7 {
3305 if shift >= 64 {
3306 return ErrIntOverflowMetrics
3307 }
3308 if iNdEx >= l {
3309 return io.ErrUnexpectedEOF
3310 }
3311 b := dAtA[iNdEx]
3312 iNdEx++
3313 wire |= uint64(b&0x7F) << shift
3314 if b < 0x80 {
3315 break
3316 }
3317 }
3318 fieldNum := int32(wire >> 3)
3319 wireType := int(wire & 0x7)
3320 if wireType == 4 {
3321 return fmt.Errorf("proto: RdmaStat: wiretype end group for non-group")
3322 }
3323 if fieldNum <= 0 {
3324 return fmt.Errorf("proto: RdmaStat: illegal tag %d (wire type %d)", fieldNum, wire)
3325 }
3326 switch fieldNum {
3327 case 1:
3328 if wireType != 2 {
3329 return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
3330 }
3331 var msglen int
3332 for shift := uint(0); ; shift += 7 {
3333 if shift >= 64 {
3334 return ErrIntOverflowMetrics
3335 }
3336 if iNdEx >= l {
3337 return io.ErrUnexpectedEOF
3338 }
3339 b := dAtA[iNdEx]
3340 iNdEx++
3341 msglen |= int(b&0x7F) << shift
3342 if b < 0x80 {
3343 break
3344 }
3345 }
3346 if msglen < 0 {
3347 return ErrInvalidLengthMetrics
3348 }
3349 postIndex := iNdEx + msglen
3350 if postIndex < 0 {
3351 return ErrInvalidLengthMetrics
3352 }
3353 if postIndex > l {
3354 return io.ErrUnexpectedEOF
3355 }
3356 m.Current = append(m.Current, &RdmaEntry{})
3357 if err := m.Current[len(m.Current)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
3358 return err
3359 }
3360 iNdEx = postIndex
3361 case 2:
3362 if wireType != 2 {
3363 return fmt.Errorf("proto: wrong wireType = %d for field Limit", wireType)
3364 }
3365 var msglen int
3366 for shift := uint(0); ; shift += 7 {
3367 if shift >= 64 {
3368 return ErrIntOverflowMetrics
3369 }
3370 if iNdEx >= l {
3371 return io.ErrUnexpectedEOF
3372 }
3373 b := dAtA[iNdEx]
3374 iNdEx++
3375 msglen |= int(b&0x7F) << shift
3376 if b < 0x80 {
3377 break
3378 }
3379 }
3380 if msglen < 0 {
3381 return ErrInvalidLengthMetrics
3382 }
3383 postIndex := iNdEx + msglen
3384 if postIndex < 0 {
3385 return ErrInvalidLengthMetrics
3386 }
3387 if postIndex > l {
3388 return io.ErrUnexpectedEOF
3389 }
3390 m.Limit = append(m.Limit, &RdmaEntry{})
3391 if err := m.Limit[len(m.Limit)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
3392 return err
3393 }
3394 iNdEx = postIndex
3395 default:
3396 iNdEx = preIndex
3397 skippy, err := skipMetrics(dAtA[iNdEx:])
3398 if err != nil {
3399 return err
3400 }
3401 if (skippy < 0) || (iNdEx+skippy) < 0 {
3402 return ErrInvalidLengthMetrics
3403 }
3404 if (iNdEx + skippy) > l {
3405 return io.ErrUnexpectedEOF
3406 }
3407 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3408 iNdEx += skippy
3409 }
3410 }
3411
3412 if iNdEx > l {
3413 return io.ErrUnexpectedEOF
3414 }
3415 return nil
3416 }
3417 func (m *RdmaEntry) Unmarshal(dAtA []byte) error {
3418 l := len(dAtA)
3419 iNdEx := 0
3420 for iNdEx < l {
3421 preIndex := iNdEx
3422 var wire uint64
3423 for shift := uint(0); ; shift += 7 {
3424 if shift >= 64 {
3425 return ErrIntOverflowMetrics
3426 }
3427 if iNdEx >= l {
3428 return io.ErrUnexpectedEOF
3429 }
3430 b := dAtA[iNdEx]
3431 iNdEx++
3432 wire |= uint64(b&0x7F) << shift
3433 if b < 0x80 {
3434 break
3435 }
3436 }
3437 fieldNum := int32(wire >> 3)
3438 wireType := int(wire & 0x7)
3439 if wireType == 4 {
3440 return fmt.Errorf("proto: RdmaEntry: wiretype end group for non-group")
3441 }
3442 if fieldNum <= 0 {
3443 return fmt.Errorf("proto: RdmaEntry: illegal tag %d (wire type %d)", fieldNum, wire)
3444 }
3445 switch fieldNum {
3446 case 1:
3447 if wireType != 2 {
3448 return fmt.Errorf("proto: wrong wireType = %d for field Device", wireType)
3449 }
3450 var stringLen uint64
3451 for shift := uint(0); ; shift += 7 {
3452 if shift >= 64 {
3453 return ErrIntOverflowMetrics
3454 }
3455 if iNdEx >= l {
3456 return io.ErrUnexpectedEOF
3457 }
3458 b := dAtA[iNdEx]
3459 iNdEx++
3460 stringLen |= uint64(b&0x7F) << shift
3461 if b < 0x80 {
3462 break
3463 }
3464 }
3465 intStringLen := int(stringLen)
3466 if intStringLen < 0 {
3467 return ErrInvalidLengthMetrics
3468 }
3469 postIndex := iNdEx + intStringLen
3470 if postIndex < 0 {
3471 return ErrInvalidLengthMetrics
3472 }
3473 if postIndex > l {
3474 return io.ErrUnexpectedEOF
3475 }
3476 m.Device = string(dAtA[iNdEx:postIndex])
3477 iNdEx = postIndex
3478 case 2:
3479 if wireType != 0 {
3480 return fmt.Errorf("proto: wrong wireType = %d for field HcaHandles", wireType)
3481 }
3482 m.HcaHandles = 0
3483 for shift := uint(0); ; shift += 7 {
3484 if shift >= 64 {
3485 return ErrIntOverflowMetrics
3486 }
3487 if iNdEx >= l {
3488 return io.ErrUnexpectedEOF
3489 }
3490 b := dAtA[iNdEx]
3491 iNdEx++
3492 m.HcaHandles |= uint32(b&0x7F) << shift
3493 if b < 0x80 {
3494 break
3495 }
3496 }
3497 case 3:
3498 if wireType != 0 {
3499 return fmt.Errorf("proto: wrong wireType = %d for field HcaObjects", wireType)
3500 }
3501 m.HcaObjects = 0
3502 for shift := uint(0); ; shift += 7 {
3503 if shift >= 64 {
3504 return ErrIntOverflowMetrics
3505 }
3506 if iNdEx >= l {
3507 return io.ErrUnexpectedEOF
3508 }
3509 b := dAtA[iNdEx]
3510 iNdEx++
3511 m.HcaObjects |= uint32(b&0x7F) << shift
3512 if b < 0x80 {
3513 break
3514 }
3515 }
3516 default:
3517 iNdEx = preIndex
3518 skippy, err := skipMetrics(dAtA[iNdEx:])
3519 if err != nil {
3520 return err
3521 }
3522 if (skippy < 0) || (iNdEx+skippy) < 0 {
3523 return ErrInvalidLengthMetrics
3524 }
3525 if (iNdEx + skippy) > l {
3526 return io.ErrUnexpectedEOF
3527 }
3528 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3529 iNdEx += skippy
3530 }
3531 }
3532
3533 if iNdEx > l {
3534 return io.ErrUnexpectedEOF
3535 }
3536 return nil
3537 }
3538 func (m *IOStat) Unmarshal(dAtA []byte) error {
3539 l := len(dAtA)
3540 iNdEx := 0
3541 for iNdEx < l {
3542 preIndex := iNdEx
3543 var wire uint64
3544 for shift := uint(0); ; shift += 7 {
3545 if shift >= 64 {
3546 return ErrIntOverflowMetrics
3547 }
3548 if iNdEx >= l {
3549 return io.ErrUnexpectedEOF
3550 }
3551 b := dAtA[iNdEx]
3552 iNdEx++
3553 wire |= uint64(b&0x7F) << shift
3554 if b < 0x80 {
3555 break
3556 }
3557 }
3558 fieldNum := int32(wire >> 3)
3559 wireType := int(wire & 0x7)
3560 if wireType == 4 {
3561 return fmt.Errorf("proto: IOStat: wiretype end group for non-group")
3562 }
3563 if fieldNum <= 0 {
3564 return fmt.Errorf("proto: IOStat: illegal tag %d (wire type %d)", fieldNum, wire)
3565 }
3566 switch fieldNum {
3567 case 1:
3568 if wireType != 2 {
3569 return fmt.Errorf("proto: wrong wireType = %d for field Usage", wireType)
3570 }
3571 var msglen int
3572 for shift := uint(0); ; shift += 7 {
3573 if shift >= 64 {
3574 return ErrIntOverflowMetrics
3575 }
3576 if iNdEx >= l {
3577 return io.ErrUnexpectedEOF
3578 }
3579 b := dAtA[iNdEx]
3580 iNdEx++
3581 msglen |= int(b&0x7F) << shift
3582 if b < 0x80 {
3583 break
3584 }
3585 }
3586 if msglen < 0 {
3587 return ErrInvalidLengthMetrics
3588 }
3589 postIndex := iNdEx + msglen
3590 if postIndex < 0 {
3591 return ErrInvalidLengthMetrics
3592 }
3593 if postIndex > l {
3594 return io.ErrUnexpectedEOF
3595 }
3596 m.Usage = append(m.Usage, &IOEntry{})
3597 if err := m.Usage[len(m.Usage)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
3598 return err
3599 }
3600 iNdEx = postIndex
3601 default:
3602 iNdEx = preIndex
3603 skippy, err := skipMetrics(dAtA[iNdEx:])
3604 if err != nil {
3605 return err
3606 }
3607 if (skippy < 0) || (iNdEx+skippy) < 0 {
3608 return ErrInvalidLengthMetrics
3609 }
3610 if (iNdEx + skippy) > l {
3611 return io.ErrUnexpectedEOF
3612 }
3613 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3614 iNdEx += skippy
3615 }
3616 }
3617
3618 if iNdEx > l {
3619 return io.ErrUnexpectedEOF
3620 }
3621 return nil
3622 }
3623 func (m *IOEntry) Unmarshal(dAtA []byte) error {
3624 l := len(dAtA)
3625 iNdEx := 0
3626 for iNdEx < l {
3627 preIndex := iNdEx
3628 var wire uint64
3629 for shift := uint(0); ; shift += 7 {
3630 if shift >= 64 {
3631 return ErrIntOverflowMetrics
3632 }
3633 if iNdEx >= l {
3634 return io.ErrUnexpectedEOF
3635 }
3636 b := dAtA[iNdEx]
3637 iNdEx++
3638 wire |= uint64(b&0x7F) << shift
3639 if b < 0x80 {
3640 break
3641 }
3642 }
3643 fieldNum := int32(wire >> 3)
3644 wireType := int(wire & 0x7)
3645 if wireType == 4 {
3646 return fmt.Errorf("proto: IOEntry: wiretype end group for non-group")
3647 }
3648 if fieldNum <= 0 {
3649 return fmt.Errorf("proto: IOEntry: illegal tag %d (wire type %d)", fieldNum, wire)
3650 }
3651 switch fieldNum {
3652 case 1:
3653 if wireType != 0 {
3654 return fmt.Errorf("proto: wrong wireType = %d for field Major", wireType)
3655 }
3656 m.Major = 0
3657 for shift := uint(0); ; shift += 7 {
3658 if shift >= 64 {
3659 return ErrIntOverflowMetrics
3660 }
3661 if iNdEx >= l {
3662 return io.ErrUnexpectedEOF
3663 }
3664 b := dAtA[iNdEx]
3665 iNdEx++
3666 m.Major |= uint64(b&0x7F) << shift
3667 if b < 0x80 {
3668 break
3669 }
3670 }
3671 case 2:
3672 if wireType != 0 {
3673 return fmt.Errorf("proto: wrong wireType = %d for field Minor", wireType)
3674 }
3675 m.Minor = 0
3676 for shift := uint(0); ; shift += 7 {
3677 if shift >= 64 {
3678 return ErrIntOverflowMetrics
3679 }
3680 if iNdEx >= l {
3681 return io.ErrUnexpectedEOF
3682 }
3683 b := dAtA[iNdEx]
3684 iNdEx++
3685 m.Minor |= uint64(b&0x7F) << shift
3686 if b < 0x80 {
3687 break
3688 }
3689 }
3690 case 3:
3691 if wireType != 0 {
3692 return fmt.Errorf("proto: wrong wireType = %d for field Rbytes", wireType)
3693 }
3694 m.Rbytes = 0
3695 for shift := uint(0); ; shift += 7 {
3696 if shift >= 64 {
3697 return ErrIntOverflowMetrics
3698 }
3699 if iNdEx >= l {
3700 return io.ErrUnexpectedEOF
3701 }
3702 b := dAtA[iNdEx]
3703 iNdEx++
3704 m.Rbytes |= uint64(b&0x7F) << shift
3705 if b < 0x80 {
3706 break
3707 }
3708 }
3709 case 4:
3710 if wireType != 0 {
3711 return fmt.Errorf("proto: wrong wireType = %d for field Wbytes", wireType)
3712 }
3713 m.Wbytes = 0
3714 for shift := uint(0); ; shift += 7 {
3715 if shift >= 64 {
3716 return ErrIntOverflowMetrics
3717 }
3718 if iNdEx >= l {
3719 return io.ErrUnexpectedEOF
3720 }
3721 b := dAtA[iNdEx]
3722 iNdEx++
3723 m.Wbytes |= uint64(b&0x7F) << shift
3724 if b < 0x80 {
3725 break
3726 }
3727 }
3728 case 5:
3729 if wireType != 0 {
3730 return fmt.Errorf("proto: wrong wireType = %d for field Rios", wireType)
3731 }
3732 m.Rios = 0
3733 for shift := uint(0); ; shift += 7 {
3734 if shift >= 64 {
3735 return ErrIntOverflowMetrics
3736 }
3737 if iNdEx >= l {
3738 return io.ErrUnexpectedEOF
3739 }
3740 b := dAtA[iNdEx]
3741 iNdEx++
3742 m.Rios |= uint64(b&0x7F) << shift
3743 if b < 0x80 {
3744 break
3745 }
3746 }
3747 case 6:
3748 if wireType != 0 {
3749 return fmt.Errorf("proto: wrong wireType = %d for field Wios", wireType)
3750 }
3751 m.Wios = 0
3752 for shift := uint(0); ; shift += 7 {
3753 if shift >= 64 {
3754 return ErrIntOverflowMetrics
3755 }
3756 if iNdEx >= l {
3757 return io.ErrUnexpectedEOF
3758 }
3759 b := dAtA[iNdEx]
3760 iNdEx++
3761 m.Wios |= uint64(b&0x7F) << shift
3762 if b < 0x80 {
3763 break
3764 }
3765 }
3766 default:
3767 iNdEx = preIndex
3768 skippy, err := skipMetrics(dAtA[iNdEx:])
3769 if err != nil {
3770 return err
3771 }
3772 if (skippy < 0) || (iNdEx+skippy) < 0 {
3773 return ErrInvalidLengthMetrics
3774 }
3775 if (iNdEx + skippy) > l {
3776 return io.ErrUnexpectedEOF
3777 }
3778 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3779 iNdEx += skippy
3780 }
3781 }
3782
3783 if iNdEx > l {
3784 return io.ErrUnexpectedEOF
3785 }
3786 return nil
3787 }
3788 func (m *HugeTlbStat) Unmarshal(dAtA []byte) error {
3789 l := len(dAtA)
3790 iNdEx := 0
3791 for iNdEx < l {
3792 preIndex := iNdEx
3793 var wire uint64
3794 for shift := uint(0); ; shift += 7 {
3795 if shift >= 64 {
3796 return ErrIntOverflowMetrics
3797 }
3798 if iNdEx >= l {
3799 return io.ErrUnexpectedEOF
3800 }
3801 b := dAtA[iNdEx]
3802 iNdEx++
3803 wire |= uint64(b&0x7F) << shift
3804 if b < 0x80 {
3805 break
3806 }
3807 }
3808 fieldNum := int32(wire >> 3)
3809 wireType := int(wire & 0x7)
3810 if wireType == 4 {
3811 return fmt.Errorf("proto: HugeTlbStat: wiretype end group for non-group")
3812 }
3813 if fieldNum <= 0 {
3814 return fmt.Errorf("proto: HugeTlbStat: illegal tag %d (wire type %d)", fieldNum, wire)
3815 }
3816 switch fieldNum {
3817 case 1:
3818 if wireType != 0 {
3819 return fmt.Errorf("proto: wrong wireType = %d for field Current", wireType)
3820 }
3821 m.Current = 0
3822 for shift := uint(0); ; shift += 7 {
3823 if shift >= 64 {
3824 return ErrIntOverflowMetrics
3825 }
3826 if iNdEx >= l {
3827 return io.ErrUnexpectedEOF
3828 }
3829 b := dAtA[iNdEx]
3830 iNdEx++
3831 m.Current |= uint64(b&0x7F) << shift
3832 if b < 0x80 {
3833 break
3834 }
3835 }
3836 case 2:
3837 if wireType != 0 {
3838 return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType)
3839 }
3840 m.Max = 0
3841 for shift := uint(0); ; shift += 7 {
3842 if shift >= 64 {
3843 return ErrIntOverflowMetrics
3844 }
3845 if iNdEx >= l {
3846 return io.ErrUnexpectedEOF
3847 }
3848 b := dAtA[iNdEx]
3849 iNdEx++
3850 m.Max |= uint64(b&0x7F) << shift
3851 if b < 0x80 {
3852 break
3853 }
3854 }
3855 case 3:
3856 if wireType != 2 {
3857 return fmt.Errorf("proto: wrong wireType = %d for field Pagesize", wireType)
3858 }
3859 var stringLen uint64
3860 for shift := uint(0); ; shift += 7 {
3861 if shift >= 64 {
3862 return ErrIntOverflowMetrics
3863 }
3864 if iNdEx >= l {
3865 return io.ErrUnexpectedEOF
3866 }
3867 b := dAtA[iNdEx]
3868 iNdEx++
3869 stringLen |= uint64(b&0x7F) << shift
3870 if b < 0x80 {
3871 break
3872 }
3873 }
3874 intStringLen := int(stringLen)
3875 if intStringLen < 0 {
3876 return ErrInvalidLengthMetrics
3877 }
3878 postIndex := iNdEx + intStringLen
3879 if postIndex < 0 {
3880 return ErrInvalidLengthMetrics
3881 }
3882 if postIndex > l {
3883 return io.ErrUnexpectedEOF
3884 }
3885 m.Pagesize = string(dAtA[iNdEx:postIndex])
3886 iNdEx = postIndex
3887 default:
3888 iNdEx = preIndex
3889 skippy, err := skipMetrics(dAtA[iNdEx:])
3890 if err != nil {
3891 return err
3892 }
3893 if (skippy < 0) || (iNdEx+skippy) < 0 {
3894 return ErrInvalidLengthMetrics
3895 }
3896 if (iNdEx + skippy) > l {
3897 return io.ErrUnexpectedEOF
3898 }
3899 m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
3900 iNdEx += skippy
3901 }
3902 }
3903
3904 if iNdEx > l {
3905 return io.ErrUnexpectedEOF
3906 }
3907 return nil
3908 }
3909 func skipMetrics(dAtA []byte) (n int, err error) {
3910 l := len(dAtA)
3911 iNdEx := 0
3912 depth := 0
3913 for iNdEx < l {
3914 var wire uint64
3915 for shift := uint(0); ; shift += 7 {
3916 if shift >= 64 {
3917 return 0, ErrIntOverflowMetrics
3918 }
3919 if iNdEx >= l {
3920 return 0, io.ErrUnexpectedEOF
3921 }
3922 b := dAtA[iNdEx]
3923 iNdEx++
3924 wire |= (uint64(b) & 0x7F) << shift
3925 if b < 0x80 {
3926 break
3927 }
3928 }
3929 wireType := int(wire & 0x7)
3930 switch wireType {
3931 case 0:
3932 for shift := uint(0); ; shift += 7 {
3933 if shift >= 64 {
3934 return 0, ErrIntOverflowMetrics
3935 }
3936 if iNdEx >= l {
3937 return 0, io.ErrUnexpectedEOF
3938 }
3939 iNdEx++
3940 if dAtA[iNdEx-1] < 0x80 {
3941 break
3942 }
3943 }
3944 case 1:
3945 iNdEx += 8
3946 case 2:
3947 var length int
3948 for shift := uint(0); ; shift += 7 {
3949 if shift >= 64 {
3950 return 0, ErrIntOverflowMetrics
3951 }
3952 if iNdEx >= l {
3953 return 0, io.ErrUnexpectedEOF
3954 }
3955 b := dAtA[iNdEx]
3956 iNdEx++
3957 length |= (int(b) & 0x7F) << shift
3958 if b < 0x80 {
3959 break
3960 }
3961 }
3962 if length < 0 {
3963 return 0, ErrInvalidLengthMetrics
3964 }
3965 iNdEx += length
3966 case 3:
3967 depth++
3968 case 4:
3969 if depth == 0 {
3970 return 0, ErrUnexpectedEndOfGroupMetrics
3971 }
3972 depth--
3973 case 5:
3974 iNdEx += 4
3975 default:
3976 return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
3977 }
3978 if iNdEx < 0 {
3979 return 0, ErrInvalidLengthMetrics
3980 }
3981 if depth == 0 {
3982 return iNdEx, nil
3983 }
3984 }
3985 return 0, io.ErrUnexpectedEOF
3986 }
3987
3988 var (
3989 ErrInvalidLengthMetrics = fmt.Errorf("proto: negative length found during unmarshaling")
3990 ErrIntOverflowMetrics = fmt.Errorf("proto: integer overflow")
3991 ErrUnexpectedEndOfGroupMetrics = fmt.Errorf("proto: unexpected end of group")
3992 )
3993
View as plain text