diff --git a/SECURITY.md b/SECURITY.md index 2d0debdc9dfae5d0b276dec35037f56fb634b51f..51ce2211a01caf416e58f4063275c8501e299bdd 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -12,6 +12,7 @@ If you identify a vulnerability then please report the issue to the Arm Product Scripts within this project may download and patch third party sources. These third party sources are: -* TensorFlow (commit: 'd72f781') -* LLVM (commit: '2d287f5') +* TensorFlow (commit: 'da8018a052b8bfbed60e3baf7b908a1017c97126') +* LLVM (commit: 'f8cb7987c64dcffb72414a40560055cb717dbf74') * pybind11 2.13.4 +* rules_shell 0.4.1 diff --git a/WORKSPACE b/WORKSPACE index c8ca62135c7f38a06e9d3e8694852b21159edf03..ab65eac91c4e0c01b1e3912d538832ebe767386e 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -8,11 +8,17 @@ workspace(name = "tosa_converter_for_tflite") load("//patches:patches_list.bzl", "tensorflow_patch_list", "llvm_patch_list") -TENSORFLOW_COMMIT = "d72f78171ae6089422f6cde01046f545a3e369f8" -TENSORFLOW_SHA256 = "1a41ed277deb329b6ab62f18ab039c4f42ef062c6a24e458d84aa28b83a0b39e" +# Updating the commit of TF may require alignement between this WORKSPACE and the upstream TF one +# along with LLVM_COMMIT and RULES_SHELL_VERSION used in upstream TF +TENSORFLOW_COMMIT = "da8018a052b8bfbed60e3baf7b908a1017c97126" +TENSORFLOW_SHA256 = "5f5f8f1c532c50998566a2e7f9d43d977b8a6541a08ced038f1dac6807fd5e17" + +LLVM_COMMIT = "f8cb7987c64dcffb72414a40560055cb717dbf74" +LLVM_SHA256 = "2fb69c816106c22518a9b677d5daa7fed900187a84ad0be26453f5763ee88424" + +RULES_SHELL_VERSION = "0.4.1" +RULES_SHELL_SHA256 = "bc61ef94facc78e20a645726f64756e5e285a045037c7a61f65af2941f4c25e1" -LLVM_COMMIT = "2d287f51eff2a5fbf84458a33f7fb2493cf67965" -LLVM_SHA256 = "e06d0a35b0e0570b2f54dfd23d0e9fe6f084e032c14bb7ab194b06cb8c9cb86c" load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") http_archive( @@ -32,13 +38,12 @@ tf_workspace3() # Override tf_workspace3 llvm-raw configured repository http_archive( name = "llvm-raw", - build_file = "@org_tensorflow//third_party/llvm:llvm.BUILD", + build_file = "@org_tensorflow//third_party/xla/third_party/llvm:llvm.BUILD", patch_args = ["-p1"], patches = [ - "@org_tensorflow//third_party/llvm:zstd.patch", - # LLVM build.patch to exclude assembly sources on Windows, - # as clang-cl does not support the '.hidden' directive used in those files. - "@org_tensorflow//third_party/llvm:build.patch", + "@org_tensorflow//third_party/xla/third_party/llvm:zstd.patch", + "@org_tensorflow//third_party/xla/third_party/llvm:build.patch", + "@org_tensorflow//third_party/xla/third_party/llvm:memcpy.patch", ] + llvm_patch_list, strip_prefix = "llvm-project-{commit}".format(commit = LLVM_COMMIT), urls = [ @@ -47,6 +52,17 @@ http_archive( sha256 = LLVM_SHA256, ) +http_archive( + name = "rules_shell", + sha256 = RULES_SHELL_SHA256, + strip_prefix = "rules_shell-{version}".format(version = RULES_SHELL_VERSION), + url = "https://github.com/bazelbuild/rules_shell/archive/v{version}.tar.gz".format(version = RULES_SHELL_VERSION), +) + +load("@rules_shell//shell:repositories.bzl", "rules_shell_dependencies", "rules_shell_toolchains") +rules_shell_dependencies() +rules_shell_toolchains() + # Initialize Python load("@local_xla//third_party/py:python_init_rules.bzl", "python_init_rules") python_init_rules() diff --git a/patches/move_dequantize_tfl_softmax_to_tfl_passes.patch b/patches/move_dequantize_tfl_softmax_to_tfl_passes.patch deleted file mode 100644 index 23ee6a088ab9588f79f9109bff6412c4dfb8b934..0000000000000000000000000000000000000000 --- a/patches/move_dequantize_tfl_softmax_to_tfl_passes.patch +++ /dev/null @@ -1,13 +0,0 @@ -# -# SPDX-FileCopyrightText: Copyright 2025 Arm Limited and/or its affiliates -# -# SPDX-License-Identifier: Apache-2.0 -# -diff --git a/tensorflow/compiler/mlir/tosa/BUILD b/tensorflow/compiler/mlir/tosa/BUILD -index 4bc56d2d1b4..fc365aadfb1 100644 ---- a/tensorflow/compiler/mlir/tosa/BUILD -+++ b/tensorflow/compiler/mlir/tosa/BUILD -@@ -132 +131,0 @@ cc_library( -- "transforms/dequantize_tfl_softmax.cc", -@@ -189,0 +189 @@ cc_library( -+ "transforms/dequantize_tfl_softmax.cc", diff --git a/patches/patches_list.bzl b/patches/patches_list.bzl index fb9239c36210a588250eedcb4083f27c8b5cc24a..b7fdb7d4a7e8d4507e378ab4a022f99a887a4b93 100644 --- a/patches/patches_list.bzl +++ b/patches/patches_list.bzl @@ -4,8 +4,6 @@ # SPDX-License-Identifier: Apache-2.0 # -tensorflow_patch_list = [ - "//patches:move_dequantize_tfl_softmax_to_tfl_passes.patch" -] +tensorflow_patch_list = [] llvm_patch_list = []