| 380 | } |
| 381 | |
| 382 | std::unique_ptr<fft::Plan> ROCMFft::Create1dPlan(Stream *stream, uint64 num_x, |
| 383 | fft::Type type, |
| 384 | bool in_place_fft) { |
| 385 | std::unique_ptr<ROCMFftPlan> fft_plan_ptr{new ROCMFftPlan()}; |
| 386 | uint64 elem_count[1] = {num_x}; |
| 387 | port::Status status = fft_plan_ptr->Initialize( |
| 388 | parent_, stream, 1, elem_count, type, /*scratch_allocator=*/nullptr); |
| 389 | // TODO(yangzihao): In the future, send error msg back to TensorFlow |
| 390 | // so it can fail gracefully, |
| 391 | if (!status.ok()) { |
| 392 | LOG(FATAL) << "failed to initialize hipfft 1d plan: " |
| 393 | << status.error_message(); |
| 394 | } |
| 395 | return std::move(fft_plan_ptr); |
| 396 | } |
| 397 | |
| 398 | std::unique_ptr<fft::Plan> ROCMFft::Create1dPlanWithScratchAllocator( |
| 399 | Stream *stream, uint64 num_x, fft::Type type, bool in_place_fft, |
nothing calls this directly
no test coverage detected