Skip to content

Commit

Permalink
Fix iGPU CMakeFile tags (#6695) (#6698)
Browse files Browse the repository at this point in the history
* Unify iGPU test build with x86 ARM

* adding TRITON_IGPU_BUILD to core build definition; adding logic to skip caffe2plan test if TRITON_IGPU_BUILD=1

* re-organizing some copies in Dockerfile.QA to fix igpu devel build

* Pre-commit fix

---------

Co-authored-by: kyle <[email protected]>
  • Loading branch information
kthui and kyle authored Dec 14, 2023
1 parent 2b607f2 commit ebe3ccb
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 16 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,7 @@ ExternalProject_Add(triton-server
-Daws-c-common_DIR:PATH=${TRITON_THIRD_PARTY_INSTALL_PREFIX}/aws-sdk-cpp/${LIB_DIR}/aws-c-common/cmake
-Daws-checksums_DIR:PATH=${TRITON_THIRD_PARTY_INSTALL_PREFIX}/aws-sdk-cpp/${LIB_DIR}/aws-checksums/cmake
-Dopentelemetry-cpp_DIR:PATH=${_FINDPACKAGE_OPENTELEMETRY_CONFIG_DIR}
-DTRITON_IGPU_BUILD:BOOL=${TRITON_IGPU_BUILD}
-DTRITON_THIRD_PARTY_REPO_TAG:STRING=${TRITON_THIRD_PARTY_REPO_TAG}
-DTRITON_COMMON_REPO_TAG:STRING=${TRITON_COMMON_REPO_TAG}
-DTRITON_CORE_REPO_TAG:STRING=${TRITON_CORE_REPO_TAG}
Expand Down
8 changes: 3 additions & 5 deletions Dockerfile.QA
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,13 @@ RUN mkdir -p qa/L0_decoupled/models/repeat_int32/1 && \
mkdir -p qa/L0_decoupled/models/fan_repeat/1 && \
mkdir -p qa/L0_decoupled/models/sequence_repeat/1 && \
mkdir -p qa/L0_decoupled/models/repeat_square/1 && \
mkdir -p qa/L0_decoupled/models/nested_square/1
mkdir -p qa/L0_decoupled/models/nested_square/1 && \
mkdir -p qa/L0_grpc_state_cleanup/models/repeat_int32/1

RUN if [ "$IGPU_BUILD" == "0" ]; then \
cp backends/repeat/libtriton_repeat.so qa/L0_model_config && \
cp backends/repeat/libtriton_repeat.so qa/L0_decoupled/models/repeat_int32/1 && \
cp backends/repeat/libtriton_repeat.so qa/L0_grpc_state_cleanup/models/repeat_int32/1/. && \
cp backends/square/libtriton_square.so qa/L0_decoupled/models/square_int32/1; \
fi

Expand All @@ -264,10 +266,6 @@ RUN cp -r qa/L0_decoupled/models qa/L0_decoupled/python_models/ && \
cp /workspace/tritonbuild/python/examples/decoupled/square_config.pbtxt \
qa/L0_decoupled/python_models/square_int32/.

RUN mkdir -p qa/L0_grpc_state_cleanup/models/repeat_int32/1 && \
cp backends/repeat/libtriton_repeat.so \
qa/L0_grpc_state_cleanup/models/repeat_int32/1/.

RUN mkdir -p qa/L0_repoagent_checksum/models/identity_int32/1 && \
cp tritonbuild/identity/install/backends/identity/libtriton_identity.so \
qa/L0_repoagent_checksum/models/identity_int32/1/.
Expand Down
9 changes: 2 additions & 7 deletions build.py
Original file line number Diff line number Diff line change
Expand Up @@ -616,9 +616,7 @@ def pytorch_cmake_args(images):
if "pytorch" in images:
image = images["pytorch"]
else:
image = "nvcr.io/nvidia/pytorch:{}-py3".format(
FLAGS.upstream_container_version
)
image = "nvcr.io/nvidia/pytorch:{}-py3".format(FLAGS.upstream_container_version)
cargs = [
cmake_backend_arg("pytorch", "TRITON_PYTORCH_DOCKER_IMAGE", None, image),
]
Expand Down Expand Up @@ -651,7 +649,6 @@ def onnxruntime_cmake_args(images, library_paths):
)
)


if target_platform() == "windows":
if "base" in images:
cargs.append(
Expand Down Expand Up @@ -767,9 +764,7 @@ def tensorflow_cmake_args(images, library_paths):
FLAGS.upstream_container_version
)
extra_args = [
cmake_backend_arg(
backend_name, "TRITON_TENSORFLOW_DOCKER_IMAGE", None, image
)
cmake_backend_arg(backend_name, "TRITON_TENSORFLOW_DOCKER_IMAGE", None, image)
]
return extra_args

Expand Down
4 changes: 1 addition & 3 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,5 @@ endif() # NOT WIN32

# Currently unit tests do not build for windows...
if ( NOT WIN32)
if ( NOT EXISTS "/etc/ld.so.conf.d/nvidia-tegra.conf" )
add_subdirectory(test test)
endif()
add_subdirectory(test test)
endif() # NOT WIN32
2 changes: 1 addition & 1 deletion src/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ find_package(GTest REQUIRED)
#
# caffe2plan
#
if(${TRITON_ENABLE_TENSORRT})
if(${TRITON_ENABLE_TENSORRT} AND NOT ${TRITON_IGPU_BUILD})
add_executable(caffe2plan caffe2plan.cc)
target_include_directories(caffe2plan PRIVATE ${CUDA_INCLUDE_DIRS})
target_link_libraries(
Expand Down

0 comments on commit ebe3ccb

Please sign in to comment.