add AMF git submodule and build AMF encoding latency test

This commit is contained in:
yukirora 2023-06-29 15:12:39 +00:00
Родитель 3a6622f7d3
Коммит 57cfa5ca0c
4 изменённых файлов: 20 добавлений и 1 удалений

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

@ -21,3 +21,6 @@
[submodule "third_party/gpu-burn"]
path = third_party/gpu-burn
url = https://github.com/wilicc/gpu-burn.git
[submodule "third_party/AMF"]
path = third_party/AMF
url = https://github.com/GPUOpen-LibrariesAndSDKs/AMF.git

Просмотреть файл

@ -59,6 +59,9 @@ RUN python -m pip install setuptools==65.0.0 && \
python -m pip install --no-cache-dir .[amdworker] && \
make directxbuild
ADD third_party third_party
RUN make -C third_party directx_amd
# Run the entrypoint script for enabling vendor-specific graphics APIs
RUN powershell -Command "Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine -Force"
CMD [ "python", "dockerfile/directx/enable-graphics-apis.py" ]

1
third_party/AMF поставляемый Submodule

@ -0,0 +1 @@
Subproject commit bc64bf6e8bfca3083755b7cbec3c23d5546fb04a

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

@ -11,7 +11,7 @@ HPCX_HOME ?= /opt/hpcx
CUDA_VER ?= $(shell nvcc --version | grep 'release' | awk '{print $$6}' | cut -c2- | cut -d '.' -f1-2)
ROCBLAS_BRANCH ?= rocm-$(shell dpkg -l | grep 'rocm-dev ' | awk '{print $$3}' | cut -d '.' -f1-3)
.PHONY: all cuda rocm common cuda_cutlass cuda_bandwidthTest cuda_nccl_tests cuda_perftest rocm_perftest fio rocm_rccl_tests rocm_rocblas rocm_bandwidthTest gpcnet cuda_gpuburn cpu_stream cpu_hpl
.PHONY: all cuda rocm common cuda_cutlass cuda_bandwidthTest cuda_nccl_tests cuda_perftest rocm_perftest fio rocm_rccl_tests rocm_rocblas rocm_bandwidthTest gpcnet cuda_gpuburn cpu_stream cpu_hpl directx_amf_encoding_latency directx_amd
# Build all targets.
all: cuda rocm
@ -19,6 +19,7 @@ cuda: common cuda_cutlass cuda_bandwidthTest cuda_nccl_tests cuda_perftest gpcne
rocm: common rocm_perftest rocm_rccl_tests rocm_rocblas rocm_bandwidthTest
cpu: common cpu_perftest
common: cpu_hpl cpu_stream fio
directx_amd: directx_amf_encoding_latency
# Create $(SB_MICRO_PATH)/bin and $(SB_MICRO_PATH)/lib, no error if existing, make parent directories as needed.
sb_micro_path:
@ -148,3 +149,14 @@ ifneq (,$(wildcard stream-tests/Makefile))
make all
cp -v ./stream-tests/stream*.exe $(SB_MICRO_PATH)/bin/
endif
# Build AMD Encoder Latency Test
directx_amf_encoding_latency:
IF EXIST AMF\amf\public\samples\CPPSamples\EncodingLatency\EncoderLatency_VS2019.vcxproj (
curl -L -o vs_buildtools.exe https://aka.ms/vs/16/release/vs_buildtools.exe && echo "Downloaded vs_buildtools.exe" && \
start /wait vs_buildtools.exe --quiet --wait --norestart --nocache --installPath C:/temp/BuildTools --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Component.VC.ATLMFC --includeRecommended && echo "Installed VS Build Tools" && \
del vs_buildtools.exe && echo "Deleted vs_buildtools.exe" && \
"C:\temp\BuildTools\MSBuild\Current\Bin\MSBuild.exe" "AMF\amf\public\samples\CPPSamples_vs2019.sln" /t:EncoderLatency /p:Configuration=Release /p:OutDir="%SB_MICRO_PATH%\bin"
)