MCPcopy Create free account
hub / github.com/Tencent/phxqueue / LoadInfo2Load

Function LoadInfo2Load

phxqueue/scheduler/schedulermgr.cpp:22–26  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20
21
22inline int LoadInfo2Load(const phxqueue::comm::proto::LoadInfo &loadinfo, const int load_use_proc_used_ratio) {
23 double x = loadinfo.proc_used_ratio() / 100.0;
24 //x = x * x * x;
25 return (int)(loadinfo.cpu() * (1 + x * load_use_proc_used_ratio));
26}
27
28
29}

Callers 1

GetAddrScaleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected