linux下部署开发者工具包NVIDIA HPC SDK

NVIDIA HPC SDK是一套综合的编译器、库和工具,用于GPU加速HPC建模和仿真应用。随着对运行Linux的NVIDIA gpu和x86-64、OpenPOWER或Arm cpu的支持,NVIDIA HPC SDK为构建跨平台、性能可移植和可扩展的HPC应用程序提供了经过验证的工具和技术。

下面我们就来看看HPC SDK的部署

首先我们去下载部署包,注意这个包也是跟cuda有版本对应,我们是Blackwell架构的卡,所以我们需要cuda12.8及以上的cuda,所以我们HPC SDK选择的25.3,下载地址:https://developer.nvidia.com/nvidia-hpc-sdk-253-downloads

下面是安装和配置过程

wget https://developer.download.nvidia.com/hpc-sdk/25.3/nvhpc_2025_253_Linux_x86_64_cuda_12.8.tar.gz
mkdir -p /opt/compiler
mv nvhpc_2025_253_Linux_x86_64_cuda_12.8.tar.gz /opt/compiler
cd /opt/compiler
tar xpzf nvhpc_2025_253_Linux_x86_64_cuda_12.8.tar.gz
cd nvhpc_2025_253_Linux_x86_64_cuda_12.8
./install

然后会有如下打印

Welcome to the NVIDIA HPC SDK Linux installer!

You are installing NVIDIA HPC SDK 2025 version 25.3 for Linux_x86_64.
Please note that all Trademarks and Marks are the properties
of their respective owners.

Press enter to continue...


A network installation will save disk space by having only one copy of the
compilers and most of the libraries for all compilers on the network, and
the main installation needs to be done once for all systems on the network.

1  Single system install
2  Network install

Please choose install option: 

按回车确认安装位置,默认安装目录是/opt/nvidia/hpc_sdk,再按“1”选择单机安装,安装程序会自行找到之前安装的“cuda toolkit”,安装完成后按回车结束。

最后我们配置下环境变量,我们配置在/etc/profile中

vim /etc/profile
#最下面添加如下配置
NVARCH=`uname -s`_`uname -m`; export NVARCH
NVCOMPILERS=/opt/nvidia/hpc_sdk; export NVCOMPILERS
MANPATH=$MANPATH:$NVCOMPILERS/$NVARCH/25.3/compilers/man; export MANPATH
PATH=$NVCOMPILERS/$NVARCH/25.3/compilers/bin:$PATH; export PATH

上述配置好以后我们使用source命令使其生效

source /etc/profile

最后使用以下命令进行验证即可。

nvc -v
nvcc -v
nvc++ -v
pgcc -v

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://sulao.cn/post/1096

评论列表

0%