Skip to content

Commit

Permalink
To ensure that C++20 is fully supported in TensorFlow,
Browse files Browse the repository at this point in the history
Ubuntu image used in TF SIG Build Dockerfile upgraded from 20.04 to 22.04 (LTS).

PiperOrigin-RevId: 615889505
  • Loading branch information
tensorflower-gardener committed Apr 8, 2024
1 parent 109ef13 commit e74c9b4
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 24 deletions.
3 changes: 2 additions & 1 deletion ci/official/envs/ci_default
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ TFCI_DOCKER_ENABLE=
TFCI_DOCKER_IMAGE=
TFCI_DOCKER_PULL_ENABLE=
TFCI_DOCKER_REBUILD_ARGS=
TFCI_DOCKER_REBUILD_ENABLE=
# DO_NOT_SUBMIT - This should be disabled before merge
TFCI_DOCKER_REBUILD_ENABLE=1
TFCI_DOCKER_REBUILD_UPLOAD_ENABLE=
TFCI_GIT_DIR=
TFCI_INDEX_HTML_ENABLE=
Expand Down
4 changes: 2 additions & 2 deletions tensorflow/tools/tf_sig_build_dockerfiles/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
################################################################################
FROM ubuntu:20.04 as builder
FROM ubuntu:22.04 as builder
################################################################################

# Install devtoolset build dependencies
Expand All @@ -16,7 +16,7 @@ COPY builder.devtoolset/glibc2.17-inline.patch /glibc2.17-inline.patch
RUN /build_devtoolset.sh devtoolset-9 /dt9

################################################################################
FROM nvidia/cuda:12.3.1-base-ubuntu20.04 as devel
FROM nvidia/cuda:12.3.1-base-ubuntu22.04 as devel
################################################################################
COPY --from=builder /dt9 /dt9

Expand Down
7 changes: 4 additions & 3 deletions tensorflow/tools/tf_sig_build_dockerfiles/devel.packages.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ libnccl2=2.19.3-1+cuda12.3
libcudnn8-dev=8.9.6.50-1+cuda12.2
libcudnn8=8.9.6.50-1+cuda12.2
# TensorRT: See https://docs.nvidia.com/deeplearning/sdk/tensorrt-install-guide/index.html#maclearn-net-repo-install-rpm
libnvinfer-headers-dev=8.6.1.6-1+cuda12.0
libnvinfer-headers-plugin-dev=8.6.1.6-1+cuda12.0
libnvinfer-plugin8=8.6.1.6-1+cuda12.0
libnvinfer8=8.6.1.6-1+cuda12.0
libnvinfer-dev=8.6.1.6-1+cuda12.0
Expand Down Expand Up @@ -57,10 +59,9 @@ libtool
libzmq3-dev
mlocate
moreutils
openjdk-11-jdk
openjdk-11-jre-headless
openjdk-21-jdk
openjdk-21-jre-headless
pkg-config
python3-dev
python3-setuptools
rsync
software-properties-common
Expand Down
8 changes: 4 additions & 4 deletions tensorflow/tools/tf_sig_build_dockerfiles/setup.sources.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ cat >/etc/apt/sources.list.d/custom.list <<SOURCES
deb https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64 /
# More Python versions: Deadsnakes
deb http://ppa.launchpad.net/deadsnakes/ppa/ubuntu focal main
deb-src http://ppa.launchpad.net/deadsnakes/ppa/ubuntu focal main
deb http://ppa.launchpad.net/deadsnakes/ppa/ubuntu jammy main
deb-src http://ppa.launchpad.net/deadsnakes/ppa/ubuntu jammy main
# LLVM/Clang repository
deb http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main
deb-src http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main
deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
deb-src http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
SOURCES
8 changes: 4 additions & 4 deletions tensorflow/tools/toolchains/remote_config/configs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -658,12 +658,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/dt9/usr/bin/gcc",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/dt9/usr/bin/gcc",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down Expand Up @@ -698,12 +698,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/usr/lib/llvm-17/bin/clang",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/usr/lib/llvm-17/bin/clang",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down
4 changes: 2 additions & 2 deletions third_party/llvm/workspace.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ load("//third_party:repo.bzl", "tf_http_archive")

def repo(name):
"""Imports LLVM."""
LLVM_COMMIT = "8487e05967aaa2dceadd582ac8c2b154ccd39db2"
LLVM_SHA256 = "3c3e13568b179126b09f5d1e4e44b32af79150fbd4a12ce617be55726b97717f"
LLVM_COMMIT = "8ee6ab7f69ca9c34eed56faad3971d075dc47121"
LLVM_SHA256 = "c408d2a80a53057fc3596cbfbea3ec64fe8feccbff7adc5e94fde192b96ca568"

tf_http_archive(
name = name,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -658,12 +658,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/dt9/usr/bin/gcc",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/dt9/usr/bin/gcc",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down Expand Up @@ -698,12 +698,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/usr/lib/llvm-17/bin/clang",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/usr/lib/llvm-17/bin/clang",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down
8 changes: 4 additions & 4 deletions third_party/xla/tools/toolchains/remote_config/configs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -658,12 +658,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/dt9/usr/bin/gcc",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/dt9/usr/bin/gcc",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down Expand Up @@ -698,12 +698,12 @@ def initialize_rbe_configs():
# Unclear why LIBC is set to 2.19 here, and yet manylinux2010 is 2.12
# and manylinux2014 is 2.17.
env = {
"ABI_LIBC_VERSION": "glibc_2.19",
"ABI_LIBC_VERSION": "glibc_2.37",
"ABI_VERSION": "gcc",
"BAZEL_COMPILER": "/usr/lib/llvm-17/bin/clang",
"BAZEL_HOST_SYSTEM": "i686-unknown-linux-gnu",
"BAZEL_TARGET_CPU": "k8",
"BAZEL_TARGET_LIBC": "glibc_2.19",
"BAZEL_TARGET_LIBC": "glibc_2.37",
"BAZEL_TARGET_SYSTEM": "x86_64-unknown-linux-gnu",
"CC": "/usr/lib/llvm-17/bin/clang",
"CC_TOOLCHAIN_NAME": "linux_gnu_x86",
Expand Down

0 comments on commit e74c9b4

Please sign in to comment.