Skip to content

Commit 776401c

Browse files
committed
Merge remote-tracking branch 'upstream/main' into users/kevinsala/omp-dyn-groupprivate-pr
2 parents 6e4c547 + c87a29f commit 776401c

File tree

2,577 files changed

+171808
-69167
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,577 files changed

+171808
-69167
lines changed

.ci/compute_projects.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,7 @@
4949
"flang",
5050
},
5151
"lld": {"bolt", "cross-project-tests"},
52-
# TODO(issues/132795): LLDB should be enabled on clang changes.
53-
"clang": {"clang-tools-extra", "cross-project-tests"},
52+
"clang": {"clang-tools-extra", "cross-project-tests", "lldb"},
5453
"mlir": {"flang"},
5554
# Test everything if ci scripts are changed.
5655
".ci": {

.ci/compute_projects_test.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,11 @@ def test_clang(self):
8383
)
8484
self.assertEqual(
8585
env_variables["projects_to_build"],
86-
"clang;clang-tools-extra;lld;llvm",
86+
"clang;clang-tools-extra;lld;lldb;llvm",
8787
)
8888
self.assertEqual(
8989
env_variables["project_check_targets"],
90-
"check-clang check-clang-tools",
90+
"check-clang check-clang-tools check-lldb",
9191
)
9292
self.assertEqual(
9393
env_variables["runtimes_to_build"], "compiler-rt;libcxx;libcxxabi;libunwind"
@@ -158,11 +158,11 @@ def test_cir(self):
158158
)
159159
self.assertEqual(
160160
env_variables["projects_to_build"],
161-
"clang;clang-tools-extra;lld;llvm;mlir",
161+
"clang;clang-tools-extra;lld;lldb;llvm;mlir",
162162
)
163163
self.assertEqual(
164164
env_variables["project_check_targets"],
165-
"check-clang check-clang-cir check-clang-tools",
165+
"check-clang check-clang-cir check-clang-tools check-lldb",
166166
)
167167
self.assertEqual(
168168
env_variables["runtimes_to_build"], "compiler-rt;libcxx;libcxxabi;libunwind"

.ci/monolithic-linux.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ cmake -S "${MONOREPO_ROOT}"/llvm -B "${BUILD_DIR}" \
6060
-D MLIR_ENABLE_BINDINGS_PYTHON=ON \
6161
-D LLDB_ENABLE_PYTHON=ON \
6262
-D LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS=ON \
63-
-D CMAKE_INSTALL_PREFIX="${INSTALL_DIR}"
63+
-D CMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \
64+
-D CMAKE_EXE_LINKER_FLAGS="-no-pie"
6465

6566
start-group "ninja"
6667

.github/workflows/pr-code-format.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,6 @@ jobs:
7070
- name: Run code formatter
7171
env:
7272
GITHUB_PR_NUMBER: ${{ github.event.pull_request.number }}
73-
START_REV: ${{ github.event.pull_request.base.sha }}
74-
END_REV: ${{ github.event.pull_request.head.sha }}
7573
CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
7674
# Create an empty comments file so the pr-write job doesn't fail.
7775
run: |

.github/workflows/premerge.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,11 @@ jobs:
6969
7070
./.ci/monolithic-linux.sh "${projects_to_build}" "${project_check_targets}" "${runtimes_to_build}" "${runtimes_check_targets}" "${runtimes_check_targets_needs_reconfig}" "${enable_cir}"
7171
- name: Upload Artifacts
72+
# In some cases, Github will fail to upload the artifact. We want to
73+
# continue anyways as a failed artifact upload is an infra failure, not
74+
# a checks failure.
75+
# https://github.com/actions/upload-artifact/issues/569
76+
continue-on-error: true
7277
if: '!cancelled()'
7378
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
7479
with:
@@ -114,6 +119,11 @@ jobs:
114119
# these environment variables.
115120
bash -c "export SCCACHE_GCS_BUCKET=$CACHE_GCS_BUCKET; export SCCACHE_GCS_RW_MODE=READ_WRITE; export SCCACHE_IDLE_TIMEOUT=0; sccache --start-server; .ci/monolithic-windows.sh \"${{ steps.vars.outputs.windows-projects }}\" \"${{ steps.vars.outputs.windows-check-targets }}\""
116121
- name: Upload Artifacts
122+
# In some cases, Github will fail to upload the artifact. We want to
123+
# continue anyways as a failed artifact upload is an infra failure, not
124+
# a checks failure.
125+
# https://github.com/actions/upload-artifact/issues/569
126+
continue-on-error: true
117127
if: '!cancelled()'
118128
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
119129
with:

bolt/docs/CommandLineArgumentReference.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,12 @@
138138
Dump function CFGs to graphviz format after each stage;enable '-print-loops'
139139
for color-coded blocks
140140

141+
- `--dump-dot-func=<func1,func2,func3...>`
142+
143+
Dump function CFGs to graphviz format for specified functions only;
144+
takes function name patterns (regex supported). Note: C++ function names
145+
must be passed using their mangled names
146+
141147
- `--dump-linux-exceptions`
142148

143149
Dump Linux kernel exception table

bolt/include/bolt/Core/BinaryFunction.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1196,11 +1196,6 @@ class BinaryFunction {
11961196
return getSecondaryEntryPointSymbol(BB.getLabel());
11971197
}
11981198

1199-
/// Remove a label from the secondary entry point map.
1200-
void removeSymbolFromSecondaryEntryPointMap(const MCSymbol *Label) {
1201-
SecondaryEntryPoints.erase(Label);
1202-
}
1203-
12041199
/// Return true if the basic block is an entry point into the function
12051200
/// (either primary or secondary).
12061201
bool isEntryPoint(const BinaryBasicBlock &BB) const {

bolt/include/bolt/Rewrite/RewriteInstance.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ class RewriteInstance {
241241

242242
/// Adjust function sizes and set proper maximum size values after the whole
243243
/// symbol table has been processed.
244-
void adjustFunctionBoundaries();
244+
void adjustFunctionBoundaries(DenseMap<uint64_t, MarkerSymType> &MarkerSyms);
245245

246246
/// Make .eh_frame section relocatable.
247247
void relocateEHFrameSection();

bolt/include/bolt/Utils/CommandLineOpts.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@
1515

1616
#include "llvm/Support/CommandLine.h"
1717

18+
namespace llvm {
19+
namespace bolt {
20+
class BinaryFunction;
21+
}
22+
} // namespace llvm
23+
1824
namespace opts {
1925

2026
enum HeatmapModeKind {
@@ -100,6 +106,9 @@ extern llvm::cl::opt<unsigned> Verbosity;
100106
/// Return true if we should process all functions in the binary.
101107
bool processAllFunctions();
102108

109+
/// Return true if we should dump dot graphs for the given function.
110+
bool shouldDumpDot(const llvm::bolt::BinaryFunction &Function);
111+
103112
enum GadgetScannerKind { GS_PACRET, GS_PAUTH, GS_ALL };
104113

105114
extern llvm::cl::bits<GadgetScannerKind> GadgetScannersToRun;

bolt/lib/Core/BinaryFunction.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1915,13 +1915,9 @@ void BinaryFunction::postProcessEntryPoints() {
19151915
continue;
19161916

19171917
// If we have grabbed a wrong code label which actually points to some
1918-
// constant island inside the function, ignore this label and remove it
1919-
// from the secondary entry point map.
1920-
if (isStartOfConstantIsland(Offset)) {
1921-
BC.SymbolToFunctionMap.erase(Label);
1922-
removeSymbolFromSecondaryEntryPointMap(Label);
1918+
// constant island inside the function, ignore this label.
1919+
if (isStartOfConstantIsland(Offset))
19231920
continue;
1924-
}
19251921

19261922
BC.errs() << "BOLT-WARNING: reference in the middle of instruction "
19271923
"detected in function "

0 commit comments

Comments
 (0)