Skip to content

Commit 74fa172

Browse files
committed
Resolve merge conflicts
1 parent 409ac07 commit 74fa172

File tree

18 files changed

+413
-321
lines changed

18 files changed

+413
-321
lines changed
Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,18 @@
1-
<<<<<<< HEAD:tensorflow/tools/tf_sig_build_dockerfiles/setup.packages.rocm.cs7.sh
2-
#!/usr/bin/env bash
3-
#
4-
# Copyright 2022 The TensorFlow Authors. All Rights Reserved.
5-
=======
61
# Copyright 2024 Google LLC.
7-
>>>>>>> upstream/master:tensorflow/lite/experimental/litert/vendors/google_tensor/BUILD
82
#
93
# Licensed under the Apache License, Version 2.0 (the "License");
104
# you may not use this file except in compliance with the License.
115
# You may obtain a copy of the License at
126
#
13-
# http://www.apache.org/licenses/LICENSE-2.0
7+
# http://www.apache.org/licenses/LICENSE-2.0
148
#
159
# Unless required by applicable law or agreed to in writing, software
1610
# distributed under the License is distributed on an "AS IS" BASIS,
1711
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1812
# See the License for the specific language governing permissions and
1913
# limitations under the License.
20-
# ==============================================================================
21-
#
22-
# setup.packages.sh: Given a list of Ubuntu packages, install them and clean up.
23-
# Usage: setup.packages.sh <package_list.txt>
24-
set -e
25-
set -x
2614

27-
<<<<<<< HEAD:tensorflow/tools/tf_sig_build_dockerfiles/setup.packages.rocm.cs7.sh
28-
yum clean all
29-
yum update -y
30-
PKG_LIST=$(sed -e '/^\s*#.*$/d' -e '/^\s*$/d' "$1" | sort -u)
31-
yum --enablerepo=extras install -y $PKG_LIST
32-
=======
3315
package(
3416
# copybara:uncomment default_applicable_licenses = ["//tensorflow:license"],
3517
default_visibility = ["//tensorflow/lite/experimental/litert:__subpackages__"],
3618
)
37-
>>>>>>> upstream/master:tensorflow/lite/experimental/litert/vendors/google_tensor/BUILD

third_party/llvm/generated.patch

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
Auto generated patch. Do not edit or delete it, even if empty.
2-
<<<<<<< HEAD
32
diff -ruN --strip-trailing-cr a/lld/ELF/Config.h b/lld/ELF/Config.h
43
--- a/lld/ELF/Config.h
54
+++ b/lld/ELF/Config.h
@@ -57,5 +56,3 @@ diff -ruN --strip-trailing-cr a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp
5756
demoteSymbolsAndComputeIsPreemptible(ctx);
5857

5958
if (ctx.arg.copyRelocs && ctx.arg.discard != DiscardPolicy::None)
60-
=======
61-
>>>>>>> upstream/master

third_party/llvm/workspace.bzl

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,8 @@ load("//third_party:repo.bzl", "tf_http_archive")
44

55
def repo(name):
66
"""Imports LLVM."""
7-
<<<<<<< HEAD
87
LLVM_COMMIT = "2e5a5237daf82a657561c490845c406e13657311"
98
LLVM_SHA256 = "e0622b7f81a046e1576d8d07c5ba916346c2a1c06528655d3ddd45a1028eac89"
10-
=======
11-
LLVM_COMMIT = "386af4a5c64ab75eaee2448dc38f2e34a40bfed0"
12-
LLVM_SHA256 = "4b752a2dfb5e4e55cf9812a353bce7e437e0852f4eef64929f48d74732080c50"
13-
>>>>>>> upstream/master
149

1510
tf_http_archive(
1611
name = name,

third_party/shardy/temporary.patch

Lines changed: 0 additions & 123 deletions
Original file line numberDiff line numberDiff line change
@@ -1,119 +1,4 @@
11
diff --git a/third_party/llvm/generated.patch b/third_party/llvm/generated.patch
2-
<<<<<<< HEAD
3-
index 776d4e6..bdba21a 100644
4-
--- a/third_party/llvm/generated.patch
5-
+++ b/third_party/llvm/generated.patch
6-
@@ -1,56 +1,58 @@
7-
Auto generated patch. Do not edit or delete it, even if empty.
8-
-diff -ruN --strip-trailing-cr a/llvm/lib/CodeGen/GlobalMerge.cpp b/llvm/lib/CodeGen/GlobalMerge.cpp
9-
---- a/llvm/lib/CodeGen/GlobalMerge.cpp
10-
-+++ b/llvm/lib/CodeGen/GlobalMerge.cpp
11-
-@@ -423,12 +423,24 @@
12-
+diff -ruN --strip-trailing-cr a/lld/ELF/Config.h b/lld/ELF/Config.h
13-
+--- a/lld/ELF/Config.h
14-
++++ b/lld/ELF/Config.h
15-
+@@ -619,7 +619,6 @@
16-
+ };
17-
+ ElfSym sym{};
18-
+ std::unique_ptr<SymbolTable> symtab;
19-
+- SmallVector<Symbol *, 0> synthesizedSymbols;
20-
+
21-
+ SmallVector<std::unique_ptr<MemoryBuffer>> memoryBuffers;
22-
+ SmallVector<ELFFileBase *, 0> objectFiles;
23-
+diff -ruN --strip-trailing-cr a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp
24-
+--- a/lld/ELF/Writer.cpp
25-
++++ b/lld/ELF/Writer.cpp
26-
+@@ -149,7 +149,6 @@
27-
+ if (!s || s->isDefined() || s->isCommon())
28-
+ return nullptr;
29-
+
30-
+- ctx.synthesizedSymbols.push_back(s);
31-
+ s->resolve(ctx, Defined{ctx, ctx.internalFile, StringRef(), STB_GLOBAL,
32-
+ stOther, STT_NOTYPE, val,
33-
+ /*size=*/0, sec});
34-
+@@ -283,7 +282,6 @@
35-
+ static void demoteSymbolsAndComputeIsPreemptible(Ctx &ctx) {
36-
+ llvm::TimeTraceScope timeScope("Demote symbols");
37-
+ DenseMap<InputFile *, DenseMap<SectionBase *, size_t>> sectionIndexMap;
38-
+- bool hasDynSymTab = ctx.arg.hasDynSymTab;
39-
+ for (Symbol *sym : ctx.symtab->getSymbols()) {
40-
+ if (auto *d = dyn_cast<Defined>(sym)) {
41-
+ if (d->section && !d->section->isLive())
42-
+@@ -296,12 +294,11 @@
43-
+ sym->type)
44-
+ .overwrite(*sym);
45-
+ sym->versionId = VER_NDX_GLOBAL;
46-
+- if (sym->includeInDynsym(ctx))
47-
+- sym->isExported = true;
48-
+ }
49-
}
50-
- }
51-
52-
-+ // Now we found a bunch of sets of globals used together. We accumulated
53-
-+ // the number of times we encountered the sets (i.e., the number of functions
54-
-+ // that use that exact set of globals).
55-
-+ //
56-
-+ // Multiply that by the size of the set to give us a crude profitability
57-
-+ // metric.
58-
-+ llvm::stable_sort(UsedGlobalSets,
59-
-+ [](const UsedGlobalSet &UGS1, const UsedGlobalSet &UGS2) {
60-
-+ return UGS1.Globals.count() * UGS1.UsageCount <
61-
-+ UGS2.Globals.count() * UGS2.UsageCount;
62-
-+ });
63-
-+
64-
- // We can choose to merge all globals together, but ignore globals never used
65-
- // with another global. This catches the obviously non-profitable cases of
66-
- // having a single global, but is aggressive enough for any other case.
67-
- if (GlobalMergeIgnoreSingleUse) {
68-
- BitVector AllGlobals(Globals.size());
69-
-- for (const UsedGlobalSet &UGS : UsedGlobalSets) {
70-
-+ for (const UsedGlobalSet &UGS : llvm::reverse(UsedGlobalSets)) {
71-
- if (UGS.UsageCount == 0)
72-
- continue;
73-
- if (UGS.Globals.count() > 1)
74-
-@@ -437,16 +449,6 @@
75-
- return doMerge(Globals, AllGlobals, M, isConst, AddrSpace);
76-
+- if (hasDynSymTab)
77-
++ sym->isExported = sym->includeInDynsym(ctx);
78-
++ if (ctx.arg.hasDynSymTab)
79-
+ sym->isPreemptible = sym->isExported && computeIsPreemptible(ctx, *sym);
80-
+ }
81-
+ }
82-
+@@ -1839,11 +1836,6 @@
83-
+ }
84-
}
85-
86-
-- // Now we found a bunch of sets of globals used together. We accumulated
87-
-- // the number of times we encountered the sets (i.e., the number of functions
88-
-- // that use that exact set of globals). Multiply that by the size of the set
89-
-- // to give us a crude profitability metric.
90-
-- llvm::stable_sort(UsedGlobalSets,
91-
-- [](const UsedGlobalSet &UGS1, const UsedGlobalSet &UGS2) {
92-
-- return UGS1.Globals.count() * UGS1.UsageCount >=
93-
-- UGS2.Globals.count() * UGS2.UsageCount;
94-
-- });
95-
+- // If the previous code block defines any non-hidden symbols (e.g.
96-
+- // __global_pointer$), they may be exported.
97-
+- for (Symbol *sym : ctx.synthesizedSymbols)
98-
+- sym->isExported = sym->includeInDynsym(ctx);
99-
-
100-
- // Starting from the sets with the best (=biggest) profitability, find a
101-
- // good combination.
102-
- // The ideal (and expensive) solution can only be found by trying all
103-
-@@ -456,7 +458,7 @@
104-
- BitVector PickedGlobals(Globals.size());
105-
- bool Changed = false;
106-
+ demoteSymbolsAndComputeIsPreemptible(ctx);
107-
108-
-- for (const UsedGlobalSet &UGS : UsedGlobalSets) {
109-
-+ for (const UsedGlobalSet &UGS : llvm::reverse(UsedGlobalSets)) {
110-
- if (UGS.UsageCount == 0)
111-
- continue;
112-
- if (PickedGlobals.anyCommon(UGS.Globals))
113-
+ if (ctx.arg.copyRelocs && ctx.arg.discard != DiscardPolicy::None)
114-
diff --git a/third_party/llvm/workspace.bzl b/third_party/llvm/workspace.bzl
115-
index 6b3934d..9a336b9 100644
116-
=======
1172
index f35b1a3..509398d 100644
1183
--- a/third_party/llvm/generated.patch
1194
+++ b/third_party/llvm/generated.patch
@@ -628,24 +513,16 @@ index f35b1a3..509398d 100644
628513
-+^11 = blockcount: 0
629514
diff --git a/third_party/llvm/workspace.bzl b/third_party/llvm/workspace.bzl
630515
index d2ef15d..c4a6676 100644
631-
>>>>>>> upstream/master
632516
--- a/third_party/llvm/workspace.bzl
633517
+++ b/third_party/llvm/workspace.bzl
634518
@@ -4,8 +4,8 @@ load("//third_party:repo.bzl", "tf_http_archive")
635519

636520
def repo(name):
637521
"""Imports LLVM."""
638-
<<<<<<< HEAD
639-
- LLVM_COMMIT = "77c780d64b950d6850d5ec1ee06cd0c21b38b89e"
640-
- LLVM_SHA256 = "109bdf7b5e62992fa8ccf9445eb462b046ffc6409de859f5f7482ea3cde8f967"
641-
+ LLVM_COMMIT = "2e5a5237daf82a657561c490845c406e13657311"
642-
+ LLVM_SHA256 = "e0622b7f81a046e1576d8d07c5ba916346c2a1c06528655d3ddd45a1028eac89"
643-
=======
644522
- LLVM_COMMIT = "f0d05b099dafda89df4c971b64b2051c33db5da1"
645523
- LLVM_SHA256 = "29326f27b5bffa5f57b0f8a99d3e864c09a67bf899341103a7cd609fd3ea80e3"
646524
+ LLVM_COMMIT = "386af4a5c64ab75eaee2448dc38f2e34a40bfed0"
647525
+ LLVM_SHA256 = "4b752a2dfb5e4e55cf9812a353bce7e437e0852f4eef64929f48d74732080c50"
648-
>>>>>>> upstream/master
649526

650527
tf_http_archive(
651528
name = name,

third_party/shardy/workspace.bzl

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,8 @@
33
load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls")
44

55
def repo():
6-
<<<<<<< HEAD
7-
SHARDY_COMMIT = "8cf632f5e74c3777fc47d19525a9e2e1c597fc54"
8-
SHARDY_SHA256 = "12be33b73a5d2bb45df138fab2400b411e4e7b3ad5a058acb6ef397b2252c8df"
9-
=======
106
SHARDY_COMMIT = "71c3f3293063aa4301d72c9b3a1e15bd568a8ffd"
117
SHARDY_SHA256 = "d60c69d1f842c4358586a5eed572818b7320485924b0bdd4fcc4ca2ea367b37c"
12-
>>>>>>> upstream/master
138

149
tf_http_archive(
1510
name = "shardy",

0 commit comments

Comments
 (0)