SuccessChanges

Summary

  1. Use consistent code for setting FPFeatures from operator constructors. (details)
  2. Always keep unset fields in FPOptionsOverride zeroed. (details)
  3. Replace setter named 'getAsOpaqueInt' with a real getter. (details)
  4. [StackSafety] Skip ambiguous lifetime analysis (details)
  5. Initial MLIR python bindings based on the C API. (details)
  6. [clang] fix a compilation bug (details)
  7. [InstCombine] Fix a compilation bug (details)
  8. [PowerPC] Make StartMI ignore COPY like instructions. (details)
  9. [X86] Reject dirflag in inline asm constraints other than clobber. (details)
  10. [lldb] Print the exception traceback when hitting cleanup errors (details)
  11. [clang] Make signature help work with dependent args (details)
  12. [lldb][NFC] Remove stride parameter from GetArrayElementType (details)
  13. [VE] Support f128 (details)
  14. [lldb] Get lldb-server platform's --socket-file working again (details)
  15. [lldb] Fix that log enable's -f parameter causes LLDB to crash when it can't open the log file (details)
  16. [lldb] Add SBModule::GarbageCollectAllocatedModules and clear modules after each test run (details)
  17. [lldb] Forcefully complete a type when adding nested classes (details)
  18. [lldb/Utility] Simplify and generalize Scalar class (details)
  19. [lldb] Don't delete orphaned shared modules in SBDebugger::DeleteTarget (details)
  20. [lldb] Remove OS-specific string from TestInvalidArgsLog (details)
  21. [NFC][StackSafety] Move out sort from the loop (details)
  22. [InlineCost] Fix scalable vectors in visitAlloca (details)
  23. [lldb][NFC] Use the proper type for the 'storage' parameter of CreateFunctionDeclaration (details)
  24. [X86][AVX] Move lowerShuffleWithVPMOV inside explicit shuffle lowering cases (details)
  25. [lldb][NFC] Use expect_expr in more tests (details)
  26. [lldb][NFC] Remove name parameter from CreateFunctionTemplateDecl (details)
  27. [LLD][ELF] - Do not produce an invalid dynamic relocation order with --shuffle-sections. (details)
Commit ae3067055b33f6ab5657fbae5845cc743b91c299 by richard
Use consistent code for setting FPFeatures from operator constructors.
The file was modifiedclang/lib/AST/Expr.cpp (diff)
Commit ae500e4d0964adea69372d083416b0f13e9a87eb by richard
Always keep unset fields in FPOptionsOverride zeroed.

There are three fields that the FPOptions default constructor sets to
non-zero values; those fields previously could have been zero or
non-zero depending on whether they'd been explicitly removed from the
FPOptionsOverride set. However, that doesn't seem to ever actually
happen, so this is NFC, except that it makes the AST file representation
of FPOptionsOverride make more sense.
The file was modifiedclang/include/clang/Basic/LangOptions.h (diff)
The file was modifiedclang/test/PCH/determinism.cpp (diff)
Commit 948219d1098736758123c43f995ec784db5d921e by richard
Replace setter named 'getAsOpaqueInt' with a real getter.

Clean up a bunch of places where the opaque forms of FPOptions and
FPOptionsOverride were being used inappropriately.
The file was modifiedclang/lib/Serialization/ASTReaderStmt.cpp (diff)
The file was modifiedclang/lib/Sema/Sema.cpp (diff)
The file was modifiedclang/lib/Serialization/ASTWriter.cpp (diff)
The file was modifiedclang/lib/Parse/ParseDeclCXX.cpp (diff)
The file was modifiedclang/include/clang/Serialization/ASTReader.h (diff)
The file was modifiedclang/lib/Serialization/ASTReader.cpp (diff)
The file was modifiedclang/include/clang/Sema/Sema.h (diff)
The file was modifiedclang/lib/Sema/TreeTransform.h (diff)
The file was modifiedclang/include/clang/Basic/LangOptions.h (diff)
The file was modifiedclang/lib/Sema/SemaAttr.cpp (diff)
Commit e10e7829bf6f10c053c05e42b676d7acaf54a221 by Vitaly Buka
[StackSafety] Skip ambiguous lifetime analysis

If we can't identify alloca used in lifetime marker we
need to assume to worst case scenario.

Reviewed By: eugenis

Differential Revision: https://reviews.llvm.org/D84630
The file was modifiedllvm/include/llvm/Analysis/StackLifetime.h (diff)
The file was addedllvm/test/Transforms/SafeStack/X86/no-crash-on-lifetime.ll
The file was modifiedllvm/test/Analysis/StackSafetyAnalysis/lifetime.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/stack-tagging.ll (diff)
The file was modifiedllvm/lib/Analysis/StackLifetime.cpp (diff)
Commit fcd2969da9e04a70103bfbf8a382c0842fcf6aaf by stellaraccident
Initial MLIR python bindings based on the C API.

* Basic support for context creation, module parsing and dumping.

Differential Revision: https://reviews.llvm.org/D85481
The file was modifiedmlir/lib/Bindings/Python/CMakeLists.txt (diff)
The file was addedmlir/lib/Bindings/Python/IRModules.cpp
The file was addedmlir/test/Bindings/Python/ir_test.py
The file was modifiedmlir/lib/Bindings/Python/MainModule.cpp (diff)
The file was addedmlir/lib/Bindings/Python/IRModules.h
Commit 000ad1a976a537256b17788dcf8b50ca117007b8 by yhs
[clang] fix a compilation bug

With gcc 6.3.0, I hit the following compilation bug:
  /home/yhs/work/llvm-project/clang/lib/Frontend/CompilerInvocation.cpp:
  In function ‘bool ParseCodeGenArgs(clang::CodeGenOptions&, llvm::opt::ArgList&,
  clang::InputKind, clang::DiagnosticsEngine&, const clang::TargetOptions&,
  const clang::FrontendOptions&)’:
  /home/yhs/work/llvm-project/clang/lib/Frontend/CompilerInvocation.cpp:780:12:
    error: unused variable ‘A’ [-Werror=unused-variable]
     if (Arg *A = Args.getLastArg(OPT_fuse_ctor_homing))
              ^
  cc1plus: all warnings being treated as errors

The bug is introduced by Commit ae6523cd62a4 ("[DebugInfo] Add
-fuse-ctor-homing cc1 flag so we can turn on constructor homing only
if limited debug info is already on.")
The file was modifiedclang/lib/Frontend/CompilerInvocation.cpp (diff)
Commit aa61e43040495235706229a7bde748a9beff137b by yhs
[InstCombine] Fix a compilation bug

With gcc 6.3.0, I hit the following compilation bug.
  ../lib/Transforms/InstCombine/InstCombineVectorOps.cpp:937:2: error: extra ‘;’ [-Werror=pedantic]
   };
    ^
  cc1plus: all warnings being treated as errors

The error is introduced by Commit ae7f08812e09 ("[InstCombine]
Aggregate reconstruction simplification (PR47060)")
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp (diff)
Commit 4d52ebb9b9c72b656c1ccb6a1424841f246cd791 by czhengsz
[PowerPC] Make StartMI ignore COPY like instructions.

Reviewed By: lkail

Differential Revision: https://reviews.llvm.org/D85659
The file was modifiedllvm/lib/Target/PowerPC/PPCInstrInfo.cpp (diff)
The file was modifiedllvm/test/CodeGen/PowerPC/fixup-kill-dead-flag-crash.mir (diff)
The file was modifiedllvm/lib/Target/PowerPC/PPCInstrInfo.h (diff)
Commit a206f8509124c483358eb6e80e08bf621efd7655 by craig.topper
[X86] Reject dirflag in inline asm constraints other than clobber.

Fixes the crash from PR47195.
The file was modifiedllvm/lib/Target/X86/X86ISelLowering.cpp (diff)
Commit 24fc3177c1767535aeb494511a13dabf9f6de647 by Raphael Isemann
[lldb] Print the exception traceback when hitting cleanup errors

Right now if the test suite encounters a cleanup error it just prints "CLEANUP
ERROR:" but not any additional information.

This patch just prints the exception that caused the cleanup error. This should
make debugging the failing tests for D83865 easier (and seems in general nice to
have).

Reviewed By: labath

Differential Revision: https://reviews.llvm.org/D83874
The file was modifiedlldb/packages/Python/lldbsuite/test/test_result.py (diff)
Commit 53c593c2c893a40083771789e3d3e164eea1892d by kadircet
[clang] Make signature help work with dependent args

Fixes https://github.com/clangd/clangd/issues/490

Differential Revision: https://reviews.llvm.org/D85826
The file was modifiedclang/test/CodeCompletion/call.cpp (diff)
The file was modifiedclang-tools-extra/clangd/unittests/CodeCompleteTests.cpp (diff)
The file was modifiedclang/lib/Sema/SemaCodeComplete.cpp (diff)
Commit 5913f2591c45dc84e872a62343f81462372ccbdb by Raphael Isemann
[lldb][NFC] Remove stride parameter from GetArrayElementType

This parameter isn't used anywhere in LLDB nor the Swift downstream branch. It
also doesn't really fit into the TypeSystem APIs that usually don't return
additional related functionality via some output parameters. Also the
implementations already states that the calculated value there is wrong.

Let's remove it. If we need this functionality at some point then Swift's much
nicer `GetByteStride` function seems like the way to go.

Reviewed By: aprantl

Differential Revision: https://reviews.llvm.org/D84299
The file was modifiedlldb/include/lldb/Symbol/TypeSystem.h (diff)
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (diff)
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.h (diff)
The file was modifiedlldb/source/Symbol/CompilerType.cpp (diff)
The file was modifiedlldb/include/lldb/Symbol/CompilerType.h (diff)
Commit 40f1e7e80401dab11f6003fb59c43ba9059959cd by marukawa
[VE] Support f128

Support f128 using VE instructions.  Update regression tests.
I've noticed there is no load or store i128 test, so I add them too.

Reviewed By: simoll

Differential Revision: https://reviews.llvm.org/D86035
The file was modifiedllvm/test/CodeGen/VE/va_arg.ll (diff)
The file was modifiedllvm/lib/Target/VE/VEMCInstLower.cpp (diff)
The file was modifiedllvm/test/CodeGen/VE/load.ll (diff)
The file was modifiedllvm/lib/Target/VE/VEInstrInfo.cpp (diff)
The file was modifiedllvm/test/CodeGen/VE/load_gv.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/store_gv.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/call.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/load_off.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/fp_add.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/fp_mul.ll (diff)
The file was modifiedllvm/lib/Target/VE/VECallingConv.td (diff)
The file was modifiedllvm/test/CodeGen/VE/store.ll (diff)
The file was modifiedllvm/lib/Target/VE/VEInstrInfo.td (diff)
The file was modifiedllvm/lib/Target/VE/VEISelLowering.cpp (diff)
The file was modifiedllvm/test/CodeGen/VE/fp_sub.ll (diff)
The file was modifiedllvm/lib/Target/VE/VEISelLowering.h (diff)
The file was modifiedllvm/lib/Target/VE/VERegisterInfo.cpp (diff)
The file was modifiedllvm/test/CodeGen/VE/fp_div.ll (diff)
The file was modifiedllvm/test/CodeGen/VE/va_caller.ll (diff)
Commit c57ea1b48f26caf7922bf434187e1c277f412550 by Raphael Isemann
[lldb] Get lldb-server platform's --socket-file working again

`lldb-server platform --socket-file /any/path` currently always fails to create
the socket file.  This stopped working after D67424 which changed the
input variables of `writeFileAtomically` slightly. We're expected to
pass in a temporary path template (`/tmp/foo-%%%%%`) and the final
path we want to write. Instead we currently pass in the never set
`temp_file_path` as the temporary path (which will make this function always
fail) and pass in the temp_file_spec's path as the final path (which is actually
the template path such as `/tmp/foo-%%%%%`) instead of the actual path
we want to write (e.g. `/tmp/foo`).

Reviewed By: labath

Differential Revision: https://reviews.llvm.org/D85890
The file was modifiedlldb/tools/lldb-server/lldb-platform.cpp (diff)
Commit 867c347c32e27825a649af1ca5ccf22c350d2b8c by Raphael Isemann
[lldb] Fix that log enable's -f parameter causes LLDB to crash when it can't open the log file

We didn't do anything with the llvm::Error we get from `Open`, so when we end up in the
error case we just crash due to the llvm::Error sanity check. Also add the missing newline
behind the error message so it no longer messes with the next (lldb) prompt.

Reviewed By: JDevlieghere

Differential Revision: https://reviews.llvm.org/D85970
The file was modifiedlldb/source/Core/Debugger.cpp (diff)
The file was modifiedlldb/test/API/commands/log/invalid-args/TestInvalidArgsLog.py (diff)
Commit c2f9454a16e45e1df09d8ebed6dadbc0da264442 by Raphael Isemann
[lldb] Add SBModule::GarbageCollectAllocatedModules and clear modules after each test run

Right now the only places in the SB API where lldb:: ModuleSP instances are
destroyed are in SBDebugger::MemoryPressureDetected (where it's just attempted
but not guaranteed) and in SBDebugger::DeleteTarget (which will be removed in
D83933). Tests that directly create an lldb::ModuleSP and never create a target
therefore currently leak lldb::Module instances. This triggers the sanity checks
in lldbtest that make sure that the global module list is empty after a test.

This patch adds SBModule::GarbageCollectAllocatedModules as an explicit way to
clean orphaned lldb::ModuleSP instances. Also we now start calling this method
at the end of each test run and move the sanity check behind that call to make
this work. This way even tests that don't create targets can pass the sanity
check.

This fixes TestUnicodeSymbols.py when D83865 is applied (which makes that the
sanity checks actually fail the test).

Reviewed By: JDevlieghere

Differential Revision: https://reviews.llvm.org/D83876
The file was modifiedlldb/include/lldb/API/SBModule.h (diff)
The file was modifiedlldb/source/API/SBModule.cpp (diff)
The file was modifiedlldb/packages/Python/lldbsuite/test/lldbtest.py (diff)
The file was modifiedlldb/bindings/interface/SBModule.i (diff)
Commit 2d89a3ba121b96a4af9aecaf52205eab200394c3 by pavel
[lldb] Forcefully complete a type when adding nested classes

With -flimit-debug-info, we can run into cases when we only have a class
as a declaration, but we do have a definition of a nested class. In this
case, clang will hit an assertion when adding a member to an incomplete
type (but only if it's adding a c++ class, and not C struct).

It turns out we already had code to handle a similar situation arising
in the -gmodules scenario. This extends the code to handle
-flimit-debug-info as well, and reorganizes bits of other code handling
completion of types to move functions doing similar things closer
together.

Differential Revision: https://reviews.llvm.org/D85968
The file was modifiedlldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.h (diff)
The file was modifiedlldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (diff)
The file was modifiedlldb/test/Shell/SymbolFile/DWARF/DW_AT_declaration-with-children.s (diff)
Commit 67cdb899c6b3ec231f35ca17a00023758ef127ba by pavel
[lldb/Utility] Simplify and generalize Scalar class

The class contains an enum listing all host integer types as well as
some non-host types. This setup is a remnant of a time when this class
was actually implemented in terms of host integer types. Now that we are
using llvm::APInt, they are mostly useless and mean that each function
needs to enumerate all of these cases even though it treats most of them
identically.

I only leave e_sint and e_uint to denote the integer signedness, but I
want to remove that in a follow-up as well.

Removing these cases simplifies most of these functions, with the only
exception being PromoteToMaxType, which can no longer rely on a simple
enum comparison to determine what needs to be promoted.

This also makes the class ready to work with arbitrary integer sizes, so
it does not need to be modified when someone needs to add a larger
integer size.

Differential Revision: https://reviews.llvm.org/D85836
The file was modifiedlldb/include/lldb/Utility/Scalar.h (diff)
The file was modifiedlldb/unittests/Utility/ScalarTest.cpp (diff)
The file was modifiedlldb/source/Utility/Scalar.cpp (diff)
Commit 24c74f5e8c2cf263dd84292ca5d33ee0890b48dd by Raphael Isemann
[lldb] Don't delete orphaned shared modules in SBDebugger::DeleteTarget

In D83876 the consensus seems that LLDB should never deleted orphaned modules
implicitly. However, SBDebugger::DeleteTarget is currently doing exactly that.
This code was added in 753406221b55b95141c8c1239660dc4db4e35ea5 but I don't see
any explanation in the commit, so I think we should delete it.

Reviewed By: clayborg

Differential Revision: https://reviews.llvm.org/D83933
The file was modifiedlldb/source/API/SBDebugger.cpp (diff)
Commit 6b97fa0bfefea7d9028b899a92bc29ab9b133906 by Raphael Isemann
[lldb] Remove OS-specific string from TestInvalidArgsLog

This is the error message from the OS, so we shouldn't check against the
OS-specific part of the string.

Fixes the test on Windows which returns a different error message.
The file was modifiedlldb/test/API/commands/log/invalid-args/TestInvalidArgsLog.py (diff)
Commit 3b348d91028726f840868875dac3bcefcefda917 by Vitaly Buka
[NFC][StackSafety] Move out sort from the loop
The file was modifiedllvm/lib/Analysis/StackSafetyAnalysis.cpp (diff)
The file was modifiedllvm/test/Bitcode/thinlto-function-summary-paramaccess.ll (diff)
Commit 2ccde3c96b784f74370beff5dab5fbf3e70fae8b by cullen.rhodes
[InlineCost] Fix scalable vectors in visitAlloca

Discovered as part of the VLS type work (see D85128).

Reviewed By: efriedma

Differential Revision: https://reviews.llvm.org/D85848
The file was modifiedllvm/lib/Analysis/InlineCost.cpp (diff)
The file was addedllvm/test/Transforms/Inline/inline-scalable.ll
Commit cd2139a527f2d829bdde7877c992215f598e927b by Raphael Isemann
[lldb][NFC] Use the proper type for the 'storage' parameter of CreateFunctionDeclaration

All the callers pass an enum and we cast the int anyway back to the actual type,
so we might as well just use the type for the parameter.
The file was modifiedlldb/unittests/Symbol/TestTypeSystemClang.cpp (diff)
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.h (diff)
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (diff)
Commit 1d2ede87eacb0c4a063691905b4464bb04f8eca7 by llvm-dev
[X86][AVX] Move lowerShuffleWithVPMOV inside explicit shuffle lowering cases

Perform lowerShuffleWithVPMOV as part of the v16i8/v8i16 shuffle lowering stages, which are the only types that are currently supported.

We need to expand support for lowering shuffles as truncations to fix the remaining regressions in D66004
The file was modifiedllvm/lib/Target/X86/X86ISelLowering.cpp (diff)
Commit 42b9a683523628bfbb4f7447c0ca9607f3eee83f by Raphael Isemann
[lldb][NFC] Use expect_expr in more tests
The file was modifiedlldb/test/API/commands/expression/cast_int_to_anonymous_enum/TestCastIntToAnonymousEnum.py (diff)
The file was modifiedlldb/test/API/commands/expression/function_template_specialization_temp_args/TestFunctionTemplateSpecializationTempArgs.py (diff)
The file was modifiedlldb/test/API/lang/objc/objc_direct-methods/main.m (diff)
The file was modifiedlldb/test/API/lang/cpp/namespace/TestNamespace.py (diff)
The file was modifiedlldb/test/API/commands/expression/expr-in-syscall/TestExpressionInSyscall.py (diff)
The file was modifiedlldb/test/API/commands/expression/ignore-artificial-constructors/main.cpp (diff)
The file was modifiedlldb/test/API/commands/expression/argument_passing_restrictions/TestArgumentPassingRestrictions.py (diff)
Commit 7e6c437fb413eb7ae102e8db869bb55a748411ff by Raphael Isemann
[lldb][NFC] Remove name parameter from CreateFunctionTemplateDecl

It's unused and not documented.
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.cpp (diff)
The file was modifiedlldb/unittests/Symbol/TestTypeSystemClang.cpp (diff)
The file was modifiedlldb/source/Plugins/TypeSystem/Clang/TypeSystemClang.h (diff)
The file was modifiedlldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp (diff)
Commit c135a68d426fd69d26454658bfa62102993f12a7 by grimar
[LLD][ELF] - Do not produce an invalid dynamic relocation order with --shuffle-sections.

Normally (when not on android with android relocation packing enabled),
we put IRelative relocations to ".rel[a].dyn", after other relocations,
to ensure that IRelatives are processed last by the dynamic loader.

To achieve that we add the `in.relaIplt` after the `part.relaDyn`:
https://github.com/llvm/llvm-project/blob/master/lld/ELF/Writer.cpp#L540

The problem is that `--shuffle-sections` might break the sections order.
This patch fixes it.

Fixes https://bugs.llvm.org/show_bug.cgi?id=47056.

Differential revision: https://reviews.llvm.org/D85651
The file was modifiedlld/ELF/Writer.cpp (diff)
The file was modifiedlld/test/ELF/gnu-ifunc-plt.s (diff)