-
Notifications
You must be signed in to change notification settings - Fork 162
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 jobs using clang as CUDA compiler #493
Merged
Merged
Changes from 26 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
1e5c6b3
Allow setting CUDA compiler via CMAKE_CUDA_COMPILER envvar.
jrhemstad 388af5b
Move nvcc version check to CUB script.
jrhemstad b625e93
Add clang-cuda job to matrix.
jrhemstad 260805f
Add compiler field to matrix for clang-cuda.
jrhemstad 5ac0622
Add Thrust clang-cuda job.
jrhemstad a428b21
Fix formatting.
jrhemstad 3da71f4
s/need/needs/
jrhemstad 25efa7c
Can't spell good.
jrhemstad ce622cf
[skip-tests] Add clang cuda job to status check job.
jrhemstad 13c95ba
Disable other jobs for now.
jrhemstad 800913c
Disable other jobs in status check.
jrhemstad 5667982
Add output to compute matrix job.
jrhemstad 8e66201
Missin quote.
jrhemstad 8a2560b
Fix logic for enabling CUB benchmarks.
jrhemstad dc550e7
Fix reference to cuda version in job name.
jrhemstad afd8f13
make clang-cuda job matrix over libs.
jrhemstad abb8235
Fix build script to use matrix lib value.
jrhemstad 873db9e
Fix job name in status check.
jrhemstad 93a10e5
Fix formatting.
jrhemstad 26938c2
Fix job name.
jrhemstad 1356a4e
Generate custom matrix with cartesian product of libs.
jrhemstad 7437913
Add hacks that allow clang-cuda to work.
wmaxey 81c8efa
Merge branch 'main' into clang-cuda-ci
jrhemstad 22fcb5e
Merge branch 'clang-cuda-ci' of github.com:jrhemstad/cccl into clang-…
jrhemstad 4d4616b
Do not build RDC tests for Clang CUDA
gevtushenko 4e204b2
Attempt to fix thrust::complex for Clang-CUDA
gevtushenko 9acf004
Fix macro definitions that are nvcc specific
miscco ff7a43a
Add missing header that is otherwise coming from the cuda side
miscco 1f3e8c4
Fix invalid initialization order in constructor
miscco 7feab38
Fix clang-cuda being picky about attribute orders
miscco 9f70dc0
clang-cuda requires deduction guides to be marked as `__host__ __devi…
miscco 621ca51
Fix some warnings about unused typedefs
miscco 5802424
Fix invalid ifdefs
miscco 523535d
Rename shadowing typedefs
miscco 4085dd7
Work around compiler crash
miscco 71b37bf
Ignore unused private member warning
miscco 0c8b4a0
Remove non compiling code
miscco afa9004
Add missing includes
miscco 69fe6ed
Fix tests
miscco c0872b9
We need to force include `force_include.h`
miscco 11dd488
Avoid signed / unsigned warnings
miscco 0be8b9d
Properly escape inside asm
miscco c5e2d23
Consider clang-cuda for platform-test
miscco 5583d28
clang can handle subsumption
miscco 0a2bd94
Avoid more signed / unsigned issues
miscco d071520
Escape all the things
miscco d634859
Silence more warnings
miscco 4223917
Remove trailing commata
miscco 8f4beea
Fix two tests that should fail to compile
miscco 44febea
Fix pipeline divergent threads
miscco 91145f4
Disable two tests that rely on managed variables
miscco 0e2cb57
Disable two tests that rely on managed variables
miscco 3eb8e8b
Merge branch 'clang-cuda-ci' of github.com:jrhemstad/cccl into pr/jrh…
miscco 374ecb2
Fix one more test for SM_80
miscco 0685884
Disable test that fails during runtime with an invalid launch parameter
miscco b228f26
Re-enable other jobs.
jrhemstad 8980e65
Merge branch 'clang-cuda-ci' of github.com:jrhemstad/cccl into clang-…
jrhemstad 4be1ed2
Re-enable other jobs in status check.
jrhemstad c8154ee
Update clang-cuda job names.
jrhemstad 7501721
Try not to add invalid flag to clang
miscco fa10123
try to fix `is_nothrow_invocable` test
miscco 16b6e58
Mark is_swappable test as potentially passing
miscco 34e270a
Make MSVC pass
miscco 894c986
Unfail test that seems to pass
miscco b95c9e6
Fix test for nvrtc
miscco 42519b6
Fix fail test
miscco 995fea5
Address review comments
miscco 60682bf
Do not pass warnings flags similar to nvcc for clang-cuda
miscco e1ca980
Merge branch 'main' into clang-cuda-ci
jrhemstad 46f0941
Merge branch 'main' into pr/jrhemstad/493
miscco File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -628,12 +628,17 @@ def configure_compile_flags(self): | |||||
self.config.available_features.add("nvrtc") | ||||||
if self.cxx.type == 'nvcc': | ||||||
self.cxx.compile_flags += ['--extended-lambda'] | ||||||
real_arch_format = '-gencode=arch=compute_{0},code=sm_{0}' | ||||||
virt_arch_format = '-gencode=arch=compute_{0},code=compute_{0}' | ||||||
if self.cxx.type == 'clang': | ||||||
real_arch_format = '--cuda-gpu-arch=sm_{0}' | ||||||
virt_arch_format = '--cuda-gpu-arch=compute_{0}' | ||||||
pre_sm_32 = True | ||||||
pre_sm_60 = True | ||||||
pre_sm_70 = True | ||||||
pre_sm_80 = True | ||||||
pre_sm_90 = True | ||||||
if compute_archs and self.cxx.type == 'nvcc': | ||||||
if compute_archs and (self.cxx.type == 'nvcc' or self.cxx.type == 'clang'): | ||||||
pre_sm_32 = False | ||||||
pre_sm_60 = False | ||||||
pre_sm_70 = False | ||||||
|
@@ -654,10 +659,9 @@ def configure_compile_flags(self): | |||||
if arch < 70: pre_sm_70 = True | ||||||
if arch < 80: pre_sm_80 = True | ||||||
if arch < 90: pre_sm_90 = True | ||||||
arch_flag = real_arch_format.format(arch) | ||||||
if mode.count("virtual"): | ||||||
arch_flag = '-gencode=arch=compute_{0},code=compute_{0}'.format(arch) | ||||||
else: | ||||||
arch_flag = '-gencode=arch=compute_{0},code=sm_{0}'.format(arch) | ||||||
arch_flag = virt_arch_format.format(arch) | ||||||
self.cxx.compile_flags += [arch_flag] | ||||||
if pre_sm_32: | ||||||
self.config.available_features.add("pre-sm-32") | ||||||
|
@@ -820,8 +824,9 @@ def configure_compile_flags_header_includes(self): | |||||
and self.cxx_stdlib_under_test != 'libc++'): | ||||||
self.lit_config.note('using the system cxx headers') | ||||||
return | ||||||
if self.cxx.type != 'nvcc' and self.cxx.type != 'nvhpc': | ||||||
self.cxx.compile_flags += ['-nostdinc++'] | ||||||
# I don't think this is required, since removing it helps clang-cuda compile and libcudacxx only supports building in CUDA modes? | ||||||
# if self.cxx.type != 'nvcc' and self.cxx.type != 'pgi': | ||||||
# self.cxx.compile_flags += ['-nostdinc++'] | ||||||
if cxx_headers is None: | ||||||
cxx_headers = os.path.join(self.libcudacxx_src_root, 'include') | ||||||
if not os.path.isdir(cxx_headers): | ||||||
|
@@ -1063,16 +1068,17 @@ def configure_link_flags_cxx_library(self): | |||||
self.cxx.link_flags += ['-lc++experimental'] | ||||||
if self.link_shared: | ||||||
self.cxx.link_flags += ['-lc++'] | ||||||
elif self.cxx.type != 'nvcc' and self.cxx.type != 'nvhpc': | ||||||
cxx_library_root = self.get_lit_conf('cxx_library_root') | ||||||
if cxx_library_root: | ||||||
libname = self.make_static_lib_name('c++') | ||||||
abs_path = os.path.join(cxx_library_root, libname) | ||||||
assert os.path.exists(abs_path) and \ | ||||||
"static libc++ library does not exist" | ||||||
self.cxx.link_flags += [abs_path] | ||||||
else: | ||||||
self.cxx.link_flags += ['-lc++'] | ||||||
# Device code does not have binary components, don't link libc++ | ||||||
# elif self.cxx.type != 'nvcc' and self.cxx.type != 'pgi': | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. how did this change from nvhpc to pgi?
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. maybe just remove completely |
||||||
# cxx_library_root = self.get_lit_conf('cxx_library_root') | ||||||
# if cxx_library_root: | ||||||
# libname = self.make_static_lib_name('c++') | ||||||
# abs_path = os.path.join(cxx_library_root, libname) | ||||||
# assert os.path.exists(abs_path) and \ | ||||||
# "static libc++ library does not exist" | ||||||
# self.cxx.link_flags += [abs_path] | ||||||
# else: | ||||||
# self.cxx.link_flags += ['-lc++'] | ||||||
|
||||||
def configure_link_flags_abi_library(self): | ||||||
cxx_abi = self.get_lit_conf('cxx_abi', 'libcxxabi') | ||||||
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.