Skip to content

Commit

Permalink
fix: HIP plans
Browse files Browse the repository at this point in the history
  • Loading branch information
Yuuichi Asahi committed Dec 3, 2024
1 parent b89170a commit 9e2cf2f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions fft/src/KokkosFFT_HIP_plans.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ auto create_plan(const ExecutionSpace& exec_space,
plan = std::make_unique<PlanType>();
// hipfftResult hipfft_rt = hipfftCreate(&(*plan));
// KOKKOSFFT_THROW_IF(hipfft_rt != HIPFFT_SUCCESS, "hipfftCreate failed");

hipStream_t stream = exec_space.hip_stream();
hipfftResult hipfft_rt = hipfftSetStream((*plan).plan(), stream);
KOKKOSFFT_THROW_IF(hipfft_rt != HIPFFT_SUCCESS, "hipfftSetStream failed");

Expand Down
2 changes: 1 addition & 1 deletion fft/src/KokkosFFT_HIP_types.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ struct ScopedHIPfftPlanType {
ScopedHIPfftPlanType() { hipfftCreate(&m_plan); }
~ScopedHIPfftPlanType() { hipfftDestroy(m_plan); }

ScopedHIPfftPlanType &plan() { return m_plan; }
hipfftHandle &plan() { return m_plan; }
};

#if defined(ENABLE_HOST_AND_DEVICE)
Expand Down

0 comments on commit 9e2cf2f

Please sign in to comment.