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

Method CreateExecutable

tensorflow/compiler/xla/service/hlo_runner.cc:430–444  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

428}
429
430StatusOr<std::unique_ptr<Executable>> HloRunner::CreateExecutable(
431 std::unique_ptr<HloModule> module, bool run_hlo_passes) {
432 if (run_hlo_passes) {
433 auto module_group = absl::make_unique<HloModuleGroup>(std::move(module));
434 TF_ASSIGN_OR_RETURN(
435 auto executables,
436 backend().compiler()->Compile(std::move(module_group),
437 {{backend().default_stream_executor()}},
438 backend().memory_allocator()));
439 return std::move(executables[0]);
440 }
441 return backend().compiler()->RunBackend(std::move(module),
442 backend().default_stream_executor(),
443 backend().memory_allocator());
444}
445
446ServiceExecutableRunOptions HloRunner::GetServiceRunOptionsForDevice(
447 int64 device, se::Stream* stream, DeviceAssignment* device_assignment,

Callers 2

RunMultipleTimesMethod · 0.80
XLA_TEST_FFunction · 0.80

Calls 5

backendFunction · 0.85
RunBackendMethod · 0.45
compilerMethod · 0.45
memory_allocatorMethod · 0.45

Tested by 2

RunMultipleTimesMethod · 0.64
XLA_TEST_FFunction · 0.64