Skip to content

Commit c44e578

Browse files
authored
merge main into amd-staging (#545)
2 parents 0c4c05e + 0fadc21 commit c44e578

File tree

61 files changed

+9014
-257
lines changed

Some content is hidden

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

61 files changed

+9014
-257
lines changed

.github/workflows/build-ci-container-windows.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
- build-ci-container-windows
5757
permissions:
5858
packages: write
59-
runs-on: windows-2022
59+
runs-on: ubuntu-24.04
6060
env:
6161
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6262
steps:
@@ -66,8 +66,12 @@ jobs:
6666
name: container
6767
- name: Push Container
6868
run: |
69-
docker load -i ${{ needs.build-ci-container-windows.outputs.container-filename }}
70-
docker tag ${{ needs.build-ci-container-windows.outputs.container-name-tag }} ${{ needs.build-ci-container-windows.outputs.container-name }}:latest
71-
docker login -u ${{ github.actor }} -p $env:GITHUB_TOKEN ghcr.io
72-
docker push ${{ needs.build-ci-container-windows.outputs.container-name-tag }}
73-
docker push ${{ needs.build-ci-container-windows.outputs.container-name }}:latest
69+
sudo apt-get update
70+
sudo apt-get install -y skopeo
71+
skopeo login -u ${{ github.actor }} -p ${{ secrets.GITHUB_TOKEN }} ghcr.io
72+
skopeo copy docker-archive:${{ needs.build-ci-container-windows.outputs.container-filename }} \
73+
--dest-compress-format zstd \
74+
docker://${{ needs.build-ci-container-windows.outputs.container-name-tag }}
75+
skopeo copy docker-archive:${{ needs.build-ci-container-windows.outputs.container-filename }} \
76+
--dest-compress-format zstd \
77+
docker://${{ needs.build-ci-container-windows.outputs.container-name }}:latest

clang-tools-extra/clang-tidy/.clang-tidy

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ Checks: >
1515
performance-*,
1616
-performance-enum-size,
1717
-performance-no-int-to-ptr,
18-
-performance-unnecessary-value-param,
1918
readability-*,
2019
-readability-avoid-nested-conditional-operator,
2120
-readability-braces-around-statements,

clang-tools-extra/clang-tidy/ClangTidy.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -455,8 +455,8 @@ ClangTidyASTConsumerFactory::createASTConsumer(
455455

456456
if (Context.canEnableModuleHeadersParsing() &&
457457
Context.getLangOpts().Modules && OverlayFS != nullptr) {
458-
auto ModuleExpander =
459-
std::make_unique<ExpandModularHeadersPPCallbacks>(&Compiler, OverlayFS);
458+
auto ModuleExpander = std::make_unique<ExpandModularHeadersPPCallbacks>(
459+
&Compiler, *OverlayFS);
460460
ModuleExpanderPP = ModuleExpander->getPreprocessor();
461461
PP->addPPCallbacks(std::move(ModuleExpander));
462462
}

clang-tools-extra/clang-tidy/ExpandModularHeadersPPCallbacks.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,7 @@ class ExpandModularHeadersPPCallbacks::FileRecorder {
6565
};
6666

6767
ExpandModularHeadersPPCallbacks::ExpandModularHeadersPPCallbacks(
68-
CompilerInstance *CI,
69-
IntrusiveRefCntPtr<llvm::vfs::OverlayFileSystem> OverlayFS)
68+
CompilerInstance *CI, llvm::vfs::OverlayFileSystem &OverlayFS)
7069
: Recorder(std::make_unique<FileRecorder>()), Compiler(*CI),
7170
InMemoryFs(new llvm::vfs::InMemoryFileSystem),
7271
Sources(Compiler.getSourceManager()),
@@ -76,7 +75,7 @@ ExpandModularHeadersPPCallbacks::ExpandModularHeadersPPCallbacks(
7675
LangOpts(Compiler.getLangOpts()), HSOpts(Compiler.getHeaderSearchOpts()) {
7776
// Add a FileSystem containing the extra files needed in place of modular
7877
// headers.
79-
OverlayFS->pushOverlay(InMemoryFs);
78+
OverlayFS.pushOverlay(InMemoryFs);
8079

8180
Diags.setSourceManager(&Sources);
8281
// FIXME: Investigate whatever is there better way to initialize DiagEngine

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

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,8 @@ namespace tooling {
4141
/// non-modular way.
4242
class ExpandModularHeadersPPCallbacks : public PPCallbacks {
4343
public:
44-
ExpandModularHeadersPPCallbacks(
45-
CompilerInstance *CI,
46-
IntrusiveRefCntPtr<llvm::vfs::OverlayFileSystem> OverlayFS);
44+
ExpandModularHeadersPPCallbacks(CompilerInstance *CI,
45+
llvm::vfs::OverlayFileSystem &OverlayFS);
4746
~ExpandModularHeadersPPCallbacks() override;
4847

4948
/// Returns the preprocessor that provides callbacks for the whole

clang-tools-extra/clang-tidy/android/CloexecCheck.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ static std::string buildFixMsgForStringFlag(const Expr *Arg,
3636
}
3737

3838
void CloexecCheck::registerMatchersImpl(
39-
MatchFinder *Finder, internal::Matcher<FunctionDecl> Function) {
39+
MatchFinder *Finder, const internal::Matcher<FunctionDecl> &Function) {
4040
// We assume all the checked APIs are C functions.
4141
Finder->addMatcher(
4242
callExpr(

clang-tools-extra/clang-tidy/android/CloexecCheck.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ class CloexecCheck : public ClangTidyCheck {
2929
: ClangTidyCheck(Name, Context) {}
3030

3131
protected:
32-
void
33-
registerMatchersImpl(ast_matchers::MatchFinder *Finder,
34-
ast_matchers::internal::Matcher<FunctionDecl> Function);
32+
void registerMatchersImpl(
33+
ast_matchers::MatchFinder *Finder,
34+
const ast_matchers::internal::Matcher<FunctionDecl> &Function);
3535

3636
/// Currently, we have three types of fixes.
3737
///

clang-tools-extra/clang-tidy/boost/UseRangesCheck.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
#include <initializer_list>
1919
#include <optional>
2020
#include <string>
21+
#include <utility>
2122

2223
// FixItHint - Let the docs script know that this class does provide fixits
2324

@@ -217,11 +218,11 @@ utils::UseRangesCheck::ReplacerMap UseRangesCheck::getReplacerMap() const {
217218
const auto AddFromStd =
218219
[&](llvm::IntrusiveRefCntPtr<UseRangesCheck::Replacer> Replacer,
219220
std::initializer_list<StringRef> Names) {
220-
AddFrom(Replacer, Names, "std");
221+
AddFrom(std::move(Replacer), Names, "std");
221222
};
222223

223224
const auto AddFromBoost =
224-
[&](llvm::IntrusiveRefCntPtr<UseRangesCheck::Replacer> Replacer,
225+
[&](const llvm::IntrusiveRefCntPtr<UseRangesCheck::Replacer> &Replacer,
225226
std::initializer_list<
226227
std::pair<StringRef, std::initializer_list<StringRef>>>
227228
NamespaceAndNames) {

clang-tools-extra/clang-tidy/bugprone/RawMemoryCallOnNonTrivialTypeCheck.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,8 @@ void RawMemoryCallOnNonTrivialTypeCheck::storeOptions(
6464

6565
void RawMemoryCallOnNonTrivialTypeCheck::registerMatchers(MatchFinder *Finder) {
6666
using namespace ast_matchers::internal;
67-
auto IsStructPointer = [](Matcher<CXXRecordDecl> Constraint = anything(),
67+
auto IsStructPointer = [](const Matcher<CXXRecordDecl> &Constraint =
68+
anything(),
6869
bool Bind = false) {
6970
return expr(unaryOperator(
7071
hasOperatorName("&"),
@@ -74,8 +75,8 @@ void RawMemoryCallOnNonTrivialTypeCheck::registerMatchers(MatchFinder *Finder) {
7475
};
7576
auto IsRecordSizeOf =
7677
expr(sizeOfExpr(hasArgumentOfType(equalsBoundNode("Record"))));
77-
auto ArgChecker = [&](Matcher<CXXRecordDecl> RecordConstraint,
78-
BindableMatcher<Stmt> SecondArg = expr()) {
78+
auto ArgChecker = [&](const Matcher<CXXRecordDecl> &RecordConstraint,
79+
const BindableMatcher<Stmt> &SecondArg = expr()) {
7980
return allOf(argumentCountIs(3),
8081
hasArgument(0, IsStructPointer(RecordConstraint, true)),
8182
hasArgument(1, SecondArg), hasArgument(2, IsRecordSizeOf));

clang-tools-extra/clang-tidy/bugprone/SignalHandlerCheck.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ void SignalHandlerCheck::check(const MatchFinder::MatchResult &Result) {
435435

436436
bool SignalHandlerCheck::checkFunction(
437437
const FunctionDecl *FD, const Expr *CallOrRef,
438-
std::function<void(bool)> ChainReporter) {
438+
llvm::function_ref<void(bool)> ChainReporter) {
439439
const bool FunctionIsCalled = isa<CallExpr>(CallOrRef);
440440

441441
if (isStandardFunction(FD)) {
@@ -471,7 +471,7 @@ bool SignalHandlerCheck::checkFunction(
471471

472472
bool SignalHandlerCheck::checkFunctionCPP14(
473473
const FunctionDecl *FD, const Expr *CallOrRef,
474-
std::function<void(bool)> ChainReporter) {
474+
llvm::function_ref<void(bool)> ChainReporter) {
475475
if (!FD->isExternC()) {
476476
diag(CallOrRef->getBeginLoc(),
477477
"functions without C linkage are not allowed as signal "

0 commit comments

Comments
 (0)