MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / AddRange

Function AddRange

tensorflow/core/platform/default/test_benchmark.cc:69–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67namespace {
68
69void AddRange(std::vector<int>* dst, int lo, int hi, int mult) {
70 CHECK_GE(lo, 0);
71 CHECK_GE(hi, lo);
72
73 // Add "lo"
74 dst->push_back(lo);
75
76 // Now space out the benchmarks in multiples of "mult"
77 for (int32 i = 1; i < kint32max / mult; i *= mult) {
78 if (i >= hi) break;
79 if (i > lo) {
80 dst->push_back(i);
81 }
82 }
83 // Add "hi" (if different from "lo")
84 if (hi != lo) {
85 dst->push_back(hi);
86 }
87}
88
89} // namespace
90

Callers 2

RangeMethod · 0.85
RangePairMethod · 0.85

Calls 1

push_backMethod · 0.45

Tested by

no test coverage detected