Skip to content

cmake case miss #925

@yiyuezhuo

Description

@yiyuezhuo

When I try to build torch from source. I get error:

CMake Error at /home/yiyuezhuo/Downloads/pytorch-master/cmake/FindCUDA/FindCUDA/select_compute_arch.cmake:142 (message):  
Unknown CUDA Architecture Name 2.1(2.0) in CUDA_SELECT_NVCC_ARCH_FLAGS

I look the file select_compute_arch.cmake, I don't know cmake script very well. But I think of the value of arch_name variable is "2.1(2.0)", but it can't be matched by the origin logic. From origin code, it seem likes having same meaning as "Fermi". So I insert these line into select_compute_arch.make:

    elseif(arch_name STREQUAL "2.1(2.0)")
      set(arch_bin 2.0 "2.1(2.0)")

then it works.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions