Skip to content

Commit 79ca702

Browse files
authored
Merge branch 'main' into seg-generate
2 parents 13f7843 + 1e1ff21 commit 79ca702

File tree

595 files changed

+16551
-5836
lines changed

Some content is hidden

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

595 files changed

+16551
-5836
lines changed

.ci/monolithic-linux.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,13 @@ start-group "ninja"
6666

6767
# Targets are not escaped as they are passed as separate arguments.
6868
ninja -C "${BUILD_DIR}" -k 0 ${targets} |& tee ninja.log
69+
cp ${BUILD_DIR}/.ninja_log ninja.ninja_log
6970

7071
if [[ "${runtime_targets}" != "" ]]; then
7172
start-group "ninja Runtimes"
7273

7374
ninja -C "${BUILD_DIR}" ${runtime_targets} |& tee ninja_runtimes.log
75+
cp ${BUILD_DIR}/.ninja_log ninja_runtimes.ninja_log
7476
fi
7577

7678
# Compiling runtimes with just-built Clang and running their tests
@@ -87,6 +89,7 @@ if [[ "${runtime_targets_needs_reconfig}" != "" ]]; then
8789

8890
ninja -C "${BUILD_DIR}" ${runtime_targets_needs_reconfig} \
8991
|& tee ninja_runtimes_needs_reconfig1.log
92+
cp ${BUILD_DIR}/.ninja_log ninja_runtimes_needs_reconig.ninja_log
9093

9194
start-group "CMake Runtimes Clang Modules"
9295

@@ -99,4 +102,5 @@ if [[ "${runtime_targets_needs_reconfig}" != "" ]]; then
99102

100103
ninja -C "${BUILD_DIR}" ${runtime_targets_needs_reconfig} \
101104
|& tee ninja_runtimes_needs_reconfig2.log
105+
cp ${BUILD_DIR}/.ninja_log ninja_runtimes_needs_reconfig2.ninja_log
102106
fi

.ci/monolithic-windows.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,11 @@ start-group "ninja"
5555

5656
# Targets are not escaped as they are passed as separate arguments.
5757
ninja -C "${BUILD_DIR}" -k 0 ${targets} |& tee ninja.log
58+
cp ${BUILD_DIR}/.ninja_log ninja.ninja_log
5859

5960
if [[ "${runtime_targets}" != "" ]]; then
6061
start-group "ninja runtimes"
6162

6263
ninja -C "${BUILD_DIR}" -k 0 ${runtimes_targets} |& tee ninja_runtimes.log
64+
cp ${BUILD_DIR}/.ninja_log ninja_runtimes.ninja_log
6365
fi

.ci/premerge_advisor_upload.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,20 @@ def main(commit_sha, workflow_run_number, build_log_files):
2323
)
2424
test_failures = generate_test_report_lib.get_failures(junit_objects)
2525
source = "pull_request" if "GITHUB_ACTIONS" in os.environ else "postcommit"
26+
current_platform = f"{platform.system()}-{platform.machine()}".lower()
2627
failure_info = {
2728
"source_type": source,
2829
"base_commit_sha": commit_sha,
2930
"source_id": workflow_run_number,
3031
"failures": [],
32+
"platform": current_platform,
3133
}
3234
if test_failures:
33-
for name, failure_message in test_failures:
34-
failure_info["failures"].append({"name": name, "message": failure_message})
35+
for _, failures in test_failures.items():
36+
for name, failure_message in failures:
37+
failure_info["failures"].append(
38+
{"name": name, "message": failure_message}
39+
)
3540
else:
3641
ninja_failures = generate_test_report_lib.find_failure_in_ninja_logs(ninja_logs)
3742
for name, failure_message in ninja_failures:

.ci/utils.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function at-exit {
2626
mkdir -p artifacts
2727
sccache --show-stats
2828
sccache --show-stats >> artifacts/sccache_stats.txt
29-
cp "${BUILD_DIR}"/.ninja_log artifacts/.ninja_log
29+
cp "${MONOREPO_ROOT}"/*.ninja_log artifacts/ || :
3030
cp "${MONOREPO_ROOT}"/*.log artifacts/ || :
3131
cp "${BUILD_DIR}"/test-results.*.xml artifacts/ || :
3232

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@
131131
/mlir/test/python/ @ftynse @makslevental @stellaraccident @rolfmorel
132132
/mlir/python/ @ftynse @makslevental @stellaraccident @rolfmorel
133133
/mlir/lib/Bindings/Python @makslevental @rolfmorel
134+
/mlir/include/Bindings/Python @makslevental @rolfmorel
134135

135136
# MLIR Mem2Reg/SROA
136137
/mlir/**/Transforms/Mem2Reg.* @moxinilian

bolt/lib/Core/CallGraph.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
#undef USE_SSECRC
2323
#endif
2424

25-
static LLVM_ATTRIBUTE_UNUSED inline size_t hash_int64_fallback(int64_t k) {
25+
[[maybe_unused]] static inline size_t hash_int64_fallback(int64_t k) {
2626
uint64_t key = (unsigned long long)k;
2727
// "64 bit Mix Functions", from Thomas Wang's "Integer Hash Function."
2828
// http://www.concentric.net/~ttwang/tech/inthash.htm
@@ -35,7 +35,7 @@ static LLVM_ATTRIBUTE_UNUSED inline size_t hash_int64_fallback(int64_t k) {
3535
return static_cast<size_t>(static_cast<uint32_t>(key));
3636
}
3737

38-
static LLVM_ATTRIBUTE_UNUSED inline size_t hash_int64(int64_t k) {
38+
[[maybe_unused]] static inline size_t hash_int64(int64_t k) {
3939
#if defined(USE_SSECRC) && defined(__SSE4_2__)
4040
size_t h = 0;
4141
__asm("crc32q %1, %0\n" : "+r"(h) : "rm"(k));

bolt/lib/Core/DebugData.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ std::optional<AttrInfo> findAttributeInfo(const DWARFDie DIE,
101101
return findAttributeInfo(DIE, AbbrevDecl, *Index);
102102
}
103103

104-
LLVM_ATTRIBUTE_UNUSED
104+
[[maybe_unused]]
105105
static void printLE64(const std::string &S) {
106106
for (uint32_t I = 0, Size = S.size(); I < Size; ++I) {
107107
errs() << Twine::utohexstr(S[I]);

bolt/lib/Rewrite/DWARFRewriter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ static void printDie(const DWARFDie &DIE) {
6969
}
7070

7171
/// Lazily parse DWARF DIE and print it out.
72-
LLVM_ATTRIBUTE_UNUSED
72+
[[maybe_unused]]
7373
static void printDie(DWARFUnit &DU, uint64_t DIEOffset) {
7474
uint64_t OriginalOffsets = DIEOffset;
7575
uint64_t NextCUOffset = DU.getNextUnitOffset();

clang-tools-extra/clang-doc/Generators.cpp

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -97,15 +97,11 @@ void Generator::addInfoToIndex(Index &Idx, const doc::Info *Info) {
9797

9898
// This anchor is used to force the linker to link in the generated object file
9999
// and thus register the generators.
100-
static int LLVM_ATTRIBUTE_UNUSED YAMLGeneratorAnchorDest =
101-
YAMLGeneratorAnchorSource;
102-
static int LLVM_ATTRIBUTE_UNUSED MDGeneratorAnchorDest =
103-
MDGeneratorAnchorSource;
104-
static int LLVM_ATTRIBUTE_UNUSED HTMLGeneratorAnchorDest =
105-
HTMLGeneratorAnchorSource;
106-
static int LLVM_ATTRIBUTE_UNUSED MHTMLGeneratorAnchorDest =
100+
[[maybe_unused]] static int YAMLGeneratorAnchorDest = YAMLGeneratorAnchorSource;
101+
[[maybe_unused]] static int MDGeneratorAnchorDest = MDGeneratorAnchorSource;
102+
[[maybe_unused]] static int HTMLGeneratorAnchorDest = HTMLGeneratorAnchorSource;
103+
[[maybe_unused]] static int MHTMLGeneratorAnchorDest =
107104
MHTMLGeneratorAnchorSource;
108-
static int LLVM_ATTRIBUTE_UNUSED JSONGeneratorAnchorDest =
109-
JSONGeneratorAnchorSource;
105+
[[maybe_unused]] static int JSONGeneratorAnchorDest = JSONGeneratorAnchorSource;
110106
} // namespace doc
111107
} // namespace clang

clang-tools-extra/clang-tidy/ClangTidyForceLinker.h

Lines changed: 25 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -16,132 +16,131 @@ namespace clang::tidy {
1616

1717
// This anchor is used to force the linker to link the AbseilModule.
1818
extern volatile int AbseilModuleAnchorSource;
19-
static int LLVM_ATTRIBUTE_UNUSED AbseilModuleAnchorDestination =
19+
[[maybe_unused]] static int AbseilModuleAnchorDestination =
2020
AbseilModuleAnchorSource;
2121

2222
// This anchor is used to force the linker to link the AlteraModule.
2323
extern volatile int AlteraModuleAnchorSource;
24-
static int LLVM_ATTRIBUTE_UNUSED AlteraModuleAnchorDestination =
24+
[[maybe_unused]] static int AlteraModuleAnchorDestination =
2525
AlteraModuleAnchorSource;
2626

2727
// This anchor is used to force the linker to link the AndroidModule.
2828
extern volatile int AndroidModuleAnchorSource;
29-
static int LLVM_ATTRIBUTE_UNUSED AndroidModuleAnchorDestination =
29+
[[maybe_unused]] static int AndroidModuleAnchorDestination =
3030
AndroidModuleAnchorSource;
3131

3232
// This anchor is used to force the linker to link the BoostModule.
3333
extern volatile int BoostModuleAnchorSource;
34-
static int LLVM_ATTRIBUTE_UNUSED BoostModuleAnchorDestination =
34+
[[maybe_unused]] static int BoostModuleAnchorDestination =
3535
BoostModuleAnchorSource;
3636

3737
// This anchor is used to force the linker to link the BugproneModule.
3838
extern volatile int BugproneModuleAnchorSource;
39-
static int LLVM_ATTRIBUTE_UNUSED BugproneModuleAnchorDestination =
39+
[[maybe_unused]] static int BugproneModuleAnchorDestination =
4040
BugproneModuleAnchorSource;
4141

4242
// This anchor is used to force the linker to link the CERTModule.
4343
extern volatile int CERTModuleAnchorSource;
44-
static int LLVM_ATTRIBUTE_UNUSED CERTModuleAnchorDestination =
44+
[[maybe_unused]] static int CERTModuleAnchorDestination =
4545
CERTModuleAnchorSource;
4646

4747
// This anchor is used to force the linker to link the ConcurrencyModule.
4848
extern volatile int ConcurrencyModuleAnchorSource;
49-
static int LLVM_ATTRIBUTE_UNUSED ConcurrencyModuleAnchorDestination =
49+
[[maybe_unused]] static int ConcurrencyModuleAnchorDestination =
5050
ConcurrencyModuleAnchorSource;
5151

5252
// This anchor is used to force the linker to link the CppCoreGuidelinesModule.
5353
extern volatile int CppCoreGuidelinesModuleAnchorSource;
54-
static int LLVM_ATTRIBUTE_UNUSED CppCoreGuidelinesModuleAnchorDestination =
54+
[[maybe_unused]] static int CppCoreGuidelinesModuleAnchorDestination =
5555
CppCoreGuidelinesModuleAnchorSource;
5656

5757
#if CLANG_TIDY_ENABLE_QUERY_BASED_CUSTOM_CHECKS
5858
// This anchor is used to force the linker to link the CustomModule.
5959
extern volatile int CustomModuleAnchorSource;
60-
static int LLVM_ATTRIBUTE_UNUSED CustomModuleAnchorDestination =
60+
[[maybe_unused]] static int CustomModuleAnchorDestination =
6161
CustomModuleAnchorSource;
6262
#endif
6363

6464
// This anchor is used to force the linker to link the DarwinModule.
6565
extern volatile int DarwinModuleAnchorSource;
66-
static int LLVM_ATTRIBUTE_UNUSED DarwinModuleAnchorDestination =
66+
[[maybe_unused]] static int DarwinModuleAnchorDestination =
6767
DarwinModuleAnchorSource;
6868

6969
// This anchor is used to force the linker to link the FuchsiaModule.
7070
extern volatile int FuchsiaModuleAnchorSource;
71-
static int LLVM_ATTRIBUTE_UNUSED FuchsiaModuleAnchorDestination =
71+
[[maybe_unused]] static int FuchsiaModuleAnchorDestination =
7272
FuchsiaModuleAnchorSource;
7373

7474
// This anchor is used to force the linker to link the GoogleModule.
7575
extern volatile int GoogleModuleAnchorSource;
76-
static int LLVM_ATTRIBUTE_UNUSED GoogleModuleAnchorDestination =
76+
[[maybe_unused]] static int GoogleModuleAnchorDestination =
7777
GoogleModuleAnchorSource;
7878

7979
// This anchor is used to force the linker to link the HICPPModule.
8080
extern volatile int HICPPModuleAnchorSource;
81-
static int LLVM_ATTRIBUTE_UNUSED HICPPModuleAnchorDestination =
81+
[[maybe_unused]] static int HICPPModuleAnchorDestination =
8282
HICPPModuleAnchorSource;
8383

8484
// This anchor is used to force the linker to link the LinuxKernelModule.
8585
extern volatile int LinuxKernelModuleAnchorSource;
86-
static int LLVM_ATTRIBUTE_UNUSED LinuxKernelModuleAnchorDestination =
86+
[[maybe_unused]] static int LinuxKernelModuleAnchorDestination =
8787
LinuxKernelModuleAnchorSource;
8888

8989
// This anchor is used to force the linker to link the LLVMModule.
9090
extern volatile int LLVMModuleAnchorSource;
91-
static int LLVM_ATTRIBUTE_UNUSED LLVMModuleAnchorDestination =
91+
[[maybe_unused]] static int LLVMModuleAnchorDestination =
9292
LLVMModuleAnchorSource;
9393

9494
// This anchor is used to force the linker to link the LLVMLibcModule.
9595
extern volatile int LLVMLibcModuleAnchorSource;
96-
static int LLVM_ATTRIBUTE_UNUSED LLVMLibcModuleAnchorDestination =
96+
[[maybe_unused]] static int LLVMLibcModuleAnchorDestination =
9797
LLVMLibcModuleAnchorSource;
9898

9999
// This anchor is used to force the linker to link the MiscModule.
100100
extern volatile int MiscModuleAnchorSource;
101-
static int LLVM_ATTRIBUTE_UNUSED MiscModuleAnchorDestination =
101+
[[maybe_unused]] static int MiscModuleAnchorDestination =
102102
MiscModuleAnchorSource;
103103

104104
// This anchor is used to force the linker to link the ModernizeModule.
105105
extern volatile int ModernizeModuleAnchorSource;
106-
static int LLVM_ATTRIBUTE_UNUSED ModernizeModuleAnchorDestination =
106+
[[maybe_unused]] static int ModernizeModuleAnchorDestination =
107107
ModernizeModuleAnchorSource;
108108

109109
#if CLANG_TIDY_ENABLE_STATIC_ANALYZER && \
110110
!defined(CLANG_TIDY_DISABLE_STATIC_ANALYZER_CHECKS)
111111
// This anchor is used to force the linker to link the MPIModule.
112112
extern volatile int MPIModuleAnchorSource;
113-
static int LLVM_ATTRIBUTE_UNUSED MPIModuleAnchorDestination =
114-
MPIModuleAnchorSource;
113+
[[maybe_unused]] static int MPIModuleAnchorDestination = MPIModuleAnchorSource;
115114
#endif
116115

117116
// This anchor is used to force the linker to link the ObjCModule.
118117
extern volatile int ObjCModuleAnchorSource;
119-
static int LLVM_ATTRIBUTE_UNUSED ObjCModuleAnchorDestination =
118+
[[maybe_unused]] static int ObjCModuleAnchorDestination =
120119
ObjCModuleAnchorSource;
121120

122121
// This anchor is used to force the linker to link the OpenMPModule.
123122
extern volatile int OpenMPModuleAnchorSource;
124-
static int LLVM_ATTRIBUTE_UNUSED OpenMPModuleAnchorDestination =
123+
[[maybe_unused]] static int OpenMPModuleAnchorDestination =
125124
OpenMPModuleAnchorSource;
126125

127126
// This anchor is used to force the linker to link the PerformanceModule.
128127
extern volatile int PerformanceModuleAnchorSource;
129-
static int LLVM_ATTRIBUTE_UNUSED PerformanceModuleAnchorDestination =
128+
[[maybe_unused]] static int PerformanceModuleAnchorDestination =
130129
PerformanceModuleAnchorSource;
131130

132131
// This anchor is used to force the linker to link the PortabilityModule.
133132
extern volatile int PortabilityModuleAnchorSource;
134-
static int LLVM_ATTRIBUTE_UNUSED PortabilityModuleAnchorDestination =
133+
[[maybe_unused]] static int PortabilityModuleAnchorDestination =
135134
PortabilityModuleAnchorSource;
136135

137136
// This anchor is used to force the linker to link the ReadabilityModule.
138137
extern volatile int ReadabilityModuleAnchorSource;
139-
static int LLVM_ATTRIBUTE_UNUSED ReadabilityModuleAnchorDestination =
138+
[[maybe_unused]] static int ReadabilityModuleAnchorDestination =
140139
ReadabilityModuleAnchorSource;
141140

142141
// This anchor is used to force the linker to link the ZirconModule.
143142
extern volatile int ZirconModuleAnchorSource;
144-
static int LLVM_ATTRIBUTE_UNUSED ZirconModuleAnchorDestination =
143+
[[maybe_unused]] static int ZirconModuleAnchorDestination =
145144
ZirconModuleAnchorSource;
146145

147146
} // namespace clang::tidy

0 commit comments

Comments
 (0)