Benchmarks: Fix bug - fix bug of third_party/cuda-samples git checkout issue when building docker (#126)

* fix bug in docker build of third_party/cuda-samples
This commit is contained in:
Yuting Jiang 2021-07-15 16:41:57 +08:00 коммит произвёл GitHub
Родитель f9550bd693
Коммит 9547ccc19a
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
2 изменённых файлов: 2 добавлений и 6 удалений

3
.gitmodules поставляемый
Просмотреть файл

@ -2,6 +2,3 @@
path = third_party/cutlass
url = https://github.com/NVIDIA/cutlass.git
branch = v2.4.0
[submodule "third_party/cuda-samples"]
path = third_party/cuda-samples
url = https://github.com/NVIDIA/cuda-samples.git

5
third_party/Makefile поставляемый
Просмотреть файл

@ -25,8 +25,7 @@ endif
# The version we use is the released tag of cuda-samples which is consistent with the cuda version in the environment or docker.
# The Makefile of bandwidthTest does not have 'install' target, so need to copy bin to $(SB_MICRO_PATH)/bin/ and create $(SB_MICRO_PATH)/bin/ if not existing.
bandwidthTest: sb_micro_path
ifneq (,$(wildcard cuda-samples/Samples/bandwidthTest/Makefile))
cd cuda-samples && git checkout v$(shell nvcc --version | grep 'release' | awk '{print $$6}' | cut -c2- | cut -d '.' -f1-2)
if [ -d cuda-samples ]; then rm -rf cuda-samples; fi
git clone -b v$(shell nvcc --version | grep 'release' | awk '{print $$6}' | cut -c2- | cut -d '.' -f1-2) https://github.com/NVIDIA/cuda-samples.git ./cuda-samples
cd ./cuda-samples/Samples/bandwidthTest && make clean && make TARGET_ARCH=x86_64 SMS="70 75 80 86"
cp -v ./cuda-samples/Samples/bandwidthTest/bandwidthTest $(SB_MICRO_PATH)/bin/
endif