diff options
author | pg <pg@yandex-team.com> | 2025-02-21 07:26:40 +0300 |
---|---|---|
committer | pg <pg@yandex-team.com> | 2025-02-21 07:46:38 +0300 |
commit | 6439b5a3fc32966be75de7839c2ca04246448589 (patch) | |
tree | 1bc0ecf538a0b27f0c6d43e84923b07f96586f1c /build/scripts/link_dyn_lib.py | |
parent | f497aea13d73711c8a4edd6a9a1549b89faea6e9 (diff) | |
download | ydb-6439b5a3fc32966be75de7839c2ca04246448589.tar.gz |
refactor out cuda support plugin
commit_hash:1507ae315ae21b87283bf38786230eb5a7352a3d
Diffstat (limited to 'build/scripts/link_dyn_lib.py')
-rw-r--r-- | build/scripts/link_dyn_lib.py | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/build/scripts/link_dyn_lib.py b/build/scripts/link_dyn_lib.py index 307b539429..9322c5fbf8 100644 --- a/build/scripts/link_dyn_lib.py +++ b/build/scripts/link_dyn_lib.py @@ -129,26 +129,6 @@ def fix_windows_param(ex): return ['/DEF:{}'.format(def_file.name)] -CUDA_LIBRARIES = { - '-lcublas_static': '-lcublas', - '-lcublasLt_static': '-lcublasLt', - '-lcudart_static': '-lcudart', - '-lcudnn_static': '-lcudnn', - '-lcufft_static_nocallback': '-lcufft', - '-lcurand_static': '-lcurand', - '-lcusolver_static': '-lcusolver', - '-lcusparse_static': '-lcusparse', - '-lmyelin_compiler_static': '-lmyelin', - '-lmyelin_executor_static': '-lnvcaffe_parser', - '-lmyelin_pattern_library_static': '', - '-lmyelin_pattern_runtime_static': '', - '-lnvinfer_static': '-lnvinfer', - '-lnvinfer_plugin_static': '-lnvinfer_plugin', - '-lnvonnxparser_static': '-lnvonnxparser', - '-lnvparsers_static': '-lnvparsers', -} - - def fix_cmd(arch, c): if arch == 'WINDOWS': prefix = '/DEF:' @@ -174,16 +154,6 @@ def fix_cmd(arch, c): return sum((do_fix(x) for x in c), []) -def fix_cmd_for_dynamic_cuda(cmd): - flags = [] - for flag in cmd: - if flag in CUDA_LIBRARIES: - flags.append(CUDA_LIBRARIES[flag]) - else: - flags.append(flag) - return flags - - def parse_args(args): parser = optparse.OptionParser() parser.disable_interspersed_args() @@ -231,13 +201,6 @@ if __name__ == '__main__': cmd = args cmd = fix_cmd(opts.arch, cmd) - if opts.dynamic_cuda: - cmd = fix_cmd_for_dynamic_cuda(cmd) - else: - cuda_manager = link_exe.CUDAManager(opts.cuda_architectures, opts.nvprune_exe) - cmd = link_exe.process_cuda_libraries_by_nvprune(cmd, cuda_manager, opts.build_root) - cmd = link_exe.process_cuda_libraries_by_objcopy(cmd, opts.build_root, opts.objcopy_exe) - cmd = ProcessWholeArchiveOption(opts.arch, opts.whole_archive_peers, opts.whole_archive_libs).construct_cmd(cmd) thinlto_cache.preprocess(opts, cmd) |