MCPcopy Create free account
hub / github.com/bytedance/bolt / write

Method write

bolt/exec/SpillFile.cpp:171–185  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

169}
170
171uint64_t SpillWriteFile::write(std::unique_ptr<folly::IOBuf> iobuf) {
172 auto writtenBytes = iobuf->computeChainDataLength();
173 if (spillUringEnabled_ && file_->uringEnabled()) {
174 while (iobuf) {
175 auto current = std::move(iobuf);
176 iobuf = current->pop();
177 auto taskId = taskId_++;
178 auto writeBuff = writeBuffers_->add(current, taskId, file_);
179 file_->submitWrite(writeBuff, taskId);
180 }
181 } else {
182 file_->append(std::move(iobuf));
183 }
184 return writtenBytes;
185}
186
187uint64_t SpillWriteFile::write(std::string_view buf) {
188 auto writtenBytes = buf.size();

Callers 15

_pollFunction · 0.45
writeFunction · 0.45
string>Method · 0.45
writeBufferFunction · 0.45
writeStringViewsFunction · 0.45
writeScalarConstantFunction · 0.45
saveStringToFileFunction · 0.45
saveStdVectorToFileFunction · 0.45
saveSelectivityVectorFunction · 0.45
maybeInitTraceMethod · 0.45
flushMethod · 0.45
appendToPartitionMethod · 0.45

Calls 15

writeBufferFunction · 0.85
memcpyFunction · 0.85
createStreamTreeMethod · 0.80
getRowSizeMethod · 0.80
serializeFunction · 0.50
uringEnabledMethod · 0.45
popMethod · 0.45
addMethod · 0.45
submitWriteMethod · 0.45
appendMethod · 0.45
sizeMethod · 0.45
typeMethod · 0.45

Tested by 3

TEST_FFunction · 0.36
writeToFileFunction · 0.36
writeToFileMethod · 0.36