SuccessChanges

Summary

  1. [flang] Clean up TODO comments and fix one (DATA constant ambiguity) (details)
  2. [NFC][Tests][SimplifyCFG] Trim whitespaces at the end of lines (details)
  3. [NFCI][SimplifyCFG] Add basic scaffolding for gradually making the pass DomTree-aware (details)
  4. [mlir][IR] Define the singleton builtin types in ODS instead of C++ (details)
  5. [RISCV] Only custom legalize i32 arguments to vector intrinsics on RV64. (details)
  6. [clang] Migrate deprecated DebugInfo::get to DILocation::get (details)
  7. AMDGPU: Remove redundant CCAction for i1 (details)
  8. GlobalISel: Fix generic handling of single outgoing call arguments (details)
  9. [Hexagon] Fix bitcasting v1i8 -> i8 (details)
  10. [docs][unittest][Go][StackProtector] Migrate deprecated DebugInfo::get to DILocation::get (details)
  11. Frontend: Fix confusing comment at call to clearOutputFiles, NFC (details)
Commit 9a883bfa11dd77cf2d45a25c5efc364e256e6d9a by pklausler
[flang] Clean up TODO comments and fix one (DATA constant ambiguity)

Remove resolved & moot TODO comments in Common/, Parser/,
and Evaluate/.  Address a pending one relating to parsing
ambiguity in DATA statement constants, handling it with
symbol table information in Semantics and adding a test.

Differential Revision: https://reviews.llvm.org/D93323
The file was modifiedflang/lib/Evaluate/type.cpp
The file was modifiedflang/include/flang/Evaluate/real.h
The file was modifiedflang/lib/Semantics/rewrite-parse-tree.cpp
The file was modifiedflang/include/flang/Parser/dump-parse-tree.h
The file was modifiedflang/include/flang/Parser/parse-tree.h
The file was modifiedflang/test/Semantics/data01.f90
The file was modifiedflang/lib/Parser/program-parsers.cpp
The file was modifiedflang/lib/Semantics/data-to-inits.cpp
The file was modifiedflang/lib/Parser/Fortran-parsers.cpp
The file was modifiedflang/test/Semantics/data06.f90
The file was modifiedflang/lib/Evaluate/check-expression.cpp
The file was addedflang/test/Semantics/data10.f90
The file was modifiedflang/include/flang/Parser/parse-state.h
Commit a7deedc414e2abbe4b9557d46e896a5bdba25f2b by lebedev.ri
[NFC][Tests][SimplifyCFG] Trim whitespaces at the end of lines
The file was modifiedllvm/test/Transforms/SimplifyCFG/X86/empty-cleanuppad.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2008-12-06-SingleEntryPhi.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/wineh-unreachable.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2003-08-17-BranchFold.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2008-05-16-PHIBlockMerge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2003-08-17-BranchFoldOrdering.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/common-code-hoisting.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/nomerge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/preserve-make-implicit-on-switch-to-br.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiEliminate.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiBlockMerge2.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PHINode.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiNoEliminate.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/invoke_unwind.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/trapping-load-unreachable.ll
Commit e1133179587dd895962a2fe4d6eb0cb1e63b5ee2 by lebedev.ri
[NFCI][SimplifyCFG] Add basic scaffolding for gradually making the pass DomTree-aware

Two observations:
1. Unavailability of DomTree makes it impossible to make
  `FoldBranchToCommonDest()` transform in certain cases,
   where the successor is dominated by predecessor,
   because we then don't have PHI's, and can't recreate them,
   well, without handrolling 'is dominated by' check,
   which doesn't really look like a great solution to me.
2. Avoiding invalidating DomTree in SimplifyCFG will
   decrease the number of `Dominator Tree Construction` by 5
   (from 28 now, i.e. -18%) in `-O3` old-pm pipeline
   (as per `llvm/test/Other/opt-O3-pipeline.ll`)
   This might or might not be beneficial for compile time.

So the plan is to make SimplifyCFG preserve DomTree, and then
eventually make DomTree fully required and preserved by the pass.

Now, SimplifyCFG is ~7KLOC. I don't think it will be nice
to do all this uplifting in a single mega-commit,
nor would it be possible to review it in any meaningful way.

But, i believe, it should be possible to do this in smaller steps,
introducing the new behavior, in an optional way, off-by-default,
opt-in option, and gradually fixing transforms one-by-one
and adding the flag to appropriate test coverage.

Then, eventually, the default should be flipped,
and eventually^2 the flag removed.

And that is what is happening here - when the new off-by-default option
is specified, DomTree is required and is claimed to be preserved,
and SimplifyCFG-internal assertions verify that the DomTree is still OK.
The file was modifiedllvm/include/llvm/Transforms/Utils/Local.h
The file was modifiedllvm/lib/Transforms/Scalar/SimplifyCFGPass.cpp
The file was modifiedllvm/lib/Transforms/Utils/SimplifyCFG.cpp
Commit 95019de8a122619fc038c9fe3c80e625e3456bbf by riddleriver
[mlir][IR] Define the singleton builtin types in ODS instead of C++

This exposes several issues with the current generation that this revision also fixes.
* TypeDef now allows specifying the base class to use when generating.
* TypeDef now inherits from DialectType, which allows for using it as a TypeConstraint
* Parser/Printers are now no longer generated in the header(removing duplicate symbols), and are now only generated when necessary.
    - Now that generatedTypeParser/Printer are only generated in the definition file,
      existing users will need to manually expose this functionality when necessary.
* ::get() is no longer generated for singleton types, because it isn't necessary.

Differential Revision: https://reviews.llvm.org/D93270
The file was modifiedmlir/lib/TableGen/Constraint.cpp
The file was modifiedmlir/lib/TableGen/TypeDef.cpp
The file was addedmlir/include/mlir/IR/BuiltinTypes.td
The file was modifiedmlir/tools/mlir-tblgen/TypeDefGen.cpp
The file was modifiedmlir/docs/OpDefinitions.md
The file was modifiedmlir/lib/IR/CMakeLists.txt
The file was modifiedmlir/include/mlir/IR/BuiltinOps.td
The file was modifiedmlir/include/mlir/IR/BuiltinTypes.h
The file was modifiedmlir/include/mlir/TableGen/TypeDef.h
The file was modifiedmlir/test/mlir-tblgen/typedefs.td
The file was addedmlir/include/mlir/IR/BuiltinDialect.td
The file was modifiedmlir/lib/IR/BuiltinTypes.cpp
The file was modifiedmlir/test/lib/Dialect/Test/TestDialect.cpp
The file was modifiedmlir/include/mlir/IR/OpBase.td
The file was modifiedmlir/include/mlir/IR/CMakeLists.txt
The file was modifiedmlir/test/lib/Dialect/Test/TestTypes.cpp
Commit 028efac2d7c2a32c35a093e53ea12f527edff7c7 by craig.topper
[RISCV] Only custom legalize i32 arguments to vector intrinsics on RV64.
The file was modifiedllvm/lib/Target/RISCV/RISCVISelLowering.cpp
Commit 59decf8e9c3d86472073266ad8ee1cc699d94525 by i
[clang] Migrate deprecated DebugInfo::get to DILocation::get
The file was modifiedclang/lib/CodeGen/CGDebugInfo.cpp
Commit 97f51f0489e55ec73efd8d1623d19b3455f39878 by Matthew.Arsenault
AMDGPU: Remove redundant CCAction for i1
The file was modifiedllvm/lib/Target/AMDGPU/AMDGPUCallingConv.td
Commit e7e7d371fd871c9976bd2c7bbb9be60fe37c6d28 by Matthew.Arsenault
GlobalISel: Fix generic handling of single outgoing call arguments

Simply call the argument handler like is done for the incoming
case. This will allow removal of hacks in the AMDGPU call lowering in
a future change.
The file was modifiedllvm/lib/CodeGen/GlobalISel/CallLowering.cpp
Commit 71601d2ac9954cb59c443cb3ae442cb106df35d4 by kparzysz
[Hexagon] Fix bitcasting v1i8 -> i8
The file was modifiedllvm/lib/Target/Hexagon/HexagonISelLowering.cpp
The file was addedllvm/test/CodeGen/Hexagon/isel-bitcast-v1i8-i8.ll
Commit 8c4e55762d8b7a07546a5db18e33ccc6a9d97002 by i
[docs][unittest][Go][StackProtector] Migrate deprecated DebugInfo::get to DILocation::get
The file was modifiedllvm/unittests/Transforms/Utils/CloningTest.cpp
The file was modifiedllvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
The file was modifiedllvm/unittests/IR/IRBuilderTest.cpp
The file was modifiedllvm/unittests/CodeGen/LexicalScopesTest.cpp
The file was modifiedllvm/unittests/Frontend/OpenMPIRBuilderTest.cpp
The file was modifiedllvm/lib/CodeGen/StackProtector.cpp
The file was modifiedllvm/bindings/go/llvm/IRBindings.cpp
Commit 0eb4378290ffcd5da650217df3ac3b8c473d5ed6 by Duncan P. N. Exon Smith
Frontend: Fix confusing comment at call to clearOutputFiles, NFC

Fix the comment in front of `compileModuleImpl`'s call to
`CompilerInstance::clearOutputFiles`. The purpose of this call is to
delete any stray temporary files after the module generation thread
crashes.

The comment is from f545f67de3a1bfdbbfad88acde5b540ce3b82f4f, and
was associated with manually deleting a generated module map. Then
13afbf42d830dd43febbeb0855aa359ca9dbfbf9 added this `clearOutputFiles`
call between the comment and the code it referenced. Finally,
1f76c4e8101b9beaf8f1b10a57faa80256ab2b05 started sending the generated
module map directly to the SourceManager instead of putting it on disk,
deleting the call that the comment referenced.

No functionality change.
The file was modifiedclang/lib/Frontend/CompilerInstance.cpp