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

[Bug]: 使用setup安装的时候找不到CUTLASS #1048

Open
Powerofev1l opened this issue Mar 8, 2025 · 1 comment
Open

[Bug]: 使用setup安装的时候找不到CUTLASS #1048

Powerofev1l opened this issue Mar 8, 2025 · 1 comment

Comments

@Powerofev1l
Copy link

Issue Type

Build/Install

Modules Involved

Others

Have you reproduced the bug with SPU HEAD?

Yes

Have you searched existing issues?

No

SPU Version

0.9.x

OS Platform and Distribution

22.04

Python Version

3.10

Compiler Version

No response

Current Behavior?

a

Standalone code to reproduce the issue

无论我使用bazel build还是setup.py都不行
(spu) root@autodl-container-861d418dc2-77de5b2b:~/spu-main# bazel build //:spu_wheel -c opt --config=gpu
ERROR: Skipping '//:spu_wheel': no such target '//:spu_wheel': target 'spu_wheel' not declared in package '' defined by /root/spu-main/BUILD.bazel (Tip: use `query "//:*"` to see all the targets in that package)
WARNING: Target pattern parsing failed.
INFO: Build options --copt and --host_copt have changed, discarding analysis cache.
INFO: Analyzed 0 targets (1 packages loaded, 0 targets configured).
INFO: Found 0 targets...
ERROR: command succeeded, but there were errors parsing the target pattern
INFO: Elapsed time: 1.669s, Critical Path: 0.00s
INFO: 1 process: 1 internal.
FAILED: Build did NOT complete successfully

Relevant log output

spu) root@autodl-container-861d418dc2-77de5b2b:~/spu-main# export ENABLE_GPU_BUILD=1 && python setup.py bdist_wheel
INFO: Starting clean (this may take a while). Consider using --async if the clean takes more than several minutes.
/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/__init__.py:94: _DeprecatedInstaller: setuptools.installer and fetch_build_eggs are deprecated.
!!

        ********************************************************************************
        Requirements should be satisfied by a PEP 517 installer.
        If you are using pip, you can try `pip install --use-pep517`.
        ********************************************************************************

!!
  dist.fetch_build_eggs(dist.setup_requires)
running bdist_wheel
running build
running build_py
creating build/lib.linux-x86_64-cpython-310/spu
copying spu/__init__.py -> build/lib.linux-x86_64-cpython-310/spu
copying spu/api.py -> build/lib.linux-x86_64-cpython-310/spu
copying spu/psi.py -> build/lib.linux-x86_64-cpython-310/spu
copying spu/spu_pb2.py -> build/lib.linux-x86_64-cpython-310/spu
copying spu/version.py -> build/lib.linux-x86_64-cpython-310/spu
creating build/lib.linux-x86_64-cpython-310/spu/experimental
copying spu/experimental/__init__.py -> build/lib.linux-x86_64-cpython-310/spu/experimental
copying spu/experimental/drop_cached_var_impl.py -> build/lib.linux-x86_64-cpython-310/spu/experimental
copying spu/experimental/make_cached_var_impl.py -> build/lib.linux-x86_64-cpython-310/spu/experimental
creating build/lib.linux-x86_64-cpython-310/spu/intrinsic
copying spu/intrinsic/__init__.py -> build/lib.linux-x86_64-cpython-310/spu/intrinsic
copying spu/intrinsic/add_new_intrinsic.py -> build/lib.linux-x86_64-cpython-310/spu/intrinsic
copying spu/intrinsic/example_binary_impl.py -> build/lib.linux-x86_64-cpython-310/spu/intrinsic
copying spu/intrinsic/example_impl.py -> build/lib.linux-x86_64-cpython-310/spu/intrinsic
creating build/lib.linux-x86_64-cpython-310/spu/ops
copying spu/ops/__init__.py -> build/lib.linux-x86_64-cpython-310/spu/ops
creating build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/__init__.py -> build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/distributed.py -> build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/distributed_impl.py -> build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/frontend.py -> build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/polyfill.py -> build/lib.linux-x86_64-cpython-310/spu/utils
copying spu/utils/simulation.py -> build/lib.linux-x86_64-cpython-310/spu/utils
creating build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/__init__.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/aggregation.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/groupby_test.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/groupby_via_shuffle.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/postprocess.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/segmentation.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/shuffle.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
copying spu/ops/groupby/utils.py -> build/lib.linux-x86_64-cpython-310/spu/ops/groupby
running build_ext
Build with extra flags = ['--verbose_failures', '--http_timeout_scaling=10.0', '--remote_retries=10', '-c', 'opt', '--config=gpu', '--config=avx']
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/xla/third_party/llvm/workspace.bzl:9:10: GGGGGG
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/xla/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'llvm-raw' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'com_google_absl' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'eigen_archive' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'pybind11_bazel' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'com_google_protobuf' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'com_google_googletest' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'com_github_gflags_gflags' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'com_github_grpc_grpc' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'zlib' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'nvtx_archive' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'pybind11' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/tsl/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'upb' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/xla/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'jsoncpp_git' because it already exists.
DEBUG: /root/.cache/bazel/_bazel_root/913b7ed37662cd469f2231252915f2c9/external/xla/third_party/repo.bzl:132:14: 
Warning: skipping import of repository 'cutlass_archive' because it already exists.
ERROR: /root/spu-main/libspu/cuda_support/BUILD.bazel:20:13: no such package '@com_github_nvidia_cutlass//': The repository '@com_github_nvidia_cutlass' could not be resolved: Repository '@com_github_nvidia_cutlass' is not defined and referenced by '//libspu/cuda_support:kernels'
WARNING: /root/spu-main/libspu/compiler/front_end/BUILD.bazel:18:15: in cc_library rule //libspu/compiler/front_end:hlo_importer: Target '//libspu/compiler/front_end:hlo_importer' violates visibility of target '@xla//xla/service/gpu/transforms:dot_dimension_sorter'. Continuing because --nocheck_visibility is active
WARNING: errors encountered while analyzing target '//spu:init': it will not be built
WARNING: errors encountered while analyzing target '//spu/utils:distributed': it will not be built
WARNING: errors encountered while analyzing target '//spu:api': it will not be built
INFO: Analyzed 3 targets (343 packages loaded, 36975 targets configured).
INFO: Found 0 targets...
ERROR: command succeeded, but not all targets were analyzed
INFO: Elapsed time: 7.197s, Critical Path: 0.02s
INFO: 1 process: 1 internal.
FAILED: Build did NOT complete successfully
Traceback (most recent call last):
  File "/root/spu-main/setup.py", line 275, in <module>
    setuptools.setup(
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/__init__.py", line 117, in setup
    return distutils.core.setup(**attrs)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 186, in setup
    return run_commands(dist)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 202, in run_commands
    dist.run_commands()
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 983, in run_commands
    self.run_command(cmd)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/dist.py", line 999, in run_command
    super().run_command(command)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 1002, in run_command
    cmd_obj.run()
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/command/bdist_wheel.py", line 379, in run
    self.run_command("build")
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 339, in run_command
    self.distribution.run_command(command)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/dist.py", line 999, in run_command
    super().run_command(command)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 1002, in run_command
    cmd_obj.run()
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/command/build.py", line 136, in run
    self.run_command(cmd_name)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 339, in run_command
    self.distribution.run_command(command)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/dist.py", line 999, in run_command
    super().run_command(command)
  File "/root/miniconda3/envs/spu/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 1002, in run_command
    cmd_obj.run()
  File "/root/spu-main/setup.py", line 246, in run
    return pip_run(self)
  File "/root/spu-main/setup.py", line 217, in pip_run
    build(True, True)
  File "/root/spu-main/setup.py", line 173, in build
    return bazel_invoke(
  File "/root/spu-main/setup.py", line 123, in bazel_invoke
    result = invoker(['bazel'] + cmdline, *args, **kwargs)
  File "/root/miniconda3/envs/spu/lib/python3.10/subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['bazel', 'build', '--verbose_failures', '--http_timeout_scaling=10.0', '--remote_retries=10', '-c', 'opt', '--config=gpu', '--config=avx', '--', '//spu:init', '//spu/utils:distributed', '//spu:api']' returned non-zero exit status 1.
@w-gc
Copy link
Collaborator

w-gc commented Mar 10, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants