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

Method StoreToLiteral

tensorflow/compiler/xrt/xrt_state.cc:241–248  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

239}
240
241Status XRTTupleAllocation::StoreToLiteral(xla::Backend* backend,
242 xla::MutableLiteralBase* literal) {
243 auto transfer_manager = backend->transfer_manager();
244 TF_ASSIGN_OR_RETURN(auto stream, backend->BorrowStream(device_ordinal()));
245 TF_ASSIGN_OR_RETURN(xla::ShapedBuffer shaped_buffer, ToShapedBuffer());
246 return transfer_manager->TransferLiteralFromDevice(stream.get(),
247 shaped_buffer, literal);
248}
249
250Status XRTTupleAllocation::WriteLiteral(xla::Backend* backend,
251 const xla::Literal& literal) {

Callers

nothing calls this directly

Calls 3

transfer_managerMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected