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

open up extra return #103

Merged
merged 1 commit into from
Feb 25, 2022
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
5 changes: 2 additions & 3 deletions include/camp/resource/cuda.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,10 @@ namespace resources
}
}
::camp::throw_re("invalid pointer detected");
#if defined(__CUDACC__) && defined(__CUDA_ARCH__)
// This return statement exists because nvcc is annoying
// This return statement exists because compilers do not determine the
// above unconditionally throws
// related: https://stackoverflow.com/questions/64523302/cuda-missing-return-statement-at-end-of-non-void-function-in-constexpr-if-fun
return MemoryAccess::Unknown;
#endif
}
public:
Cuda(int group = -1, int dev = 0)
Expand Down