SuccessChanges

Summary

  1. [AMDGPU] Run hazard recognizer pass later (details)
  2. [flang] Disallow pointer constants (details)
  3. [CGSCC] Add -abort-on-max-devirt-iterations-reached option (details)
  4. [SCEV] Add additional tests where the max BTC is limited by wrapping. (details)
  5. Revert "Recommit "[SCEV] Use nw flag and symbolic iteration count to sharpen ranges of AddRecs"" (details)
  6. [AMDGPU] Drop array size in AMDGCNGPUs and R600GPUs (details)
  7. [VectorCombine] Avoid crossing address space boundaries. (details)
  8. Extend memset-to-zero optimization to C++11 aggregate functional casts (details)
  9. Treat constant contexts as being in the default rounding mode. (details)
  10. make the AsmPrinterHandler array public (details)
  11. Fix Windows llvm-objdump tests (details)
  12. [AMDGPU] Fix gfx1032 description in AMDGPUUsage.rst. NFC. (details)
  13. Revert "Fix Windows llvm-objdump tests" (details)
  14. [Format/ObjC] Correctly handle base class with lightweight generics and protocol (details)
  15. Revert "make the AsmPrinterHandler array public" (details)
  16. [lldb] Implement ObjCExceptionThrowFrameRecognizer::GetName() (details)
Commit 978fbd8268ce5f5cd01ae9fc41cd03ea7a08dabe by Austin.Kerbow
[AMDGPU] Run hazard recognizer pass later

If instructions were removed in peephole passes after the hazard recognizer was
run it is possible that new hazards could be introduced.

Fixes: SWDEV-253090

Reviewed By: rampitec, arsenm

Differential Revision: https://reviews.llvm.org/D89077
The file was modifiedllvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
The file was addedllvm/test/CodeGen/AMDGPU/hazard-pass-ordering.mir
Commit f2897b8f45c1df944e45f849757d2a2507e96805 by psteinfeld
[flang] Disallow pointer constants

None of the other Fortran compilers allow them.

Differential Revision: https://reviews.llvm.org/D89581
The file was modifiedflang/lib/Semantics/check-declarations.cpp
The file was modifiedflang/test/Semantics/resolve90.f90
Commit faf521042098f3780a8b12698260833d9c980b62 by aeubanks
[CGSCC] Add -abort-on-max-devirt-iterations-reached option

Aborts if we hit the max devirtualization iteration.
Will be useful for testing that changes to devirtualization don't cause
devirtualization to repeat passes more times than necessary.

Reviewed By: rnk

Differential Revision: https://reviews.llvm.org/D89519
The file was modifiedllvm/include/llvm/Analysis/CGSCCPassManager.h
The file was modifiedllvm/lib/Analysis/CGSCCPassManager.cpp
The file was modifiedllvm/test/Other/cgscc-devirt-iteration.ll
Commit f085b7cbc1a673e89f74926961e44ba468411619 by flo
[SCEV] Add additional tests where the max BTC is limited by wrapping.
The file was modifiedllvm/test/Analysis/ScalarEvolution/max-backedge-taken-count-limit-by-wrapping.ll
Commit 74c8c2d903e2c849a2132ae798018f8bbe00ea21 by nikita.ppv
Revert "Recommit "[SCEV] Use nw flag and symbolic iteration count to sharpen ranges of AddRecs""

This reverts commit 32b72c3165bf65cca2e8e6197b59eb4c4b60392a.

While better than before, this change still introduces a large
compile-time regression (>3% on mafft):
https://llvm-compile-time-tracker.com/compare.php?from=fbd62fe60fb2281ca33da35dc25ca3c87ec0bb51&to=32b72c3165bf65cca2e8e6197b59eb4c4b60392a&stat=instructions

Additionally, the logic here doesn't look quite right to me,
I will comment in more detail on the differential revision.
The file was modifiedllvm/test/Transforms/IndVarSimplify/X86/eliminate-trunc.ll
The file was modifiedllvm/lib/Analysis/ScalarEvolution.cpp
The file was modifiedllvm/test/Analysis/ScalarEvolution/no-wrap-symbolic-becount.ll
The file was modifiedllvm/test/Transforms/IndVarSimplify/promote-iv-to-eliminate-casts.ll
The file was modifiedllvm/include/llvm/Analysis/ScalarEvolution.h
Commit 874524ab88a9cb8a9208be281ab5103c92b8bf15 by Stanislav.Mekhanoshin
[AMDGPU] Drop array size in AMDGCNGPUs and R600GPUs

Differential Revision: https://reviews.llvm.org/D89568
The file was modifiedllvm/lib/Support/TargetParser.cpp
Commit c36c0fabd17a57513fa00ebd5579f307f889cb64 by tra
[VectorCombine] Avoid crossing address space boundaries.

We can not bitcast pointers across different address spaces, and VectorCombine
should be careful when it attempts to find the original source of the loaded
data.

Differential Revision: https://reviews.llvm.org/D89577
The file was addedllvm/test/Transforms/VectorCombine/AMDGPU/as-transition.ll
The file was addedllvm/test/Transforms/VectorCombine/AMDGPU/lit.local.cfg
The file was modifiedllvm/lib/Transforms/Vectorize/VectorCombine.cpp
Commit 48c70c1664aa4512cb7e08352dd8eb33dde4807c by richard
Extend memset-to-zero optimization to C++11 aggregate functional casts
Aggr{...}.

We previously missed these cases due to not stepping over the additional
AST nodes representing their syntactic form.
The file was modifiedclang/lib/CodeGen/CGExprAgg.cpp
The file was modifiedclang/test/CodeGenCXX/cxx11-initializer-aggregate.cpp
Commit 7e801ca0efa99f7cec7a2aea30513ad282030b51 by richard
Treat constant contexts as being in the default rounding mode.

This addresses a regression where pretty much all C++ compilations using
-frounding-math now fail, due to rounding being performed in constexpr
function definitions in the standard library.

This follows the "manifestly constant evaluated" approach described in
https://reviews.llvm.org/D87528#2270676 -- evaluations that are required
to succeed at compile time are permitted even in regions with dynamic
rounding modes, as are (unfortunately) the evaluation of the
initializers of local variables of const integral types.

Differential Revision: https://reviews.llvm.org/D89360
The file was addedclang/test/Sema/rounding-math.c
The file was modifiedclang/lib/AST/ExprConstant.cpp
The file was addedclang/test/SemaCXX/rounding-math.cpp
Commit ac2def2d8d8c9aa6f96f0c869a5b988ae602385a by vtjnash
make the AsmPrinterHandler array public

This lets external consumers customize the output, similar to how
AssemblyAnnotationWriter lets the caller define callbacks when printing
IR. The array of handlers already existed, this just cleans up the code
so that it can be exposed publically.

Differential Revision: https://reviews.llvm.org/D74158
The file was modifiedllvm/include/llvm/CodeGen/AsmPrinter.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
The file was modifiedllvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
The file was modifiedllvm/include/llvm/CodeGen/AsmPrinterHandler.h
The file was modifiedllvm/lib/CodeGen/MachineModuleInfo.cpp
The file was modifiedllvm/unittests/CodeGen/TestAsmPrinter.h
The file was modifiedllvm/unittests/CodeGen/AsmPrinterDwarfTest.cpp
The file was modifiedllvm/lib/Target/BPF/BTFDebug.cpp
The file was modifiedllvm/include/llvm/CodeGen/DebugHandlerBase.h
Commit 66506eeb37b293b9be5b943d51ec087608396d8c by rengolin
Fix Windows llvm-objdump tests

Broken in e95f9a23fad with path issues.
The file was modifiedllvm/test/tools/llvm-objdump/X86/source-interleave-prefix.test
The file was modifiedllvm/test/tools/llvm-objdump/X86/source-interleave-prefix-non-windows.test
Commit 173389e16d32521ee8160b97f31daefcdd78fa2e by Stanislav.Mekhanoshin
[AMDGPU] Fix gfx1032 description in AMDGPUUsage.rst. NFC.

Differential Revision: https://reviews.llvm.org/D89565
The file was modifiedllvm/docs/AMDGPUUsage.rst
Commit f0f3d1b1817a48daa0680324bec3c6d34e590d4a by rengolin
Revert "Fix Windows llvm-objdump tests"

It had already been fixed in a different way.
The file was modifiedllvm/test/tools/llvm-objdump/X86/source-interleave-prefix.test
The file was modifiedllvm/test/tools/llvm-objdump/X86/source-interleave-prefix-non-windows.test
Commit 24b5266892c30e2c9cb6ea28c2631e988a5754b6 by benhamilton
[Format/ObjC] Correctly handle base class with lightweight generics and protocol

ClangFormat does not correctly handle an Objective-C interface declaration
with both lightweight generics and a protocol conformance.

This simple example:

```
@interface Foo : Bar <Baz> <Blech>

@end
```

means `Foo` extends `Bar` (a lightweight generic class whose type
parameter is `Baz`) and also conforms to the protocol `Blech`.

ClangFormat should not apply any changes to the above example, but
instead it currently formats it quite poorly:

```
@interface Foo : Bar <Baz>
<Blech>

    @end
    ```

The bug is that `UnwrappedLineParser` assumes an open-angle bracket
after a base class name is a protocol list, but it can also be a
lightweight generic specification.

This diff fixes the bug by factoring out the logic to parse
lightweight generics so it can apply both to the declared class
as well as the base class.

Test Plan: New tests added. Ran tests with:
  % ninja FormatTests && ./tools/clang/unittests/Format/FormatTests
  Confirmed tests failed before diff and passed after diff.

Reviewed By: sammccall, MyDeveloperDay

Differential Revision: https://reviews.llvm.org/D89496
The file was modifiedclang/lib/Format/UnwrappedLineParser.h
The file was modifiedclang/lib/Format/UnwrappedLineParser.cpp
The file was modifiedclang/unittests/Format/FormatTestObjC.cpp
Commit 4242df14708cb84b3732ba1a22fb77146833340b by vtjnash
Revert "make the AsmPrinterHandler array public"

I messed up one of the tests.
The file was modifiedllvm/include/llvm/CodeGen/AsmPrinter.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
The file was modifiedllvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
The file was modifiedllvm/include/llvm/CodeGen/DebugHandlerBase.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
The file was modifiedllvm/unittests/CodeGen/TestAsmPrinter.h
The file was modifiedllvm/lib/CodeGen/MachineModuleInfo.cpp
The file was modifiedllvm/include/llvm/CodeGen/AsmPrinterHandler.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
The file was modifiedllvm/lib/Target/BPF/BTFDebug.cpp
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
The file was modifiedllvm/unittests/CodeGen/AsmPrinterDwarfTest.cpp
Commit f16cecf3752a7c168293934d2ba6472a6b405694 by davelee.com
[lldb] Implement ObjCExceptionThrowFrameRecognizer::GetName()

Implement `GetName` for `ObjCExceptionThrowFrameRecognizer`. Otherwise, `frame recognizer list` shows "(internal)" for the name.

Differential Revision: https://reviews.llvm.org/D89589
The file was modifiedlldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp