Skip to content

无法兼容CUDA13.0版本 #21

@Vinci-hit

Description

@Vinci-hit

默认会检测出跟cuda版本不匹配的sm59等架构,在手动修改了架构编号后再编译,会出现c++版本不匹配,强制制定了c++版本后,会出现error: namespace "cub" has no member "Max" max_val = BlockReduce(temp).Reduce(max_val, cub::Max());

通过导入
#include <cuda/std/functional>
修改为
max_val = BlockReduce(temp).Reduce(max_val, cuda::maximum<float>{});
解决

查询官方文档发现,cub::Max()确实不存在。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions