MCPcopy Create free account
hub / github.com/apache/arrow / RoundUp

Function RoundUp

cpp/src/arrow/util/bit_util.h:88–90  ·  view source on GitHub ↗

Returns 'value' rounded up to the nearest multiple of 'factor'

Source from the content-addressed store, hash-verified

86
87// Returns 'value' rounded up to the nearest multiple of 'factor'
88constexpr int64_t RoundUp(int64_t value, int64_t factor) {
89 return CeilDiv(value, factor) * factor;
90}
91
92// Returns 'value' rounded down to the nearest multiple of 'factor'
93constexpr int64_t RoundDown(int64_t value, int64_t factor) {

Callers 6

TEST_PFunction · 0.85
SetBitmapImplFunction · 0.85
CoveringBytesFunction · 0.85
VisitFixedWidthArrayMethod · 0.85
TESTFunction · 0.85
PaddedAllocationSizeMethod · 0.85

Calls 1

CeilDivFunction · 0.85

Tested by 2

TEST_PFunction · 0.68
TESTFunction · 0.68