FailedChanges

Summary

  1. [clang] Add a new nullability annotation for swift async: _Nullable_result (details)
  2. [clang] Add support for attribute 'swift_async' (details)
  3. Revert "[test] Fix asan/TestCases/Linux/globals-gc-sections-lld.cpp with -fsanitize-address-globals-dead-stripping" (details)
  4. [clang] Fix noderef for array member of deref expr (details)
  5. [flang] Improve initializer semantics, esp. for component default values (details)
  6. [clang] Fix noderef for AddrOf on MemberExpr (details)
  7. Teach isKnownNonEqual how to recurse through invertible multiplies (details)
  8. [AArch64][GlobalISel] Narrow 128-bit regs to 64-bit regs in emitTestBit (details)
  9. [clang][AMDGPU] rename sram-ecc as sramecc (details)
  10. Customize exception thrown from mlir.Operation.create() python bindings (details)
  11. Add Python binding for MLIR Type Attribute (details)
Commit 9cd2413f1ca7a7f40132ea3c44f251851aa325c2 by erik.pilkington
[clang] Add a new nullability annotation for swift async: _Nullable_result

_Nullable_result generally like _Nullable, except when being imported into a
swift async method. rdar://70106409

Differential revision: https://reviews.llvm.org/D92495
The file was modifiedclang/include/clang/Basic/Features.def
The file was modifiedclang/include/clang/Basic/Specifiers.h
The file was modifiedclang/lib/Sema/SemaExpr.cpp
The file was modifiedclang/tools/c-index-test/c-index-test.c
The file was modifiedclang/test/SemaObjC/nullability.m
The file was modifiedclang/include/clang/Basic/Attr.td
The file was modifiedclang/include/clang/Basic/AttrDocs.td
The file was modifiedclang/lib/Basic/IdentifierTable.cpp
The file was modifiedclang/include/clang/Basic/TokenKinds.def
The file was modifiedclang/include/clang/AST/Type.h
The file was modifiedclang/lib/Sema/SemaCodeComplete.cpp
The file was modifiedclang/lib/Parse/ParseTentative.cpp
The file was modifiedclang/lib/Sema/Sema.cpp
The file was modifiedclang/lib/Basic/Diagnostic.cpp
The file was modifiedclang/lib/Sema/SemaExprObjC.cpp
The file was modifiedclang/tools/libclang/CXType.cpp
The file was modifiedclang/include/clang-c/Index.h
The file was modifiedclang/include/clang/Sema/Sema.h
The file was modifiedclang/lib/AST/Type.cpp
The file was modifiedclang/lib/Parse/ParseDecl.cpp
The file was modifiedclang/lib/Sema/SemaType.cpp
The file was addedclang/test/SemaObjC/nullable-result.m
The file was modifiedclang/lib/APINotes/APINotesYAMLCompiler.cpp
The file was modifiedclang/lib/AST/TypePrinter.cpp
The file was modifiedclang/test/Index/nullability.c
Commit 5a28e1d9e50eb0b866351b5ab3213678fd28374b by erik.pilkington
[clang] Add support for attribute 'swift_async'

This attributes specifies how (or if) a given function or method will be
imported into a swift async method. rdar://70111252

Differential revision: https://reviews.llvm.org/D92742
The file was addedclang/test/SemaObjC/attr-swift-async.m
The file was modifiedclang/include/clang/Basic/Attr.td
The file was modifiedclang/include/clang/Basic/DiagnosticSemaKinds.td
The file was modifiedclang/lib/Sema/SemaDeclAttr.cpp
The file was modifiedclang/test/Misc/pragma-attribute-supported-attributes-list.test
The file was modifiedclang/include/clang/Basic/AttrDocs.td
Commit 1d03a54d9460fa122f0be9bf9018b9a4358745a9 by 31459023+hctim
Revert "[test] Fix asan/TestCases/Linux/globals-gc-sections-lld.cpp with -fsanitize-address-globals-dead-stripping"

This reverts commit 140808768d3e5c0f4e52dd42094650f5d282e34a.

Reason: Broke the upstream bots - discussed offline.
The file was modifiedcompiler-rt/test/asan/TestCases/Linux/globals-gc-sections-lld.cpp
Commit 155fca3cae275562e626d3e4fbfac70b4b75d2e7 by leonardchan
    [clang] Fix noderef for array member of deref expr

    Committing on behalf of thejh (Jann Horn).

    Given an attribute((noderef)) pointer "p" to the struct

    struct s { int a[2]; };
    ensure that the following expressions are treated the same way by the
    noderef logic:

    p->a
    (*p).a
    Until now, the first expression would be treated correctly (nothing is
    added to PossibleDerefs because CheckMemberAccessOfNoDeref() bails out
    on array members), but the second expression would incorrectly warn
    because "*p" creates a PossibleDerefs entry.

    Handle this case the same way as for the AddrOf operator.

    Differential Revision: https://reviews.llvm.org/D92140
The file was modifiedclang/test/Frontend/noderef.c
The file was modifiedclang/lib/Sema/SemaExprMember.cpp
Commit 641ede93efd664cc2e1d1788b195a80b50b36f66 by pklausler
[flang] Improve initializer semantics, esp. for component default values

This patch plugs many holes in static initializer semantics, improves error
messages for default initial values and other component properties in
parameterized derived type instantiations, and cleans up several small
issues noticed during development.  We now do proper scalar expansion,
folding, and type, rank, and shape conformance checking for component
default initializers in derived types and PDT instantiations.
The initial values of named constants are now guaranteed to have been folded
when installed in the symbol table, and are no longer folded or
scalar-expanded at each use in expression folding.  Semantics documentation
was extended with information about the various kinds of initializations
in Fortran and when each of them are processed in the compiler.

Some necessary concomitant changes have bulked this patch out a bit:
* contextual messages attachments, which are now produced for parameterized
  derived type instantiations so that the user can figure out which
  instance caused a problem with a component, have been added as part
  of ContextualMessages, and their implementation was debugged
* several APIs in evaluate::characteristics was changed so that a FoldingContext
  is passed as an argument rather than just its intrinsic procedure table;
  this affected client call sites in many files
* new tools in Evaluate/check-expression.cpp to determine when an Expr
  actually is a single constant value and to validate a non-pointer
  variable initializer or object component default value
* shape conformance checking has additional arguments that control
  whether scalar expansion is allowed
* several now-unused functions and data members noticed and removed
* several crashes and bogus errors exposed by testing this new code
  were fixed
* a -fdebug-stack-trace option to enable LLVM's stack tracing on
  a crash, which might be useful in the future

TL;DR: Initialization processing does more and takes place at the right
times for all of the various kinds of things that can be initialized.

Differential Review: https://reviews.llvm.org/D92783
The file was modifiedflang/include/flang/Evaluate/type.h
The file was modifiedflang/lib/Semantics/check-declarations.cpp
The file was modifiedflang/lib/Evaluate/shape.cpp
The file was modifiedflang/lib/Evaluate/characteristics.cpp
The file was modifiedflang/docs/Semantics.md
The file was modifiedflang/test/Semantics/data04.f90
The file was modifiedflang/test/Semantics/resolve69.f90
The file was modifiedflang/lib/Semantics/check-call.cpp
The file was modifiedflang/lib/Semantics/resolve-names.cpp
The file was modifiedflang/include/flang/Parser/message.h
The file was modifiedflang/lib/Evaluate/type.cpp
The file was modifiedflang/lib/Evaluate/fold-logical.cpp
The file was modifiedflang/include/flang/Evaluate/characteristics.h
The file was modifiedflang/lib/Evaluate/check-expression.cpp
The file was modifiedflang/lib/Semantics/pointer-assignment.cpp
The file was modifiedflang/test/Semantics/resolve37.f90
The file was modifiedflang/tools/f18/f18.cpp
The file was modifiedflang/lib/Semantics/data-to-inits.cpp
The file was modifiedflang/lib/Evaluate/fold.cpp
The file was modifiedflang/lib/Parser/message.cpp
The file was modifiedflang/test/Semantics/array-constr-values.f90
The file was modifiedflang/lib/Semantics/expression.cpp
The file was modifiedflang/test/Semantics/structconst02.f90
The file was modifiedflang/lib/Semantics/check-do-forall.cpp
The file was modifiedflang/lib/Evaluate/fold-implementation.h
The file was modifiedflang/include/flang/Evaluate/tools.h
The file was modifiedflang/include/flang/Semantics/tools.h
The file was modifiedflang/include/flang/Evaluate/shape.h
The file was modifiedflang/lib/Parser/parse-tree.cpp
The file was modifiedflang/test/Semantics/init01.f90
The file was modifiedflang/lib/Semantics/tools.cpp
The file was modifiedflang/lib/Semantics/type.cpp
The file was modifiedflang/test/Semantics/resolve44.f90
The file was modifiedflang/lib/Semantics/check-declarations.h
The file was modifiedflang/include/flang/Common/reference-counted.h
The file was modifiedflang/include/flang/Evaluate/check-expression.h
The file was modifiedflang/include/flang/Semantics/scope.h
The file was modifiedflang/lib/Evaluate/intrinsics.cpp
The file was modifiedflang/include/flang/Evaluate/common.h
The file was modifiedflang/include/flang/Semantics/symbol.h
The file was modifiedflang/lib/Evaluate/tools.cpp
The file was modifiedflang/test/Semantics/resolve58.f90
Commit 6dad7ec539cbcf6f59b63753a86b8015bd6ea66f by leonardchan
[clang] Fix noderef for AddrOf on MemberExpr

Committing on behalf of thejh (Jann Horn).

As part of this change, one existing test case has to be adjusted
because it accidentally stripped the NoDeref attribute without
getting caught.

Depends on D92140

Differential Review: https://reviews.llvm.org/D92141
The file was modifiedclang/lib/Sema/SemaExprMember.cpp
The file was modifiedclang/test/Frontend/noderef.c
Commit 2656885390f17cceae142b4265c337fcee2410c0 by listmail
Teach isKnownNonEqual how to recurse through invertible multiplies

Build on the work started in 8f07629, and add the multiply case. In the process, more clearly describe the requirement for the operation we're looking through.

Differential Revision: https://reviews.llvm.org/D92726
The file was modifiedllvm/test/Analysis/ValueTracking/known-non-equal.ll
The file was modifiedllvm/lib/Analysis/ValueTracking.cpp
Commit 195a7af0abb26915f962462f69c0f17e3835f78b by Jessica Paquette
[AArch64][GlobalISel] Narrow 128-bit regs to 64-bit regs in emitTestBit

When we have a 128-bit register, emitTestBit would incorrectly narrow to 32
bits always. If the bit number was > 32, then we would need a TB(N)ZX. This
would cause a crash, as we'd have the wrong register class. (PR48379)

This generalizes `narrowExtReg` into `moveScalarRegClass`.

This also allows us to remove `widenGPRBankRegIfNeeded` entirely, since
`selectCopy` correctly handles SUBREG_TO_REG etc.

This does create some codegen changes (since `selectCopy` uses the `all`
regclass variants). However, I think that these will likely be optimized away,
and we can always improve the `selectCopy` code. It looks like we should
revisit `selectCopy` at this point, and possibly refactor it into at least one
`emit` function.

Differential Revision: https://reviews.llvm.org/D92707
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/opt-fold-ext-tbz-tbnz.mir
The file was modifiedllvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/widen-narrow-tbz-tbnz.mir
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/subreg-copy.mir
Commit 40ad476a32445ec98666adcf24d2b33fd887ccc6 by Yaxun.Liu
[clang][AMDGPU] rename sram-ecc as sramecc

As backend renamed sram-ecc to sramecc, this patch makes
corresponding change in clang.

Differential Revision: https://reviews.llvm.org/D86217
The file was modifiedclang/test/Driver/hip-target-id.hip
The file was modifiedllvm/include/llvm/Support/TargetParser.h
The file was modifiedclang/include/clang/Basic/DiagnosticDriverKinds.td
The file was modifiedclang/test/Driver/amdgpu-features.c
The file was modifiedclang/test/Driver/hip-invalid-target-id.hip
The file was modifiedclang/test/Driver/target-id-macros.hip
The file was modifiedclang/include/clang/Basic/TargetID.h
The file was modifiedclang/test/Driver/invalid-target-id.cl
The file was modifiedclang/test/Driver/hip-toolchain-features.hip
The file was modifiedclang/include/clang/Driver/Options.td
The file was modifiedllvm/lib/Support/TargetParser.cpp
The file was modifiedclang/lib/Basic/Targets/AMDGPU.h
The file was modifiedclang/lib/Basic/TargetID.cpp
The file was modifiedclang/test/Driver/target-id-macros.cl
The file was modifiedclang/test/Driver/target-id.cl
Commit e15ae454b4b4632d4f40a9d95a5c7e4de95990cc by joker.eph
Customize exception thrown from mlir.Operation.create() python bindings

The default exception handling isn't very user friendly and does not
point accurately to the issue. Instead we can indicate which of the
operands isn't valid and provide contextual information in the error
message.

Differential Revision: https://reviews.llvm.org/D92710
The file was modifiedmlir/test/Bindings/Python/ir_operation.py
The file was modifiedmlir/lib/Bindings/Python/IRModules.cpp
Commit e56f398dd3740d97ac3b7ec1c69a12b951efd9a3 by joker.eph
Add Python binding for MLIR Type Attribute

Differential Revision: https://reviews.llvm.org/D92711
The file was modifiedmlir/test/Bindings/Python/ir_attributes.py
The file was modifiedmlir/lib/Bindings/Python/IRModules.cpp