Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing inline keywords to cudautils::launch #430

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions HeterogeneousCore/CUDAUtilities/interface/launch.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,19 +88,16 @@ namespace cudautils {
void operator()(void const* ptrs[], Tuple const& t) {}
};

#if 0
#endif

} // namespace detail

// wrappers for cudaLaunchKernel

void launch(void (*kernel)(), LaunchParameters config) {
inline void launch(void (*kernel)(), LaunchParameters config) {
cudaCheck(cudaLaunchKernel(
(const void*)kernel, config.gridDim, config.blockDim, nullptr, config.sharedMem, config.stream));
}

template <typename F, typename... Args>
template <typename F, typename... Args> inline
#if __cplusplus >= 201703L
std::enable_if_t<std::is_invocable_r<void, F, Args&&...>::value>
#else
Expand All @@ -120,12 +117,12 @@ namespace cudautils {

// wrappers for cudaLaunchCooperativeKernel

void launch_cooperative(void (*kernel)(), LaunchParameters config) {
inline void launch_cooperative(void (*kernel)(), LaunchParameters config) {
cudaCheck(cudaLaunchCooperativeKernel(
(const void*)kernel, config.gridDim, config.blockDim, nullptr, config.sharedMem, config.stream));
}

template <typename F, typename... Args>
template <typename F, typename... Args> inline
#if __cplusplus >= 201703L
std::enable_if_t<std::is_invocable_r<void, F, Args&&...>::value>
#else
Expand Down