Skip to content

Commit

Permalink
[NCCL] Upgrade TF NCCL version to 2.18.5
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 576427971
  • Loading branch information
tensorflower-gardener committed Oct 25, 2023
1 parent 3b257c1 commit 78de87b
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 49 deletions.
2 changes: 1 addition & 1 deletion tensorflow/tools/pip_package/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ def standard_or_nightly(standard, nightly):
'nvidia-curand-cu12 == 10.3.3.141',
'nvidia-cusolver-cu12 == 11.5.2.141',
'nvidia-cusparse-cu12 == 12.1.2.141',
'nvidia-nccl-cu12 == 2.16.5',
'nvidia-nccl-cu12 == 2.18.3',
'nvidia-nvjitlink-cu12 == 12.2.140',
'tensorrt == 8.6.1.post1',
'tensorrt-bindings == 8.6.1',
Expand Down
6 changes: 3 additions & 3 deletions tensorflow/workspace2.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -507,9 +507,9 @@ def _tf_repositories():
name = "nccl_archive",
build_file = "//third_party:nccl/archive.BUILD",
patch_file = ["//third_party/nccl:archive.patch"],
sha256 = "0e3d7b6295beed81dc15002e88abf7a3b45b5c686b13b779ceac056f5612087f",
strip_prefix = "nccl-2.16.5-1",
urls = tf_mirror_urls("https://github.com/nvidia/nccl/archive/v2.16.5-1.tar.gz"),
sha256 = "16ac98f3e926c024ce48e10ab220e19ce734adc48c423cfd55ad6f509bd1179f",
strip_prefix = "nccl-2.18.5-1",
urls = tf_mirror_urls("https://github.com/nvidia/nccl/archive/v2.18.5-1.tar.gz"),
)

java_import_external(
Expand Down
6 changes: 5 additions & 1 deletion third_party/nccl/archive.BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ load(

NCCL_MAJOR = 2

NCCL_MINOR = 16
NCCL_MINOR = 18

NCCL_PATCH = 5

Expand Down Expand Up @@ -210,6 +210,10 @@ cuda_library(
],
include_prefix = "third_party/nccl",
linkopts = ["-lrt"],
# The following definition is needed to enable placeholder literals such as
# PRIx64 defined at the inttypes.h since Tensorflow docker image uses
# an old version of glibc.
local_defines = ["__STDC_FORMAT_MACROS"],
strip_include_prefix = "src",
target_compatible_with = select({
"@local_config_cuda//cuda:using_clang": [],
Expand Down
13 changes: 0 additions & 13 deletions third_party/nccl/archive.patch
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,6 @@ diff --git a/src/collectives/device/sendrecv.cu b/src/collectives/device/sendrec
similarity index 100%
rename from src/collectives/device/sendrecv.cu
rename to src/collectives/device/sendrecv.cu.cc
diff --git a/src/include/nvtx.h b/src/include/nvtx.h
index 2aeb932..cdc67d2 100644
--- a/src/include/nvtx.h
+++ b/src/include/nvtx.h
@@ -37,7 +37,7 @@ struct nccl_domain{static constexpr char const* name{"NCCL"};};

class payload_schema {
public:
- NVTX3_RELAXED_CONSTEXPR explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
+ explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
{
schema_attr.name = schemaName;
schema_attr.entries = entries;
diff --git a/src/collectives/device/common.h b/src/collectives/device/common.h
index accf8371a..4ab1bfac6 100644
--- a/src/collectives/device/common.h
Expand Down
6 changes: 5 additions & 1 deletion third_party/xla/third_party/nccl/archive.BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ load(

NCCL_MAJOR = 2

NCCL_MINOR = 16
NCCL_MINOR = 18

NCCL_PATCH = 5

Expand Down Expand Up @@ -210,6 +210,10 @@ cuda_library(
],
include_prefix = "third_party/nccl",
linkopts = ["-lrt"],
# The following definition is needed to enable placeholder literals such as
# PRIx64 defined at the inttypes.h since Tensorflow docker image uses
# an old version of glibc.
local_defines = ["__STDC_FORMAT_MACROS"],
strip_include_prefix = "src",
target_compatible_with = select({
"@local_config_cuda//cuda:using_clang": [],
Expand Down
13 changes: 0 additions & 13 deletions third_party/xla/third_party/nccl/archive.patch
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,6 @@ diff --git a/src/collectives/device/sendrecv.cu b/src/collectives/device/sendrec
similarity index 100%
rename from src/collectives/device/sendrecv.cu
rename to src/collectives/device/sendrecv.cu.cc
diff --git a/src/include/nvtx.h b/src/include/nvtx.h
index 2aeb932..cdc67d2 100644
--- a/src/include/nvtx.h
+++ b/src/include/nvtx.h
@@ -37,7 +37,7 @@ struct nccl_domain{static constexpr char const* name{"NCCL"};};

class payload_schema {
public:
- NVTX3_RELAXED_CONSTEXPR explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
+ explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
{
schema_attr.name = schemaName;
schema_attr.entries = entries;
diff --git a/src/collectives/device/common.h b/src/collectives/device/common.h
index accf8371a..4ab1bfac6 100644
--- a/src/collectives/device/common.h
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ load(

NCCL_MAJOR = 2

NCCL_MINOR = 16
NCCL_MINOR = 18

NCCL_PATCH = 5

Expand Down Expand Up @@ -210,6 +210,10 @@ cuda_library(
],
include_prefix = "third_party/nccl",
linkopts = ["-lrt"],
# The following definition is needed to enable placeholder literals such as
# PRIx64 defined at the inttypes.h since Tensorflow docker image uses
# an old version of glibc.
local_defines = ["__STDC_FORMAT_MACROS"],
strip_include_prefix = "src",
target_compatible_with = select({
"@local_config_cuda//cuda:using_clang": [],
Expand Down
13 changes: 0 additions & 13 deletions third_party/xla/third_party/tsl/third_party/nccl/archive.patch
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,6 @@ diff --git a/src/collectives/device/sendrecv.cu b/src/collectives/device/sendrec
similarity index 100%
rename from src/collectives/device/sendrecv.cu
rename to src/collectives/device/sendrecv.cu.cc
diff --git a/src/include/nvtx.h b/src/include/nvtx.h
index 2aeb932..cdc67d2 100644
--- a/src/include/nvtx.h
+++ b/src/include/nvtx.h
@@ -37,7 +37,7 @@ struct nccl_domain{static constexpr char const* name{"NCCL"};};

class payload_schema {
public:
- NVTX3_RELAXED_CONSTEXPR explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
+ explicit payload_schema(const nvtxPayloadSchemaEntry_t entries[], size_t numEntries, const uint64_t schemaId, const char* schemaName = nullptr) noexcept
{
schema_attr.name = schemaName;
schema_attr.entries = entries;
diff --git a/src/collectives/device/common.h b/src/collectives/device/common.h
index accf8371a..4ab1bfac6 100644
--- a/src/collectives/device/common.h
Expand Down
6 changes: 3 additions & 3 deletions third_party/xla/third_party/tsl/workspace2.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -424,9 +424,9 @@ def _tf_repositories():
name = "nccl_archive",
build_file = "//third_party:nccl/archive.BUILD",
patch_file = ["//third_party/nccl:archive.patch"],
sha256 = "0e3d7b6295beed81dc15002e88abf7a3b45b5c686b13b779ceac056f5612087f",
strip_prefix = "nccl-2.16.5-1",
urls = tf_mirror_urls("https://github.com/nvidia/nccl/archive/v2.16.5-1.tar.gz"),
sha256 = "16ac98f3e926c024ce48e10ab220e19ce734adc48c423cfd55ad6f509bd1179f",
strip_prefix = "nccl-2.18.5-1",
urls = tf_mirror_urls("https://github.com/nvidia/nccl/archive/v2.18.5-1.tar.gz"),
)

java_import_external(
Expand Down

0 comments on commit 78de87b

Please sign in to comment.